From c8332bb12230b0abe5c27654f06ba867ca364a62 Mon Sep 17 00:00:00 2001 From: Ilia Denisov Date: Sat, 9 May 2026 21:52:24 +0200 Subject: [PATCH] ui/phase-17: clamp ship-class name input to validator's 30-rune limit Mirrors the validateEntityName MAX_LENGTH on the form input so the field stops accepting characters once the limit is hit. The validator still runs and surfaces the localised reason if a paste overshoots; the maxlength is purely a typing-time guardrail. Co-Authored-By: Claude Opus 4.7 --- ui/frontend/src/lib/active-view/designer-ship-class.svelte | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/frontend/src/lib/active-view/designer-ship-class.svelte b/ui/frontend/src/lib/active-view/designer-ship-class.svelte index 7bb39cb..87787c7 100644 --- a/ui/frontend/src/lib/active-view/designer-ship-class.svelte +++ b/ui/frontend/src/lib/active-view/designer-ship-class.svelte @@ -250,6 +250,7 @@ the value fields so the diff in Phase 18 stays minimal. bind:this={nameInputEl} bind:value={name} data-testid="designer-ship-class-input-name" + maxlength="30" aria-invalid={validation.ok ? "false" : "true"} />