Skip to content

Commit

Permalink
Update resources (#126)
Browse files Browse the repository at this point in the history
Resources no longer show tapped. Resource box hover effect now works

---------

Co-authored-by: Dan Bastin <[email protected]>
  • Loading branch information
Trys2Hard and danbastin authored Feb 24, 2025
1 parent 2e48889 commit ef987ea
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,11 @@ const Resources: React.FC<IResourcesProps> = ({
transition: 'background-color 0.3s ease',
padding: '1rem 2rem',
overflow: 'visible',
cursor: 'pointer',
'&:hover': {
background:
trayPlayer === 'player'
? 'linear-gradient(to top, white, transparent)'
trayPlayer === connectedPlayer
? 'rgba(255, 255, 255, 0.1)'
: null,
},
},
Expand All @@ -48,7 +49,6 @@ const Resources: React.FC<IResourcesProps> = ({
justifyContent: 'center',
alignItems: 'center',
flexDirection: 'row',
cursor: 'pointer',
position: 'relative',
zIndex: 1,
},
Expand Down
4 changes: 2 additions & 2 deletions src/app/_components/_sharedcomponents/Cards/GameCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ const GameCard: React.FC<IGameCardProps> = ({
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
transform: card.exhausted ? 'rotate(4deg)' : 'none',
transform: card.exhausted && card.zone !== 'resource' ? 'rotate(4deg)' : 'none',
transition: 'transform 0.15s ease',
'&:hover': {
cursor: disabled ? 'normal' : 'pointer',
Expand All @@ -154,7 +154,7 @@ const GameCard: React.FC<IGameCardProps> = ({
position: 'absolute',
width: '100%',
height: '100%',
backgroundColor: card?.exhausted ? 'rgba(0, 0, 0, 0.5)' : 'transparent',
backgroundColor: card?.exhausted && card.zone !== 'resource' ? 'rgba(0, 0, 0, 0.5)' : 'transparent',
filter: 'none',
clickEvents: 'none',
display: 'flex',
Expand Down

0 comments on commit ef987ea

Please sign in to comment.