martty 0.2.17 → 0.2.18-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/acp-host.js +66 -9
- package/lib/ayu.js +22 -0
- package/lib/boot.js +26 -4
- package/lib/catppuccin.js +23 -0
- package/lib/client-run.js +11 -2
- package/lib/cordis-protocol.js +4 -0
- package/lib/creator-overlay.js +3 -3
- package/lib/everforest.js +21 -0
- package/lib/iceberg.js +21 -0
- package/lib/index.js +10 -2
- package/lib/inspect.js +139 -7
- package/lib/kanagawa.js +22 -0
- package/lib/mux.js +2 -0
- package/lib/palettes/ayu.json +44 -0
- package/lib/palettes/catppuccin.json +44 -0
- package/lib/palettes/everforest.json +44 -0
- package/lib/palettes/iceberg.json +44 -0
- package/lib/palettes/kanagawa.json +44 -0
- package/lib/palettes/solarized.json +44 -0
- package/lib/runner.js +2 -2
- package/lib/solarized.js +21 -0
- package/lib/tui-client-plugin-registry.js +3 -3
- package/lib/tui-local-plugins.js +2 -1
- package/lib/tui-plugin-store.js +4 -3
- package/lib/tui-presets.js +129 -13
- package/lib/tui-theme.js +17 -3
- package/package.json +3 -2
- package/skills/tui-plugin-development/SKILL.md +11 -8
- package/vendor/darwin-arm64/dsh-tui +0 -0
- package/vendor/darwin-x64/dsh-tui +0 -0
- package/vendor/linux-arm64/dsh-tui +0 -0
- package/vendor/linux-x64/dsh-tui +0 -0
- package/vendor/win32-x64/dsh-tui.exe +0 -0
package/lib/tui-theme.js
CHANGED
|
@@ -242,7 +242,7 @@ export function installTuiTheme(ctx, options = {}) {
|
|
|
242
242
|
let activationRevision = 0
|
|
243
243
|
|
|
244
244
|
const builtin = validatePalette(defaultPalette)
|
|
245
|
-
palettes.set(builtin.id, { palette: builtin, owner: undefined, loaded: true })
|
|
245
|
+
palettes.set(builtin.id, { palette: builtin, owner: undefined, loaded: true, source: 'static' })
|
|
246
246
|
|
|
247
247
|
function emit(method, params) {
|
|
248
248
|
if (typeof send === 'function') {
|
|
@@ -279,7 +279,14 @@ export function installTuiTheme(ctx, options = {}) {
|
|
|
279
279
|
activeId = id
|
|
280
280
|
activationRevision += 1
|
|
281
281
|
if (notifyPainter) {
|
|
282
|
-
emit(CORDIS_METHODS.themeUpdate, {
|
|
282
|
+
emit(CORDIS_METHODS.themeUpdate, {
|
|
283
|
+
protocol: PROTOCOL,
|
|
284
|
+
palette,
|
|
285
|
+
activate: true,
|
|
286
|
+
loaded: entry.loaded,
|
|
287
|
+
source: entry.source,
|
|
288
|
+
...(entry.owner === undefined ? {} : { owner: { pluginId: entry.owner } }),
|
|
289
|
+
})
|
|
283
290
|
}
|
|
284
291
|
if (previousId !== id) {
|
|
285
292
|
for (const listener of [...listeners]) {
|
|
@@ -336,13 +343,18 @@ export function installTuiTheme(ctx, options = {}) {
|
|
|
336
343
|
const setup = () => {
|
|
337
344
|
const previousId = cover ? activeId : undefined
|
|
338
345
|
let leaseRevision
|
|
339
|
-
|
|
346
|
+
const source = owner === undefined ? 'static' : registerOptions.source ?? 'dynamic'
|
|
347
|
+
if (source !== 'static' && source !== 'dynamic') {
|
|
348
|
+
throw new Error('tuiTheme.register: source must be static or dynamic')
|
|
349
|
+
}
|
|
350
|
+
entry = { palette: validated, owner, loaded: true, source }
|
|
340
351
|
palettes.set(validated.id, entry)
|
|
341
352
|
emit(CORDIS_METHODS.themeUpdate, {
|
|
342
353
|
protocol: PROTOCOL,
|
|
343
354
|
palette: validated,
|
|
344
355
|
activate: false,
|
|
345
356
|
loaded: true,
|
|
357
|
+
source,
|
|
346
358
|
...(owner === undefined ? {} : { owner: { pluginId: owner } }),
|
|
347
359
|
})
|
|
348
360
|
if (cover) {
|
|
@@ -372,6 +384,7 @@ export function installTuiTheme(ctx, options = {}) {
|
|
|
372
384
|
palette: validated,
|
|
373
385
|
activate: false,
|
|
374
386
|
loaded: false,
|
|
387
|
+
source: entry.source,
|
|
375
388
|
owner: { pluginId: owner },
|
|
376
389
|
})
|
|
377
390
|
}
|
|
@@ -400,6 +413,7 @@ export function installTuiTheme(ctx, options = {}) {
|
|
|
400
413
|
palette: next,
|
|
401
414
|
activate: false,
|
|
402
415
|
loaded: true,
|
|
416
|
+
source: entry.source,
|
|
403
417
|
...(owner === undefined ? {} : { owner: { pluginId: owner } }),
|
|
404
418
|
})
|
|
405
419
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "martty",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.18-beta.2",
|
|
4
4
|
"description": "Terminal-native ACP client UI; Cordis client tree, any ACP agent",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
"main": "lib/index.js",
|
|
16
16
|
"scripts": {
|
|
17
17
|
"pretest": "node --test ../scripts/workflow-release.test.mjs ../scripts/package-alias.test.mjs",
|
|
18
|
-
"test": "node --test ../scripts/package-native.test.mjs ../scripts/check-release-tag.test.mjs ../scripts/check-static-elf.test.mjs ../scripts/smoke-old-linux.test.mjs ../scripts/cargo-guard.test.mjs ../scripts/build-npm.test.mjs ../scripts/client-profile.test.mjs ../scripts/plugin-runner.test.mjs ../scripts/profile-link-resolution.test.mjs ../scripts/release.test.mjs ../scripts/jsonrpc-line-transport.test.mjs ../scripts/tui-theme.test.mjs ../scripts/tui-presets.test.mjs ../scripts/tui-plugin-store.test.mjs ../scripts/tui-local-plugins.test.mjs ../scripts/tui-client-plugin-registry.test.mjs ../scripts/tui-slots.test.mjs ../scripts/tui-commands.test.mjs ../scripts/tui-overlay.test.mjs ../scripts/mux.test.mjs ../scripts/acp-client.test.mjs ../scripts/acp-client-events.test.mjs ../scripts/acp-session-config.test.mjs ../scripts/acp-session-plan.test.mjs ../scripts/acp-session-stats.test.mjs ../scripts/acp-session-status.test.mjs ../scripts/plan-view.test.mjs ../scripts/stats-view.test.mjs ../scripts/status-view.test.mjs ../scripts/deepseek-logo.test.mjs ../scripts/runner.test.mjs ../scripts/inspect.test.mjs ../scripts/creator-overlay.test.mjs ../scripts/real-agent-e2e.test.mjs"
|
|
18
|
+
"test": "node --test ../scripts/package-native.test.mjs ../scripts/check-release-tag.test.mjs ../scripts/check-static-elf.test.mjs ../scripts/smoke-old-linux.test.mjs ../scripts/cargo-guard.test.mjs ../scripts/build-npm.test.mjs ../scripts/client-profile.test.mjs ../scripts/plugin-runner.test.mjs ../scripts/profile-link-resolution.test.mjs ../scripts/profile-smoke-tui.test.mjs ../scripts/release.test.mjs ../scripts/jsonrpc-line-transport.test.mjs ../scripts/tui-theme.test.mjs ../scripts/tui-presets.test.mjs ../scripts/tui-plugin-store.test.mjs ../scripts/tui-local-plugins.test.mjs ../scripts/tui-client-plugin-registry.test.mjs ../scripts/tui-slots.test.mjs ../scripts/tui-commands.test.mjs ../scripts/tui-overlay.test.mjs ../scripts/mux.test.mjs ../scripts/acp-client.test.mjs ../scripts/acp-client-events.test.mjs ../scripts/acp-session-config.test.mjs ../scripts/acp-session-plan.test.mjs ../scripts/acp-session-stats.test.mjs ../scripts/acp-session-status.test.mjs ../scripts/plan-view.test.mjs ../scripts/stats-view.test.mjs ../scripts/status-view.test.mjs ../scripts/deepseek-logo.test.mjs ../scripts/runner.test.mjs ../scripts/inspect.test.mjs ../scripts/creator-overlay.test.mjs ../scripts/real-agent-e2e.test.mjs",
|
|
19
|
+
"test:profile-install-matrix": "node --test ../scripts/profile-install-matrix.test.mjs"
|
|
19
20
|
},
|
|
20
21
|
"publishConfig": {
|
|
21
22
|
"access": "public",
|
|
@@ -31,17 +31,19 @@ skill for shared Cordis behavior and for any genuine Host or Web half.
|
|
|
31
31
|
later state updates finish activation. Reply with one short status sentence;
|
|
32
32
|
do not summarize the implementation while approval is pending.
|
|
33
33
|
7. After the later state update confirms activation, persist a new or modified
|
|
34
|
-
UI
|
|
35
|
-
requested a temporary preview. Use
|
|
36
|
-
`packageId
|
|
34
|
+
Client-only UI or Theme Plugin with `tui_plugin_save`, unless the user explicitly
|
|
35
|
+
requested a temporary preview. Use `kind: "ui"` or `kind: "theme"`, the returned
|
|
36
|
+
exact `pluginId` and `packageId`, and a stable `artifactId`; use
|
|
37
37
|
`replace: true` only when updating an artifact already read from disk.
|
|
38
|
+
If `code.host` exists, do not call `tui_plugin_save`: Host-only and dual
|
|
39
|
+
Packages belong to the connected Harness and need its separate shipping path.
|
|
38
40
|
8. Report success only after `tui_plugin_save` returns `saved`, including its
|
|
39
41
|
exact path. Do not call a temporary dynamic Plugin durable. Other dynamic
|
|
40
42
|
TUI Plugins remain process-local unless a separate shipping path was
|
|
41
43
|
explicitly requested.
|
|
42
44
|
|
|
43
45
|
The normal preview trajectory is therefore one list, one query per needed
|
|
44
|
-
Provider, one define, and one run. A durable UI
|
|
46
|
+
Provider, one define, and one run. A durable UI or Theme Plugin adds one
|
|
45
47
|
save after successful activation. Once inspect returns a sufficient live
|
|
46
48
|
contract, author immediately; do not re-prove it from generic Cordis concepts.
|
|
47
49
|
|
|
@@ -73,7 +75,7 @@ Use the narrowest capability:
|
|
|
73
75
|
| Need | Inspect family | Runtime service |
|
|
74
76
|
| --- | --- | --- |
|
|
75
77
|
| Palette registration/activation | `Theme` | `tuiTheme` |
|
|
76
|
-
| Saved
|
|
78
|
+
| Saved UI Plugin composition | `UiPresets` (legacy provider id) | `tuiPresets` (legacy service id) |
|
|
77
79
|
| Persistent terminal content | `Slots` | `tuiSlots` |
|
|
78
80
|
| Local slash command | `Commands` | `tuiCommands` |
|
|
79
81
|
| Transient slider or node view | `Overlay` | `tuiOverlay` |
|
|
@@ -103,12 +105,13 @@ compose only in the Plugin code. The services do not imply one another:
|
|
|
103
105
|
in that one Plugin. Never read/subscribe to active theme or implement a
|
|
104
106
|
theme condition yourself. Immediate preview uses the inspected registration
|
|
105
107
|
option and enters the same Plugin seat.
|
|
106
|
-
- **UI
|
|
108
|
+
- **UI Plugins:** use the current `tuiPresets.register({ id, label }, mount)`
|
|
109
|
+
compatibility service when the user
|
|
107
110
|
wants one saved `/ui` choice to mount several UI contributions together.
|
|
108
|
-
The synchronous mount callback returns one disposer. A UI
|
|
111
|
+
The synchronous mount callback returns one disposer. A UI Plugin owns
|
|
109
112
|
structural UI contributions such as slots, chrome, or a pet. It does not
|
|
110
113
|
register, select, clone, or generate a Theme: `/ui`, `/theme`, and dark/light
|
|
111
|
-
are independent state dimensions. A
|
|
114
|
+
are independent state dimensions. A UI Plugin may document a recommended
|
|
112
115
|
Theme, but recommendation is not runtime ownership.
|
|
113
116
|
- **Commands:** register a local slash command. Registration publishes slash
|
|
114
117
|
completion and keeps invocation out of the ACP prompt. Its availability is
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/vendor/linux-x64/dsh-tui
CHANGED
|
Binary file
|
|
Binary file
|