@leitwerk-dev/ui 0.1.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/dist/LICENSE +13 -0
- package/dist/assets/ChronicleMarkdown-BLgtHeEE.js +16 -0
- package/dist/assets/ChronicleMarkdown-D6hFzERy.css +1 -0
- package/dist/assets/FutureLaunchDetailPage-KrXSGzHM.js +1 -0
- package/dist/assets/FutureLaunchDetailPage-VPMBtpYc.css +1 -0
- package/dist/assets/GenericLauncher-Cv38FByt.js +1 -0
- package/dist/assets/GenericLauncher-D_GMtsQ5.css +1 -0
- package/dist/assets/HomePage-Cd3lEtwZ.js +1 -0
- package/dist/assets/HomePage-DYh_QHXv.css +1 -0
- package/dist/assets/PageHeader-6PdvYODN.css +1 -0
- package/dist/assets/PageHeader-D6pP4hIh.js +1 -0
- package/dist/assets/ProcessActionsMenu-1QySGNy9.js +1 -0
- package/dist/assets/ProcessActionsMenu-BT2r9vO8.css +1 -0
- package/dist/assets/ProcessDetailPage-BLuc7sjV.js +12 -0
- package/dist/assets/ProcessDetailPage-CSrjzajF.css +1 -0
- package/dist/assets/ProcessFlowDiagram-BAh_M_rb.js +2 -0
- package/dist/assets/ProcessFlowDiagram-Cz8wNicU.css +1 -0
- package/dist/assets/ProcessesPage-BcM38HMs.css +1 -0
- package/dist/assets/ProcessesPage-DtPweRU-.js +1 -0
- package/dist/assets/ScheduleDateTimePicker-CQGvY-Rc.js +1 -0
- package/dist/assets/ScheduleDateTimePicker-CadXN9z7.css +1 -0
- package/dist/assets/SkillsPage-B30FAFia.css +1 -0
- package/dist/assets/SkillsPage-bXuv0kEE.js +2 -0
- package/dist/assets/WatchersPage-DNyUsU1y.js +1 -0
- package/dist/assets/WatchersPage-Dnfi1zUK.css +1 -0
- package/dist/assets/api-CqECFdii.js +1 -0
- package/dist/assets/browser-storage-LbKCyf_w.js +1 -0
- package/dist/assets/dist-B7WNbObw.js +2 -0
- package/dist/assets/index-66T4Gmbl.css +1 -0
- package/dist/assets/index-C8qCggeq.js +7 -0
- package/dist/assets/index-client-BqF3_t3P.js +2 -0
- package/dist/assets/mermaid-render.worker-DAVgiVRG.js +6393 -0
- package/dist/assets/retry-config.svelte-DFKCJtCe.js +1 -0
- package/dist/assets/router.svelte-COr45o9R.js +1 -0
- package/dist/fonts/OFL-Public-Sans.txt +115 -0
- package/dist/fonts/OFL-Spectral.txt +93 -0
- package/dist/fonts/README.md +38 -0
- package/dist/fonts/fonts.css +85 -0
- package/dist/fonts/public-sans-latin-cd00287f.woff2 +0 -0
- package/dist/fonts/public-sans-latin-ext-d025d4ba.woff2 +0 -0
- package/dist/fonts/spectral-latin-89d48951.woff2 +0 -0
- package/dist/fonts/spectral-latin-b7578f14.woff2 +0 -0
- package/dist/fonts/spectral-latin-c4e0a00d.woff2 +0 -0
- package/dist/fonts/spectral-latin-ext-260738f4.woff2 +0 -0
- package/dist/fonts/spectral-latin-ext-ab18ac17.woff2 +0 -0
- package/dist/fonts/spectral-latin-ext-f58c1db3.woff2 +0 -0
- package/dist/index.html +32 -0
- package/package.json +47 -0
- package/src/App.svelte +257 -0
- package/src/chronicle/components/ChronicleActionSection.svelte +1035 -0
- package/src/chronicle/components/ChronicleExpandButton.svelte +70 -0
- package/src/chronicle/components/ChronicleFlow.svelte +289 -0
- package/src/chronicle/components/ChronicleLeafOutcomePlaceholder.svelte +44 -0
- package/src/chronicle/components/ChronicleLeafOutcomeRendererHost.svelte +408 -0
- package/src/chronicle/components/ChronicleLeafOutcomeSection.svelte +253 -0
- package/src/chronicle/components/ChronicleLiveChip.svelte +96 -0
- package/src/chronicle/components/ChronicleLiveTail.svelte +376 -0
- package/src/chronicle/components/ChronicleMarkdown.svelte +168 -0
- package/src/chronicle/components/ChronicleOperatorInputSection.svelte +41 -0
- package/src/chronicle/components/ChronicleProcessErrorSection.svelte +131 -0
- package/src/chronicle/components/ChroniclePromptSection.svelte +54 -0
- package/src/chronicle/components/ChronicleQuestionRequest.svelte +167 -0
- package/src/chronicle/components/ChronicleReasoningDetailsOverlay.svelte +893 -0
- package/src/chronicle/components/ChronicleRecoverySection.svelte +338 -0
- package/src/chronicle/components/ChronicleScheduledActionSection.svelte +192 -0
- package/src/chronicle/components/ChronicleSectionHeader.svelte +135 -0
- package/src/chronicle/components/ChronicleStartupRecoverySection.svelte +138 -0
- package/src/chronicle/components/ChronicleTerminalSummary.svelte +127 -0
- package/src/chronicle/components/ChronicleThinkingSection.svelte +191 -0
- package/src/chronicle/components/ChronicleThinkingText.svelte +46 -0
- package/src/chronicle/components/ChronicleToolCallItem.svelte +477 -0
- package/src/chronicle/components/ChronicleTurnCluster.svelte +325 -0
- package/src/chronicle/components/ChronicleTurnRail.svelte +584 -0
- package/src/chronicle/components/ChronicleUsageStats.svelte +107 -0
- package/src/chronicle/components/CompactActionComposer.svelte +417 -0
- package/src/chronicle/components/ModelProfileOptions.svelte +20 -0
- package/src/chronicle/components/ProviderOptionsEditor.svelte +171 -0
- package/src/chronicle/components/RecoveryModelControl.svelte +95 -0
- package/src/chronicle/lib/action-bindings.ts +90 -0
- package/src/chronicle/lib/action-model-display.ts +133 -0
- package/src/chronicle/lib/action-preview.ts +16 -0
- package/src/chronicle/lib/chronicle-projection.ts +1342 -0
- package/src/chronicle/lib/chronicle-selectable-items.ts +352 -0
- package/src/chronicle/lib/chronicle-view-model.ts +121 -0
- package/src/chronicle/lib/formatting.ts +18 -0
- package/src/chronicle/lib/leaf-outcome-loader.ts +214 -0
- package/src/chronicle/lib/leaf-outcome-runtime.ts +37 -0
- package/src/chronicle/lib/prompt-highlighting.ts +78 -0
- package/src/chronicle/lib/scroll-sync.ts +88 -0
- package/src/chronicle/lib/tool-call-summary.ts +64 -0
- package/src/components/BrowserUiExtensionIndicatorHost.svelte +34 -0
- package/src/components/ConversationTreeDiagram.svelte +393 -0
- package/src/components/FormFieldRenderer.svelte +359 -0
- package/src/components/GenericLauncher.svelte +1970 -0
- package/src/components/KeyboardShortcutsModal.svelte +52 -0
- package/src/components/ModalShell.svelte +105 -0
- package/src/components/PageHeader.svelte +146 -0
- package/src/components/ProcessActionsMenu.svelte +514 -0
- package/src/components/ProcessInfoOverlay.svelte +1229 -0
- package/src/components/ScheduleDateTimePicker.svelte +155 -0
- package/src/components/SkillSelector.svelte +45 -0
- package/src/components/ToastContainer.svelte +192 -0
- package/src/components/launcher-form-copy.ts +172 -0
- package/src/components/launcher-model-config.ts +263 -0
- package/src/components/launcher-schedule.ts +127 -0
- package/src/extension-ui-dev-server.ts +98 -0
- package/src/lib/api.ts +970 -0
- package/src/lib/beautiful-mermaid-elk-instance.ts +54 -0
- package/src/lib/browser-storage.ts +11 -0
- package/src/lib/cost-estimates.ts +41 -0
- package/src/lib/elk-bundled-worker.ts +41 -0
- package/src/lib/flow-layout.ts +326 -0
- package/src/lib/format.ts +96 -0
- package/src/lib/future-executions-logic.ts +12 -0
- package/src/lib/future-launch-detail.ts +145 -0
- package/src/lib/instance-tree-layout.ts +158 -0
- package/src/lib/keyboard-shortcuts-help.ts +20 -0
- package/src/lib/keyboard.ts +40 -0
- package/src/lib/launcher-recent-values.ts +68 -0
- package/src/lib/markdown.ts +94 -0
- package/src/lib/mermaid-render.worker.ts +36 -0
- package/src/lib/pi-stream.ts +3 -0
- package/src/lib/primary-path-detail.ts +337 -0
- package/src/lib/primary-path-replay.ts +27 -0
- package/src/lib/process-browser.ts +179 -0
- package/src/lib/process-initial-prompt.ts +7 -0
- package/src/lib/process-launch-notices.svelte.ts +25 -0
- package/src/lib/process-row-view.ts +60 -0
- package/src/lib/process-terminal-display.ts +17 -0
- package/src/lib/process-toast-focus.svelte.ts +18 -0
- package/src/lib/processes-logic.ts +2 -0
- package/src/lib/processes.svelte.ts +334 -0
- package/src/lib/request-guard.ts +20 -0
- package/src/lib/retry-config.svelte.ts +19 -0
- package/src/lib/rich-markdown-elements.ts +173 -0
- package/src/lib/router-logic.ts +190 -0
- package/src/lib/router.svelte.ts +56 -0
- package/src/lib/runtime-config.ts +96 -0
- package/src/lib/test-fixtures.ts +13 -0
- package/src/lib/toasts.svelte.ts +104 -0
- package/src/lib/tool-call-rendering.ts +66 -0
- package/src/lib/ui-extensions.svelte.ts +381 -0
- package/src/lib/usage-snapshot.ts +9 -0
- package/src/lib/ws-classifier.ts +80 -0
- package/src/lib/ws.svelte.ts +281 -0
- package/src/main.ts +8 -0
- package/src/pages/FutureLaunchDetailPage.svelte +479 -0
- package/src/pages/HomePage.svelte +306 -0
- package/src/pages/ProcessCard.svelte +99 -0
- package/src/pages/ProcessDetailPage.svelte +599 -0
- package/src/pages/ProcessFlowDiagram.svelte +696 -0
- package/src/pages/ProcessGallery.svelte +252 -0
- package/src/pages/ProcessesPage.svelte +994 -0
- package/src/pages/SkillsPage.svelte +665 -0
- package/src/pages/WatchersPage.svelte +330 -0
- package/src/pages/process-detail/OverlayFrame.svelte +58 -0
- package/src/pages/process-detail/ProcessDetailChronicle.svelte +460 -0
- package/src/pages/process-detail/ProcessDetailHeader.svelte +167 -0
- package/src/pages/process-detail/process-detail-action-drafts.svelte.ts +211 -0
- package/src/pages/process-detail/process-detail-actions.svelte.ts +548 -0
- package/src/pages/process-detail/process-detail-chronicle-dom.ts +102 -0
- package/src/pages/process-detail/process-detail-chronicle-scroll.svelte.ts +711 -0
- package/src/pages/process-detail/process-detail-mutations.svelte.ts +91 -0
- package/src/pages/process-detail/process-detail-view-model.ts +149 -0
- package/src/shell/AppShell.svelte +249 -0
- package/src/shell/RouteLoadBoundary.svelte +43 -0
- package/src/shell/Sidebar.svelte +1358 -0
- package/src/shell/test-fixtures/RouteLoadTestComponent.svelte +5 -0
- package/src/vite-env.d.ts +2 -0
- package/src/vite-server-config.ts +27 -0
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
import {
|
|
2
|
+
type PrimaryPathActiveTurnSnapshot,
|
|
3
|
+
type PrimaryPathSnapshot,
|
|
4
|
+
type PrimaryPathToolCallSnapshot,
|
|
5
|
+
type PrimaryPathTraceItemSnapshot,
|
|
6
|
+
type PrimaryPathWsFrame,
|
|
7
|
+
WS_PRIMARY_PATH_TYPES,
|
|
8
|
+
} from "@leitwerk-dev/protocol";
|
|
9
|
+
import { cloneTurnUsageSnapshot } from "./usage-snapshot.js";
|
|
10
|
+
|
|
11
|
+
function cloneToolCalls(toolCalls: readonly PrimaryPathToolCallSnapshot[]) {
|
|
12
|
+
return toolCalls.map((toolCall) => ({
|
|
13
|
+
...toolCall,
|
|
14
|
+
...(toolCall.arguments ? { arguments: { ...toolCall.arguments } } : {}),
|
|
15
|
+
}));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
function cloneTraceItems(traceItems: readonly PrimaryPathTraceItemSnapshot[]) {
|
|
19
|
+
return traceItems.map((traceItem) => ({ ...traceItem }));
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
function createActiveTurnSnapshot(
|
|
23
|
+
turnRecord: Extract<
|
|
24
|
+
PrimaryPathWsFrame,
|
|
25
|
+
{ type: typeof WS_PRIMARY_PATH_TYPES.TURN_STARTED }
|
|
26
|
+
>["payload"]["turnRecord"],
|
|
27
|
+
): PrimaryPathActiveTurnSnapshot {
|
|
28
|
+
return {
|
|
29
|
+
turnRecordId: turnRecord.id,
|
|
30
|
+
turnId: turnRecord.turnId,
|
|
31
|
+
turnType: turnRecord.turnType,
|
|
32
|
+
pathType: turnRecord.pathType,
|
|
33
|
+
startedAt: turnRecord.startedAt,
|
|
34
|
+
assistant: {
|
|
35
|
+
text: "",
|
|
36
|
+
thinking: "",
|
|
37
|
+
lastUpdatedAt: null,
|
|
38
|
+
},
|
|
39
|
+
toolCalls: [],
|
|
40
|
+
traceItems: [],
|
|
41
|
+
usage: null,
|
|
42
|
+
eventWindowTruncated: false,
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
function updateSemanticLeafRefs<TSnapshot extends PrimaryPathSnapshot>(
|
|
47
|
+
snapshot: TSnapshot,
|
|
48
|
+
rootEntry: PrimaryPathSnapshot["semanticEntryRefs"]["rootEntry"],
|
|
49
|
+
currentLeaf: PrimaryPathSnapshot["semanticEntryRefs"]["currentPrimaryPathLeaf"],
|
|
50
|
+
): TSnapshot {
|
|
51
|
+
return {
|
|
52
|
+
...snapshot,
|
|
53
|
+
currentLeaf,
|
|
54
|
+
semanticEntryRefs: {
|
|
55
|
+
...snapshot.semanticEntryRefs,
|
|
56
|
+
rootEntry,
|
|
57
|
+
currentPrimaryPathLeaf: currentLeaf,
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
function upsertToolCall(
|
|
63
|
+
toolCalls: readonly PrimaryPathToolCallSnapshot[],
|
|
64
|
+
nextToolCall: PrimaryPathToolCallSnapshot,
|
|
65
|
+
): PrimaryPathToolCallSnapshot[] {
|
|
66
|
+
const existingIndex = toolCalls.findIndex(
|
|
67
|
+
(toolCall) => toolCall.toolCallId === nextToolCall.toolCallId,
|
|
68
|
+
);
|
|
69
|
+
if (existingIndex === -1) {
|
|
70
|
+
return [...toolCalls, nextToolCall];
|
|
71
|
+
}
|
|
72
|
+
return toolCalls.map((toolCall, index) =>
|
|
73
|
+
index === existingIndex
|
|
74
|
+
? {
|
|
75
|
+
...toolCall,
|
|
76
|
+
...nextToolCall,
|
|
77
|
+
arguments: nextToolCall.arguments ?? toolCall.arguments,
|
|
78
|
+
}
|
|
79
|
+
: toolCall,
|
|
80
|
+
);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
function appendThinkingTraceItems(
|
|
84
|
+
traceItems: readonly PrimaryPathTraceItemSnapshot[],
|
|
85
|
+
text: string,
|
|
86
|
+
): PrimaryPathTraceItemSnapshot[] {
|
|
87
|
+
if (text.length === 0) {
|
|
88
|
+
return [...traceItems];
|
|
89
|
+
}
|
|
90
|
+
const lastTraceItem = traceItems.at(-1);
|
|
91
|
+
if (lastTraceItem?.kind === "thinking") {
|
|
92
|
+
return [
|
|
93
|
+
...traceItems.slice(0, -1),
|
|
94
|
+
{
|
|
95
|
+
...lastTraceItem,
|
|
96
|
+
text: lastTraceItem.text + text,
|
|
97
|
+
},
|
|
98
|
+
];
|
|
99
|
+
}
|
|
100
|
+
return [...traceItems, { kind: "thinking", text }];
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
function ensureToolTraceItem(
|
|
104
|
+
traceItems: readonly PrimaryPathTraceItemSnapshot[],
|
|
105
|
+
toolCallId: string,
|
|
106
|
+
): PrimaryPathTraceItemSnapshot[] {
|
|
107
|
+
if (
|
|
108
|
+
traceItems.some(
|
|
109
|
+
(traceItem) => traceItem.kind === "tool_call" && traceItem.toolCallId === toolCallId,
|
|
110
|
+
)
|
|
111
|
+
) {
|
|
112
|
+
return [...traceItems];
|
|
113
|
+
}
|
|
114
|
+
return [...traceItems, { kind: "tool_call", toolCallId }];
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export function getPrimaryPathActiveTurnOutput(
|
|
118
|
+
activeTurn: PrimaryPathActiveTurnSnapshot | null | undefined,
|
|
119
|
+
): string {
|
|
120
|
+
if (!activeTurn) {
|
|
121
|
+
return "";
|
|
122
|
+
}
|
|
123
|
+
return activeTurn.assistant.text.trim();
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
export function applyPrimaryPathFrame<TSnapshot extends PrimaryPathSnapshot>(
|
|
127
|
+
snapshot: TSnapshot,
|
|
128
|
+
frame: PrimaryPathWsFrame,
|
|
129
|
+
): TSnapshot {
|
|
130
|
+
switch (frame.type) {
|
|
131
|
+
case WS_PRIMARY_PATH_TYPES.TURN_STARTED:
|
|
132
|
+
return {
|
|
133
|
+
...snapshot,
|
|
134
|
+
turnState: {
|
|
135
|
+
...snapshot.turnState,
|
|
136
|
+
currentTurnRecordId: frame.payload.turnRecord.id,
|
|
137
|
+
isStreaming: true,
|
|
138
|
+
activeTurn: createActiveTurnSnapshot(frame.payload.turnRecord),
|
|
139
|
+
},
|
|
140
|
+
};
|
|
141
|
+
case WS_PRIMARY_PATH_TYPES.ASSISTANT_PARTIAL: {
|
|
142
|
+
const activeTurn = snapshot.turnState.activeTurn;
|
|
143
|
+
if (
|
|
144
|
+
!activeTurn ||
|
|
145
|
+
(frame.payload.turnRecordId && activeTurn.turnRecordId !== frame.payload.turnRecordId)
|
|
146
|
+
) {
|
|
147
|
+
return snapshot;
|
|
148
|
+
}
|
|
149
|
+
return {
|
|
150
|
+
...snapshot,
|
|
151
|
+
turnState: {
|
|
152
|
+
...snapshot.turnState,
|
|
153
|
+
isStreaming: true,
|
|
154
|
+
activeTurn: {
|
|
155
|
+
...activeTurn,
|
|
156
|
+
assistant: {
|
|
157
|
+
...activeTurn.assistant,
|
|
158
|
+
text:
|
|
159
|
+
frame.payload.streamType === "thinking"
|
|
160
|
+
? activeTurn.assistant.text
|
|
161
|
+
: activeTurn.assistant.text + frame.payload.text,
|
|
162
|
+
thinking:
|
|
163
|
+
frame.payload.streamType === "thinking"
|
|
164
|
+
? activeTurn.assistant.thinking + frame.payload.text
|
|
165
|
+
: activeTurn.assistant.thinking,
|
|
166
|
+
lastUpdatedAt: frame.payload.timestamp,
|
|
167
|
+
},
|
|
168
|
+
traceItems:
|
|
169
|
+
frame.payload.streamType === "thinking"
|
|
170
|
+
? appendThinkingTraceItems(activeTurn.traceItems, frame.payload.text)
|
|
171
|
+
: cloneTraceItems(activeTurn.traceItems),
|
|
172
|
+
},
|
|
173
|
+
},
|
|
174
|
+
};
|
|
175
|
+
}
|
|
176
|
+
case WS_PRIMARY_PATH_TYPES.USAGE_UPDATED: {
|
|
177
|
+
const activeTurn = snapshot.turnState.activeTurn;
|
|
178
|
+
if (
|
|
179
|
+
!activeTurn ||
|
|
180
|
+
(frame.payload.turnRecordId && activeTurn.turnRecordId !== frame.payload.turnRecordId)
|
|
181
|
+
) {
|
|
182
|
+
return snapshot;
|
|
183
|
+
}
|
|
184
|
+
return {
|
|
185
|
+
...snapshot,
|
|
186
|
+
turnState: {
|
|
187
|
+
...snapshot.turnState,
|
|
188
|
+
activeTurn: {
|
|
189
|
+
...activeTurn,
|
|
190
|
+
usage: cloneTurnUsageSnapshot(frame.payload.usage),
|
|
191
|
+
},
|
|
192
|
+
},
|
|
193
|
+
};
|
|
194
|
+
}
|
|
195
|
+
case WS_PRIMARY_PATH_TYPES.TOOL_CALL_STARTED: {
|
|
196
|
+
const activeTurn = snapshot.turnState.activeTurn;
|
|
197
|
+
if (
|
|
198
|
+
!activeTurn ||
|
|
199
|
+
(frame.payload.turnRecordId && activeTurn.turnRecordId !== frame.payload.turnRecordId)
|
|
200
|
+
) {
|
|
201
|
+
return snapshot;
|
|
202
|
+
}
|
|
203
|
+
return {
|
|
204
|
+
...snapshot,
|
|
205
|
+
turnState: {
|
|
206
|
+
...snapshot.turnState,
|
|
207
|
+
activeTurn: {
|
|
208
|
+
...activeTurn,
|
|
209
|
+
toolCalls: upsertToolCall(activeTurn.toolCalls, {
|
|
210
|
+
toolCallId: frame.payload.toolCallId,
|
|
211
|
+
toolName: frame.payload.toolName,
|
|
212
|
+
status: "running",
|
|
213
|
+
startedAt: frame.payload.timestamp,
|
|
214
|
+
completedAt: null,
|
|
215
|
+
arguments: frame.payload.arguments,
|
|
216
|
+
result: null,
|
|
217
|
+
isError: false,
|
|
218
|
+
}),
|
|
219
|
+
traceItems: ensureToolTraceItem(activeTurn.traceItems, frame.payload.toolCallId),
|
|
220
|
+
},
|
|
221
|
+
},
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
case WS_PRIMARY_PATH_TYPES.TOOL_CALL_COMPLETED: {
|
|
225
|
+
const activeTurn = snapshot.turnState.activeTurn;
|
|
226
|
+
if (
|
|
227
|
+
!activeTurn ||
|
|
228
|
+
(frame.payload.turnRecordId && activeTurn.turnRecordId !== frame.payload.turnRecordId)
|
|
229
|
+
) {
|
|
230
|
+
return snapshot;
|
|
231
|
+
}
|
|
232
|
+
const existingToolCall = activeTurn.toolCalls.find(
|
|
233
|
+
(toolCall) => toolCall.toolCallId === frame.payload.toolCallId,
|
|
234
|
+
);
|
|
235
|
+
return {
|
|
236
|
+
...snapshot,
|
|
237
|
+
turnState: {
|
|
238
|
+
...snapshot.turnState,
|
|
239
|
+
activeTurn: {
|
|
240
|
+
...activeTurn,
|
|
241
|
+
toolCalls: upsertToolCall(activeTurn.toolCalls, {
|
|
242
|
+
toolCallId: frame.payload.toolCallId,
|
|
243
|
+
toolName: frame.payload.toolName,
|
|
244
|
+
status: "completed",
|
|
245
|
+
startedAt: existingToolCall?.startedAt ?? frame.payload.timestamp,
|
|
246
|
+
completedAt: frame.payload.timestamp,
|
|
247
|
+
arguments: existingToolCall?.arguments ?? null,
|
|
248
|
+
result: frame.payload.result,
|
|
249
|
+
isError: frame.payload.isError,
|
|
250
|
+
}),
|
|
251
|
+
traceItems: ensureToolTraceItem(activeTurn.traceItems, frame.payload.toolCallId),
|
|
252
|
+
},
|
|
253
|
+
},
|
|
254
|
+
};
|
|
255
|
+
}
|
|
256
|
+
case WS_PRIMARY_PATH_TYPES.ASSISTANT_COMMITTED: {
|
|
257
|
+
const nextSnapshot = updateSemanticLeafRefs(
|
|
258
|
+
snapshot,
|
|
259
|
+
frame.payload.rootEntry,
|
|
260
|
+
frame.payload.currentLeaf,
|
|
261
|
+
);
|
|
262
|
+
return {
|
|
263
|
+
...nextSnapshot,
|
|
264
|
+
turnState: {
|
|
265
|
+
...nextSnapshot.turnState,
|
|
266
|
+
currentTurnRecordId: null,
|
|
267
|
+
isStreaming: false,
|
|
268
|
+
activeTurn: null,
|
|
269
|
+
},
|
|
270
|
+
};
|
|
271
|
+
}
|
|
272
|
+
case WS_PRIMARY_PATH_TYPES.TURN_ANNOTATION_CHANGED: {
|
|
273
|
+
const nextAnnotations = snapshot.turnAnnotations.some(
|
|
274
|
+
(annotation) => annotation.id === frame.payload.annotation.id,
|
|
275
|
+
)
|
|
276
|
+
? snapshot.turnAnnotations.map((annotation) =>
|
|
277
|
+
annotation.id === frame.payload.annotation.id ? frame.payload.annotation : annotation,
|
|
278
|
+
)
|
|
279
|
+
: [...snapshot.turnAnnotations, frame.payload.annotation];
|
|
280
|
+
return {
|
|
281
|
+
...snapshot,
|
|
282
|
+
turnAnnotations: nextAnnotations,
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
case WS_PRIMARY_PATH_TYPES.LABEL_CHANGED: {
|
|
286
|
+
if (
|
|
287
|
+
!frame.payload.targetId ||
|
|
288
|
+
!snapshot.primaryPathEntries.some((entry) => entry.id === frame.payload.targetId)
|
|
289
|
+
) {
|
|
290
|
+
return snapshot;
|
|
291
|
+
}
|
|
292
|
+
const nextLabels = { ...snapshot.labels };
|
|
293
|
+
if (frame.payload.label) {
|
|
294
|
+
nextLabels[frame.payload.targetId] = frame.payload.label;
|
|
295
|
+
} else {
|
|
296
|
+
delete nextLabels[frame.payload.targetId];
|
|
297
|
+
}
|
|
298
|
+
return {
|
|
299
|
+
...snapshot,
|
|
300
|
+
labels: nextLabels,
|
|
301
|
+
};
|
|
302
|
+
}
|
|
303
|
+
case WS_PRIMARY_PATH_TYPES.CHANGED:
|
|
304
|
+
return updateSemanticLeafRefs(snapshot, frame.payload.rootEntry, frame.payload.currentLeaf);
|
|
305
|
+
default:
|
|
306
|
+
return snapshot;
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
export function clonePrimaryPathSnapshot<TSnapshot extends PrimaryPathSnapshot>(
|
|
311
|
+
snapshot: TSnapshot,
|
|
312
|
+
): TSnapshot {
|
|
313
|
+
return {
|
|
314
|
+
...snapshot,
|
|
315
|
+
rebuiltAt: snapshot.rebuiltAt,
|
|
316
|
+
primaryPathEntries: snapshot.primaryPathEntries.map((entry) => ({ ...entry })),
|
|
317
|
+
semanticEntryRefs: { ...snapshot.semanticEntryRefs },
|
|
318
|
+
labels: { ...snapshot.labels },
|
|
319
|
+
turnAnnotations: snapshot.turnAnnotations.map((annotation) => ({
|
|
320
|
+
...annotation,
|
|
321
|
+
references: [...annotation.references],
|
|
322
|
+
payload: { ...annotation.payload },
|
|
323
|
+
})),
|
|
324
|
+
turnState: {
|
|
325
|
+
...snapshot.turnState,
|
|
326
|
+
activeTurn: snapshot.turnState.activeTurn
|
|
327
|
+
? {
|
|
328
|
+
...snapshot.turnState.activeTurn,
|
|
329
|
+
assistant: { ...snapshot.turnState.activeTurn.assistant },
|
|
330
|
+
toolCalls: cloneToolCalls(snapshot.turnState.activeTurn.toolCalls),
|
|
331
|
+
traceItems: cloneTraceItems(snapshot.turnState.activeTurn.traceItems),
|
|
332
|
+
usage: cloneTurnUsageSnapshot(snapshot.turnState.activeTurn.usage),
|
|
333
|
+
}
|
|
334
|
+
: null,
|
|
335
|
+
},
|
|
336
|
+
};
|
|
337
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import {
|
|
2
|
+
compareTimestampStrings,
|
|
3
|
+
type PrimaryPathSnapshot,
|
|
4
|
+
type PrimaryPathWsFrame,
|
|
5
|
+
} from "@leitwerk-dev/protocol";
|
|
6
|
+
import { applyPrimaryPathFrame, clonePrimaryPathSnapshot } from "./primary-path-detail.js";
|
|
7
|
+
|
|
8
|
+
export function shouldReplayPrimaryPathFrameAfterSnapshot(
|
|
9
|
+
frame: Pick<PrimaryPathWsFrame, "sentAt">,
|
|
10
|
+
snapshot: Pick<PrimaryPathSnapshot, "rebuiltAt">,
|
|
11
|
+
): boolean {
|
|
12
|
+
return compareTimestampStrings(frame.sentAt, snapshot.rebuiltAt) > 0;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export function replayPrimaryPathFramesAfterSnapshot<TSnapshot extends PrimaryPathSnapshot>(
|
|
16
|
+
snapshot: TSnapshot,
|
|
17
|
+
frames: readonly PrimaryPathWsFrame[],
|
|
18
|
+
): TSnapshot {
|
|
19
|
+
let nextSnapshot = clonePrimaryPathSnapshot(snapshot);
|
|
20
|
+
for (const frame of frames) {
|
|
21
|
+
if (!shouldReplayPrimaryPathFrameAfterSnapshot(frame, nextSnapshot)) {
|
|
22
|
+
continue;
|
|
23
|
+
}
|
|
24
|
+
nextSnapshot = applyPrimaryPathFrame(nextSnapshot, frame);
|
|
25
|
+
}
|
|
26
|
+
return nextSnapshot;
|
|
27
|
+
}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import type { ProcessLifecycleStatus } from "@leitwerk-dev/domain";
|
|
2
|
+
import type { ProcessBrowseItem, ProcessOverviewItem } from "@leitwerk-dev/protocol";
|
|
3
|
+
import * as v from "valibot";
|
|
4
|
+
import type { StorageLike } from "./browser-storage.js";
|
|
5
|
+
import { formatDefinition, formatStatus, formatTurnId } from "./format.js";
|
|
6
|
+
|
|
7
|
+
export const PROCESS_BROWSER_PAGE_SIZE = 100;
|
|
8
|
+
|
|
9
|
+
const processBrowserStatusFilterSchema = v.picklist([
|
|
10
|
+
"all",
|
|
11
|
+
"running",
|
|
12
|
+
"scheduled",
|
|
13
|
+
"needs_attention",
|
|
14
|
+
"completed",
|
|
15
|
+
"aborted",
|
|
16
|
+
]);
|
|
17
|
+
const processBrowserSortSchema = v.object({
|
|
18
|
+
key: v.picklist(["status", "title", "timeline"]),
|
|
19
|
+
direction: v.picklist(["asc", "desc"]),
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
export type ProcessBrowserStatusFilter = v.InferOutput<typeof processBrowserStatusFilterSchema>;
|
|
23
|
+
export type ProcessBrowserSort = v.InferOutput<typeof processBrowserSortSchema>;
|
|
24
|
+
export type ProcessBrowserSortKey = ProcessBrowserSort["key"];
|
|
25
|
+
|
|
26
|
+
export interface ProcessBrowserFilterState {
|
|
27
|
+
status: ProcessBrowserStatusFilter;
|
|
28
|
+
query: string;
|
|
29
|
+
processType: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const processBrowserViewSchema = v.object({
|
|
33
|
+
status: processBrowserStatusFilterSchema,
|
|
34
|
+
processType: v.pipe(v.string(), v.maxLength(200)),
|
|
35
|
+
sort: processBrowserSortSchema,
|
|
36
|
+
});
|
|
37
|
+
export type ProcessBrowserViewPreference = v.InferOutput<typeof processBrowserViewSchema>;
|
|
38
|
+
|
|
39
|
+
const PROCESS_BROWSER_VIEW_STORAGE_KEY = "leitwerk.process-browser-view.v1";
|
|
40
|
+
export const DEFAULT_PROCESS_BROWSER_VIEW: ProcessBrowserViewPreference = {
|
|
41
|
+
status: "all",
|
|
42
|
+
processType: "",
|
|
43
|
+
sort: { key: "timeline", direction: "desc" },
|
|
44
|
+
};
|
|
45
|
+
export const EMPTY_PROCESS_BROWSER_STATUS_COUNTS: Record<ProcessBrowserStatusFilter, number> = {
|
|
46
|
+
all: 0,
|
|
47
|
+
running: 0,
|
|
48
|
+
scheduled: 0,
|
|
49
|
+
needs_attention: 0,
|
|
50
|
+
completed: 0,
|
|
51
|
+
aborted: 0,
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
export function readProcessBrowserView(storage: StorageLike | null): ProcessBrowserViewPreference {
|
|
55
|
+
try {
|
|
56
|
+
const raw = storage?.getItem(PROCESS_BROWSER_VIEW_STORAGE_KEY);
|
|
57
|
+
const result = raw && v.safeParse(processBrowserViewSchema, JSON.parse(raw));
|
|
58
|
+
return result?.success ? result.output : DEFAULT_PROCESS_BROWSER_VIEW;
|
|
59
|
+
} catch {
|
|
60
|
+
return DEFAULT_PROCESS_BROWSER_VIEW;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export function writeProcessBrowserView(
|
|
65
|
+
storage: StorageLike | null,
|
|
66
|
+
preference: ProcessBrowserViewPreference,
|
|
67
|
+
): void {
|
|
68
|
+
try {
|
|
69
|
+
storage?.setItem(PROCESS_BROWSER_VIEW_STORAGE_KEY, JSON.stringify(preference));
|
|
70
|
+
} catch {
|
|
71
|
+
// Preferences must never block browsing.
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
interface ProcessBrowserItemBase {
|
|
76
|
+
id: string;
|
|
77
|
+
kind: "process" | "future";
|
|
78
|
+
title: string;
|
|
79
|
+
processId: string;
|
|
80
|
+
processDisplayName: string;
|
|
81
|
+
statusFilter: Exclude<ProcessBrowserStatusFilter, "all">;
|
|
82
|
+
statusDetail: string;
|
|
83
|
+
initialPrompt: string | null;
|
|
84
|
+
createdAt: string | null;
|
|
85
|
+
updatedAt: string | null;
|
|
86
|
+
sortAt: string | null;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export interface ProcessBrowserProcessItem extends ProcessBrowserItemBase {
|
|
90
|
+
kind: "process";
|
|
91
|
+
instanceId: string;
|
|
92
|
+
futureExecutionId: null;
|
|
93
|
+
lifecycleStatus: ProcessLifecycleStatus;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export interface ProcessBrowserFutureItem extends ProcessBrowserItemBase {
|
|
97
|
+
kind: "future";
|
|
98
|
+
instanceId: string | null;
|
|
99
|
+
futureExecutionId: string | null;
|
|
100
|
+
lifecycleStatus: null;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export type ProcessBrowserItem = ProcessBrowserProcessItem | ProcessBrowserFutureItem;
|
|
104
|
+
|
|
105
|
+
function statusFilterForProcess(
|
|
106
|
+
item: ProcessOverviewItem,
|
|
107
|
+
): Exclude<ProcessBrowserStatusFilter, "all"> {
|
|
108
|
+
if (item.lifecycleStatus === "completed" || item.lifecycleStatus === "aborted") {
|
|
109
|
+
return item.lifecycleStatus;
|
|
110
|
+
}
|
|
111
|
+
return item.lifecycleStatus === "error" || item.lifecycleStatus === "waiting"
|
|
112
|
+
? "needs_attention"
|
|
113
|
+
: "running";
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
function statusLine(item: ProcessOverviewItem): string {
|
|
117
|
+
const status = formatStatus(item.lifecycleStatus);
|
|
118
|
+
return item.selectedTurnId ? `${status} · ${formatTurnId(item.selectedTurnId)}` : status;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export function buildProcessBrowserItem(entry: ProcessBrowseItem): ProcessBrowserItem {
|
|
122
|
+
if (entry.kind === "process") {
|
|
123
|
+
const item = entry.item;
|
|
124
|
+
return {
|
|
125
|
+
id: item.instanceId,
|
|
126
|
+
kind: "process",
|
|
127
|
+
title: item.title,
|
|
128
|
+
processId: item.processId,
|
|
129
|
+
processDisplayName: item.processDisplayName?.trim() || formatDefinition(item.processId),
|
|
130
|
+
statusFilter: statusFilterForProcess(item),
|
|
131
|
+
statusDetail: statusLine(item),
|
|
132
|
+
initialPrompt: item.initialPromptPreview,
|
|
133
|
+
createdAt: item.createdAt,
|
|
134
|
+
updatedAt: item.updatedAt,
|
|
135
|
+
sortAt:
|
|
136
|
+
item.statusCategory === "terminal"
|
|
137
|
+
? (item.closedAt ?? item.updatedAt ?? item.createdAt)
|
|
138
|
+
: (item.updatedAt ?? item.createdAt),
|
|
139
|
+
instanceId: item.instanceId,
|
|
140
|
+
futureExecutionId: null,
|
|
141
|
+
lifecycleStatus: item.lifecycleStatus,
|
|
142
|
+
};
|
|
143
|
+
}
|
|
144
|
+
const item = entry.item;
|
|
145
|
+
return {
|
|
146
|
+
id: item.id,
|
|
147
|
+
kind: "future",
|
|
148
|
+
title: item.title,
|
|
149
|
+
processId: item.processId,
|
|
150
|
+
processDisplayName:
|
|
151
|
+
item.kind === "launch"
|
|
152
|
+
? item.launcherLabel || formatDefinition(item.processId)
|
|
153
|
+
: formatDefinition(item.processId),
|
|
154
|
+
statusFilter: "scheduled",
|
|
155
|
+
statusDetail:
|
|
156
|
+
item.kind === "action"
|
|
157
|
+
? `Scheduled action · ${item.actionLabel}`
|
|
158
|
+
: item.scheduleKind === "cron"
|
|
159
|
+
? "Recurring scheduled start"
|
|
160
|
+
: "Scheduled start",
|
|
161
|
+
initialPrompt: item.initialPromptPreview,
|
|
162
|
+
createdAt: null,
|
|
163
|
+
updatedAt: item.nextRunAt,
|
|
164
|
+
sortAt: item.nextRunAt,
|
|
165
|
+
instanceId: item.instanceId,
|
|
166
|
+
futureExecutionId: item.kind === "launch" ? item.id : null,
|
|
167
|
+
lifecycleStatus: null,
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
export function buildProcessBrowserItems(
|
|
172
|
+
entries: readonly ProcessBrowseItem[],
|
|
173
|
+
): ProcessBrowserItem[] {
|
|
174
|
+
return entries.map(buildProcessBrowserItem);
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export function hasActiveFilters(filters: ProcessBrowserFilterState): boolean {
|
|
178
|
+
return filters.status !== "all" || filters.query.trim() !== "" || filters.processType !== "";
|
|
179
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export interface ProcessLaunchNotice {
|
|
2
|
+
instanceId: string;
|
|
3
|
+
message: string;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
let currentNotice: ProcessLaunchNotice | null = null;
|
|
7
|
+
|
|
8
|
+
export function queueProcessLaunchNotice(notice: ProcessLaunchNotice): void {
|
|
9
|
+
currentNotice = notice;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export function consumeProcessLaunchNotice(instanceId: string): ProcessLaunchNotice | null {
|
|
13
|
+
if (!currentNotice || currentNotice.instanceId !== instanceId) {
|
|
14
|
+
return null;
|
|
15
|
+
}
|
|
16
|
+
const notice = currentNotice;
|
|
17
|
+
currentNotice = null;
|
|
18
|
+
return notice;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export function clearProcessLaunchNotice(instanceId?: string): void {
|
|
22
|
+
if (!instanceId || currentNotice?.instanceId === instanceId) {
|
|
23
|
+
currentNotice = null;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { type ProcessRowSlot, sortProcessRows } from "@leitwerk-dev/domain";
|
|
2
|
+
import type { ProcessOverviewItem } from "./api.js";
|
|
3
|
+
import { formatDefinition, formatStatus, formatTurnId } from "./format.js";
|
|
4
|
+
|
|
5
|
+
export interface ProcessRowView extends ProcessRowSlot {
|
|
6
|
+
processDisplayName: string;
|
|
7
|
+
statusLabel: string;
|
|
8
|
+
turnLabel: string | null;
|
|
9
|
+
statusLine: string;
|
|
10
|
+
createdAt: string;
|
|
11
|
+
updatedAt: string;
|
|
12
|
+
closedAt: string | null;
|
|
13
|
+
initialPrompt: string | null;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
function buildStatusLine(row: ProcessRowSlot): string {
|
|
17
|
+
const statusLabel = formatStatus(row.lifecycleStatus);
|
|
18
|
+
return row.selectedTurnId ? `${statusLabel} · ${formatTurnId(row.selectedTurnId)}` : statusLabel;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
function resolveProcessDisplayName(item: ProcessOverviewItem): string {
|
|
22
|
+
const processDisplayName = item.processDisplayName?.trim();
|
|
23
|
+
return processDisplayName || formatDefinition(item.processId);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export function buildProcessRowView(item: ProcessOverviewItem): ProcessRowView {
|
|
27
|
+
const row: ProcessRowSlot = item;
|
|
28
|
+
return {
|
|
29
|
+
...row,
|
|
30
|
+
processDisplayName: resolveProcessDisplayName(item),
|
|
31
|
+
statusLabel: formatStatus(row.lifecycleStatus),
|
|
32
|
+
turnLabel: row.selectedTurnId ? formatTurnId(row.selectedTurnId) : null,
|
|
33
|
+
statusLine: buildStatusLine(row),
|
|
34
|
+
createdAt: item.createdAt,
|
|
35
|
+
updatedAt: item.updatedAt,
|
|
36
|
+
closedAt: row.statusCategory === "terminal" ? item.closedAt : null,
|
|
37
|
+
initialPrompt: item.initialPromptPreview,
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
function closedAtTimestamp(row: ProcessRowView): number {
|
|
42
|
+
const timestamp = Date.parse(row.closedAt ?? "");
|
|
43
|
+
return Number.isFinite(timestamp) ? timestamp : Number.NEGATIVE_INFINITY;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
function compareTerminalRows(a: ProcessRowView, b: ProcessRowView): number {
|
|
47
|
+
return (
|
|
48
|
+
closedAtTimestamp(b) - closedAtTimestamp(a) ||
|
|
49
|
+
a.title.localeCompare(b.title) ||
|
|
50
|
+
a.instanceId.localeCompare(b.instanceId)
|
|
51
|
+
);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function sortProcessRowViews(rows: readonly ProcessRowView[]): ProcessRowView[] {
|
|
55
|
+
const sorted = sortProcessRows([...rows]) as ProcessRowView[];
|
|
56
|
+
return [
|
|
57
|
+
...sorted.filter((row) => row.statusCategory !== "terminal"),
|
|
58
|
+
...sorted.filter((row) => row.statusCategory === "terminal").sort(compareTerminalRows),
|
|
59
|
+
];
|
|
60
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export type ProcessTerminalStatus = "completed" | "aborted";
|
|
2
|
+
|
|
3
|
+
export function getProcessTerminalIcon(status: ProcessTerminalStatus): string {
|
|
4
|
+
return status === "completed" ? "✓" : "✕";
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export function getProcessTerminalHeading(status: ProcessTerminalStatus): string {
|
|
8
|
+
return status === "completed" ? "Completed" : "Aborted";
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export function getProcessTerminalRailTitle(status: ProcessTerminalStatus): string {
|
|
12
|
+
return getProcessTerminalHeading(status);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export function getProcessTerminalVerb(status: ProcessTerminalStatus): string {
|
|
16
|
+
return status === "completed" ? "Completed" : "Aborted";
|
|
17
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ProcessAttentionTarget } from "@leitwerk-dev/protocol";
|
|
2
|
+
import { writable } from "svelte/store";
|
|
3
|
+
|
|
4
|
+
export interface PendingProcessToastFocus {
|
|
5
|
+
instanceId: string;
|
|
6
|
+
target: ProcessAttentionTarget;
|
|
7
|
+
queuedAt: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export const pendingProcessToastFocusStore = writable<PendingProcessToastFocus | null>(null);
|
|
11
|
+
|
|
12
|
+
export function queuePendingProcessToastFocus(focus: PendingProcessToastFocus | null): void {
|
|
13
|
+
pendingProcessToastFocusStore.set(focus);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export function clearPendingProcessToastFocus(): void {
|
|
17
|
+
pendingProcessToastFocusStore.set(null);
|
|
18
|
+
}
|