Line

ui/client/features/command-palette/services/PaletteBrowser

Cockpit client (features), v0.9. Source: ui/client/features/command-palette/services/PaletteBrowser.ts.

Functions#

rememberFocus()#

rememberFocus(): () => void

Defined in: ui/client/features/command-palette/services/PaletteBrowser.ts:16

Remembers the focused element and returns a function that puts focus back on it.

Returns#

() => void


subscribePaletteShortcut()#

subscribePaletteShortcut(onToggle): () => void

Defined in: ui/client/features/command-palette/services/PaletteBrowser.ts:4

Calls onToggle on Ctrl/Cmd+K anywhere (capture phase, so editors cannot swallow it). Returns an unsubscribe.

Parameters#

onToggle

() => void

Returns#

() => void