From 2d7a6fc848665c94ca4e51e382f76ff3f800b634 Mon Sep 17 00:00:00 2001 From: CutieCat2804 Date: Wed, 16 Oct 2024 20:11:08 +0200 Subject: [PATCH] add restart button to window mode --- src/components/Board.tsx | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/components/Board.tsx b/src/components/Board.tsx index 37dcd96..a41afbf 100644 --- a/src/components/Board.tsx +++ b/src/components/Board.tsx @@ -122,7 +122,7 @@ const Board: React.FC = (props) => { }, [onViewportChange]); const theme = useTheme( // eslint-disable-next-line @typescript-eslint/no-explicit-any - themes.find((t) => t.id === (game.theme as any))!.theme, + themes.find((t) => t.id === (game.theme as any))!.theme ); const boardWidth = game.width * (theme?.size || 0); const boardHeight = game.height * (theme?.size || 0); @@ -154,7 +154,7 @@ const Board: React.FC = (props) => { className={cn( "w-full h-[70vh] overflow-hidden outline-white/40 outline-2 flex flex-col", zenMode && "fixed top-0 left-0 z-50 right-0 bottom-0 h-[100vh]", - props.className, + props.className )} style={{ width: props.width ? `${props.width}px` : undefined, @@ -164,11 +164,9 @@ const Board: React.FC = (props) => { >
- {zenMode && ( - - )} +