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