Settings shortcuts documented and empty clip timer fixed
· 2 min read
EXEPERT now treats visualizer keyboard controls as documented commands instead of hidden global behavior, and the right-panel clip preview no longer pretends a video is loaded when the stimulus slot is empty.
What changed
src/ui/keyboard-shortcuts.tsadds a shared registry for visible keyboard commands and a guard that decides whether global scene shortcuts should run.src/events.tsnow scopes the visualizer shortcuts soSpace,A, andSonly affect the 3D scene when focus is outside inputs, buttons, chat, search, Settings, diagnostics, prompt playground, andlil-guicontrols.index.htmladds a Keyboard Shortcuts & Commands card to Settings and changes the initial clip preview from a fake0:06duration to an explicit empty state.src/ui/workbench.tsrenders the Settings command list from the shortcut registry so the visible docs match the active runtime behavior.src/ui/media-duration.tscentralizes duration labels: no stimulus shows:, images showStill, videos show their metadata duration, and unknown loaded media showsLoaded.src/brain-ui.tsnow resets cleared media to an empty state, waits for video metadata before showing a duration badge, and removes the clip-thumb badge when no stimulus is loaded.css/app.cssadds the empty clip thumbnail style and responsive Settings shortcut rows with compactkbdchips, scope labels, and wrapped descriptions.src/__tests__/keyboard-shortcuts.test.tsandsrc/__tests__/media-duration.test.tscover the shortcut guard and duration label behavior.
User impact
- Pressing
A,S, orSpacewhile typing in Chat or interacting with Settings no longer toggles visualizer helpers by accident. - Settings now lists the app's current global and contextual commands, including Search, Diagnostics, Chat send, model picker navigation, and the Floor Platform visualizer command.
- Fresh app load and cleared clips show Duration : and a muted No clip
thumbnail instead of
0:06. - Uploaded images show Still instead of a fake video duration; uploaded videos show their real metadata duration once available.
Verification
Checked locally with:
pnpm typecheck
pnpm exec vitest run src/__tests__/keyboard-shortcuts.test.ts src/__tests__/media-duration.test.ts
pnpm build
The browser smoke test opened http://localhost:9001/, confirmed the empty clip
state, confirmed the Settings list rendered nine command rows, and verified
A, S, and Space type normally inside the Chat input.