@xmoon76/dsh-pi-tui 0.3.4 → 0.3.5
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/README.en.md +648 -0
- package/README.md +557 -466
- package/dist/builtins.mjs +1 -13
- package/dist/extension/advanced.d.mts +1 -1
- package/dist/extension/unstable.d.mts +1 -1
- package/dist/extensions.d.mts +9 -6
- package/dist/extensions.mjs +1 -1
- package/dist/index.d.mts +2 -12
- package/dist/index.mjs +2 -2
- package/dist/{public-types-CZz5_arj.d.mts → public-types-_pe9ZH00.d.mts} +74 -8
- package/dist/{src-B1uP5j0d.mjs → src-B93JMbsv.mjs} +13497 -2012
- package/package.json +11 -6
- package/README.zh-CN.md +0 -469
- package/scripts/advanced-plugin-smoke.mjs +0 -314
- package/scripts/bench.mts +0 -302
- package/scripts/client-boundary-baseline.json +0 -82
- package/scripts/client-boundary-gate.mjs +0 -165
- package/scripts/e2e-session-lease.sh +0 -388
- package/scripts/examples-plugin-smoke.mjs +0 -320
- package/scripts/extension-fixture-smoke.mjs +0 -219
- package/scripts/naming-gate.mjs +0 -158
- package/scripts/phase4-plugin-smoke.mjs +0 -318
- package/scripts/pre-push-stages.mjs +0 -116
- package/scripts/preview-prompt.mts +0 -62
- package/scripts/preview-role-styles.mts +0 -97
- package/scripts/tarball-smoke.mjs +0 -393
- package/scripts/unstable-plugin-smoke.mjs +0 -300
- package/scripts/vim-plugin-smoke.mjs +0 -315
- /package/dist/{theme-registry-CjbtRmhd.d.mts → keybinding-registry-CjbtRmhd.d.mts} +0 -0
package/dist/builtins.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { TUI_STARTUP_SERVICE } from "./startup.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { I as dshVersion, V as PI_TUI_EXTENSIONS_SERVICE } from "./src-B93JMbsv.mjs";
|
|
3
3
|
import { readFileSync } from "node:fs";
|
|
4
4
|
import { join } from "node:path";
|
|
5
5
|
//#region src/builtins.ts
|
|
@@ -36,18 +36,6 @@ function apply(ctx) {
|
|
|
36
36
|
text: installedDsh === void 0 ? `tui-v${packageVersion()}` : `dsh-${installedDsh} · tui-v${packageVersion()}`,
|
|
37
37
|
tone: "info"
|
|
38
38
|
});
|
|
39
|
-
const counters = service.register("chrome.footer.status", {
|
|
40
|
-
id: "builtin-turns-steps",
|
|
41
|
-
order: 1e3,
|
|
42
|
-
description: "Completed turns/steps counters (first-party builtin)."
|
|
43
|
-
}, { spans: [] });
|
|
44
|
-
const renderCounters = (state) => {
|
|
45
|
-
const spans = [{ text: `t${state.session.turns}/s${state.session.steps}` }];
|
|
46
|
-
counters.replace({ spans });
|
|
47
|
-
};
|
|
48
|
-
service.subscribeState((state) => {
|
|
49
|
-
renderCounters(state);
|
|
50
|
-
});
|
|
51
39
|
const todoDock = service.register("input.dock.item", {
|
|
52
40
|
id: "builtin-todo-summary",
|
|
53
41
|
order: 1e3,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as PiTuiApiInfo, E as NormalizedKey, _ as ExtensionTier, h as EditorSnapshot, ot as TuiOverlayOptions, v as ExtensionView } from "../public-types-_pe9ZH00.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/extension/advanced-types.d.ts
|
|
4
4
|
/** API level of the advanced tier. Bumped only on advanced breaking changes. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as PiTuiApiInfo, _ as ExtensionTier, ot as TuiOverlayOptions } from "../public-types-_pe9ZH00.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/extension/unstable-types.d.ts
|
|
4
4
|
/** API level of the unstable tier. Bumped only on unstable breaking changes. */
|
package/dist/extensions.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as
|
|
1
|
+
import { $ as TuiKeybindingContribution, A as PiTuiSlotSemantic, B as TextView, C as InputWidget, D as PiTuiApiInfo, E as NormalizedKey, F as SpacerView, G as TuiAutocompleteQuery, H as TuiAction, I as StackView, J as TuiColorPalette, K as TuiAutocompleteRegistryView, L as StyledSpan, M as RegistrationSpec, N as RowsView, O as PiTuiCapability, P as SessionSnapshot, Q as TuiCommandHandle, R as SurfaceSnapshot, S as HeaderBadge, T as MessagePresentationSnapshot, U as TuiAutocompleteItem, V as ToolPresentationSnapshot, W as TuiAutocompleteProvider, X as TuiCommandBridgeView, Y as TuiCommandBridgeSnapshot, Z as TuiCommandContribution, _t as TuiThemeRegistrySnapshot, a as ContributionHealth, at as TuiOverlayHandle, b as FooterSegment, bt as describeKey, c as DockItem, ct as TuiRendererRegistrySnapshot, d as EditorHost, dt as TuiSettingHandle, et as TuiKeybindingHandle, f as EditorHostAction, ft as TuiSettingsRegistrySnapshot, g as ExtensionEditor, gt as TuiThemeHandle, h as EditorSnapshot, ht as TuiThemeContribution, i as AutocompleteProviderContribution, it as TuiMessageRendererContribution, j as RegistrationHandle, k as PiTuiSlotName, l as EditorContribution, lt as TuiRendererRegistryView, m as EditorInputEvent, mt as TuiSizeValue, n as ActivitySnapshot, nt as TuiKeybindingRegistryView, o as ContributionRecord, ot as TuiOverlayOptions, p as EditorHostActionResult, pt as TuiSettingsRegistryView, q as TuiAutocompleteSuggestions, r as AutocompleteHandle, rt as TuiLocalCommandHandler, s as ContributionState, st as TuiRendererHandle, t as API_VERSION, tt as TuiKeybindingRegistrySnapshot, u as EditorHandle, ut as TuiSettingContribution, v as ExtensionView, vt as TuiThemeRegistryView, w as MarkdownView, x as FrameView, y as FooterItemContribution, yt as TuiToolRendererContribution, z as SurfaceStateValues } from "./public-types-_pe9ZH00.mjs";
|
|
2
2
|
import { Context, Service } from "@deepseek-ai/cordis";
|
|
3
3
|
|
|
4
4
|
//#region src/extension/service.d.ts
|
|
@@ -53,10 +53,13 @@ interface PiTuiExtensionService {
|
|
|
53
53
|
*/
|
|
54
54
|
registerSetting(contribution: TuiSettingContribution): TuiSettingHandle;
|
|
55
55
|
/**
|
|
56
|
-
* Register a keybinding (M5
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
56
|
+
* Register a keybinding (M5): normalized key → public semantic action.
|
|
57
|
+
* The registry validates the contribution (public TuiAction whitelist,
|
|
58
|
+
* reserved keys, text-producing keys, editor-owned keys, legacy C0 collisions) and its
|
|
59
|
+
* records feed the LIVE InputRouter lookups + the runner's
|
|
60
|
+
* effective-keymap plugin rules (M6); routing precedence stays
|
|
61
|
+
* Host-owned. Rejections throw loudly; the binding is owned by the
|
|
62
|
+
* calling fiber.
|
|
60
63
|
* @param contribution - the binding contribution.
|
|
61
64
|
*/
|
|
62
65
|
registerKeybinding(contribution: TuiKeybindingContribution): TuiKeybindingHandle;
|
|
@@ -129,4 +132,4 @@ declare const inject: string[];
|
|
|
129
132
|
*/
|
|
130
133
|
declare function apply(ctx: Context): void;
|
|
131
134
|
//#endregion
|
|
132
|
-
export { API_VERSION, type ActivitySnapshot, type AutocompleteHandle, type AutocompleteProviderContribution, type ContributionHealth, type ContributionRecord, type ContributionState, type DockItem, type EditorContribution, type EditorHandle, type EditorHost, type EditorHostAction, type EditorHostActionResult, type EditorInputEvent, type EditorSnapshot, type ExtensionEditor, type ExtensionView, type FooterSegment, type FrameView, type HeaderBadge, type InputWidget, type MarkdownView, type MessagePresentationSnapshot, type NormalizedKey, PI_TUI_EXTENSIONS_SERVICE, type PiTuiApiInfo, type PiTuiCapability, type PiTuiExtensionService, type PiTuiSlotName, type PiTuiSlotSemantic, type RegistrationHandle, type RegistrationSpec, type RowsView, type SessionSnapshot, type SpacerView, type StackView, type StyledSpan, type SurfaceSnapshot, type SurfaceStateValues, type TextView, type ToolPresentationSnapshot, type TuiAction, type TuiAutocompleteItem, type TuiAutocompleteProvider, type TuiAutocompleteQuery, type TuiAutocompleteRegistryView, type TuiAutocompleteSuggestions, type TuiColorPalette, type TuiCommandBridgeSnapshot, type TuiCommandBridgeView, type TuiCommandContribution, type TuiCommandHandle, type TuiKeybindingContribution, type TuiKeybindingHandle, type TuiKeybindingRegistrySnapshot, type TuiKeybindingRegistryView, type TuiLocalCommandHandler, type TuiMessageRendererContribution, type TuiOverlayHandle, type TuiOverlayOptions, type TuiRendererHandle, type TuiRendererRegistrySnapshot, type TuiSettingContribution, type TuiSettingHandle, type TuiSettingsRegistrySnapshot, type TuiSettingsRegistryView, type TuiSizeValue, type TuiThemeContribution, type TuiThemeHandle, type TuiThemeRegistrySnapshot, type TuiThemeRegistryView, type TuiToolRendererContribution, apply, describeKey, inject, name };
|
|
135
|
+
export { API_VERSION, type ActivitySnapshot, type AutocompleteHandle, type AutocompleteProviderContribution, type ContributionHealth, type ContributionRecord, type ContributionState, type DockItem, type EditorContribution, type EditorHandle, type EditorHost, type EditorHostAction, type EditorHostActionResult, type EditorInputEvent, type EditorSnapshot, type ExtensionEditor, type ExtensionView, type FooterItemContribution, type FooterSegment, type FrameView, type HeaderBadge, type InputWidget, type MarkdownView, type MessagePresentationSnapshot, type NormalizedKey, PI_TUI_EXTENSIONS_SERVICE, type PiTuiApiInfo, type PiTuiCapability, type PiTuiExtensionService, type PiTuiSlotName, type PiTuiSlotSemantic, type RegistrationHandle, type RegistrationSpec, type RowsView, type SessionSnapshot, type SpacerView, type StackView, type StyledSpan, type SurfaceSnapshot, type SurfaceStateValues, type TextView, type ToolPresentationSnapshot, type TuiAction, type TuiAutocompleteItem, type TuiAutocompleteProvider, type TuiAutocompleteQuery, type TuiAutocompleteRegistryView, type TuiAutocompleteSuggestions, type TuiColorPalette, type TuiCommandBridgeSnapshot, type TuiCommandBridgeView, type TuiCommandContribution, type TuiCommandHandle, type TuiKeybindingContribution, type TuiKeybindingHandle, type TuiKeybindingRegistrySnapshot, type TuiKeybindingRegistryView, type TuiLocalCommandHandler, type TuiMessageRendererContribution, type TuiOverlayHandle, type TuiOverlayOptions, type TuiRendererHandle, type TuiRendererRegistrySnapshot, type TuiSettingContribution, type TuiSettingHandle, type TuiSettingsRegistrySnapshot, type TuiSettingsRegistryView, type TuiSizeValue, type TuiThemeContribution, type TuiThemeHandle, type TuiThemeRegistrySnapshot, type TuiThemeRegistryView, type TuiToolRendererContribution, apply, describeKey, inject, name };
|
package/dist/extensions.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import "./startup.mjs";
|
|
2
|
-
import { B as
|
|
2
|
+
import { B as name, H as API_VERSION, R as apply, U as describeKey, V as PI_TUI_EXTENSIONS_SERVICE, z as inject } from "./src-B93JMbsv.mjs";
|
|
3
3
|
export { API_VERSION, PI_TUI_EXTENSIONS_SERVICE, apply, describeKey, inject, name };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { H as TuiAction } from "./public-types-_pe9ZH00.mjs";
|
|
2
2
|
import z from "@deepseek-ai/schemastery";
|
|
3
3
|
import { Agent, ModelSelectionRef } from "@deepseek-ai/dsh-agent";
|
|
4
4
|
import { ContentBlock } from "@deepseek-ai/dsh-llm";
|
|
@@ -212,16 +212,6 @@ interface Config {
|
|
|
212
212
|
sessionId?: string;
|
|
213
213
|
}
|
|
214
214
|
declare const Config: z<Config>;
|
|
215
|
-
/**
|
|
216
|
-
* Wire the credential surface refresh to the dsh 0.1.1-rc.1 credential
|
|
217
|
-
* events. The rc.1 release split the credential update event into the
|
|
218
|
-
* reference half and the durable-record half; both change what the footer
|
|
219
|
-
* model row and the welcome card show (a /login /logout, an external
|
|
220
|
-
* .credentials.yaml edit, or an authorization flow committing a record), so
|
|
221
|
-
* they share one best-effort callback. The callback must not read secrets
|
|
222
|
-
* or mutate providers — it only re-reads describe-level state.
|
|
223
|
-
*/
|
|
224
|
-
declare function registerCredentialSurfaceRefresh(ctx: Context, refresh: () => void): void;
|
|
225
215
|
/**
|
|
226
216
|
* Slash commands that need no session: before the first user message
|
|
227
217
|
* (deferred start) they run locally without creating one. Everything else
|
|
@@ -745,4 +735,4 @@ declare function recomposeBlank(ctx: Context, agent: {
|
|
|
745
735
|
*/
|
|
746
736
|
declare function apply(ctx: Context, config: Config): void;
|
|
747
737
|
//#endregion
|
|
748
|
-
export { AgentComposition, CompactionFold, CompactionSettleSurface, Config, HOST_COMMAND_CATALOG, InitialCatalogResolution, InterruptAgentLike, InterruptWriterLike, LOCAL_COMMANDS, PendingSubagentCall, QueueFoldResult, QueueInboxMessage, QueueNoticeSource, RecomposableSession, RecomposeOutcome, ResolveInitialCatalogOptions, SESSIONLESS_COMMANDS, SessionLockRefusedError, ViewerOpenToken, apply, busyAfterTurnBoundary, commandRejectsImages, compactingFromLog, composeAgent, createViewerOpenToken, dangerCommand, foldCompactionEvent, foldQueueRows, forkSeed, inject, interruptAgent, isPlainExitPrompt, isSubagentSettlementNotice, isUserQueueInput, matchPendingSubagentCall, name, normalizeSkillInvocation, recomposeBlank, recordedPreset,
|
|
738
|
+
export { AgentComposition, CompactionFold, CompactionSettleSurface, Config, HOST_COMMAND_CATALOG, InitialCatalogResolution, InterruptAgentLike, InterruptWriterLike, LOCAL_COMMANDS, PendingSubagentCall, QueueFoldResult, QueueInboxMessage, QueueNoticeSource, RecomposableSession, RecomposeOutcome, ResolveInitialCatalogOptions, SESSIONLESS_COMMANDS, SessionLockRefusedError, ViewerOpenToken, apply, busyAfterTurnBoundary, commandRejectsImages, compactingFromLog, composeAgent, createViewerOpenToken, dangerCommand, foldCompactionEvent, foldQueueRows, forkSeed, inject, interruptAgent, isPlainExitPrompt, isSubagentSettlementNotice, isUserQueueInput, matchPendingSubagentCall, name, normalizeSkillInvocation, recomposeBlank, recordedPreset, resolveInitialCatalog, resumeCommand, runningProfile, settleCompactionSurface, shouldConsumeAdvertisedMiss, shouldSteerOnEnter, subagentJobTranscriptId, subagentJobViewHint, subagentNoticeIsFailure, teardownViewerForSessionSwap, viewerActionCapability };
|
package/dist/index.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import "./startup.mjs";
|
|
2
|
-
import { A as
|
|
3
|
-
export { Config, HOST_COMMAND_CATALOG, LOCAL_COMMANDS, SESSIONLESS_COMMANDS, SessionLockRefusedError, apply, busyAfterTurnBoundary, commandRejectsImages, compactingFromLog, composeAgent, createViewerOpenToken, dangerCommand, foldCompactionEvent, foldQueueRows, forkSeed, inject, interruptAgent, isPlainExitPrompt, isSubagentSettlementNotice, isUserQueueInput, matchPendingSubagentCall, name, normalizeSkillInvocation, recomposeBlank, recordedPreset,
|
|
2
|
+
import { A as shouldSteerOnEnter, C as recomposeBlank, D as runningProfile, E as resumeCommand, F as viewerActionCapability, L as forkSeed, M as subagentJobViewHint, N as subagentNoticeIsFailure, O as settleCompactionSurface, P as teardownViewerForSessionSwap, S as normalizeSkillInvocation, T as resolveInitialCatalog, _ as isPlainExitPrompt, a as SessionLockRefusedError, b as matchPendingSubagentCall, c as commandRejectsImages, d as createViewerOpenToken, f as dangerCommand, g as interruptAgent, h as inject, i as SESSIONLESS_COMMANDS, j as subagentJobTranscriptId, k as shouldConsumeAdvertisedMiss, l as compactingFromLog, m as foldQueueRows, n as HOST_COMMAND_CATALOG, o as apply, p as foldCompactionEvent, r as LOCAL_COMMANDS, s as busyAfterTurnBoundary, t as Config, u as composeAgent, v as isSubagentSettlementNotice, w as recordedPreset, x as name, y as isUserQueueInput } from "./src-B93JMbsv.mjs";
|
|
3
|
+
export { Config, HOST_COMMAND_CATALOG, LOCAL_COMMANDS, SESSIONLESS_COMMANDS, SessionLockRefusedError, apply, busyAfterTurnBoundary, commandRejectsImages, compactingFromLog, composeAgent, createViewerOpenToken, dangerCommand, foldCompactionEvent, foldQueueRows, forkSeed, inject, interruptAgent, isPlainExitPrompt, isSubagentSettlementNotice, isUserQueueInput, matchPendingSubagentCall, name, normalizeSkillInvocation, recomposeBlank, recordedPreset, resolveInitialCatalog, resumeCommand, runningProfile, settleCompactionSurface, shouldConsumeAdvertisedMiss, shouldSteerOnEnter, subagentJobTranscriptId, subagentJobViewHint, subagentNoticeIsFailure, teardownViewerForSessionSwap, viewerActionCapability };
|
|
@@ -70,9 +70,9 @@ interface TuiAutocompleteProvider {
|
|
|
70
70
|
/** API version of the extension surface (bumped only on breaking changes). */
|
|
71
71
|
declare const API_VERSION: 1;
|
|
72
72
|
/** Capability identifiers, feature-detected via {@link PiTuiApiInfo}. */
|
|
73
|
-
type PiTuiCapability = 'slot.chrome.header.badge' | 'slot.input.dock.item' | 'slot.chrome.footer.status' | 'slot.input.widget' | 'surface.snapshot' | 'advanced.input.capture' | 'advanced.ui.interactive' | 'advanced.editor.control' | 'unstable.input.raw' | 'unstable.surface.handle';
|
|
73
|
+
type PiTuiCapability = 'slot.chrome.header.badge' | 'slot.input.dock.item' | 'slot.chrome.footer.status' | 'slot.chrome.footer.item' | 'slot.input.widget' | 'surface.snapshot' | 'advanced.input.capture' | 'advanced.ui.interactive' | 'advanced.editor.control' | 'unstable.input.raw' | 'unstable.surface.handle';
|
|
74
74
|
/** Slot identities this bundle knows; unknown names are rejected at registration. */
|
|
75
|
-
type PiTuiSlotName = 'chrome.header.badge' | 'input.dock.item' | 'chrome.footer.status' | 'input.widget.above' | 'input.widget.below';
|
|
75
|
+
type PiTuiSlotName = 'chrome.header.badge' | 'input.dock.item' | 'chrome.footer.status' | 'chrome.footer.item' | 'input.widget.above' | 'input.widget.below';
|
|
76
76
|
/** Slot semantics: how competing contributions resolve. */
|
|
77
77
|
type PiTuiSlotSemantic = 'list' | 'single';
|
|
78
78
|
/** Extension tier metadata shared by every tier entry (plan §4/§5). */
|
|
@@ -132,8 +132,14 @@ interface ContributionRecord<T> {
|
|
|
132
132
|
readonly order: number;
|
|
133
133
|
readonly priority: number;
|
|
134
134
|
readonly description: string | undefined;
|
|
135
|
-
/** The Cordis fiber
|
|
135
|
+
/** The Cordis fiber identity that owns this registration, UID-QUALIFIED
|
|
136
|
+
* (`<uid>:<name>`) — diagnostics, uniqueness and owner-scoped disposal
|
|
137
|
+
* never conflate two anonymous sibling fibers. */
|
|
136
138
|
readonly owner: string;
|
|
139
|
+
/** The HMR-STABLE owner identity for slots whose canonical keys are
|
|
140
|
+
* PERSISTED across reloads (chrome.footer.item). Absent → the key
|
|
141
|
+
* derives from `owner`. */
|
|
142
|
+
readonly stableOwner?: string;
|
|
137
143
|
/** The live contribution value. */
|
|
138
144
|
readonly value: T;
|
|
139
145
|
}
|
|
@@ -216,6 +222,34 @@ interface FooterSegment {
|
|
|
216
222
|
readonly minWidth?: number;
|
|
217
223
|
readonly importance?: number;
|
|
218
224
|
}
|
|
225
|
+
/**
|
|
226
|
+
* M4: one configurable footer item contribution (the `chrome.footer.item`
|
|
227
|
+
* slot). Plain data only — the host compiles and renders; a plugin never
|
|
228
|
+
* touches ANSI, width, layout or the terminal. The item becomes a
|
|
229
|
+
* first-class citizen of the footer configurator: users can show/hide,
|
|
230
|
+
* reorder and zone-place it like any builtin item. Dynamic updates use the
|
|
231
|
+
* standard `handle.replace(...)` / `handle.invalidate()` pattern.
|
|
232
|
+
*/
|
|
233
|
+
interface FooterItemContribution {
|
|
234
|
+
/** The picker label (shown in /footer and /settings). */
|
|
235
|
+
readonly label: string;
|
|
236
|
+
readonly description?: string;
|
|
237
|
+
/** The rendered segment (the LIVE value — replace() swaps it). The
|
|
238
|
+
* segment's OWN `minWidth` is the item's minimum renderable width
|
|
239
|
+
* (never truncated below it) and is the AUTHORITY when both are set. */
|
|
240
|
+
readonly segment: FooterSegment;
|
|
241
|
+
/** Where the item lands by default in a fresh layout. */
|
|
242
|
+
readonly defaultZone?: 'left' | 'right';
|
|
243
|
+
/** Layout weight: lower importance items drop first under pressure. */
|
|
244
|
+
readonly importance?: number;
|
|
245
|
+
/**
|
|
246
|
+
* @deprecated Use `segment.minWidth` — the segment is the single
|
|
247
|
+
* min-width authority and WINS when both are set. This top-level field
|
|
248
|
+
* is kept (and still honored when the segment carries none) so earlier
|
|
249
|
+
* draft code keeps type-checking; new code must set it on the segment.
|
|
250
|
+
*/
|
|
251
|
+
readonly minWidth?: number;
|
|
252
|
+
}
|
|
219
253
|
/** One styled run of text. The host owns ANSI compilation; plugins supply
|
|
220
254
|
* semantic tokens only (no raw escapes, ever). */
|
|
221
255
|
interface StyledSpan {
|
|
@@ -366,7 +400,10 @@ interface TuiCommandBridgeSnapshot {
|
|
|
366
400
|
/** One registered theme contribution (M5). */
|
|
367
401
|
interface TuiThemeContribution {
|
|
368
402
|
readonly id: string;
|
|
369
|
-
/** The
|
|
403
|
+
/** The DISPLAY name (shown in the theme picker). The selection IDENTITY
|
|
404
|
+
* is the source-qualified value `plugin:<owner>/<id>` — a display name
|
|
405
|
+
* is a label only and never round-trips back to an identity (the
|
|
406
|
+
* review's P2). */
|
|
370
407
|
readonly name: string;
|
|
371
408
|
/** The semantic palette (hex colours; the host maps it at apply time). */
|
|
372
409
|
readonly palette: TuiColorPalette;
|
|
@@ -440,10 +477,32 @@ interface TuiCommandBridgeView {
|
|
|
440
477
|
isLocal(name: string, staticLocal: ReadonlySet<string>): boolean;
|
|
441
478
|
snapshot(): TuiCommandBridgeSnapshot;
|
|
442
479
|
}
|
|
443
|
-
/** The read-side of the theme registry (M5).
|
|
480
|
+
/** The read-side of the theme registry (M5). Selections are addressed by
|
|
481
|
+
* SOURCE-QUALIFIED selectable values (`plugin:<owner>/<id>`), never by
|
|
482
|
+
* the bare display name — the picker/apply/persist protocol (the review's
|
|
483
|
+
* P2: a bare name shared the custom-FILE namespace, so a persisted value's
|
|
484
|
+
* meaning depended on which source existed). */
|
|
444
485
|
interface TuiThemeRegistryView {
|
|
486
|
+
/** The display names (diagnostics / /status counts only). */
|
|
445
487
|
names(): string[];
|
|
488
|
+
/** DEPRECATED (still functional for the current API version — removal
|
|
489
|
+
* requires the next breaking API version): the palette behind a bare
|
|
490
|
+
* display NAME. The bare name is ambiguous now that plugin themes and
|
|
491
|
+
* custom files can share one (the source-qualified
|
|
492
|
+
* {@link paletteForSelectable} is the identity-addressed read). Kept as
|
|
493
|
+
* a source-compatibility shim: the concrete registry never dropped it,
|
|
494
|
+
* so removing it from this view would break existing Stable plugins'
|
|
495
|
+
* typecheck without a runtime need (the review's P1/P2). */
|
|
446
496
|
paletteFor(name: string): TuiColorPalette | undefined;
|
|
497
|
+
/** The source-qualified selectable values (the /settings picker's
|
|
498
|
+
* plugin section; sorted). */
|
|
499
|
+
selectableValues(): string[];
|
|
500
|
+
/** The palette for one source-qualified selectable value. */
|
|
501
|
+
paletteForSelectable(value: string): TuiColorPalette | undefined;
|
|
502
|
+
/** The display name behind one source-qualified selectable value. */
|
|
503
|
+
displayNameForSelectable(value: string): string | undefined;
|
|
504
|
+
/** Whether one source-qualified selectable value is live. */
|
|
505
|
+
hasSelectable(value: string): boolean;
|
|
447
506
|
snapshot(): TuiThemeRegistrySnapshot;
|
|
448
507
|
}
|
|
449
508
|
/** The read-side of the settings registry (M5). */
|
|
@@ -483,7 +542,11 @@ interface NormalizedKey {
|
|
|
483
542
|
}
|
|
484
543
|
/** The semantic actions a plugin may bind (plan §2.2 / §11). */
|
|
485
544
|
type TuiAction = 'submit-draft' | 'queue-draft' | 'steer-draft' | 'cancel-activity' | 'open-search' | 'toggle-fullscreen' | 'cycle-permission';
|
|
486
|
-
/** One keybinding contribution (M5
|
|
545
|
+
/** One keybinding contribution (M5): a normalized key + one of the
|
|
546
|
+
* PUBLIC semantic actions. The registry validates and canonicalizes it
|
|
547
|
+
* (action whitelist, reserved keys, text-producing keys, editor-owned keys, legacy C0
|
|
548
|
+
* collisions); the records feed the LIVE InputRouter lookups and the
|
|
549
|
+
* runner's effective-keymap plugin rules (M6). */
|
|
487
550
|
interface TuiKeybindingContribution {
|
|
488
551
|
readonly id: string;
|
|
489
552
|
readonly key: NormalizedKey;
|
|
@@ -569,7 +632,10 @@ interface TuiRendererHandle {
|
|
|
569
632
|
}
|
|
570
633
|
/** The read-side of the renderer registry (M7): the host's message cache
|
|
571
634
|
* asks it to present a message/tool through the plugin chain. The
|
|
572
|
-
* concrete registry is host-internal.
|
|
635
|
+
* concrete registry is host-internal. The ABI is owner-LESS (the Stable
|
|
636
|
+
* v1 contract — an existing plugin's `(id, error)` callback must never
|
|
637
|
+
* receive the host's owner in the error slot); the host's OWNER-scoped
|
|
638
|
+
* health path uses the concrete registry's *Owned variants. */
|
|
573
639
|
interface TuiRendererRegistryView {
|
|
574
640
|
renderMessage(snapshot: MessagePresentationSnapshot, onError: (id: string, error: unknown) => void, canUse?: (id: string, view: ExtensionView) => boolean): {
|
|
575
641
|
view: ExtensionView;
|
|
@@ -740,4 +806,4 @@ interface ExtensionEditor {
|
|
|
740
806
|
dispose(): void;
|
|
741
807
|
}
|
|
742
808
|
//#endregion
|
|
743
|
-
export {
|
|
809
|
+
export { TuiKeybindingContribution as $, PiTuiSlotSemantic as A, TextView as B, InputWidget as C, PiTuiApiInfo as D, NormalizedKey as E, SpacerView as F, TuiAutocompleteQuery as G, TuiAction as H, StackView as I, TuiColorPalette as J, TuiAutocompleteRegistryView as K, StyledSpan as L, RegistrationSpec as M, RowsView as N, PiTuiCapability as O, SessionSnapshot as P, TuiCommandHandle as Q, SurfaceSnapshot as R, HeaderBadge as S, MessagePresentationSnapshot as T, TuiAutocompleteItem as U, ToolPresentationSnapshot as V, TuiAutocompleteProvider as W, TuiCommandBridgeView as X, TuiCommandBridgeSnapshot as Y, TuiCommandContribution as Z, ExtensionTier as _, TuiThemeRegistrySnapshot as _t, ContributionHealth as a, TuiOverlayHandle as at, FooterSegment as b, describeKey as bt, DockItem as c, TuiRendererRegistrySnapshot as ct, EditorHost as d, TuiSettingHandle as dt, TuiKeybindingHandle as et, EditorHostAction as f, TuiSettingsRegistrySnapshot as ft, ExtensionEditor as g, TuiThemeHandle as gt, EditorSnapshot as h, TuiThemeContribution as ht, AutocompleteProviderContribution as i, TuiMessageRendererContribution as it, RegistrationHandle as j, PiTuiSlotName as k, EditorContribution as l, TuiRendererRegistryView as lt, EditorInputEvent as m, TuiSizeValue as mt, ActivitySnapshot as n, TuiKeybindingRegistryView as nt, ContributionRecord as o, TuiOverlayOptions as ot, EditorHostActionResult as p, TuiSettingsRegistryView as pt, TuiAutocompleteSuggestions as q, AutocompleteHandle as r, TuiLocalCommandHandler as rt, ContributionState as s, TuiRendererHandle as st, API_VERSION as t, TuiKeybindingRegistrySnapshot as tt, EditorHandle as u, TuiSettingContribution as ut, ExtensionView as v, TuiThemeRegistryView as vt, MarkdownView as w, FrameView as x, FooterItemContribution as y, TuiToolRendererContribution as yt, SurfaceStateValues as z };
|