@contractspec/example.workflow-system 0.0.0-canary-20260113170453

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.
Files changed (157) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +124 -0
  3. package/dist/approval/approval.enum.d.ts +14 -0
  4. package/dist/approval/approval.enum.d.ts.map +1 -0
  5. package/dist/approval/approval.enum.js +29 -0
  6. package/dist/approval/approval.enum.js.map +1 -0
  7. package/dist/approval/approval.event.d.ts +131 -0
  8. package/dist/approval/approval.event.d.ts.map +1 -0
  9. package/dist/approval/approval.event.js +220 -0
  10. package/dist/approval/approval.event.js.map +1 -0
  11. package/dist/approval/approval.handler.d.ts +23 -0
  12. package/dist/approval/approval.handler.d.ts.map +1 -0
  13. package/dist/approval/approval.handler.js +72 -0
  14. package/dist/approval/approval.handler.js.map +1 -0
  15. package/dist/approval/approval.operations.d.ts +535 -0
  16. package/dist/approval/approval.operations.d.ts.map +1 -0
  17. package/dist/approval/approval.operations.js +345 -0
  18. package/dist/approval/approval.operations.js.map +1 -0
  19. package/dist/approval/approval.schema.d.ts +100 -0
  20. package/dist/approval/approval.schema.d.ts.map +1 -0
  21. package/dist/approval/approval.schema.js +110 -0
  22. package/dist/approval/approval.schema.js.map +1 -0
  23. package/dist/approval/index.d.ts +5 -0
  24. package/dist/approval/index.js +6 -0
  25. package/dist/docs/index.d.ts +1 -0
  26. package/dist/docs/index.js +1 -0
  27. package/dist/docs/workflow-system.docblock.d.ts +1 -0
  28. package/dist/docs/workflow-system.docblock.js +115 -0
  29. package/dist/docs/workflow-system.docblock.js.map +1 -0
  30. package/dist/entities/approval.d.ts +58 -0
  31. package/dist/entities/approval.d.ts.map +1 -0
  32. package/dist/entities/approval.js +128 -0
  33. package/dist/entities/approval.js.map +1 -0
  34. package/dist/entities/index.d.ts +139 -0
  35. package/dist/entities/index.d.ts.map +1 -0
  36. package/dist/entities/index.js +32 -0
  37. package/dist/entities/index.js.map +1 -0
  38. package/dist/entities/instance.d.ts +69 -0
  39. package/dist/entities/instance.d.ts.map +1 -0
  40. package/dist/entities/instance.js +168 -0
  41. package/dist/entities/instance.js.map +1 -0
  42. package/dist/entities/step.d.ts +50 -0
  43. package/dist/entities/step.d.ts.map +1 -0
  44. package/dist/entities/step.js +135 -0
  45. package/dist/entities/step.js.map +1 -0
  46. package/dist/entities/workflow.d.ts +41 -0
  47. package/dist/entities/workflow.d.ts.map +1 -0
  48. package/dist/entities/workflow.js +102 -0
  49. package/dist/entities/workflow.js.map +1 -0
  50. package/dist/example.d.ts +7 -0
  51. package/dist/example.d.ts.map +1 -0
  52. package/dist/example.js +58 -0
  53. package/dist/example.js.map +1 -0
  54. package/dist/handlers/index.d.ts +2 -0
  55. package/dist/handlers/index.js +3 -0
  56. package/dist/handlers/workflow.handlers.d.ts +122 -0
  57. package/dist/handlers/workflow.handlers.d.ts.map +1 -0
  58. package/dist/handlers/workflow.handlers.js +263 -0
  59. package/dist/handlers/workflow.handlers.js.map +1 -0
  60. package/dist/index.d.ts +26 -0
  61. package/dist/index.js +26 -0
  62. package/dist/instance/index.d.ts +5 -0
  63. package/dist/instance/index.js +6 -0
  64. package/dist/instance/instance.enum.d.ts +10 -0
  65. package/dist/instance/instance.enum.d.ts.map +1 -0
  66. package/dist/instance/instance.enum.js +20 -0
  67. package/dist/instance/instance.enum.js.map +1 -0
  68. package/dist/instance/instance.event.d.ts +356 -0
  69. package/dist/instance/instance.event.d.ts.map +1 -0
  70. package/dist/instance/instance.event.js +293 -0
  71. package/dist/instance/instance.event.js.map +1 -0
  72. package/dist/instance/instance.handler.d.ts +27 -0
  73. package/dist/instance/instance.handler.d.ts.map +1 -0
  74. package/dist/instance/instance.handler.js +94 -0
  75. package/dist/instance/instance.handler.js.map +1 -0
  76. package/dist/instance/instance.operations.d.ts +1024 -0
  77. package/dist/instance/instance.operations.d.ts.map +1 -0
  78. package/dist/instance/instance.operations.js +464 -0
  79. package/dist/instance/instance.operations.js.map +1 -0
  80. package/dist/instance/instance.schema.d.ts +223 -0
  81. package/dist/instance/instance.schema.d.ts.map +1 -0
  82. package/dist/instance/instance.schema.js +172 -0
  83. package/dist/instance/instance.schema.js.map +1 -0
  84. package/dist/presentations/index.d.ts +63 -0
  85. package/dist/presentations/index.d.ts.map +1 -0
  86. package/dist/presentations/index.js +340 -0
  87. package/dist/presentations/index.js.map +1 -0
  88. package/dist/seeders/index.d.ts +10 -0
  89. package/dist/seeders/index.d.ts.map +1 -0
  90. package/dist/seeders/index.js +19 -0
  91. package/dist/seeders/index.js.map +1 -0
  92. package/dist/shared/index.d.ts +3 -0
  93. package/dist/shared/index.js +3 -0
  94. package/dist/shared/mock-data.d.ts +19 -0
  95. package/dist/shared/mock-data.d.ts.map +1 -0
  96. package/dist/shared/mock-data.js +12 -0
  97. package/dist/shared/mock-data.js.map +1 -0
  98. package/dist/shared/types.d.ts +81 -0
  99. package/dist/shared/types.d.ts.map +1 -0
  100. package/dist/shared/types.js +0 -0
  101. package/dist/state-machine/index.d.ts +148 -0
  102. package/dist/state-machine/index.d.ts.map +1 -0
  103. package/dist/state-machine/index.js +158 -0
  104. package/dist/state-machine/index.js.map +1 -0
  105. package/dist/tests/operations.test-spec.d.ts +10 -0
  106. package/dist/tests/operations.test-spec.d.ts.map +1 -0
  107. package/dist/tests/operations.test-spec.js +123 -0
  108. package/dist/tests/operations.test-spec.js.map +1 -0
  109. package/dist/ui/WorkflowDashboard.d.ts +7 -0
  110. package/dist/ui/WorkflowDashboard.d.ts.map +1 -0
  111. package/dist/ui/WorkflowDashboard.js +223 -0
  112. package/dist/ui/WorkflowDashboard.js.map +1 -0
  113. package/dist/ui/hooks/index.d.ts +2 -0
  114. package/dist/ui/hooks/index.js +5 -0
  115. package/dist/ui/hooks/useWorkflowList.d.ts +22 -0
  116. package/dist/ui/hooks/useWorkflowList.d.ts.map +1 -0
  117. package/dist/ui/hooks/useWorkflowList.js +55 -0
  118. package/dist/ui/hooks/useWorkflowList.js.map +1 -0
  119. package/dist/ui/index.d.ts +6 -0
  120. package/dist/ui/index.js +6 -0
  121. package/dist/ui/renderers/index.d.ts +2 -0
  122. package/dist/ui/renderers/index.js +3 -0
  123. package/dist/ui/renderers/workflow.markdown.d.ts +28 -0
  124. package/dist/ui/renderers/workflow.markdown.d.ts.map +1 -0
  125. package/dist/ui/renderers/workflow.markdown.js +234 -0
  126. package/dist/ui/renderers/workflow.markdown.js.map +1 -0
  127. package/dist/workflow/index.d.ts +5 -0
  128. package/dist/workflow/index.js +6 -0
  129. package/dist/workflow/workflow.enum.d.ts +22 -0
  130. package/dist/workflow/workflow.enum.d.ts.map +1 -0
  131. package/dist/workflow/workflow.enum.js +47 -0
  132. package/dist/workflow/workflow.enum.js.map +1 -0
  133. package/dist/workflow/workflow.event.d.ts +135 -0
  134. package/dist/workflow/workflow.event.d.ts.map +1 -0
  135. package/dist/workflow/workflow.event.js +150 -0
  136. package/dist/workflow/workflow.event.js.map +1 -0
  137. package/dist/workflow/workflow.handler.d.ts +29 -0
  138. package/dist/workflow/workflow.handler.d.ts.map +1 -0
  139. package/dist/workflow/workflow.handler.js +66 -0
  140. package/dist/workflow/workflow.handler.js.map +1 -0
  141. package/dist/workflow/workflow.operations.d.ts +1011 -0
  142. package/dist/workflow/workflow.operations.d.ts.map +1 -0
  143. package/dist/workflow/workflow.operations.js +345 -0
  144. package/dist/workflow/workflow.operations.js.map +1 -0
  145. package/dist/workflow/workflow.schema.d.ts +265 -0
  146. package/dist/workflow/workflow.schema.d.ts.map +1 -0
  147. package/dist/workflow/workflow.schema.js +249 -0
  148. package/dist/workflow/workflow.schema.js.map +1 -0
  149. package/dist/workflow-system.capability.d.ts +9 -0
  150. package/dist/workflow-system.capability.d.ts.map +1 -0
  151. package/dist/workflow-system.capability.js +34 -0
  152. package/dist/workflow-system.capability.js.map +1 -0
  153. package/dist/workflow-system.feature.d.ts +12 -0
  154. package/dist/workflow-system.feature.d.ts.map +1 -0
  155. package/dist/workflow-system.feature.js +346 -0
  156. package/dist/workflow-system.feature.js.map +1 -0
  157. package/package.json +133 -0
@@ -0,0 +1,340 @@
1
+ import { WorkflowDefinitionModel } from "../workflow/workflow.schema.js";
2
+ import { WorkflowInstanceModel } from "../instance/instance.schema.js";
3
+ import { ApprovalRequestModel } from "../approval/approval.schema.js";
4
+ import { StabilityEnum, definePresentation } from "@contractspec/lib.contracts";
5
+
6
+ //#region src/presentations/index.ts
7
+ /**
8
+ * Workflow System Presentation Descriptors
9
+ */
10
+ /**
11
+ * Workflow designer canvas for building workflows.
12
+ */
13
+ const WorkflowDesignerPresentation = definePresentation({
14
+ meta: {
15
+ key: "workflow.designer",
16
+ version: "1.0.0",
17
+ title: "Workflow Designer",
18
+ description: "Visual workflow designer with drag-and-drop steps",
19
+ domain: "workflow-system",
20
+ owners: ["@workflow-team"],
21
+ tags: [
22
+ "workflow",
23
+ "designer",
24
+ "admin"
25
+ ],
26
+ stability: StabilityEnum.Experimental,
27
+ goal: "Building and modifying workflow definitions",
28
+ context: "Workflow administration and setup"
29
+ },
30
+ source: {
31
+ type: "component",
32
+ framework: "react",
33
+ componentKey: "WorkflowDesigner",
34
+ props: WorkflowDefinitionModel
35
+ },
36
+ targets: ["react"],
37
+ policy: { flags: ["workflow.designer.enabled"] }
38
+ });
39
+ /**
40
+ * List of workflow definitions.
41
+ */
42
+ const WorkflowListPresentation = definePresentation({
43
+ meta: {
44
+ key: "workflow.definition.list",
45
+ version: "1.0.0",
46
+ title: "Workflow List",
47
+ description: "List of workflow definitions with status and actions",
48
+ domain: "workflow-system",
49
+ owners: ["@workflow-team"],
50
+ tags: [
51
+ "workflow",
52
+ "list",
53
+ "admin"
54
+ ],
55
+ stability: StabilityEnum.Experimental,
56
+ goal: "Overview of all defined workflows",
57
+ context: "Workflow management dashboard"
58
+ },
59
+ source: {
60
+ type: "component",
61
+ framework: "react",
62
+ componentKey: "WorkflowDefinitionList",
63
+ props: WorkflowDefinitionModel
64
+ },
65
+ targets: ["react", "markdown"],
66
+ policy: { flags: ["workflow.enabled"] }
67
+ });
68
+ /**
69
+ * Workflow definition detail view.
70
+ */
71
+ const WorkflowDetailPresentation = definePresentation({
72
+ meta: {
73
+ key: "workflow.definition.detail",
74
+ version: "1.0.0",
75
+ title: "Workflow Details",
76
+ description: "Detailed view of a workflow definition with steps",
77
+ domain: "workflow-system",
78
+ owners: ["@workflow-team"],
79
+ tags: ["workflow", "detail"],
80
+ stability: StabilityEnum.Experimental,
81
+ goal: "Viewing technical details of a workflow definition",
82
+ context: "Workflow inspection and debugging"
83
+ },
84
+ source: {
85
+ type: "component",
86
+ framework: "react",
87
+ componentKey: "WorkflowDefinitionDetail",
88
+ props: WorkflowDefinitionModel
89
+ },
90
+ targets: ["react", "markdown"],
91
+ policy: { flags: ["workflow.enabled"] }
92
+ });
93
+ /**
94
+ * List of running workflow instances.
95
+ */
96
+ const InstanceListPresentation = definePresentation({
97
+ meta: {
98
+ key: "workflow.instance.list",
99
+ version: "1.0.0",
100
+ title: "Instance List",
101
+ description: "List of workflow instances with status and progress",
102
+ domain: "workflow-system",
103
+ owners: ["@workflow-team"],
104
+ tags: [
105
+ "workflow",
106
+ "instance",
107
+ "list"
108
+ ],
109
+ stability: StabilityEnum.Experimental,
110
+ goal: "Monitoring active and past workflow executions",
111
+ context: "Operations monitoring"
112
+ },
113
+ source: {
114
+ type: "component",
115
+ framework: "react",
116
+ componentKey: "WorkflowInstanceList",
117
+ props: WorkflowInstanceModel
118
+ },
119
+ targets: ["react", "markdown"],
120
+ policy: { flags: ["workflow.enabled"] }
121
+ });
122
+ /**
123
+ * Workflow instance detail view with timeline.
124
+ */
125
+ const InstanceDetailPresentation = definePresentation({
126
+ meta: {
127
+ key: "workflow.instance.detail",
128
+ version: "1.0.0",
129
+ title: "Instance Details",
130
+ description: "Detailed view of a workflow instance with step timeline",
131
+ domain: "workflow-system",
132
+ owners: ["@workflow-team"],
133
+ tags: [
134
+ "workflow",
135
+ "instance",
136
+ "detail",
137
+ "timeline"
138
+ ],
139
+ stability: StabilityEnum.Experimental,
140
+ goal: "Detailed inspection of a specific workflow instance",
141
+ context: "Case management and troubleshooting"
142
+ },
143
+ source: {
144
+ type: "component",
145
+ framework: "react",
146
+ componentKey: "WorkflowInstanceDetail",
147
+ props: WorkflowInstanceModel
148
+ },
149
+ targets: ["react", "markdown"],
150
+ policy: { flags: ["workflow.enabled"] }
151
+ });
152
+ /**
153
+ * Workflow progress tracker widget.
154
+ */
155
+ const ProgressTrackerPresentation = definePresentation({
156
+ meta: {
157
+ key: "workflow.instance.progress",
158
+ version: "1.0.0",
159
+ title: "Progress Tracker",
160
+ description: "Visual progress tracker showing current step in workflow",
161
+ domain: "workflow-system",
162
+ owners: ["@workflow-team"],
163
+ tags: [
164
+ "workflow",
165
+ "progress",
166
+ "widget"
167
+ ],
168
+ stability: StabilityEnum.Experimental,
169
+ goal: "Quick view of current progress for a workflow",
170
+ context: "Embedded progress indicator in entity views"
171
+ },
172
+ source: {
173
+ type: "component",
174
+ framework: "react",
175
+ componentKey: "WorkflowProgressTracker",
176
+ props: WorkflowInstanceModel
177
+ },
178
+ targets: ["react"],
179
+ policy: { flags: ["workflow.enabled"] }
180
+ });
181
+ /**
182
+ * Approval inbox - list of pending approvals.
183
+ */
184
+ const ApprovalInboxPresentation = definePresentation({
185
+ meta: {
186
+ key: "workflow.approval.inbox",
187
+ version: "1.0.0",
188
+ title: "Approval Inbox",
189
+ description: "Inbox showing pending approval requests for current user",
190
+ domain: "workflow-system",
191
+ owners: ["@workflow-team"],
192
+ tags: [
193
+ "workflow",
194
+ "approval",
195
+ "inbox"
196
+ ],
197
+ stability: StabilityEnum.Experimental,
198
+ goal: "Managing personal workload of approval requests",
199
+ context: "Personal task management"
200
+ },
201
+ source: {
202
+ type: "component",
203
+ framework: "react",
204
+ componentKey: "ApprovalInbox",
205
+ props: ApprovalRequestModel
206
+ },
207
+ targets: ["react", "markdown"],
208
+ policy: { flags: ["workflow.approvals.enabled"] }
209
+ });
210
+ /**
211
+ * Approval request detail view.
212
+ */
213
+ const ApprovalDetailPresentation = definePresentation({
214
+ meta: {
215
+ key: "workflow.approval.detail",
216
+ version: "1.0.0",
217
+ title: "Approval Details",
218
+ description: "Detailed approval request view with context and actions",
219
+ domain: "workflow-system",
220
+ owners: ["@workflow-team"],
221
+ tags: [
222
+ "workflow",
223
+ "approval",
224
+ "detail"
225
+ ],
226
+ stability: StabilityEnum.Experimental,
227
+ goal: "Decision support for an approval request",
228
+ context: "Specific approval action"
229
+ },
230
+ source: {
231
+ type: "component",
232
+ framework: "react",
233
+ componentKey: "ApprovalRequestDetail",
234
+ props: ApprovalRequestModel
235
+ },
236
+ targets: ["react", "markdown"],
237
+ policy: { flags: ["workflow.approvals.enabled"] }
238
+ });
239
+ /**
240
+ * Approval decision form.
241
+ */
242
+ const ApprovalFormPresentation = definePresentation({
243
+ meta: {
244
+ key: "workflow.approval.form",
245
+ version: "1.0.0",
246
+ title: "Approval Form",
247
+ description: "Form for submitting approval decisions",
248
+ domain: "workflow-system",
249
+ owners: ["@workflow-team"],
250
+ tags: [
251
+ "workflow",
252
+ "approval",
253
+ "form"
254
+ ],
255
+ stability: StabilityEnum.Experimental,
256
+ goal: "Submitting a decision on an approval request",
257
+ context: "Approval decision dialog"
258
+ },
259
+ source: {
260
+ type: "component",
261
+ framework: "react",
262
+ componentKey: "ApprovalDecisionForm"
263
+ },
264
+ targets: ["react"],
265
+ policy: { flags: ["workflow.approvals.enabled"] }
266
+ });
267
+ /**
268
+ * Pending approvals count badge.
269
+ */
270
+ const PendingApprovalsBadgePresentation = definePresentation({
271
+ meta: {
272
+ key: "workflow.approval.badge",
273
+ version: "1.0.0",
274
+ title: "Pending Approvals Badge",
275
+ description: "Badge showing count of pending approvals",
276
+ domain: "workflow-system",
277
+ owners: ["@workflow-team"],
278
+ tags: [
279
+ "workflow",
280
+ "approval",
281
+ "badge",
282
+ "widget"
283
+ ],
284
+ stability: StabilityEnum.Experimental,
285
+ goal: "Visual notification of pending approvals",
286
+ context: "Global navigation or sidebar"
287
+ },
288
+ source: {
289
+ type: "component",
290
+ framework: "react",
291
+ componentKey: "PendingApprovalsBadge"
292
+ },
293
+ targets: ["react"],
294
+ policy: { flags: ["workflow.approvals.enabled"] }
295
+ });
296
+ /**
297
+ * Workflow metrics dashboard widget.
298
+ */
299
+ const WorkflowMetricsPresentation = definePresentation({
300
+ meta: {
301
+ key: "workflow.metrics",
302
+ version: "1.0.0",
303
+ title: "Workflow Metrics",
304
+ description: "Dashboard widget showing workflow metrics and statistics",
305
+ domain: "workflow-system",
306
+ owners: ["@workflow-team"],
307
+ tags: [
308
+ "workflow",
309
+ "metrics",
310
+ "dashboard"
311
+ ],
312
+ stability: StabilityEnum.Experimental,
313
+ goal: "Monitoring throughput and bottlenecks",
314
+ context: "System performance dashboard"
315
+ },
316
+ source: {
317
+ type: "component",
318
+ framework: "react",
319
+ componentKey: "WorkflowMetricsDashboard"
320
+ },
321
+ targets: ["react", "markdown"],
322
+ policy: { flags: ["workflow.metrics.enabled"] }
323
+ });
324
+ const WorkflowSystemPresentations = {
325
+ WorkflowDesignerPresentation,
326
+ WorkflowListPresentation,
327
+ WorkflowDetailPresentation,
328
+ InstanceListPresentation,
329
+ InstanceDetailPresentation,
330
+ ProgressTrackerPresentation,
331
+ ApprovalInboxPresentation,
332
+ ApprovalDetailPresentation,
333
+ ApprovalFormPresentation,
334
+ PendingApprovalsBadgePresentation,
335
+ WorkflowMetricsPresentation
336
+ };
337
+
338
+ //#endregion
339
+ export { ApprovalDetailPresentation, ApprovalFormPresentation, ApprovalInboxPresentation, InstanceDetailPresentation, InstanceListPresentation, PendingApprovalsBadgePresentation, ProgressTrackerPresentation, WorkflowDesignerPresentation, WorkflowDetailPresentation, WorkflowListPresentation, WorkflowMetricsPresentation, WorkflowSystemPresentations };
340
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/presentations/index.ts"],"sourcesContent":["/**\n * Workflow System Presentation Descriptors\n */\nimport { definePresentation, StabilityEnum } from '@contractspec/lib.contracts';\nimport { WorkflowDefinitionModel } from '../workflow/workflow.schema';\nimport { WorkflowInstanceModel } from '../instance/instance.schema';\nimport { ApprovalRequestModel } from '../approval/approval.schema';\n\n// ============ Workflow Definition Presentations ============\n\n/**\n * Workflow designer canvas for building workflows.\n */\nexport const WorkflowDesignerPresentation = definePresentation({\n meta: {\n key: 'workflow.designer',\n version: '1.0.0',\n title: 'Workflow Designer',\n description: 'Visual workflow designer with drag-and-drop steps',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'designer', 'admin'],\n stability: StabilityEnum.Experimental,\n goal: 'Building and modifying workflow definitions',\n context: 'Workflow administration and setup',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowDesigner',\n props: WorkflowDefinitionModel,\n },\n targets: ['react'],\n policy: {\n flags: ['workflow.designer.enabled'],\n },\n});\n\n/**\n * List of workflow definitions.\n */\nexport const WorkflowListPresentation = definePresentation({\n meta: {\n key: 'workflow.definition.list',\n version: '1.0.0',\n title: 'Workflow List',\n description: 'List of workflow definitions with status and actions',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'list', 'admin'],\n stability: StabilityEnum.Experimental,\n goal: 'Overview of all defined workflows',\n context: 'Workflow management dashboard',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowDefinitionList',\n props: WorkflowDefinitionModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.enabled'],\n },\n});\n\n/**\n * Workflow definition detail view.\n */\nexport const WorkflowDetailPresentation = definePresentation({\n meta: {\n key: 'workflow.definition.detail',\n version: '1.0.0',\n title: 'Workflow Details',\n description: 'Detailed view of a workflow definition with steps',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'detail'],\n stability: StabilityEnum.Experimental,\n goal: 'Viewing technical details of a workflow definition',\n context: 'Workflow inspection and debugging',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowDefinitionDetail',\n props: WorkflowDefinitionModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.enabled'],\n },\n});\n\n// ============ Workflow Instance Presentations ============\n\n/**\n * List of running workflow instances.\n */\nexport const InstanceListPresentation = definePresentation({\n meta: {\n key: 'workflow.instance.list',\n version: '1.0.0',\n title: 'Instance List',\n description: 'List of workflow instances with status and progress',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'instance', 'list'],\n stability: StabilityEnum.Experimental,\n goal: 'Monitoring active and past workflow executions',\n context: 'Operations monitoring',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowInstanceList',\n props: WorkflowInstanceModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.enabled'],\n },\n});\n\n/**\n * Workflow instance detail view with timeline.\n */\nexport const InstanceDetailPresentation = definePresentation({\n meta: {\n key: 'workflow.instance.detail',\n version: '1.0.0',\n title: 'Instance Details',\n description: 'Detailed view of a workflow instance with step timeline',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'instance', 'detail', 'timeline'],\n stability: StabilityEnum.Experimental,\n goal: 'Detailed inspection of a specific workflow instance',\n context: 'Case management and troubleshooting',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowInstanceDetail',\n props: WorkflowInstanceModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.enabled'],\n },\n});\n\n/**\n * Workflow progress tracker widget.\n */\nexport const ProgressTrackerPresentation = definePresentation({\n meta: {\n key: 'workflow.instance.progress',\n version: '1.0.0',\n title: 'Progress Tracker',\n description: 'Visual progress tracker showing current step in workflow',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'progress', 'widget'],\n stability: StabilityEnum.Experimental,\n goal: 'Quick view of current progress for a workflow',\n context: 'Embedded progress indicator in entity views',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowProgressTracker',\n props: WorkflowInstanceModel,\n },\n targets: ['react'],\n policy: {\n flags: ['workflow.enabled'],\n },\n});\n\n// ============ Approval Presentations ============\n\n/**\n * Approval inbox - list of pending approvals.\n */\nexport const ApprovalInboxPresentation = definePresentation({\n meta: {\n key: 'workflow.approval.inbox',\n version: '1.0.0',\n title: 'Approval Inbox',\n description: 'Inbox showing pending approval requests for current user',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'approval', 'inbox'],\n stability: StabilityEnum.Experimental,\n goal: 'Managing personal workload of approval requests',\n context: 'Personal task management',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'ApprovalInbox',\n props: ApprovalRequestModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.approvals.enabled'],\n },\n});\n\n/**\n * Approval request detail view.\n */\nexport const ApprovalDetailPresentation = definePresentation({\n meta: {\n key: 'workflow.approval.detail',\n version: '1.0.0',\n title: 'Approval Details',\n description: 'Detailed approval request view with context and actions',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'approval', 'detail'],\n stability: StabilityEnum.Experimental,\n goal: 'Decision support for an approval request',\n context: 'Specific approval action',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'ApprovalRequestDetail',\n props: ApprovalRequestModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.approvals.enabled'],\n },\n});\n\n/**\n * Approval decision form.\n */\nexport const ApprovalFormPresentation = definePresentation({\n meta: {\n key: 'workflow.approval.form',\n version: '1.0.0',\n title: 'Approval Form',\n description: 'Form for submitting approval decisions',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'approval', 'form'],\n stability: StabilityEnum.Experimental,\n goal: 'Submitting a decision on an approval request',\n context: 'Approval decision dialog',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'ApprovalDecisionForm',\n },\n targets: ['react'],\n policy: {\n flags: ['workflow.approvals.enabled'],\n },\n});\n\n// ============ Dashboard Widgets ============\n\n/**\n * Pending approvals count badge.\n */\nexport const PendingApprovalsBadgePresentation = definePresentation({\n meta: {\n key: 'workflow.approval.badge',\n version: '1.0.0',\n title: 'Pending Approvals Badge',\n description: 'Badge showing count of pending approvals',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'approval', 'badge', 'widget'],\n stability: StabilityEnum.Experimental,\n goal: 'Visual notification of pending approvals',\n context: 'Global navigation or sidebar',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'PendingApprovalsBadge',\n },\n targets: ['react'],\n policy: {\n flags: ['workflow.approvals.enabled'],\n },\n});\n\n/**\n * Workflow metrics dashboard widget.\n */\nexport const WorkflowMetricsPresentation = definePresentation({\n meta: {\n key: 'workflow.metrics',\n version: '1.0.0',\n title: 'Workflow Metrics',\n description: 'Dashboard widget showing workflow metrics and statistics',\n domain: 'workflow-system',\n owners: ['@workflow-team'],\n tags: ['workflow', 'metrics', 'dashboard'],\n stability: StabilityEnum.Experimental,\n goal: 'Monitoring throughput and bottlenecks',\n context: 'System performance dashboard',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'WorkflowMetricsDashboard',\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['workflow.metrics.enabled'],\n },\n});\n\n// ============ All Presentations ============\n\nexport const WorkflowSystemPresentations = {\n // Definition\n WorkflowDesignerPresentation,\n WorkflowListPresentation,\n WorkflowDetailPresentation,\n\n // Instance\n InstanceListPresentation,\n InstanceDetailPresentation,\n ProgressTrackerPresentation,\n\n // Approval\n ApprovalInboxPresentation,\n ApprovalDetailPresentation,\n ApprovalFormPresentation,\n PendingApprovalsBadgePresentation,\n\n // Dashboard\n WorkflowMetricsPresentation,\n};\n"],"mappings":";;;;;;;;;;;;AAaA,MAAa,+BAA+B,mBAAmB;CAC7D,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aAAa;EACb,QAAQ;EAC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f;CACD,SAAS,CAAC,SAAS,WAAW;CAC9B,QAAQ,EACN,OAAO,CAAC,2BAA2B,EACpC;CACF,CAAC;AAIF,MAAa,8BAA8B;CAEzC;CACA;CACA;CAGA;CACA;CACA;CAGA;CACA;CACA;CACA;CAGA;CACD"}
@@ -0,0 +1,10 @@
1
+ import { DatabasePort } from "@contractspec/lib.runtime-sandbox";
2
+
3
+ //#region src/seeders/index.d.ts
4
+ declare function seedWorkflowSystem(params: {
5
+ projectId: string;
6
+ db: DatabasePort;
7
+ }): Promise<void>;
8
+ //#endregion
9
+ export { seedWorkflowSystem };
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","names":[],"sources":["../../src/seeders/index.ts"],"sourcesContent":[],"mappings":";;;iBAEsB,kBAAA;;EAAA,EAAA,EAEhB,YAFgB;IAGrB"}
@@ -0,0 +1,19 @@
1
+ //#region src/seeders/index.ts
2
+ async function seedWorkflowSystem(params) {
3
+ const { projectId, db } = params;
4
+ if ((await db.query(`SELECT COUNT(*) as count FROM workflow_definition WHERE "projectId" = $1`, [projectId])).rows[0]?.count > 0) return;
5
+ await db.execute(`INSERT INTO workflow_definition (id, "projectId", "organizationId", name, description, type, status)
6
+ VALUES ($1, $2, $3, $4, $5, $6, $7)`, [
7
+ "wf_1",
8
+ projectId,
9
+ "org_demo",
10
+ "Approval Workflow",
11
+ "Demo approval workflow",
12
+ "APPROVAL",
13
+ "ACTIVE"
14
+ ]);
15
+ }
16
+
17
+ //#endregion
18
+ export { seedWorkflowSystem };
19
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/seeders/index.ts"],"sourcesContent":["import type { DatabasePort } from '@contractspec/lib.runtime-sandbox';\n\nexport async function seedWorkflowSystem(params: {\n projectId: string;\n db: DatabasePort;\n}) {\n const { projectId, db } = params;\n\n const existing = await db.query(\n `SELECT COUNT(*) as count FROM workflow_definition WHERE \"projectId\" = $1`,\n [projectId]\n );\n if ((existing.rows[0]?.count as number) > 0) return;\n\n await db.execute(\n `INSERT INTO workflow_definition (id, \"projectId\", \"organizationId\", name, description, type, status)\n VALUES ($1, $2, $3, $4, $5, $6, $7)`,\n [\n 'wf_1',\n projectId,\n 'org_demo',\n 'Approval Workflow',\n 'Demo approval workflow',\n 'APPROVAL',\n 'ACTIVE',\n ]\n );\n}\n"],"mappings":";AAEA,eAAsB,mBAAmB,QAGtC;CACD,MAAM,EAAE,WAAW,OAAO;AAM1B,MAJiB,MAAM,GAAG,MACxB,4EACA,CAAC,UAAU,CACZ,EACa,KAAK,IAAI,QAAmB,EAAG;AAE7C,OAAM,GAAG,QACP;2CAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACD,CACF"}
@@ -0,0 +1,3 @@
1
+ import { ApprovalRequestRecord, HandlerContext, WorkflowDefinitionRecord, WorkflowInstanceRecord, WorkflowStepRecord } from "./types.js";
2
+ import { mockDataStore } from "./mock-data.js";
3
+ export { ApprovalRequestRecord, HandlerContext, WorkflowDefinitionRecord, WorkflowInstanceRecord, WorkflowStepRecord, mockDataStore };
@@ -0,0 +1,3 @@
1
+ import { mockDataStore } from "./mock-data.js";
2
+
3
+ export { mockDataStore };
@@ -0,0 +1,19 @@
1
+ import { ApprovalRequestRecord, WorkflowDefinitionRecord, WorkflowInstanceRecord, WorkflowStepRecord } from "./types.js";
2
+
3
+ //#region src/shared/mock-data.d.ts
4
+
5
+ declare const mockDataStore: {
6
+ workflows: Map<string, WorkflowDefinitionRecord>;
7
+ steps: Map<string, WorkflowStepRecord>;
8
+ instances: Map<string, WorkflowInstanceRecord>;
9
+ approvals: Map<string, ApprovalRequestRecord>;
10
+ stepExecutions: Map<string, {
11
+ id: string;
12
+ instanceId: string;
13
+ stepId: string;
14
+ status: string;
15
+ }>;
16
+ };
17
+ //#endregion
18
+ export { mockDataStore };
19
+ //# sourceMappingURL=mock-data.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-data.d.ts","names":[],"sources":["../../src/shared/mock-data.ts"],"sourcesContent":[],"mappings":";;;;cAYa"}
@@ -0,0 +1,12 @@
1
+ //#region src/shared/mock-data.ts
2
+ const mockDataStore = {
3
+ workflows: /* @__PURE__ */ new Map(),
4
+ steps: /* @__PURE__ */ new Map(),
5
+ instances: /* @__PURE__ */ new Map(),
6
+ approvals: /* @__PURE__ */ new Map(),
7
+ stepExecutions: /* @__PURE__ */ new Map()
8
+ };
9
+
10
+ //#endregion
11
+ export { mockDataStore };
12
+ //# sourceMappingURL=mock-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-data.js","names":[],"sources":["../../src/shared/mock-data.ts"],"sourcesContent":["/**\n * Mock data store for workflow system.\n * In production, this would be backed by a database.\n */\n\nimport type {\n WorkflowDefinitionRecord,\n WorkflowStepRecord,\n WorkflowInstanceRecord,\n ApprovalRequestRecord,\n} from './types';\n\nexport const mockDataStore = {\n workflows: new Map<string, WorkflowDefinitionRecord>(),\n steps: new Map<string, WorkflowStepRecord>(),\n instances: new Map<string, WorkflowInstanceRecord>(),\n approvals: new Map<string, ApprovalRequestRecord>(),\n stepExecutions: new Map<\n string,\n { id: string; instanceId: string; stepId: string; status: string }\n >(),\n};\n"],"mappings":";AAYA,MAAa,gBAAgB;CAC3B,2BAAW,IAAI,KAAuC;CACtD,uBAAO,IAAI,KAAiC;CAC5C,2BAAW,IAAI,KAAqC;CACpD,2BAAW,IAAI,KAAoC;CACnD,gCAAgB,IAAI,KAGjB;CACJ"}
@@ -0,0 +1,81 @@
1
+ //#region src/shared/types.d.ts
2
+ /**
3
+ * Shared types for workflow system handlers.
4
+ */
5
+ interface WorkflowDefinitionRecord {
6
+ id: string;
7
+ key: string;
8
+ name: string;
9
+ description?: string;
10
+ version: string;
11
+ status: 'DRAFT' | 'ACTIVE' | 'DEPRECATED' | 'ARCHIVED';
12
+ triggerType: 'MANUAL' | 'EVENT' | 'SCHEDULED' | 'API';
13
+ initialStepId?: string;
14
+ featureFlagKey?: string;
15
+ organizationId: string;
16
+ createdBy: string;
17
+ createdAt: Date;
18
+ updatedAt: Date;
19
+ publishedAt?: Date;
20
+ }
21
+ interface WorkflowStepRecord {
22
+ id: string;
23
+ workflowDefinitionId: string;
24
+ key: string;
25
+ name: string;
26
+ description?: string;
27
+ type: 'START' | 'APPROVAL' | 'TASK' | 'CONDITION' | 'PARALLEL' | 'WAIT' | 'ACTION' | 'END';
28
+ position: number;
29
+ transitions: Record<string, string>;
30
+ approvalMode?: 'ANY' | 'ALL' | 'MAJORITY' | 'SEQUENTIAL';
31
+ approverRoles: string[];
32
+ timeoutSeconds?: number;
33
+ createdAt: Date;
34
+ updatedAt: Date;
35
+ }
36
+ interface WorkflowInstanceRecord {
37
+ id: string;
38
+ workflowDefinitionId: string;
39
+ referenceId?: string;
40
+ referenceType?: string;
41
+ status: 'PENDING' | 'RUNNING' | 'WAITING' | 'PAUSED' | 'COMPLETED' | 'CANCELLED' | 'FAILED' | 'TIMEOUT';
42
+ currentStepId?: string;
43
+ contextData: Record<string, unknown>;
44
+ triggeredBy: string;
45
+ organizationId: string;
46
+ priority: number;
47
+ dueAt?: Date;
48
+ outcome?: string;
49
+ resultData?: Record<string, unknown>;
50
+ errorMessage?: string;
51
+ createdAt: Date;
52
+ updatedAt: Date;
53
+ startedAt?: Date;
54
+ completedAt?: Date;
55
+ }
56
+ interface ApprovalRequestRecord {
57
+ id: string;
58
+ workflowInstanceId: string;
59
+ stepExecutionId: string;
60
+ approverId: string;
61
+ approverRole?: string;
62
+ title: string;
63
+ description?: string;
64
+ status: 'PENDING' | 'APPROVED' | 'REJECTED' | 'DELEGATED' | 'ESCALATED' | 'WITHDRAWN' | 'EXPIRED';
65
+ decision?: 'APPROVE' | 'REJECT' | 'REQUEST_CHANGES' | 'DELEGATE' | 'ABSTAIN';
66
+ decisionComment?: string;
67
+ decidedAt?: Date;
68
+ dueAt?: Date;
69
+ contextSnapshot?: Record<string, unknown>;
70
+ sequenceOrder: number;
71
+ createdAt: Date;
72
+ updatedAt: Date;
73
+ }
74
+ interface HandlerContext {
75
+ userId: string;
76
+ userRoles: string[];
77
+ organizationId: string;
78
+ }
79
+ //#endregion
80
+ export { ApprovalRequestRecord, HandlerContext, WorkflowDefinitionRecord, WorkflowInstanceRecord, WorkflowStepRecord };
81
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","names":[],"sources":["../../src/shared/types.ts"],"sourcesContent":[],"mappings":";;AAIA;;AAaa,UAbI,wBAAA,CAaJ;EACG,EAAA,EAAA,MAAA;EAAI,GAAA,EAAA,MAAA;EAGH,IAAA,EAAA,MAAA;EAgBF,WAAA,CAAA,EAAA,MAAA;EAIF,OAAA,EAAA,MAAA;EACA,MAAA,EAAA,OAAA,GAAA,QAAA,GAAA,YAAA,GAAA,UAAA;EAAI,WAAA,EAAA,QAAA,GAAA,OAAA,GAAA,WAAA,GAAA,KAAA;EAGA,aAAA,CAAA,EAAA,MAAA;EAeF,cAAA,CAAA,EAAA,MAAA;EAIL,cAAA,EAAA,MAAA;EAEK,SAAA,EAAA,MAAA;EAEF,SAAA,EApDA,IAoDA;EACA,SAAA,EApDA,IAoDA;EACC,WAAA,CAAA,EApDE,IAoDF;;AACM,UAlDH,kBAAA,CAkDG;EAGH,EAAA,EAAA,MAAA;EAkBH,oBAAA,EAAA,MAAA;EACJ,GAAA,EAAA,MAAA;EACU,IAAA,EAAA,MAAA;EAEP,WAAA,CAAA,EAAA,MAAA;EACA,IAAA,EAAA,OAAA,GAAA,UAAA,GAAA,MAAA,GAAA,WAAA,GAAA,UAAA,GAAA,MAAA,GAAA,QAAA,GAAA,KAAA;EAAI,QAAA,EAAA,MAAA;EAGA,WAAA,EA/DF,MA+DgB,CAAA,MAAA,EAAA,MAAA,CAAA;;;;aA3DlB;aACA;;UAGI,sBAAA;;;;;;;eAeF;;;;UAIL;;eAEK;;aAEF;aACA;cACC;gBACE;;UAGC,qBAAA;;;;;;;;;;;cAkBH;UACJ;oBACU;;aAEP;aACA;;UAGI,cAAA"}
File without changes