@principal-ai/subsystems-react 0.28.2 → 0.28.4
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/subsystem/SubsystemComponentGraph.d.ts +7 -0
- package/dist/subsystem/SubsystemComponentGraph.d.ts.map +1 -1
- package/dist/subsystem/SubsystemComponentGraph.js +71 -9
- package/dist/subsystem/SubsystemComponentGraph.js.map +1 -1
- package/dist/subsystem/WalkthroughsPanel.d.ts +7 -1
- package/dist/subsystem/WalkthroughsPanel.d.ts.map +1 -1
- package/dist/subsystem/WalkthroughsPanel.js +68 -42
- package/dist/subsystem/WalkthroughsPanel.js.map +1 -1
- package/package.json +1 -1
- package/src/stories/Subsystem/ComponentGraph/ProposedWalkthroughs.stories.tsx +165 -0
- package/src/subsystem/SubsystemComponentGraph.tsx +98 -8
- package/src/subsystem/WalkthroughsPanel.tsx +85 -26
|
@@ -12,21 +12,25 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
|
|
|
12
12
|
*/
|
|
13
13
|
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
14
14
|
import { useTheme } from '@principal-ade/industry-theme';
|
|
15
|
-
import { GripVertical, Pause, Play
|
|
16
|
-
import { reorderTargetIndex, reorderWalkthroughs, walkthroughStepGraphEdgeId, } from './model';
|
|
15
|
+
import { ChevronDown, GripVertical, Pause, Play } from 'lucide-react';
|
|
16
|
+
import { PROPOSED_COLOR, reorderTargetIndex, reorderWalkthroughs, walkthroughStepGraphEdgeId, } from './model';
|
|
17
17
|
/** Pause (ms) between steps when a walkthrough autoplays. */
|
|
18
18
|
export const WALKTHROUGH_PLAY_PAUSE_MS = 2500;
|
|
19
19
|
/** One collapsible walkthrough in the sidebar's flows panel. Clicking the
|
|
20
|
-
* title: closed → open + select; open
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
|
|
20
|
+
* title: closed → open + select; open with a step selected → select the whole
|
|
21
|
+
* flow (deselect the step, stay open); open with the whole flow selected →
|
|
22
|
+
* close + clear focus. The right-aligned close button collapses without
|
|
23
|
+
* selecting. A step row focuses that step's edge. */
|
|
24
|
+
function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, onFocusFlow, onClearFocus, onFocusStep, onHoverStep, onHoverFlow, onLeaveStep, reorder, dragActive, isHoverSuppressed, proposedAliases, }) {
|
|
24
25
|
const { theme } = useTheme();
|
|
25
26
|
const muted = theme.colors.textMuted ?? theme.colors.textSecondary;
|
|
26
27
|
const hoverBg = theme.colors.background;
|
|
27
28
|
const wholeFlowActive = active !== null && active.stepIndex === null;
|
|
29
|
+
// A step is "proposed" when either endpoint is a proposed component.
|
|
30
|
+
const stepProposed = (from, to) => proposedAliases != null && (proposedAliases.has(from) || proposedAliases.has(to));
|
|
31
|
+
const touchesProposed = walkthrough.steps.some((s) => stepProposed(s.from, s.to));
|
|
28
32
|
const [headerHover, setHeaderHover] = useState(false);
|
|
29
|
-
const [
|
|
33
|
+
const [collapseHover, setCollapseHover] = useState(false);
|
|
30
34
|
const [playHover, setPlayHover] = useState(false);
|
|
31
35
|
const [gripHover, setGripHover] = useState(false);
|
|
32
36
|
const [hoveredStep, setHoveredStep] = useState(null);
|
|
@@ -49,7 +53,7 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
49
53
|
// drop. Reset every row's hover whenever a drag starts or ends.
|
|
50
54
|
useEffect(() => {
|
|
51
55
|
setHeaderHover(false);
|
|
52
|
-
|
|
56
|
+
setCollapseHover(false);
|
|
53
57
|
setPlayHover(false);
|
|
54
58
|
setGripHover(false);
|
|
55
59
|
setHoveredStep(null);
|
|
@@ -114,13 +118,16 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
114
118
|
onToggleCollapsed(walkthrough.id);
|
|
115
119
|
onFocusFlow(walkthrough);
|
|
116
120
|
}
|
|
117
|
-
else if (active === null) {
|
|
118
|
-
|
|
119
|
-
}
|
|
120
|
-
else {
|
|
121
|
+
else if (active !== null && active.stepIndex === null) {
|
|
122
|
+
// Whole flow already selected → collapse + clear.
|
|
121
123
|
onToggleCollapsed(walkthrough.id);
|
|
122
124
|
onClearFocus();
|
|
123
125
|
}
|
|
126
|
+
else {
|
|
127
|
+
// Expanded with nothing (or a step) selected → select the whole
|
|
128
|
+
// flow, which deselects any focused step without collapsing.
|
|
129
|
+
onFocusFlow(walkthrough);
|
|
130
|
+
}
|
|
124
131
|
}, style: {
|
|
125
132
|
flex: 1,
|
|
126
133
|
display: 'flex',
|
|
@@ -138,7 +145,7 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
138
145
|
fontSize: theme.fontSizes[1],
|
|
139
146
|
fontFamily: theme.fonts.monospace,
|
|
140
147
|
fontWeight: 600,
|
|
141
|
-
color: theme.colors.text,
|
|
148
|
+
color: touchesProposed ? PROPOSED_COLOR : theme.colors.text,
|
|
142
149
|
}, children: walkthrough.title }) }), !collapsed && (_jsxs(_Fragment, { children: [_jsx("button", { type: "button", "aria-label": playing ? `Pause ${walkthrough.title} autoplay` : `Play ${walkthrough.title}`, title: playing ? 'Pause' : 'Play through steps', onMouseEnter: () => setPlayHover(true), onMouseLeave: () => setPlayHover(false), onClick: (e) => {
|
|
143
150
|
e.stopPropagation();
|
|
144
151
|
togglePlay();
|
|
@@ -156,7 +163,7 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
156
163
|
color: playing || playHover ? theme.colors.text : muted,
|
|
157
164
|
cursor: 'pointer',
|
|
158
165
|
transition: 'background 120ms ease, color 120ms ease',
|
|
159
|
-
}, children: playing ? _jsx(Pause, { size: 12, strokeWidth: 2 }) : _jsx(Play, { size: 12, strokeWidth: 2 }) }), _jsx("button", { type: "button", "aria-label": `
|
|
166
|
+
}, children: playing ? _jsx(Pause, { size: 12, strokeWidth: 2 }) : _jsx(Play, { size: 12, strokeWidth: 2 }) }), _jsx("button", { type: "button", "aria-label": `Collapse ${walkthrough.title}`, title: "Collapse", onMouseEnter: () => setCollapseHover(true), onMouseLeave: () => setCollapseHover(false), onClick: (e) => {
|
|
160
167
|
e.stopPropagation();
|
|
161
168
|
onToggleCollapsed(walkthrough.id);
|
|
162
169
|
if (active !== null)
|
|
@@ -171,11 +178,11 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
171
178
|
padding: 0,
|
|
172
179
|
border: 'none',
|
|
173
180
|
borderRadius: 4,
|
|
174
|
-
background:
|
|
175
|
-
color:
|
|
181
|
+
background: collapseHover ? theme.colors.border : 'transparent',
|
|
182
|
+
color: collapseHover ? theme.colors.text : muted,
|
|
176
183
|
cursor: 'pointer',
|
|
177
184
|
transition: 'background 120ms ease, color 120ms ease',
|
|
178
|
-
}, children: _jsx(
|
|
185
|
+
}, children: _jsx(ChevronDown, { size: 14, strokeWidth: 2 }) })] })), reorder && (_jsx("span", { role: "button", tabIndex: -1, draggable: true, "aria-label": `Reorder ${walkthrough.title}`, title: "Drag to reorder", onMouseEnter: () => {
|
|
179
186
|
if (!isHoverSuppressed?.())
|
|
180
187
|
setGripHover(true);
|
|
181
188
|
}, onMouseLeave: () => setGripHover(false), onDragStart: (e) => reorder.onDragStart(reorder.index, e), onDragEnd: reorder.onDragEnd, onClick: (e) => e.stopPropagation(), style: {
|
|
@@ -192,9 +199,10 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
192
199
|
onLeaveStep();
|
|
193
200
|
}, children: walkthrough.steps.map((step, i) => {
|
|
194
201
|
const stepActive = active !== null && active.stepIndex === i;
|
|
202
|
+
const proposed = stepProposed(step.from, step.to);
|
|
195
203
|
return (_jsxs("button", { ref: (el) => {
|
|
196
204
|
stepButtonRefs.current[i] = el;
|
|
197
|
-
}, type: "button", onMouseEnter: () => {
|
|
205
|
+
}, type: "button", title: proposed ? 'Step touches a proposed component' : undefined, onMouseEnter: () => {
|
|
198
206
|
setHoveredStep(i);
|
|
199
207
|
onHoverStep(walkthrough, i);
|
|
200
208
|
}, onClick: () => onFocusStep(walkthrough, i), style: {
|
|
@@ -202,9 +210,9 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
202
210
|
alignItems: 'center',
|
|
203
211
|
gap: 8,
|
|
204
212
|
minWidth: 0,
|
|
205
|
-
padding: '8px 8px 8px
|
|
213
|
+
padding: '8px 8px 8px 17px',
|
|
206
214
|
textAlign: 'left',
|
|
207
|
-
borderRadius:
|
|
215
|
+
borderRadius: 0,
|
|
208
216
|
border: 'none',
|
|
209
217
|
outline: 'none',
|
|
210
218
|
background: stepActive || hoveredStep === i ? hoverBg : 'transparent',
|
|
@@ -215,7 +223,12 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
215
223
|
width: 14,
|
|
216
224
|
fontSize: theme.fontSizes[0],
|
|
217
225
|
fontFamily: theme.fonts.monospace,
|
|
218
|
-
|
|
226
|
+
fontWeight: proposed ? 700 : undefined,
|
|
227
|
+
color: proposed
|
|
228
|
+
? PROPOSED_COLOR
|
|
229
|
+
: stepActive
|
|
230
|
+
? theme.colors.text
|
|
231
|
+
: muted,
|
|
219
232
|
}, children: i + 1 }), _jsx("span", { style: {
|
|
220
233
|
flex: 1,
|
|
221
234
|
minWidth: 0,
|
|
@@ -224,7 +237,7 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
224
237
|
whiteSpace: 'nowrap',
|
|
225
238
|
fontSize: theme.fontSizes[1],
|
|
226
239
|
fontFamily: theme.fonts.monospace,
|
|
227
|
-
color: theme.colors.text,
|
|
240
|
+
color: proposed ? PROPOSED_COLOR : theme.colors.text,
|
|
228
241
|
}, children: step.symbol })] }, `${walkthroughStepGraphEdgeId(step)}-${i}`));
|
|
229
242
|
}) }))] }));
|
|
230
243
|
}
|
|
@@ -233,7 +246,7 @@ function WalkthroughFlow({ walkthrough, collapsed, active, onToggleCollapsed, on
|
|
|
233
246
|
* drag-reorderable. The host owns the array; a drop calls `onReorder` with the
|
|
234
247
|
* next order and the host re-renders with it.
|
|
235
248
|
*/
|
|
236
|
-
export function WalkthroughsPanel({ walkthroughs, expandedWalkthroughs, focusedWalkthroughId, focusedStepIndex, hoveredWalkthroughStep, onToggleCollapsed, onFocusFlow, onClearFocus, onFocusStep, onHoverStep, onHoverFlow, onLeaveStep, onReorder, }) {
|
|
249
|
+
export function WalkthroughsPanel({ walkthroughs, expandedWalkthroughs, focusedWalkthroughId, focusedStepIndex, hoveredWalkthroughStep, onToggleCollapsed, onFocusFlow, onClearFocus, onFocusStep, onHoverStep, onHoverFlow, onLeaveStep, onReorder, proposedAliases, }) {
|
|
237
250
|
const { theme } = useTheme();
|
|
238
251
|
// Reordering is offered only while every row is collapsed: the compact list
|
|
239
252
|
// is what you drag, and expanded step lists would make drop targets tall and
|
|
@@ -320,26 +333,39 @@ export function WalkthroughsPanel({ walkthroughs, expandedWalkthroughs, focusedW
|
|
|
320
333
|
const showBottom = reorderable &&
|
|
321
334
|
i === walkthroughs.length - 1 &&
|
|
322
335
|
dropBoundary === walkthroughs.length;
|
|
323
|
-
return (
|
|
336
|
+
return (_jsxs("div", { "data-walkthrough-row": tl.id, "data-reorder-index": i, onDragOver: reorderable ? (e) => handleDragOver(e, i) : undefined, onDrop: reorderable ? handleDrop : undefined, style: {
|
|
337
|
+
position: 'relative',
|
|
324
338
|
opacity: isDragging ? 0.45 : 1,
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
:
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
:
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
339
|
+
transition: 'opacity 120ms ease',
|
|
340
|
+
}, children: [i > 0 && (_jsx("div", { "aria-hidden": true, style: {
|
|
341
|
+
position: 'absolute',
|
|
342
|
+
top: 0,
|
|
343
|
+
left: 0,
|
|
344
|
+
right: 0,
|
|
345
|
+
height: 1,
|
|
346
|
+
background: theme.colors.border,
|
|
347
|
+
pointerEvents: 'none',
|
|
348
|
+
} })), (showTop || showBottom) && (_jsx("div", { "aria-hidden": true, style: {
|
|
349
|
+
position: 'absolute',
|
|
350
|
+
left: 0,
|
|
351
|
+
right: 0,
|
|
352
|
+
height: 2,
|
|
353
|
+
zIndex: 2,
|
|
354
|
+
background: accent,
|
|
355
|
+
pointerEvents: 'none',
|
|
356
|
+
...(showTop ? { top: 0 } : { bottom: 0 }),
|
|
357
|
+
} })), _jsx(WalkthroughFlow, { walkthrough: tl, collapsed: !expandedWalkthroughs.has(tl.id), active: focusedWalkthroughId === tl.id
|
|
358
|
+
? { stepIndex: focusedStepIndex }
|
|
359
|
+
: hoveredWalkthroughStep?.walkthroughId === tl.id
|
|
360
|
+
? { stepIndex: hoveredWalkthroughStep.stepIndex }
|
|
361
|
+
: null, onToggleCollapsed: onToggleCollapsed, onFocusFlow: onFocusFlow, onClearFocus: onClearFocus, onFocusStep: onFocusStep, onHoverStep: onHoverStep, onHoverFlow: onHoverFlow, onLeaveStep: onLeaveStep, reorder: reorderable
|
|
362
|
+
? {
|
|
363
|
+
index: i,
|
|
364
|
+
isDragging,
|
|
365
|
+
onDragStart: handleDragStart,
|
|
366
|
+
onDragEnd: resetDrag,
|
|
367
|
+
}
|
|
368
|
+
: undefined, dragActive: dragIndex != null, isHoverSuppressed: isHoverSuppressed, proposedAliases: proposedAliases })] }, tl.id));
|
|
343
369
|
}) }));
|
|
344
370
|
}
|
|
345
371
|
//# sourceMappingURL=WalkthroughsPanel.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WalkthroughsPanel.js","sourceRoot":"","sources":["../../src/subsystem/WalkthroughsPanel.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,WAAW,EAAE,SAA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AAU,EAAE,MAAM;4BAClB,aAAa,EAAE,MAAM;4BACrB,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;yBAC1C,GACD,CACH,EACD,KAAC,eAAe,IACd,WAAW,EAAE,EAAE,EACf,SAAS,EAAE,CAAC,oBAAoB,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,EAC3C,MAAM,EACJ,oBAAoB,KAAK,EAAE,CAAC,EAAE;4BAC5B,CAAC,CAAC,EAAE,SAAS,EAAE,gBAAgB,EAAE;4BACjC,CAAC,CAAC,sBAAsB,EAAE,aAAa,KAAK,EAAE,CAAC,EAAE;gCAC/C,CAAC,CAAC,EAAE,SAAS,EAAE,sBAAsB,CAAC,SAAS,EAAE;gCACjD,CAAC,CAAC,IAAI,EAEZ,iBAAiB,EAAE,iBAAiB,EACpC,WAAW,EAAE,WAAW,EACxB,YAAY,EAAE,YAAY,EAC1B,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,OAAO,EACL,WAAW;4BACT,CAAC,CAAC;gCACE,KAAK,EAAE,CAAC;gCACR,UAAU;gCACV,WAAW,EAAE,eAAe;gCAC5B,SAAS,EAAE,SAAS;6BACrB;4BACH,CAAC,CAAC,SAAS,EAEf,UAAU,EAAE,SAAS,IAAI,IAAI,EAC7B,iBAAiB,EAAE,iBAAiB,EACpC,eAAe,EAAE,eAAe,GAChC,KAxEG,EAAE,CAAC,EAAE,CAyEN,CACP,CAAC;QACJ,CAAC,CAAC,GACE,CACP,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import '@xyflow/react/dist/style.css';
|
|
3
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
4
|
+
import { ThemeProvider, defaultEditorTheme } from '@principal-ade/industry-theme';
|
|
5
|
+
import { SubsystemComponentGraph } from '../../../subsystem/SubsystemComponentGraph';
|
|
6
|
+
import type { SubsystemComponent, SubsystemWalkthrough } from '../../../subsystem/model';
|
|
7
|
+
|
|
8
|
+
const meta = {
|
|
9
|
+
title: 'Subsystem/ComponentGraph/ProposedWalkthroughs',
|
|
10
|
+
component: SubsystemComponentGraph,
|
|
11
|
+
parameters: {
|
|
12
|
+
layout: 'fullscreen',
|
|
13
|
+
},
|
|
14
|
+
tags: ['autodocs'],
|
|
15
|
+
decorators: [
|
|
16
|
+
(Story) => (
|
|
17
|
+
<ThemeProvider theme={defaultEditorTheme}>
|
|
18
|
+
<Story />
|
|
19
|
+
</ThemeProvider>
|
|
20
|
+
),
|
|
21
|
+
],
|
|
22
|
+
} satisfies Meta<typeof SubsystemComponentGraph>;
|
|
23
|
+
|
|
24
|
+
export default meta;
|
|
25
|
+
type Story = StoryObj<typeof meta>;
|
|
26
|
+
|
|
27
|
+
const PURL = 'pkg:github/principal-ai/subsystem-modeling';
|
|
28
|
+
|
|
29
|
+
const components: SubsystemComponent[] = [
|
|
30
|
+
{
|
|
31
|
+
alias: 'audit',
|
|
32
|
+
name: 'auditSubsystemModel',
|
|
33
|
+
construct: 'function',
|
|
34
|
+
file: 'src/bun/verify-subsystem-component.ts',
|
|
35
|
+
purl: PURL,
|
|
36
|
+
symbol: 'auditSubsystemModel',
|
|
37
|
+
purpose: 'Deterministic dry-run audit of a stored model',
|
|
38
|
+
role: 'entry',
|
|
39
|
+
process: 'studio/host',
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
alias: 'maintain',
|
|
43
|
+
name: 'runMaintainModel',
|
|
44
|
+
construct: 'function',
|
|
45
|
+
file: 'src/bun/maintain-model.ts',
|
|
46
|
+
purl: PURL,
|
|
47
|
+
symbol: 'runMaintainModel',
|
|
48
|
+
purpose: 'Existing maintain agent runner',
|
|
49
|
+
process: 'studio/host',
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
alias: 'lifecycle',
|
|
53
|
+
name: 'OpenCodeV2Lifecycle',
|
|
54
|
+
construct: 'function',
|
|
55
|
+
file: '',
|
|
56
|
+
purl: PURL,
|
|
57
|
+
symbol: 'OpenCodeV2Lifecycle',
|
|
58
|
+
purpose: 'Proposed Studio host: detect / install / update / ensure',
|
|
59
|
+
proposed: true,
|
|
60
|
+
process: 'studio/host',
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
alias: 'cache',
|
|
64
|
+
name: 'LifecycleProbeCache',
|
|
65
|
+
construct: 'store',
|
|
66
|
+
file: '',
|
|
67
|
+
purl: PURL,
|
|
68
|
+
symbol: 'LifecycleProbeCache',
|
|
69
|
+
purpose: 'Proposed cache of probe results',
|
|
70
|
+
proposed: true,
|
|
71
|
+
process: 'studio/host',
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
alias: 'cli',
|
|
75
|
+
name: '@opencode-ai/cli',
|
|
76
|
+
construct: 'external',
|
|
77
|
+
file: '',
|
|
78
|
+
purl: 'pkg:npm/@opencode-ai/cli@beta',
|
|
79
|
+
symbol: '',
|
|
80
|
+
purpose: 'Real external OpenCode CLI',
|
|
81
|
+
role: 'service',
|
|
82
|
+
},
|
|
83
|
+
];
|
|
84
|
+
|
|
85
|
+
const walkthroughs: SubsystemWalkthrough[] = [
|
|
86
|
+
{
|
|
87
|
+
id: 'wt-audit',
|
|
88
|
+
title: 'Audit a model',
|
|
89
|
+
steps: [
|
|
90
|
+
{
|
|
91
|
+
from: 'audit',
|
|
92
|
+
to: 'maintain',
|
|
93
|
+
mechanism: 'calls',
|
|
94
|
+
file: 'src/bun/verify-subsystem-component.ts',
|
|
95
|
+
line: 1,
|
|
96
|
+
symbol: 'auditSubsystemModel',
|
|
97
|
+
annotation: 'Live-only walkthrough — no proposed badge.',
|
|
98
|
+
},
|
|
99
|
+
],
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
id: 'wt-install',
|
|
103
|
+
title: 'Install OpenCode V2',
|
|
104
|
+
steps: [
|
|
105
|
+
{
|
|
106
|
+
from: 'audit',
|
|
107
|
+
to: 'maintain',
|
|
108
|
+
mechanism: 'calls',
|
|
109
|
+
file: 'src/bun/verify-subsystem-component.ts',
|
|
110
|
+
line: 1,
|
|
111
|
+
symbol: 'auditSubsystemModel',
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
from: 'maintain',
|
|
115
|
+
to: 'lifecycle',
|
|
116
|
+
mechanism: 'uses',
|
|
117
|
+
file: 'src/bun/maintain-model.ts',
|
|
118
|
+
line: 1,
|
|
119
|
+
symbol: 'runMaintainModel',
|
|
120
|
+
annotation: 'Hop onto the proposed lifecycle — step index is tinted.',
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
from: 'lifecycle',
|
|
124
|
+
to: 'cli',
|
|
125
|
+
mechanism: 'calls',
|
|
126
|
+
file: 'src/bun/maintain-model.ts',
|
|
127
|
+
line: 1,
|
|
128
|
+
symbol: 'OpenCodeV2Lifecycle.ensure',
|
|
129
|
+
},
|
|
130
|
+
],
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
id: 'wt-warm',
|
|
134
|
+
title: 'Warm the probe cache',
|
|
135
|
+
steps: [
|
|
136
|
+
{
|
|
137
|
+
from: 'lifecycle',
|
|
138
|
+
to: 'cache',
|
|
139
|
+
mechanism: 'writes',
|
|
140
|
+
file: 'src/bun/maintain-model.ts',
|
|
141
|
+
line: 1,
|
|
142
|
+
symbol: 'LifecycleProbeCache.set',
|
|
143
|
+
annotation: 'Both endpoints are proposed.',
|
|
144
|
+
},
|
|
145
|
+
],
|
|
146
|
+
},
|
|
147
|
+
];
|
|
148
|
+
|
|
149
|
+
function ProposedWalkthroughsDemo() {
|
|
150
|
+
return (
|
|
151
|
+
<div style={{ width: '100%', height: '100vh', display: 'flex', flexDirection: 'column' }}>
|
|
152
|
+
<SubsystemComponentGraph
|
|
153
|
+
components={components}
|
|
154
|
+
relations={[]}
|
|
155
|
+
walkthroughs={walkthroughs}
|
|
156
|
+
title="proposed-work marker"
|
|
157
|
+
description="Walkthroughs that touch a **proposed** component get their title tinted darkgoldenrod in the flows panel; expand a row and each hop onto a proposed component is tinted too (index and title). Nodes for proposed components already draw dashed darkgoldenrod on the canvas."
|
|
158
|
+
/>
|
|
159
|
+
</div>
|
|
160
|
+
);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export const ProposedWorkflows: Story = {
|
|
164
|
+
render: () => <ProposedWalkthroughsDemo />,
|
|
165
|
+
};
|
|
@@ -84,6 +84,48 @@ type DrawerTarget =
|
|
|
84
84
|
| { kind: 'file'; file: string; startLine?: number }
|
|
85
85
|
| { kind: 'walkthrough'; walkthroughId: string; stepIndex: number | null };
|
|
86
86
|
|
|
87
|
+
/**
|
|
88
|
+
* Per-model UI state persisted to `localStorage`, keyed by `persistKey`.
|
|
89
|
+
* Only the walkthrough working set is stored — which flows are expanded and
|
|
90
|
+
* which flow/step is selected — so tabbing away from a model and back lands
|
|
91
|
+
* you where you left off. Transient things (hover, drag, camera) are not saved.
|
|
92
|
+
*/
|
|
93
|
+
interface PersistedViewState {
|
|
94
|
+
expandedWalkthroughs?: string[];
|
|
95
|
+
focusedWalkthroughId?: string | null;
|
|
96
|
+
focusedStepIndex?: number | null;
|
|
97
|
+
sidebarWidth?: number;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
const VIEW_STATE_PREFIX = 'principal.subsystems.viewState.';
|
|
101
|
+
|
|
102
|
+
function readViewState(key: string | undefined): PersistedViewState {
|
|
103
|
+
if (!key || typeof window === 'undefined') return {};
|
|
104
|
+
try {
|
|
105
|
+
const raw = window.localStorage.getItem(VIEW_STATE_PREFIX + key);
|
|
106
|
+
if (!raw) return {};
|
|
107
|
+
const parsed: unknown = JSON.parse(raw);
|
|
108
|
+
return parsed && typeof parsed === 'object'
|
|
109
|
+
? (parsed as PersistedViewState)
|
|
110
|
+
: {};
|
|
111
|
+
} catch {
|
|
112
|
+
return {};
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
function writeViewState(
|
|
117
|
+
key: string | undefined,
|
|
118
|
+
patch: PersistedViewState,
|
|
119
|
+
): void {
|
|
120
|
+
if (!key || typeof window === 'undefined') return;
|
|
121
|
+
try {
|
|
122
|
+
const merged = { ...readViewState(key), ...patch };
|
|
123
|
+
window.localStorage.setItem(VIEW_STATE_PREFIX + key, JSON.stringify(merged));
|
|
124
|
+
} catch {
|
|
125
|
+
// Best-effort: private mode / quota — view state is non-critical.
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
|
|
87
129
|
export interface SubsystemComponentGraphProps {
|
|
88
130
|
components: SubsystemComponent[];
|
|
89
131
|
/** Topology relations (structural / module / type). Display edges are derived with walkthrough hops. */
|
|
@@ -232,6 +274,13 @@ export interface SubsystemComponentGraphProps {
|
|
|
232
274
|
onVerifyComponent?: (componentAlias: string) => void;
|
|
233
275
|
/** Live verification status for the selected component. */
|
|
234
276
|
componentVerification?: ComponentVerificationState | null;
|
|
277
|
+
/**
|
|
278
|
+
* When set, the graph's walkthrough working set — expanded flows and the
|
|
279
|
+
* selected flow/step — is persisted to `localStorage` under this key and
|
|
280
|
+
* restored on mount. Hosts key it by the model id so each model remembers
|
|
281
|
+
* where the user left off. Omit to keep the state purely in-memory.
|
|
282
|
+
*/
|
|
283
|
+
persistKey?: string;
|
|
235
284
|
}
|
|
236
285
|
|
|
237
286
|
const nodeTypes: NodeTypes = {
|
|
@@ -319,10 +368,13 @@ interface InnerProps extends SubsystemComponentGraphProps {
|
|
|
319
368
|
measured: { w: number; h: number } | null;
|
|
320
369
|
}
|
|
321
370
|
|
|
322
|
-
function Inner({ components, relations, walkthroughs, initialWalkthroughId, onReorderWalkthroughs, onSelect, onEdgeSelect, measured: _measured, maxNodeWidth, showEdgeLabels, edgeView, title, hideSidebar, walkthroughStepMode = 'focus', autoPlayWalkthroughs = false, walkthroughAutoPlayIntervalMs = WALKTHROUGH_PLAY_PAUSE_MS, zoomOnWalkthroughFocus = true, graphTitle, showWalkthroughTitle = false, description, canvasOverlay, sidebarExtra, sidebarAfterDescription, diagnostic, issues, showIssues, onSelectIssue, onApplyIssueFix, onHoverIssue, renderFileView, renderFileViewer, renderWalkthroughViewer, onFileSelect, onVerifyComponent, componentVerification }: InnerProps) {
|
|
371
|
+
function Inner({ components, relations, walkthroughs, initialWalkthroughId, onReorderWalkthroughs, onSelect, onEdgeSelect, measured: _measured, maxNodeWidth, showEdgeLabels, edgeView, title, hideSidebar, walkthroughStepMode = 'focus', autoPlayWalkthroughs = false, walkthroughAutoPlayIntervalMs = WALKTHROUGH_PLAY_PAUSE_MS, zoomOnWalkthroughFocus = true, graphTitle, showWalkthroughTitle = false, description, canvasOverlay, sidebarExtra, sidebarAfterDescription, diagnostic, issues, showIssues, onSelectIssue, onApplyIssueFix, onHoverIssue, renderFileView, renderFileViewer, renderWalkthroughViewer, onFileSelect, onVerifyComponent, componentVerification, persistKey }: InnerProps) {
|
|
323
372
|
const { theme } = useTheme();
|
|
324
373
|
const { fitView } = useReactFlow();
|
|
325
374
|
const viewport = useViewport();
|
|
375
|
+
// Restored once per mount from `localStorage` (see `readViewState`). Each
|
|
376
|
+
// graph is its own tab/mount, so `persistKey` is stable for a mount.
|
|
377
|
+
const persisted = useMemo(() => readViewState(persistKey), [persistKey]);
|
|
326
378
|
const graphEdges = useMemo(
|
|
327
379
|
() => deriveGraphEdges({ relations, walkthroughs }),
|
|
328
380
|
[relations, walkthroughs],
|
|
@@ -350,9 +402,14 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
350
402
|
const [hoveredComponentAlias, setHoveredComponentId] = useState<string | null>(null);
|
|
351
403
|
// Walkthrough focus — selected flow (or step) is full strength; other
|
|
352
404
|
// opened-flow members stay visible but dimmed; everything else is hidden.
|
|
353
|
-
|
|
405
|
+
// Restored from the persisted view state when a `persistKey` is set.
|
|
406
|
+
const [focusedWalkthroughId, setFocusedWalkthroughId] = useState<string | null>(
|
|
407
|
+
persisted.focusedWalkthroughId ?? null,
|
|
408
|
+
);
|
|
354
409
|
// `null` = whole flow focused; a number = that single step's edge focused.
|
|
355
|
-
const [focusedStepIndex, setFocusedStepIndex] = useState<number | null>(
|
|
410
|
+
const [focusedStepIndex, setFocusedStepIndex] = useState<number | null>(
|
|
411
|
+
persisted.focusedStepIndex ?? null,
|
|
412
|
+
);
|
|
356
413
|
// Hovered walkthrough in the flows panel: dims every canvas node/edge not
|
|
357
414
|
// involved in the hover preview (or selected ∪ hovered when a step is
|
|
358
415
|
// focused). `stepIndex: null` = whole flow (collapsed title hover);
|
|
@@ -381,7 +438,10 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
381
438
|
: 'relations');
|
|
382
439
|
// Walkthrough flows the user has expanded (via the title row). Closed by
|
|
383
440
|
// default so a graph with several flows doesn't dump every step list at once.
|
|
384
|
-
|
|
441
|
+
// Restored from the persisted view state when a `persistKey` is set.
|
|
442
|
+
const [expandedWalkthroughs, setExpandedWalkthroughs] = useState<Set<string>>(
|
|
443
|
+
() => new Set(persisted.expandedWalkthroughs ?? []),
|
|
444
|
+
);
|
|
385
445
|
// Sidebar description visibility. Hidden by default so the files/flows
|
|
386
446
|
// panel gets the vertical room; the title-row toggle reveals it.
|
|
387
447
|
const [descriptionVisible, setDescriptionVisible] = useState(false);
|
|
@@ -389,11 +449,16 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
389
449
|
// `true` only when a description exists AND the user opened it.
|
|
390
450
|
const showDesc = !!description && descriptionVisible;
|
|
391
451
|
// Sidebar width (px). Draggable via the resize handle between the sidebar
|
|
392
|
-
// and the graph canvas; clamps to sensible bounds while dragging.
|
|
393
|
-
|
|
452
|
+
// and the graph canvas; clamps to sensible bounds while dragging. Restored
|
|
453
|
+
// from the persisted view state when a `persistKey` is set.
|
|
454
|
+
const [sidebarWidth, setSidebarWidth] = useState(persisted.sidebarWidth ?? 450);
|
|
394
455
|
const [sidebarDrag, setSidebarDrag] = useState(false);
|
|
395
456
|
const sidebarDragStartX = useRef(0);
|
|
396
|
-
const sidebarDragStartWidth = useRef(
|
|
457
|
+
const sidebarDragStartWidth = useRef(450);
|
|
458
|
+
// Mirror of `sidebarWidth` for the drag-end persist (the mouseup listener
|
|
459
|
+
// closes over the drag-start render).
|
|
460
|
+
const sidebarWidthRef = useRef(sidebarWidth);
|
|
461
|
+
sidebarWidthRef.current = sidebarWidth;
|
|
397
462
|
const sidebarMinWidth = 240;
|
|
398
463
|
const sidebarMaxWidth = useMemo(
|
|
399
464
|
() => Math.max(Math.min((_measured?.w ?? 680) * 0.5, 600), sidebarMinWidth),
|
|
@@ -422,6 +487,8 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
422
487
|
};
|
|
423
488
|
const onUp = () => {
|
|
424
489
|
setSidebarDrag(false);
|
|
490
|
+
// Persist only on drag end — not on every mousemove.
|
|
491
|
+
writeViewState(persistKey, { sidebarWidth: sidebarWidthRef.current });
|
|
425
492
|
// Re-fit the canvas so the graph re-centers in the new available space.
|
|
426
493
|
requestAnimationFrame(() => fitView());
|
|
427
494
|
};
|
|
@@ -431,7 +498,23 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
431
498
|
document.removeEventListener('mousemove', onMove);
|
|
432
499
|
document.removeEventListener('mouseup', onUp);
|
|
433
500
|
};
|
|
434
|
-
}, [sidebarDrag, sidebarMaxWidth, fitView]);
|
|
501
|
+
}, [sidebarDrag, sidebarMaxWidth, fitView, persistKey]);
|
|
502
|
+
// Persist the walkthrough working set per model. Each write merges into the
|
|
503
|
+
// stored blob, so the three fields never clobber one another.
|
|
504
|
+
useEffect(() => {
|
|
505
|
+
if (!persistKey) return;
|
|
506
|
+
writeViewState(persistKey, {
|
|
507
|
+
expandedWalkthroughs: Array.from(expandedWalkthroughs),
|
|
508
|
+
});
|
|
509
|
+
}, [persistKey, expandedWalkthroughs]);
|
|
510
|
+
useEffect(() => {
|
|
511
|
+
if (!persistKey) return;
|
|
512
|
+
writeViewState(persistKey, { focusedWalkthroughId });
|
|
513
|
+
}, [persistKey, focusedWalkthroughId]);
|
|
514
|
+
useEffect(() => {
|
|
515
|
+
if (!persistKey) return;
|
|
516
|
+
writeViewState(persistKey, { focusedStepIndex });
|
|
517
|
+
}, [persistKey, focusedStepIndex]);
|
|
435
518
|
// Ref mirror of `selected` so the SUBSYSTEM_CALLBACKS click handler (a
|
|
436
519
|
// closure over the effect deps) can toggle without a stale value.
|
|
437
520
|
const selectedRef = useRef<SubsystemComponent | null>(null);
|
|
@@ -986,6 +1069,12 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
986
1069
|
// own owner-avatar header. Clicking a header collapses that repo's tree.
|
|
987
1070
|
const repoGroups = useMemo(() => buildRepoGroups(components), [components]);
|
|
988
1071
|
const hasWalkthroughs = useMemo(() => (walkthroughs?.length ?? 0) > 0, [walkthroughs]);
|
|
1072
|
+
// Aliases of proposed components — the flows panel tints walkthrough titles
|
|
1073
|
+
// (and steps) that touch one.
|
|
1074
|
+
const proposedAliases = useMemo(
|
|
1075
|
+
() => new Set(components.filter((c) => c.proposed).map((c) => c.alias)),
|
|
1076
|
+
[components],
|
|
1077
|
+
);
|
|
989
1078
|
// Diagnostics view in the sidebar. Uncontrolled unless the host pins
|
|
990
1079
|
// `showIssues`: the title-row chip toggles it, seeded from issues presence.
|
|
991
1080
|
const [diagnosticsOpen, setDiagnosticsOpen] = useState<boolean>(
|
|
@@ -1708,6 +1797,7 @@ function Inner({ components, relations, walkthroughs, initialWalkthroughId, onRe
|
|
|
1708
1797
|
}
|
|
1709
1798
|
onLeaveStep={() => setHoveredWalkthroughStep(null)}
|
|
1710
1799
|
onReorder={onReorderWalkthroughs}
|
|
1800
|
+
proposedAliases={proposedAliases}
|
|
1711
1801
|
/>
|
|
1712
1802
|
) : treeFilePaths.length > 0 ? (
|
|
1713
1803
|
<>
|