@principal-ai/subsystems-react 0.54.0 → 0.55.1
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/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/pierre/PierreTrailCodeView.d.ts +1 -1
- package/dist/pierre/PierreTrailCodeView.d.ts.map +1 -1
- package/dist/subsystem/ComponentDeclaration.d.ts +1 -1
- package/dist/subsystem/ComponentDeclaration.d.ts.map +1 -1
- package/dist/subsystem/ComponentDeclaration.js +1 -1
- package/dist/subsystem/ComponentDeclaration.js.map +1 -1
- package/dist/subsystem/ConstructsCatalog.d.ts +1 -1
- package/dist/subsystem/ConstructsCatalog.d.ts.map +1 -1
- package/dist/subsystem/IssueList.d.ts +4 -5
- package/dist/subsystem/IssueList.d.ts.map +1 -1
- package/dist/subsystem/IssueList.js +33 -28
- package/dist/subsystem/IssueList.js.map +1 -1
- package/dist/subsystem/SubsystemComponentGraph.d.ts +1 -1
- package/dist/subsystem/SubsystemComponentGraph.d.ts.map +1 -1
- package/dist/subsystem/SubsystemComponentGraph.js +6 -6
- package/dist/subsystem/SubsystemComponentGraph.js.map +1 -1
- package/dist/subsystem/SymbolInspectionCard.d.ts +1 -1
- package/dist/subsystem/SymbolInspectionCard.d.ts.map +1 -1
- package/dist/subsystem/SymbolInspectionCard.js +1 -1
- package/dist/subsystem/SymbolInspectionCard.js.map +1 -1
- package/dist/subsystem/TrailsPanel.d.ts.map +1 -1
- package/dist/subsystem/TrailsPanel.js +7 -1
- package/dist/subsystem/TrailsPanel.js.map +1 -1
- package/dist/subsystem/{declarationRef.d.ts → sourceSpan.d.ts} +1 -1
- package/dist/subsystem/sourceSpan.d.ts.map +1 -0
- package/dist/subsystem/{declarationRef.js → sourceSpan.js} +1 -1
- package/dist/subsystem/sourceSpan.js.map +1 -0
- package/package.json +1 -1
- package/src/index.ts +2 -2
- package/src/pierre/PierreTrailCodeView.tsx +1 -1
- package/src/stories/Subsystem/ComponentGraph/Constructs.stories.tsx +1 -1
- package/src/stories/Subsystem/ComponentGraph/DetailPanel.stories.tsx +1 -1
- package/src/stories/Subsystem/ComponentGraph/Issues.stories.tsx +21 -14
- package/src/stories/Subsystem/ComponentGraph/Trails.stories.tsx +77 -1
- package/src/stories/Subsystem/ConstructsCatalog.stories.tsx +1 -1
- package/src/stories/Subsystem/IssueIcons.stories.tsx +65 -0
- package/src/subsystem/ComponentDeclaration.tsx +2 -2
- package/src/subsystem/ConstructsCatalog.tsx +1 -1
- package/src/subsystem/IssueList.tsx +34 -29
- package/src/subsystem/SubsystemComponentGraph.tsx +9 -9
- package/src/subsystem/SymbolInspectionCard.tsx +2 -2
- package/src/subsystem/TrailsPanel.tsx +7 -1
- package/src/subsystem/{declarationRef.test.ts → sourceSpan.test.ts} +1 -1
- package/dist/subsystem/declarationRef.d.ts.map +0 -1
- package/dist/subsystem/declarationRef.js.map +0 -1
- /package/src/subsystem/{declarationRef.ts → sourceSpan.ts} +0 -0
|
@@ -55,7 +55,7 @@ import {
|
|
|
55
55
|
type SubsystemTrail,
|
|
56
56
|
} from './model';
|
|
57
57
|
import { ConstructsCatalog } from './ConstructsCatalog';
|
|
58
|
-
import type { SubsystemOpenFileOptions } from './
|
|
58
|
+
import type { SubsystemOpenFileOptions } from './sourceSpan';
|
|
59
59
|
import {
|
|
60
60
|
SubsystemAgentsPanel,
|
|
61
61
|
type SubsystemAgentsPanelProps,
|
|
@@ -893,7 +893,7 @@ function Inner({ components, trails, graphifyRelations, orderByLine, initialTrai
|
|
|
893
893
|
}, [drawerStepIndex, focusedTrail, visibleStepIndex]);
|
|
894
894
|
|
|
895
895
|
// Refresh selected component when the components list updates (e.g. verify
|
|
896
|
-
// writes back
|
|
896
|
+
// writes back declarationSpan).
|
|
897
897
|
useEffect(() => {
|
|
898
898
|
if (!selected) return;
|
|
899
899
|
const fresh = components.find((c) => c.alias === selected.alias);
|
|
@@ -902,7 +902,7 @@ function Inner({ components, trails, graphifyRelations, orderByLine, initialTrai
|
|
|
902
902
|
|
|
903
903
|
// Pass 1: build with estimated widths so React Flow can measure the DOM.
|
|
904
904
|
// The pane stays hidden until Pass 2 completes. Key off layout-affecting
|
|
905
|
-
// fields only —
|
|
905
|
+
// fields only — declarationSpan updates after verify must not re-run ELK.
|
|
906
906
|
const layoutKey = useMemo(
|
|
907
907
|
() => subsystemGraphLayoutKey({ components, trails, graphifyRelations }),
|
|
908
908
|
[components, trails, graphifyRelations],
|
|
@@ -1226,22 +1226,22 @@ function Inner({ components, trails, graphifyRelations, orderByLine, initialTrai
|
|
|
1226
1226
|
// Keyed by the React Flow edge id (from → mechanism → to). An edge can have
|
|
1227
1227
|
// multiple steps with issues; we show the worst status (stale > unconfirmed).
|
|
1228
1228
|
const stepIssueBadgeByEdgeId = useMemo(() => {
|
|
1229
|
-
const map = new Map<string, { kind: '
|
|
1229
|
+
const map = new Map<string, { kind: 'step_span_unconfirmed' | 'step_span_stale'; severity: 'info' | 'error'; count: number }>();
|
|
1230
1230
|
if (!issues?.length || !trails?.length) {
|
|
1231
1231
|
return map;
|
|
1232
1232
|
}
|
|
1233
1233
|
for (const issue of issues) {
|
|
1234
|
-
if (issue.kind !== '
|
|
1234
|
+
if (issue.kind !== 'step_span_unconfirmed' && issue.kind !== 'step_span_stale') continue;
|
|
1235
1235
|
const stepInfo = issueStep(issue);
|
|
1236
1236
|
if (!stepInfo) continue;
|
|
1237
1237
|
const step = stepInfo.trail.steps[stepInfo.stepIndex];
|
|
1238
1238
|
if (!step) continue;
|
|
1239
1239
|
const edgeId = trailStepGraphEdgeId(step);
|
|
1240
1240
|
const prev = map.get(edgeId);
|
|
1241
|
-
//
|
|
1242
|
-
const isWorse = issue.kind === '
|
|
1241
|
+
// step_span_stale is worse than step_span_unconfirmed
|
|
1242
|
+
const isWorse = issue.kind === 'step_span_stale' && prev?.kind !== 'step_span_stale';
|
|
1243
1243
|
map.set(edgeId, {
|
|
1244
|
-
kind: isWorse || !prev ? issue.kind as '
|
|
1244
|
+
kind: isWorse || !prev ? issue.kind as 'step_span_unconfirmed' | 'step_span_stale' : prev.kind,
|
|
1245
1245
|
severity: prev?.severity === 'error' || issue.severity === 'error' ? 'error' : 'info',
|
|
1246
1246
|
count: (prev?.count ?? 0) + 1,
|
|
1247
1247
|
});
|
|
@@ -2994,7 +2994,7 @@ function Inner({ components, trails, graphifyRelations, orderByLine, initialTrai
|
|
|
2994
2994
|
return (
|
|
2995
2995
|
<span
|
|
2996
2996
|
aria-hidden
|
|
2997
|
-
title={lbl.stepIssue.kind === '
|
|
2997
|
+
title={lbl.stepIssue.kind === 'step_span_stale'
|
|
2998
2998
|
? 'Call site changed since verification'
|
|
2999
2999
|
: 'Call site not yet verified'}
|
|
3000
3000
|
style={{
|
|
@@ -15,8 +15,8 @@ import { ExternalLink } from 'lucide-react';
|
|
|
15
15
|
import { useTheme } from '@principal-ade/industry-theme';
|
|
16
16
|
import { resolvePierreSyntaxThemeName } from '../pierre/pierreSyntaxTheme';
|
|
17
17
|
import { sourceLangForPath, type SourceSyntaxLang } from '../pierre/sourceLang';
|
|
18
|
-
import type { SubsystemOpenFileOptions } from './
|
|
19
|
-
import { parseSourceLocation } from './
|
|
18
|
+
import type { SubsystemOpenFileOptions } from './sourceSpan';
|
|
19
|
+
import { parseSourceLocation } from './sourceSpan';
|
|
20
20
|
import { generateDeclarationString } from './formatDeclaration';
|
|
21
21
|
import type {
|
|
22
22
|
SubsystemComponent,
|
|
@@ -250,7 +250,13 @@ function TrailFlow({
|
|
|
250
250
|
display: 'flex',
|
|
251
251
|
alignItems: 'center',
|
|
252
252
|
minWidth: 0,
|
|
253
|
-
padding:
|
|
253
|
+
// Vertical padding, not just the row's min-height: a title that
|
|
254
|
+
// wraps to two+ lines must grow the header past `minHeight`, and
|
|
255
|
+
// without this the text sits flush against the row's top and bottom
|
|
256
|
+
// edges (the controls stretch to the text height). 6px keeps a
|
|
257
|
+
// one-line title under `TRAIL_CONTROL_SIZE`, so single-line rows
|
|
258
|
+
// stay 34px.
|
|
259
|
+
padding: '6px 0',
|
|
254
260
|
border: 'none',
|
|
255
261
|
background: 'transparent',
|
|
256
262
|
textAlign: 'left',
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"declarationRef.d.ts","sourceRoot":"","sources":["../../src/subsystem/declarationRef.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AAEzE,YAAY,EAAE,mBAAmB,EAAE,CAAC;AAEpC;;;;;;;;GAQG;AACH,MAAM,MAAM,aAAa,GACrB,MAAM,GACN,OAAO,GACP,SAAS,GACT,YAAY,GACZ,WAAW,CAAC;AAEhB,eAAO,MAAM,qBAAqB,MAAgB,CAAC;AAEnD,wEAAwE;AACxE,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,GAAG,MAAM,GAAG,IAAI,CAMjF;AAED,wDAAwD;AACxD,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAE7D;AAED,0EAA0E;AAC1E,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAKzF;AAED,iEAAiE;AACjE,MAAM,WAAW,wBAAwB;IACvC,4EAA4E;IAC5E,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"declarationRef.js","sourceRoot":"","sources":["../../src/subsystem/declarationRef.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAsBH,MAAM,CAAC,MAAM,qBAAqB,GAAG,IAAa,CAAC;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