From c80b9cedb6458de65b9fdf05631bc0c6bc15ae0d Mon Sep 17 00:00:00 2001 From: tiennm99 Date: Tue, 28 Apr 2026 11:09:57 +0700 Subject: [PATCH] fix(mobile): kill footer mistouch and dock/board overlap Footer link was overlapping the on-screen D-pad and action stack tap zones during gameplay. Hide the footer on the game view and respect safe-area-inset on the screens where it stays. MobileControls drops position:fixed and lives in a flex row at the bottom of GameView's flex column. .board-wrap is now flex:1 1 auto with min-height:0 so puzzles scroll inside their wrapper, never under the controls. Magic max-height:calc(100vh - 260px) gone. RESET on mobile is now two-tap armed (label flips to TAP AGAIN, red background, 2s timeout) so a stray thumb cannot wipe a puzzle. The R keyboard shortcut is unchanged. D-pad arrows fire on pointerdown and auto-repeat at 130ms while held, matching the keyboard REPEAT_MS. preventDefault on pointerdown blocks the synthesized click double-fire. $effect cleanup clears intervals on unmount. Armed RESET text switched to white (4.85:1 on --danger) to clear WCAG-AA; using --bg failed at 3.1:1. --- src/App.svelte | 12 +-- src/views/GameView.svelte | 17 ++-- src/views/MobileControls.svelte | 136 ++++++++++++++++++++++++++------ 3 files changed, 132 insertions(+), 33 deletions(-) diff --git a/src/App.svelte b/src/App.svelte index f35d31f..23feb3a 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -31,17 +31,19 @@ {/key} {/if} - +{#if view !== 'game'} + +{/if}