Skip to content

The agent that grows with you

fix(desktop): give HUD gestures their own keybindings page

brooklyn!fca3221df48d
diff --git a/apps/desktop/src/app/settings/keybind-settings.tsx b/apps/desktop/src/app/settings/keybind-settings.tsx
index 334ce00c122..1d294e08563 100644
--- a/apps/desktop/src/app/settings/keybind-settings.tsx
+++ b/apps/desktop/src/app/settings/keybind-settings.tsx
@@ -39,6 +39,14 @@ interface KeybindSettingsProps {
}
export function KeybindSettings({ subpage }: KeybindSettingsProps = {}) {
+ if (subpage === 'hud-gesture') {
+ return (
+ <SettingsContent>
+ <HudModifierSettings />
+ </SettingsContent>
+ )
+ }
+
if (subpage === 'screen-capture') {
return (
<SettingsContent>
@@ -138,11 +146,6 @@ function ShortcutSettings({ includeScreenshot }: { includeScreenshot: boolean })
<ScreenshotSettings />
)}
- {(!isSearching ||
- `${t.settings.hudModifier.title} ${t.settings.hudModifier.description}`
- .toLowerCase()
- .includes(query.toLowerCase())) && <HudModifierSettings />}
-
<div className="pb-3">
<SearchField
aria-label={k.search}
diff --git a/apps/desktop/src/app/settings/other-subpages.ts b/apps/desktop/src/app/settings/other-subpages.ts
index 6f550a9a7ce..8fd3cc425bd 100644
--- a/apps/desktop/src/app/settings/other-subpages.ts
+++ b/apps/desktop/src/app/settings/other-subpages.ts
@@ -9,6 +9,7 @@ export const OTHER_SUBPAGES: Record<string, { id: string; labelKey: string }[]>
],
keybinds: [
{ id: 'shortcuts', labelKey: 'keyboardShortcuts' },
+ { id: 'hud-gesture', labelKey: 'hudGesture' },
{ id: 'screen-capture', labelKey: 'screenCapture' }
],
notifications: [
diff --git a/apps/desktop/src/app/settings/subpages.test.ts b/apps/desktop/src/app/settings/subpages.test.ts
index 11374407130..b176bc2c16d 100644
--- a/apps/desktop/src/app/settings/subpages.test.ts
+++ b/apps/desktop/src/app/settings/subpages.test.ts
@@ -50,6 +50,8 @@ describe('settings subpage routing', () => {
const cases: [SettingsView, string, string][] = [
['config:model', 'aux=vision', 'auxiliary'],
+ ['keybinds', 'setting=hud-modifier', 'hud-gesture'],
+ ['keybinds', 'page=shortcuts&setting=hud-modifier', 'hud-gesture'],
['sessions', 'session=archived-id', 'archived'],
['vault', 'kind=login', 'credentials'],
['vault', 'label=Example', 'credentials'],
diff --git a/apps/desktop/src/app/settings/subpages.ts b/apps/desktop/src/app/settings/subpages.ts
index 2f7f470be08..490dc0a5a00 100644
--- a/apps/desktop/src/app/settings/subpages.ts
+++ b/apps/desktop/src/app/settings/subpages.ts
@@ -75,6 +75,7 @@ const SUBPAGE_ICONS: Record<string, IconComponent> = {
gatewayDevices: Network,
gatewayManagedUpdates: Download,
keyboardShortcuts: Keyboard,
+ hudGesture: Keyboard,
screenCapture: FileImage,
notificationAlerts: Bell,
notificationSounds: Volume2,
@@ -104,6 +105,10 @@ export function settingsSubpages(view: SettingsView): readonly SettingsSubpage[]
/** Shared by search serialization and saved links that predate subpages. */
export function settingsSubpageForTarget(view: SettingsView, field?: string, setting?: string): string | undefined {
+ if (view === 'keybinds' && setting === 'hud-modifier') {
+ return 'hud-gesture'
+ }
+
if (view === 'config:appearance' && setting) {
return appearanceSubpageForSetting(setting)
}
diff --git a/apps/desktop/src/app/settings/use-settings-search.ts b/apps/desktop/src/app/settings/use-settings-search.ts
index a57e7e6ad49..02b77da61f6 100644
--- a/apps/desktop/src/app/settings/use-settings-search.ts
+++ b/apps/desktop/src/app/settings/use-settings-search.ts
@@ -301,7 +301,7 @@ export function useSettingsSearchCatalog(enabled: boolean) {
keywords: ['HUD', 'summon', 'modifier', 'tap', 'Ctrl', 'Alt', 'Command', 'Option'],
label: t.settings.hudModifier.title,
description: t.settings.hudModifier.description,
- target: { view: 'keybinds' as const, subpage: 'shortcuts', setting: 'hud-modifier' }
+ target: { view: 'keybinds' as const, subpage: 'hud-gesture', setting: 'hud-modifier' }
}
]
: [])
diff --git a/website/docs/user-guide/desktop.md b/website/docs/user-guide/desktop.md
index 39ee2403a47..4e746a99560 100644
--- a/website/docs/user-guide/desktop.md
+++ b/website/docs/user-guide/desktop.md
@@ -174,7 +174,7 @@ Talk to Hermes and hear it back, the same [voice mode](./features/voice-mode.md)
- **Moving the bar** — on macOS and Windows, **press and hold** anywhere on the composer for a beat, then drag. On Linux/X11, hold **Ctrl** and drag with the primary mouse button for an immediate grab (including over selected text); press-and-hold remains available too. Keep the grab held while invoking your desktop switch shortcut to carry the HUD onto another virtual desktop. On native Wayland the composer bar is a compositor drag handle (the only way to move it, because an app cannot place its own window).
- **Resizing** — drag any edge or corner of the bar; the opposite edge stays anchored. Native Wayland exposes the right and bottom edges because the compositor does not allow apps to position top-level windows themselves.
- **Reset layout** — the discard control on the bar restores the default size and (on X11 / macOS / Windows) position. Use this if a persisted size leaves the HUD unusable.
-- **Tap to summon** — enable **Settings → Keyboard Shortcuts → Tap to summon HUD**, then tap and release **⌘+Option** on macOS or **Ctrl+Alt** on Windows/Linux X11. Release both keys within half a second without another key or mouse action. On Windows, use left Alt; right Alt is reserved for AltGr layouts. This opens or focuses the HUD from another app; it does not toggle it closed, record audio, or send a message. Off by default and saved only on this device. macOS requires Input Monitoring permission; the settings row offers permission recovery and reports when the listener is ready. Linux Wayland does not expose this gesture, so keep using the in-app HUD shortcut there.
+- **Tap to summon** — enable **Tap to summon HUD** under **Settings → Keyboard Shortcuts → HUD gesture**, then tap and release **⌘+Option** on macOS or **Ctrl+Alt** on Windows/Linux X11. Release both keys within half a second without another key or mouse action. On Windows, use left Alt; right Alt is reserved for AltGr layouts. This opens or focuses the HUD from another app; it does not toggle it closed, record audio, or send a message. Off by default and saved only on this device. macOS requires Input Monitoring permission; the page offers recovery controls only when permission or another error needs attention. Linux Wayland does not expose this gesture, so keep using the in-app HUD shortcut there.
- **Snap to pointer** — **⌘/Ctrl+Shift+G** (a global hotkey, works from any app) jumps the HUD to wherever your cursor is. On native Wayland this is a no-op — the compositor owns placement.
- **Exiting** — click the exit button on the bar, press **⌘/Ctrl+Shift+H** again, or press **⌘/Ctrl+W** while the HUD has focus. The app window comes back in front with your session and the caret in its composer.