From b92016db51b38aee825a247256165781b77c3692 Mon Sep 17 00:00:00 2001 From: Eric Wagoner Date: Fri, 4 Sep 2026 16:00:09 -0400 Subject: [PATCH] The unasked council leaves with the turn Advice offered on a first turn stayed on the sidebar until dismissed, as advice a player asked for should. Offered advice now clears when the turn passes; asking again keeps it. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01Jm2auWk6RP71CjaAb4FMoG --- packages/web/src/App.svelte | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/web/src/App.svelte b/packages/web/src/App.svelte index 2937082..4a9416c 100644 --- a/packages/web/src/App.svelte +++ b/packages/web/src/App.svelte @@ -1312,6 +1312,7 @@ let councilHints = $state(null); async function askCouncil() { if (!view) return; + if (councilHints !== null) councilUnasked = false; // asked again: theirs to keep const { tableHints } = await import("./hints"); councilHints = tableHints(view); } @@ -1383,11 +1384,18 @@ /** On a first turn the council speaks unasked, once — a newcomer will * not know to ask, and a minute's silence is how they leave. */ let counciled = false; + /** The unasked advice is for that one turn: it leaves when the turn does. */ + let councilUnasked = false; $effect(() => { if (!view || !isYourTurn || prefs.coached || view.turn.round !== 1 || counciled || councilHints !== null) return; counciled = true; + councilUnasked = true; void askCouncil(); }); + $effect(() => { + if (!councilUnasked || !view) return; + if (!isYourTurn || view.turn.round !== 1) { councilHints = null; councilUnasked = false; } + }); /** Arrow keys and WASD walk on the board, as they do in the first-person * pane — that pane takes the keys itself while it is up. */