@burdenoff/microfe-cosmicintersection 2026.827.1 → 2026.830.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/components/ActionMenu.d.ts +1 -1
- package/dist/cosmicintersection/components/ActionMenu.d.ts.map +1 -1
- package/dist/cosmicintersection/components/ActionMenu.js +51 -54
- package/dist/cosmicintersection/components/ActionMenu.js.map +1 -1
- package/dist/cosmicintersection/components/EntityFormShell.d.ts +1 -1
- package/dist/cosmicintersection/components/EntityFormShell.d.ts.map +1 -1
- package/dist/cosmicintersection/components/EntityFormShell.js +29 -27
- package/dist/cosmicintersection/components/EntityFormShell.js.map +1 -1
- package/dist/cosmicintersection/components/ErrorState.d.ts +1 -1
- package/dist/cosmicintersection/components/ErrorState.d.ts.map +1 -1
- package/dist/cosmicintersection/components/ErrorState.js +19 -17
- package/dist/cosmicintersection/components/ErrorState.js.map +1 -1
- package/dist/cosmicintersection/components/FileUploadField.d.ts.map +1 -1
- package/dist/cosmicintersection/components/FileUploadField.js +61 -60
- package/dist/cosmicintersection/components/FileUploadField.js.map +1 -1
- package/dist/cosmicintersection/components/LoadingState.d.ts +1 -1
- package/dist/cosmicintersection/components/LoadingState.d.ts.map +1 -1
- package/dist/cosmicintersection/components/LoadingState.js +15 -13
- package/dist/cosmicintersection/components/LoadingState.js.map +1 -1
- package/dist/cosmicintersection/components/PageLayout.d.ts.map +1 -1
- package/dist/cosmicintersection/components/PageLayout.js +28 -27
- package/dist/cosmicintersection/components/PageLayout.js.map +1 -1
- package/dist/cosmicintersection/components/Pagination.d.ts.map +1 -1
- package/dist/cosmicintersection/components/Pagination.js +38 -35
- package/dist/cosmicintersection/components/Pagination.js.map +1 -1
- package/dist/cosmicintersection/components/StatusBadge.d.ts.map +1 -1
- package/dist/cosmicintersection/components/StatusBadge.js +30 -9
- package/dist/cosmicintersection/components/StatusBadge.js.map +1 -1
- package/dist/cosmicintersection/pages/access/AccessPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/access/AccessPage.js +147 -146
- package/dist/cosmicintersection/pages/access/AccessPage.js.map +1 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js +260 -259
- package/dist/cosmicintersection/pages/analyses/AnalysesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js +63 -62
- package/dist/cosmicintersection/pages/collections/CollectionsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js +132 -131
- package/dist/cosmicintersection/pages/dashboard/DashboardPage.js.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js +178 -177
- package/dist/cosmicintersection/pages/datasets/DatasetsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js +138 -145
- package/dist/cosmicintersection/pages/discovery/DiscoveryPage.js.map +1 -1
- package/dist/cosmicintersection/pages/lineage/LineagePage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/lineage/LineagePage.js +78 -88
- package/dist/cosmicintersection/pages/lineage/LineagePage.js.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js +125 -124
- package/dist/cosmicintersection/pages/notebooks/NotebooksPage.js.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js +152 -151
- package/dist/cosmicintersection/pages/pipelines/PipelinesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js +175 -174
- package/dist/cosmicintersection/pages/releases/ReleasesPage.js.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/runs/RunsPage.js +197 -188
- package/dist/cosmicintersection/pages/runs/RunsPage.js.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourcesPage.d.ts.map +1 -1
- package/dist/cosmicintersection/pages/sources/SourcesPage.js +65 -64
- package/dist/cosmicintersection/pages/sources/SourcesPage.js.map +1 -1
- package/dist/dev/main.d.ts.map +1 -1
- package/dist/shared/hooks/useTr.d.ts +12 -0
- package/dist/shared/hooks/useTr.d.ts.map +1 -0
- package/dist/shared/hooks/useTr.js +16 -0
- package/dist/shared/hooks/useTr.js.map +1 -0
- package/package.json +1 -1
|
@@ -1,31 +1,32 @@
|
|
|
1
1
|
import { useCosmicIntersection as e } from "../../context/CosmicIntersectionContext.js";
|
|
2
2
|
import { notify as t } from "../../lib/toast.js";
|
|
3
|
-
import { useCosDatasetsQuery as ee, useCosNotebooksQuery as
|
|
4
|
-
import
|
|
3
|
+
import { useCosDatasetsQuery as ee, useCosNotebooksQuery as te, useCosPublishReleaseMutation as n, useCosReleasesQuery as r } from "../../api/cosmicApi.js";
|
|
4
|
+
import { useTr as ne } from "../../../shared/hooks/useTr.js";
|
|
5
|
+
import i from "../../components/ActionMenu.js";
|
|
5
6
|
import re from "../../components/EmptyState.js";
|
|
6
7
|
import ie from "../../components/ErrorState.js";
|
|
7
8
|
import ae from "../../components/LoadingState.js";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
9
|
+
import a from "../../components/SafeLink.js";
|
|
10
|
+
import oe from "../../components/DiscussionPanel.js";
|
|
11
|
+
import se from "../../components/PageLayout.js";
|
|
12
|
+
import o, { usePagination as s } from "../../components/Pagination.js";
|
|
13
|
+
import c, { formatEnumLabel as ce } from "../../components/StatusBadge.js";
|
|
13
14
|
import "../../components/index.js";
|
|
14
|
-
import { useMemo as
|
|
15
|
-
import { Fragment as
|
|
16
|
-
import { BookOpen as
|
|
17
|
-
import { Button as g, Dialog as _, DialogClose as
|
|
15
|
+
import { useMemo as l, useState as u } from "react";
|
|
16
|
+
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
17
|
+
import { BookOpen as le, Database as ue, ExternalLink as m, NotebookPen as de, Plus as fe, Rocket as h } from "lucide-react";
|
|
18
|
+
import { Button as g, Dialog as _, DialogClose as pe, DialogContent as v, DialogDescription as y, DialogFooter as b, DialogHeader as x, DialogTitle as S, Input as me, Label as he, Select as ge, SelectContent as _e, SelectItem as C, SelectTrigger as ve, SelectValue as ye, Table as be, TableBody as xe, TableCell as w, TableHead as T, TableHeader as Se, TableRow as E } from "@burdenoff/fe-libs/ui";
|
|
18
19
|
//#region src/cosmicintersection/pages/releases/ReleasesPage.tsx
|
|
19
|
-
var
|
|
20
|
+
var D = "ALL", O = [
|
|
20
21
|
"DRAFT",
|
|
21
22
|
"UNDER_REVIEW",
|
|
22
23
|
"PUBLISHED",
|
|
23
24
|
"RETRACTED"
|
|
24
25
|
];
|
|
25
|
-
function
|
|
26
|
+
function k(e) {
|
|
26
27
|
return e === "DRAFT" || e === "UNDER_REVIEW";
|
|
27
28
|
}
|
|
28
|
-
function
|
|
29
|
+
function A(e) {
|
|
29
30
|
if (!e) return "—";
|
|
30
31
|
let t = new Date(e);
|
|
31
32
|
return Number.isNaN(t.getTime()) ? "—" : t.toLocaleDateString(void 0, {
|
|
@@ -34,166 +35,166 @@ function j(e) {
|
|
|
34
35
|
day: "numeric"
|
|
35
36
|
});
|
|
36
37
|
}
|
|
37
|
-
function
|
|
38
|
+
function j(e) {
|
|
38
39
|
let t = e.trim();
|
|
39
40
|
return /^https?:\/\//i.test(t) ? t : `https://doi.org/${t.replace(/^doi:/i, "")}`;
|
|
40
41
|
}
|
|
41
|
-
function
|
|
42
|
-
let { navigate:
|
|
42
|
+
function M() {
|
|
43
|
+
let { navigate: M } = e(), N = ne(), [P, Ce] = u(D), F = s({
|
|
43
44
|
pageSize: 20,
|
|
44
45
|
resetKey: P
|
|
45
|
-
}), { data: I, loading: L, error: R, refetch: z } =
|
|
46
|
-
status: P ===
|
|
46
|
+
}), { data: I, loading: L, error: R, refetch: z } = r({
|
|
47
|
+
status: P === D ? void 0 : P,
|
|
47
48
|
pagination: {
|
|
48
49
|
limit: F.limit,
|
|
49
50
|
offset: F.offset
|
|
50
51
|
}
|
|
51
|
-
}), [
|
|
52
|
+
}), [we, { loading: B }] = n(), V = l(() => I?.cosListReleases.items ?? [], [I]), Te = I?.cosListReleases.pageInfo, H = ee({ pagination: {
|
|
52
53
|
limit: 100,
|
|
53
54
|
offset: 0
|
|
54
|
-
} }), U =
|
|
55
|
+
} }), U = te({ pagination: {
|
|
55
56
|
limit: 100,
|
|
56
57
|
offset: 0
|
|
57
|
-
} }),
|
|
58
|
+
} }), Ee = l(() => {
|
|
58
59
|
let e = /* @__PURE__ */ new Map();
|
|
59
60
|
for (let t of H.data?.cosListDatasets.items ?? []) e.set(t.id, t.name);
|
|
60
61
|
return e;
|
|
61
|
-
}, [H.data]), W =
|
|
62
|
+
}, [H.data]), W = l(() => {
|
|
62
63
|
let e = /* @__PURE__ */ new Map();
|
|
63
64
|
for (let t of U.data?.cosListNotebooks.items ?? []) e.set(t.id, t.title);
|
|
64
65
|
return e;
|
|
65
|
-
}, [U.data]), [G, K] =
|
|
66
|
-
K(null),
|
|
67
|
-
}, [J, Y] =
|
|
66
|
+
}, [U.data]), [G, K] = u(null), q = (e) => {
|
|
67
|
+
K(null), M(e);
|
|
68
|
+
}, [J, Y] = u(null), [X, Z] = u(""), Q = (e) => {
|
|
68
69
|
Z(e.doi ?? ""), Y(e);
|
|
69
|
-
},
|
|
70
|
+
}, De = async () => {
|
|
70
71
|
if (!J) return;
|
|
71
72
|
let e = X.trim();
|
|
72
|
-
(await
|
|
73
|
+
(await we({ variables: {
|
|
73
74
|
id: J.id,
|
|
74
75
|
doi: e || void 0
|
|
75
|
-
} })).data?.cosPublishRelease?.id && (t.success("Release published",
|
|
76
|
-
}, $ = /* @__PURE__ */
|
|
76
|
+
} })).data?.cosPublishRelease?.id && (t.success(N("cosmicintersection.pages.releases.publishSuccess", "Release published"), N("cosmicintersection.pages.releases.publishSuccessDescription", "“{{name}}” is now public.", { name: J.title })), Y(null), Z(""), await z());
|
|
77
|
+
}, $ = /* @__PURE__ */ p(g, {
|
|
77
78
|
type: "button",
|
|
78
|
-
onClick: () =>
|
|
79
|
-
children: [/* @__PURE__ */
|
|
79
|
+
onClick: () => M("releases/create"),
|
|
80
|
+
children: [/* @__PURE__ */ f(fe, { className: "size-4" }), N("cosmicintersection.pages.releases.create", "New release")]
|
|
80
81
|
});
|
|
81
|
-
return /* @__PURE__ */
|
|
82
|
-
title: "Releases",
|
|
83
|
-
description: "Citable, versioned publications that bundle datasets and notebooks for the community.",
|
|
82
|
+
return /* @__PURE__ */ p(se, {
|
|
83
|
+
title: N("cosmicintersection.pages.releases.title", "Releases"),
|
|
84
|
+
description: N("cosmicintersection.pages.releases.description", "Citable, versioned publications that bundle datasets and notebooks for the community."),
|
|
84
85
|
actions: $,
|
|
85
86
|
children: [
|
|
86
|
-
/* @__PURE__ */
|
|
87
|
+
/* @__PURE__ */ p("div", {
|
|
87
88
|
className: "space-y-4",
|
|
88
|
-
children: [/* @__PURE__ */
|
|
89
|
+
children: [/* @__PURE__ */ f("div", {
|
|
89
90
|
className: "flex flex-wrap items-center gap-3",
|
|
90
|
-
children: /* @__PURE__ */
|
|
91
|
+
children: /* @__PURE__ */ f("div", {
|
|
91
92
|
className: "w-full max-w-[14rem]",
|
|
92
|
-
children: /* @__PURE__ */
|
|
93
|
+
children: /* @__PURE__ */ p(ge, {
|
|
93
94
|
value: P,
|
|
94
|
-
onValueChange:
|
|
95
|
-
children: [/* @__PURE__ */
|
|
95
|
+
onValueChange: Ce,
|
|
96
|
+
children: [/* @__PURE__ */ f(ve, {
|
|
96
97
|
"aria-label": "Filter by status",
|
|
97
|
-
children: /* @__PURE__ */
|
|
98
|
-
}), /* @__PURE__ */
|
|
99
|
-
value:
|
|
98
|
+
children: /* @__PURE__ */ f(ye, { placeholder: "All statuses" })
|
|
99
|
+
}), /* @__PURE__ */ p(_e, { children: [/* @__PURE__ */ f(C, {
|
|
100
|
+
value: D,
|
|
100
101
|
children: "All statuses"
|
|
101
|
-
}),
|
|
102
|
+
}), O.map((e) => /* @__PURE__ */ f(C, {
|
|
102
103
|
value: e,
|
|
103
|
-
children:
|
|
104
|
+
children: ce(e)
|
|
104
105
|
}, e))] })]
|
|
105
106
|
})
|
|
106
107
|
})
|
|
107
108
|
}), (() => {
|
|
108
|
-
if (L) return /* @__PURE__ */
|
|
109
|
+
if (L) return /* @__PURE__ */ f(ae, {
|
|
109
110
|
variant: "rows",
|
|
110
111
|
rows: 6,
|
|
111
|
-
label: "Loading releases…"
|
|
112
|
+
label: N("cosmicintersection.pages.releases.loading", "Loading releases…")
|
|
112
113
|
});
|
|
113
|
-
if (R) return /* @__PURE__ */
|
|
114
|
+
if (R) return /* @__PURE__ */ f(ie, {
|
|
114
115
|
message: R.message,
|
|
115
116
|
onRetry: () => void z()
|
|
116
117
|
});
|
|
117
118
|
if (V.length === 0) {
|
|
118
|
-
let e = P !==
|
|
119
|
-
return /* @__PURE__ */
|
|
119
|
+
let e = P !== D;
|
|
120
|
+
return /* @__PURE__ */ f(re, {
|
|
120
121
|
icon: h,
|
|
121
|
-
title: e ? "No releases match this filter" : "No releases yet",
|
|
122
|
-
description: e ? "Try clearing the status filter to see more releases." : "Package datasets and notebooks into a citable, versioned release for publication.",
|
|
122
|
+
title: e ? N("cosmicintersection.pages.releases.emptyFilterTitle", "No releases match this filter") : N("cosmicintersection.pages.releases.emptyTitle", "No releases yet"),
|
|
123
|
+
description: e ? N("cosmicintersection.pages.releases.emptyFilterDescription", "Try clearing the status filter to see more releases.") : N("cosmicintersection.pages.releases.emptyDescription", "Package datasets and notebooks into a citable, versioned release for publication."),
|
|
123
124
|
action: e ? void 0 : $
|
|
124
125
|
});
|
|
125
126
|
}
|
|
126
|
-
return /* @__PURE__ */ d
|
|
127
|
-
/* @__PURE__ */
|
|
127
|
+
return /* @__PURE__ */ p(d, { children: [
|
|
128
|
+
/* @__PURE__ */ f("div", {
|
|
128
129
|
className: "hidden rounded-card border border-border-default bg-bg-elevated md:block",
|
|
129
|
-
children: /* @__PURE__ */
|
|
130
|
-
/* @__PURE__ */
|
|
131
|
-
/* @__PURE__ */
|
|
132
|
-
/* @__PURE__ */
|
|
133
|
-
/* @__PURE__ */
|
|
134
|
-
/* @__PURE__ */
|
|
135
|
-
/* @__PURE__ */
|
|
136
|
-
/* @__PURE__ */
|
|
137
|
-
/* @__PURE__ */
|
|
130
|
+
children: /* @__PURE__ */ p(be, { children: [/* @__PURE__ */ f(Se, { children: /* @__PURE__ */ p(E, { children: [
|
|
131
|
+
/* @__PURE__ */ f(T, { children: "Title" }),
|
|
132
|
+
/* @__PURE__ */ f(T, { children: "Version" }),
|
|
133
|
+
/* @__PURE__ */ f(T, { children: "Status" }),
|
|
134
|
+
/* @__PURE__ */ f(T, { children: "DOI" }),
|
|
135
|
+
/* @__PURE__ */ f(T, { children: "Authors" }),
|
|
136
|
+
/* @__PURE__ */ f(T, { children: "Published" }),
|
|
137
|
+
/* @__PURE__ */ f(T, { children: "License" }),
|
|
138
|
+
/* @__PURE__ */ f(T, {
|
|
138
139
|
className: "text-right",
|
|
139
140
|
children: "Actions"
|
|
140
141
|
})
|
|
141
|
-
] }) }), /* @__PURE__ */
|
|
142
|
-
/* @__PURE__ */
|
|
142
|
+
] }) }), /* @__PURE__ */ f(xe, { children: V.map((e) => /* @__PURE__ */ p(E, { children: [
|
|
143
|
+
/* @__PURE__ */ f(w, { children: /* @__PURE__ */ f("button", {
|
|
143
144
|
type: "button",
|
|
144
145
|
onClick: () => K(e),
|
|
145
146
|
className: "text-left font-medium text-text-primary underline-offset-2 hover:underline focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-border-focus",
|
|
146
147
|
children: e.title
|
|
147
148
|
}) }),
|
|
148
|
-
/* @__PURE__ */
|
|
149
|
+
/* @__PURE__ */ f(w, {
|
|
149
150
|
className: "whitespace-nowrap text-sm text-text-secondary",
|
|
150
151
|
children: e.version || "—"
|
|
151
152
|
}),
|
|
152
|
-
/* @__PURE__ */
|
|
153
|
-
/* @__PURE__ */
|
|
153
|
+
/* @__PURE__ */ f(w, { children: /* @__PURE__ */ f(c, { status: e.status }) }),
|
|
154
|
+
/* @__PURE__ */ f(w, {
|
|
154
155
|
className: "max-w-[14rem]",
|
|
155
|
-
children: e.doi ? /* @__PURE__ */
|
|
156
|
-
href:
|
|
156
|
+
children: e.doi ? /* @__PURE__ */ p(a, {
|
|
157
|
+
href: j(e.doi),
|
|
157
158
|
className: "inline-flex items-center gap-1 truncate text-sm text-text-primary underline-offset-2 hover:underline",
|
|
158
159
|
fallbackClassName: "block truncate text-sm text-text-secondary",
|
|
159
|
-
children: [/* @__PURE__ */
|
|
160
|
+
children: [/* @__PURE__ */ f("span", {
|
|
160
161
|
className: "truncate",
|
|
161
162
|
children: e.doi
|
|
162
|
-
}), /* @__PURE__ */
|
|
163
|
+
}), /* @__PURE__ */ f(m, {
|
|
163
164
|
className: "size-3.5 shrink-0",
|
|
164
165
|
"aria-hidden": "true"
|
|
165
166
|
})]
|
|
166
|
-
}) : /* @__PURE__ */
|
|
167
|
+
}) : /* @__PURE__ */ f("span", {
|
|
167
168
|
className: "text-sm text-text-secondary",
|
|
168
169
|
children: "—"
|
|
169
170
|
})
|
|
170
171
|
}),
|
|
171
|
-
/* @__PURE__ */
|
|
172
|
+
/* @__PURE__ */ f(w, {
|
|
172
173
|
className: "max-w-[14rem]",
|
|
173
|
-
children: e.authors.length === 0 ? /* @__PURE__ */
|
|
174
|
+
children: e.authors.length === 0 ? /* @__PURE__ */ f("span", {
|
|
174
175
|
className: "text-sm text-text-secondary",
|
|
175
176
|
children: "—"
|
|
176
|
-
}) : /* @__PURE__ */
|
|
177
|
+
}) : /* @__PURE__ */ f("span", {
|
|
177
178
|
className: "line-clamp-1 text-sm text-text-secondary",
|
|
178
179
|
children: e.authors.join(", ")
|
|
179
180
|
})
|
|
180
181
|
}),
|
|
181
|
-
/* @__PURE__ */
|
|
182
|
+
/* @__PURE__ */ f(w, {
|
|
182
183
|
className: "whitespace-nowrap text-sm text-text-secondary",
|
|
183
|
-
children:
|
|
184
|
+
children: A(e.publishedAt)
|
|
184
185
|
}),
|
|
185
|
-
/* @__PURE__ */
|
|
186
|
+
/* @__PURE__ */ f(w, {
|
|
186
187
|
className: "whitespace-nowrap text-sm text-text-secondary",
|
|
187
188
|
children: e.license || "—"
|
|
188
189
|
}),
|
|
189
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ f(w, {
|
|
190
191
|
className: "text-right",
|
|
191
|
-
children: /* @__PURE__ */
|
|
192
|
+
children: /* @__PURE__ */ f(i, {
|
|
192
193
|
ariaLabel: `Actions for ${e.title}`,
|
|
193
194
|
onView: () => K(e),
|
|
194
|
-
extraItems:
|
|
195
|
+
extraItems: k(e.status) ? [{
|
|
195
196
|
key: "publish",
|
|
196
|
-
label: "Publish",
|
|
197
|
+
label: N("cosmicintersection.pages.releases.publish", "Publish"),
|
|
197
198
|
icon: h,
|
|
198
199
|
onSelect: () => Q(e)
|
|
199
200
|
}] : []
|
|
@@ -201,55 +202,55 @@ function N() {
|
|
|
201
202
|
})
|
|
202
203
|
] }, e.id)) })] })
|
|
203
204
|
}),
|
|
204
|
-
/* @__PURE__ */
|
|
205
|
+
/* @__PURE__ */ f("ul", {
|
|
205
206
|
className: "space-y-3 md:hidden",
|
|
206
|
-
children: V.map((e) => /* @__PURE__ */
|
|
207
|
+
children: V.map((e) => /* @__PURE__ */ f("li", {
|
|
207
208
|
className: "rounded-card border border-border-default bg-bg-elevated",
|
|
208
|
-
children: /* @__PURE__ */
|
|
209
|
+
children: /* @__PURE__ */ p("div", {
|
|
209
210
|
className: "flex items-start justify-between gap-2 p-4",
|
|
210
|
-
children: [/* @__PURE__ */
|
|
211
|
+
children: [/* @__PURE__ */ p("div", {
|
|
211
212
|
className: "min-w-0 flex-1 space-y-2",
|
|
212
213
|
children: [
|
|
213
|
-
/* @__PURE__ */
|
|
214
|
+
/* @__PURE__ */ p("div", {
|
|
214
215
|
className: "flex flex-wrap items-center gap-2",
|
|
215
|
-
children: [/* @__PURE__ */
|
|
216
|
+
children: [/* @__PURE__ */ f("button", {
|
|
216
217
|
type: "button",
|
|
217
218
|
onClick: () => K(e),
|
|
218
219
|
className: "truncate text-left font-medium text-text-primary underline-offset-2 hover:underline",
|
|
219
220
|
children: e.title
|
|
220
|
-
}), /* @__PURE__ */
|
|
221
|
+
}), /* @__PURE__ */ f(c, { status: e.status })]
|
|
221
222
|
}),
|
|
222
|
-
/* @__PURE__ */
|
|
223
|
+
/* @__PURE__ */ p("div", {
|
|
223
224
|
className: "flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-text-secondary",
|
|
224
225
|
children: [
|
|
225
|
-
/* @__PURE__ */
|
|
226
|
-
e.license ? /* @__PURE__ */
|
|
227
|
-
/* @__PURE__ */
|
|
226
|
+
/* @__PURE__ */ f("span", { children: e.version || "v—" }),
|
|
227
|
+
e.license ? /* @__PURE__ */ f("span", { children: e.license }) : null,
|
|
228
|
+
/* @__PURE__ */ f("span", { children: A(e.publishedAt) })
|
|
228
229
|
]
|
|
229
230
|
}),
|
|
230
|
-
e.authors.length > 0 ? /* @__PURE__ */
|
|
231
|
+
e.authors.length > 0 ? /* @__PURE__ */ f("p", {
|
|
231
232
|
className: "line-clamp-1 text-xs text-text-secondary",
|
|
232
233
|
children: e.authors.join(", ")
|
|
233
234
|
}) : null,
|
|
234
|
-
e.doi ? /* @__PURE__ */
|
|
235
|
-
href:
|
|
235
|
+
e.doi ? /* @__PURE__ */ p(a, {
|
|
236
|
+
href: j(e.doi),
|
|
236
237
|
className: "inline-flex items-center gap-1 text-xs text-text-primary underline-offset-2 hover:underline",
|
|
237
238
|
fallbackClassName: "block truncate text-xs text-text-secondary",
|
|
238
|
-
children: [/* @__PURE__ */
|
|
239
|
+
children: [/* @__PURE__ */ p("span", {
|
|
239
240
|
className: "truncate",
|
|
240
241
|
children: ["DOI: ", e.doi]
|
|
241
|
-
}), /* @__PURE__ */
|
|
242
|
+
}), /* @__PURE__ */ f(m, {
|
|
242
243
|
className: "size-3 shrink-0",
|
|
243
244
|
"aria-hidden": "true"
|
|
244
245
|
})]
|
|
245
246
|
}) : null
|
|
246
247
|
]
|
|
247
|
-
}), /* @__PURE__ */
|
|
248
|
+
}), /* @__PURE__ */ f(i, {
|
|
248
249
|
ariaLabel: `Actions for ${e.title}`,
|
|
249
250
|
onView: () => K(e),
|
|
250
|
-
extraItems:
|
|
251
|
+
extraItems: k(e.status) ? [{
|
|
251
252
|
key: "publish",
|
|
252
|
-
label: "Publish",
|
|
253
|
+
label: N("cosmicintersection.pages.releases.publish", "Publish"),
|
|
253
254
|
icon: h,
|
|
254
255
|
onSelect: () => Q(e)
|
|
255
256
|
}] : []
|
|
@@ -257,150 +258,150 @@ function N() {
|
|
|
257
258
|
})
|
|
258
259
|
}, e.id))
|
|
259
260
|
}),
|
|
260
|
-
/* @__PURE__ */
|
|
261
|
+
/* @__PURE__ */ f(o, {
|
|
261
262
|
offset: F.offset,
|
|
262
263
|
limit: F.limit,
|
|
263
264
|
loadedCount: V.length,
|
|
264
|
-
hasMore:
|
|
265
|
+
hasMore: Te?.hasMore ?? !1,
|
|
265
266
|
onPrev: F.prevPage,
|
|
266
267
|
onNext: F.nextPage,
|
|
267
|
-
itemLabel: "releases",
|
|
268
|
+
itemLabel: N("cosmicintersection.pages.releases.itemLabel", "releases"),
|
|
268
269
|
loading: L
|
|
269
270
|
})
|
|
270
271
|
] });
|
|
271
272
|
})()]
|
|
272
273
|
}),
|
|
273
|
-
/* @__PURE__ */
|
|
274
|
+
/* @__PURE__ */ f(_, {
|
|
274
275
|
open: G !== null,
|
|
275
276
|
onOpenChange: (e) => e ? void 0 : K(null),
|
|
276
|
-
children: /* @__PURE__ */
|
|
277
|
+
children: /* @__PURE__ */ f(v, {
|
|
277
278
|
className: "max-h-[85vh] max-w-lg overflow-y-auto",
|
|
278
|
-
children: G ? /* @__PURE__ */ d
|
|
279
|
-
/* @__PURE__ */
|
|
279
|
+
children: G ? /* @__PURE__ */ p(d, { children: [
|
|
280
|
+
/* @__PURE__ */ p(x, { children: [/* @__PURE__ */ p(S, {
|
|
280
281
|
className: "flex items-center gap-2",
|
|
281
|
-
children: [/* @__PURE__ */
|
|
282
|
+
children: [/* @__PURE__ */ f(le, {
|
|
282
283
|
className: "size-5 text-text-secondary",
|
|
283
284
|
"aria-hidden": "true"
|
|
284
285
|
}), G.title]
|
|
285
|
-
}), /* @__PURE__ */
|
|
286
|
+
}), /* @__PURE__ */ p(y, { children: [
|
|
286
287
|
"Version ",
|
|
287
288
|
G.version || "—",
|
|
288
289
|
" · ",
|
|
289
|
-
/* @__PURE__ */
|
|
290
|
+
/* @__PURE__ */ f(c, { status: G.status })
|
|
290
291
|
] })] }),
|
|
291
|
-
/* @__PURE__ */
|
|
292
|
+
/* @__PURE__ */ p("div", {
|
|
292
293
|
className: "space-y-4 text-sm",
|
|
293
294
|
children: [
|
|
294
|
-
/* @__PURE__ */
|
|
295
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
295
296
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
296
297
|
children: "Abstract"
|
|
297
|
-
}), /* @__PURE__ */
|
|
298
|
+
}), /* @__PURE__ */ f("p", {
|
|
298
299
|
className: "mt-1 whitespace-pre-wrap text-text-primary",
|
|
299
300
|
children: G.abstract?.trim() || "No abstract provided."
|
|
300
301
|
})] }),
|
|
301
|
-
/* @__PURE__ */
|
|
302
|
+
/* @__PURE__ */ p("div", {
|
|
302
303
|
className: "grid grid-cols-2 gap-4",
|
|
303
304
|
children: [
|
|
304
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
305
306
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
306
307
|
children: "Authors"
|
|
307
|
-
}), /* @__PURE__ */
|
|
308
|
+
}), /* @__PURE__ */ f("p", {
|
|
308
309
|
className: "mt-1 text-text-primary",
|
|
309
310
|
children: G.authors.length ? G.authors.join(", ") : "—"
|
|
310
311
|
})] }),
|
|
311
|
-
/* @__PURE__ */
|
|
312
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
312
313
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
313
314
|
children: "License"
|
|
314
|
-
}), /* @__PURE__ */
|
|
315
|
+
}), /* @__PURE__ */ f("p", {
|
|
315
316
|
className: "mt-1 text-text-primary",
|
|
316
317
|
children: G.license || "—"
|
|
317
318
|
})] }),
|
|
318
|
-
/* @__PURE__ */
|
|
319
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
319
320
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
320
321
|
children: "Published"
|
|
321
|
-
}), /* @__PURE__ */
|
|
322
|
+
}), /* @__PURE__ */ f("p", {
|
|
322
323
|
className: "mt-1 text-text-primary",
|
|
323
|
-
children:
|
|
324
|
+
children: A(G.publishedAt)
|
|
324
325
|
})] }),
|
|
325
|
-
/* @__PURE__ */
|
|
326
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
326
327
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
327
328
|
children: "DOI"
|
|
328
|
-
}), /* @__PURE__ */
|
|
329
|
+
}), /* @__PURE__ */ f("p", {
|
|
329
330
|
className: "mt-1",
|
|
330
|
-
children: G.doi ? /* @__PURE__ */
|
|
331
|
-
href:
|
|
331
|
+
children: G.doi ? /* @__PURE__ */ p(a, {
|
|
332
|
+
href: j(G.doi),
|
|
332
333
|
className: "inline-flex items-center gap-1 text-text-primary underline-offset-2 hover:underline",
|
|
333
334
|
fallbackClassName: "text-text-secondary",
|
|
334
|
-
children: [G.doi, /* @__PURE__ */
|
|
335
|
+
children: [G.doi, /* @__PURE__ */ f(m, {
|
|
335
336
|
className: "size-3.5",
|
|
336
337
|
"aria-hidden": "true"
|
|
337
338
|
})]
|
|
338
|
-
}) : /* @__PURE__ */
|
|
339
|
+
}) : /* @__PURE__ */ f("span", {
|
|
339
340
|
className: "text-text-secondary",
|
|
340
341
|
children: "Not assigned"
|
|
341
342
|
})
|
|
342
343
|
})] })
|
|
343
344
|
]
|
|
344
345
|
}),
|
|
345
|
-
/* @__PURE__ */
|
|
346
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
|
|
346
347
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
347
348
|
children: [
|
|
348
349
|
"Datasets (",
|
|
349
350
|
G.datasetIds.length,
|
|
350
351
|
")"
|
|
351
352
|
]
|
|
352
|
-
}), /* @__PURE__ */
|
|
353
|
+
}), /* @__PURE__ */ f("div", {
|
|
353
354
|
className: "mt-1 flex flex-wrap gap-1.5",
|
|
354
|
-
children: G.datasetIds.length === 0 ? /* @__PURE__ */
|
|
355
|
+
children: G.datasetIds.length === 0 ? /* @__PURE__ */ f("span", {
|
|
355
356
|
className: "text-text-secondary",
|
|
356
357
|
children: "None linked."
|
|
357
358
|
}) : G.datasetIds.map((e) => {
|
|
358
|
-
let t =
|
|
359
|
-
return /* @__PURE__ */
|
|
359
|
+
let t = Ee.get(e);
|
|
360
|
+
return /* @__PURE__ */ p(g, {
|
|
360
361
|
type: "button",
|
|
361
362
|
variant: "outline",
|
|
362
363
|
size: "sm",
|
|
363
364
|
className: "h-auto gap-1 px-2 py-1",
|
|
364
365
|
onClick: () => q(`datasets/${e}`),
|
|
365
|
-
children: [/* @__PURE__ */
|
|
366
|
+
children: [/* @__PURE__ */ f(ue, {
|
|
366
367
|
className: "size-3.5",
|
|
367
368
|
"aria-hidden": "true"
|
|
368
|
-
}), /* @__PURE__ */
|
|
369
|
+
}), /* @__PURE__ */ f("span", {
|
|
369
370
|
className: t ? "" : "font-mono text-xs",
|
|
370
371
|
children: t ?? e
|
|
371
372
|
})]
|
|
372
373
|
}, e);
|
|
373
374
|
})
|
|
374
375
|
})] }),
|
|
375
|
-
/* @__PURE__ */
|
|
376
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
376
377
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
377
378
|
children: "Notebook"
|
|
378
|
-
}), /* @__PURE__ */
|
|
379
|
+
}), /* @__PURE__ */ f("div", {
|
|
379
380
|
className: "mt-1",
|
|
380
|
-
children: G.notebookId ? /* @__PURE__ */
|
|
381
|
+
children: G.notebookId ? /* @__PURE__ */ p(g, {
|
|
381
382
|
type: "button",
|
|
382
383
|
variant: "outline",
|
|
383
384
|
size: "sm",
|
|
384
385
|
className: "h-auto gap-1 px-2 py-1",
|
|
385
386
|
onClick: () => q(`notebooks/${G.notebookId}`),
|
|
386
|
-
children: [/* @__PURE__ */
|
|
387
|
+
children: [/* @__PURE__ */ f(de, {
|
|
387
388
|
className: "size-3.5",
|
|
388
389
|
"aria-hidden": "true"
|
|
389
|
-
}), /* @__PURE__ */
|
|
390
|
+
}), /* @__PURE__ */ f("span", {
|
|
390
391
|
className: W.get(G.notebookId) ? "" : "font-mono text-xs",
|
|
391
392
|
children: W.get(G.notebookId) ?? G.notebookId
|
|
392
393
|
})]
|
|
393
|
-
}) : /* @__PURE__ */
|
|
394
|
+
}) : /* @__PURE__ */ f("span", {
|
|
394
395
|
className: "text-text-secondary",
|
|
395
396
|
children: "None linked."
|
|
396
397
|
})
|
|
397
398
|
})] }),
|
|
398
|
-
/* @__PURE__ */
|
|
399
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("p", {
|
|
399
400
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
400
401
|
children: "Discussion"
|
|
401
|
-
}), /* @__PURE__ */
|
|
402
|
+
}), /* @__PURE__ */ f("div", {
|
|
402
403
|
className: "mt-2",
|
|
403
|
-
children: /* @__PURE__ */
|
|
404
|
+
children: /* @__PURE__ */ f(oe, {
|
|
404
405
|
entityType: "cosmicintersection-release",
|
|
405
406
|
entityId: G.id,
|
|
406
407
|
title: G.title,
|
|
@@ -409,16 +410,16 @@ function N() {
|
|
|
409
410
|
})] })
|
|
410
411
|
]
|
|
411
412
|
}),
|
|
412
|
-
/* @__PURE__ */
|
|
413
|
+
/* @__PURE__ */ p(b, { children: [k(G.status) ? /* @__PURE__ */ p(g, {
|
|
413
414
|
type: "button",
|
|
414
415
|
onClick: () => {
|
|
415
416
|
let e = G;
|
|
416
417
|
K(null), Q(e);
|
|
417
418
|
},
|
|
418
|
-
children: [/* @__PURE__ */
|
|
419
|
-
}) : null, /* @__PURE__ */
|
|
419
|
+
children: [/* @__PURE__ */ f(h, { className: "size-4" }), "Publish"]
|
|
420
|
+
}) : null, /* @__PURE__ */ f(pe, {
|
|
420
421
|
asChild: !0,
|
|
421
|
-
children: /* @__PURE__ */
|
|
422
|
+
children: /* @__PURE__ */ f(g, {
|
|
422
423
|
type: "button",
|
|
423
424
|
variant: "outline",
|
|
424
425
|
children: "Close"
|
|
@@ -427,76 +428,76 @@ function N() {
|
|
|
427
428
|
] }) : null
|
|
428
429
|
})
|
|
429
430
|
}),
|
|
430
|
-
/* @__PURE__ */
|
|
431
|
+
/* @__PURE__ */ f(_, {
|
|
431
432
|
open: J !== null,
|
|
432
433
|
onOpenChange: (e) => e || B ? void 0 : Y(null),
|
|
433
|
-
children: /* @__PURE__ */
|
|
434
|
+
children: /* @__PURE__ */ p(v, {
|
|
434
435
|
className: "max-w-md",
|
|
435
436
|
children: [
|
|
436
|
-
/* @__PURE__ */
|
|
437
|
-
J ? /* @__PURE__ */
|
|
437
|
+
/* @__PURE__ */ p(x, { children: [/* @__PURE__ */ f(S, { children: N("cosmicintersection.pages.releases.publishRelease", "Publish release") }), /* @__PURE__ */ f(y, { children: J ? N("cosmicintersection.pages.releases.publishDescription", "Publish “{{name}}” to make it publicly citable. You can attach a DOI now or later.", { name: J.title }) : "" })] }),
|
|
438
|
+
J ? /* @__PURE__ */ p("dl", {
|
|
438
439
|
className: "grid grid-cols-3 gap-x-4 gap-y-3 rounded-card border border-border-default bg-bg-sunken p-3",
|
|
439
440
|
children: [
|
|
440
|
-
/* @__PURE__ */
|
|
441
|
+
/* @__PURE__ */ p("div", {
|
|
441
442
|
className: "col-span-2 min-w-0",
|
|
442
|
-
children: [/* @__PURE__ */
|
|
443
|
+
children: [/* @__PURE__ */ f("dt", {
|
|
443
444
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
444
445
|
children: "Authors"
|
|
445
|
-
}), /* @__PURE__ */
|
|
446
|
+
}), /* @__PURE__ */ f("dd", {
|
|
446
447
|
className: "mt-0.5 truncate text-sm text-text-primary",
|
|
447
448
|
title: J.authors.join(", "),
|
|
448
449
|
children: J.authors.length ? J.authors.join(", ") : "—"
|
|
449
450
|
})]
|
|
450
451
|
}),
|
|
451
|
-
/* @__PURE__ */
|
|
452
|
+
/* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("dt", {
|
|
452
453
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
453
454
|
children: "Datasets"
|
|
454
|
-
}), /* @__PURE__ */
|
|
455
|
+
}), /* @__PURE__ */ f("dd", {
|
|
455
456
|
className: "mt-0.5 text-sm tabular-nums text-text-primary",
|
|
456
457
|
children: J.datasetIds.length
|
|
457
458
|
})] }),
|
|
458
|
-
/* @__PURE__ */
|
|
459
|
+
/* @__PURE__ */ p("div", {
|
|
459
460
|
className: "col-span-3 min-w-0",
|
|
460
|
-
children: [/* @__PURE__ */
|
|
461
|
+
children: [/* @__PURE__ */ f("dt", {
|
|
461
462
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
462
463
|
children: "License"
|
|
463
|
-
}), /* @__PURE__ */
|
|
464
|
+
}), /* @__PURE__ */ f("dd", {
|
|
464
465
|
className: "mt-0.5 truncate text-sm text-text-primary",
|
|
465
466
|
children: J.license || "—"
|
|
466
467
|
})]
|
|
467
468
|
})
|
|
468
469
|
]
|
|
469
470
|
}) : null,
|
|
470
|
-
/* @__PURE__ */
|
|
471
|
+
/* @__PURE__ */ p("div", {
|
|
471
472
|
className: "space-y-2",
|
|
472
473
|
children: [
|
|
473
|
-
/* @__PURE__ */
|
|
474
|
+
/* @__PURE__ */ f(he, {
|
|
474
475
|
htmlFor: "release-doi",
|
|
475
|
-
children: "DOI (optional)"
|
|
476
|
+
children: N("cosmicintersection.pages.releases.doiOptional", "DOI (optional)")
|
|
476
477
|
}),
|
|
477
|
-
/* @__PURE__ */
|
|
478
|
+
/* @__PURE__ */ f(me, {
|
|
478
479
|
id: "release-doi",
|
|
479
480
|
value: X,
|
|
480
481
|
onChange: (e) => Z(e.target.value),
|
|
481
482
|
placeholder: "10.1234/cosmic.2026.0001"
|
|
482
483
|
}),
|
|
483
|
-
/* @__PURE__ */
|
|
484
|
+
/* @__PURE__ */ f("p", {
|
|
484
485
|
className: "text-xs text-text-secondary",
|
|
485
|
-
children: "A Digital Object Identifier makes the release permanently referenceable."
|
|
486
|
+
children: N("cosmicintersection.pages.releases.doiHint", "A Digital Object Identifier makes the release permanently referenceable.")
|
|
486
487
|
})
|
|
487
488
|
]
|
|
488
489
|
}),
|
|
489
|
-
/* @__PURE__ */
|
|
490
|
+
/* @__PURE__ */ p(b, { children: [/* @__PURE__ */ f(g, {
|
|
490
491
|
type: "button",
|
|
491
492
|
variant: "outline",
|
|
492
493
|
onClick: () => Y(null),
|
|
493
494
|
disabled: B,
|
|
494
|
-
children: "Cancel"
|
|
495
|
-
}), /* @__PURE__ */
|
|
495
|
+
children: N("cosmicintersection.common.cancel", "Cancel")
|
|
496
|
+
}), /* @__PURE__ */ p(g, {
|
|
496
497
|
type: "button",
|
|
497
|
-
onClick: () => void
|
|
498
|
+
onClick: () => void De(),
|
|
498
499
|
disabled: B,
|
|
499
|
-
children: [/* @__PURE__ */
|
|
500
|
+
children: [/* @__PURE__ */ f(h, { className: "size-4" }), B ? N("cosmicintersection.pages.releases.publishing", "Publishing…") : N("cosmicintersection.pages.releases.publishRelease", "Publish release")]
|
|
500
501
|
})] })
|
|
501
502
|
]
|
|
502
503
|
})
|
|
@@ -505,6 +506,6 @@ function N() {
|
|
|
505
506
|
});
|
|
506
507
|
}
|
|
507
508
|
//#endregion
|
|
508
|
-
export {
|
|
509
|
+
export { M as default };
|
|
509
510
|
|
|
510
511
|
//# sourceMappingURL=ReleasesPage.js.map
|