Skip to content

Commit 5d6392c

Browse files
committed
feat(frontend): improve command palette accessibility semantics
1 parent e4cae78 commit 5d6392c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

frontend/src/components/CommandPalette.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,10 +378,11 @@ export function CommandPalette() {
378378
if (!open) return null;
379379

380380
return (
381-
<div className="fixed inset-0 z-50 flex items-start justify-center pt-24">
381+
<div className="fixed inset-0 z-50 flex items-start justify-center pt-24" role="dialog" aria-modal="true" aria-label="Command palette">
382382
<div
383383
className="absolute inset-0 bg-black/70"
384384
onClick={closePalette}
385+
aria-hidden="true"
385386
/>
386387
<div className="relative w-full max-w-lg bg-void-light border border-hud-border overflow-hidden">
387388
<div className="corner-mark corner-mark-tl" />
@@ -438,6 +439,7 @@ export function CommandPalette() {
438439
autoFocus
439440
value={query}
440441
onChange={(e) => setQuery(e.target.value)}
442+
aria-label={t("placeholder")}
441443
placeholder={mode === "global" ? t("globalPlaceholder") : t("placeholder")}
442444
className="w-full px-4 py-3 bg-transparent text-hud-text font-mono text-base placeholder-hud-label focus:outline-none"
443445
/>

0 commit comments

Comments
 (0)