@shipfox/client-projects 4.0.0 → 5.0.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.
Files changed (42) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/CHANGELOG.md +21 -0
  3. package/dist/feature.d.ts +0 -10
  4. package/dist/feature.d.ts.map +1 -1
  5. package/dist/feature.js +0 -12
  6. package/dist/feature.js.map +1 -1
  7. package/dist/hooks/api/projects.d.ts +5 -1
  8. package/dist/hooks/api/projects.d.ts.map +1 -1
  9. package/dist/hooks/api/projects.js +12 -1
  10. package/dist/hooks/api/projects.js.map +1 -1
  11. package/dist/index.d.ts +1 -3
  12. package/dist/index.d.ts.map +1 -1
  13. package/dist/index.js +1 -2
  14. package/dist/index.js.map +1 -1
  15. package/dist/pages/create-project-page.stories.d.ts.map +1 -1
  16. package/dist/pages/create-project-page.stories.js +1 -4
  17. package/dist/pages/create-project-page.stories.js.map +1 -1
  18. package/dist/tsconfig.test.tsbuildinfo +1 -1
  19. package/package.json +7 -9
  20. package/src/feature.ts +0 -12
  21. package/src/hooks/api/projects.ts +23 -1
  22. package/src/index.ts +1 -6
  23. package/src/pages/create-project-page.stories.tsx +1 -4
  24. package/test/pages.tsx +2 -17
  25. package/tsconfig.build.tsbuildinfo +1 -1
  26. package/dist/components/workspace-setup-guard.d.ts +0 -9
  27. package/dist/components/workspace-setup-guard.d.ts.map +0 -1
  28. package/dist/components/workspace-setup-guard.js +0 -160
  29. package/dist/components/workspace-setup-guard.js.map +0 -1
  30. package/dist/pages/project-workflows-page.d.ts +0 -4
  31. package/dist/pages/project-workflows-page.d.ts.map +0 -1
  32. package/dist/pages/project-workflows-page.js +0 -481
  33. package/dist/pages/project-workflows-page.js.map +0 -1
  34. package/dist/routes/workflows.d.ts +0 -5
  35. package/dist/routes/workflows.d.ts.map +0 -1
  36. package/dist/routes/workflows.js +0 -16
  37. package/dist/routes/workflows.js.map +0 -1
  38. package/src/components/workspace-setup-guard.test.tsx +0 -534
  39. package/src/components/workspace-setup-guard.tsx +0 -185
  40. package/src/pages/project-workflows-page.test.tsx +0 -258
  41. package/src/pages/project-workflows-page.tsx +0 -445
  42. package/src/routes/workflows.tsx +0 -10
@@ -1,481 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { ApiError } from '@shipfox/client-api';
3
- import { QueryLoadError } from '@shipfox/client-ui';
4
- import { useFireManualWorkflowMutation } from '@shipfox/client-workflows';
5
- import { Button } from '@shipfox/react-ui/button';
6
- import { Callout } from '@shipfox/react-ui/callout';
7
- import { EmptyState } from '@shipfox/react-ui/empty-state';
8
- import { Icon } from '@shipfox/react-ui/icon';
9
- import { LoadErrorState } from '@shipfox/react-ui/load-error-state';
10
- import { RelativeTime, RelativeTimeProvider } from '@shipfox/react-ui/relative-time';
11
- import { Sheet, SheetBody, SheetContent, SheetDescription, SheetHeader, SheetTitle } from '@shipfox/react-ui/sheet';
12
- import { Skeleton } from '@shipfox/react-ui/skeleton';
13
- import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '@shipfox/react-ui/table';
14
- import { toast } from '@shipfox/react-ui/toast';
15
- import { Code, Header, Text } from '@shipfox/react-ui/typography';
16
- import { useState } from 'react';
17
- import { SourceStrip } from '#components/source-strip.js';
18
- import { useDefinitionsInfiniteQuery } from '#hooks/api/definitions.js';
19
- import { useProjectQuery } from '#hooks/api/projects.js';
20
- export function ProjectWorkflowsPage({ projectId }) {
21
- return /*#__PURE__*/ _jsx(RelativeTimeProvider, {
22
- children: /*#__PURE__*/ _jsx(ProjectWorkflowsPageInner, {
23
- projectId: projectId
24
- })
25
- });
26
- }
27
- function ProjectWorkflowsPageInner({ projectId }) {
28
- const projectQuery = useProjectQuery(projectId);
29
- const definitionsQuery = useDefinitionsInfiniteQuery(projectId);
30
- const fireManual = useFireManualWorkflowMutation();
31
- const [selectedDefinition, setSelectedDefinition] = useState(null);
32
- const [runError, setRunError] = useState(null);
33
- const definitions = definitionsQuery.data?.pages.flatMap((page)=>page.definitions) ?? [];
34
- const sync = definitionsQuery.data?.pages[0]?.sync;
35
- async function handleRun(definition) {
36
- setRunError(null);
37
- if (!definition.manual_trigger) return;
38
- try {
39
- await fireManual.mutateAsync({
40
- projectId,
41
- definitionId: definition.id
42
- });
43
- toast.success('Run queued');
44
- } catch (error) {
45
- const message = errorMessage(error, 'Could not queue run.');
46
- setRunError({
47
- definitionId: definition.id,
48
- message
49
- });
50
- toast.error(message);
51
- }
52
- }
53
- return /*#__PURE__*/ _jsxs("div", {
54
- className: "flex w-full flex-col gap-24",
55
- children: [
56
- projectQuery.isPending ? /*#__PURE__*/ _jsxs("div", {
57
- className: "flex flex-col gap-12",
58
- children: [
59
- /*#__PURE__*/ _jsx(Skeleton, {
60
- className: "h-28 w-1/3"
61
- }),
62
- /*#__PURE__*/ _jsx(Skeleton, {
63
- className: "h-18 w-1/2"
64
- })
65
- ]
66
- }) : null,
67
- projectQuery.isError && projectQuery.data === undefined ? projectQuery.error instanceof ApiError && projectQuery.error.status === 404 ? /*#__PURE__*/ _jsx(EmptyState, {
68
- icon: "errorWarningLine",
69
- title: "Project not found",
70
- description: "This project doesn't exist, or you don't have access to it."
71
- }) : /*#__PURE__*/ _jsx(QueryLoadError, {
72
- query: projectQuery,
73
- subject: "project"
74
- }) : null,
75
- projectQuery.data ? /*#__PURE__*/ _jsxs(_Fragment, {
76
- children: [
77
- /*#__PURE__*/ _jsxs("header", {
78
- className: "flex flex-col gap-4",
79
- children: [
80
- /*#__PURE__*/ _jsx(Header, {
81
- variant: "h2",
82
- children: "Workflows"
83
- }),
84
- /*#__PURE__*/ _jsx(Text, {
85
- size: "sm",
86
- className: "text-foreground-neutral-muted",
87
- children: "Synced workflow definitions for this project source."
88
- })
89
- ]
90
- }),
91
- /*#__PURE__*/ _jsx(SourceStrip, {
92
- connectionId: projectQuery.data.source.connection_id,
93
- externalRepositoryId: projectQuery.data.source.external_repository_id,
94
- sync: sync,
95
- isPending: definitionsQuery.isPending
96
- }),
97
- /*#__PURE__*/ _jsx(WorkflowSyncAlert, {
98
- sync: sync
99
- }),
100
- /*#__PURE__*/ _jsx(WorkflowDefinitionsList, {
101
- definitions: definitions,
102
- isPending: definitionsQuery.isPending,
103
- isError: definitionsQuery.isError,
104
- sync: sync ?? null,
105
- runError: runError,
106
- runningDefinitionId: fireManual.isPending && fireManual.variables ? fireManual.variables.definitionId : null,
107
- hasNextPage: definitionsQuery.hasNextPage,
108
- isFetchingNextPage: definitionsQuery.isFetchingNextPage,
109
- isFetchNextPageError: definitionsQuery.isFetchNextPageError,
110
- onRetry: ()=>definitionsQuery.refetch(),
111
- onLoadMore: ()=>definitionsQuery.fetchNextPage(),
112
- onOpenDefinition: setSelectedDefinition,
113
- onRun: (definition)=>{
114
- void handleRun(definition);
115
- }
116
- })
117
- ]
118
- }) : null,
119
- /*#__PURE__*/ _jsx(DefinitionSheet, {
120
- definition: selectedDefinition,
121
- onOpenChange: (open)=>{
122
- if (!open) setSelectedDefinition(null);
123
- }
124
- })
125
- ]
126
- });
127
- }
128
- function WorkflowDefinitionsList({ definitions, isPending, isError, sync, runError, runningDefinitionId, hasNextPage, isFetchingNextPage, isFetchNextPageError, onRetry, onLoadMore, onOpenDefinition, onRun }) {
129
- if (isPending) {
130
- return /*#__PURE__*/ _jsxs("div", {
131
- className: "flex flex-col gap-8",
132
- children: [
133
- /*#__PURE__*/ _jsx(Skeleton, {
134
- className: "h-40 w-full"
135
- }),
136
- /*#__PURE__*/ _jsx(Skeleton, {
137
- className: "h-40 w-full"
138
- }),
139
- /*#__PURE__*/ _jsx(Skeleton, {
140
- className: "h-40 w-full"
141
- })
142
- ]
143
- });
144
- }
145
- if (isError && definitions.length === 0) {
146
- return /*#__PURE__*/ _jsx(LoadErrorState, {
147
- title: "Couldn't load workflows",
148
- description: "Definitions could not be loaded. Source metadata remains visible.",
149
- onRetry: onRetry,
150
- retryLabel: "Retry loading workflows"
151
- });
152
- }
153
- if (definitions.length === 0) {
154
- return /*#__PURE__*/ _jsx(WorkflowEmptyState, {
155
- sync: sync
156
- });
157
- }
158
- return /*#__PURE__*/ _jsxs(_Fragment, {
159
- children: [
160
- /*#__PURE__*/ _jsx("div", {
161
- className: "hidden rounded-8 border border-border-neutral-base md:block",
162
- children: /*#__PURE__*/ _jsxs(Table, {
163
- children: [
164
- /*#__PURE__*/ _jsx(TableHeader, {
165
- children: /*#__PURE__*/ _jsxs(TableRow, {
166
- children: [
167
- /*#__PURE__*/ _jsx(TableHead, {
168
- className: "w-40"
169
- }),
170
- /*#__PURE__*/ _jsx(TableHead, {
171
- children: "Workflow"
172
- }),
173
- /*#__PURE__*/ _jsx(TableHead, {
174
- className: "w-180",
175
- children: "Updated"
176
- }),
177
- /*#__PURE__*/ _jsx(TableHead, {
178
- className: "w-80 text-right"
179
- })
180
- ]
181
- })
182
- }),
183
- /*#__PURE__*/ _jsx(TableBody, {
184
- children: definitions.map((definition)=>{
185
- const runErrorMessage = runError?.definitionId === definition.id ? runError.message : null;
186
- const isRunning = runningDefinitionId === definition.id;
187
- return(// The workflow-name cell holds a `<button>` so the row is
188
- // keyboard-reachable (Tab focuses, Enter/Space activates
189
- // via native button semantics). The TableRow itself is no
190
- // longer clickable — a row-level onClick would be invisible
191
- // to keyboard users and require custom keydown handling.
192
- // The `group` class on the row still drives the Run button
193
- // reveal on hover or focus-within.
194
- /*#__PURE__*/ _jsxs(TableRow, {
195
- className: "group",
196
- children: [
197
- /*#__PURE__*/ _jsx(TableCell, {
198
- children: /*#__PURE__*/ _jsx(Icon, {
199
- name: sourceIcon(definition.source),
200
- className: "size-16 text-foreground-neutral-muted",
201
- "aria-hidden": "true"
202
- })
203
- }),
204
- /*#__PURE__*/ _jsx(TableCell, {
205
- className: "max-w-260",
206
- children: /*#__PURE__*/ _jsxs("div", {
207
- className: "flex min-w-0 flex-col gap-2",
208
- children: [
209
- /*#__PURE__*/ _jsxs("button", {
210
- type: "button",
211
- onClick: ()=>onOpenDefinition(definition),
212
- className: "flex min-w-0 flex-col gap-2 text-left outline-none focus-visible:shadow-border-interactive-with-active rounded-4",
213
- children: [
214
- /*#__PURE__*/ _jsx(Text, {
215
- size: "sm",
216
- bold: true,
217
- className: "truncate",
218
- children: definition.name
219
- }),
220
- /*#__PURE__*/ _jsx(Code, {
221
- className: "truncate text-foreground-neutral-muted",
222
- children: definition.config_path ?? 'Manual definition'
223
- })
224
- ]
225
- }),
226
- runErrorMessage ? /*#__PURE__*/ _jsx(Text, {
227
- size: "xs",
228
- className: "text-tag-error-text",
229
- children: runErrorMessage
230
- }) : null
231
- ]
232
- })
233
- }),
234
- /*#__PURE__*/ _jsx(TableCell, {
235
- className: "text-foreground-neutral-muted",
236
- children: /*#__PURE__*/ _jsx(RelativeTime, {
237
- value: definition.updated_at
238
- })
239
- }),
240
- /*#__PURE__*/ _jsx(TableCell, {
241
- children: definition.manual_trigger ? /*#__PURE__*/ _jsx("div", {
242
- className: "flex justify-end opacity-0 transition-opacity group-hover:opacity-100 group-focus-within:opacity-100",
243
- children: /*#__PURE__*/ _jsx(Button, {
244
- size: "xs",
245
- isLoading: isRunning,
246
- onClick: ()=>onRun(definition),
247
- children: "Run"
248
- })
249
- }) : null
250
- })
251
- ]
252
- }, definition.id));
253
- })
254
- })
255
- ]
256
- })
257
- }),
258
- /*#__PURE__*/ _jsx("div", {
259
- className: "flex flex-col rounded-8 border border-border-neutral-base md:hidden",
260
- children: definitions.map((definition)=>{
261
- const runErrorMessage = runError?.definitionId === definition.id ? runError.message : null;
262
- const isRunning = runningDefinitionId === definition.id;
263
- return /*#__PURE__*/ _jsxs("div", {
264
- className: "flex flex-col gap-10 border-b border-border-neutral-base p-12 last:border-b-0",
265
- children: [
266
- /*#__PURE__*/ _jsxs("button", {
267
- type: "button",
268
- className: "flex min-w-0 items-start gap-10 text-left",
269
- onClick: ()=>onOpenDefinition(definition),
270
- children: [
271
- /*#__PURE__*/ _jsx(Icon, {
272
- name: sourceIcon(definition.source),
273
- className: "size-16 shrink-0 text-foreground-neutral-muted",
274
- "aria-hidden": "true"
275
- }),
276
- /*#__PURE__*/ _jsxs("div", {
277
- className: "flex min-w-0 flex-col gap-4",
278
- children: [
279
- /*#__PURE__*/ _jsx(Text, {
280
- size: "sm",
281
- bold: true,
282
- className: "break-words",
283
- children: definition.name
284
- }),
285
- /*#__PURE__*/ _jsx(Code, {
286
- className: "break-words text-foreground-neutral-muted",
287
- children: definition.config_path ?? 'Manual definition'
288
- })
289
- ]
290
- })
291
- ]
292
- }),
293
- /*#__PURE__*/ _jsxs("div", {
294
- className: "flex items-center justify-between gap-8",
295
- children: [
296
- /*#__PURE__*/ _jsxs(Text, {
297
- size: "xs",
298
- className: "text-foreground-neutral-muted",
299
- children: [
300
- "Updated ",
301
- /*#__PURE__*/ _jsx(RelativeTime, {
302
- value: definition.updated_at
303
- })
304
- ]
305
- }),
306
- definition.manual_trigger ? /*#__PURE__*/ _jsx(Button, {
307
- size: "sm",
308
- isLoading: isRunning,
309
- onClick: ()=>onRun(definition),
310
- children: "Run"
311
- }) : null
312
- ]
313
- }),
314
- runErrorMessage ? /*#__PURE__*/ _jsx(Text, {
315
- size: "xs",
316
- className: "text-tag-error-text",
317
- children: runErrorMessage
318
- }) : null
319
- ]
320
- }, definition.id);
321
- })
322
- }),
323
- isFetchNextPageError ? /*#__PURE__*/ _jsx(Callout, {
324
- role: "alert",
325
- type: "error",
326
- children: /*#__PURE__*/ _jsxs("div", {
327
- className: "flex items-center justify-between gap-12",
328
- children: [
329
- /*#__PURE__*/ _jsx(Text, {
330
- size: "sm",
331
- children: "Could not load more workflows."
332
- }),
333
- /*#__PURE__*/ _jsx(Button, {
334
- size: "sm",
335
- variant: "secondary",
336
- onClick: onLoadMore,
337
- children: "Retry"
338
- })
339
- ]
340
- })
341
- }) : null,
342
- hasNextPage ? /*#__PURE__*/ _jsx("div", {
343
- className: "flex justify-center",
344
- children: /*#__PURE__*/ _jsx(Button, {
345
- size: "sm",
346
- variant: "secondary",
347
- isLoading: isFetchingNextPage,
348
- onClick: onLoadMore,
349
- children: "Load more"
350
- })
351
- }) : null
352
- ]
353
- });
354
- }
355
- function sourceIcon(source) {
356
- return source === 'vcs' ? 'gitBranchLine' : 'terminalLine';
357
- }
358
- function WorkflowEmptyState({ sync }) {
359
- const message = sync?.status === 'failed' && sync.last_error_code === 'no-workflow-files' ? 'No workflow files found under .shipfox/workflows/.' : sync?.status === 'failed' ? sync.last_error_message ?? 'Workflow definitions could not be synced.' : sync?.status === 'syncing' ? 'Workflow definitions are being discovered.' : sync?.status === 'succeeded' ? 'No workflow definitions found.' : 'Workflow sync has not reported yet.';
360
- return /*#__PURE__*/ _jsx(EmptyState, {
361
- icon: "flowChart",
362
- title: "No workflows",
363
- description: message
364
- });
365
- }
366
- function WorkflowSyncAlert({ sync }) {
367
- if (sync?.status !== 'failed') return null;
368
- return /*#__PURE__*/ _jsx(Callout, {
369
- role: "alert",
370
- type: "error",
371
- children: /*#__PURE__*/ _jsxs("div", {
372
- className: "flex flex-col gap-4",
373
- children: [
374
- /*#__PURE__*/ _jsx(Text, {
375
- size: "sm",
376
- bold: true,
377
- children: "Workflow sync failed"
378
- }),
379
- /*#__PURE__*/ _jsx(Text, {
380
- size: "sm",
381
- children: sync.last_error_message ?? 'The latest workflow sync failed before definitions updated.'
382
- })
383
- ]
384
- })
385
- });
386
- }
387
- function DefinitionSheet({ definition, onOpenChange }) {
388
- const normalizedJson = definition ? JSON.stringify({
389
- workflow_document: definition.workflow_document,
390
- workflow_model: definition.workflow_model
391
- }, null, 2) : '';
392
- return /*#__PURE__*/ _jsx(Sheet, {
393
- open: Boolean(definition),
394
- onOpenChange: onOpenChange,
395
- children: /*#__PURE__*/ _jsx(SheetContent, {
396
- className: "w-full sm:max-w-[560px]",
397
- children: definition ? /*#__PURE__*/ _jsxs(_Fragment, {
398
- children: [
399
- /*#__PURE__*/ _jsxs(SheetHeader, {
400
- children: [
401
- /*#__PURE__*/ _jsx(SheetTitle, {
402
- children: definition.name
403
- }),
404
- /*#__PURE__*/ _jsx(SheetDescription, {
405
- children: definition.config_path ?? 'Manual workflow definition'
406
- })
407
- ]
408
- }),
409
- /*#__PURE__*/ _jsxs(SheetBody, {
410
- className: "gap-18",
411
- children: [
412
- /*#__PURE__*/ _jsxs("div", {
413
- className: "grid w-full gap-10",
414
- children: [
415
- /*#__PURE__*/ _jsx(Metadata, {
416
- label: "Definition id",
417
- value: definition.id
418
- }),
419
- /*#__PURE__*/ _jsx(Metadata, {
420
- label: "Source",
421
- value: definition.source
422
- }),
423
- /*#__PURE__*/ _jsx(Metadata, {
424
- label: "Ref",
425
- value: definition.ref ?? 'Not set'
426
- }),
427
- /*#__PURE__*/ _jsx(Metadata, {
428
- label: "SHA",
429
- value: definition.sha ?? 'Not set'
430
- })
431
- ]
432
- }),
433
- /*#__PURE__*/ _jsxs("div", {
434
- className: "flex w-full flex-col gap-8",
435
- children: [
436
- /*#__PURE__*/ _jsx(Text, {
437
- size: "sm",
438
- bold: true,
439
- children: "Normalized definition"
440
- }),
441
- /*#__PURE__*/ _jsx("pre", {
442
- className: "max-h-[52vh] w-full overflow-auto rounded-8 border border-border-neutral-base bg-background-neutral-subtle p-12 scrollbar",
443
- children: /*#__PURE__*/ _jsx(Code, {
444
- as: "code",
445
- className: "whitespace-pre text-foreground-neutral-base",
446
- children: normalizedJson
447
- })
448
- })
449
- ]
450
- })
451
- ]
452
- })
453
- ]
454
- }) : null
455
- })
456
- });
457
- }
458
- function Metadata({ label, value }) {
459
- return /*#__PURE__*/ _jsxs("div", {
460
- className: "min-w-0 py-12 first:pt-0 last:pb-0",
461
- children: [
462
- /*#__PURE__*/ _jsx(Text, {
463
- size: "xs",
464
- className: "text-foreground-neutral-muted",
465
- children: label
466
- }),
467
- /*#__PURE__*/ _jsx(Text, {
468
- size: "sm",
469
- className: "break-words",
470
- children: value
471
- })
472
- ]
473
- });
474
- }
475
- function errorMessage(error, fallback) {
476
- if (error instanceof ApiError && error.message) return error.message;
477
- if (error instanceof Error && error.message) return error.message;
478
- return fallback;
479
- }
480
-
481
- //# sourceMappingURL=project-workflows-page.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/pages/project-workflows-page.tsx"],"sourcesContent":["import type {DefinitionDto, DefinitionSyncSummaryDto} from '@shipfox/api-definitions-dto';\nimport {ApiError} from '@shipfox/client-api';\nimport {QueryLoadError} from '@shipfox/client-ui';\nimport {useFireManualWorkflowMutation} from '@shipfox/client-workflows';\nimport {Button} from '@shipfox/react-ui/button';\nimport {Callout} from '@shipfox/react-ui/callout';\nimport {EmptyState} from '@shipfox/react-ui/empty-state';\nimport {Icon, type IconName} from '@shipfox/react-ui/icon';\nimport {LoadErrorState} from '@shipfox/react-ui/load-error-state';\nimport {RelativeTime, RelativeTimeProvider} from '@shipfox/react-ui/relative-time';\nimport {\n Sheet,\n SheetBody,\n SheetContent,\n SheetDescription,\n SheetHeader,\n SheetTitle,\n} from '@shipfox/react-ui/sheet';\nimport {Skeleton} from '@shipfox/react-ui/skeleton';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@shipfox/react-ui/table';\nimport {toast} from '@shipfox/react-ui/toast';\nimport {Code, Header, Text} from '@shipfox/react-ui/typography';\nimport {useState} from 'react';\nimport {SourceStrip} from '#components/source-strip.js';\nimport {useDefinitionsInfiniteQuery} from '#hooks/api/definitions.js';\nimport {useProjectQuery} from '#hooks/api/projects.js';\n\nexport function ProjectWorkflowsPage({projectId}: {projectId: string}) {\n return (\n <RelativeTimeProvider>\n <ProjectWorkflowsPageInner projectId={projectId} />\n </RelativeTimeProvider>\n );\n}\n\nfunction ProjectWorkflowsPageInner({projectId}: {projectId: string}) {\n const projectQuery = useProjectQuery(projectId);\n const definitionsQuery = useDefinitionsInfiniteQuery(projectId);\n const fireManual = useFireManualWorkflowMutation();\n const [selectedDefinition, setSelectedDefinition] = useState<DefinitionDto | null>(null);\n const [runError, setRunError] = useState<{definitionId: string; message: string} | null>(null);\n const definitions = definitionsQuery.data?.pages.flatMap((page) => page.definitions) ?? [];\n const sync = definitionsQuery.data?.pages[0]?.sync;\n\n async function handleRun(definition: DefinitionDto) {\n setRunError(null);\n if (!definition.manual_trigger) return;\n try {\n await fireManual.mutateAsync({projectId, definitionId: definition.id});\n toast.success('Run queued');\n } catch (error) {\n const message = errorMessage(error, 'Could not queue run.');\n setRunError({definitionId: definition.id, message});\n toast.error(message);\n }\n }\n\n return (\n <div className=\"flex w-full flex-col gap-24\">\n {projectQuery.isPending ? (\n <div className=\"flex flex-col gap-12\">\n <Skeleton className=\"h-28 w-1/3\" />\n <Skeleton className=\"h-18 w-1/2\" />\n </div>\n ) : null}\n\n {projectQuery.isError && projectQuery.data === undefined ? (\n projectQuery.error instanceof ApiError && projectQuery.error.status === 404 ? (\n <EmptyState\n icon=\"errorWarningLine\"\n title=\"Project not found\"\n description=\"This project doesn't exist, or you don't have access to it.\"\n />\n ) : (\n <QueryLoadError query={projectQuery} subject=\"project\" />\n )\n ) : null}\n\n {projectQuery.data ? (\n <>\n <header className=\"flex flex-col gap-4\">\n <Header variant=\"h2\">Workflows</Header>\n <Text size=\"sm\" className=\"text-foreground-neutral-muted\">\n Synced workflow definitions for this project source.\n </Text>\n </header>\n\n <SourceStrip\n connectionId={projectQuery.data.source.connection_id}\n externalRepositoryId={projectQuery.data.source.external_repository_id}\n sync={sync}\n isPending={definitionsQuery.isPending}\n />\n\n <WorkflowSyncAlert sync={sync} />\n\n <WorkflowDefinitionsList\n definitions={definitions}\n isPending={definitionsQuery.isPending}\n isError={definitionsQuery.isError}\n sync={sync ?? null}\n runError={runError}\n runningDefinitionId={\n fireManual.isPending && fireManual.variables\n ? fireManual.variables.definitionId\n : null\n }\n hasNextPage={definitionsQuery.hasNextPage}\n isFetchingNextPage={definitionsQuery.isFetchingNextPage}\n isFetchNextPageError={definitionsQuery.isFetchNextPageError}\n onRetry={() => definitionsQuery.refetch()}\n onLoadMore={() => definitionsQuery.fetchNextPage()}\n onOpenDefinition={setSelectedDefinition}\n onRun={(definition) => {\n void handleRun(definition);\n }}\n />\n </>\n ) : null}\n\n <DefinitionSheet\n definition={selectedDefinition}\n onOpenChange={(open) => {\n if (!open) setSelectedDefinition(null);\n }}\n />\n </div>\n );\n}\n\nfunction WorkflowDefinitionsList({\n definitions,\n isPending,\n isError,\n sync,\n runError,\n runningDefinitionId,\n hasNextPage,\n isFetchingNextPage,\n isFetchNextPageError,\n onRetry,\n onLoadMore,\n onOpenDefinition,\n onRun,\n}: {\n definitions: DefinitionDto[];\n isPending: boolean;\n isError: boolean;\n sync: DefinitionSyncSummaryDto | null;\n runError: {definitionId: string; message: string} | null;\n runningDefinitionId: string | null;\n hasNextPage: boolean;\n isFetchingNextPage: boolean;\n isFetchNextPageError: boolean;\n onRetry: () => void;\n onLoadMore: () => void;\n onOpenDefinition: (definition: DefinitionDto) => void;\n onRun: (definition: DefinitionDto) => void;\n}) {\n if (isPending) {\n return (\n <div className=\"flex flex-col gap-8\">\n <Skeleton className=\"h-40 w-full\" />\n <Skeleton className=\"h-40 w-full\" />\n <Skeleton className=\"h-40 w-full\" />\n </div>\n );\n }\n\n if (isError && definitions.length === 0) {\n return (\n <LoadErrorState\n title=\"Couldn't load workflows\"\n description=\"Definitions could not be loaded. Source metadata remains visible.\"\n onRetry={onRetry}\n retryLabel=\"Retry loading workflows\"\n />\n );\n }\n\n if (definitions.length === 0) {\n return <WorkflowEmptyState sync={sync} />;\n }\n\n return (\n <>\n <div className=\"hidden rounded-8 border border-border-neutral-base md:block\">\n <Table>\n <TableHeader>\n <TableRow>\n <TableHead className=\"w-40\"></TableHead>\n <TableHead>Workflow</TableHead>\n <TableHead className=\"w-180\">Updated</TableHead>\n <TableHead className=\"w-80 text-right\"></TableHead>\n </TableRow>\n </TableHeader>\n <TableBody>\n {definitions.map((definition) => {\n const runErrorMessage =\n runError?.definitionId === definition.id ? runError.message : null;\n const isRunning = runningDefinitionId === definition.id;\n\n return (\n // The workflow-name cell holds a `<button>` so the row is\n // keyboard-reachable (Tab focuses, Enter/Space activates\n // via native button semantics). The TableRow itself is no\n // longer clickable — a row-level onClick would be invisible\n // to keyboard users and require custom keydown handling.\n // The `group` class on the row still drives the Run button\n // reveal on hover or focus-within.\n <TableRow key={definition.id} className=\"group\">\n <TableCell>\n <Icon\n name={sourceIcon(definition.source)}\n className=\"size-16 text-foreground-neutral-muted\"\n aria-hidden=\"true\"\n />\n </TableCell>\n <TableCell className=\"max-w-260\">\n <div className=\"flex min-w-0 flex-col gap-2\">\n <button\n type=\"button\"\n onClick={() => onOpenDefinition(definition)}\n className=\"flex min-w-0 flex-col gap-2 text-left outline-none focus-visible:shadow-border-interactive-with-active rounded-4\"\n >\n <Text size=\"sm\" bold className=\"truncate\">\n {definition.name}\n </Text>\n <Code className=\"truncate text-foreground-neutral-muted\">\n {definition.config_path ?? 'Manual definition'}\n </Code>\n </button>\n {runErrorMessage ? (\n <Text size=\"xs\" className=\"text-tag-error-text\">\n {runErrorMessage}\n </Text>\n ) : null}\n </div>\n </TableCell>\n <TableCell className=\"text-foreground-neutral-muted\">\n <RelativeTime value={definition.updated_at} />\n </TableCell>\n <TableCell>\n {definition.manual_trigger ? (\n <div className=\"flex justify-end opacity-0 transition-opacity group-hover:opacity-100 group-focus-within:opacity-100\">\n <Button size=\"xs\" isLoading={isRunning} onClick={() => onRun(definition)}>\n Run\n </Button>\n </div>\n ) : null}\n </TableCell>\n </TableRow>\n );\n })}\n </TableBody>\n </Table>\n </div>\n\n <div className=\"flex flex-col rounded-8 border border-border-neutral-base md:hidden\">\n {definitions.map((definition) => {\n const runErrorMessage =\n runError?.definitionId === definition.id ? runError.message : null;\n const isRunning = runningDefinitionId === definition.id;\n\n return (\n <div\n key={definition.id}\n className=\"flex flex-col gap-10 border-b border-border-neutral-base p-12 last:border-b-0\"\n >\n <button\n type=\"button\"\n className=\"flex min-w-0 items-start gap-10 text-left\"\n onClick={() => onOpenDefinition(definition)}\n >\n <Icon\n name={sourceIcon(definition.source)}\n className=\"size-16 shrink-0 text-foreground-neutral-muted\"\n aria-hidden=\"true\"\n />\n <div className=\"flex min-w-0 flex-col gap-4\">\n <Text size=\"sm\" bold className=\"break-words\">\n {definition.name}\n </Text>\n <Code className=\"break-words text-foreground-neutral-muted\">\n {definition.config_path ?? 'Manual definition'}\n </Code>\n </div>\n </button>\n <div className=\"flex items-center justify-between gap-8\">\n <Text size=\"xs\" className=\"text-foreground-neutral-muted\">\n Updated <RelativeTime value={definition.updated_at} />\n </Text>\n {definition.manual_trigger ? (\n <Button size=\"sm\" isLoading={isRunning} onClick={() => onRun(definition)}>\n Run\n </Button>\n ) : null}\n </div>\n {runErrorMessage ? (\n <Text size=\"xs\" className=\"text-tag-error-text\">\n {runErrorMessage}\n </Text>\n ) : null}\n </div>\n );\n })}\n </div>\n\n {isFetchNextPageError ? (\n <Callout role=\"alert\" type=\"error\">\n <div className=\"flex items-center justify-between gap-12\">\n <Text size=\"sm\">Could not load more workflows.</Text>\n <Button size=\"sm\" variant=\"secondary\" onClick={onLoadMore}>\n Retry\n </Button>\n </div>\n </Callout>\n ) : null}\n\n {hasNextPage ? (\n <div className=\"flex justify-center\">\n <Button size=\"sm\" variant=\"secondary\" isLoading={isFetchingNextPage} onClick={onLoadMore}>\n Load more\n </Button>\n </div>\n ) : null}\n </>\n );\n}\n\nfunction sourceIcon(source: 'manual' | 'vcs'): IconName {\n return source === 'vcs' ? ('gitBranchLine' as IconName) : ('terminalLine' as IconName);\n}\n\nfunction WorkflowEmptyState({sync}: {sync: DefinitionSyncSummaryDto | null}) {\n const message =\n sync?.status === 'failed' && sync.last_error_code === 'no-workflow-files'\n ? 'No workflow files found under .shipfox/workflows/.'\n : sync?.status === 'failed'\n ? (sync.last_error_message ?? 'Workflow definitions could not be synced.')\n : sync?.status === 'syncing'\n ? 'Workflow definitions are being discovered.'\n : sync?.status === 'succeeded'\n ? 'No workflow definitions found.'\n : 'Workflow sync has not reported yet.';\n\n return <EmptyState icon=\"flowChart\" title=\"No workflows\" description={message} />;\n}\n\nfunction WorkflowSyncAlert({sync}: {sync: DefinitionSyncSummaryDto | null | undefined}) {\n if (sync?.status !== 'failed') return null;\n\n return (\n <Callout role=\"alert\" type=\"error\">\n <div className=\"flex flex-col gap-4\">\n <Text size=\"sm\" bold>\n Workflow sync failed\n </Text>\n <Text size=\"sm\">\n {sync.last_error_message ?? 'The latest workflow sync failed before definitions updated.'}\n </Text>\n </div>\n </Callout>\n );\n}\n\nfunction DefinitionSheet({\n definition,\n onOpenChange,\n}: {\n definition: DefinitionDto | null;\n onOpenChange: (open: boolean) => void;\n}) {\n const normalizedJson = definition\n ? JSON.stringify(\n {\n workflow_document: definition.workflow_document,\n workflow_model: definition.workflow_model,\n },\n null,\n 2,\n )\n : '';\n\n return (\n <Sheet open={Boolean(definition)} onOpenChange={onOpenChange}>\n <SheetContent className=\"w-full sm:max-w-[560px]\">\n {definition ? (\n <>\n <SheetHeader>\n <SheetTitle>{definition.name}</SheetTitle>\n <SheetDescription>\n {definition.config_path ?? 'Manual workflow definition'}\n </SheetDescription>\n </SheetHeader>\n <SheetBody className=\"gap-18\">\n <div className=\"grid w-full gap-10\">\n <Metadata label=\"Definition id\" value={definition.id} />\n <Metadata label=\"Source\" value={definition.source} />\n <Metadata label=\"Ref\" value={definition.ref ?? 'Not set'} />\n <Metadata label=\"SHA\" value={definition.sha ?? 'Not set'} />\n </div>\n <div className=\"flex w-full flex-col gap-8\">\n <Text size=\"sm\" bold>\n Normalized definition\n </Text>\n <pre className=\"max-h-[52vh] w-full overflow-auto rounded-8 border border-border-neutral-base bg-background-neutral-subtle p-12 scrollbar\">\n <Code as=\"code\" className=\"whitespace-pre text-foreground-neutral-base\">\n {normalizedJson}\n </Code>\n </pre>\n </div>\n </SheetBody>\n </>\n ) : null}\n </SheetContent>\n </Sheet>\n );\n}\n\nfunction Metadata({label, value}: {label: string; value: string}) {\n return (\n <div className=\"min-w-0 py-12 first:pt-0 last:pb-0\">\n <Text size=\"xs\" className=\"text-foreground-neutral-muted\">\n {label}\n </Text>\n <Text size=\"sm\" className=\"break-words\">\n {value}\n </Text>\n </div>\n );\n}\n\nfunction errorMessage(error: unknown, fallback: string) {\n if (error instanceof ApiError && error.message) return error.message;\n if (error instanceof Error && error.message) return error.message;\n return fallback;\n}\n"],"names":["ApiError","QueryLoadError","useFireManualWorkflowMutation","Button","Callout","EmptyState","Icon","LoadErrorState","RelativeTime","RelativeTimeProvider","Sheet","SheetBody","SheetContent","SheetDescription","SheetHeader","SheetTitle","Skeleton","Table","TableBody","TableCell","TableHead","TableHeader","TableRow","toast","Code","Header","Text","useState","SourceStrip","useDefinitionsInfiniteQuery","useProjectQuery","ProjectWorkflowsPage","projectId","ProjectWorkflowsPageInner","projectQuery","definitionsQuery","fireManual","selectedDefinition","setSelectedDefinition","runError","setRunError","definitions","data","pages","flatMap","page","sync","handleRun","definition","manual_trigger","mutateAsync","definitionId","id","success","error","message","errorMessage","div","className","isPending","isError","undefined","status","icon","title","description","query","subject","header","variant","size","connectionId","source","connection_id","externalRepositoryId","external_repository_id","WorkflowSyncAlert","WorkflowDefinitionsList","runningDefinitionId","variables","hasNextPage","isFetchingNextPage","isFetchNextPageError","onRetry","refetch","onLoadMore","fetchNextPage","onOpenDefinition","onRun","DefinitionSheet","onOpenChange","open","length","retryLabel","WorkflowEmptyState","map","runErrorMessage","isRunning","name","sourceIcon","aria-hidden","button","type","onClick","bold","config_path","value","updated_at","isLoading","role","last_error_code","last_error_message","normalizedJson","JSON","stringify","workflow_document","workflow_model","Boolean","Metadata","label","ref","sha","pre","as","fallback","Error"],"mappings":";AACA,SAAQA,QAAQ,QAAO,sBAAsB;AAC7C,SAAQC,cAAc,QAAO,qBAAqB;AAClD,SAAQC,6BAA6B,QAAO,4BAA4B;AACxE,SAAQC,MAAM,QAAO,2BAA2B;AAChD,SAAQC,OAAO,QAAO,4BAA4B;AAClD,SAAQC,UAAU,QAAO,gCAAgC;AACzD,SAAQC,IAAI,QAAsB,yBAAyB;AA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AAK;wCAAKkC,IAAI;kDAAC;;kDAGrB,KAACkB;wCAAIhE,WAAU;kDACb,cAAA,KAAClC;4CAAKmG,IAAG;4CAAOjE,WAAU;sDACvBsD;;;;;;;;iBAMT;;;AAIZ;AAEA,SAASM,SAAS,EAACC,KAAK,EAAEb,KAAK,EAAiC;IAC9D,qBACE,MAACjD;QAAIC,WAAU;;0BACb,KAAChC;gBAAK4C,MAAK;gBAAKZ,WAAU;0BACvB6D;;0BAEH,KAAC7F;gBAAK4C,MAAK;gBAAKZ,WAAU;0BACvBgD;;;;AAIT;AAEA,SAASlD,aAAaF,KAAc,EAAEsE,QAAgB;IACpD,IAAItE,iBAAiBtD,YAAYsD,MAAMC,OAAO,EAAE,OAAOD,MAAMC,OAAO;IACpE,IAAID,iBAAiBuE,SAASvE,MAAMC,OAAO,EAAE,OAAOD,MAAMC,OAAO;IACjE,OAAOqE;AACT"}
@@ -1,5 +0,0 @@
1
- declare const _default: import("@shipfox/client-shell/runtime").RouteImpl<{
2
- readonly component: () => import("react").JSX.Element;
3
- }>;
4
- export default _default;
5
- //# sourceMappingURL=workflows.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"workflows.d.ts","sourceRoot":"","sources":["../../src/routes/workflows.tsx"],"names":[],"mappings":";;;AAIA,wBAKG"}
@@ -1,16 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { defineRoute } from '@shipfox/client-shell/runtime';
3
- import { useParams } from '@tanstack/react-router';
4
- import { ProjectWorkflowsPage } from '#pages/project-workflows-page.js';
5
- export default defineRoute({
6
- component: ()=>{
7
- const { pid } = useParams({
8
- strict: false
9
- });
10
- return /*#__PURE__*/ _jsx(ProjectWorkflowsPage, {
11
- projectId: pid
12
- });
13
- }
14
- });
15
-
16
- //# sourceMappingURL=workflows.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/routes/workflows.tsx"],"sourcesContent":["import {defineRoute} from '@shipfox/client-shell/runtime';\nimport {useParams} from '@tanstack/react-router';\nimport {ProjectWorkflowsPage} from '#pages/project-workflows-page.js';\n\nexport default defineRoute({\n component: () => {\n const {pid} = useParams({strict: false}) as {pid: string};\n return <ProjectWorkflowsPage projectId={pid} />;\n },\n});\n"],"names":["defineRoute","useParams","ProjectWorkflowsPage","component","pid","strict","projectId"],"mappings":";AAAA,SAAQA,WAAW,QAAO,gCAAgC;AAC1D,SAAQC,SAAS,QAAO,yBAAyB;AACjD,SAAQC,oBAAoB,QAAO,mCAAmC;AAEtE,eAAeF,YAAY;IACzBG,WAAW;QACT,MAAM,EAACC,GAAG,EAAC,GAAGH,UAAU;YAACI,QAAQ;QAAK;QACtC,qBAAO,KAACH;YAAqBI,WAAWF;;IAC1C;AACF,GAAG"}