Skip to content

Commit 1d30144

Browse files
Copilotmgierschdev
andcommitted
Fix captured pieces visibility - add background and text shadow for white pieces
Co-authored-by: mgierschdev <62764972+mgierschdev@users.noreply.github.com>
1 parent fbda28a commit 1d30144

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

frontend/src/app/_client_components/CapturedPieces.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,11 @@ export default function CapturedPieces({pieces, color}: CapturedPiecesProps) {
3838
gap: '4px',
3939
fontSize: '24px',
4040
minHeight: '30px',
41-
alignItems: 'center'
41+
alignItems: 'center',
42+
backgroundColor: '#f0f0f0',
43+
padding: '8px',
44+
borderRadius: '4px',
45+
border: '1px solid #ccc'
4246
}}>
4347
{Object.entries(pieceCounts).map(([type, count]) => (
4448
<div key={type} style={{ display: 'flex', alignItems: 'center' }}>
@@ -47,7 +51,10 @@ export default function CapturedPieces({pieces, color}: CapturedPiecesProps) {
4751
key={`${type}-${index}`}
4852
style={{
4953
marginRight: '2px',
50-
filter: color === 'White' ? 'invert(1)' : 'none'
54+
color: color === 'White' ? '#FFFFFF' : '#000000',
55+
textShadow: color === 'White'
56+
? '-1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000'
57+
: 'none'
5158
}}
5259
>
5360
{pieceSymbols[type] || ''}

0 commit comments

Comments
 (0)