@burdenoff/microfe-cosmicintersection 2026.704.1 → 2026.704.3
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/CosmicIntersectionRoutes.js +45 -25
- package/dist/cosmicintersection/CosmicIntersectionRoutes.js.map +1 -1
- package/dist/cosmicintersection/api/cosmicApi.js +137 -66
- package/dist/cosmicintersection/api/cosmicApi.js.map +1 -1
- package/dist/cosmicintersection/components/ActivityFeedPanel.js +68 -0
- package/dist/cosmicintersection/components/ActivityFeedPanel.js.map +1 -0
- package/dist/cosmicintersection/components/DiscussionPanel.js +57 -0
- package/dist/cosmicintersection/components/DiscussionPanel.js.map +1 -0
- package/dist/cosmicintersection/components/FacetPanel.js +66 -0
- package/dist/cosmicintersection/components/FacetPanel.js.map +1 -0
- package/dist/cosmicintersection/components/LineageGraph.js +388 -0
- package/dist/cosmicintersection/components/LineageGraph.js.map +1 -0
- package/dist/cosmicintersection/components/ResultsChart.js +329 -0
- package/dist/cosmicintersection/components/ResultsChart.js.map +1 -0
- package/dist/cosmicintersection/components/StepDAG.js +104 -0
- package/dist/cosmicintersection/components/StepDAG.js.map +1 -0
- package/dist/cosmicintersection/components/index.js +5 -3
- package/dist/cosmicintersection/pages/access/AccessPage.js +220 -161
- package/dist/cosmicintersection/pages/access/AccessPage.js.map +1 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js +332 -172
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.js +167 -109
- package/dist/cosmicintersection/pages/collections/CollectionDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.js +87 -61
- package/dist/cosmicintersection/pages/collections/CollectionFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js +51 -42
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js +31 -18
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.js +330 -184
- package/dist/cosmicintersection/pages/datasets/DatasetDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetFormPage.js +7 -7
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js +321 -163
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js +358 -0
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js.map +1 -0
- package/dist/cosmicintersection/pages/lineage/LineagePage.js +171 -0
- package/dist/cosmicintersection/pages/lineage/LineagePage.js.map +1 -0
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.js +339 -260
- package/dist/cosmicintersection/pages/notebooks/NotebookDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js +143 -82
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.js +286 -142
- package/dist/cosmicintersection/pages/pipelines/PipelineDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.js +305 -103
- package/dist/cosmicintersection/pages/pipelines/PipelineFormPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js +183 -79
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js +346 -204
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunDetailPage.js +184 -136
- package/dist/cosmicintersection/pages/runs/RunDetailPage.js.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.js +182 -120
- package/dist/cosmicintersection/pages/runs/RunsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.js +234 -0
- package/dist/cosmicintersection/pages/sources/SourceDetailPage.js.map +1 -0
- package/dist/cosmicintersection/pages/sources/SourcesPage.js +250 -133
- package/dist/cosmicintersection/pages/sources/SourcesPage.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,27 +1,32 @@
|
|
|
1
1
|
import { useCosmicIntersection as e } from "../../context/CosmicIntersectionContext.js";
|
|
2
2
|
import { notify as t } from "../../lib/toast.js";
|
|
3
|
-
import { useCosArchiveDatasetMutation as n, useCosCollectionsQuery as r, useCosDatasetsQuery as i, useCosPublishDatasetMutation as a, useCosSourcesQuery as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
3
|
+
import { useCosArchiveDatasetMutation as n, useCosCollectionsQuery as r, useCosDatasetsQuery as i, useCosPublishDatasetMutation as a, useCosSourcesQuery as ee } from "../../api/cosmicApi.js";
|
|
4
|
+
import o from "../../components/ActionMenu.js";
|
|
5
|
+
import s from "../../components/EmptyState.js";
|
|
6
|
+
import c from "../../components/ErrorState.js";
|
|
7
|
+
import te from "../../components/LoadingState.js";
|
|
8
|
+
import l from "../../components/PageLayout.js";
|
|
9
|
+
import u, { usePagination as d } from "../../components/Pagination.js";
|
|
10
|
+
import f, { formatEnumLabel as p } from "../../components/StatusBadge.js";
|
|
11
11
|
import "../../components/index.js";
|
|
12
|
-
import { useMemo as
|
|
13
|
-
import { Fragment as
|
|
14
|
-
import { Database as
|
|
15
|
-
import { Badge as
|
|
12
|
+
import { useMemo as m, useState as h } from "react";
|
|
13
|
+
import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
14
|
+
import { Compass as ne, Database as re, Plus as y } from "lucide-react";
|
|
15
|
+
import { Badge as b, Button as x, Select as S, SelectContent as C, SelectItem as w, SelectTrigger as T, SelectValue as E, Table as ie, TableBody as ae, TableCell as D, TableHead as O, TableHeader as oe, TableRow as k } from "@burdenoff/fe-libs/ui";
|
|
16
16
|
//#region src/cosmicintersection/pages/datasets/DatasetsPage.tsx
|
|
17
|
-
var
|
|
17
|
+
var se = [
|
|
18
18
|
"DRAFT",
|
|
19
19
|
"INGESTING",
|
|
20
20
|
"AVAILABLE",
|
|
21
21
|
"DEPRECATED",
|
|
22
22
|
"ARCHIVED"
|
|
23
|
-
],
|
|
24
|
-
|
|
23
|
+
], ce = [
|
|
24
|
+
"PUBLIC",
|
|
25
|
+
"WORKSPACE",
|
|
26
|
+
"RESTRICTED",
|
|
27
|
+
"EMBARGOED"
|
|
28
|
+
], A = "__all__", le = 200;
|
|
29
|
+
function j(e) {
|
|
25
30
|
if (!e) return "—";
|
|
26
31
|
let t = Number(e);
|
|
27
32
|
if (!Number.isFinite(t) || t <= 0) return "—";
|
|
@@ -36,217 +41,370 @@ function I(e) {
|
|
|
36
41
|
for (; r >= 1024 && i < n.length - 1;) r /= 1024, i += 1;
|
|
37
42
|
return `${r >= 10 || i === 0 ? Math.round(r) : r.toFixed(1)} ${n[i]}`;
|
|
38
43
|
}
|
|
39
|
-
function
|
|
44
|
+
function M(e) {
|
|
40
45
|
if (!e) return "—";
|
|
41
46
|
let t = new Date(e);
|
|
42
47
|
return Number.isNaN(t.getTime()) ? "—" : t.toLocaleDateString();
|
|
43
48
|
}
|
|
44
|
-
function
|
|
45
|
-
let { navigate:
|
|
49
|
+
function N() {
|
|
50
|
+
let { navigate: N } = e(), [P, F] = h(A), [I, L] = h(A), [R, z] = h(A), [B, V] = h(A), [H, U] = h(A), W = d({
|
|
46
51
|
pageSize: 20,
|
|
47
|
-
resetKey: `${
|
|
48
|
-
}), { data:
|
|
49
|
-
status:
|
|
50
|
-
sourceId:
|
|
51
|
-
collectionId:
|
|
52
|
+
resetKey: `${P}|${I}|${R}|${B}|${H}`
|
|
53
|
+
}), { data: G, loading: K, error: ue, refetch: q } = i({
|
|
54
|
+
status: P === A ? void 0 : P,
|
|
55
|
+
sourceId: I === A ? void 0 : I,
|
|
56
|
+
collectionId: R === A ? void 0 : R,
|
|
57
|
+
format: B === A ? void 0 : B,
|
|
58
|
+
accessLevel: H === A ? void 0 : H,
|
|
52
59
|
pagination: {
|
|
53
|
-
limit:
|
|
54
|
-
offset:
|
|
60
|
+
limit: W.limit,
|
|
61
|
+
offset: W.offset
|
|
55
62
|
}
|
|
56
|
-
}),
|
|
63
|
+
}), de = ee({ pagination: {
|
|
57
64
|
limit: 100,
|
|
58
65
|
offset: 0
|
|
59
|
-
} }),
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
66
|
+
} }), fe = r(), J = i({ pagination: {
|
|
67
|
+
limit: le,
|
|
68
|
+
offset: 0
|
|
69
|
+
} }), [pe] = a(), [me] = n(), Y = m(() => G?.cosListDatasets?.items ?? [], [G]), he = G?.cosListDatasets?.pageInfo, ge = de.data?.cosListSources?.items ?? [], _e = fe.data?.cosListCollections ?? [], X = m(() => {
|
|
70
|
+
let e = /* @__PURE__ */ new Set();
|
|
71
|
+
for (let t of J.data?.cosListDatasets?.items ?? []) t.format && e.add(t.format);
|
|
72
|
+
return [...e].sort((e, t) => e.localeCompare(t));
|
|
73
|
+
}, [J.data]), Z = P === A && I === A && R === A && B === A && H === A, Q = async (e) => {
|
|
74
|
+
(await pe({ variables: { id: e.id } })).data?.cosPublishDataset && (t.success("Dataset published", `“${e.name}” is now available.`), await q());
|
|
75
|
+
}, $ = async (e) => {
|
|
76
|
+
let n = await me({ variables: { id: e.id } });
|
|
63
77
|
if (n.error) throw Error(n.error.message);
|
|
64
78
|
if (!n.data?.cosArchiveDataset) throw t.error("Could not archive dataset", "The server did not confirm the change."), Error("Archive not confirmed");
|
|
65
|
-
t.success("Dataset archived"), await
|
|
79
|
+
t.success("Dataset archived"), await q();
|
|
66
80
|
};
|
|
67
|
-
return /* @__PURE__ */
|
|
81
|
+
return /* @__PURE__ */ _(l, {
|
|
68
82
|
title: "Datasets",
|
|
69
83
|
description: "Federated science datasets — catalog, schema, lineage and access, all from live data.",
|
|
70
|
-
actions: /* @__PURE__ */
|
|
84
|
+
actions: /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ v(x, {
|
|
85
|
+
type: "button",
|
|
86
|
+
variant: "outline",
|
|
87
|
+
onClick: () => N("discovery"),
|
|
88
|
+
children: [/* @__PURE__ */ _(ne, { className: "size-4" }), "Discover"]
|
|
89
|
+
}), /* @__PURE__ */ v(x, {
|
|
71
90
|
type: "button",
|
|
72
|
-
onClick: () =>
|
|
73
|
-
children: [/* @__PURE__ */
|
|
74
|
-
}),
|
|
75
|
-
children: /* @__PURE__ */
|
|
91
|
+
onClick: () => N("datasets/create"),
|
|
92
|
+
children: [/* @__PURE__ */ _(y, { className: "size-4" }), "New dataset"]
|
|
93
|
+
})] }),
|
|
94
|
+
children: /* @__PURE__ */ v("div", {
|
|
76
95
|
className: "space-y-4",
|
|
77
|
-
children: [/* @__PURE__ */
|
|
96
|
+
children: [/* @__PURE__ */ v("div", {
|
|
78
97
|
className: "flex flex-wrap items-end gap-3",
|
|
79
98
|
children: [
|
|
80
|
-
/* @__PURE__ */
|
|
99
|
+
/* @__PURE__ */ v("label", {
|
|
81
100
|
className: "space-y-1 text-sm",
|
|
82
|
-
children: [/* @__PURE__ */
|
|
101
|
+
children: [/* @__PURE__ */ _("span", {
|
|
83
102
|
className: "block font-medium text-text-primary",
|
|
84
103
|
children: "Status"
|
|
85
|
-
}), /* @__PURE__ */
|
|
86
|
-
value:
|
|
87
|
-
onValueChange:
|
|
88
|
-
children: [/* @__PURE__ */
|
|
104
|
+
}), /* @__PURE__ */ v(S, {
|
|
105
|
+
value: P,
|
|
106
|
+
onValueChange: F,
|
|
107
|
+
children: [/* @__PURE__ */ _(T, {
|
|
89
108
|
"aria-label": "Filter by status",
|
|
90
109
|
className: "w-44",
|
|
91
|
-
children: /* @__PURE__ */
|
|
92
|
-
}), /* @__PURE__ */
|
|
93
|
-
value:
|
|
110
|
+
children: /* @__PURE__ */ _(E, {})
|
|
111
|
+
}), /* @__PURE__ */ v(C, { children: [/* @__PURE__ */ _(w, {
|
|
112
|
+
value: A,
|
|
94
113
|
children: "All statuses"
|
|
95
|
-
}),
|
|
114
|
+
}), se.map((e) => /* @__PURE__ */ _(w, {
|
|
96
115
|
value: e,
|
|
97
|
-
children:
|
|
116
|
+
children: p(e)
|
|
98
117
|
}, e))] })]
|
|
99
118
|
})]
|
|
100
119
|
}),
|
|
101
|
-
/* @__PURE__ */
|
|
120
|
+
/* @__PURE__ */ v("label", {
|
|
102
121
|
className: "space-y-1 text-sm",
|
|
103
|
-
children: [/* @__PURE__ */
|
|
122
|
+
children: [/* @__PURE__ */ _("span", {
|
|
104
123
|
className: "block font-medium text-text-primary",
|
|
105
124
|
children: "Source"
|
|
106
|
-
}), /* @__PURE__ */
|
|
107
|
-
value:
|
|
108
|
-
onValueChange:
|
|
109
|
-
children: [/* @__PURE__ */
|
|
125
|
+
}), /* @__PURE__ */ v(S, {
|
|
126
|
+
value: I,
|
|
127
|
+
onValueChange: L,
|
|
128
|
+
children: [/* @__PURE__ */ _(T, {
|
|
110
129
|
"aria-label": "Filter by source",
|
|
111
130
|
className: "w-48",
|
|
112
|
-
children: /* @__PURE__ */
|
|
113
|
-
}), /* @__PURE__ */
|
|
114
|
-
value:
|
|
131
|
+
children: /* @__PURE__ */ _(E, {})
|
|
132
|
+
}), /* @__PURE__ */ v(C, { children: [/* @__PURE__ */ _(w, {
|
|
133
|
+
value: A,
|
|
115
134
|
children: "All sources"
|
|
116
|
-
}),
|
|
135
|
+
}), ge.map((e) => /* @__PURE__ */ _(w, {
|
|
117
136
|
value: e.id,
|
|
118
137
|
children: e.name
|
|
119
138
|
}, e.id))] })]
|
|
120
139
|
})]
|
|
121
140
|
}),
|
|
122
|
-
/* @__PURE__ */
|
|
141
|
+
/* @__PURE__ */ v("label", {
|
|
123
142
|
className: "space-y-1 text-sm",
|
|
124
|
-
children: [/* @__PURE__ */
|
|
143
|
+
children: [/* @__PURE__ */ _("span", {
|
|
125
144
|
className: "block font-medium text-text-primary",
|
|
126
145
|
children: "Collection"
|
|
127
|
-
}), /* @__PURE__ */
|
|
128
|
-
value:
|
|
129
|
-
onValueChange:
|
|
130
|
-
children: [/* @__PURE__ */
|
|
146
|
+
}), /* @__PURE__ */ v(S, {
|
|
147
|
+
value: R,
|
|
148
|
+
onValueChange: z,
|
|
149
|
+
children: [/* @__PURE__ */ _(T, {
|
|
131
150
|
"aria-label": "Filter by collection",
|
|
132
151
|
className: "w-48",
|
|
133
|
-
children: /* @__PURE__ */
|
|
134
|
-
}), /* @__PURE__ */
|
|
135
|
-
value:
|
|
152
|
+
children: /* @__PURE__ */ _(E, {})
|
|
153
|
+
}), /* @__PURE__ */ v(C, { children: [/* @__PURE__ */ _(w, {
|
|
154
|
+
value: A,
|
|
136
155
|
children: "All collections"
|
|
137
|
-
}),
|
|
156
|
+
}), _e.map((e) => /* @__PURE__ */ _(w, {
|
|
138
157
|
value: e.id,
|
|
139
158
|
children: e.name
|
|
140
159
|
}, e.id))] })]
|
|
141
160
|
})]
|
|
161
|
+
}),
|
|
162
|
+
/* @__PURE__ */ v("label", {
|
|
163
|
+
className: "space-y-1 text-sm",
|
|
164
|
+
children: [/* @__PURE__ */ _("span", {
|
|
165
|
+
className: "block font-medium text-text-primary",
|
|
166
|
+
children: "Format"
|
|
167
|
+
}), /* @__PURE__ */ v(S, {
|
|
168
|
+
value: B,
|
|
169
|
+
onValueChange: V,
|
|
170
|
+
disabled: X.length === 0,
|
|
171
|
+
children: [/* @__PURE__ */ _(T, {
|
|
172
|
+
"aria-label": "Filter by format",
|
|
173
|
+
className: "w-40",
|
|
174
|
+
children: /* @__PURE__ */ _(E, {})
|
|
175
|
+
}), /* @__PURE__ */ v(C, { children: [/* @__PURE__ */ _(w, {
|
|
176
|
+
value: A,
|
|
177
|
+
children: "All formats"
|
|
178
|
+
}), X.map((e) => /* @__PURE__ */ _(w, {
|
|
179
|
+
value: e,
|
|
180
|
+
children: e
|
|
181
|
+
}, e))] })]
|
|
182
|
+
})]
|
|
183
|
+
}),
|
|
184
|
+
/* @__PURE__ */ v("label", {
|
|
185
|
+
className: "space-y-1 text-sm",
|
|
186
|
+
children: [/* @__PURE__ */ _("span", {
|
|
187
|
+
className: "block font-medium text-text-primary",
|
|
188
|
+
children: "Access"
|
|
189
|
+
}), /* @__PURE__ */ v(S, {
|
|
190
|
+
value: H,
|
|
191
|
+
onValueChange: U,
|
|
192
|
+
children: [/* @__PURE__ */ _(T, {
|
|
193
|
+
"aria-label": "Filter by access level",
|
|
194
|
+
className: "w-44",
|
|
195
|
+
children: /* @__PURE__ */ _(E, {})
|
|
196
|
+
}), /* @__PURE__ */ v(C, { children: [/* @__PURE__ */ _(w, {
|
|
197
|
+
value: A,
|
|
198
|
+
children: "All access levels"
|
|
199
|
+
}), ce.map((e) => /* @__PURE__ */ _(w, {
|
|
200
|
+
value: e,
|
|
201
|
+
children: p(e)
|
|
202
|
+
}, e))] })]
|
|
203
|
+
})]
|
|
142
204
|
})
|
|
143
205
|
]
|
|
144
|
-
}),
|
|
206
|
+
}), K ? /* @__PURE__ */ _(te, {
|
|
145
207
|
variant: "rows",
|
|
146
208
|
rows: 6,
|
|
147
209
|
label: "Loading datasets…"
|
|
148
|
-
}) :
|
|
210
|
+
}) : ue ? /* @__PURE__ */ _(c, {
|
|
149
211
|
message: "We could not load datasets. Please try again.",
|
|
150
|
-
onRetry: () => void
|
|
151
|
-
}) :
|
|
152
|
-
icon:
|
|
153
|
-
title:
|
|
154
|
-
description:
|
|
155
|
-
action:
|
|
212
|
+
onRetry: () => void q()
|
|
213
|
+
}) : Y.length === 0 ? /* @__PURE__ */ _(s, {
|
|
214
|
+
icon: re,
|
|
215
|
+
title: Z ? "No datasets yet." : "No datasets match these filters.",
|
|
216
|
+
description: Z ? "Register your first dataset to start federating science data across sources." : "Try a different status, source, collection, format or access level.",
|
|
217
|
+
action: Z ? /* @__PURE__ */ v(x, {
|
|
156
218
|
type: "button",
|
|
157
|
-
onClick: () =>
|
|
158
|
-
children: [/* @__PURE__ */
|
|
219
|
+
onClick: () => N("datasets/create"),
|
|
220
|
+
children: [/* @__PURE__ */ _(y, { className: "size-4" }), "New dataset"]
|
|
159
221
|
}) : void 0
|
|
160
|
-
}) : /* @__PURE__ */
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
/* @__PURE__ */ v(
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
/* @__PURE__ */ v(j, { children: "Tags" }),
|
|
172
|
-
/* @__PURE__ */ v(j, { children: "Updated" }),
|
|
173
|
-
/* @__PURE__ */ v(j, {
|
|
174
|
-
className: "text-right",
|
|
175
|
-
children: "Actions"
|
|
176
|
-
})
|
|
177
|
-
] }) }), /* @__PURE__ */ v(te, { children: Q.map((e) => /* @__PURE__ */ y(N, {
|
|
178
|
-
className: "cursor-pointer",
|
|
179
|
-
onClick: () => R(`datasets/${e.id}`),
|
|
180
|
-
children: [
|
|
181
|
-
/* @__PURE__ */ y(A, { children: [/* @__PURE__ */ v("span", {
|
|
182
|
-
className: "font-medium text-text-primary",
|
|
183
|
-
children: e.name
|
|
184
|
-
}), e.description ? /* @__PURE__ */ v("p", {
|
|
185
|
-
className: "mt-0.5 line-clamp-1 max-w-xs text-xs text-text-secondary",
|
|
186
|
-
children: e.description
|
|
187
|
-
}) : null] }),
|
|
188
|
-
/* @__PURE__ */ v(A, { children: /* @__PURE__ */ v(p, { status: e.status }) }),
|
|
189
|
-
/* @__PURE__ */ v(A, { children: /* @__PURE__ */ v("span", {
|
|
190
|
-
className: "text-sm text-text-secondary",
|
|
191
|
-
children: m(e.accessLevel)
|
|
192
|
-
}) }),
|
|
193
|
-
/* @__PURE__ */ v(A, { children: /* @__PURE__ */ v("span", {
|
|
194
|
-
className: "text-sm text-text-secondary",
|
|
195
|
-
children: e.format || "—"
|
|
196
|
-
}) }),
|
|
197
|
-
/* @__PURE__ */ v(A, {
|
|
198
|
-
className: "text-right text-sm tabular-nums text-text-secondary",
|
|
199
|
-
children: I(e.sizeBytes)
|
|
200
|
-
}),
|
|
201
|
-
/* @__PURE__ */ v(A, { children: /* @__PURE__ */ v("div", {
|
|
202
|
-
className: "flex max-w-[12rem] flex-wrap gap-1",
|
|
203
|
-
children: e.tags.length === 0 ? /* @__PURE__ */ v("span", {
|
|
204
|
-
className: "text-xs text-text-secondary",
|
|
205
|
-
children: "—"
|
|
206
|
-
}) : /* @__PURE__ */ y(_, { children: [e.tags.slice(0, 2).map((e) => /* @__PURE__ */ v(S, {
|
|
207
|
-
variant: "secondary",
|
|
208
|
-
children: e
|
|
209
|
-
}, e)), e.tags.length > 2 ? /* @__PURE__ */ y(S, {
|
|
210
|
-
variant: "secondary",
|
|
211
|
-
children: ["+", e.tags.length - 2]
|
|
212
|
-
}) : null] })
|
|
213
|
-
}) }),
|
|
214
|
-
/* @__PURE__ */ v(A, {
|
|
215
|
-
className: "whitespace-nowrap text-sm text-text-secondary",
|
|
216
|
-
children: L(e.updatedAt)
|
|
222
|
+
}) : /* @__PURE__ */ v(g, { children: [
|
|
223
|
+
/* @__PURE__ */ _("div", {
|
|
224
|
+
className: "hidden rounded-card border border-border-default bg-bg-elevated md:block",
|
|
225
|
+
children: /* @__PURE__ */ v(ie, { children: [/* @__PURE__ */ _(oe, { children: /* @__PURE__ */ v(k, { children: [
|
|
226
|
+
/* @__PURE__ */ _(O, { children: "Name" }),
|
|
227
|
+
/* @__PURE__ */ _(O, { children: "Status" }),
|
|
228
|
+
/* @__PURE__ */ _(O, { children: "Access" }),
|
|
229
|
+
/* @__PURE__ */ _(O, { children: "Format" }),
|
|
230
|
+
/* @__PURE__ */ _(O, {
|
|
231
|
+
className: "text-right",
|
|
232
|
+
children: "Size"
|
|
217
233
|
}),
|
|
218
|
-
/* @__PURE__ */
|
|
234
|
+
/* @__PURE__ */ _(O, { children: "Tags" }),
|
|
235
|
+
/* @__PURE__ */ _(O, { children: "Updated" }),
|
|
236
|
+
/* @__PURE__ */ _(O, {
|
|
219
237
|
className: "text-right",
|
|
220
|
-
children:
|
|
221
|
-
ariaLabel: `Actions for ${e.name}`,
|
|
222
|
-
entityName: e.name,
|
|
223
|
-
onView: () => R(`datasets/${e.id}`),
|
|
224
|
-
onEdit: () => R(`datasets/${e.id}/edit`),
|
|
225
|
-
extraItems: e.status === "AVAILABLE" || e.status === "ARCHIVED" ? [] : [{
|
|
226
|
-
key: "publish",
|
|
227
|
-
label: "Publish",
|
|
228
|
-
onSelect: () => void se(e)
|
|
229
|
-
}],
|
|
230
|
-
onDelete: () => ce(e),
|
|
231
|
-
deleteLabel: "Archive dataset"
|
|
232
|
-
})
|
|
238
|
+
children: "Actions"
|
|
233
239
|
})
|
|
234
|
-
]
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
240
|
+
] }) }), /* @__PURE__ */ _(ae, { children: Y.map((e) => /* @__PURE__ */ v(k, {
|
|
241
|
+
className: "cursor-pointer",
|
|
242
|
+
onClick: () => N(`datasets/${e.id}`),
|
|
243
|
+
children: [
|
|
244
|
+
/* @__PURE__ */ v(D, { children: [/* @__PURE__ */ _("span", {
|
|
245
|
+
className: "font-medium text-text-primary",
|
|
246
|
+
children: e.name
|
|
247
|
+
}), e.description ? /* @__PURE__ */ _("p", {
|
|
248
|
+
className: "mt-0.5 line-clamp-1 max-w-xs text-xs text-text-secondary",
|
|
249
|
+
children: e.description
|
|
250
|
+
}) : null] }),
|
|
251
|
+
/* @__PURE__ */ _(D, { children: /* @__PURE__ */ _(f, { status: e.status }) }),
|
|
252
|
+
/* @__PURE__ */ _(D, { children: /* @__PURE__ */ _("span", {
|
|
253
|
+
className: "text-sm text-text-secondary",
|
|
254
|
+
children: p(e.accessLevel)
|
|
255
|
+
}) }),
|
|
256
|
+
/* @__PURE__ */ _(D, { children: /* @__PURE__ */ _("span", {
|
|
257
|
+
className: "text-sm text-text-secondary",
|
|
258
|
+
children: e.format || "—"
|
|
259
|
+
}) }),
|
|
260
|
+
/* @__PURE__ */ _(D, {
|
|
261
|
+
className: "text-right text-sm tabular-nums text-text-secondary",
|
|
262
|
+
children: j(e.sizeBytes)
|
|
263
|
+
}),
|
|
264
|
+
/* @__PURE__ */ _(D, { children: /* @__PURE__ */ _("div", {
|
|
265
|
+
className: "flex max-w-[12rem] flex-wrap gap-1",
|
|
266
|
+
children: e.tags.length === 0 ? /* @__PURE__ */ _("span", {
|
|
267
|
+
className: "text-xs text-text-secondary",
|
|
268
|
+
children: "—"
|
|
269
|
+
}) : /* @__PURE__ */ v(g, { children: [e.tags.slice(0, 2).map((e) => /* @__PURE__ */ _(b, {
|
|
270
|
+
variant: "secondary",
|
|
271
|
+
children: e
|
|
272
|
+
}, e)), e.tags.length > 2 ? /* @__PURE__ */ v(b, {
|
|
273
|
+
variant: "secondary",
|
|
274
|
+
children: ["+", e.tags.length - 2]
|
|
275
|
+
}) : null] })
|
|
276
|
+
}) }),
|
|
277
|
+
/* @__PURE__ */ _(D, {
|
|
278
|
+
className: "whitespace-nowrap text-sm text-text-secondary",
|
|
279
|
+
children: M(e.updatedAt)
|
|
280
|
+
}),
|
|
281
|
+
/* @__PURE__ */ _(D, {
|
|
282
|
+
className: "text-right",
|
|
283
|
+
children: /* @__PURE__ */ _(o, {
|
|
284
|
+
ariaLabel: `Actions for ${e.name}`,
|
|
285
|
+
entityName: e.name,
|
|
286
|
+
onView: () => N(`datasets/${e.id}`),
|
|
287
|
+
onEdit: () => N(`datasets/${e.id}/edit`),
|
|
288
|
+
extraItems: e.status === "AVAILABLE" || e.status === "ARCHIVED" ? [] : [{
|
|
289
|
+
key: "publish",
|
|
290
|
+
label: "Publish",
|
|
291
|
+
onSelect: () => void Q(e)
|
|
292
|
+
}],
|
|
293
|
+
onDelete: () => $(e),
|
|
294
|
+
deleteLabel: "Archive dataset"
|
|
295
|
+
})
|
|
296
|
+
})
|
|
297
|
+
]
|
|
298
|
+
}, e.id)) })] })
|
|
299
|
+
}),
|
|
300
|
+
/* @__PURE__ */ _("ul", {
|
|
301
|
+
className: "space-y-3 md:hidden",
|
|
302
|
+
children: Y.map((e) => /* @__PURE__ */ _("li", { children: /* @__PURE__ */ v("div", {
|
|
303
|
+
role: "button",
|
|
304
|
+
tabIndex: 0,
|
|
305
|
+
"aria-label": `Open ${e.name}`,
|
|
306
|
+
onClick: () => N(`datasets/${e.id}`),
|
|
307
|
+
onKeyDown: (t) => {
|
|
308
|
+
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), N(`datasets/${e.id}`));
|
|
309
|
+
},
|
|
310
|
+
className: "flex flex-col gap-3 rounded-card border border-border-default bg-bg-elevated p-4 outline-none transition-colors hover:bg-bg-sunken focus-visible:ring-2 focus-visible:ring-border-focus",
|
|
311
|
+
children: [
|
|
312
|
+
/* @__PURE__ */ v("div", {
|
|
313
|
+
className: "flex items-start justify-between gap-3",
|
|
314
|
+
children: [/* @__PURE__ */ v("div", {
|
|
315
|
+
className: "min-w-0",
|
|
316
|
+
children: [/* @__PURE__ */ _("p", {
|
|
317
|
+
className: "font-medium text-text-primary",
|
|
318
|
+
children: e.name
|
|
319
|
+
}), e.description ? /* @__PURE__ */ _("p", {
|
|
320
|
+
className: "mt-0.5 line-clamp-2 text-xs text-text-secondary",
|
|
321
|
+
children: e.description
|
|
322
|
+
}) : null]
|
|
323
|
+
}), /* @__PURE__ */ _("div", {
|
|
324
|
+
onClick: (e) => e.stopPropagation(),
|
|
325
|
+
children: /* @__PURE__ */ _(o, {
|
|
326
|
+
ariaLabel: `Actions for ${e.name}`,
|
|
327
|
+
entityName: e.name,
|
|
328
|
+
onView: () => N(`datasets/${e.id}`),
|
|
329
|
+
onEdit: () => N(`datasets/${e.id}/edit`),
|
|
330
|
+
extraItems: e.status === "AVAILABLE" || e.status === "ARCHIVED" ? [] : [{
|
|
331
|
+
key: "publish",
|
|
332
|
+
label: "Publish",
|
|
333
|
+
onSelect: () => void Q(e)
|
|
334
|
+
}],
|
|
335
|
+
onDelete: () => $(e),
|
|
336
|
+
deleteLabel: "Archive dataset"
|
|
337
|
+
})
|
|
338
|
+
})]
|
|
339
|
+
}),
|
|
340
|
+
/* @__PURE__ */ v("div", {
|
|
341
|
+
className: "flex flex-wrap items-center gap-1.5",
|
|
342
|
+
children: [/* @__PURE__ */ _(f, { status: e.status }), /* @__PURE__ */ _(f, { status: e.accessLevel })]
|
|
343
|
+
}),
|
|
344
|
+
/* @__PURE__ */ v("dl", {
|
|
345
|
+
className: "grid grid-cols-2 gap-x-4 gap-y-1 text-xs",
|
|
346
|
+
children: [
|
|
347
|
+
/* @__PURE__ */ v("div", {
|
|
348
|
+
className: "flex justify-between gap-2",
|
|
349
|
+
children: [/* @__PURE__ */ _("dt", {
|
|
350
|
+
className: "text-text-secondary",
|
|
351
|
+
children: "Format"
|
|
352
|
+
}), /* @__PURE__ */ _("dd", {
|
|
353
|
+
className: "text-text-primary",
|
|
354
|
+
children: e.format || "—"
|
|
355
|
+
})]
|
|
356
|
+
}),
|
|
357
|
+
/* @__PURE__ */ v("div", {
|
|
358
|
+
className: "flex justify-between gap-2",
|
|
359
|
+
children: [/* @__PURE__ */ _("dt", {
|
|
360
|
+
className: "text-text-secondary",
|
|
361
|
+
children: "Size"
|
|
362
|
+
}), /* @__PURE__ */ _("dd", {
|
|
363
|
+
className: "tabular-nums text-text-primary",
|
|
364
|
+
children: j(e.sizeBytes)
|
|
365
|
+
})]
|
|
366
|
+
}),
|
|
367
|
+
/* @__PURE__ */ v("div", {
|
|
368
|
+
className: "flex justify-between gap-2",
|
|
369
|
+
children: [/* @__PURE__ */ _("dt", {
|
|
370
|
+
className: "text-text-secondary",
|
|
371
|
+
children: "Updated"
|
|
372
|
+
}), /* @__PURE__ */ _("dd", {
|
|
373
|
+
className: "text-text-primary",
|
|
374
|
+
children: M(e.updatedAt)
|
|
375
|
+
})]
|
|
376
|
+
})
|
|
377
|
+
]
|
|
378
|
+
}),
|
|
379
|
+
e.tags.length > 0 ? /* @__PURE__ */ v("div", {
|
|
380
|
+
className: "flex flex-wrap gap-1",
|
|
381
|
+
children: [e.tags.slice(0, 4).map((e) => /* @__PURE__ */ _(b, {
|
|
382
|
+
variant: "secondary",
|
|
383
|
+
className: "text-xs",
|
|
384
|
+
children: e
|
|
385
|
+
}, e)), e.tags.length > 4 ? /* @__PURE__ */ v("span", {
|
|
386
|
+
className: "text-xs text-text-secondary",
|
|
387
|
+
children: ["+", e.tags.length - 4]
|
|
388
|
+
}) : null]
|
|
389
|
+
}) : null
|
|
390
|
+
]
|
|
391
|
+
}) }, e.id))
|
|
392
|
+
}),
|
|
393
|
+
/* @__PURE__ */ _(u, {
|
|
394
|
+
offset: W.offset,
|
|
395
|
+
limit: W.limit,
|
|
396
|
+
loadedCount: Y.length,
|
|
397
|
+
hasMore: !!he?.hasMore,
|
|
398
|
+
onPrev: W.prevPage,
|
|
399
|
+
onNext: W.nextPage,
|
|
400
|
+
itemLabel: "datasets",
|
|
401
|
+
loading: K
|
|
402
|
+
})
|
|
403
|
+
] })]
|
|
246
404
|
})
|
|
247
405
|
});
|
|
248
406
|
}
|
|
249
407
|
//#endregion
|
|
250
|
-
export {
|
|
408
|
+
export { N as default };
|
|
251
409
|
|
|
252
410
|
//# sourceMappingURL=DatasetsPage.js.map
|