- Themes: a plugin theme is an `appearance.theme` value
(`plugin:<id>/<theme>`), offered by Settings › Appearance (and the
preferred themes of Sync with OS), Quick Switch, the toolbar gear menu and
Welcome › Customize. The project window selects it in the plugin host;
picking a built-in theme clears it. While its plugin is off, the built-in
theme of its kind shows and the choice is kept.
- File icon themes: chosen in Settings › Appearance › File icon theme and
kept in `appearance.fileIconTheme`, so every window follows.
- Keymap: plugins' default shortcuts show in Settings › Keymap as the
defaults of their actions: removable, changeable, resettable and part of
conflict checks.
- Problems: a plugin's problems are withdrawn when it stops, fails, is
disabled or uninstalled. Settings › Inspections lists them under Plugins by
plugin name; stored overrides of `plugin:` producers parse correctly.
- Status bar items of plugins are named in the status bar menu and can be
hidden.
- Languages added or removed by plugins refresh Override File Type, the
Code Style pages and Inspections without a restart.
- Uninstalling a plugin deletes the secrets it declared.
- The Settings window follows plugin changes made elsewhere.
- The plugin system is marked Preview (Settings › Plugins, README); Harbor
Night is versioned 0.1.0 like the other official plugins.
- Release: the official plugins are packed, signed (secret
PLUGIN_SIGNING_KEY) and indexed into the release as
`plugins-index.json`; released builds use it as the default marketplace.
Without the key the step is skipped.
- Graphviz: `.dot` / `.gv` files open beside a live preview (a web view
rendering with Graphviz compiled to WebAssembly) in any layout engine,
with zoom, pan, Fit and SVG / PNG export through the save dialog. What
Graphviz reports goes from the page to the plugin's code, which publishes
it as problems on the named line. A DOT language, file icons and a
New Graphviz Graph template.
- Regex Tester: a tool window whose html view sends pattern, flags, text and
replacement as you type; the plugin matches with Rust's regex (linear time)
and answers with matches, groups and the replacement in UTF-16 offsets.
Use Selection and Test Selection take the editor's selection.
- License Header: files without a copyright / SPDX header are reported when
they open and on save; a quick fix and a command add one in the file's
comment syntax (after a shebang or encoding line); a project scan in a
background task reports the rest. Holder and license are settings.
- Harbor Night becomes an official plugin and the one source of the theme
files: `openidea-plugin new --template theme`, the theme docs and tests
start from it.
- Tool windows' renders and events carry the window's active editor, as
commands do, so a view's buttons can act on what the user is editing.
- knip leaves plugins' web pages (projects of their own) alone.
- Remove the Kubernetes official plugin.
- `hello` and `language-toy` move from `plugins/` to
`crates/ide-plugin/tests/fixtures/`: they stay what the host's tests run
against, but are no longer listed as plugins of the repository.
- A `jobs` fixture takes over what only Kubernetes exercised: a tree view
filled by a pinned program, a terminal for the activated entry in the
invoking window, string and number settings, locally and in remote
projects.
- `plugins/` now holds only the official plugins; `build.sh`, CI and the
debug plugin catalog follow.
Install Plugin from Package File now takes an `.oiplugin`, a `.zip` or a
package folder's `plugin.toml`, and goes through the same install page
(capabilities, signature, consent) as every other install.
- A zip may hold the package at its root or in its only folder, as zipping
the folder makes; archiver metadata (`__MACOSX`, `.DS_Store`, `._*`) is
left out. A zip without a `plugin.toml` there, such as an IntelliJ plugin,
is refused with a message saying so. Unsafe paths, links and size limits
are checked as for `.oiplugin` files.
- Picking a `plugin.toml` installs its folder.
Co-authored-by: florentvdry <16673235+florentvdry@users.noreply.github.com>
Plugins can now ship a web page as the UI of a view or custom editor
(`web = "web/index.html"`), so editors built on web libraries are plugins
rather than part of the core.
- Web views: every file under the page's directory is part of the package
(checked, copied on install, covered by the digest and signature) and
served through the `openidea-plugin` URL scheme, under a per-revision
path with a CSP of its own, into an `<iframe sandbox="allow-scripts">`.
An update or reinstall reloads open pages.
- Frame bridge (`window.openidea`), shared by html bodies and web pages:
theme, messages to the plugin's code, `document.get/edit/replace/onChange`
(versioned edits that join the text editor's undo history, Save and dirty
state), `saveFile`/`openFile` through the IDE's dialogs, and IDE shortcuts
the page leaves alone.
- Custom editor layouts: tab, split (Editor and X) or preview over the text
editor, switchable from the tab's actions.
- New points `fileIcons` and `fileTemplates`; new optional capability
`clipboard` for web views.
- Excalidraw official plugin: `.excalidraw` / `.excalidraw.json` open as an
interactive canvas kept in step with the file's text, with self-hosted
fonts, PNG/SVG export, images, file icons, a New Drawing template and
JSON highlighting. Closes#732.
- Fixes: a lock-order deadlock between listing plugins and refreshing
project pins; the dev server ignored edits under `src/features/plugins`.
- `plugins/build.sh` builds and checks web pages; CI typechecks and tests
them.
Co-authored-by: Deng Liu <5108773+dengliu@users.noreply.github.com>
Plugin API (breaking; the plugin system is unreleased):
- Remove the runtime `contributions` interface (register-command,
register-language, register-theme). Commands, languages and themes are
declared in plugin.toml only, so everything a plugin contributes goes
through the install preview and consent. The registry drops runtime
scope, `contribute` and `dispose_runtime`; inline `definition` in
language and theme declarations is gone.
- `completion-item.kind` is a string (the 25 LSP kinds; unknown kinds show
no icon), like the other open-ended kinds.
- `lifecycle.activate` and `commands.run` return `types.error` instead of a
string. The host maps it to the matching error kind, and only `failed`
counts against the plugin: cancelling, a missing grant or an unknown
command does not. The SDK's `Plugin` returns `Result<_, Error>`; plain
messages convert to `Error::Failed`.
Runtime:
- Editor providers of several plugins are called at the same time
(`Actor::submit` + `Pending::wait`): the wait is the slowest plugin's,
not the sum, so each gets the full edit-path budget.
Versioning and tooling:
- Components are checked at install and by `openidea-plugin check` for the
plugin API they were built for; another major or a newer minor is
refused with what to do.
- Tests: the SDK's WIT matches the host's, a simulated next-minor host
links every shipped component, every host function has an SDK wrapper,
released APIs only grow (no snapshot until the first release).
- plugins/build.sh builds every checked-in component, records a source
fingerprint next to it, and `--check` fails on stale components; CI runs
it plus fmt, clippy (host and wasm) and tests for the SDK, the official
plugins and the fixtures.
- The API evolution rules and the checklist for a new host function are in
plugins/README.md; the design notes under docs/ are removed.
- Inject `data-theme` and stable `--openidea-*` colour and font variables
(concrete values; the frame has no IDE stylesheet) into html view bodies.
- Post theme changes to the loaded frame instead of rebuilding srcdoc, so a
theme switch keeps the frame's state; re-send on load to close the race.
- Expose `openidea.theme` / `openidea.onThemeChange` to frame scripts.
- Move `subscribeTheme` / `themeKey` from the Markdown mermaid module to
`src/platform/themeWatch.ts`, shared by both.
- Document the variables in plugins/README.md.
Rework the plugin system per docs/plugin_plan.md (P0–P8):
- Extension-point registry (ide-extension) so new contribution types register
without touching the kernel; languages, run detectors, providers, views and
UI contributions go through it.
- Per-plugin capability consent with a risk-graded ledger; process
capabilities are pinned to resolved binary paths and hashes.
- Async, actor-per-plugin Wasm runtime with lazy activation, cancellation,
events, long-running tasks and idle reclamation.
- Plugin host moved into ide-host, shared by local and remote projects.
- Distribution: install/package tooling (openidea-plugin bin) and a static
market index.
- WIT frozen as openidea:plugin@1.0.0; Rust SDK with mock host.
- Ten official validation plugins under plugins/official.
HTML files in Angular projects were highlighted as plain HTML. Languages can now declare framework UI modes with root markers (angular.json, node_modules/@angular/core); files under such a root get the framework's editor mode, re-detected when a marker appears or disappears, and the root-marker lookup is shared with language server roots. The Angular Template mode (vendored @codemirror/lang-angular, MIT) adds @if/@for/@switch/@defer/@let blocks, key and animation binding names, and colours {{ }} delimiters.
Lazily loaded editor modes are now loaded before a document's first editor opens, so a file never renders as plain text first (this also left Angular templates uncoloured).
Co-authored-by: nntndfrk <2458463+nntndfrk@users.noreply.github.com>
Run oxfmt once over the whole repository (formatting only, no logic changes) and add `pnpm format:check` to the frontend CI job so unformatted code no longer builds up. `.oxfmtrc.json` now skips the generated theme docs, test fixtures and code blocks inside Markdown.
Co-authored-by: jaw52 <53564781+jaw52@users.noreply.github.com>
Adds Solarized Light, Solarized Dark, One Light and One Dark as built-in themes across the workbench, editor, terminal and Mermaid, keeping the original palettes (MIT notices in THIRD_PARTY_LICENSES.md, mapping in docs/themes.md).
- Native window colours are read from tokens.css at build time (`theme_frame.rs`) instead of a second colour table.
- Startup restores the built-in palette before first paint.
- Editor schemes, the terminal and Mermaid refresh on switches between themes of the same kind.
- The plugin packages of the same themes are removed.
- A test requires every built-in palette theme to define each token (only listed ones may inherit from the base theme), so new tokens can't silently miss them.
Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VUYsdXA2nkF5v6zsC93dpn
Solarized Light/Dark and One Light/Dark ship as theme plugins (plugins/theme-solarized, plugins/theme-one) with complete UI tokens, editor schemes and terminal colours, and the original palettes' MIT notices. Installing a plugin now also copies its LICENSE/NOTICE/COPYING.
Theme handling that benefits every plugin theme:
- The last plugin theme is restored before first paint (splash, workbench); the native window background follows the theme.
- HSL / color-mix() / var() colours are resolved to RGB for native windows, the Settings window and Mermaid.
- Mermaid, the terminal and editor schemes follow switches between two themes of the same kind.
- An explicitly chosen editor scheme wins over a plugin theme's editor colours.
Supersedes #85.
Co-authored-by: bghtyu <3931591+bghtyu@users.noreply.github.com>
Claude-Session: https://claude.ai/code/session_01VUYsdXA2nkF5v6zsC93dpn
Per the maintainer's decision for #24, no third-party themes are bundled; instead a theme plugin template and docs let the community port themes (IntelliJ also ships few themes, the rest are plugins).
- templates/theme-plugin: manifest-only plugin with an original example (Harbor Night) covering every UI token and an editor scheme (.icls equivalent).
- docs/plugins/themes.md: format, IntelliJ / VS Code porting tables, generated token reference (pnpm gen:theme-docs); drift test fails when tokens.css and the template/reference disagree.
- pnpm theme:import-intellij: dependency-free converter for IntelliJ .theme.json (+ .icls).
- Plugin host: themes may name an editor-scheme merged over the theme; comments allowed in theme files.
- Fixes: a plugin theme's kind now switches the light/dark base; plugin themes go in their own stylesheet so the Appearance accent and editor scheme still layer on top.
Verified: ide-plugin tests, vitest (44), in-app on macOS: installed the template from disk, applied Harbor Night (dark base + teal accent over Islands Light), back to default restored the light theme.
Claude-Session: https://claude.ai/code/session_01VUYsdXA2nkF5v6zsC93dpn