Fix hover effect on grey circles
Ensure grey circles do not change color on hover.
This commit is contained in:
parent
1ff24d145c
commit
1adc590312
1 changed files with 2 additions and 2 deletions
|
|
@ -79,9 +79,9 @@ const SubtractionGame = () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const getCircleClass = (index: number) => {
|
const getCircleClass = (index: number) => {
|
||||||
const baseClass = 'w-8 h-8 rounded-full border-2 border-black cursor-pointer transition-colors';
|
|
||||||
const isHighlighted = highlightedIndices.includes(index);
|
const isHighlighted = highlightedIndices.includes(index);
|
||||||
const fillClass = isHighlighted ? 'bg-yellow-200 hover:bg-yellow-300' : 'bg-gray-300 hover:bg-gray-400';
|
const baseClass = `w-8 h-8 rounded-full border-2 border-black transition-colors ${isHighlighted ? 'cursor-pointer' : ''}`;
|
||||||
|
const fillClass = isHighlighted ? 'bg-yellow-200 hover:bg-yellow-300' : 'bg-gray-300';
|
||||||
return `${baseClass} ${fillClass}`;
|
return `${baseClass} ${fillClass}`;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue