M1.8: command palette, global keymap, UI commands
- Engine: ui.registerCommands (validated, replaces the previous set),
UI commands in listCommands with ui: true and labelKey, running one
through the engine emits uiCommand {id, params}.
- Frontend: ui/src/commands/ (keymap by key code, fuzzy ranking, Pinia
commands store with handlers, recents and error toasts), the command
palette (Mod+Shift+P), UI commands palette.open, settings.open (Mod+,,
disabled until M1.9b) and view.toggleProjectTree (Mod+1). The editor's
shortcuts.ts moved into the global keymap.
- Tests: engine and control-channel tests for registration and
uiCommand, Vitest for keymap, ranking, store, palette and App wiring.
- Docs: architecture, ui-parity, target-app-parity, gaps, roadmap,
ROADMAP, README.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
2f8fef876b
commit
184b8a3468
33 changed files with 2282 additions and 233 deletions
|
|
@ -1,8 +1,11 @@
|
|||
//! Workspace state that commands read and change.
|
||||
|
||||
use std::collections::{BTreeMap, BTreeSet};
|
||||
|
||||
use serde_json::{Map, Value};
|
||||
|
||||
use crate::buffers::Buffers;
|
||||
use crate::cmd::ui::UiCommand;
|
||||
use crate::journal::Journal;
|
||||
use crate::settings::Settings;
|
||||
use crate::workspace::Workspace;
|
||||
|
|
@ -28,6 +31,10 @@ pub struct State {
|
|||
/// The crash-recovery journal of the open project; `None` without a
|
||||
/// project or without persistence.
|
||||
pub journal: Option<Journal>,
|
||||
/// Ids of the engine's own commands, which UI commands may not take.
|
||||
pub engine_commands: BTreeSet<&'static str>,
|
||||
/// UI commands the frontend registered (`ui.registerCommands`), by id.
|
||||
pub ui_commands: BTreeMap<String, UiCommand>,
|
||||
/// Number of notifications emitted, for their ids.
|
||||
notifications: u64,
|
||||
/// Events queued for the host, oldest first.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue