From 0498f1de436ec01f495cb3c2d5a5153b01e026d1 Mon Sep 17 00:00:00 2001 From: "claude (blind_chess)" Date: Mon, 18 May 2026 20:04:49 -0400 Subject: [PATCH] feat(client): label attempted-move announcements by player MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Attempted-move lines (no_such_piece, no_legal_moves, wont_help, illegal_move) now show "White — " or "Black — " prefix derived from ply parity. Removed alarm-red err styling; replaced with neutral dim+italic via .entry.attempt. Co-Authored-By: Claude Opus 4.7 (1M context) --- packages/client/src/lib/ModeratorPanel.svelte | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/client/src/lib/ModeratorPanel.svelte b/packages/client/src/lib/ModeratorPanel.svelte index 011a575..ff83b5b 100644 --- a/packages/client/src/lib/ModeratorPanel.svelte +++ b/packages/client/src/lib/ModeratorPanel.svelte @@ -24,9 +24,11 @@
Moderator
{#each visible as a, i (i)} -
+ {@const isAttempt = a.text === 'no_such_piece' || a.text === 'no_legal_moves' || a.text === 'wont_help' || a.text === 'illegal_move'} + {@const actor = a.ply % 2 === 0 ? 'White' : 'Black'} +
{a.ply > 0 ? `#${a.ply}` : ''} - {moderatorText(a.text, a.payload)} + {isAttempt ? `${actor} — ` : ''}{moderatorText(a.text, a.payload)}
{:else}
The moderator is silent.
@@ -67,7 +69,7 @@ border-bottom: 1px dashed rgba(255,255,255,0.05); } .entry:last-child { border-bottom: none; } - .entry.err .text { color: #f87171; } + .entry.attempt .text { color: var(--text-dim); font-style: italic; } .ply { color: var(--text-dim); font-family: ui-monospace, monospace;