final implementation of requested behaviors

This commit is contained in:
vndangkhoa 2026-04-29 16:24:31 +07:00
parent f556b7dcc0
commit e660dfa637

View file

@ -44,8 +44,13 @@ function TetrisPiece({ piece, isDark }) {
}
};
// Start with background color (will be overridden by animation for mobile)
const bgColor = piece.label === 'cv' ? piece.color : (isDark ? piece.colorDark : piece.color);
// For desktop: start gray, show hover color when hovering
// For mobile: use actual color (will be animated)
const bgColor = piece.label === 'cv'
? piece.color
: (isDark || isMobile)
? (color || piece.color)
: '#cccccc'; // Start gray for desktop
const rowDelay = piece.startY * 8;
const textColor = '#ffffff';
const isStatic = piece.label === 'cv' || piece.featured;