@burdenoff/microfe-cosmicintersection 2026.1109.7 → 2026.1110.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cosmicintersection/CosmicIntersectionRoot.d.ts +0 -1
- package/dist/cosmicintersection/CosmicIntersectionRoot.js +1 -2
- package/dist/cosmicintersection/CosmicIntersectionRoot.js.map +1 -1
- package/dist/cosmicintersection/CosmicIntersectionRoutes.d.ts +0 -1
- package/dist/cosmicintersection/CosmicIntersectionRoutes.js +36 -33
- package/dist/cosmicintersection/CosmicIntersectionRoutes.js.map +1 -1
- package/dist/cosmicintersection/api/cosmicApi.d.ts +86 -1
- package/dist/cosmicintersection/api/cosmicApi.js +70 -14
- package/dist/cosmicintersection/api/cosmicApi.js.map +1 -1
- package/dist/cosmicintersection/api/databricksTransport.d.ts +0 -1
- package/dist/cosmicintersection/api/databricksTransport.js +1 -2
- package/dist/cosmicintersection/api/databricksTransport.js.map +1 -1
- package/dist/cosmicintersection/api/tagsApi.d.ts +0 -1
- package/dist/cosmicintersection/api/tagsApi.js +1 -2
- package/dist/cosmicintersection/api/tagsApi.js.map +1 -1
- package/dist/cosmicintersection/components/ActionMenu.d.ts +0 -1
- package/dist/cosmicintersection/components/ActionMenu.js +1 -2
- package/dist/cosmicintersection/components/ActionMenu.js.map +1 -1
- package/dist/cosmicintersection/components/ActivityFeedPanel.d.ts +0 -1
- package/dist/cosmicintersection/components/ActivityFeedPanel.js +27 -25
- package/dist/cosmicintersection/components/ActivityFeedPanel.js.map +1 -1
- package/dist/cosmicintersection/components/AiRunAttribution.d.ts +0 -1
- package/dist/cosmicintersection/components/AiRunAttribution.js +1 -2
- package/dist/cosmicintersection/components/AiRunAttribution.js.map +1 -1
- package/dist/cosmicintersection/components/DatabricksQueueForm.d.ts +0 -1
- package/dist/cosmicintersection/components/DatabricksQueueForm.js +1 -2
- package/dist/cosmicintersection/components/DatabricksQueueForm.js.map +1 -1
- package/dist/cosmicintersection/components/DatabricksRunPanel.d.ts +0 -1
- package/dist/cosmicintersection/components/DatabricksRunPanel.js +1 -2
- package/dist/cosmicintersection/components/DatabricksRunPanel.js.map +1 -1
- package/dist/cosmicintersection/components/DiscussionPanel.d.ts +0 -1
- package/dist/cosmicintersection/components/DiscussionPanel.js +4 -4
- package/dist/cosmicintersection/components/DiscussionPanel.js.map +1 -1
- package/dist/cosmicintersection/components/EmptyState.d.ts +0 -1
- package/dist/cosmicintersection/components/EmptyState.js +1 -2
- package/dist/cosmicintersection/components/EmptyState.js.map +1 -1
- package/dist/cosmicintersection/components/EntityFormShell.d.ts +0 -1
- package/dist/cosmicintersection/components/EntityFormShell.js +1 -2
- package/dist/cosmicintersection/components/EntityFormShell.js.map +1 -1
- package/dist/cosmicintersection/components/EntityTagsField.d.ts +0 -1
- package/dist/cosmicintersection/components/EntityTagsField.js +1 -2
- package/dist/cosmicintersection/components/EntityTagsField.js.map +1 -1
- package/dist/cosmicintersection/components/ErrorState.d.ts +0 -1
- package/dist/cosmicintersection/components/ErrorState.js +1 -2
- package/dist/cosmicintersection/components/ErrorState.js.map +1 -1
- package/dist/cosmicintersection/components/FacetPanel.d.ts +0 -1
- package/dist/cosmicintersection/components/FacetPanel.js +1 -2
- package/dist/cosmicintersection/components/FacetPanel.js.map +1 -1
- package/dist/cosmicintersection/components/FileUploadField.d.ts +0 -1
- package/dist/cosmicintersection/components/FileUploadField.js +1 -2
- package/dist/cosmicintersection/components/FileUploadField.js.map +1 -1
- package/dist/cosmicintersection/components/LineageGraph.d.ts +0 -1
- package/dist/cosmicintersection/components/LineageGraph.js +7 -12
- package/dist/cosmicintersection/components/LineageGraph.js.map +1 -1
- package/dist/cosmicintersection/components/LoadingState.d.ts +0 -1
- package/dist/cosmicintersection/components/LoadingState.js +1 -2
- package/dist/cosmicintersection/components/LoadingState.js.map +1 -1
- package/dist/cosmicintersection/components/PageLayout.d.ts +0 -1
- package/dist/cosmicintersection/components/PageLayout.js +1 -2
- package/dist/cosmicintersection/components/PageLayout.js.map +1 -1
- package/dist/cosmicintersection/components/Pagination.d.ts +0 -1
- package/dist/cosmicintersection/components/Pagination.js +1 -2
- package/dist/cosmicintersection/components/Pagination.js.map +1 -1
- package/dist/cosmicintersection/components/ReleaseDraftDialog.d.ts +0 -1
- package/dist/cosmicintersection/components/ReleaseDraftDialog.js +7 -12
- package/dist/cosmicintersection/components/ReleaseDraftDialog.js.map +1 -1
- package/dist/cosmicintersection/components/ResultsChart.d.ts +0 -1
- package/dist/cosmicintersection/components/ResultsChart.js +4 -8
- package/dist/cosmicintersection/components/ResultsChart.js.map +1 -1
- package/dist/cosmicintersection/components/RunTriageCard.d.ts +0 -1
- package/dist/cosmicintersection/components/RunTriageCard.js +18 -19
- package/dist/cosmicintersection/components/RunTriageCard.js.map +1 -1
- package/dist/cosmicintersection/components/SafeLink.d.ts +0 -1
- package/dist/cosmicintersection/components/SafeLink.js +8 -7
- package/dist/cosmicintersection/components/SafeLink.js.map +1 -1
- package/dist/cosmicintersection/components/SchemaProposalPanel.d.ts +0 -1
- package/dist/cosmicintersection/components/SchemaProposalPanel.js +17 -18
- package/dist/cosmicintersection/components/SchemaProposalPanel.js.map +1 -1
- package/dist/cosmicintersection/components/ScienceCanvas.d.ts +0 -1
- package/dist/cosmicintersection/components/ScienceCanvas.js +226 -233
- package/dist/cosmicintersection/components/ScienceCanvas.js.map +1 -1
- package/dist/cosmicintersection/components/StatusBadge.d.ts +0 -1
- package/dist/cosmicintersection/components/StatusBadge.js +1 -2
- package/dist/cosmicintersection/components/StatusBadge.js.map +1 -1
- package/dist/cosmicintersection/components/StepDAG.d.ts +0 -1
- package/dist/cosmicintersection/components/StepDAG.js +1 -2
- package/dist/cosmicintersection/components/StepDAG.js.map +1 -1
- package/dist/cosmicintersection/components/WorkspaceTagsPicker.d.ts +0 -1
- package/dist/cosmicintersection/components/WorkspaceTagsPicker.js +1 -2
- package/dist/cosmicintersection/components/WorkspaceTagsPicker.js.map +1 -1
- package/dist/cosmicintersection/components/index.d.ts +0 -1
- package/dist/cosmicintersection/components/index.js +14 -14
- package/dist/cosmicintersection/context/CosmicIntersectionContext.d.ts +0 -1
- package/dist/cosmicintersection/context/CosmicIntersectionContext.js +2 -7
- package/dist/cosmicintersection/context/CosmicIntersectionContext.js.map +1 -1
- package/dist/cosmicintersection/hooks/useDatabricksExecutions.d.ts +0 -1
- package/dist/cosmicintersection/hooks/useDatabricksExecutions.js +18 -19
- package/dist/cosmicintersection/hooks/useDatabricksExecutions.js.map +1 -1
- package/dist/cosmicintersection/hooks/useDatabricksQueueForm.d.ts +0 -1
- package/dist/cosmicintersection/hooks/useDatabricksQueueForm.js +1 -2
- package/dist/cosmicintersection/hooks/useDatabricksQueueForm.js.map +1 -1
- package/dist/cosmicintersection/hooks/useEntityTagSync.d.ts +0 -1
- package/dist/cosmicintersection/hooks/useEntityTagSync.js +29 -25
- package/dist/cosmicintersection/hooks/useEntityTagSync.js.map +1 -1
- package/dist/cosmicintersection/index.d.ts +0 -1
- package/dist/cosmicintersection/lib/assistantAwareDialog.d.ts +0 -1
- package/dist/cosmicintersection/lib/assistantAwareDialog.js +1 -2
- package/dist/cosmicintersection/lib/assistantAwareDialog.js.map +1 -1
- package/dist/cosmicintersection/lib/databricksForm.d.ts +0 -1
- package/dist/cosmicintersection/lib/databricksForm.js +1 -2
- package/dist/cosmicintersection/lib/databricksForm.js.map +1 -1
- package/dist/cosmicintersection/lib/databricksIntent.d.ts +0 -1
- package/dist/cosmicintersection/lib/databricksIntent.js +1 -2
- package/dist/cosmicintersection/lib/databricksIntent.js.map +1 -1
- package/dist/cosmicintersection/lib/databricksPresentation.d.ts +0 -1
- package/dist/cosmicintersection/lib/databricksPresentation.js +1 -2
- package/dist/cosmicintersection/lib/databricksPresentation.js.map +1 -1
- package/dist/cosmicintersection/lib/mutationResult.d.ts +0 -1
- package/dist/cosmicintersection/lib/mutationResult.js +1 -2
- package/dist/cosmicintersection/lib/mutationResult.js.map +1 -1
- package/dist/cosmicintersection/lib/toast.d.ts +0 -1
- package/dist/cosmicintersection/lib/toast.js +1 -2
- package/dist/cosmicintersection/lib/toast.js.map +1 -1
- package/dist/cosmicintersection/lib/useSelectedRecord.d.ts +0 -1
- package/dist/cosmicintersection/lib/useSelectedRecord.js +1 -2
- package/dist/cosmicintersection/lib/useSelectedRecord.js.map +1 -1
- package/dist/cosmicintersection/lib/useTrackRecentItem.d.ts +0 -1
- package/dist/cosmicintersection/lib/useTrackRecentItem.js +7 -8
- package/dist/cosmicintersection/lib/useTrackRecentItem.js.map +1 -1
- package/dist/cosmicintersection/lib/visualization.d.ts +0 -1
- package/dist/cosmicintersection/lib/visualization.js +2 -3
- package/dist/cosmicintersection/lib/visualization.js.map +1 -1
- package/dist/cosmicintersection/lib/visualizationSamples.d.ts +0 -1
- package/dist/cosmicintersection/pages/access/AccessPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/access/AccessPage.js +225 -226
- package/dist/cosmicintersection/pages/access/AccessPage.js.map +1 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js +259 -260
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/archive/ArchivePage.d.ts +2 -0
- package/dist/cosmicintersection/pages/archive/ArchivePage.js +256 -0
- package/dist/cosmicintersection/pages/archive/ArchivePage.js.map +1 -0
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.js +32 -33
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.js +17 -18
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js +20 -21
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js +19 -20
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.js +64 -75
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetFormPage.js +22 -23
- package/dist/cosmicintersection/pages/datasets/DatasetFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js +207 -208
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js +20 -24
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js.map +1 -1
- package/dist/cosmicintersection/pages/lineage/LineagePage.d.ts +0 -1
- package/dist/cosmicintersection/pages/lineage/LineagePage.js +53 -54
- package/dist/cosmicintersection/pages/lineage/LineagePage.js.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.js +61 -62
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookFormPage.js +50 -48
- package/dist/cosmicintersection/pages/notebooks/NotebookFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js +28 -29
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.js +119 -120
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.js +41 -42
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js +30 -31
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/releases/ReleaseFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/releases/ReleaseFormPage.js +16 -17
- package/dist/cosmicintersection/pages/releases/ReleaseFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js +268 -269
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/runs/RunDetailPage.js +194 -195
- package/dist/cosmicintersection/pages/runs/RunDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.js +20 -21
- package/dist/cosmicintersection/pages/runs/RunsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.js +31 -32
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourceFormPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/sources/SourceFormPage.js +23 -24
- package/dist/cosmicintersection/pages/sources/SourceFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourcesPage.d.ts +0 -1
- package/dist/cosmicintersection/pages/sources/SourcesPage.js +184 -182
- package/dist/cosmicintersection/pages/sources/SourcesPage.js.map +1 -1
- package/dist/cosmicintersection/types/index.d.ts +0 -1
- package/dist/cosmicintersection/utils/cn.d.ts +0 -1
- package/dist/cosmicintersection/utils/cn.js +1 -2
- package/dist/cosmicintersection/utils/cn.js.map +1 -1
- package/dist/cosmicintersection/utils/i18n.d.ts +0 -1
- package/dist/cosmicintersection/utils/navigation.d.ts +0 -1
- package/dist/dev/main.d.ts +0 -1
- package/dist/generated/global-types.d.ts +0 -1
- package/dist/generated/wspace-operations.d.ts +0 -1
- package/dist/generated/wspace-operations.js +1 -2
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +155 -85
- package/dist/index.d.ts +0 -1
- package/dist/index.js +3 -3
- package/dist/node_modules/clsx/dist/clsx.js +7 -6
- package/dist/node_modules/clsx/dist/clsx.js.map +1 -1
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +4 -21
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js.map +1 -1
- package/dist/services/createSandboxAssistantTransport.d.ts +0 -1
- package/dist/services/createSandboxAssistantTransport.js +1 -2
- package/dist/services/createSandboxAssistantTransport.js.map +1 -1
- package/dist/services/recentItems.d.ts +0 -1
- package/dist/services/recentItems.js +5 -6
- package/dist/services/recentItems.js.map +1 -1
- package/dist/shared/hooks/useTr.d.ts +0 -1
- package/dist/shared/hooks/useTr.js +1 -2
- package/dist/shared/hooks/useTr.js.map +1 -1
- package/dist/stories/EmptyState.stories.d.ts +0 -1
- package/dist/stories/LoadingState.stories.d.ts +0 -1
- package/dist/stories/ScienceCanvas.stories.d.ts +0 -1
- package/dist/stories/StatusBadge.stories.d.ts +0 -1
- package/dist/stories/WorkspaceTagsPicker.stories.d.ts +0 -1
- package/dist/test/fakeGateway.d.ts +0 -1
- package/dist/test/fixtures.d.ts +0 -1
- package/dist/test/happydom.d.ts +1 -0
- package/dist/test/i18nMock.d.ts +13 -1
- package/dist/test/renderWithProviders.d.ts +1 -2
- package/dist/test/storage.d.ts +13 -0
- package/dist/types/assistant.d.ts +0 -1
- package/dist/utils/pageContext.d.ts +0 -1
- package/dist/utils/pageContext.js +1 -2
- package/dist/utils/pageContext.js.map +1 -1
- package/package.json +64 -38
- package/dist/cosmicintersection/CosmicIntersectionRoot.d.ts.map +0 -1
- package/dist/cosmicintersection/CosmicIntersectionRoutes.d.ts.map +0 -1
- package/dist/cosmicintersection/api/cosmicApi.d.ts.map +0 -1
- package/dist/cosmicintersection/api/databricksTransport.d.ts.map +0 -1
- package/dist/cosmicintersection/api/tagsApi.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ActionMenu.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ActivityFeedPanel.d.ts.map +0 -1
- package/dist/cosmicintersection/components/AiRunAttribution.d.ts.map +0 -1
- package/dist/cosmicintersection/components/DatabricksQueueForm.d.ts.map +0 -1
- package/dist/cosmicintersection/components/DatabricksRunPanel.d.ts.map +0 -1
- package/dist/cosmicintersection/components/DiscussionPanel.d.ts.map +0 -1
- package/dist/cosmicintersection/components/EmptyState.d.ts.map +0 -1
- package/dist/cosmicintersection/components/EntityFormShell.d.ts.map +0 -1
- package/dist/cosmicintersection/components/EntityTagsField.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ErrorState.d.ts.map +0 -1
- package/dist/cosmicintersection/components/FacetPanel.d.ts.map +0 -1
- package/dist/cosmicintersection/components/FileUploadField.d.ts.map +0 -1
- package/dist/cosmicintersection/components/LineageGraph.d.ts.map +0 -1
- package/dist/cosmicintersection/components/LoadingState.d.ts.map +0 -1
- package/dist/cosmicintersection/components/PageLayout.d.ts.map +0 -1
- package/dist/cosmicintersection/components/Pagination.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ReleaseDraftDialog.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ResultsChart.d.ts.map +0 -1
- package/dist/cosmicintersection/components/RunTriageCard.d.ts.map +0 -1
- package/dist/cosmicintersection/components/SafeLink.d.ts.map +0 -1
- package/dist/cosmicintersection/components/SchemaProposalPanel.d.ts.map +0 -1
- package/dist/cosmicintersection/components/ScienceCanvas.d.ts.map +0 -1
- package/dist/cosmicintersection/components/StatusBadge.d.ts.map +0 -1
- package/dist/cosmicintersection/components/StepDAG.d.ts.map +0 -1
- package/dist/cosmicintersection/components/WorkspaceTagsPicker.d.ts.map +0 -1
- package/dist/cosmicintersection/components/index.d.ts.map +0 -1
- package/dist/cosmicintersection/context/CosmicIntersectionContext.d.ts.map +0 -1
- package/dist/cosmicintersection/hooks/useDatabricksExecutions.d.ts.map +0 -1
- package/dist/cosmicintersection/hooks/useDatabricksQueueForm.d.ts.map +0 -1
- package/dist/cosmicintersection/hooks/useEntityTagSync.d.ts.map +0 -1
- package/dist/cosmicintersection/index.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/assistantAwareDialog.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/databricksForm.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/databricksIntent.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/databricksPresentation.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/mutationResult.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/toast.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/useSelectedRecord.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/useTrackRecentItem.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/visualization.d.ts.map +0 -1
- package/dist/cosmicintersection/lib/visualizationSamples.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/access/AccessPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/lineage/LineagePage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebookFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/releases/ReleaseFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/runs/RunDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/sources/SourceFormPage.d.ts.map +0 -1
- package/dist/cosmicintersection/pages/sources/SourcesPage.d.ts.map +0 -1
- package/dist/cosmicintersection/types/index.d.ts.map +0 -1
- package/dist/cosmicintersection/utils/cn.d.ts.map +0 -1
- package/dist/cosmicintersection/utils/i18n.d.ts.map +0 -1
- package/dist/cosmicintersection/utils/navigation.d.ts.map +0 -1
- package/dist/dev/main.d.ts.map +0 -1
- package/dist/generated/global-types.d.ts.map +0 -1
- package/dist/generated/wspace-operations.d.ts.map +0 -1
- package/dist/generated/wspace-types.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/services/createSandboxAssistantTransport.d.ts.map +0 -1
- package/dist/services/recentItems.d.ts.map +0 -1
- package/dist/shared/hooks/useTr.d.ts.map +0 -1
- package/dist/stories/EmptyState.stories.d.ts.map +0 -1
- package/dist/stories/LoadingState.stories.d.ts.map +0 -1
- package/dist/stories/ScienceCanvas.stories.d.ts.map +0 -1
- package/dist/stories/StatusBadge.stories.d.ts.map +0 -1
- package/dist/stories/WorkspaceTagsPicker.stories.d.ts.map +0 -1
- package/dist/test/fakeGateway.d.ts.map +0 -1
- package/dist/test/fixtures.d.ts.map +0 -1
- package/dist/test/i18nMock.d.ts.map +0 -1
- package/dist/test/renderWithProviders.d.ts.map +0 -1
- package/dist/test/setup.d.ts +0 -1
- package/dist/test/setup.d.ts.map +0 -1
- package/dist/types/assistant.d.ts.map +0 -1
- package/dist/utils/pageContext.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotebooksPage.js","names":[],"sources":["../../../../src/cosmicintersection/pages/notebooks/NotebooksPage.tsx"],"sourcesContent":["/**\n * NotebooksPage — paginated list of analysis notebooks.\n *\n * Notebooks are computational documents (title, runtime, environment, linked\n * datasets) that scientists run analyses inside. This surface lists them from\n * `cosListNotebooks` with a status filter, per-row View / Edit / Archive\n * actions, and offset pagination. Every value here comes from the backend —\n * there is no fabricated data.\n */\nimport { useState } from 'react';\nimport { NotebookText, Plus, Share2 } from 'lucide-react';\nimport {\n Badge,\n Button,\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@burdenoff/fe-libs/ui';\n\nimport {\n useCosArchiveNotebookMutation,\n useCosNotebooksQuery,\n type CosNotebook,\n type CosNotebookStatus,\n} from '../../api/cosmicApi';\nimport {\n ActionMenu,\n EmptyState,\n ErrorState,\n LoadingState,\n PageLayout,\n Pagination,\n StatusBadge,\n usePagination,\n} from '../../components';\nimport { useCosmicIntersection } from '../../context/CosmicIntersectionContext';\nimport { notify } from '../../lib/toast';\nimport { useTr } from '../../../shared/hooks/useTr';\n\nconst STATUS_OPTIONS: { value: CosNotebookStatus; label: string }[] = [\n { value: 'DRAFT', label: 'Draft' },\n { value: 'RUNNING', label: 'Running' },\n { value: 'PUBLISHED', label: 'Published' },\n { value: 'ARCHIVED', label: 'Archived' },\n];\n\nconst ALL = 'ALL';\n\nfunction formatDate(value?: string | null): string {\n if (!value) {\n return '—';\n }\n const date = new Date(value);\n if (Number.isNaN(date.getTime())) {\n return '—';\n }\n return date.toLocaleDateString(undefined, { year: 'numeric', month: 'short', day: 'numeric' });\n}\n\nexport default function NotebooksPage() {\n const { navigate } = useCosmicIntersection();\n const tr = useTr();\n const [statusFilter, setStatusFilter] = useState<CosNotebookStatus | undefined>(undefined);\n const pagination = usePagination({ pageSize: 50, resetKey: statusFilter });\n\n const { data, loading, error, refetch } = useCosNotebooksQuery({\n status: statusFilter,\n pagination: { limit: pagination.limit, offset: pagination.offset },\n });\n const [archiveNotebook] = useCosArchiveNotebookMutation();\n\n const notebooks = data?.cosListNotebooks.items ?? [];\n const pageInfo = data?.cosListNotebooks.pageInfo;\n\n const handleArchive = async (notebook: CosNotebook) => {\n const response = await archiveNotebook({ variables: { id: notebook.id } });\n if (response.error) {\n // onError already surfaced the toast; rethrow so the confirm dialog stays open.\n throw new Error(response.error.message);\n }\n if (!response.data?.cosArchiveNotebook) {\n notify.error(\n tr('cosmicintersection.pages.notebooks.archiveError', 'Could not archive notebook'),\n tr(\n 'cosmicintersection.pages.notebooks.archiveErrorDescription',\n 'The server did not confirm the change.'\n )\n );\n throw new Error('Archive not confirmed');\n }\n await refetch();\n notify.success(\n tr('cosmicintersection.pages.notebooks.archiveSuccess', 'Notebook archived'),\n tr(\n 'cosmicintersection.pages.notebooks.archiveSuccessDescription',\n '“{{name}}” was archived.',\n { name: notebook.title }\n )\n );\n };\n\n const actions = (\n <Button type=\"button\" onClick={() => navigate('notebooks/create')}>\n <Plus className=\"size-4\" />\n {tr('cosmicintersection.pages.notebooks.create', 'New notebook')}\n </Button>\n );\n\n return (\n <PageLayout\n title={tr('cosmicintersection.pages.notebooks.title', 'Notebooks')}\n description={tr(\n 'cosmicintersection.pages.notebooks.description',\n 'Computational notebooks for running analyses over federated science datasets.'\n )}\n actions={actions}\n >\n <div className=\"space-y-4\">\n <div className=\"flex flex-wrap items-center gap-3\">\n <label className=\"text-sm text-text-secondary\" htmlFor=\"notebook-status-filter\">\n Status\n </label>\n <Select\n value={statusFilter ?? ALL}\n onValueChange={(value) =>\n setStatusFilter(value === ALL ? undefined : (value as CosNotebookStatus))\n }\n >\n <SelectTrigger\n id=\"notebook-status-filter\"\n className=\"w-48\"\n aria-label=\"Filter by status\"\n >\n <SelectValue />\n </SelectTrigger>\n <SelectContent>\n <SelectItem value={ALL}>All statuses</SelectItem>\n {STATUS_OPTIONS.map((option) => (\n <SelectItem key={option.value} value={option.value}>\n {option.label}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n\n {loading ? (\n <LoadingState\n variant=\"rows\"\n rows={6}\n label={tr('cosmicintersection.pages.notebooks.loading', 'Loading notebooks…')}\n />\n ) : error ? (\n <ErrorState\n message={tr(\n 'cosmicintersection.pages.notebooks.error',\n 'We could not load your notebooks. Please try again.'\n )}\n onRetry={() => void refetch()}\n />\n ) : notebooks.length === 0 ? (\n <EmptyState\n icon={NotebookText}\n title={\n statusFilter\n ? tr(\n 'cosmicintersection.pages.notebooks.emptyFilterTitle',\n 'No notebooks match this filter.'\n )\n : tr('cosmicintersection.pages.notebooks.emptyTitle', 'No notebooks yet.')\n }\n description={\n statusFilter\n ? tr(\n 'cosmicintersection.pages.notebooks.emptyFilterDescription',\n 'Try a different status filter.'\n )\n : tr(\n 'cosmicintersection.pages.notebooks.emptyDescription',\n 'Create your first notebook to start analysing federated datasets.'\n )\n }\n action={\n statusFilter ? undefined : (\n <Button type=\"button\" onClick={() => navigate('notebooks/create')}>\n <Plus className=\"size-4\" />\n {tr('cosmicintersection.pages.notebooks.create', 'New notebook')}\n </Button>\n )\n }\n />\n ) : (\n <>\n {/* Desktop table */}\n <div className=\"hidden rounded-card border border-border-default bg-bg-elevated md:block\">\n <Table>\n <TableHeader>\n <TableRow>\n <TableHead>Title</TableHead>\n <TableHead>Status</TableHead>\n <TableHead>Runtime</TableHead>\n <TableHead className=\"text-right\">Datasets</TableHead>\n <TableHead>Sharing</TableHead>\n <TableHead>Tags</TableHead>\n <TableHead>Updated</TableHead>\n <TableHead className=\"w-12 text-right\">Actions</TableHead>\n </TableRow>\n </TableHeader>\n <TableBody>\n {notebooks.map((notebook) => (\n <TableRow\n key={notebook.id}\n className=\"cursor-pointer\"\n onClick={() => navigate(`notebooks/${notebook.id}`)}\n >\n <TableCell className=\"font-medium text-text-primary\">\n {notebook.title}\n </TableCell>\n <TableCell>\n <StatusBadge status={notebook.status} />\n </TableCell>\n <TableCell className=\"text-text-secondary\">\n {notebook.runtime ?? '—'}\n </TableCell>\n <TableCell className=\"text-right tabular-nums text-text-secondary\">\n {notebook.datasetIds.length}\n </TableCell>\n <TableCell>\n {notebook.isShared ? (\n <Badge variant=\"secondary\" className=\"gap-1\">\n <Share2 className=\"size-3\" aria-hidden=\"true\" />\n {tr('cosmicintersection.common.shared', 'Shared')}\n </Badge>\n ) : (\n <span className=\"text-text-secondary\">\n {tr('cosmicintersection.common.private', 'Private')}\n </span>\n )}\n </TableCell>\n <TableCell>\n {notebook.tags.length > 0 ? (\n <div className=\"flex flex-wrap gap-1\">\n {notebook.tags.slice(0, 3).map((tag) => (\n <Badge key={tag} variant=\"outline\">\n {tag}\n </Badge>\n ))}\n {notebook.tags.length > 3 ? (\n <span className=\"text-xs text-text-secondary\">\n +{notebook.tags.length - 3}\n </span>\n ) : null}\n </div>\n ) : (\n <span className=\"text-text-secondary\">—</span>\n )}\n </TableCell>\n <TableCell className=\"whitespace-nowrap text-text-secondary\">\n {formatDate(notebook.updatedAt)}\n </TableCell>\n <TableCell className=\"text-right\">\n <ActionMenu\n ariaLabel={`Actions for ${notebook.title}`}\n entityName={notebook.title}\n onView={() => navigate(`notebooks/${notebook.id}`)}\n onEdit={() => navigate(`notebooks/${notebook.id}/edit`)}\n onDelete={\n notebook.status === 'ARCHIVED'\n ? undefined\n : () => handleArchive(notebook)\n }\n deleteLabel={tr(\n 'cosmicintersection.pages.notebooks.archive',\n 'Archive notebook'\n )}\n />\n </TableCell>\n </TableRow>\n ))}\n </TableBody>\n </Table>\n </div>\n\n {/* Mobile card list */}\n <ul className=\"space-y-3 md:hidden\">\n {notebooks.map((notebook) => (\n <li\n key={notebook.id}\n className=\"rounded-card border border-border-default bg-bg-elevated\"\n >\n <div className=\"flex items-start justify-between gap-2 p-4\">\n <button\n type=\"button\"\n onClick={() => navigate(`notebooks/${notebook.id}`)}\n className=\"min-w-0 flex-1 space-y-2 text-left\"\n >\n <div className=\"flex flex-wrap items-center gap-2\">\n <span className=\"truncate font-medium text-text-primary\">\n {notebook.title}\n </span>\n <StatusBadge status={notebook.status} />\n </div>\n <div className=\"flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-text-secondary\">\n <span>Runtime: {notebook.runtime ?? '—'}</span>\n <span className=\"tabular-nums\">\n {notebook.datasetIds.length} dataset\n {notebook.datasetIds.length === 1 ? '' : 's'}\n </span>\n {notebook.isShared ? (\n <span className=\"inline-flex items-center gap-1\">\n <Share2 className=\"size-3\" aria-hidden=\"true\" />\n {tr('cosmicintersection.common.shared', 'Shared')}\n </span>\n ) : (\n <span>{tr('cosmicintersection.common.private', 'Private')}</span>\n )}\n <span>Updated {formatDate(notebook.updatedAt)}</span>\n </div>\n {notebook.tags.length > 0 ? (\n <div className=\"flex flex-wrap gap-1\">\n {notebook.tags.slice(0, 4).map((tag) => (\n <Badge key={tag} variant=\"outline\">\n {tag}\n </Badge>\n ))}\n {notebook.tags.length > 4 ? (\n <span className=\"text-xs text-text-secondary\">\n +{notebook.tags.length - 4}\n </span>\n ) : null}\n </div>\n ) : null}\n </button>\n <ActionMenu\n ariaLabel={`Actions for ${notebook.title}`}\n entityName={notebook.title}\n onView={() => navigate(`notebooks/${notebook.id}`)}\n onEdit={() => navigate(`notebooks/${notebook.id}/edit`)}\n onDelete={\n notebook.status === 'ARCHIVED' ? undefined : () => handleArchive(notebook)\n }\n deleteLabel={tr(\n 'cosmicintersection.pages.notebooks.archive',\n 'Archive notebook'\n )}\n />\n </div>\n </li>\n ))}\n </ul>\n </>\n )}\n\n {!loading && !error && notebooks.length > 0 ? (\n <Pagination\n offset={pagination.offset}\n limit={pagination.limit}\n loadedCount={notebooks.length}\n hasMore={pageInfo?.hasMore ?? false}\n onPrev={pagination.prevPage}\n onNext={pagination.nextPage}\n itemLabel={tr('cosmicintersection.pages.notebooks.itemLabel', 'notebooks')}\n loading={loading}\n />\n ) : null}\n </div>\n </PageLayout>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AA+CA,IAAM,IAAgE;CACpE;EAAE,OAAO;EAAS,OAAO;CAAQ;CACjC;EAAE,OAAO;EAAW,OAAO;CAAU;CACrC;EAAE,OAAO;EAAa,OAAO;CAAY;CACzC;EAAE,OAAO;EAAY,OAAO;CAAW;AACzC,GAEM,IAAM;AAEZ,SAAS,EAAW,GAA+B;CACjD,IAAI,CAAC,GACH,OAAO;CAET,IAAM,IAAO,IAAI,KAAK,CAAK;CAI3B,OAHI,OAAO,MAAM,EAAK,QAAQ,CAAC,IACtB,MAEF,EAAK,mBAAmB,KAAA,GAAW;EAAE,MAAM;EAAW,OAAO;EAAS,KAAK;CAAU,CAAC;AAC/F;AAEA,SAAwB,IAAgB;CACtC,IAAM,EAAE,gBAAa,EAAsB,GACrC,IAAK,EAAM,GACX,CAAC,GAAc,KAAmB,EAAwC,KAAA,CAAS,GACnF,IAAa,EAAc;EAAE,UAAU;EA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,GAAD;WAAiB,SAAQ;qBACtB;UACI,GAFK,CAEL,CACR,GACA,EAAS,KAAK,SAAS,IACtB,kBAAC,QAAD;WAAM,WAAU;qBAAhB,CAA8C,KAC1C,EAAS,KAAK,SAAS,CACrB;eACJ,IACD;cACH;QACE;WACR,kBAAC,GAAD;QACE,WAAW,eAAe,EAAS;QACnC,YAAY,EAAS;QACrB,cAAc,EAAS,aAAa,EAAS,IAAI;QACjD,cAAc,EAAS,aAAa,EAAS,GAAG,MAAM;QACtD,UACE,EAAS,WAAW,aAAa,KAAA,UAAkB,EAAc,CAAQ;QAE3E,aAAa,EACX,8CACA,kBACF;OACD,CAAA,CACE;;KACH,GA5DG,EAAS,EA4DZ,CACL;IACC,CAAA,CACJ,EAAA,CAAA;IAGH,CAAC,KAAW,CAAC,KAAS,EAAU,SAAS,IACxC,kBAAC,GAAD;KACE,QAAQ,EAAW;KACnB,OAAO,EAAW;KAClB,aAAa,EAAU;KACvB,SAAS,GAAU,WAAW;KAC9B,QAAQ,EAAW;KACnB,QAAQ,EAAW;KACnB,WAAW,EAAG,gDAAgD,WAAW;KAChE;IACV,CAAA,IACC;GACD;;CACK,CAAA;AAEhB"}
|
|
1
|
+
{"version":3,"file":"NotebooksPage.js","names":["_Fragment","Fragment$1","STATUS_OPTIONS","ALL","formatDate","value","date","NotebooksPage","useCosmicIntersection","tr","useTr","statusFilter","setStatusFilter","useState","pagination","usePagination","useCosNotebooksQuery","archiveNotebook","useCosArchiveNotebookMutation","notebooks","data","pageInfo","handleArchive","response","notebook","notify","refetch","actions","Button","navigate","Plus","PageLayout","Select","SelectTrigger","SelectValue","SelectContent","SelectItem","option","loading","LoadingState","error","ErrorState","EmptyState","NotebookText","Table","TableHeader","TableRow","TableHead","TableBody","TableCell","StatusBadge","Badge","Share2","tag","ActionMenu","Pagination"],"sources":["../../../../src/cosmicintersection/pages/notebooks/NotebooksPage.tsx"],"sourcesContent":["/**\n * NotebooksPage — paginated list of analysis notebooks.\n *\n * Notebooks are computational documents (title, runtime, environment, linked\n * datasets) that scientists run analyses inside. This surface lists them from\n * `cosListNotebooks` with a status filter, per-row View / Edit / Archive\n * actions, and offset pagination. Every value here comes from the backend —\n * there is no fabricated data.\n */\nimport { useState } from 'react';\nimport { NotebookText, Plus, Share2 } from 'lucide-react';\nimport {\n Badge,\n Button,\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@burdenoff/fe-libs/ui';\n\nimport {\n useCosArchiveNotebookMutation,\n useCosNotebooksQuery,\n type CosNotebook,\n type CosNotebookStatus,\n} from '../../api/cosmicApi';\nimport {\n ActionMenu,\n EmptyState,\n ErrorState,\n LoadingState,\n PageLayout,\n Pagination,\n StatusBadge,\n usePagination,\n} from '../../components';\nimport { useCosmicIntersection } from '../../context/CosmicIntersectionContext';\nimport { notify } from '../../lib/toast';\nimport { useTr } from '../../../shared/hooks/useTr';\n\nconst STATUS_OPTIONS: { value: CosNotebookStatus; label: string }[] = [\n { value: 'DRAFT', label: 'Draft' },\n { value: 'RUNNING', label: 'Running' },\n { value: 'PUBLISHED', label: 'Published' },\n { value: 'ARCHIVED', label: 'Archived' },\n];\n\nconst ALL = 'ALL';\n\nfunction formatDate(value?: string | null): string {\n if (!value) {\n return '—';\n }\n const date = new Date(value);\n if (Number.isNaN(date.getTime())) {\n return '—';\n }\n return date.toLocaleDateString(undefined, { year: 'numeric', month: 'short', day: 'numeric' });\n}\n\nexport default function NotebooksPage() {\n const { navigate } = useCosmicIntersection();\n const tr = useTr();\n const [statusFilter, setStatusFilter] = useState<CosNotebookStatus | undefined>(undefined);\n const pagination = usePagination({ pageSize: 50, resetKey: statusFilter });\n\n const { data, loading, error, refetch } = useCosNotebooksQuery({\n status: statusFilter,\n pagination: { limit: pagination.limit, offset: pagination.offset },\n });\n const [archiveNotebook] = useCosArchiveNotebookMutation();\n\n const notebooks = data?.cosListNotebooks.items ?? [];\n const pageInfo = data?.cosListNotebooks.pageInfo;\n\n const handleArchive = async (notebook: CosNotebook) => {\n const response = await archiveNotebook({ variables: { id: notebook.id } });\n if (response.error) {\n // onError already surfaced the toast; rethrow so the confirm dialog stays open.\n throw new Error(response.error.message);\n }\n if (!response.data?.cosArchiveNotebook) {\n notify.error(\n tr('cosmicintersection.pages.notebooks.archiveError', 'Could not archive notebook'),\n tr(\n 'cosmicintersection.pages.notebooks.archiveErrorDescription',\n 'The server did not confirm the change.'\n )\n );\n throw new Error('Archive not confirmed');\n }\n await refetch();\n notify.success(\n tr('cosmicintersection.pages.notebooks.archiveSuccess', 'Notebook archived'),\n tr(\n 'cosmicintersection.pages.notebooks.archiveSuccessDescription',\n '“{{name}}” was archived.',\n { name: notebook.title }\n )\n );\n };\n\n const actions = (\n <Button type=\"button\" onClick={() => navigate('notebooks/create')}>\n <Plus className=\"size-4\" />\n {tr('cosmicintersection.pages.notebooks.create', 'New notebook')}\n </Button>\n );\n\n return (\n <PageLayout\n title={tr('cosmicintersection.pages.notebooks.title', 'Notebooks')}\n description={tr(\n 'cosmicintersection.pages.notebooks.description',\n 'Computational notebooks for running analyses over federated science datasets.'\n )}\n actions={actions}\n >\n <div className=\"space-y-4\">\n <div className=\"flex flex-wrap items-center gap-3\">\n <label className=\"text-sm text-text-secondary\" htmlFor=\"notebook-status-filter\">\n Status\n </label>\n <Select\n value={statusFilter ?? ALL}\n onValueChange={(value) =>\n setStatusFilter(value === ALL ? undefined : (value as CosNotebookStatus))\n }\n >\n <SelectTrigger\n id=\"notebook-status-filter\"\n className=\"w-48\"\n aria-label=\"Filter by status\"\n >\n <SelectValue />\n </SelectTrigger>\n <SelectContent>\n <SelectItem value={ALL}>All statuses</SelectItem>\n {STATUS_OPTIONS.map((option) => (\n <SelectItem key={option.value} value={option.value}>\n {option.label}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n\n {loading ? (\n <LoadingState\n variant=\"rows\"\n rows={6}\n label={tr('cosmicintersection.pages.notebooks.loading', 'Loading notebooks…')}\n />\n ) : error ? (\n <ErrorState\n message={tr(\n 'cosmicintersection.pages.notebooks.error',\n 'We could not load your notebooks. Please try again.'\n )}\n onRetry={() => void refetch()}\n />\n ) : notebooks.length === 0 ? (\n <EmptyState\n icon={NotebookText}\n title={\n statusFilter\n ? tr(\n 'cosmicintersection.pages.notebooks.emptyFilterTitle',\n 'No notebooks match this filter.'\n )\n : tr('cosmicintersection.pages.notebooks.emptyTitle', 'No notebooks yet.')\n }\n description={\n statusFilter\n ? tr(\n 'cosmicintersection.pages.notebooks.emptyFilterDescription',\n 'Try a different status filter.'\n )\n : tr(\n 'cosmicintersection.pages.notebooks.emptyDescription',\n 'Create your first notebook to start analysing federated datasets.'\n )\n }\n action={\n statusFilter ? undefined : (\n <Button type=\"button\" onClick={() => navigate('notebooks/create')}>\n <Plus className=\"size-4\" />\n {tr('cosmicintersection.pages.notebooks.create', 'New notebook')}\n </Button>\n )\n }\n />\n ) : (\n <>\n {/* Desktop table */}\n <div className=\"hidden rounded-card border border-border-default bg-bg-elevated md:block\">\n <Table>\n <TableHeader>\n <TableRow>\n <TableHead>Title</TableHead>\n <TableHead>Status</TableHead>\n <TableHead>Runtime</TableHead>\n <TableHead className=\"text-right\">Datasets</TableHead>\n <TableHead>Sharing</TableHead>\n <TableHead>Tags</TableHead>\n <TableHead>Updated</TableHead>\n <TableHead className=\"w-12 text-right\">Actions</TableHead>\n </TableRow>\n </TableHeader>\n <TableBody>\n {notebooks.map((notebook) => (\n <TableRow\n key={notebook.id}\n className=\"cursor-pointer\"\n onClick={() => navigate(`notebooks/${notebook.id}`)}\n >\n <TableCell className=\"font-medium text-text-primary\">\n {notebook.title}\n </TableCell>\n <TableCell>\n <StatusBadge status={notebook.status} />\n </TableCell>\n <TableCell className=\"text-text-secondary\">\n {notebook.runtime ?? '—'}\n </TableCell>\n <TableCell className=\"text-right tabular-nums text-text-secondary\">\n {notebook.datasetIds.length}\n </TableCell>\n <TableCell>\n {notebook.isShared ? (\n <Badge variant=\"secondary\" className=\"gap-1\">\n <Share2 className=\"size-3\" aria-hidden=\"true\" />\n {tr('cosmicintersection.common.shared', 'Shared')}\n </Badge>\n ) : (\n <span className=\"text-text-secondary\">\n {tr('cosmicintersection.common.private', 'Private')}\n </span>\n )}\n </TableCell>\n <TableCell>\n {notebook.tags.length > 0 ? (\n <div className=\"flex flex-wrap gap-1\">\n {notebook.tags.slice(0, 3).map((tag) => (\n <Badge key={tag} variant=\"outline\">\n {tag}\n </Badge>\n ))}\n {notebook.tags.length > 3 ? (\n <span className=\"text-xs text-text-secondary\">\n +{notebook.tags.length - 3}\n </span>\n ) : null}\n </div>\n ) : (\n <span className=\"text-text-secondary\">—</span>\n )}\n </TableCell>\n <TableCell className=\"whitespace-nowrap text-text-secondary\">\n {formatDate(notebook.updatedAt)}\n </TableCell>\n <TableCell className=\"text-right\">\n <ActionMenu\n ariaLabel={`Actions for ${notebook.title}`}\n entityName={notebook.title}\n onView={() => navigate(`notebooks/${notebook.id}`)}\n onEdit={() => navigate(`notebooks/${notebook.id}/edit`)}\n onDelete={\n notebook.status === 'ARCHIVED'\n ? undefined\n : () => handleArchive(notebook)\n }\n deleteLabel={tr(\n 'cosmicintersection.pages.notebooks.archive',\n 'Archive notebook'\n )}\n />\n </TableCell>\n </TableRow>\n ))}\n </TableBody>\n </Table>\n </div>\n\n {/* Mobile card list */}\n <ul className=\"space-y-3 md:hidden\">\n {notebooks.map((notebook) => (\n <li\n key={notebook.id}\n className=\"rounded-card border border-border-default bg-bg-elevated\"\n >\n <div className=\"flex items-start justify-between gap-2 p-4\">\n <button\n type=\"button\"\n onClick={() => navigate(`notebooks/${notebook.id}`)}\n className=\"min-w-0 flex-1 space-y-2 text-left\"\n >\n <div className=\"flex flex-wrap items-center gap-2\">\n <span className=\"truncate font-medium text-text-primary\">\n {notebook.title}\n </span>\n <StatusBadge status={notebook.status} />\n </div>\n <div className=\"flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-text-secondary\">\n <span>Runtime: {notebook.runtime ?? '—'}</span>\n <span className=\"tabular-nums\">\n {notebook.datasetIds.length} dataset\n {notebook.datasetIds.length === 1 ? '' : 's'}\n </span>\n {notebook.isShared ? (\n <span className=\"inline-flex items-center gap-1\">\n <Share2 className=\"size-3\" aria-hidden=\"true\" />\n {tr('cosmicintersection.common.shared', 'Shared')}\n </span>\n ) : (\n <span>{tr('cosmicintersection.common.private', 'Private')}</span>\n )}\n <span>Updated {formatDate(notebook.updatedAt)}</span>\n </div>\n {notebook.tags.length > 0 ? (\n <div className=\"flex flex-wrap gap-1\">\n {notebook.tags.slice(0, 4).map((tag) => (\n <Badge key={tag} variant=\"outline\">\n {tag}\n </Badge>\n ))}\n {notebook.tags.length > 4 ? (\n <span className=\"text-xs text-text-secondary\">\n +{notebook.tags.length - 4}\n </span>\n ) : null}\n </div>\n ) : null}\n </button>\n <ActionMenu\n ariaLabel={`Actions for ${notebook.title}`}\n entityName={notebook.title}\n onView={() => navigate(`notebooks/${notebook.id}`)}\n onEdit={() => navigate(`notebooks/${notebook.id}/edit`)}\n onDelete={\n notebook.status === 'ARCHIVED' ? undefined : () => handleArchive(notebook)\n }\n deleteLabel={tr(\n 'cosmicintersection.pages.notebooks.archive',\n 'Archive notebook'\n )}\n />\n </div>\n </li>\n ))}\n </ul>\n </>\n )}\n\n {!loading && !error && notebooks.length > 0 ? (\n <Pagination\n offset={pagination.offset}\n limit={pagination.limit}\n loadedCount={notebooks.length}\n hasMore={pageInfo?.hasMore ?? false}\n onPrev={pagination.prevPage}\n onNext={pagination.nextPage}\n itemLabel={tr('cosmicintersection.pages.notebooks.itemLabel', 'notebooks')}\n loading={loading}\n />\n ) : null}\n </div>\n </PageLayout>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AA+CA,IAAME,IAAgE;CACpE;EAAE,OAAO;EAAS,OAAO;CAAQ;CACjC;EAAE,OAAO;EAAW,OAAO;CAAU;CACrC;EAAE,OAAO;EAAa,OAAO;CAAY;CACzC;E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;QACtD,UACEA,EAAS,WAAW,aAAa,KAAA,UAAkBF,EAAcE,CAAQ;QAE3E,aAAaf,EACX,8CACA,kBACF;OACD,CAAA,CACE;;KACH,GA5DGe,EAAS,EA4DZ,CACL;IACC,CAAA,CACJ,EAAA,CAAA;IAGH,CAACc,KAAW,CAACE,KAASrB,EAAU,SAAS,IACxC,kBAACoC,GAAD;KACE,QAAQzC,EAAW;KACnB,OAAOA,EAAW;KAClB,aAAaK,EAAU;KACvB,SAASE,GAAU,WAAW;KAC9B,QAAQP,EAAW;KACnB,QAAQA,EAAW;KACnB,WAAWL,EAAG,gDAAgD,WAAW;KAChE;IACV,CAAA,IACC;GACD;;CACK,CAAA;AAEhB"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
1
|
+
import { useCosArchivePipelineMutation as e, useCosPipelineQuery as t, useCosRunStepsQuery as n, useCosRunsQuery as r, useCosStartRunMutation as ee, useWorkflowDefinitionQuery as te } from "../../api/cosmicApi.js";
|
|
2
|
+
import "../../components/index.js";
|
|
3
|
+
import { StepDAG as ne } from "../../components/StepDAG.js";
|
|
4
4
|
import { EmptyState as i } from "../../components/EmptyState.js";
|
|
5
5
|
import { ErrorState as a } from "../../components/ErrorState.js";
|
|
6
6
|
import { LoadingState as o } from "../../components/LoadingState.js";
|
|
7
7
|
import { PageLayout as s } from "../../components/PageLayout.js";
|
|
8
|
-
import { Pagination as
|
|
9
|
-
import { StatusBadge as
|
|
10
|
-
import "../../
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import { useMemo as
|
|
15
|
-
import { Fragment as
|
|
16
|
-
import { useParams as
|
|
17
|
-
import { AlertDialog as
|
|
18
|
-
import { Archive as
|
|
19
|
-
|
|
8
|
+
import { Pagination as c, usePagination as l } from "../../components/Pagination.js";
|
|
9
|
+
import { StatusBadge as u } from "../../components/StatusBadge.js";
|
|
10
|
+
import { useCosmicIntersection as re } from "../../context/CosmicIntersectionContext.js";
|
|
11
|
+
import { mutationSucceeded as d } from "../../lib/mutationResult.js";
|
|
12
|
+
import { notify as f } from "../../lib/toast.js";
|
|
13
|
+
import { useTrackRecentItem as ie } from "../../lib/useTrackRecentItem.js";
|
|
14
|
+
import { useMemo as p, useState as ae } from "react";
|
|
15
|
+
import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
16
|
+
import { useParams as oe } from "react-router";
|
|
17
|
+
import { AlertDialog as se, AlertDialogAction as _, AlertDialogCancel as ce, AlertDialogContent as le, AlertDialogDescription as ue, AlertDialogFooter as de, AlertDialogHeader as fe, AlertDialogTitle as pe, Button as v, Card as y, CardContent as b, CardHeader as x, CardTitle as S, Table as me, TableBody as C, TableCell as w, TableHead as T, TableHeader as he, TableRow as E, buttonVariants as ge } from "@burdenoff/fe-libs/ui";
|
|
18
|
+
import { Archive as _e, Pencil as D, Play as O, Workflow as ve } from "lucide-react";
|
|
19
|
+
// src/cosmicintersection/pages/pipelines/PipelineDetailPage.tsx
|
|
20
20
|
var k = [
|
|
21
21
|
"INGEST",
|
|
22
22
|
"CALIBRATE",
|
|
@@ -54,73 +54,73 @@ function M(e) {
|
|
|
54
54
|
return t < 60 ? `${t.toFixed(1)} s` : `${Math.floor(t / 60)}m ${Math.round(t % 60)}s`;
|
|
55
55
|
}
|
|
56
56
|
function N({ label: e, children: t }) {
|
|
57
|
-
return /* @__PURE__ */
|
|
57
|
+
return /* @__PURE__ */ g("div", {
|
|
58
58
|
className: "flex flex-col gap-1 border-b border-border-seam py-3 last:border-0 sm:flex-row sm:items-start sm:gap-4",
|
|
59
|
-
children: [/* @__PURE__ */
|
|
59
|
+
children: [/* @__PURE__ */ h("span", {
|
|
60
60
|
className: "w-40 shrink-0 text-sm font-medium text-text-secondary",
|
|
61
61
|
children: e
|
|
62
|
-
}), /* @__PURE__ */
|
|
62
|
+
}), /* @__PURE__ */ h("span", {
|
|
63
63
|
className: "min-w-0 text-sm text-text-primary",
|
|
64
64
|
children: t
|
|
65
65
|
})]
|
|
66
66
|
});
|
|
67
67
|
}
|
|
68
68
|
function P({ icon: e, children: t }) {
|
|
69
|
-
return /* @__PURE__ */
|
|
69
|
+
return /* @__PURE__ */ g("span", {
|
|
70
70
|
className: "inline-flex items-center gap-1.5 rounded-full border border-border-default bg-bg-elevated px-2.5 py-0.5 text-xs text-text-secondary",
|
|
71
|
-
children: [e ? /* @__PURE__ */
|
|
71
|
+
children: [e ? /* @__PURE__ */ h(e, {
|
|
72
72
|
className: "size-3.5",
|
|
73
73
|
"aria-hidden": "true"
|
|
74
74
|
}) : null, t]
|
|
75
75
|
});
|
|
76
76
|
}
|
|
77
77
|
function F() {
|
|
78
|
-
let { id: k = "" } =
|
|
78
|
+
let { id: k = "" } = oe(), { navigate: A } = re(), { data: F, loading: be, error: xe, refetch: I } = t(k), L = l({
|
|
79
79
|
pageSize: 10,
|
|
80
80
|
resetKey: k
|
|
81
|
-
}), { data: R, loading: z, error: Se, refetch: B } =
|
|
81
|
+
}), { data: R, loading: z, error: Se, refetch: B } = r({
|
|
82
82
|
pipelineId: k,
|
|
83
83
|
pagination: {
|
|
84
84
|
limit: L.limit,
|
|
85
85
|
offset: L.offset
|
|
86
86
|
}
|
|
87
|
-
}), V = F?.cosPipeline, { data: Ce } =
|
|
88
|
-
|
|
87
|
+
}), V = F?.cosPipeline, { data: Ce } = te(V?.workflowDefinitionId), H = Ce?.workflowDefinition ?? null;
|
|
88
|
+
ie(V ? {
|
|
89
89
|
type: "pipeline",
|
|
90
90
|
id: V.id,
|
|
91
91
|
name: V.name,
|
|
92
92
|
path: `pipelines/${encodeURIComponent(V.id)}`
|
|
93
93
|
} : null);
|
|
94
|
-
let U =
|
|
94
|
+
let U = p(() => R?.cosListRuns.items ?? [], [R]), we = R?.cosListRuns.pageInfo, W = p(() => ye(V?.steps), [V?.steps]), G = U[0]?.id ?? "", Te = !!V && W.length === 0 && !!G, { data: K } = n(Te ? G : ""), q = p(() => [...K?.cosListRunSteps ?? []].sort((e, t) => e.position - t.position).map((e) => ({
|
|
95
95
|
kind: e.kind,
|
|
96
96
|
name: e.name,
|
|
97
97
|
status: e.status
|
|
98
|
-
})), [K]), J = W.length > 0 ? W : q,
|
|
98
|
+
})), [K]), J = W.length > 0 ? W : q, Ee = W.length === 0 && q.length > 0, [De, { loading: Y }] = ee(), [Oe, { loading: X }] = e(), [ke, Z] = ae(!1), Q = async () => {
|
|
99
99
|
if (!V) return;
|
|
100
|
-
let e = await
|
|
101
|
-
|
|
102
|
-
},
|
|
100
|
+
let e = await De({ variables: { input: { pipelineId: V.id } } }), t = e.data?.cosStartRun?.id;
|
|
101
|
+
d(e, t, "Could not start a run") && (f.success("Run started", "A new run was queued."), await Promise.all([I(), B()]), t && A(`runs/${t}`));
|
|
102
|
+
}, Ae = async () => {
|
|
103
103
|
if (!V) return;
|
|
104
|
-
let e = await
|
|
105
|
-
|
|
104
|
+
let e = await Oe({ variables: { id: V.id } });
|
|
105
|
+
d(e, e.data?.cosArchivePipeline, "Could not archive pipeline") && (Z(!1), f.success("Pipeline archived", `“${V.name}” was archived.`), A("pipelines"));
|
|
106
106
|
};
|
|
107
|
-
if (be) return /* @__PURE__ */
|
|
107
|
+
if (be) return /* @__PURE__ */ h(s, {
|
|
108
108
|
title: "Pipeline",
|
|
109
109
|
backPath: "pipelines",
|
|
110
|
-
children: /* @__PURE__ */
|
|
110
|
+
children: /* @__PURE__ */ h(o, { label: "Loading pipeline…" })
|
|
111
111
|
});
|
|
112
|
-
if (xe) return /* @__PURE__ */
|
|
112
|
+
if (xe) return /* @__PURE__ */ h(s, {
|
|
113
113
|
title: "Pipeline",
|
|
114
114
|
backPath: "pipelines",
|
|
115
|
-
children: /* @__PURE__ */
|
|
115
|
+
children: /* @__PURE__ */ h(a, { onRetry: () => void I() })
|
|
116
116
|
});
|
|
117
|
-
if (!V) return /* @__PURE__ */
|
|
117
|
+
if (!V) return /* @__PURE__ */ h(s, {
|
|
118
118
|
title: "Pipeline",
|
|
119
119
|
backPath: "pipelines",
|
|
120
|
-
children: /* @__PURE__ */
|
|
120
|
+
children: /* @__PURE__ */ h(i, {
|
|
121
121
|
title: "Pipeline not found",
|
|
122
122
|
description: "This pipeline may have been archived or you may not have access to it.",
|
|
123
|
-
action: /* @__PURE__ */
|
|
123
|
+
action: /* @__PURE__ */ h(v, {
|
|
124
124
|
type: "button",
|
|
125
125
|
variant: "outline",
|
|
126
126
|
onClick: () => A("pipelines"),
|
|
@@ -128,216 +128,216 @@ function F() {
|
|
|
128
128
|
})
|
|
129
129
|
})
|
|
130
130
|
});
|
|
131
|
-
let $ = V.status === "ARCHIVED",
|
|
132
|
-
return /* @__PURE__ */
|
|
131
|
+
let $ = V.status === "ARCHIVED", je = !!(V.steps && Object.keys(V.steps).length > 0);
|
|
132
|
+
return /* @__PURE__ */ g(s, {
|
|
133
133
|
title: V.name,
|
|
134
134
|
description: V.description ?? void 0,
|
|
135
135
|
backPath: "pipelines",
|
|
136
|
-
actions: /* @__PURE__ */
|
|
136
|
+
actions: /* @__PURE__ */ g("div", {
|
|
137
137
|
className: "flex flex-wrap items-center gap-2",
|
|
138
138
|
children: [
|
|
139
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ g(v, {
|
|
140
140
|
type: "button",
|
|
141
141
|
onClick: () => void Q(),
|
|
142
142
|
disabled: Y || $,
|
|
143
|
-
children: [/* @__PURE__ */
|
|
143
|
+
children: [/* @__PURE__ */ h(O, { className: "size-4" }), Y ? "Starting…" : "Start run"]
|
|
144
144
|
}),
|
|
145
|
-
/* @__PURE__ */
|
|
145
|
+
/* @__PURE__ */ g(v, {
|
|
146
146
|
type: "button",
|
|
147
147
|
variant: "outline",
|
|
148
148
|
onClick: () => A(`pipelines/${V.id}/edit`),
|
|
149
|
-
children: [/* @__PURE__ */
|
|
149
|
+
children: [/* @__PURE__ */ h(D, { className: "size-4" }), "Edit"]
|
|
150
150
|
}),
|
|
151
|
-
$ ? null : /* @__PURE__ */
|
|
151
|
+
$ ? null : /* @__PURE__ */ g(v, {
|
|
152
152
|
type: "button",
|
|
153
153
|
variant: "outline",
|
|
154
154
|
onClick: () => Z(!0),
|
|
155
|
-
children: [/* @__PURE__ */
|
|
155
|
+
children: [/* @__PURE__ */ h(_e, { className: "size-4" }), "Archive"]
|
|
156
156
|
})
|
|
157
157
|
]
|
|
158
158
|
}),
|
|
159
|
-
children: [/* @__PURE__ */
|
|
159
|
+
children: [/* @__PURE__ */ g("div", {
|
|
160
160
|
className: "space-y-6",
|
|
161
161
|
children: [
|
|
162
|
-
/* @__PURE__ */
|
|
162
|
+
/* @__PURE__ */ g("div", {
|
|
163
163
|
className: "flex flex-wrap items-center gap-2",
|
|
164
|
-
children: [/* @__PURE__ */
|
|
165
|
-
icon:
|
|
164
|
+
children: [/* @__PURE__ */ h(u, { status: V.status }), V.workflowDefinitionId ? /* @__PURE__ */ h(P, {
|
|
165
|
+
icon: ve,
|
|
166
166
|
children: H ? `${H.name} (v${H.version})` : "Workflow-linked"
|
|
167
|
-
}) : /* @__PURE__ */
|
|
168
|
-
icon:
|
|
167
|
+
}) : /* @__PURE__ */ h(P, {
|
|
168
|
+
icon: O,
|
|
169
169
|
children: "Manual runs"
|
|
170
170
|
})]
|
|
171
171
|
}),
|
|
172
|
-
/* @__PURE__ */
|
|
172
|
+
/* @__PURE__ */ g(y, { children: [/* @__PURE__ */ h(x, { children: /* @__PURE__ */ h(S, { children: "Overview" }) }), /* @__PURE__ */ g(b, {
|
|
173
173
|
className: "space-y-4",
|
|
174
174
|
children: [
|
|
175
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ g("div", {
|
|
176
176
|
className: "flex flex-wrap items-baseline justify-between gap-2",
|
|
177
|
-
children: [/* @__PURE__ */
|
|
177
|
+
children: [/* @__PURE__ */ h("span", {
|
|
178
178
|
className: "text-sm font-medium text-text-secondary",
|
|
179
179
|
children: "Step flow"
|
|
180
|
-
}),
|
|
180
|
+
}), Ee ? /* @__PURE__ */ h("span", {
|
|
181
181
|
className: "text-xs text-text-secondary",
|
|
182
182
|
children: "Derived from the latest run."
|
|
183
183
|
}) : null]
|
|
184
184
|
}),
|
|
185
|
-
J.length > 0 ? /* @__PURE__ */
|
|
185
|
+
J.length > 0 ? /* @__PURE__ */ h(ne, { steps: J }) : /* @__PURE__ */ g("div", {
|
|
186
186
|
className: "rounded-card border border-dashed border-border-default bg-bg-sunken px-4 py-8 text-center",
|
|
187
|
-
children: [/* @__PURE__ */
|
|
187
|
+
children: [/* @__PURE__ */ h("p", {
|
|
188
188
|
className: "text-sm text-text-secondary",
|
|
189
189
|
children: "No steps defined yet. Edit the pipeline to add ingest, calibrate, transform, analyze or export steps."
|
|
190
|
-
}), /* @__PURE__ */
|
|
190
|
+
}), /* @__PURE__ */ g(v, {
|
|
191
191
|
type: "button",
|
|
192
192
|
variant: "outline",
|
|
193
193
|
size: "sm",
|
|
194
194
|
className: "mt-3",
|
|
195
195
|
onClick: () => A(`pipelines/${V.id}/edit`),
|
|
196
|
-
children: [/* @__PURE__ */
|
|
196
|
+
children: [/* @__PURE__ */ h(D, { className: "size-4" }), "Add steps"]
|
|
197
197
|
})]
|
|
198
198
|
}),
|
|
199
|
-
|
|
199
|
+
je ? /* @__PURE__ */ g("details", {
|
|
200
200
|
className: "group rounded-card border border-border-default bg-bg-sunken",
|
|
201
|
-
children: [/* @__PURE__ */
|
|
201
|
+
children: [/* @__PURE__ */ g("summary", {
|
|
202
202
|
className: "flex cursor-pointer list-none items-center justify-between px-4 py-2.5 text-sm font-medium text-text-secondary transition-colors hover:text-text-primary",
|
|
203
|
-
children: ["Advanced — raw steps JSON", /* @__PURE__ */
|
|
203
|
+
children: ["Advanced — raw steps JSON", /* @__PURE__ */ h("span", {
|
|
204
204
|
className: "text-xs text-text-secondary transition-transform group-open:rotate-180",
|
|
205
205
|
children: "▾"
|
|
206
206
|
})]
|
|
207
|
-
}), /* @__PURE__ */
|
|
207
|
+
}), /* @__PURE__ */ h("pre", {
|
|
208
208
|
className: "overflow-x-auto border-t border-border-seam p-4 font-mono text-xs text-text-primary",
|
|
209
209
|
children: JSON.stringify(V.steps, null, 2)
|
|
210
210
|
})]
|
|
211
211
|
}) : null
|
|
212
212
|
]
|
|
213
213
|
})] }),
|
|
214
|
-
/* @__PURE__ */
|
|
215
|
-
/* @__PURE__ */
|
|
214
|
+
/* @__PURE__ */ g(y, { children: [/* @__PURE__ */ h(x, { children: /* @__PURE__ */ h(S, { children: "Details" }) }), /* @__PURE__ */ g(b, { children: [
|
|
215
|
+
/* @__PURE__ */ h(N, {
|
|
216
216
|
label: "Status",
|
|
217
|
-
children: /* @__PURE__ */
|
|
217
|
+
children: /* @__PURE__ */ h(u, { status: V.status })
|
|
218
218
|
}),
|
|
219
|
-
/* @__PURE__ */
|
|
219
|
+
/* @__PURE__ */ h(N, {
|
|
220
220
|
label: "Automation",
|
|
221
|
-
children: V.workflowDefinitionId ? /* @__PURE__ */
|
|
221
|
+
children: V.workflowDefinitionId ? /* @__PURE__ */ g(m, { children: [
|
|
222
222
|
H ? `${H.name} (v${H.version}, ${H.status})` : "Linked workflow",
|
|
223
223
|
" · ",
|
|
224
|
-
/* @__PURE__ */
|
|
224
|
+
/* @__PURE__ */ h("a", {
|
|
225
225
|
href: "/workflows",
|
|
226
226
|
className: "underline underline-offset-2",
|
|
227
227
|
children: "Open Workflows"
|
|
228
228
|
})
|
|
229
229
|
] }) : "Manual — start a run from this page"
|
|
230
230
|
}),
|
|
231
|
-
/* @__PURE__ */
|
|
231
|
+
/* @__PURE__ */ h(N, {
|
|
232
232
|
label: "Last run",
|
|
233
233
|
children: j(V.lastRunAt)
|
|
234
234
|
}),
|
|
235
|
-
/* @__PURE__ */
|
|
235
|
+
/* @__PURE__ */ h(N, {
|
|
236
236
|
label: "Created",
|
|
237
237
|
children: j(V.createdAt)
|
|
238
238
|
}),
|
|
239
|
-
/* @__PURE__ */
|
|
239
|
+
/* @__PURE__ */ h(N, {
|
|
240
240
|
label: "Tags",
|
|
241
|
-
children: V.tags.length === 0 ? "—" : /* @__PURE__ */
|
|
241
|
+
children: V.tags.length === 0 ? "—" : /* @__PURE__ */ h("span", {
|
|
242
242
|
className: "flex flex-wrap gap-1",
|
|
243
|
-
children: V.tags.map((e) => /* @__PURE__ */
|
|
243
|
+
children: V.tags.map((e) => /* @__PURE__ */ h("span", {
|
|
244
244
|
className: "rounded-full bg-bg-sunken px-2 py-0.5 text-xs text-text-secondary",
|
|
245
245
|
children: e
|
|
246
246
|
}, e))
|
|
247
247
|
})
|
|
248
248
|
})
|
|
249
249
|
] })] }),
|
|
250
|
-
/* @__PURE__ */
|
|
250
|
+
/* @__PURE__ */ g(y, { children: [/* @__PURE__ */ h(x, { children: /* @__PURE__ */ h(S, { children: "Runs" }) }), /* @__PURE__ */ h(b, { children: z ? /* @__PURE__ */ h(o, {
|
|
251
251
|
variant: "rows",
|
|
252
252
|
rows: 4,
|
|
253
253
|
label: "Loading runs…"
|
|
254
|
-
}) : Se ? /* @__PURE__ */
|
|
254
|
+
}) : Se ? /* @__PURE__ */ h(a, {
|
|
255
255
|
message: "Could not load runs.",
|
|
256
256
|
onRetry: () => void B()
|
|
257
|
-
}) : U.length === 0 ? /* @__PURE__ */
|
|
258
|
-
icon:
|
|
257
|
+
}) : U.length === 0 ? /* @__PURE__ */ h(i, {
|
|
258
|
+
icon: O,
|
|
259
259
|
title: "No runs yet",
|
|
260
260
|
description: "Start a run to process data through this pipeline.",
|
|
261
|
-
action: /* @__PURE__ */
|
|
261
|
+
action: /* @__PURE__ */ g(v, {
|
|
262
262
|
type: "button",
|
|
263
263
|
onClick: () => void Q(),
|
|
264
264
|
disabled: $,
|
|
265
|
-
children: [/* @__PURE__ */
|
|
265
|
+
children: [/* @__PURE__ */ h(O, { className: "size-4" }), "Start run"]
|
|
266
266
|
})
|
|
267
|
-
}) : /* @__PURE__ */
|
|
268
|
-
/* @__PURE__ */
|
|
267
|
+
}) : /* @__PURE__ */ g(m, { children: [
|
|
268
|
+
/* @__PURE__ */ h("div", {
|
|
269
269
|
className: "hidden rounded-card border border-border-default md:block",
|
|
270
|
-
children: /* @__PURE__ */
|
|
271
|
-
/* @__PURE__ */
|
|
272
|
-
/* @__PURE__ */
|
|
273
|
-
/* @__PURE__ */
|
|
274
|
-
/* @__PURE__ */
|
|
275
|
-
/* @__PURE__ */
|
|
276
|
-
] }) }), /* @__PURE__ */
|
|
270
|
+
children: /* @__PURE__ */ g(me, { children: [/* @__PURE__ */ h(he, { children: /* @__PURE__ */ g(E, { children: [
|
|
271
|
+
/* @__PURE__ */ h(T, { children: "Run" }),
|
|
272
|
+
/* @__PURE__ */ h(T, { children: "Status" }),
|
|
273
|
+
/* @__PURE__ */ h(T, { children: "Started" }),
|
|
274
|
+
/* @__PURE__ */ h(T, { children: "Duration" }),
|
|
275
|
+
/* @__PURE__ */ h(T, { children: "Triggered by" })
|
|
276
|
+
] }) }), /* @__PURE__ */ h(C, { children: U.map((e) => /* @__PURE__ */ g(E, {
|
|
277
277
|
className: "cursor-pointer",
|
|
278
278
|
onClick: () => A(`runs/${e.id}`),
|
|
279
279
|
children: [
|
|
280
|
-
/* @__PURE__ */
|
|
280
|
+
/* @__PURE__ */ g(w, {
|
|
281
281
|
className: "font-medium text-text-primary",
|
|
282
282
|
children: ["#", e.runNumber]
|
|
283
283
|
}),
|
|
284
|
-
/* @__PURE__ */
|
|
285
|
-
/* @__PURE__ */
|
|
284
|
+
/* @__PURE__ */ h(w, { children: /* @__PURE__ */ h(u, { status: e.status }) }),
|
|
285
|
+
/* @__PURE__ */ h(w, {
|
|
286
286
|
className: "whitespace-nowrap text-text-secondary",
|
|
287
287
|
children: j(e.startedAt)
|
|
288
288
|
}),
|
|
289
|
-
/* @__PURE__ */
|
|
289
|
+
/* @__PURE__ */ h(w, {
|
|
290
290
|
className: "tabular-nums text-text-secondary",
|
|
291
291
|
children: M(e.durationMs)
|
|
292
292
|
}),
|
|
293
|
-
/* @__PURE__ */
|
|
293
|
+
/* @__PURE__ */ h(w, {
|
|
294
294
|
className: "text-text-secondary",
|
|
295
295
|
children: e.triggeredBy || "—"
|
|
296
296
|
})
|
|
297
297
|
]
|
|
298
298
|
}, e.id)) })] })
|
|
299
299
|
}),
|
|
300
|
-
/* @__PURE__ */
|
|
300
|
+
/* @__PURE__ */ h("ul", {
|
|
301
301
|
className: "space-y-3 md:hidden",
|
|
302
|
-
children: U.map((e) => /* @__PURE__ */
|
|
302
|
+
children: U.map((e) => /* @__PURE__ */ h("li", { children: /* @__PURE__ */ g("button", {
|
|
303
303
|
type: "button",
|
|
304
304
|
onClick: () => A(`runs/${e.id}`),
|
|
305
305
|
className: "flex w-full flex-col gap-2 rounded-card border border-border-default bg-bg-elevated p-4 text-left transition-colors hover:border-border-strong",
|
|
306
|
-
children: [/* @__PURE__ */
|
|
306
|
+
children: [/* @__PURE__ */ g("div", {
|
|
307
307
|
className: "flex items-center justify-between gap-2",
|
|
308
|
-
children: [/* @__PURE__ */
|
|
308
|
+
children: [/* @__PURE__ */ g("span", {
|
|
309
309
|
className: "font-medium text-text-primary",
|
|
310
310
|
children: ["#", e.runNumber]
|
|
311
|
-
}), /* @__PURE__ */
|
|
312
|
-
}), /* @__PURE__ */
|
|
311
|
+
}), /* @__PURE__ */ h(u, { status: e.status })]
|
|
312
|
+
}), /* @__PURE__ */ g("dl", {
|
|
313
313
|
className: "grid grid-cols-2 gap-x-3 gap-y-1 text-xs text-text-secondary",
|
|
314
314
|
children: [
|
|
315
|
-
/* @__PURE__ */
|
|
315
|
+
/* @__PURE__ */ g("div", {
|
|
316
316
|
className: "flex flex-col",
|
|
317
|
-
children: [/* @__PURE__ */
|
|
317
|
+
children: [/* @__PURE__ */ h("dt", {
|
|
318
318
|
className: "text-text-secondary",
|
|
319
319
|
children: "Started"
|
|
320
|
-
}), /* @__PURE__ */
|
|
320
|
+
}), /* @__PURE__ */ h("dd", {
|
|
321
321
|
className: "text-text-primary",
|
|
322
322
|
children: j(e.startedAt)
|
|
323
323
|
})]
|
|
324
324
|
}),
|
|
325
|
-
/* @__PURE__ */
|
|
325
|
+
/* @__PURE__ */ g("div", {
|
|
326
326
|
className: "flex flex-col",
|
|
327
|
-
children: [/* @__PURE__ */
|
|
327
|
+
children: [/* @__PURE__ */ h("dt", {
|
|
328
328
|
className: "text-text-secondary",
|
|
329
329
|
children: "Duration"
|
|
330
|
-
}), /* @__PURE__ */
|
|
330
|
+
}), /* @__PURE__ */ h("dd", {
|
|
331
331
|
className: "tabular-nums text-text-primary",
|
|
332
332
|
children: M(e.durationMs)
|
|
333
333
|
})]
|
|
334
334
|
}),
|
|
335
|
-
/* @__PURE__ */
|
|
335
|
+
/* @__PURE__ */ g("div", {
|
|
336
336
|
className: "col-span-2 flex flex-col",
|
|
337
|
-
children: [/* @__PURE__ */
|
|
337
|
+
children: [/* @__PURE__ */ h("dt", {
|
|
338
338
|
className: "text-text-secondary",
|
|
339
339
|
children: "Triggered by"
|
|
340
|
-
}), /* @__PURE__ */
|
|
340
|
+
}), /* @__PURE__ */ h("dd", {
|
|
341
341
|
className: "text-text-primary",
|
|
342
342
|
children: e.triggeredBy || "—"
|
|
343
343
|
})]
|
|
@@ -346,7 +346,7 @@ function F() {
|
|
|
346
346
|
})]
|
|
347
347
|
}) }, e.id))
|
|
348
348
|
}),
|
|
349
|
-
/* @__PURE__ */
|
|
349
|
+
/* @__PURE__ */ h(c, {
|
|
350
350
|
offset: L.offset,
|
|
351
351
|
limit: L.limit,
|
|
352
352
|
loadedCount: U.length,
|
|
@@ -358,28 +358,27 @@ function F() {
|
|
|
358
358
|
})
|
|
359
359
|
] }) })] })
|
|
360
360
|
]
|
|
361
|
-
}), /* @__PURE__ */
|
|
362
|
-
open:
|
|
361
|
+
}), /* @__PURE__ */ h(se, {
|
|
362
|
+
open: ke,
|
|
363
363
|
onOpenChange: (e) => X ? void 0 : Z(e),
|
|
364
|
-
children: /* @__PURE__ */
|
|
364
|
+
children: /* @__PURE__ */ g(le, { children: [/* @__PURE__ */ g(fe, { children: [/* @__PURE__ */ g(pe, { children: [
|
|
365
365
|
"Archive “",
|
|
366
366
|
V.name,
|
|
367
367
|
"”?"
|
|
368
|
-
] }), /* @__PURE__ */
|
|
368
|
+
] }), /* @__PURE__ */ h(ue, { children: "Archiving stops the pipeline from being triggered. Existing runs are kept for reference." })] }), /* @__PURE__ */ g(de, { children: [/* @__PURE__ */ h(ce, {
|
|
369
369
|
disabled: X,
|
|
370
370
|
children: "Cancel"
|
|
371
|
-
}), /* @__PURE__ */
|
|
371
|
+
}), /* @__PURE__ */ h(_, {
|
|
372
372
|
onClick: (e) => {
|
|
373
|
-
e.preventDefault(),
|
|
373
|
+
e.preventDefault(), Ae();
|
|
374
374
|
},
|
|
375
375
|
disabled: X,
|
|
376
|
-
className:
|
|
376
|
+
className: ge({ variant: "destructive" }),
|
|
377
377
|
children: X ? "Archiving…" : "Archive pipeline"
|
|
378
378
|
})] })] })
|
|
379
379
|
})]
|
|
380
380
|
});
|
|
381
381
|
}
|
|
382
|
-
//#endregion
|
|
383
382
|
export { F as default };
|
|
384
383
|
|
|
385
384
|
//# sourceMappingURL=PipelineDetailPage.js.map
|