@deepseek-harness-tui/dsh-tui 0.18.0 → 0.20.0
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.md +90 -59
- package/bin/dsh-tui.js +46 -3
- package/cordis.patch.yml +5 -3
- package/cordis.yml +3 -2
- package/guide/dsh-tui-guide/codex-backend.en.md +2 -2
- package/guide/dsh-tui-guide/codex-backend.md +2 -2
- package/guide/dsh-tui-guide/configuration.en.md +7 -2
- package/guide/dsh-tui-guide/configuration.md +7 -2
- package/guide/dsh-tui-guide/getting-started.en.md +168 -4
- package/guide/dsh-tui-guide/getting-started.md +121 -14
- package/guide/dsh-tui-guide/interaction.en.md +11 -10
- package/guide/dsh-tui-guide/interaction.md +5 -4
- package/guide/dsh-tui-guide/user-guide.en.md +12 -6
- package/guide/dsh-tui-guide/user-guide.md +12 -6
- package/lib/settings.json +24 -8
- package/lib/types/adapter/ports/channel-ui.d.ts +10 -7
- package/lib/types/adapter/ports/channel-ui.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-view.d.ts +67 -8
- package/lib/types/adapter/ports/channel-view.d.ts.map +1 -1
- package/lib/types/agent/events.d.ts +14 -5
- package/lib/types/agent/events.d.ts.map +1 -1
- package/lib/types/agent/session.d.ts +5 -0
- package/lib/types/agent/session.d.ts.map +1 -1
- package/lib/types/backends/claude/tools.d.ts.map +1 -1
- package/lib/types/backends/claude/tools.js +8 -3
- package/lib/types/backends/claude/translate/core.d.ts +2 -2
- package/lib/types/backends/claude/translate/core.d.ts.map +1 -1
- package/lib/types/backends/claude/translate/core.js +10 -6
- package/lib/types/backends/codex/session/commands.d.ts +2 -0
- package/lib/types/backends/codex/session/commands.d.ts.map +1 -1
- package/lib/types/backends/codex/session/commands.js +8 -4
- package/lib/types/backends/codex/session/input.d.ts +11 -7
- package/lib/types/backends/codex/session/input.d.ts.map +1 -1
- package/lib/types/backends/codex/session/input.js +68 -15
- package/lib/types/backends/codex/session/session.d.ts.map +1 -1
- package/lib/types/backends/codex/session/session.js +2 -3
- package/lib/types/backends/codex/translate/presentation.d.ts.map +1 -1
- package/lib/types/backends/codex/translate/presentation.js +5 -2
- package/lib/types/channel/interaction.d.ts.map +1 -1
- package/lib/types/channel/interaction.js +1 -0
- package/lib/types/channel/permissions.d.ts +15 -0
- package/lib/types/channel/permissions.d.ts.map +1 -1
- package/lib/types/channel/permissions.js +28 -0
- package/lib/types/channel/projection.d.ts.map +1 -1
- package/lib/types/channel/projection.js +89 -11
- package/lib/types/channel/questions.d.ts +45 -3
- package/lib/types/channel/questions.d.ts.map +1 -1
- package/lib/types/channel/questions.js +43 -0
- package/lib/types/channel/sanitize.d.ts.map +1 -1
- package/lib/types/channel/sanitize.js +8 -4
- package/lib/types/channel/subagent-failure.d.ts +49 -0
- package/lib/types/channel/subagent-failure.d.ts.map +1 -0
- package/lib/types/channel/subagent-failure.js +59 -0
- package/lib/types/channel/transcript.d.ts +17 -0
- package/lib/types/channel/transcript.d.ts.map +1 -1
- package/lib/types/channel/transcript.js +35 -0
- package/lib/types/commands.js +2 -2
- package/lib/types/components/MessageList.d.ts.map +1 -1
- package/lib/types/components/MessageList.js +14 -10
- package/lib/types/components/PromptInput.d.ts.map +1 -1
- package/lib/types/components/PromptInput.js +61 -6
- package/lib/types/components/SplitDiffView.d.ts.map +1 -1
- package/lib/types/components/SplitDiffView.js +3 -2
- package/lib/types/components/StarPrompt.d.ts +5 -3
- package/lib/types/components/StarPrompt.d.ts.map +1 -1
- package/lib/types/components/StarPrompt.js +56 -6
- package/lib/types/components/SubagentCard.d.ts.map +1 -1
- package/lib/types/components/SubagentCard.js +1 -1
- package/lib/types/components/SubagentDashboard.d.ts.map +1 -1
- package/lib/types/components/SubagentDashboard.js +9 -2
- package/lib/types/components/SubagentDetailScene.d.ts.map +1 -1
- package/lib/types/components/SubagentDetailScene.js +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts.map +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.js +126 -25
- package/lib/types/components/questions/AskUserQuestionPanel.d.ts +5 -8
- package/lib/types/components/questions/AskUserQuestionPanel.d.ts.map +1 -1
- package/lib/types/components/questions/AskUserQuestionPanel.js +7 -4
- package/lib/types/components/questions/PlanReviewPanel.d.ts +3 -6
- package/lib/types/components/questions/PlanReviewPanel.d.ts.map +1 -1
- package/lib/types/components/revealScope.d.ts +15 -0
- package/lib/types/components/revealScope.d.ts.map +1 -0
- package/lib/types/components/revealScope.js +17 -0
- package/lib/types/components/sidePanel/btw/BtwComposer.d.ts +34 -1
- package/lib/types/components/sidePanel/btw/BtwComposer.d.ts.map +1 -1
- package/lib/types/components/sidePanel/btw/BtwComposer.js +108 -7
- package/lib/types/components/sidePanel/btw/BtwPanelAdapter.d.ts.map +1 -1
- package/lib/types/components/sidePanel/btw/BtwPanelAdapter.js +1 -1
- package/lib/types/components/sidePanel/btw/BtwThreadScene.d.ts.map +1 -1
- package/lib/types/components/sidePanel/btw/BtwThreadScene.js +1 -1
- package/lib/types/components/smoothReveal.d.ts +36 -6
- package/lib/types/components/smoothReveal.d.ts.map +1 -1
- package/lib/types/components/smoothReveal.js +92 -21
- package/lib/types/components/teamRoster.d.ts +6 -3
- package/lib/types/components/teamRoster.d.ts.map +1 -1
- package/lib/types/components/workspaces/HomeWorkspaceRow.d.ts +4 -14
- package/lib/types/components/workspaces/HomeWorkspaceRow.d.ts.map +1 -1
- package/lib/types/components/workspaces/HomeWorkspaceRow.js +26 -17
- package/lib/types/dsh-adapter/approvals.d.ts +19 -0
- package/lib/types/dsh-adapter/approvals.d.ts.map +1 -1
- package/lib/types/dsh-adapter/approvals.js +17 -1
- package/lib/types/dsh-adapter/backend/session.d.ts.map +1 -1
- package/lib/types/dsh-adapter/backend/session.js +12 -0
- package/lib/types/dsh-adapter/backend/translate.d.ts.map +1 -1
- package/lib/types/dsh-adapter/backend/translate.js +21 -4
- package/lib/types/dsh-adapter/channel/attached-context.d.ts +15 -2
- package/lib/types/dsh-adapter/channel/attached-context.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/attached-context.js +26 -3
- package/lib/types/dsh-adapter/channel/binding-events.d.ts +3 -0
- package/lib/types/dsh-adapter/channel/binding-events.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/binding-events.js +43 -2
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts +2 -6
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/context-bookkeeping.js +7 -1
- package/lib/types/dsh-adapter/channel/core/compose.d.ts +2 -6
- package/lib/types/dsh-adapter/channel/core/compose.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/core/compose.js +1 -1
- package/lib/types/dsh-adapter/channel/core/local-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/core/local-actions.js +3 -26
- package/lib/types/dsh-adapter/channel/emitter.js +1 -1
- package/lib/types/dsh-adapter/channel/extensions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/extensions.js +15 -4
- package/lib/types/dsh-adapter/channel/input-actions.d.ts +2 -2
- package/lib/types/dsh-adapter/channel/input-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/input-actions.js +34 -10
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts +3 -7
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/input-delivery.js +14 -5
- package/lib/types/dsh-adapter/channel/local-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/local-actions.js +7 -3
- package/lib/types/dsh-adapter/channel/model-actions.d.ts +4 -1
- package/lib/types/dsh-adapter/channel/model-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/model-actions.js +26 -9
- package/lib/types/dsh-adapter/channel/model-selection.d.ts +27 -2
- package/lib/types/dsh-adapter/channel/model-selection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/model-selection.js +81 -37
- package/lib/types/dsh-adapter/channel/model-switch.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/model-switch.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/projection-helpers.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/projection-helpers.js +4 -2
- package/lib/types/dsh-adapter/channel/session-rewind.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-rewind.js +6 -2
- package/lib/types/dsh-adapter/channel/session-tree-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-tree-actions.js +8 -4
- package/lib/types/dsh-adapter/channel/settings-host.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/settings-host.js +185 -36
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts +55 -4
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/subagent-projection.js +80 -16
- package/lib/types/dsh-adapter/channel/subagent-transcript.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/subagent-transcript.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/subagent-transcript.js +6 -5
- package/lib/types/dsh-adapter/channel/task-completion.js +2 -10
- package/lib/types/dsh-adapter/channel/transcript.d.ts +3 -2
- package/lib/types/dsh-adapter/channel/transcript.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/transcript.js +13 -4
- package/lib/types/dsh-adapter/channel/types.d.ts +11 -2
- package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/compat/compaction-previews.d.ts +11 -0
- package/lib/types/dsh-adapter/compat/compaction-previews.d.ts.map +1 -0
- package/lib/types/dsh-adapter/compat/compaction-previews.js +38 -0
- package/lib/types/dsh-adapter/compat/messages.d.ts +1 -1
- package/lib/types/dsh-adapter/compat/messages.d.ts.map +1 -1
- package/lib/types/dsh-adapter/compat/messages.js +2 -2
- package/lib/types/dsh-adapter/contract.d.ts +29 -3
- package/lib/types/dsh-adapter/contract.d.ts.map +1 -1
- package/lib/types/dsh-adapter/contract.js +48 -5
- package/lib/types/dsh-adapter/experimental-bundles.d.ts +5 -0
- package/lib/types/dsh-adapter/experimental-bundles.d.ts.map +1 -1
- package/lib/types/dsh-adapter/experimental-bundles.js +0 -2
- package/lib/types/dsh-adapter/fresh-agent.d.ts +1 -1
- package/lib/types/dsh-adapter/fresh-agent.d.ts.map +1 -1
- package/lib/types/dsh-adapter/fresh-agent.js +60 -11
- package/lib/types/dsh-adapter/host-access.d.ts.map +1 -1
- package/lib/types/dsh-adapter/host-access.js +60 -11
- package/lib/types/dsh-adapter/host-contract.d.ts +1 -1
- package/lib/types/dsh-adapter/host-contract.d.ts.map +1 -1
- package/lib/types/dsh-adapter/host-contract.js +5 -3
- package/lib/types/dsh-adapter/host-dsh.d.ts +2 -8
- package/lib/types/dsh-adapter/host-dsh.d.ts.map +1 -1
- package/lib/types/dsh-adapter/host-dsh.js +30 -6
- package/lib/types/dsh-adapter/host-entry.js +4 -0
- package/lib/types/dsh-adapter/index.d.ts +9 -1
- package/lib/types/dsh-adapter/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/index.js +5 -0
- package/lib/types/dsh-adapter/oauth/account-notifications.d.ts +73 -0
- package/lib/types/dsh-adapter/oauth/account-notifications.d.ts.map +1 -0
- package/lib/types/dsh-adapter/oauth/account-notifications.js +250 -0
- package/lib/types/dsh-adapter/oauth/bonus.d.ts +34 -9
- package/lib/types/dsh-adapter/oauth/bonus.d.ts.map +1 -1
- package/lib/types/dsh-adapter/oauth/bonus.js +47 -5
- package/lib/types/dsh-adapter/oauth/deepseek.d.ts +7 -2
- package/lib/types/dsh-adapter/oauth/deepseek.d.ts.map +1 -1
- package/lib/types/dsh-adapter/oauth/deepseek.js +6 -1
- package/lib/types/dsh-adapter/oauth/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/oauth/index.js +44 -0
- package/lib/types/dsh-adapter/oauth/profiles.d.ts.map +1 -1
- package/lib/types/dsh-adapter/oauth/profiles.js +14 -1
- package/lib/types/dsh-adapter/oauth/service.d.ts.map +1 -1
- package/lib/types/dsh-adapter/oauth/service.js +5 -6
- package/lib/types/dsh-adapter/plugin-manage.d.ts +6 -4
- package/lib/types/dsh-adapter/plugin-manage.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin-manage.js +3 -2
- package/lib/types/dsh-adapter/plugin.d.ts +237 -6
- package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin.js +751 -67
- package/lib/types/dsh-adapter/presets.d.ts +38 -11
- package/lib/types/dsh-adapter/presets.d.ts.map +1 -1
- package/lib/types/dsh-adapter/presets.js +46 -17
- package/lib/types/dsh-adapter/process-exit.d.ts +1 -1
- package/lib/types/dsh-adapter/process-exit.js +1 -1
- package/lib/types/dsh-adapter/questions.d.ts +3 -4
- package/lib/types/dsh-adapter/questions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/questions.js +1 -1
- package/lib/types/dsh-adapter/session-list-metadata.js +2 -2
- package/lib/types/dsh-adapter/session-projection-store.d.ts +1 -1
- package/lib/types/dsh-adapter/session-projection-store.d.ts.map +1 -1
- package/lib/types/dsh-adapter/session-projection-store.js +30 -23
- package/lib/types/dsh-adapter/sessionTree.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessionTree.js +4 -1
- package/lib/types/dsh-adapter/subagents.d.ts +6 -0
- package/lib/types/dsh-adapter/subagents.d.ts.map +1 -1
- package/lib/types/dsh-adapter/subagents.js +32 -3
- package/lib/types/dsh-adapter/team-mode.d.ts +46 -27
- package/lib/types/dsh-adapter/team-mode.d.ts.map +1 -1
- package/lib/types/dsh-adapter/team-mode.js +157 -29
- package/lib/types/dsh-adapter/team-roster.d.ts +53 -18
- package/lib/types/dsh-adapter/team-roster.d.ts.map +1 -1
- package/lib/types/dsh-adapter/team-roster.js +206 -39
- package/lib/types/dsh-adapter/team-tools.d.ts +25 -12
- package/lib/types/dsh-adapter/team-tools.d.ts.map +1 -1
- package/lib/types/dsh-adapter/team-tools.js +81 -26
- package/lib/types/dsh-adapter/tool-scope.d.ts +24 -0
- package/lib/types/dsh-adapter/tool-scope.d.ts.map +1 -0
- package/lib/types/dsh-adapter/tool-scope.js +127 -0
- package/lib/types/dsh-adapter/types.d.ts +2 -1
- package/lib/types/dsh-adapter/types.d.ts.map +1 -1
- package/lib/types/heldInputs.d.ts +55 -16
- package/lib/types/heldInputs.d.ts.map +1 -1
- package/lib/types/heldInputs.js +277 -41
- package/lib/types/i18n.d.ts +292 -20
- package/lib/types/i18n.d.ts.map +1 -1
- package/lib/types/i18n.js +89 -13
- package/lib/types/ink/components/App.d.ts +2 -0
- package/lib/types/ink/components/App.d.ts.map +1 -1
- package/lib/types/ink/components/App.js +8 -0
- package/lib/types/ink/dom.d.ts.map +1 -1
- package/lib/types/ink/dom.js +13 -3
- package/lib/types/ink/events/input-event.d.ts.map +1 -1
- package/lib/types/ink/events/input-event.js +7 -6
- package/lib/types/ink/flush-tick.d.ts +6 -0
- package/lib/types/ink/flush-tick.d.ts.map +1 -1
- package/lib/types/ink/flush-tick.js +31 -0
- package/lib/types/ink/hit-test.d.ts +2 -0
- package/lib/types/ink/hit-test.d.ts.map +1 -1
- package/lib/types/ink/hit-test.js +10 -0
- package/lib/types/ink/hooks/use-program-status.d.ts +1 -1
- package/lib/types/ink/hooks/use-program-status.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-program-status.js +3 -2
- package/lib/types/ink/hooks/use-terminal-title.d.ts +15 -0
- package/lib/types/ink/hooks/use-terminal-title.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-terminal-title.js +23 -3
- package/lib/types/ink/ink.d.ts +1 -0
- package/lib/types/ink/ink.d.ts.map +1 -1
- package/lib/types/ink/ink.js +7 -4
- package/lib/types/ink/jumpback-state.d.ts +33 -0
- package/lib/types/ink/jumpback-state.d.ts.map +1 -0
- package/lib/types/ink/jumpback-state.js +51 -0
- package/lib/types/ink/jumpback.d.ts +78 -0
- package/lib/types/ink/jumpback.d.ts.map +1 -0
- package/lib/types/ink/jumpback.js +515 -0
- package/lib/types/ink/log-update.js +37 -14
- package/lib/types/ink/notify-helper/activate.cs +836 -0
- package/lib/types/ink/notify-helper/compile.d.ts +30 -0
- package/lib/types/ink/notify-helper/compile.d.ts.map +1 -0
- package/lib/types/ink/notify-helper/compile.js +235 -0
- package/lib/types/ink/parse-keypress.d.ts.map +1 -1
- package/lib/types/ink/parse-keypress.js +25 -0
- package/lib/types/ink/terminal-notification-windows.d.ts +8 -4
- package/lib/types/ink/terminal-notification-windows.d.ts.map +1 -1
- package/lib/types/ink/terminal-notification-windows.js +14 -21
- package/lib/types/ink/terminal-notification.d.ts +31 -2
- package/lib/types/ink/terminal-notification.d.ts.map +1 -1
- package/lib/types/ink/terminal-notification.js +51 -0
- package/lib/types/ink/terminal.d.ts +15 -3
- package/lib/types/ink/terminal.d.ts.map +1 -1
- package/lib/types/ink/terminal.js +38 -9
- package/lib/types/screens/AgentTranscriptScene.d.ts.map +1 -1
- package/lib/types/screens/AgentTranscriptScene.js +1 -1
- package/lib/types/screens/Chat.d.ts +4 -3
- package/lib/types/screens/Chat.d.ts.map +1 -1
- package/lib/types/screens/Chat.js +81 -11
- package/lib/types/screens/SessionSupervisor.d.ts +3 -6
- package/lib/types/screens/SessionSupervisor.d.ts.map +1 -1
- package/lib/types/screens/SessionSupervisor.js +5 -8
- package/lib/types/screens/sessionSupervisor/ForeignSessionPanes.d.ts +1 -2
- package/lib/types/screens/sessionSupervisor/ForeignSessionPanes.d.ts.map +1 -1
- package/lib/types/screens/sessionSupervisor/ForeignSessionPanes.js +2 -2
- package/lib/types/screens/sessionSupervisor/model.d.ts +1 -1
- package/lib/types/screens/sessionSupervisor/model.js +1 -1
- package/lib/types/sessionMounts.d.ts +12 -5
- package/lib/types/sessionMounts.d.ts.map +1 -1
- package/lib/types/sessionMounts.js +33 -6
- package/lib/types/settings/definitions.d.ts +12 -0
- package/lib/types/settings/definitions.d.ts.map +1 -1
- package/lib/types/settings/definitions.js +15 -7
- package/lib/types/update.d.ts +412 -20
- package/lib/types/update.d.ts.map +1 -1
- package/lib/types/update.js +2094 -193
- package/lib/types/updateHost.d.ts +198 -0
- package/lib/types/updateHost.d.ts.map +1 -0
- package/lib/types/updateHost.js +608 -0
- package/lib/types/utils/processName.d.ts +16 -0
- package/lib/types/utils/processName.d.ts.map +1 -0
- package/lib/types/utils/processName.js +27 -0
- package/package.json +114 -111
- package/presets/liangshen/agent.cordis.yml +4 -0
- package/tui-profile/feed/README.md +1 -1
- package/tui-profile/feed/first-party.json +1 -1
|
@@ -48,6 +48,27 @@ export function appendAttachedContextBlocks(blocks, contexts) {
|
|
|
48
48
|
}
|
|
49
49
|
return contexts.length;
|
|
50
50
|
}
|
|
51
|
+
/** NUL cannot appear in either part, so the join is unambiguous. */
|
|
52
|
+
const keyOf = (sourceId, title) => `${sourceId}\u0000${title}`;
|
|
53
|
+
/**
|
|
54
|
+
* Snapshot-first merge: a dock re-send keeps the contexts its row saved and
|
|
55
|
+
* still carries anything staged while the row sat in the dock. The live chips
|
|
56
|
+
* were already taken by `captureOrigin()`, so dropping them here would lose
|
|
57
|
+
* them for good. A duplicate key is the same panel staged again: the newer
|
|
58
|
+
* staged snapshot replaces the saved one (the user just edited it).
|
|
59
|
+
*/
|
|
60
|
+
export function mergeAttachedContexts(saved, staged) {
|
|
61
|
+
if (staged.length === 0)
|
|
62
|
+
return saved;
|
|
63
|
+
// A duplicate key is the same panel staged again: the newer snapshot wins,
|
|
64
|
+
// or the model gets the text the user just replaced. `saved` keeps its
|
|
65
|
+
// order; only its stale copies are swapped out.
|
|
66
|
+
const byKey = new Map(staged.map(context => [keyOf(context.sourceId, context.title), context]));
|
|
67
|
+
const merged = saved.map(context => byKey.get(keyOf(context.sourceId, context.title)) ?? context);
|
|
68
|
+
const savedKeys = new Set(saved.map(context => keyOf(context.sourceId, context.title)));
|
|
69
|
+
const extra = staged.filter(context => !savedKeys.has(keyOf(context.sourceId, context.title)));
|
|
70
|
+
return extra.length === 0 && merged.every((context, index) => context === saved[index]) ? saved : [...merged, ...extra];
|
|
71
|
+
}
|
|
51
72
|
/**
|
|
52
73
|
* Registry behind `ChannelUi.attachedContexts` / `attachContext` /
|
|
53
74
|
* `detachContext`. It owns no state of its own: every entry lives in the
|
|
@@ -62,11 +83,13 @@ export function appendAttachedContextBlocks(blocks, contexts) {
|
|
|
62
83
|
*/
|
|
63
84
|
export function createAttachedContextRegistry(holder, emit) {
|
|
64
85
|
let sequence = 0;
|
|
65
|
-
/** NUL cannot appear in either part, so the join is unambiguous. */
|
|
66
|
-
const keyOf = (sourceId, title) => `${sourceId}\u0000${title}`;
|
|
67
86
|
return {
|
|
68
87
|
attach(input) {
|
|
69
|
-
|
|
88
|
+
// A snapshot that is already capped knows whether it was cut; re-deriving
|
|
89
|
+
// the flag from its body would read a cut body as a full one.
|
|
90
|
+
const capped = input.truncated === true
|
|
91
|
+
? { content: input.content.slice(0, MENTION_MAX_FILE_CHARS), truncated: true }
|
|
92
|
+
: capContent(input.content);
|
|
70
93
|
const list = holder().attachedContexts;
|
|
71
94
|
const key = keyOf(input.sourceId, input.title);
|
|
72
95
|
const index = list.findIndex(item => keyOf(item.sourceId, item.title) === key);
|
|
@@ -33,10 +33,13 @@ export declare function createBindingEvents(ctx: Context, deps: {
|
|
|
33
33
|
* request reports usage. */
|
|
34
34
|
seedContextOccupancy?(session: unknown): void;
|
|
35
35
|
seedTeam?(session: unknown): void;
|
|
36
|
+
/** Re-apply per-agent registry state (the preset's tool carve-out). */
|
|
37
|
+
onBind?(agent: Agent): void;
|
|
36
38
|
inputConvergence: InputConvergence;
|
|
37
39
|
modelSelection: ReturnType<typeof createModelSelection>;
|
|
38
40
|
modelActions: {
|
|
39
41
|
applyPreferredEffort(preserveSessionEffort?: boolean): Promise<void>;
|
|
42
|
+
dropModelNodeCache?(): void;
|
|
40
43
|
};
|
|
41
44
|
modeActions: {
|
|
42
45
|
refreshMode(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"binding-events.d.ts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AAO,CAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CAAA;KAAE,CAAA;IACrE;;;uCAGmC;IACnC,iBAAiB,CAAC,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAAA;IACtD;;;sCAGkC;IAClC,gBAAgB,CAAC,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1C;;+DAE2D;IAC3D,wBAAwB,CAAC,IAAI,IAAI,CAAA;CAClC;;;;wBAsEmB,IAAI;+CAImB,YAAY,GAAG,IAAI;;EA6G7D;AAED,OAAO,EAAE,wBAAwB,EAAE,MAAM,wBAAwB,CAAA"}
|
|
@@ -98,10 +98,11 @@ export function createBindingEvents(ctx, deps) {
|
|
|
98
98
|
installSubagents();
|
|
99
99
|
},
|
|
100
100
|
onBind({ capture, current, register }) {
|
|
101
|
+
deps.onBind?.(deps.binding.agent);
|
|
101
102
|
deps.seedActivity?.(deps.binding.agent.session);
|
|
102
103
|
deps.seedContextOccupancy?.(deps.binding.agent.session);
|
|
103
104
|
deps.seedTeam?.(deps.binding.agent.session);
|
|
104
|
-
deps.modelSelection.bind(deps.binding.agent, { provider: deps.state.provider, model: deps.state.model });
|
|
105
|
+
const durableSelection = deps.modelSelection.bind(deps.binding.agent, { provider: deps.state.provider, model: deps.state.model });
|
|
105
106
|
const selected = deps.modelSelection.selection.current;
|
|
106
107
|
// A parked turn may not have logged its first selected request yet.
|
|
107
108
|
if (selected !== undefined) {
|
|
@@ -111,7 +112,7 @@ export function createBindingEvents(ctx, deps) {
|
|
|
111
112
|
const recorded = deps.binding.agent.session.requestHeader?.()?.config;
|
|
112
113
|
// Reattachment keeps a live pin; an adopted header also owns the
|
|
113
114
|
// absence of a pin. A child on a different route still seeds normally.
|
|
114
|
-
const preserveSessionEffort = selected?.reasoningEffort !== undefined ||
|
|
115
|
+
const preserveSessionEffort = durableSelection || selected?.reasoningEffort !== undefined ||
|
|
115
116
|
(recorded?.provider === deps.state.provider && recorded?.model === deps.state.model);
|
|
116
117
|
if (preserveSessionEffort)
|
|
117
118
|
deps.state.reasoningEffort = selected === undefined ? recorded?.reasoningEffort : selected.reasoningEffort;
|
|
@@ -140,6 +141,46 @@ export function createBindingEvents(ctx, deps) {
|
|
|
140
141
|
deps.messageObserver?.publish(native.agent.session, event);
|
|
141
142
|
deps.modeActions.onSessionEvent(native.agent.session, event);
|
|
142
143
|
deps.jobs?.onSessionEvent(event);
|
|
144
|
+
if (event.type === 'model/selection') {
|
|
145
|
+
// The API/Web/plugin may select on this same live Agent. The seam is
|
|
146
|
+
// authoritative; an effort-only action must never resurrect UI cache.
|
|
147
|
+
const selected = deps.modelSelection.selection.current;
|
|
148
|
+
if (selected !== undefined) {
|
|
149
|
+
const routeChanged = selected.provider !== deps.state.provider || selected.model !== deps.state.model;
|
|
150
|
+
deps.state.provider = selected.provider;
|
|
151
|
+
deps.state.model = selected.model;
|
|
152
|
+
deps.state.reasoningEffort = selected.reasoningEffort;
|
|
153
|
+
if (routeChanged) {
|
|
154
|
+
deps.state.contextWindow = undefined;
|
|
155
|
+
deps.state.effortLevels = undefined;
|
|
156
|
+
deps.modelActions.dropModelNodeCache?.();
|
|
157
|
+
void deps.modelActions.applyPreferredEffort(true);
|
|
158
|
+
deps.seedUpstreamRetry?.(selected.provider);
|
|
159
|
+
}
|
|
160
|
+
deps.state.emit();
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
if (event.type === 'request/header' && typeof native.agent.model?.current === 'function') {
|
|
164
|
+
// The projector paints the completed request's effort below. That
|
|
165
|
+
// request may have fixed A/high before a pending B/low was selected.
|
|
166
|
+
// Reconcile after projection, keeping adapter-default readouts only
|
|
167
|
+
// when that header still describes the next selected route.
|
|
168
|
+
queueMicrotask(() => {
|
|
169
|
+
if (!current())
|
|
170
|
+
return;
|
|
171
|
+
const selected = deps.modelSelection.selection.current;
|
|
172
|
+
if (selected === undefined)
|
|
173
|
+
return;
|
|
174
|
+
const header = native.agent.session.requestHeader();
|
|
175
|
+
const adapterDefault = header?.adapterDefaults?.reasoningEffort === true;
|
|
176
|
+
const effort = selected.reasoningEffort ?? (adapterDefault && header?.config.provider === selected.provider && header.config.model === selected.model
|
|
177
|
+
? header.config.reasoningEffort : undefined);
|
|
178
|
+
if (deps.state.reasoningEffort !== effort) {
|
|
179
|
+
deps.state.reasoningEffort = effort;
|
|
180
|
+
deps.state.emit();
|
|
181
|
+
}
|
|
182
|
+
});
|
|
183
|
+
}
|
|
143
184
|
if (event.type === 'working-directory/change') {
|
|
144
185
|
// The projector folds this event later in the same dispatch; only a
|
|
145
186
|
// move to a different directory refreshes.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ContextOccupancy } from '../../adapter/ports/channel-view.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { PendingMessage, PendingTrackInput } from './types.js';
|
|
3
3
|
/** Small mutable cells for Channel-local warning and pending-message state. */
|
|
4
4
|
export declare function createContextBookkeeping(state: () => {
|
|
5
5
|
/** The channel's single occupancy reading (projection first, sample
|
|
@@ -16,11 +16,7 @@ export declare function createContextBookkeeping(state: () => {
|
|
|
16
16
|
};
|
|
17
17
|
resetContextWarning: () => void;
|
|
18
18
|
checkContextWarning: () => void;
|
|
19
|
-
trackPending: (message:
|
|
20
|
-
id: string;
|
|
21
|
-
text: string;
|
|
22
|
-
images?: readonly ComposerImageRef[];
|
|
23
|
-
}, placement: PendingMessage["placement"]) => void;
|
|
19
|
+
trackPending: (message: PendingTrackInput, placement: PendingMessage["placement"]) => void;
|
|
24
20
|
untrackPending: (messageId: string, hold?: boolean) => void;
|
|
25
21
|
};
|
|
26
22
|
//# sourceMappingURL=context-bookkeeping.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context-bookkeeping.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/context-bookkeeping.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAA;AAC3E,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"context-bookkeeping.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/context-bookkeeping.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAA;AAC3E,OAAO,KAAK,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnE,+EAA+E;AAC/E,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,MAAM;IACX;wEACoE;IACpE,gBAAgB,EAAE,gBAAgB,GAAG,SAAS,CAAA;IAC9C,OAAO,EAAE,cAAc,EAAE,CAAA;IACzB,IAAI,IAAI,IAAI,CAAA;CACb,EACD,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE;IAAE,KAAK,EAAE,SAAS,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,KAAK,OAAO,EACnF,cAAc,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,EAC3C,mBAAmB,EAAE,MAAM;;;;+BAuCK,IAAI;+BApCJ,IAAI;4BAeL,iBAAiB,aAAa,cAAc,CAAC,WAAW,CAAC,KAAG,IAAI;gCAa5D,MAAM,qBAAiB,IAAI;EAU/D"}
|
|
@@ -21,7 +21,13 @@ export function createContextBookkeeping(state, notify, lowContextText, warningB
|
|
|
21
21
|
};
|
|
22
22
|
const trackPending = (message, placement) => {
|
|
23
23
|
const channel = state();
|
|
24
|
-
channel.pending = [...channel.pending, {
|
|
24
|
+
channel.pending = [...channel.pending, {
|
|
25
|
+
id: message.id,
|
|
26
|
+
text: message.text,
|
|
27
|
+
images: message.images ?? [],
|
|
28
|
+
placement,
|
|
29
|
+
...(message.contexts === undefined || message.contexts.length === 0 ? {} : { contexts: message.contexts }),
|
|
30
|
+
}];
|
|
25
31
|
channel.emit();
|
|
26
32
|
};
|
|
27
33
|
/** Drop the preview of a message the backend never took; `hold` keeps it
|
|
@@ -110,16 +110,12 @@ export declare function createCoreChannel(ctx: ChannelHost, initialSession: Agen
|
|
|
110
110
|
};
|
|
111
111
|
resetContextWarning: () => void;
|
|
112
112
|
checkContextWarning: () => void;
|
|
113
|
-
trackPending: (message:
|
|
114
|
-
id: string;
|
|
115
|
-
text: string;
|
|
116
|
-
images?: readonly import("../types.js").ComposerImageRef[];
|
|
117
|
-
}, placement: import("../types.js").PendingMessage["placement"]) => void;
|
|
113
|
+
trackPending: (message: import("../types.js").PendingTrackInput, placement: import("../types.js").PendingMessage["placement"]) => void;
|
|
118
114
|
untrackPending: (messageId: string, hold?: boolean) => void;
|
|
119
115
|
};
|
|
120
116
|
composer: import("../composer-images.js").ComposerImages;
|
|
121
117
|
input: {
|
|
122
|
-
dispatchUserText: (text: string, placement: import("../types.js").PendingMessage["placement"], images?: readonly import("../types.js").ComposerImageRef[], attach?: import("@deepseek-ai/dsh-llm").UserMessage) => void;
|
|
118
|
+
dispatchUserText: (text: string, placement: import("../types.js").PendingMessage["placement"], images?: readonly import("../types.js").ComposerImageRef[], attach?: import("@deepseek-ai/dsh-llm").UserMessage, contexts?: readonly import("../types.js").AttachedContext[]) => void;
|
|
123
119
|
activity: () => {
|
|
124
120
|
readonly dispatched: number;
|
|
125
121
|
readonly unsettled: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compose.d.ts","sourceRoot":"","sources":["../../../../../src/dsh-adapter/channel/core/compose.ts"],"names":[],"mappings":"AAsBA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gDAAgD,CAAA;AAGvF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAA;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AAW7D,OAAO,EAA4D,KAAK,sBAAsB,EAAE,MAAM,wBAAwB,CAAA;AAQ9H,OAAO,EAAsB,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAA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AAC,EAAE;QAAE,MAAM,CAAC,IAAI,IAAI,CAAC;QAAC,KAAK,CAAC,IAAI,IAAI,CAAA;KAAE,CAAA;CAC5C;AAED,wCAAwC;AACxC,MAAM,MAAM,WAAW,GAAG,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAE9D,wBAAgB,iBAAiB,CAC/B,GAAG,EAAE,WAAW,EAChB,cAAc,EAAE,YAAY,EAC5B,OAAO,EAAE,oBAAoB,EAC7B,KAAK,EAAE,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;aA+lBiE,CAAC;iBAG3D,CAAA;;wBAjkBC,MAAM,KAAG,IAAI;;;;;;;;;;;;;;;;2BAgQyB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8BApXtD,CAAA;uCAAqC,CAAC;;;;;;;;kBApCpC,CAAC;gBAAmB,CAAC;;;;;;;;;6BAqQL,IAAI;;IAm1BhC,sFAAsF;iBACzE,gBAAgB,GAAG,IAAI;IAQpC,4EAA4E;wBACxD,CAAC,OAAO,EAAE,YAAY,KAAK,IAAI,GAAG,IAAI;IAK1D,gEAAgE;aACvD,YAAY;EA4BxB"}
|
|
@@ -365,7 +365,7 @@ export function createCoreChannel(ctx, initialSession, options, owner) {
|
|
|
365
365
|
};
|
|
366
366
|
};
|
|
367
367
|
const state = {
|
|
368
|
-
...createInputActions(() => state, () => binding.session, owner, inputConvergence, composer, (text, placement, images) => dispatchUserText(text, placement, images), (command, includeInContext) => getReadyActions().runLocalCommand(command, includeInContext), sessionId => { extension.touchSession?.(sessionId); }),
|
|
368
|
+
...createInputActions(() => state, () => binding.session, owner, inputConvergence, composer, (text, placement, images, attach, contexts) => dispatchUserText(text, placement, images, attach, contexts), (command, includeInContext) => getReadyActions().runLocalCommand(command, includeInContext), sessionId => { extension.touchSession?.(sessionId); }),
|
|
369
369
|
subscribe: emitter.subscribe,
|
|
370
370
|
emit: emitter.emit,
|
|
371
371
|
emitStream: emitter.emitStream,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local-actions.d.ts","sourceRoot":"","sources":["../../../../../src/dsh-adapter/channel/core/local-actions.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAOvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AACnD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAG/C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAA;AAEzC,+DAA+D;AAC/D,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,IAAI,CAAC,YAAY,EAAE,gBAAgB,GAAG,MAAM,CAAC,EACpD,MAAM,EAAE,YAAY,CAAC,QAAQ,CAAC,EAC9B,IAAI,EAAE,MAAM,GACX,OAAO,CAYT;
|
|
1
|
+
{"version":3,"file":"local-actions.d.ts","sourceRoot":"","sources":["../../../../../src/dsh-adapter/channel/core/local-actions.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAOvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AACnD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAG/C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAA;AAEzC,+DAA+D;AAC/D,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,IAAI,CAAC,YAAY,EAAE,gBAAgB,GAAG,MAAM,CAAC,EACpD,MAAM,EAAE,YAAY,CAAC,QAAQ,CAAC,EAC9B,IAAI,EAAE,MAAM,GACX,OAAO,CAYT;AAED,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,aAAa,EAAE,IAAI,EAAE;IAC/D,KAAK,EAAE,IAAI,CAAC,YAAY,EAAE,SAAS,CAAC,CAAA;IACpC,OAAO,EAAE,IAAI,CAAC,cAAc,EAAE,SAAS,GAAG,WAAW,CAAC,CAAA;IACtD,KAAK,EAAE,YAAY,CAAA;IACnB,MAAM,EAAE;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IACzB,SAAS,EAAE,QAAQ,CAAC,kBAAkB,CAAC,CAAA;IACvC,eAAe,IAAI,IAAI,CAAA;IACvB,MAAM,EAAE,YAAY,CAAC,QAAQ,CAAC,CAAA;IAC9B,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAA;IAC/B,2EAA2E;IAC3E,QAAQ,IAAI,IAAI,CAAA;IAChB;2DACuD;IACvD,SAAS,IAAI,CAAC,MAAM,MAAM,CAAC,GAAG,SAAS,CAAA;IACvC,kEAAkE;IAClE,UAAU,CAAC,IAAI,MAAM,IAAI,CAAA;CAC1B;iBAIgB,MAAM;aAQV,IAAI;qBAYI,MAAM,SAAS,SAAS,MAAM,EAAE,YAAY;QAAE,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,IAAI;8BAchH,MAAM,KAAG,OAAO;IAE1C;;;;OAIG;6BAC4B,MAAM,oBAAoB,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;EA8CnF;AAED,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAA"}
|
|
@@ -4,7 +4,7 @@ import { writeActivityFrames } from '../../../activityPrefs.js';
|
|
|
4
4
|
import { isPresetName, normalizeActivityPreset } from '../../../components/activityFrames.js';
|
|
5
5
|
import { t } from '../../../i18n.js';
|
|
6
6
|
import { runForegroundShell } from '../../compat/shell.js';
|
|
7
|
-
import { LOCAL_OUTPUT_LIMIT,
|
|
7
|
+
import { LOCAL_OUTPUT_LIMIT, preview, previewIndented, trimLocalRows } from '../transcript.js';
|
|
8
8
|
import { sessionWorkingDirectory } from '../../../channel/working-directory.js';
|
|
9
9
|
/** `/activity frames <name>`: validate, persist, re-render. */
|
|
10
10
|
export function setActivityFrames(state, notify, name) {
|
|
@@ -29,18 +29,6 @@ export function setActivityFrames(state, notify, name) {
|
|
|
29
29
|
notify(t('activity-indicator-switched', { name: preset }));
|
|
30
30
|
return true;
|
|
31
31
|
}
|
|
32
|
-
/**
|
|
33
|
-
* One report line that keeps its shape: blank rows stay blank and leading
|
|
34
|
-
* indentation survives; a stray newline still cannot become a second row.
|
|
35
|
-
*/
|
|
36
|
-
function previewIndented(text, limit) {
|
|
37
|
-
const line = text.replace(/[\r\n]+/gu, ' ').replace(/\s+$/u, '');
|
|
38
|
-
// A truly empty Text node measures as zero height; one no-break space keeps
|
|
39
|
-
// the blank row the report asked for without painting anything.
|
|
40
|
-
if (line === '')
|
|
41
|
-
return '\u00a0';
|
|
42
|
-
return line.length <= limit ? line : `${line.slice(0, limit)}…`;
|
|
43
|
-
}
|
|
44
32
|
export function createCoreLocalActions(ctx, deps) {
|
|
45
33
|
const { owner, binding, state, rowIds, notify } = deps;
|
|
46
34
|
return {
|
|
@@ -71,19 +59,8 @@ export function createCoreLocalActions(ctx, deps) {
|
|
|
71
59
|
const render = options?.preserveWhitespace ? previewIndented : preview;
|
|
72
60
|
// Local reports cannot be restored from backend history. Retain whole
|
|
73
61
|
// recent blocks within the existing row budget, without folding facts.
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
if (state.rows[i].kind !== 'local' && state.rows[i].kind !== 'local-output') {
|
|
77
|
-
i++;
|
|
78
|
-
continue;
|
|
79
|
-
}
|
|
80
|
-
let end = i + 1;
|
|
81
|
-
while (state.rows[end]?.kind === 'local-output')
|
|
82
|
-
end++;
|
|
83
|
-
count -= end - i;
|
|
84
|
-
state.rows.splice(i, end - i);
|
|
85
|
-
markChannelReadDirty(state.rows);
|
|
86
|
-
}
|
|
62
|
+
trimLocalRows(state.rows, lines.length + 1);
|
|
63
|
+
markChannelReadDirty(state.rows);
|
|
87
64
|
state.rows.push({ id: rowIds.value++, kind: 'local', text: title });
|
|
88
65
|
for (const line of lines)
|
|
89
66
|
state.rows.push({ id: rowIds.value++, kind: 'local-output', text: render(line, limit) });
|
|
@@ -7,7 +7,7 @@ beforeStream, options = {}) {
|
|
|
7
7
|
const foldOption = options.fold;
|
|
8
8
|
const fold = typeof foldOption === 'function' ? foldOption : foldOption === false ? () => false : () => true;
|
|
9
9
|
const listeners = new Set();
|
|
10
|
-
const foldCursor = { rows: undefined, index: 0, head: undefined };
|
|
10
|
+
const foldCursor = { rows: undefined, index: 0, head: undefined, boundary: undefined };
|
|
11
11
|
let timer;
|
|
12
12
|
let disposed = false;
|
|
13
13
|
const wake = (source) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extensions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/extensions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAKlD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAA;AAyB5D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"extensions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/extensions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAKlD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAA;AAyB5D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AA6BpD,OAAO,EAAqB,KAAK,oBAAoB,EAAE,MAAM,YAAY,CAAA;AAsBzE;;;;;GAKG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,WAAW,EACjB,GAAG,EAAE,OAAO,EACZ,aAAa,EAAE,SAAS,EACxB,OAAO,EAAE,oBAAoB,GAC5B,IAAI,CA8xBN"}
|
|
@@ -27,6 +27,7 @@ import { createLoadedContextRefresher } from './loaded-context.js';
|
|
|
27
27
|
import { createLocalActions } from './local-actions.js';
|
|
28
28
|
import { mentionAttachments } from './mentions.js';
|
|
29
29
|
import { createModelSelection } from './model-selection.js';
|
|
30
|
+
import { createToolScope } from '../tool-scope.js';
|
|
30
31
|
import { createModelActions } from './model-actions.js';
|
|
31
32
|
import { createModelSwitchAction } from './model-switch.js';
|
|
32
33
|
import { autoPresetConfirmed, createPermissionModeActions } from './mode-permission-actions.js';
|
|
@@ -211,7 +212,9 @@ export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
|
211
212
|
// `/team` is gated on its service, not on a backend capability: Help and `/`
|
|
212
213
|
// completion read `commandList`, so this is the one catalog that can hide it
|
|
213
214
|
// while `agentTeams` is absent. Keep the unfiltered list so a later service
|
|
214
|
-
// mount restores the row without waiting for a skill-catalog refresh.
|
|
215
|
+
// mount restores the row without waiting for a skill-catalog refresh. On a
|
|
216
|
+
// selection host (0.2.2-rc.2+) `dsh-base` mounts the service unconditionally,
|
|
217
|
+
// so the row is always there — it carries the `/team on|off` switch.
|
|
215
218
|
let commandBase = LOCAL_COMMANDS;
|
|
216
219
|
const publishCommandList = (commands, emit = true) => {
|
|
217
220
|
state.commandList = annotateCommandCapabilities(withTeamCommandVisibility(commands, teamServiceActive(ctx)), capabilitiesOf());
|
|
@@ -222,9 +225,10 @@ export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
|
222
225
|
// before the first skill-catalog refresh publishes a new one, and a command
|
|
223
226
|
// whose capability is missing must never look usable in that window.
|
|
224
227
|
publishCommandList(LOCAL_COMMANDS, false);
|
|
225
|
-
// The team service appears and disappears with its bundle
|
|
226
|
-
// Web write)
|
|
227
|
-
//
|
|
228
|
+
// The team service appears and disappears with its bundle on a bundle host
|
|
229
|
+
// (HMR, a CLI or Web write); a selection host mounts it with `dsh-base` for
|
|
230
|
+
// the whole process. Follow the same `internal/service` signal the team
|
|
231
|
+
// store reads, so the command catalog and the Help/`/` popup follow it.
|
|
228
232
|
owner.own(ctx.on('internal/service', ((name) => {
|
|
229
233
|
if (name === 'agentTeams')
|
|
230
234
|
publishCommandList(commandBase);
|
|
@@ -480,6 +484,11 @@ export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
|
480
484
|
state.cancelPending = false;
|
|
481
485
|
state.status = binding.agent.status;
|
|
482
486
|
state.emit();
|
|
487
|
+
// Track all existing and newly published agent scopes, not only the screen's
|
|
488
|
+
// binding: background dispatch and subagents may run without being attached.
|
|
489
|
+
// Older hosts retain the final-assembly filters in the plugin instead.
|
|
490
|
+
// Created after the agent view so construction rollback still owns its listeners.
|
|
491
|
+
const toolScope = createToolScope(ctx, dispose => owner.own(dispose), () => binding.agent);
|
|
483
492
|
const modelActions = createModelActions(ctx, state, {
|
|
484
493
|
owner,
|
|
485
494
|
binding,
|
|
@@ -488,6 +497,7 @@ export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
|
488
497
|
agent: () => binding.agent,
|
|
489
498
|
notify,
|
|
490
499
|
checkContextWarning: core.bookkeeping.checkContextWarning,
|
|
500
|
+
onPresetChanged: agent => toolScope.apply(agent),
|
|
491
501
|
});
|
|
492
502
|
// The first bind (start) and every adoption tail bind through the core
|
|
493
503
|
// feed, which runs the DSH binding-events hooks below.
|
|
@@ -538,6 +548,7 @@ export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
|
538
548
|
seedActivity: options.seedActivity,
|
|
539
549
|
seedContextOccupancy: options.seedContextOccupancy,
|
|
540
550
|
seedTeam: options.seedTeam,
|
|
551
|
+
onBind: agent => toolScope.apply(agent),
|
|
541
552
|
inputConvergence: core.inputConvergence,
|
|
542
553
|
modelSelection,
|
|
543
554
|
modelActions,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { AgentSession } from '../../agent/session.js';
|
|
2
|
-
import type { ChannelState, ComposerImageRef } from './types.js';
|
|
2
|
+
import type { AttachedContext, ChannelState, ComposerImageRef } from './types.js';
|
|
3
3
|
export interface InputConvergence {
|
|
4
4
|
cancelInFlight: boolean;
|
|
5
5
|
interruptSeq: number;
|
|
@@ -29,7 +29,7 @@ export declare function createInputActions(getState: () => Pick<ChannelState, 'a
|
|
|
29
29
|
assertActive(): void;
|
|
30
30
|
}, input: InputConvergence, composer: {
|
|
31
31
|
includeLegacyImageRefs(text: string, images: readonly ComposerImageRef[]): readonly ComposerImageRef[];
|
|
32
|
-
}, dispatchUserText: (text: string, placement: 'steer' | 'followup', images?: readonly ComposerImageRef[]) => void, runLocalCommand: (command: string, includeInContext: boolean) => Promise<void>,
|
|
32
|
+
}, dispatchUserText: (text: string, placement: 'steer' | 'followup', images?: readonly ComposerImageRef[], attach?: never, contexts?: readonly AttachedContext[]) => void, runLocalCommand: (command: string, includeInContext: boolean) => Promise<void>,
|
|
33
33
|
/** Move the used session to the front of the `/resume` MRU (DSH session
|
|
34
34
|
* history); a backend whose sessions that list cannot open passes a no-op. */
|
|
35
35
|
touch?: (sessionId: string) => void): Pick<ChannelState, 'submit' | 'steer' | 'removePending' | 'cancel' | 'interruptAndDeliver' | 'interruptAndDock' | 'deliverDocked' | 'swapDockedForDraft' | 'holdInputs'>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input-actions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/input-actions.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAiB,MAAM,wBAAwB,CAAA;AAGzE,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAsC,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"input-actions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/input-actions.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AC/E,KAAK,GAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAmB,GAChD,IAAI,CAAC,YAAY,EAAE,QAAQ,GAAG,OAAO,GAAG,eAAe,GAAG,QAAQ,GAAG,qBAAqB,GAAG,kBAAkB,GAAG,eAAe,GAAG,oBAAoB,GAAG,YAAY,CAAC,CAiY1K"}
|
|
@@ -267,7 +267,7 @@ touch = touchSession) {
|
|
|
267
267
|
state.emit();
|
|
268
268
|
for (const entry of ready) {
|
|
269
269
|
touch(state.agentId);
|
|
270
|
-
dispatchUserText(entry.text, 'followup', entry.images);
|
|
270
|
+
dispatchUserText(entry.text, 'followup', entry.images, undefined, entry.contexts);
|
|
271
271
|
}
|
|
272
272
|
return ready.length;
|
|
273
273
|
},
|
|
@@ -297,6 +297,10 @@ touch = touchSession) {
|
|
|
297
297
|
// when that row was (its own session ended), so `/new` keeps it too.
|
|
298
298
|
const orphaned = state.pending[index].orphaned === true;
|
|
299
299
|
// A docked retract is purely local on every backend (see removePending).
|
|
300
|
+
// The swap row carries the DRAFT's text, so it must not inherit the
|
|
301
|
+
// retracted row's contexts: the caller re-stages those into the composer
|
|
302
|
+
// (PromptInput's restageContexts), and keeping a copy here would send the
|
|
303
|
+
// same panel body with this draft's later dock delivery.
|
|
300
304
|
state.pending = [
|
|
301
305
|
...state.pending.filter(item => item.id !== id),
|
|
302
306
|
{
|
|
@@ -311,19 +315,36 @@ touch = touchSession) {
|
|
|
311
315
|
state.emit();
|
|
312
316
|
return true;
|
|
313
317
|
},
|
|
314
|
-
holdInputs(
|
|
318
|
+
holdInputs(inputs) {
|
|
315
319
|
owner.assertActive();
|
|
316
320
|
const state = getState();
|
|
317
321
|
// Local ids like the swap's: no backend copy exists, so no inbox event
|
|
318
322
|
// can match these rows and no interrupt receipt covers them.
|
|
319
|
-
const held =
|
|
320
|
-
|
|
323
|
+
const held = inputs
|
|
324
|
+
.map(input => typeof input === 'string' ? { text: input } : input)
|
|
325
|
+
.filter(input => input.text.trim() !== '')
|
|
326
|
+
.map((input) => ({
|
|
327
|
+
id: `dock-held-${randomUUID()}`,
|
|
328
|
+
text: input.text,
|
|
329
|
+
images: [...(input.images ?? [])],
|
|
330
|
+
...(input.contexts === undefined || input.contexts.length === 0 ? {} : { contexts: [...input.contexts] }),
|
|
331
|
+
placement: 'followup',
|
|
332
|
+
docked: true,
|
|
333
|
+
orphaned: true,
|
|
321
334
|
}));
|
|
322
335
|
if (held.length === 0)
|
|
323
336
|
return 0;
|
|
324
337
|
state.pending = [...state.pending, ...held];
|
|
325
|
-
|
|
326
|
-
|
|
338
|
+
// The rows are on the pending list now: a listener throwing out of the
|
|
339
|
+
// emit (or a disposed owner in notify) must not read as "nothing was
|
|
340
|
+
// held", or the caller releases the claim and another pass holds the
|
|
341
|
+
// same inputs a second time.
|
|
342
|
+
try {
|
|
343
|
+
state.emit();
|
|
344
|
+
state.notify(t('input-orphans-held', { count: held.length }), { color: 'warning', timeoutMs: 8000 });
|
|
345
|
+
}
|
|
346
|
+
catch {
|
|
347
|
+
}
|
|
327
348
|
return held.length;
|
|
328
349
|
},
|
|
329
350
|
interruptAndDeliver(inputs) {
|
|
@@ -332,8 +353,8 @@ touch = touchSession) {
|
|
|
332
353
|
const session = getSession();
|
|
333
354
|
const queued = inputs
|
|
334
355
|
.map(input => typeof input === 'string'
|
|
335
|
-
? { text: input.trim(), images: [] }
|
|
336
|
-
: { text: input.text.trim(), images: [...(input.images ?? [])] })
|
|
356
|
+
? { text: input.trim(), images: [], contexts: undefined }
|
|
357
|
+
: { text: input.text.trim(), images: [...(input.images ?? [])], contexts: undefined })
|
|
337
358
|
.filter(input => input.text !== '');
|
|
338
359
|
if (queued.length === 0)
|
|
339
360
|
return 0;
|
|
@@ -374,8 +395,11 @@ touch = touchSession) {
|
|
|
374
395
|
touch(state.agentId);
|
|
375
396
|
// Same tui/input decision pass as a typed submit: Ctrl+Enter must
|
|
376
397
|
// not bypass a plugin's cancel/transform policy, and re-queued
|
|
377
|
-
// texts keep submission order through the one FIFO chain.
|
|
378
|
-
|
|
398
|
+
// texts keep submission order through the one FIFO chain. A docked
|
|
399
|
+
// row carries the "send to Chat" contexts its original submission
|
|
400
|
+
// did, and their chips are gone: forward them or the model loses
|
|
401
|
+
// that context.
|
|
402
|
+
dispatchUserText(entry.text, 'followup', entry.images, undefined, entry.contexts);
|
|
379
403
|
}
|
|
380
404
|
};
|
|
381
405
|
// Let cancel finish its synchronous inbox bookkeeping before waking.
|
|
@@ -5,7 +5,7 @@ import type { ChannelHost } from './channel-host.js';
|
|
|
5
5
|
import type { LocalImageStore } from './core/local-images.js';
|
|
6
6
|
import type { ChannelOwner } from './owner.js';
|
|
7
7
|
import type { AttachedContext, ChannelSelection, SelectionAttachment } from '../../adapter/ports/channel-view.js';
|
|
8
|
-
import type { ChannelImageBlock, ChannelState, ComposerImageRef, MentionAttachments, MentionFs, PendingMessage, StagedImageInput } from './types.js';
|
|
8
|
+
import type { ChannelImageBlock, ChannelState, ComposerImageRef, MentionAttachments, MentionFs, PendingMessage, PendingTrackInput, StagedImageInput } from './types.js';
|
|
9
9
|
/** One submission's enqueue-time world: the session it was typed in, the
|
|
10
10
|
* services that resolve its references, and the capabilities live then. */
|
|
11
11
|
export interface UserTextOrigin {
|
|
@@ -34,11 +34,7 @@ export interface UserTextOrigin {
|
|
|
34
34
|
/** Input FIFO, staged attachments and decision notice timers share one lifetime. */
|
|
35
35
|
export declare function createInputDelivery(ctx: ChannelHost, owner: ChannelOwner, binding: {
|
|
36
36
|
readonly session: AgentSession;
|
|
37
|
-
}, state: () => Pick<ChannelState, 'cwd' | 'workingDirectory' | 'agentId' | 'agentBindingGeneration'>, notify: ChannelState['notify'], trackPending: (message:
|
|
38
|
-
id: string;
|
|
39
|
-
text: string;
|
|
40
|
-
images?: readonly ComposerImageRef[];
|
|
41
|
-
}, placement: PendingMessage['placement']) => void, untrackPending: (id: string, hold?: boolean) => void, composer: ComposerImages, selection: () => ChannelSelection | undefined, rememberSelection: (messageId: string, info: SelectionAttachment) => void,
|
|
37
|
+
}, state: () => Pick<ChannelState, 'cwd' | 'workingDirectory' | 'agentId' | 'agentBindingGeneration'>, notify: ChannelState['notify'], trackPending: (message: PendingTrackInput, placement: PendingMessage['placement']) => void, untrackPending: (id: string, hold?: boolean) => void, composer: ComposerImages, selection: () => ChannelSelection | undefined, rememberSelection: (messageId: string, info: SelectionAttachment) => void,
|
|
42
38
|
/** The fs surface to use when the host mounts no `fs` service (a non-DSH
|
|
43
39
|
* composition reads the local disk); absent = no fallback. */
|
|
44
40
|
fallbackFs?: () => MentionFs | undefined,
|
|
@@ -52,7 +48,7 @@ localImages?: () => LocalImageStore | undefined,
|
|
|
52
48
|
* simply carries no contexts.
|
|
53
49
|
*/
|
|
54
50
|
consumeAttachedContexts?: () => readonly AttachedContext[]): {
|
|
55
|
-
dispatchUserText: (text: string, placement: PendingMessage["placement"], images?: readonly ComposerImageRef[], attach?: UserMessage) => void;
|
|
51
|
+
dispatchUserText: (text: string, placement: PendingMessage["placement"], images?: readonly ComposerImageRef[], attach?: UserMessage, contexts?: readonly AttachedContext[]) => void;
|
|
56
52
|
/** Inputs dispatched so far, and whether any is still in the FIFO (a
|
|
57
53
|
* parked decision, an `@` read, an IDE-selection read). */
|
|
58
54
|
activity: () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input-delivery.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/input-delivery.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,KAAK,WAAW,EAAE,MAAM,sBAAsB,CAAA;AAC1E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AAG1D,OAAO,EAIL,KAAK,cAAc,EACpB,MAAM,sBAAsB,CAAA;AAM7B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AACpD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAA;AAC7D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM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AAO,CAAC;QAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAE;4BAlB9F,MAAM,aACD,cAAc,CAAC,WAAW,CAAC,WAC9B,SAAS,gBAAgB,EAAE,WAC1B,WAAW,KACnB,IAAI;iCAxV6B,SAAS,WAAW,EAAE,KAAG,WAAW,EAAE;kCAarC,MAAM,KAAG,IAAI;0BAgMrB,CAAC,QAAQ,MAAM,WAAW,OAAO,CAAC,CAAC,CAAC,WAAW,cAAc,KAAG,OAAO,CAAC,CAAC,CAAC;6BA+IzE,IAAI;wBAoBZ,gBAAgB,KAAG,OAAO,CAAC,MAAM,CAAC;wBACpC,WAAW,CAAC,MAAM,EAAE,iBAAiB,CAAC,YAAY,CAAC,CAAC;;EAGzE"}
|
|
@@ -3,7 +3,7 @@ import { t } from '../../i18n.js';
|
|
|
3
3
|
import { logForDebugging } from '../../utils/debug.js';
|
|
4
4
|
import { firstStaleComposerToken, formatMissingReference, orderedComposerImages, } from './composer-images.js';
|
|
5
5
|
import { expandComposerMentions } from './composer-mentions.js';
|
|
6
|
-
import { appendAttachedContextBlocks } from './attached-context.js';
|
|
6
|
+
import { appendAttachedContextBlocks, mergeAttachedContexts } from './attached-context.js';
|
|
7
7
|
import { normalizeInputDecision } from './decisions.js';
|
|
8
8
|
import { attachIdeSelection } from './ide-selection.js';
|
|
9
9
|
import { mentionAttachments, mentionFs } from './mentions.js';
|
|
@@ -163,7 +163,7 @@ consumeAttachedContexts) {
|
|
|
163
163
|
// Track BEFORE the submit: a synchronous throw inside it rolls the
|
|
164
164
|
// preview back; otherwise the backend's pending changes retire it once
|
|
165
165
|
// the message is claimed or discarded.
|
|
166
|
-
trackPending({ id: message.id, text, images }, placement);
|
|
166
|
+
trackPending({ id: message.id, text, images, contexts: origin.attachedContexts }, placement);
|
|
167
167
|
try {
|
|
168
168
|
// The message id IS the clientMessageId every ledger above keys on; the
|
|
169
169
|
// DSH session delivers this exact message (steer/followup).
|
|
@@ -184,7 +184,9 @@ consumeAttachedContexts) {
|
|
|
184
184
|
if (!result.accepted) {
|
|
185
185
|
if (attach !== undefined)
|
|
186
186
|
attachedByMessageId.delete(message.id);
|
|
187
|
-
|
|
187
|
+
// A backend that is certain it never ran the input asks for it back
|
|
188
|
+
// (`dropped`), like an ended session: keep the text as a dock row.
|
|
189
|
+
const hold = result.dropped === true || origin.session.status === 'disposed';
|
|
188
190
|
untrackPending(message.id, hold);
|
|
189
191
|
// A refusal with no reason is still a refusal: say so, or the send
|
|
190
192
|
// looks successful while nothing was queued.
|
|
@@ -355,8 +357,15 @@ consumeAttachedContexts) {
|
|
|
355
357
|
notify(t('send-failed', { err: message }), { color: 'error' });
|
|
356
358
|
}
|
|
357
359
|
};
|
|
358
|
-
const dispatchUserText = (text, placement, images = [], attach) => {
|
|
359
|
-
const
|
|
360
|
+
const dispatchUserText = (text, placement, images = [], attach, contexts) => {
|
|
361
|
+
const captured = captureOrigin();
|
|
362
|
+
// A dock re-send carries the contexts the row saved: the live chips were
|
|
363
|
+
// consumed by the submission that was refused (#1651). `captureOrigin`
|
|
364
|
+
// already took whatever the user staged since, so merge — never replace —
|
|
365
|
+
// or those chips would be neither sent nor kept.
|
|
366
|
+
const origin = contexts === undefined || contexts.length === 0
|
|
367
|
+
? captured
|
|
368
|
+
: { ...captured, attachedContexts: mergeAttachedContexts(contexts, captured.attachedContexts) };
|
|
360
369
|
const capturedImages = composer.captureDraftImages(text, images);
|
|
361
370
|
dispatched += 1;
|
|
362
371
|
inFlight.push(text);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local-actions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/local-actions.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"local-actions.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/local-actions.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,IAAI,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AAE3D;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE;IACvC,GAAG,EAAE;QAAE,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAA;KAAE,CAAA;IACnC,KAAK,EAAE;QAAE,OAAO,IAAI,OAAO,CAAA;KAAE,CAAA;IAC7B,OAAO,EAAE;QACP,OAAO,IAAI,OAAO,CAAA;QAClB,SAAS,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAA;QACpC,QAAQ,CAAC,KAAK,EAAE;YAAE,OAAO,EAAE,OAAO,CAAA;SAAE,CAAA;KACrC,CAAA;IACD,KAAK,EAAE,YAAY,CAAA;IACnB,UAAU,EAAE,iBAAiB,CAAA;IAC7B,QAAQ,EAAE,OAAO,QAAQ,CAAA;CAC1B;IAIG;wEACoE;iBACvD,MAAM;qBAGI,OAAO,CAAC,MAAM,EAAE,CAAC;EA0B3C"}
|