Official
ui
The look of the app's components: buttons, list rows, cards, settings, callouts, and the blocks and tables of replies. Edit a component here and the whole app draws with it.
The app opens the listing; nothing installs until an agent in your Plugins workspace has read the files and you enable the plugin. In a terminal: dvg install divergence/ui@0.1.1
Permissions in 0.1.1
Files
components.test.ts818 B
// The kernel compiles in the set this plugin defines
// (crates/kernel/components/divergence.json), so the window draws every
// component before any plugin runs. It is written from here, never by
// hand: `UI_WRITE_STOCK=1 pnpm -C plugins test` rewrites it.
import assert from "node:assert/strict";
import { readFileSync, writeFileSync } from "node:fs";
import test from "node:test";
import { components } from "./components.ts";
const STOCK = new URL("../../crates/kernel/components/divergence.json", import.meta.url);
test("the kernel's stock components are this plugin's", () => {
const written = `${JSON.stringify(components, null, 2)}\n`;
if (process.env.UI_WRITE_STOCK) writeFileSync(STOCK, written);
assert.equal(readFileSync(STOCK, "utf8"), written, "run UI_WRITE_STOCK=1 pnpm -C plugins test");
});
No comments yet.