yadflow 2.6.0 → 2.7.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/CHANGELOG.md +4 -7
- package/README.md +23 -2
- package/bin/yad.mjs +22 -1
- package/cli/docs.mjs +298 -0
- package/cli/manifest.mjs +6 -1
- package/docs/index.html +4 -4
- package/package.json +2 -2
- package/skills/sdlc/config.yaml +19 -0
- package/skills/sdlc/install.sh +1 -1
- package/skills/sdlc/module-help.csv +4 -0
- package/skills/yad-connect-docs/SKILL.md +132 -0
- package/skills/yad-connect-docs/references/docs-registry.md +74 -0
- package/skills/yad-docs/SKILL.md +159 -0
- package/skills/yad-docs/references/data-mapping.md +75 -0
- package/skills/yad-docs/references/theme-map.md +69 -0
- package/skills/yad-docs/templates/app/README.md +31 -0
- package/skills/yad-docs/templates/app/eslint.config.js +23 -0
- package/skills/yad-docs/templates/app/index.html +17 -0
- package/skills/yad-docs/templates/app/package-lock.json +4030 -0
- package/skills/yad-docs/templates/app/package.json +35 -0
- package/skills/yad-docs/templates/app/public/favicon.svg +28 -0
- package/skills/yad-docs/templates/app/public/logo.svg +39 -0
- package/skills/yad-docs/templates/app/public/vite.svg +1 -0
- package/skills/yad-docs/templates/app/src/App.tsx +98 -0
- package/skills/yad-docs/templates/app/src/components/Auth/LoginPage.tsx +101 -0
- package/skills/yad-docs/templates/app/src/components/Canvas/AnimatedMessage.tsx +101 -0
- package/skills/yad-docs/templates/app/src/components/Canvas/ConnectionLine.tsx +90 -0
- package/skills/yad-docs/templates/app/src/components/Canvas/FlowCanvas.tsx +216 -0
- package/skills/yad-docs/templates/app/src/components/Canvas/SystemComponent.tsx +153 -0
- package/skills/yad-docs/templates/app/src/components/Controls/PlaybackBar.tsx +284 -0
- package/skills/yad-docs/templates/app/src/components/Controls/StepDetail.tsx +167 -0
- package/skills/yad-docs/templates/app/src/components/DetailPanel/HandlerLogicSnippet.tsx +41 -0
- package/skills/yad-docs/templates/app/src/components/DetailPanel/RequestPayloadPreview.tsx +46 -0
- package/skills/yad-docs/templates/app/src/components/DetailPanel/RightPanel.tsx +88 -0
- package/skills/yad-docs/templates/app/src/components/DetailPanel/StatusCard.tsx +76 -0
- package/skills/yad-docs/templates/app/src/components/DetailPanel/TriggerEventCard.tsx +45 -0
- package/skills/yad-docs/templates/app/src/components/DocLayout/DocPageShell.tsx +80 -0
- package/skills/yad-docs/templates/app/src/components/DocLayout/DocSectionCard.tsx +55 -0
- package/skills/yad-docs/templates/app/src/components/DocLayout/DocTableOfContents.tsx +79 -0
- package/skills/yad-docs/templates/app/src/components/DocLayout/RoleCard.tsx +67 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/ApiReferenceSection.tsx +108 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/CancelabilitySection.tsx +73 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/CriticalRunbookSection.tsx +177 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/DataMigrationSection.tsx +102 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/DbSchemaSection.tsx +98 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/DeploymentGuideSection.tsx +104 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/DriverIntegrationSection.tsx +127 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/ExecutiveSummarySection.tsx +69 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/FlowOverviewSection.tsx +73 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/FlowPathsChecklistSection.tsx +96 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/MiddlewareChainSection.tsx +107 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/MonitoringAlertingSection.tsx +106 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/NotificationLocalizationSection.tsx +102 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/PMRoadmapSection.tsx +133 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/PerformanceTestingSection.tsx +91 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/RiderIntegrationSection.tsx +99 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/SecuritySection.tsx +74 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/StatusMachineSection.tsx +90 -0
- package/skills/yad-docs/templates/app/src/components/DocSections/TestPlanSection.tsx +163 -0
- package/skills/yad-docs/templates/app/src/components/Logs/SystemLogsTerminal.tsx +126 -0
- package/skills/yad-docs/templates/app/src/components/Navigation/TopNavBar.tsx +90 -0
- package/skills/yad-docs/templates/app/src/components/Reference/BullMQJobsList.tsx +60 -0
- package/skills/yad-docs/templates/app/src/components/Reference/DecisionTreeView.tsx +49 -0
- package/skills/yad-docs/templates/app/src/components/Reference/DeeplinkActionsChips.tsx +69 -0
- package/skills/yad-docs/templates/app/src/components/Reference/DriverUIStatesTable.tsx +61 -0
- package/skills/yad-docs/templates/app/src/components/Reference/FeatureFlagMatrix.tsx +73 -0
- package/skills/yad-docs/templates/app/src/components/Reference/RiderUIStatesTable.tsx +61 -0
- package/skills/yad-docs/templates/app/src/components/Reference/RulesLegendPanel.tsx +217 -0
- package/skills/yad-docs/templates/app/src/components/Reference/StakeholderToggle.tsx +41 -0
- package/skills/yad-docs/templates/app/src/components/Reference/TroubleshootingSection.tsx +93 -0
- package/skills/yad-docs/templates/app/src/components/Sidebar/PathSelector.tsx +148 -0
- package/skills/yad-docs/templates/app/src/components/Sidebar/SidebarFooter.tsx +40 -0
- package/skills/yad-docs/templates/app/src/components/Sidebar/StepList.tsx +234 -0
- package/skills/yad-docs/templates/app/src/components/shared/Badge.tsx +28 -0
- package/skills/yad-docs/templates/app/src/components/shared/CommandPalette.tsx +213 -0
- package/skills/yad-docs/templates/app/src/components/shared/Icon.tsx +21 -0
- package/skills/yad-docs/templates/app/src/components/shared/Tooltip.tsx +42 -0
- package/skills/yad-docs/templates/app/src/data/components.ts +74 -0
- package/skills/yad-docs/templates/app/src/data/docSections.ts +231 -0
- package/skills/yad-docs/templates/app/src/data/paths.ts +2319 -0
- package/skills/yad-docs/templates/app/src/data/referenceData.ts +392 -0
- package/skills/yad-docs/templates/app/src/data/roles.ts +145 -0
- package/skills/yad-docs/templates/app/src/data/types.ts +79 -0
- package/skills/yad-docs/templates/app/src/hooks/useAnimationQueue.ts +41 -0
- package/skills/yad-docs/templates/app/src/hooks/usePlayback.ts +100 -0
- package/skills/yad-docs/templates/app/src/hooks/useStakeholderFilter.ts +10 -0
- package/skills/yad-docs/templates/app/src/index.css +121 -0
- package/skills/yad-docs/templates/app/src/main.tsx +13 -0
- package/skills/yad-docs/templates/app/src/pages/RoleSelectPage.tsx +34 -0
- package/skills/yad-docs/templates/app/src/pages/StakeholderDocPage.tsx +98 -0
- package/skills/yad-docs/templates/app/src/pages/SubPathDetailPage.tsx +282 -0
- package/skills/yad-docs/templates/app/src/store/useAuthStore.ts +42 -0
- package/skills/yad-docs/templates/app/src/store/useFlowStore.ts +197 -0
- package/skills/yad-docs/templates/app/src/utils/iconMap.ts +46 -0
- package/skills/yad-docs/templates/app/tsconfig.app.json +28 -0
- package/skills/yad-docs/templates/app/tsconfig.json +7 -0
- package/skills/yad-docs/templates/app/tsconfig.node.json +26 -0
- package/skills/yad-docs/templates/app/vite.config.ts +10 -0
- package/skills/yad-docs-overview/SKILL.md +129 -0
- package/skills/yad-docs-overview/references/pipeline-model.md +102 -0
- package/skills/yad-docs-sync/SKILL.md +99 -0
- package/skills/yad-docs-sync/references/staleness.md +81 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { create } from 'zustand';
|
|
2
|
+
|
|
3
|
+
// Login gate — presentational ONLY, never a security control (real access control is the
|
|
4
|
+
// repo / Pages ACL). `yad docs` sets DOCS_REQUIRE_LOGIN to `false` by default for public docs;
|
|
5
|
+
// teams publishing to a private Pages site can flip it to `true` (login_gate: true) and set
|
|
6
|
+
// credentials via the Vite env vars VITE_DOCS_USER / VITE_DOCS_PASS at build time.
|
|
7
|
+
const DOCS_REQUIRE_LOGIN = false;
|
|
8
|
+
const CREDENTIALS = {
|
|
9
|
+
username: import.meta.env.VITE_DOCS_USER ?? 'docs',
|
|
10
|
+
password: import.meta.env.VITE_DOCS_PASS ?? 'docs',
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
interface AuthStore {
|
|
14
|
+
isAuthenticated: boolean;
|
|
15
|
+
username: string | null;
|
|
16
|
+
error: string | null;
|
|
17
|
+
login: (username: string, password: string) => boolean;
|
|
18
|
+
logout: () => void;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export const useAuthStore = create<AuthStore>((set) => ({
|
|
22
|
+
isAuthenticated: !DOCS_REQUIRE_LOGIN || sessionStorage.getItem('auth') === 'true',
|
|
23
|
+
username: sessionStorage.getItem('auth_user'),
|
|
24
|
+
error: null,
|
|
25
|
+
|
|
26
|
+
login: (username, password) => {
|
|
27
|
+
if (username === CREDENTIALS.username && password === CREDENTIALS.password) {
|
|
28
|
+
sessionStorage.setItem('auth', 'true');
|
|
29
|
+
sessionStorage.setItem('auth_user', username);
|
|
30
|
+
set({ isAuthenticated: true, username, error: null });
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
set({ error: 'Invalid username or password' });
|
|
34
|
+
return false;
|
|
35
|
+
},
|
|
36
|
+
|
|
37
|
+
logout: () => {
|
|
38
|
+
sessionStorage.removeItem('auth');
|
|
39
|
+
sessionStorage.removeItem('auth_user');
|
|
40
|
+
set({ isAuthenticated: false, username: null, error: null });
|
|
41
|
+
},
|
|
42
|
+
}));
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
import { create } from "zustand";
|
|
2
|
+
import type { FlowPath, FlowStep, PlaybackState, StakeholderView } from "../data/types";
|
|
3
|
+
import { PATHS } from "../data/paths";
|
|
4
|
+
|
|
5
|
+
export interface LogEntry {
|
|
6
|
+
id: string;
|
|
7
|
+
timestamp: Date;
|
|
8
|
+
level: 'info' | 'warn' | 'error' | 'debug';
|
|
9
|
+
source: string;
|
|
10
|
+
message: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
interface FlowStore {
|
|
14
|
+
selectedPath: FlowPath;
|
|
15
|
+
activeSubPathId: string | null;
|
|
16
|
+
activeStepIndex: number;
|
|
17
|
+
playbackState: PlaybackState;
|
|
18
|
+
speed: number;
|
|
19
|
+
animatingMessages: boolean;
|
|
20
|
+
|
|
21
|
+
// Stakeholder
|
|
22
|
+
stakeholderView: StakeholderView;
|
|
23
|
+
|
|
24
|
+
// UI panels
|
|
25
|
+
zoomLevel: number;
|
|
26
|
+
isReferencePanelOpen: boolean;
|
|
27
|
+
isCommandPaletteOpen: boolean;
|
|
28
|
+
isLogsPanelOpen: boolean;
|
|
29
|
+
|
|
30
|
+
// Logs
|
|
31
|
+
logs: LogEntry[];
|
|
32
|
+
|
|
33
|
+
// Timer
|
|
34
|
+
elapsedTime: number;
|
|
35
|
+
|
|
36
|
+
selectPath: (pathId: number) => void;
|
|
37
|
+
selectSubPath: (subPathId: string) => void;
|
|
38
|
+
setActiveStep: (index: number) => void;
|
|
39
|
+
nextStep: () => void;
|
|
40
|
+
prevStep: () => void;
|
|
41
|
+
play: () => void;
|
|
42
|
+
pause: () => void;
|
|
43
|
+
stop: () => void;
|
|
44
|
+
setSpeed: (speed: number) => void;
|
|
45
|
+
setAnimatingMessages: (val: boolean) => void;
|
|
46
|
+
|
|
47
|
+
// Stakeholder
|
|
48
|
+
setStakeholderView: (view: StakeholderView) => void;
|
|
49
|
+
|
|
50
|
+
// Zoom
|
|
51
|
+
setZoomLevel: (level: number) => void;
|
|
52
|
+
zoomIn: () => void;
|
|
53
|
+
zoomOut: () => void;
|
|
54
|
+
resetZoom: () => void;
|
|
55
|
+
|
|
56
|
+
// Panels
|
|
57
|
+
toggleReferencePanel: () => void;
|
|
58
|
+
toggleCommandPalette: () => void;
|
|
59
|
+
toggleLogsPanel: () => void;
|
|
60
|
+
|
|
61
|
+
// Logs
|
|
62
|
+
addLog: (entry: Omit<LogEntry, 'id' | 'timestamp'>) => void;
|
|
63
|
+
clearLogs: () => void;
|
|
64
|
+
|
|
65
|
+
// Timer
|
|
66
|
+
tickElapsed: () => void;
|
|
67
|
+
resetElapsed: () => void;
|
|
68
|
+
|
|
69
|
+
// Replay
|
|
70
|
+
replayStep: () => void;
|
|
71
|
+
|
|
72
|
+
getCurrentSteps: () => FlowStep[];
|
|
73
|
+
getCurrentStep: () => FlowStep | null;
|
|
74
|
+
getTotalSteps: () => number;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
let logCounter = 0;
|
|
78
|
+
|
|
79
|
+
export const useFlowStore = create<FlowStore>((set, get) => ({
|
|
80
|
+
selectedPath: PATHS[0],
|
|
81
|
+
activeSubPathId: null,
|
|
82
|
+
activeStepIndex: 0,
|
|
83
|
+
playbackState: "idle",
|
|
84
|
+
speed: 1,
|
|
85
|
+
animatingMessages: false,
|
|
86
|
+
|
|
87
|
+
stakeholderView: 'rider-mobile-dev' as StakeholderView,
|
|
88
|
+
|
|
89
|
+
zoomLevel: 1,
|
|
90
|
+
isReferencePanelOpen: false,
|
|
91
|
+
isCommandPaletteOpen: false,
|
|
92
|
+
isLogsPanelOpen: false,
|
|
93
|
+
logs: [],
|
|
94
|
+
elapsedTime: 0,
|
|
95
|
+
|
|
96
|
+
selectPath: (pathId: number) => {
|
|
97
|
+
const path = PATHS.find((p) => p.id === pathId) || PATHS[0];
|
|
98
|
+
const hasSubPaths = path.subPaths && path.subPaths.length > 0;
|
|
99
|
+
set({
|
|
100
|
+
selectedPath: path,
|
|
101
|
+
activeStepIndex: 0,
|
|
102
|
+
playbackState: "idle",
|
|
103
|
+
animatingMessages: false,
|
|
104
|
+
activeSubPathId: hasSubPaths ? path.subPaths![0].id : null,
|
|
105
|
+
});
|
|
106
|
+
},
|
|
107
|
+
|
|
108
|
+
selectSubPath: (subPathId: string) => {
|
|
109
|
+
set({
|
|
110
|
+
activeSubPathId: subPathId,
|
|
111
|
+
activeStepIndex: 0,
|
|
112
|
+
playbackState: "idle",
|
|
113
|
+
animatingMessages: false,
|
|
114
|
+
});
|
|
115
|
+
},
|
|
116
|
+
|
|
117
|
+
setActiveStep: (index: number) => {
|
|
118
|
+
const steps = get().getCurrentSteps();
|
|
119
|
+
if (index >= 0 && index < steps.length) {
|
|
120
|
+
set({ activeStepIndex: index, animatingMessages: false });
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
|
|
124
|
+
nextStep: () => {
|
|
125
|
+
const { activeStepIndex, getCurrentSteps } = get();
|
|
126
|
+
const steps = getCurrentSteps();
|
|
127
|
+
if (activeStepIndex < steps.length - 1) {
|
|
128
|
+
set({ activeStepIndex: activeStepIndex + 1, animatingMessages: false });
|
|
129
|
+
} else {
|
|
130
|
+
set({ playbackState: "idle" });
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
|
|
134
|
+
prevStep: () => {
|
|
135
|
+
const { activeStepIndex } = get();
|
|
136
|
+
if (activeStepIndex > 0) {
|
|
137
|
+
set({ activeStepIndex: activeStepIndex - 1, animatingMessages: false });
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
|
|
141
|
+
play: () => set({ playbackState: "playing" }),
|
|
142
|
+
pause: () => set({ playbackState: "paused" }),
|
|
143
|
+
stop: () => set({ playbackState: "idle", activeStepIndex: 0, animatingMessages: false }),
|
|
144
|
+
setSpeed: (speed: number) => set({ speed }),
|
|
145
|
+
setAnimatingMessages: (val: boolean) => set({ animatingMessages: val }),
|
|
146
|
+
|
|
147
|
+
// Stakeholder
|
|
148
|
+
setStakeholderView: (view) => set({ stakeholderView: view }),
|
|
149
|
+
|
|
150
|
+
// Zoom
|
|
151
|
+
setZoomLevel: (level: number) => set({ zoomLevel: Math.max(0.5, Math.min(2, level)) }),
|
|
152
|
+
zoomIn: () => set((s) => ({ zoomLevel: Math.min(2, s.zoomLevel + 0.1) })),
|
|
153
|
+
zoomOut: () => set((s) => ({ zoomLevel: Math.max(0.5, s.zoomLevel - 0.1) })),
|
|
154
|
+
resetZoom: () => set({ zoomLevel: 1 }),
|
|
155
|
+
|
|
156
|
+
// Panels
|
|
157
|
+
toggleReferencePanel: () => set((s) => ({ isReferencePanelOpen: !s.isReferencePanelOpen })),
|
|
158
|
+
toggleCommandPalette: () => set((s) => ({ isCommandPaletteOpen: !s.isCommandPaletteOpen })),
|
|
159
|
+
toggleLogsPanel: () => set((s) => ({ isLogsPanelOpen: !s.isLogsPanelOpen })),
|
|
160
|
+
|
|
161
|
+
// Logs
|
|
162
|
+
addLog: (entry) => {
|
|
163
|
+
logCounter++;
|
|
164
|
+
set((s) => ({
|
|
165
|
+
logs: [...s.logs.slice(-200), { ...entry, id: `log-${logCounter}`, timestamp: new Date() }],
|
|
166
|
+
}));
|
|
167
|
+
},
|
|
168
|
+
clearLogs: () => set({ logs: [] }),
|
|
169
|
+
|
|
170
|
+
// Timer
|
|
171
|
+
tickElapsed: () => set((s) => ({ elapsedTime: s.elapsedTime + 0.1 })),
|
|
172
|
+
resetElapsed: () => set({ elapsedTime: 0 }),
|
|
173
|
+
|
|
174
|
+
// Replay
|
|
175
|
+
replayStep: () => {
|
|
176
|
+
set({ animatingMessages: false });
|
|
177
|
+
},
|
|
178
|
+
|
|
179
|
+
getCurrentSteps: () => {
|
|
180
|
+
const { selectedPath, activeSubPathId } = get();
|
|
181
|
+
if (selectedPath.subPaths && activeSubPathId) {
|
|
182
|
+
const sub = selectedPath.subPaths.find((s) => s.id === activeSubPathId);
|
|
183
|
+
return sub ? sub.steps : [];
|
|
184
|
+
}
|
|
185
|
+
return selectedPath.steps;
|
|
186
|
+
},
|
|
187
|
+
|
|
188
|
+
getCurrentStep: () => {
|
|
189
|
+
const { activeStepIndex } = get();
|
|
190
|
+
const steps = get().getCurrentSteps();
|
|
191
|
+
return steps[activeStepIndex] || null;
|
|
192
|
+
},
|
|
193
|
+
|
|
194
|
+
getTotalSteps: () => {
|
|
195
|
+
return get().getCurrentSteps().length;
|
|
196
|
+
},
|
|
197
|
+
}));
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
export const COMPONENT_ICONS: Record<string, string> = {
|
|
2
|
+
'rider-app': 'smartphone',
|
|
3
|
+
'driver-app': 'directions_car',
|
|
4
|
+
'backend-api': 'cloud_queue',
|
|
5
|
+
'bullmq': 'layers',
|
|
6
|
+
'ops-dashboard': 'monitor_heart',
|
|
7
|
+
'pubsub': 'cell_tower',
|
|
8
|
+
'dac': 'assignment',
|
|
9
|
+
'database': 'database',
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export const COMPONENT_ROLES: Record<string, string> = {
|
|
13
|
+
'rider-app': 'Client',
|
|
14
|
+
'driver-app': 'Client',
|
|
15
|
+
'backend-api': 'Gateway',
|
|
16
|
+
'bullmq': 'Worker',
|
|
17
|
+
'ops-dashboard': 'Dashboard',
|
|
18
|
+
'pubsub': 'Messaging',
|
|
19
|
+
'dac': 'Actions',
|
|
20
|
+
'database': 'Storage',
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export const CATEGORY_ICONS: Record<string, string> = {
|
|
24
|
+
success: 'check_circle',
|
|
25
|
+
'rider-cancel': 'cancel',
|
|
26
|
+
'driver-cancel': 'person_off',
|
|
27
|
+
timeout: 'schedule',
|
|
28
|
+
ops: 'admin_panel_settings',
|
|
29
|
+
'active-cancel': 'cancel',
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
export const ACTOR_ICONS: Record<string, string> = {
|
|
33
|
+
rider: 'person',
|
|
34
|
+
driver: 'directions_car',
|
|
35
|
+
ops: 'admin_panel_settings',
|
|
36
|
+
system: 'dns',
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
export const MESSAGE_TYPE_ICONS: Record<string, string> = {
|
|
40
|
+
request: 'input',
|
|
41
|
+
response: 'output',
|
|
42
|
+
event: 'bolt',
|
|
43
|
+
job: 'work',
|
|
44
|
+
notification: 'notifications',
|
|
45
|
+
cleanup: 'cleaning_services',
|
|
46
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
|
|
4
|
+
"target": "ES2022",
|
|
5
|
+
"useDefineForClassFields": true,
|
|
6
|
+
"lib": ["ES2022", "DOM", "DOM.Iterable"],
|
|
7
|
+
"module": "ESNext",
|
|
8
|
+
"types": ["vite/client"],
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
|
|
11
|
+
/* Bundler mode */
|
|
12
|
+
"moduleResolution": "bundler",
|
|
13
|
+
"allowImportingTsExtensions": true,
|
|
14
|
+
"verbatimModuleSyntax": true,
|
|
15
|
+
"moduleDetection": "force",
|
|
16
|
+
"noEmit": true,
|
|
17
|
+
"jsx": "react-jsx",
|
|
18
|
+
|
|
19
|
+
/* Linting */
|
|
20
|
+
"strict": true,
|
|
21
|
+
"noUnusedLocals": true,
|
|
22
|
+
"noUnusedParameters": true,
|
|
23
|
+
"erasableSyntaxOnly": true,
|
|
24
|
+
"noFallthroughCasesInSwitch": true,
|
|
25
|
+
"noUncheckedSideEffectImports": true
|
|
26
|
+
},
|
|
27
|
+
"include": ["src"]
|
|
28
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
|
|
4
|
+
"target": "ES2023",
|
|
5
|
+
"lib": ["ES2023"],
|
|
6
|
+
"module": "ESNext",
|
|
7
|
+
"types": ["node"],
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
|
|
10
|
+
/* Bundler mode */
|
|
11
|
+
"moduleResolution": "bundler",
|
|
12
|
+
"allowImportingTsExtensions": true,
|
|
13
|
+
"verbatimModuleSyntax": true,
|
|
14
|
+
"moduleDetection": "force",
|
|
15
|
+
"noEmit": true,
|
|
16
|
+
|
|
17
|
+
/* Linting */
|
|
18
|
+
"strict": true,
|
|
19
|
+
"noUnusedLocals": true,
|
|
20
|
+
"noUnusedParameters": true,
|
|
21
|
+
"erasableSyntaxOnly": true,
|
|
22
|
+
"noFallthroughCasesInSwitch": true,
|
|
23
|
+
"noUncheckedSideEffectImports": true
|
|
24
|
+
},
|
|
25
|
+
"include": ["vite.config.ts"]
|
|
26
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { defineConfig } from 'vite'
|
|
2
|
+
import react from '@vitejs/plugin-react'
|
|
3
|
+
import tailwindcss from '@tailwindcss/vite'
|
|
4
|
+
|
|
5
|
+
// `base` is substituted by `yad docs` at generate time from .sdlc/docs.json `basePath`
|
|
6
|
+
// (GitHub project Pages serve at /<repo>/; user/org Pages and GitLab Pages use /).
|
|
7
|
+
export default defineConfig({
|
|
8
|
+
base: '__BASE_PATH__',
|
|
9
|
+
plugins: [react(), tailwindcss()],
|
|
10
|
+
})
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: yad-docs-overview
|
|
3
|
+
description: 'Generates the project-level SDLC-overview interactive site — the same React/Vite/Tailwind shell as the per-epic docs — showing every yadflow stage from setup → ship: the pipeline as a flow canvas, each skill/gate as a flow step, the durable .sdlc state objects as system components, and the lenses as stakeholder roles. Themed with yadflow''s own brand palette for continuity, built from config.yaml + module-help.csv + the overview diagram. Supersedes docs/index.html with a thin redirect and deploys via `yad docs deploy --overview`. This is project documentation, not a gated state — it never touches any epic''s state or approvals. Use when the user says "generate the overview site", "build the SDLC overview docs", or after the pipeline (module-help.csv / config.yaml / skill count) changes.'
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# SDLC — Author the Overview Site (project-level, the pipeline as a living map)
|
|
7
|
+
|
|
8
|
+
**Goal:** Render the **whole yadflow pipeline** — every stage from setup → ship — as an interactive site,
|
|
9
|
+
reusing the same shell as the per-epic docs (`skills/yad-docs/templates/app/`). Where `yad-docs`
|
|
10
|
+
animates one epic's flows, this animates the **workflow itself**: the front gates, the build half, the
|
|
11
|
+
automation dial, the setup connectors. It is the regenerable successor to the hand-maintained
|
|
12
|
+
`docs/index.html` overview.
|
|
13
|
+
|
|
14
|
+
This is **project documentation, not a gated state** — there is no epic, no `state.json`, no approvals.
|
|
15
|
+
It only reads the pipeline definition and writes a project-level site. When a docs target is connected
|
|
16
|
+
(`.sdlc/docs.json`) it builds + deploys; otherwise it build-only.
|
|
17
|
+
|
|
18
|
+
## Conventions
|
|
19
|
+
|
|
20
|
+
- `{project-root}` resolves from the project working directory (the **product hub**).
|
|
21
|
+
- The overview site lives at `{project-root}/docs/sdlc-site/`; its `dist/`/`node_modules/` are gitignored,
|
|
22
|
+
the generated **source is committed**. The overview build manifest is `docs/sdlc-site/.docs-build.json`.
|
|
23
|
+
- The shell template is `skills/yad-docs/templates/app/` — copied **verbatim**, themed only in the
|
|
24
|
+
`:root` of `index.css`. Generated data satisfies `src/data/types.ts`.
|
|
25
|
+
- Theme: **yadflow's own brand palette** (the `:root` of `docs/index.html`) — for visual continuity with
|
|
26
|
+
the existing overview, not an epic's design tokens.
|
|
27
|
+
- Speak in the configured `communication_language`; write documents in `document_output_language`.
|
|
28
|
+
|
|
29
|
+
## Inputs
|
|
30
|
+
|
|
31
|
+
- `action` — `generate` (default) | `refresh` | `deploy`.
|
|
32
|
+
- `login_gate` — `true` | `false` (default `false`).
|
|
33
|
+
|
|
34
|
+
## On Activation
|
|
35
|
+
|
|
36
|
+
### Step 1 — Read the pipeline definition (the data sources)
|
|
37
|
+
There is no epic; the inputs are the workflow's own config + manifest (full mapping in
|
|
38
|
+
`references/pipeline-model.md`):
|
|
39
|
+
|
|
40
|
+
- `skills/sdlc/config.yaml` — the front/back steps, the **two dials** (assistance, automation),
|
|
41
|
+
defaults, the review-gate rule, the build conventions, the automation/trust thresholds.
|
|
42
|
+
- `skills/sdlc/module-help.csv` — the **canonical skill manifest**: each skill's `phase`,
|
|
43
|
+
`preceded-by` / `followed-by`, and `outputs`. This is the ordering source of truth.
|
|
44
|
+
- `docs/diagrams/sdlc-overview.mmd` — the overview diagram (the node/edge shape + the node classes:
|
|
45
|
+
artifact / gate / earns / locked / sentinel).
|
|
46
|
+
- the build-plan docs under `docs/` — phase narratives for the section copy.
|
|
47
|
+
|
|
48
|
+
### Step 1b — Open the authoring branch
|
|
49
|
+
Open the `docs/overview` authoring branch per the shared procedure
|
|
50
|
+
(`../yad-epic/references/state-schema.md` → "Authoring branches"): git-safe (skip with a note if not a
|
|
51
|
+
git work tree). Generate and commit on it.
|
|
52
|
+
|
|
53
|
+
### Step 2 — Model the pipeline with the shell primitives
|
|
54
|
+
Map the pipeline onto the same data structures `yad-docs` uses (concrete mapping in
|
|
55
|
+
`references/pipeline-model.md`):
|
|
56
|
+
|
|
57
|
+
- **Flow paths** = the **phases** — `Setup`, `Front half`, `Build half`, `Automation`.
|
|
58
|
+
- **Flow steps** = the **skills/gates in order** (from `module-help.csv` `preceded-by`/`followed-by`),
|
|
59
|
+
each step's `messages` = the skill's `outputs`, and `sideEffects` = the `.sdlc/` files it writes.
|
|
60
|
+
- **System components** = the **durable state objects** — the product hub, each `.sdlc/*.json`
|
|
61
|
+
(`state.json`, `approvals.json`, `repos.json`, `design.json`, `testing.json`, `learning.json`,
|
|
62
|
+
`docs.json`, `contract-lock.json`, `build-state/*`, `trust-log.json`), the connected code repos, the
|
|
63
|
+
design/testing/learning tools, and the platform.
|
|
64
|
+
- **Roles** = the **lenses** (analyst / pm / architect / ux / dev / tester / reviewer / engineer) → each
|
|
65
|
+
to its relevant sections + paths.
|
|
66
|
+
|
|
67
|
+
### Step 3 — Generate the site into `docs/sdlc-site/`
|
|
68
|
+
Copy the shell from `templates/app/` **verbatim**, generate `src/data/*.ts` deterministically (same
|
|
69
|
+
determinism rules as `yad-docs`: stable-ID sort by skill pipeline order / phase, fixed key order, no
|
|
70
|
+
timestamps in the data files), theme the `:root` of `index.css` from **yadflow's brand palette** — the
|
|
71
|
+
`docs/index.html` `:root`: `--accent: #2471a3` and the node colors (`--artifact-*`, `--gate-*`,
|
|
72
|
+
`--earns-*`, `--locked-*`, `--sentinel-*`) — and substitute the Vite base from `.sdlc/docs.json`
|
|
73
|
+
`basePath` (the overview sits at the base root, e.g. `/<repo>/`).
|
|
74
|
+
|
|
75
|
+
### Step 4 — Write the overview build manifest (the staleness baseline)
|
|
76
|
+
Write `docs/sdlc-site/.docs-build.json` — `yad-docs-sync` compares against it:
|
|
77
|
+
|
|
78
|
+
```json
|
|
79
|
+
{
|
|
80
|
+
"builtAt": "<YYYY-MM-DD>",
|
|
81
|
+
"theme": "yadflow-brand",
|
|
82
|
+
"artifactHash": "<sha256 of config.yaml + module-help.csv + docs/diagrams/sdlc-overview.mmd>",
|
|
83
|
+
"skillCount": <number of yad-* skills>,
|
|
84
|
+
"deployUrl": "<url or null>",
|
|
85
|
+
"templateVersion": "<shell template version = the yad CLI version>"
|
|
86
|
+
}
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
The overview's freshness inputs are the **config + manifest + diagram** (plus the `templateVersion`, so a
|
|
90
|
+
doc-shell upgrade triggers a rebuild). `skillCount` rides along in the manifest as an informational field
|
|
91
|
+
— it is **not** a separate hash input, since `module-help.csv` already moves whenever the skill set does.
|
|
92
|
+
Not per-epic artifacts/repo heads.
|
|
93
|
+
|
|
94
|
+
### Step 5 — Supersede `docs/index.html` (one release)
|
|
95
|
+
Turn `docs/index.html` into a **thin redirect** to `docs/sdlc-site/` (e.g. a `<meta http-equiv="refresh">`
|
|
96
|
+
+ a one-line link), and **note in the report** that the hand-maintained overview is superseded by the
|
|
97
|
+
generated site for this release. This generalizes the standing rule that feature work hand-updates
|
|
98
|
+
`docs/index.html`: the overview site now **regenerates** instead.
|
|
99
|
+
|
|
100
|
+
### Step 6 — Build / deploy (`action`)
|
|
101
|
+
- `action: generate` (default) — generate source + manifest; stop.
|
|
102
|
+
- `action: deploy` — drive **`yad docs deploy --overview`**: npm-build, ensure the Pages CI workflow,
|
|
103
|
+
report the deploy URL. Degrades to local `dist/` when no platform CLI / `target: "none"`.
|
|
104
|
+
|
|
105
|
+
### Step 7 — Stop. Report (no gate, no epic)
|
|
106
|
+
Report: the site path (`docs/sdlc-site/`), the data files produced, that the theme is the yadflow brand
|
|
107
|
+
palette, the deploy URL or "build-only", the staleness baseline, and that `docs/index.html` now
|
|
108
|
+
redirects to the generated site. Never touches any epic state.
|
|
109
|
+
|
|
110
|
+
## Hard rules
|
|
111
|
+
|
|
112
|
+
- **Project documentation, not a gate.** No epic, no `state.json`, no approvals — this skill never reads
|
|
113
|
+
or writes any epic's gated state.
|
|
114
|
+
- **The overview regenerates on pipeline change.** This **generalizes** the standing rule that feature
|
|
115
|
+
work hand-updates `docs/index.html` + the overview diagram + skill counts: the overview site now
|
|
116
|
+
regenerates whenever `module-help.csv` / `config.yaml` / the skill count changes — and `yad-docs-sync`
|
|
117
|
+
**enforces** that (it flags the overview stale when those inputs move).
|
|
118
|
+
- **Brand-palette themed, copy the shell verbatim.** Theme only the `:root`; generate only `src/data/*.ts`
|
|
119
|
+
+ the Vite base. Never hand-edit `templates/app/`.
|
|
120
|
+
- **Deterministic generation.** Same stable-sort / fixed-key / no-timestamp discipline as `yad-docs`.
|
|
121
|
+
- **Degrade gracefully.** No docs target → build-only; no `.mmd` / no build-plan docs → omit those
|
|
122
|
+
sections with a note, never invent.
|
|
123
|
+
|
|
124
|
+
## Reference
|
|
125
|
+
- The concrete mapping of every setup→ship stage to flow paths / steps / components / roles, with each
|
|
126
|
+
`yad-*` skill in pipeline order + its phase + outputs: `references/pipeline-model.md`.
|
|
127
|
+
- The per-epic counterpart (shell, determinism, theming): `../yad-docs/SKILL.md`.
|
|
128
|
+
- The connected docs target + base-path resolution: `../yad-connect-docs/SKILL.md`.
|
|
129
|
+
- The staleness/CI reconciler that enforces overview regeneration: `../yad-docs-sync/SKILL.md`.
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# Pipeline model — the yadflow workflow as `src/data/*.ts`
|
|
2
|
+
|
|
3
|
+
`yad-docs-overview` reuses the per-epic shell, but the *content* is the **workflow itself** rather than
|
|
4
|
+
one epic's flows. This file pins how the setup→ship pipeline maps onto the shell's primitives. The
|
|
5
|
+
ordering source of truth is `skills/sdlc/module-help.csv` (`phase`, `preceded-by`, `followed-by`,
|
|
6
|
+
`outputs`); the dials/thresholds come from `skills/sdlc/config.yaml`; the node classes come from
|
|
7
|
+
`docs/diagrams/sdlc-overview.mmd`.
|
|
8
|
+
|
|
9
|
+
## Primitive mapping
|
|
10
|
+
|
|
11
|
+
| Shell primitive | Overview meaning |
|
|
12
|
+
|-----------------|------------------|
|
|
13
|
+
| `FlowPath` (`paths.ts`) | a **phase**: Setup, Front half, Build half, Automation. |
|
|
14
|
+
| `FlowStep` (within a path) | a **skill or gate** in order; `messages` = its `outputs`; `sideEffects` = the `.sdlc/` files it writes; `status`/`bookingStatus` annotate gated vs. enrichment vs. earned. |
|
|
15
|
+
| `SystemComponent` (`components.ts`) | a **durable state object** (the hub, each `.sdlc/*.json`, code repos, the design/testing/learning tools, the platform). |
|
|
16
|
+
| `RoleConfig` (`roles.ts`) | a **lens** → its relevant sections + paths. |
|
|
17
|
+
| doc sections (`docSections.ts`/`referenceData.ts`) | the phase narratives + the dial/threshold reference tables (from `config.yaml` + the build-plan docs). |
|
|
18
|
+
|
|
19
|
+
## Flow paths = phases, with their skills in order
|
|
20
|
+
|
|
21
|
+
Order each path's steps by `module-help.csv` `phase` then the `preceded-by`/`followed-by` chain.
|
|
22
|
+
|
|
23
|
+
### Path: Setup (`phase: 0-setup`)
|
|
24
|
+
The connectors that make the brain context-aware and the outputs publishable. Each writes a `.sdlc/*.json`
|
|
25
|
+
and never gates.
|
|
26
|
+
|
|
27
|
+
| Step (skill) | Outputs / sideEffects |
|
|
28
|
+
|--------------|------------------------|
|
|
29
|
+
| `yad-connect-repos` | `repos.json`, `code-context/<repo>/pack.md` + `code-map.md` (+ `detect-hub`/`roster` → `hub.json`) |
|
|
30
|
+
| `yad-connect-design` | `design.json` |
|
|
31
|
+
| `yad-connect-testing` | `testing.json` |
|
|
32
|
+
| `yad-connect-learning` | `learning.json` |
|
|
33
|
+
| `yad-connect-docs` | `docs.json` |
|
|
34
|
+
|
|
35
|
+
### Path: Front half (`phase: 1-front`)
|
|
36
|
+
The gated authoring chain + the reusable review gate (10 steps, or 12 with the optional analysis).
|
|
37
|
+
|
|
38
|
+
| Step (skill) | Gate | Outputs / sideEffects |
|
|
39
|
+
|--------------|------|------------------------|
|
|
40
|
+
| `yad-analysis` *(optional)* | → `analysis-review` | `analysis.md`, seeds `state.json` |
|
|
41
|
+
| `yad-epic` | → `epic-review` | `epic.md`, seeds `state.json` |
|
|
42
|
+
| `yad-architecture` | → `architecture-review` (escalates on contract) | `architecture.md`, `contract.md`, `contract-lock.json` |
|
|
43
|
+
| `yad-ui` | → `ui-design-review` | `ui-design.md`, `DESIGN.md`, `design-links.json` |
|
|
44
|
+
| `yad-stories` | → `stories-review` (per-repo routing) | `stories/EP-<slug>-S0N.md` |
|
|
45
|
+
| `yad-test-cases` | → `test-cases-review` (parallel, non-blocking) | `test-cases.md`, `test-links.json` |
|
|
46
|
+
| `yad-review-gate` | the shared gate | `reviews/*.md`, `approvals.json`, `comments.json` |
|
|
47
|
+
| `yad-hub-bridge` | the platform PR/MR bridge | `hub-prs.json` |
|
|
48
|
+
| `yad-review-comments` | comment scaffolds | repo comment templates |
|
|
49
|
+
|
|
50
|
+
### Path: Build half (`phase: 3-build`)
|
|
51
|
+
Per-story, per-repo: `spec → tasks → implement → checks → engineer-review`, plus the commit/PR helpers.
|
|
52
|
+
|
|
53
|
+
| Step (skill) | Outputs / sideEffects |
|
|
54
|
+
|--------------|------------------------|
|
|
55
|
+
| `yad-spec` | `specs/<story-id>/` (Spec Kit layout), `link.md` |
|
|
56
|
+
| `yad-implement` | a branch + commit per atomic task |
|
|
57
|
+
| `yad-checks` | `checks/*.sh`, CI workflows |
|
|
58
|
+
| `yad-pr-template` | PR/MR template + routing helpers |
|
|
59
|
+
| `yad-commit` / `yad-open-pr` / `yad-ship` | one commit / one PR/MR |
|
|
60
|
+
| `yad-engineer-review` | engineer review + ship recorded in `build-log.json` |
|
|
61
|
+
| `yad-backfill` | DRAFT specs for legacy features |
|
|
62
|
+
|
|
63
|
+
### Path: Automation (the second dial + observation)
|
|
64
|
+
The orchestrator + the trust evidence + the read-only views. Maps the **earns** / **locked** / **sentinel**
|
|
65
|
+
node classes from the diagram.
|
|
66
|
+
|
|
67
|
+
| Step (skill) | Outputs / sideEffects |
|
|
68
|
+
|--------------|------------------------|
|
|
69
|
+
| `yad-run` | drives the back-half loop; `build-state/<story>.json`, `trust-log.json`, kill switch |
|
|
70
|
+
| `yad-learn` | tutoring; `learning-records.json` (LOCAL-ONLY, gitignored) |
|
|
71
|
+
| `yad-status` | read-only view (no writes) |
|
|
72
|
+
| `yad-docs` / `yad-docs-overview` / `yad-docs-sync` | the docs sites + their `docs-build.json` manifests |
|
|
73
|
+
|
|
74
|
+
## System components = the durable state objects
|
|
75
|
+
|
|
76
|
+
`components.ts` renders these on the canvas (deterministic positions): the **product hub**; each
|
|
77
|
+
`.sdlc/*.json` (`state.json`, `approvals.json`, `comments.json`, `hub.json`, `repos.json`, `design.json`,
|
|
78
|
+
`testing.json`, `learning.json`, `docs.json`, `contract-lock.json`, `build-state/*`, `trust-log.json`);
|
|
79
|
+
the **connected code repos**; the **design / testing / learning tools**; and the **platform**
|
|
80
|
+
(GitHub/GitLab + Pages). A skill's `sideEffects` link its step to the component it writes.
|
|
81
|
+
|
|
82
|
+
## Roles = the lenses
|
|
83
|
+
|
|
84
|
+
The eight yadflow lenses, each to its relevant phase sections + paths:
|
|
85
|
+
|
|
86
|
+
| Lens | Relevant phases / sections |
|
|
87
|
+
|------|----------------------------|
|
|
88
|
+
| analyst | Setup intent, analysis step, front-half discovery |
|
|
89
|
+
| pm | epic, stories, roadmap; the front gates |
|
|
90
|
+
| architect | architecture + the locked contract; escalation |
|
|
91
|
+
| ux | UI design, design tool connection, the design system |
|
|
92
|
+
| dev | build half: spec → implement, the per-repo loop |
|
|
93
|
+
| tester | test-cases (parallel track), the testing tool, checks |
|
|
94
|
+
| reviewer | the review gate, comments, the hub bridge |
|
|
95
|
+
| engineer | engineer review + ship, the merge gate, automation dial/trust |
|
|
96
|
+
|
|
97
|
+
## Determinism + theme
|
|
98
|
+
Same discipline as `yad-docs`: stable-sort steps by phase then pipeline order, fixed key order, **no
|
|
99
|
+
timestamps** in `src/data/*.ts` (build time lives only in `.docs-build.json`). Theme the `:root` from
|
|
100
|
+
**yadflow's brand palette** (`docs/index.html` `:root`): `--accent: #2471a3`, and carry the node-class
|
|
101
|
+
colors through to step/path colors — `--artifact-* #b7950b`, `--gate-* #ca6f1e`, `--earns-* #2471a3`,
|
|
102
|
+
`--locked-* #566573`, `--sentinel-* #1e8449` — so the canvas reads like the existing diagram.
|