Skip to content

feat: close command palette with the same shortcut#443

Merged
Kraci merged 1 commit into
mainfrom
close-palette-with-the-same-shortcut-en-1073
Jun 22, 2026
Merged

feat: close command palette with the same shortcut#443
Kraci merged 1 commit into
mainfrom
close-palette-with-the-same-shortcut-en-1073

Close command palette with the same shortcut

c379b0f
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Jun 21, 2026 in 7m 8s

Code review found 1 potential issue

Found 1 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 1
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit src/features/dashboard/sidebar/command.tsx:38-42 Cmd+K key-repeat flickers the palette open/closed

Annotations

Check warning on line 42 in src/features/dashboard/sidebar/command.tsx

See this annotation in the file changed.

@claude claude / Claude Code Review

Cmd+K key-repeat flickers the palette open/closed

Holding Cmd/Ctrl+K past the OS key-repeat delay (~500ms) now flickers the palette open/closed at ~30Hz, because the new `setOpen((prev) => !prev)` toggle flips state on every auto-repeat keydown (the previous `setOpen(true)` was idempotent and masked this). Add `if (event.repeat) return` before the toggle — the conventional guard for toggle shortcuts.