Skip to content

Commit

Permalink
fixed two bugs with hiding cards.
Browse files Browse the repository at this point in the history
  • Loading branch information
ecm85 committed Aug 9, 2024
1 parent bcc2cb1 commit 84a5c6d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion SpaceAlertResolver/UI/src/pages/CreateGame.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export function CreateGame() {
</div>
<FormGroup>
<FormControlLabel
control={<Switch value={hideCards} onChange={() => setHideCards(!hideCards)} />}
control={<Switch checked={hideCards} onChange={() => setHideCards(!hideCards)} />}
label="Hide cards (reveal turn-by-turn)"
/>
</FormGroup>
Expand Down
4 changes: 2 additions & 2 deletions SpaceAlertResolver/UI/src/pages/InputCards.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,11 @@ export function InputCards({ gameCode, connectionRef }: InputCardsProps) {
<ColorPicker onPickColor={handleColorPicked} value={playerColor} />
<FormGroup>
<FormControlLabel
control={<Switch value={hideCards} onChange={() => setHideCards(!hideCards)} />}
control={<Switch checked={hideCards} onChange={() => setHideCards(!hideCards)} />}
label="Hide cards (reveal turn-by-turn)"
/>
</FormGroup>
<PlayerBoard scannedCards={scannedCards} playerColor={playerColor} hideCards />
<PlayerBoard scannedCards={scannedCards} playerColor={playerColor} hideCards={hideCards} />
<div>
{isSubscribed && workflowState === WorkflowState.Scanned && (
<Button onClick={handleSendToServerClicked} variant="contained">
Expand Down

0 comments on commit 84a5c6d

Please sign in to comment.