Keyboard Shortcuts and Navigation Methods in the AgentsView Session Browser
AgentsView provides vim-style navigation and command-palette shortcuts accessible via the "?" key, enabling complete keyboard-driven session browsing without touching the mouse.
The kenn-io/agentsview repository ships with a comprehensive set of keyboard shortcuts and navigation methods designed for efficient session browsing. These controls are defined in the ShortcutsModal component and allow users to traverse messages, switch sessions, and invoke actions entirely from the keyboard. Whether you prefer vim-style navigation or standard application shortcuts, the interface supports both modalities to streamline your workflow.
Complete Keyboard Shortcut Reference
Global Actions and Quick Access
| Shortcut | Action | Implementation |
|---|---|---|
| ⌘ K / Ctrl K | Open the command palette (quick‑search / actions) | CommandPalette.svelte |
| ⌘ F / Ctrl F or / | Find in the current session | SessionFindBar.svelte |
| Esc | Close any open modal, palette, or the find bar | Global handler |
| ? | Show the shortcuts help modal | ShortcutsModal.svelte |
Message Navigation (Vim-Style)
| Shortcut | Action |
|---|---|
| j or ↓ | Move to the next message in the conversation |
| k or ↑ | Move to the previous message |
| o | Toggle the sort order of messages (newest ↔ oldest) |
| l | Cycle through the available message layout styles |
Session Management and Actions
| Shortcut | Action |
|---|---|
| ] | Switch to the next session in the sidebar |
| [ | Switch to the previous session |
| s | Star / un‑star the current session |
| r | Manually trigger a sync with the file system |
| e | Export the session to a local file |
| p | Publish the session to a Gist |
| c | Copy the command that can resume the session in a terminal |
| Del | Delete the current session (with confirmation) |
Desktop-Specific Zoom Controls
When running the Electron-based desktop client (sync.isDesktop), additional zoom shortcuts become available in ShortcutsModal.svelte (lines 27‑31):
- ⌘ + + / Ctrl + + — Zoom in
- ⌘ + – / Ctrl + – — Zoom out
- ⌘ + 0 / Ctrl + 0 — Reset zoom to default
These are defined separately from the base shortcuts (lines 8‑25) because they only apply to the desktop environment.
Navigation Methods Beyond Keyboard Shortcuts
Command Palette (⌘ K / Ctrl K)
The Command Palette provides a searchable interface for commands, session filters, and actions. Implemented in frontend/src/lib/components/command-palette/CommandPalette.svelte, this component opens when you press the platform-specific command key combination, allowing fuzzy-search access to all application functions.
Find in Session (⌘ F / Ctrl F or /)
The Find in Session feature displays a text-search bar that highlights matches across the current session’s messages. This is handled by frontend/src/lib/components/content/SessionFindBar.svelte and supports real-time filtering as you type.
Sidebar Session List Navigation
The session sidebar, rendered by frontend/src/lib/components/sidebar/SessionList.svelte, supports both mouse and keyboard navigation. While you can click individual sessions, the [ and ] keys provide sequential traversal without moving your hands from the home row.
Message List Traversal
The MessageList.svelte component handles message navigation, reacting to j/k or arrow key inputs to highlight the active message in the UI. This creates a focused reading experience where the selected message is visually distinct from the rest of the conversation.
Implementation in Source Code
All keyboard shortcuts are defined in frontend/src/lib/components/modals/ShortcutsModal.svelte:
- Base shortcuts (lines 8‑25): Define navigation, session management, and global actions
- Zoom shortcuts (lines 27‑31): Platform-specific zoom controls for desktop clients
The modal itself serves as both the definition file and the help interface, displaying the shortcut reference table when invoked via the ? key.
Programmatically Triggering Shortcuts
You can open the shortcuts modal programmatically by setting the active modal state:
<script>
import { ui } from '../stores/ui.svelte';
// Open the shortcuts modal (same as pressing "?")
ui.activeModal = 'shortcuts';
</script>
To trigger a manual sync from a custom handler (equivalent to pressing r):
// Trigger a manual sync from a shortcut handler
if (e.key === 'r') {
sync.trigger(); // defined in src/lib/stores/sync.svelte.js
}
Summary
- Keyboard shortcuts and navigation methods in the AgentsView session browser are defined in
ShortcutsModal.svelteand activated via single keys or modifier combinations. - Vim-style navigation (j/k) and session switching ([ / ]) allow hands-free browsing of conversations.
- The Command Palette (⌘ K / Ctrl K) and Find Bar (⌘ F / Ctrl F) provide search-driven navigation without mouse interaction.
- Desktop-only zoom shortcuts (⌘ + + / – / 0) are conditionally available when
sync.isDesktopis true. - All shortcuts can be referenced by pressing ?, which renders the help modal component.
Frequently Asked Questions
How do I view all available keyboard shortcuts in AgentsView?
Press the ? key to display the ShortcutsModal component. This modal lists every available shortcut, including platform-specific variations for macOS (⌘) and Windows/Linux (Ctrl).
Can I navigate between different sessions without using the mouse?
Yes. Use the [ key to move to the previous session and ] to move to the next session in the sidebar. These shortcuts are handled by SessionList.svelte and work regardless of whether the sidebar has focus.
Are the zoom shortcuts available in the web version of AgentsView?
No. The zoom shortcuts (⌘ + + / Ctrl + +, ⌘ + – / Ctrl + –, and ⌘ + 0 / Ctrl + 0) are available only in the desktop Electron client. The application detects the desktop environment via sync.isDesktop and conditionally registers these shortcuts in ShortcutsModal.svelte.
How do I search for specific text within a session?
Press ⌘ F / Ctrl F or the / key to open the SessionFindBar component. This displays a search bar that highlights matches across all messages in the current session, allowing you to quickly locate specific content without scrolling.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →