@parallelworks/tandem-web 0.138.2 → 0.139.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/components/AgentWork.js +35 -35
- package/components/AppRoot.js +8 -7
- package/components/AreaWork.js +1 -1
- package/components/BlockHandle.js +3 -3
- package/components/CommandPalette.js +27 -27
- package/components/DateChip.js +27 -27
- package/components/DocLinkPicker.js +17 -17
- package/components/Graph.js +6 -6
- package/components/HoverCards.js +30 -29
- package/components/IssueListBlock.js +83 -83
- package/components/LinkCard.js +20 -20
- package/components/MentionPicker.js +12 -12
- package/components/NewIssueDialog.js +116 -116
- package/components/NewProjectDialog.js +5 -4
- package/components/Planning.js +31 -43
- package/components/RouterLink.js +4 -4
- package/components/ShareDialog.js +12 -12
- package/components/SharedUI.js +19 -19
- package/components/SlashMenu.js +11 -11
- package/components/SubPages.js +10 -10
- package/components/UnlinkedMentions.js +10 -10
- package/components/WorkCounts.js +8 -8
- package/components/settings.js +31 -31
- package/hostedApp.js +41 -39
- package/hosting.d.ts +24 -11
- package/index.js +58 -27
- package/lib/base.js +1 -14
- package/lib/docs.js +6 -6
- package/lib/issueMenu.js +33 -33
- package/lib/knowledge.js +90 -101
- package/lib/knowledgeKinds.js +14 -0
- package/lib/pageTitle.js +22 -10
- package/lib/projectList.js +1 -1
- package/lib/projectStates.js +15 -0
- package/lib/router.js +20 -34
- package/package.json +2 -2
- package/pages/areas.js +223 -223
- package/pages/decisions.js +69 -69
- package/pages/issues.js +38 -38
- package/pages/projects.js +268 -267
- package/pages/triage.js +133 -133
- package/pages.js +21 -0
- package/routes/__root.js +6 -6
- package/routes/_workspace/agents/_slug2.js +21 -21
- package/routes/_workspace/agents/index2.js +16 -16
- package/routes/_workspace/areas/_area2.js +105 -105
- package/routes/_workspace/docs/_doc2.js +189 -189
- package/routes/_workspace/docs2.js +8 -8
- package/routes/_workspace/graph2.js +9 -9
- package/routes/_workspace/graph3.js +8 -8
- package/routes/_workspace/issues/_identifier2.js +249 -249
- package/routes/_workspace/issues/index.js +6 -6
- package/routes/_workspace/knowledge/_term2.js +119 -118
- package/routes/_workspace/knowledge/index.js +8 -8
- package/routes/_workspace/knowledge/index2.js +41 -40
- package/routes/_workspace/measures2.js +4 -4
- package/routes/_workspace/measures3.js +18 -18
- package/routes/_workspace/notifications2.js +112 -112
- package/routes/_workspace/people/_username.js +4 -4
- package/routes/_workspace/people/_username2.js +36 -36
- package/routes/_workspace/projects/_projectId3.js +369 -368
- package/routes/_workspace/projects/index.js +7 -7
- package/routes/_workspace/settings/account2.js +3 -3
- package/routes/_workspace/settings/audit-log2.js +4 -4
- package/routes/_workspace/settings/audit-log3.js +51 -51
- package/routes/_workspace/settings/labels2.js +14 -14
- package/routes/_workspace/settings/members2.js +9 -9
- package/routes/_workspace/settings/runners2.js +11 -11
- package/routes/_workspace/settings/teams2.js +15 -15
- package/routes/_workspace/settings/tokens2.js +5 -5
- package/routes/_workspace/settings/webhooks2.js +7 -7
- package/routes/_workspace/settings2.js +3 -3
- package/routes/_workspace/teams/_key/cycles/_number2.js +16 -16
- package/routes/_workspace/teams/_key/cycles/index2.js +40 -40
- package/routes/_workspace/teams/_key/issues.js +4 -4
- package/routes/_workspace/teams/_key/projects.js +4 -4
- package/routes/_workspace/teams/_key/settings2.js +133 -133
- package/routes/_workspace2.js +319 -319
- package/routes/docs/route2.js +19 -19
- package/routes/new2.js +8 -8
- package/routes/request2._token.js +4 -4
package/pages/triage.js
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../api/client.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
2
|
+
import { usePageTitle as n } from "../lib/pageTitle.js";
|
|
3
|
+
import { Link as r, useNavigate as i } from "../lib/router.js";
|
|
4
|
+
import { issueQuery as a, teamsQuery as o } from "../api/queries.js";
|
|
5
|
+
import { triageQuery as s } from "../lib/triage.js";
|
|
6
|
+
import { PriorityIcon as c, StatusIcon as l, TriageIcon as u, usePriorityNames as d } from "../components/icons.js";
|
|
7
|
+
import { useTime as f } from "../lib/time.js";
|
|
8
|
+
import { usePeople as p } from "../lib/people.js";
|
|
9
9
|
import { useCanTriage as m } from "../lib/roles.js";
|
|
10
10
|
import { EntityIcon as h } from "../components/EntityIcon.js";
|
|
11
11
|
import { actorAvatar as g } from "../lib/avatar.js";
|
|
12
12
|
import { Editor as _ } from "../components/Editor.js";
|
|
13
13
|
import { useShortcuts as v } from "../lib/shortcuts.js";
|
|
14
14
|
import { Avatar as y, Button as b, EmptyState as x, buttonClasses as S, toast as C } from "@parallelworks/ui";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
15
|
+
import { useParams as w, useSearch as T } from "@tanstack/react-router";
|
|
16
|
+
import { useCallback as E, useEffect as D, useRef as O, useState as k } from "react";
|
|
17
|
+
import { useErrorMessage as A } from "@parallelworks/problem/react";
|
|
18
|
+
import { useTranslations as j } from "use-intl";
|
|
19
|
+
import { Fragment as M, jsx as N, jsxs as P } from "react/jsx-runtime";
|
|
20
20
|
import { useMutation as F, useQuery as I, useQueryClient as L, useSuspenseQuery as R } from "@tanstack/react-query";
|
|
21
21
|
// src/pages/triage.tsx
|
|
22
22
|
function z() {
|
|
23
|
-
let
|
|
24
|
-
|
|
25
|
-
let
|
|
23
|
+
let r = j("triage"), { workspace: a, key: o } = w({ strict: !1 }), { issue: c } = T({ strict: !1 }), { data: l } = R(s(a, o));
|
|
24
|
+
n(r("title"));
|
|
25
|
+
let d = l.issues, f = A(), p = L(), [m, h] = k(/* @__PURE__ */ new Set()), [g, _] = k(/* @__PURE__ */ new Set()), y = E((e, t) => {
|
|
26
26
|
h((n) => n.has(e) === t ? n : t ? new Set(n).add(e) : V(n, e));
|
|
27
|
-
}, []), S =
|
|
27
|
+
}, []), S = d.filter((e) => m.has(e.id)), M = S.filter((e) => g.has(e.id)), I = i(), z = d.findIndex((e) => e.identifier === c?.toUpperCase()), W = O(null), G = d[z], K = (e) => I({
|
|
28
28
|
to: ".",
|
|
29
29
|
search: e ? { issue: e.identifier.toLowerCase() } : {},
|
|
30
30
|
replace: !0
|
|
@@ -32,17 +32,17 @@ function z() {
|
|
|
32
32
|
m.has(e.id) && _((t) => t.has(e.id) ? V(t, e.id) : new Set(t).add(e.id));
|
|
33
33
|
}, J = (e, t) => {
|
|
34
34
|
let [n, r] = e < t ? [e, t] : [t, e];
|
|
35
|
-
_(new Set(
|
|
35
|
+
_(new Set(d.slice(n, r + 1).filter((e) => m.has(e.id)).map((e) => e.id)));
|
|
36
36
|
}, Y = (e, t) => {
|
|
37
|
-
let n =
|
|
37
|
+
let n = d[t];
|
|
38
38
|
n && (e.metaKey || e.ctrlKey ? (e.preventDefault(), q(n), W.current = t) : e.shiftKey && (e.preventDefault(), J(W.current ?? (z >= 0 ? z : t), t)));
|
|
39
39
|
}, X = (e, t) => {
|
|
40
|
-
if (
|
|
41
|
-
let n = z < 0 ? 0 : Math.min(Math.max(z + e, 0),
|
|
42
|
-
t && ((W.current === null || g.size === 0) && (W.current = Math.max(z, 0)), J(W.current, n)), K(
|
|
40
|
+
if (d.length === 0) return;
|
|
41
|
+
let n = z < 0 ? 0 : Math.min(Math.max(z + e, 0), d.length - 1);
|
|
42
|
+
t && ((W.current === null || g.size === 0) && (W.current = Math.max(z, 0)), J(W.current, n)), K(d[n]);
|
|
43
43
|
}, Z = (e) => {
|
|
44
|
-
let t =
|
|
45
|
-
e.id === G?.id && K(
|
|
44
|
+
let t = d.findIndex((t) => t.id === e.id);
|
|
45
|
+
e.id === G?.id && K(d[t + 1] ?? d[t - 1]);
|
|
46
46
|
};
|
|
47
47
|
v({
|
|
48
48
|
j: () => X(1, !1),
|
|
@@ -57,19 +57,19 @@ function z() {
|
|
|
57
57
|
Enter: () => G && I({
|
|
58
58
|
to: "/$workspace/issues/$identifier",
|
|
59
59
|
params: {
|
|
60
|
-
workspace:
|
|
60
|
+
workspace: a,
|
|
61
61
|
identifier: G.identifier
|
|
62
62
|
}
|
|
63
63
|
}),
|
|
64
64
|
Escape: () => g.size > 0 ? _(/* @__PURE__ */ new Set()) : K(void 0)
|
|
65
|
-
}),
|
|
65
|
+
}), D(() => {
|
|
66
66
|
let e = G && document.getElementById(`triage-${G.id}`);
|
|
67
67
|
e && (e.scrollIntoView({ block: "nearest" }), e.parentElement?.contains(document.activeElement) && e.querySelector("a")?.focus({ preventScroll: !0 }));
|
|
68
68
|
}, [G]);
|
|
69
69
|
let Q = F({
|
|
70
|
-
mutationFn: async (n) => (await Promise.allSettled(
|
|
70
|
+
mutationFn: async (n) => (await Promise.allSettled(M.map(async (r) => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/triage", {
|
|
71
71
|
params: { path: {
|
|
72
|
-
workspace:
|
|
72
|
+
workspace: a,
|
|
73
73
|
identifier: r.identifier
|
|
74
74
|
} },
|
|
75
75
|
body: { decision: n }
|
|
@@ -77,106 +77,106 @@ function z() {
|
|
|
77
77
|
onSuccess: (e) => {
|
|
78
78
|
if (G && g.has(G.id)) {
|
|
79
79
|
let e = (e) => !g.has(e.id);
|
|
80
|
-
K(
|
|
80
|
+
K(d.slice(z + 1).find(e) ?? d.slice(0, z).findLast(e));
|
|
81
81
|
}
|
|
82
82
|
_(/* @__PURE__ */ new Set());
|
|
83
83
|
let t = e[0];
|
|
84
|
-
t && C.error(
|
|
84
|
+
t && C.error(r("bulkFailed", {
|
|
85
85
|
count: e.length,
|
|
86
|
-
reason:
|
|
86
|
+
reason: f(t.reason)
|
|
87
87
|
}));
|
|
88
88
|
},
|
|
89
|
-
onSettled: () =>
|
|
89
|
+
onSettled: () => p.invalidateQueries({ queryKey: [
|
|
90
90
|
"workspace",
|
|
91
|
-
|
|
91
|
+
a,
|
|
92
92
|
"issues"
|
|
93
93
|
] })
|
|
94
94
|
});
|
|
95
|
-
return /* @__PURE__ */
|
|
95
|
+
return /* @__PURE__ */ P("div", {
|
|
96
96
|
className: "flex h-full flex-col",
|
|
97
|
-
children: [/* @__PURE__ */
|
|
97
|
+
children: [/* @__PURE__ */ P("header", {
|
|
98
98
|
className: "flex h-12 shrink-0 items-center gap-3 border-b border-border px-4 md:px-5",
|
|
99
99
|
children: [
|
|
100
|
-
/* @__PURE__ */
|
|
100
|
+
/* @__PURE__ */ N("h1", {
|
|
101
101
|
className: "text-sm font-semibold",
|
|
102
|
-
children:
|
|
102
|
+
children: r("title")
|
|
103
103
|
}),
|
|
104
|
-
/* @__PURE__ */
|
|
104
|
+
/* @__PURE__ */ N("span", {
|
|
105
105
|
className: "text-xs text-muted-foreground tabular-nums",
|
|
106
|
-
children:
|
|
106
|
+
children: d.length
|
|
107
107
|
}),
|
|
108
|
-
|
|
108
|
+
M.length > 0 && /* @__PURE__ */ P("div", {
|
|
109
109
|
className: "ml-auto flex items-center gap-2",
|
|
110
110
|
children: [
|
|
111
|
-
/* @__PURE__ */
|
|
111
|
+
/* @__PURE__ */ N("span", {
|
|
112
112
|
className: "text-xs font-medium text-human",
|
|
113
|
-
children:
|
|
113
|
+
children: r("selected", { count: M.length })
|
|
114
114
|
}),
|
|
115
|
-
|
|
115
|
+
M.length < S.length && /* @__PURE__ */ N("button", {
|
|
116
116
|
type: "button",
|
|
117
117
|
onClick: () => _(new Set(S.map((e) => e.id))),
|
|
118
118
|
className: "text-xs hover:underline",
|
|
119
|
-
children:
|
|
119
|
+
children: r("selectAll")
|
|
120
120
|
}),
|
|
121
|
-
/* @__PURE__ */
|
|
121
|
+
/* @__PURE__ */ N("button", {
|
|
122
122
|
type: "button",
|
|
123
123
|
onClick: () => _(/* @__PURE__ */ new Set()),
|
|
124
124
|
className: "text-xs hover:underline",
|
|
125
|
-
children:
|
|
125
|
+
children: r("clear")
|
|
126
126
|
}),
|
|
127
|
-
/* @__PURE__ */
|
|
127
|
+
/* @__PURE__ */ N(b, {
|
|
128
128
|
variant: "outline",
|
|
129
129
|
size: "sm",
|
|
130
|
-
title:
|
|
130
|
+
title: r("declineHelp"),
|
|
131
131
|
loading: Q.isPending && Q.variables === "decline",
|
|
132
132
|
disabled: Q.isPending,
|
|
133
133
|
onClick: () => Q.mutate("decline"),
|
|
134
|
-
children:
|
|
134
|
+
children: r("declineCount", { count: M.length })
|
|
135
135
|
}),
|
|
136
|
-
/* @__PURE__ */
|
|
136
|
+
/* @__PURE__ */ N(b, {
|
|
137
137
|
variant: "primary",
|
|
138
138
|
size: "sm",
|
|
139
|
-
title:
|
|
139
|
+
title: r("acceptHelp"),
|
|
140
140
|
loading: Q.isPending && Q.variables === "accept",
|
|
141
141
|
disabled: Q.isPending,
|
|
142
142
|
onClick: () => Q.mutate("accept"),
|
|
143
|
-
children:
|
|
143
|
+
children: r("acceptCount", { count: M.length })
|
|
144
144
|
})
|
|
145
145
|
]
|
|
146
146
|
})
|
|
147
147
|
]
|
|
148
|
-
}),
|
|
148
|
+
}), d.length === 0 ? /* @__PURE__ */ N("div", {
|
|
149
149
|
className: "min-h-0 flex-1 overflow-y-auto p-6",
|
|
150
|
-
children: /* @__PURE__ */
|
|
151
|
-
icon: /* @__PURE__ */
|
|
152
|
-
title:
|
|
153
|
-
description:
|
|
150
|
+
children: /* @__PURE__ */ N(x, {
|
|
151
|
+
icon: /* @__PURE__ */ N(u, {}),
|
|
152
|
+
title: r("empty"),
|
|
153
|
+
description: r("emptyDescription")
|
|
154
154
|
})
|
|
155
|
-
}) : /* @__PURE__ */
|
|
155
|
+
}) : /* @__PURE__ */ P("div", {
|
|
156
156
|
className: "flex min-h-0 flex-1",
|
|
157
|
-
children: [/* @__PURE__ */
|
|
158
|
-
"aria-label":
|
|
157
|
+
children: [/* @__PURE__ */ N("ul", {
|
|
158
|
+
"aria-label": r("title"),
|
|
159
159
|
className: B("min-h-0 min-w-0 flex-1 flex-col overflow-y-auto px-2 py-2 md:flex md:max-w-md md:border-r md:border-border", G ? "hidden" : "flex"),
|
|
160
|
-
children:
|
|
161
|
-
workspace:
|
|
160
|
+
children: d.map((e, t) => /* @__PURE__ */ N(H, {
|
|
161
|
+
workspace: a,
|
|
162
162
|
issue: e,
|
|
163
163
|
onEligible: y,
|
|
164
164
|
picked: g.has(e.id) && m.has(e.id),
|
|
165
165
|
current: t === z,
|
|
166
166
|
onClick: (e) => Y(e, t)
|
|
167
167
|
}, e.id))
|
|
168
|
-
}), /* @__PURE__ */
|
|
168
|
+
}), /* @__PURE__ */ N("div", {
|
|
169
169
|
className: B("min-w-0 flex-1 overflow-y-auto md:block", G ? "block" : "hidden"),
|
|
170
|
-
children: G ? /* @__PURE__ */
|
|
171
|
-
workspace:
|
|
170
|
+
children: G ? /* @__PURE__ */ N(U, {
|
|
171
|
+
workspace: a,
|
|
172
172
|
issue: G,
|
|
173
173
|
onBack: () => K(void 0),
|
|
174
174
|
onDecided: Z
|
|
175
|
-
}, G.id) : /* @__PURE__ */
|
|
175
|
+
}, G.id) : /* @__PURE__ */ N("div", {
|
|
176
176
|
className: "px-6 py-24",
|
|
177
|
-
children: /* @__PURE__ */
|
|
178
|
-
title:
|
|
179
|
-
description:
|
|
177
|
+
children: /* @__PURE__ */ N(x, {
|
|
178
|
+
title: r("noneSelected"),
|
|
179
|
+
description: r("shortcuts")
|
|
180
180
|
})
|
|
181
181
|
})
|
|
182
182
|
})]
|
|
@@ -188,50 +188,50 @@ function V(e, t) {
|
|
|
188
188
|
let n = new Set(e);
|
|
189
189
|
return n.delete(t), n;
|
|
190
190
|
}
|
|
191
|
-
function H({ workspace: e, issue: t, onEligible:
|
|
192
|
-
let s =
|
|
193
|
-
|
|
194
|
-
|
|
191
|
+
function H({ workspace: e, issue: t, onEligible: n, picked: i, current: a, onClick: o }) {
|
|
192
|
+
let s = j("triage"), c = f(), { actorName: l, avatarOf: u } = p(e), d = m(e, t.teamId);
|
|
193
|
+
D(() => n(t.id, d), [
|
|
194
|
+
n,
|
|
195
195
|
t.id,
|
|
196
|
-
|
|
196
|
+
d
|
|
197
197
|
]);
|
|
198
198
|
let h = t.creator;
|
|
199
|
-
return /* @__PURE__ */
|
|
199
|
+
return /* @__PURE__ */ N("li", {
|
|
200
200
|
id: `triage-${t.id}`,
|
|
201
201
|
"data-picked": i || void 0,
|
|
202
|
-
children: /* @__PURE__ */
|
|
202
|
+
children: /* @__PURE__ */ P(r, {
|
|
203
203
|
to: ".",
|
|
204
204
|
search: { issue: t.identifier.toLowerCase() },
|
|
205
205
|
replace: !0,
|
|
206
206
|
onClick: o,
|
|
207
207
|
"aria-current": a || void 0,
|
|
208
208
|
className: B("flex flex-col gap-1 px-3 py-2.5 select-none", i ? "bg-human-soft" : B("rounded-md", a ? "bg-muted" : "hover:bg-muted")),
|
|
209
|
-
children: [/* @__PURE__ */
|
|
209
|
+
children: [/* @__PURE__ */ P("span", {
|
|
210
210
|
className: "flex items-baseline gap-3",
|
|
211
|
-
children: [/* @__PURE__ */
|
|
211
|
+
children: [/* @__PURE__ */ N("span", {
|
|
212
212
|
className: "min-w-0 flex-1 truncate text-sm font-medium",
|
|
213
213
|
children: t.title
|
|
214
|
-
}), /* @__PURE__ */
|
|
214
|
+
}), /* @__PURE__ */ N("span", {
|
|
215
215
|
className: "shrink-0 text-xs text-muted-foreground tabular-nums",
|
|
216
216
|
children: t.identifier
|
|
217
217
|
})]
|
|
218
|
-
}), /* @__PURE__ */
|
|
218
|
+
}), /* @__PURE__ */ P("span", {
|
|
219
219
|
className: "flex items-center gap-1.5 text-xs text-muted-foreground",
|
|
220
220
|
children: [
|
|
221
|
-
/* @__PURE__ */
|
|
221
|
+
/* @__PURE__ */ N("span", {
|
|
222
222
|
className: B("flex shrink-0 rounded-full", i && "ring-1 ring-human/40"),
|
|
223
|
-
children: /* @__PURE__ */
|
|
223
|
+
children: /* @__PURE__ */ N(y, {
|
|
224
224
|
...g(h.kind),
|
|
225
225
|
name: l(h),
|
|
226
226
|
src: u(h.kind, h.handle),
|
|
227
227
|
size: "xs"
|
|
228
228
|
})
|
|
229
229
|
}),
|
|
230
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ N("span", {
|
|
231
231
|
className: "min-w-0 flex-1 truncate",
|
|
232
232
|
children: s("from", { name: l(h) })
|
|
233
233
|
}),
|
|
234
|
-
/* @__PURE__ */
|
|
234
|
+
/* @__PURE__ */ N("time", {
|
|
235
235
|
dateTime: t.createdAt,
|
|
236
236
|
title: c.full(t.createdAt),
|
|
237
237
|
className: "shrink-0 tabular-nums",
|
|
@@ -242,84 +242,84 @@ function H({ workspace: e, issue: t, onEligible: r, picked: i, current: a, onCli
|
|
|
242
242
|
})
|
|
243
243
|
});
|
|
244
244
|
}
|
|
245
|
-
function U({ workspace:
|
|
246
|
-
let v =
|
|
247
|
-
mutationFn: async (
|
|
245
|
+
function U({ workspace: n, issue: i, onBack: s, onDecided: u }) {
|
|
246
|
+
let v = j("triage"), x = f(), C = A(), w = L(), T = d(), { data: E } = R(o(n)), { data: D } = I(a(n, i.identifier)), O = D ?? i, { actorName: k, avatarOf: z } = p(n), B = E.find((e) => e.id === O.teamId), V = m(n, O.teamId), H = F({
|
|
247
|
+
mutationFn: async (r) => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/triage", {
|
|
248
248
|
params: { path: {
|
|
249
|
-
workspace:
|
|
250
|
-
identifier:
|
|
249
|
+
workspace: n,
|
|
250
|
+
identifier: O.identifier
|
|
251
251
|
} },
|
|
252
|
-
body: { decision:
|
|
252
|
+
body: { decision: r }
|
|
253
253
|
})),
|
|
254
254
|
onSuccess: () => {
|
|
255
|
-
|
|
255
|
+
u(i), w.invalidateQueries({ queryKey: [
|
|
256
256
|
"workspace",
|
|
257
|
-
|
|
257
|
+
n,
|
|
258
258
|
"issues"
|
|
259
259
|
] });
|
|
260
260
|
}
|
|
261
|
-
}), U =
|
|
262
|
-
return /* @__PURE__ */
|
|
261
|
+
}), U = O.creator;
|
|
262
|
+
return /* @__PURE__ */ P("article", {
|
|
263
263
|
className: "mx-auto w-full max-w-3xl px-4 py-5 md:px-8",
|
|
264
264
|
children: [
|
|
265
|
-
/* @__PURE__ */
|
|
265
|
+
/* @__PURE__ */ N("button", {
|
|
266
266
|
type: "button",
|
|
267
|
-
onClick:
|
|
267
|
+
onClick: s,
|
|
268
268
|
className: "mb-3 text-xs text-muted-foreground hover:text-foreground md:hidden",
|
|
269
269
|
children: v("back")
|
|
270
270
|
}),
|
|
271
|
-
/* @__PURE__ */
|
|
271
|
+
/* @__PURE__ */ P("p", {
|
|
272
272
|
className: "flex items-center gap-1.5 text-xs text-muted-foreground",
|
|
273
273
|
children: [
|
|
274
|
-
B && /* @__PURE__ */
|
|
274
|
+
B && /* @__PURE__ */ N(h, {
|
|
275
275
|
icon: B.icon,
|
|
276
276
|
name: B.name,
|
|
277
277
|
className: "size-3.5"
|
|
278
278
|
}),
|
|
279
|
-
/* @__PURE__ */
|
|
279
|
+
/* @__PURE__ */ N("span", {
|
|
280
280
|
className: "tabular-nums",
|
|
281
|
-
children:
|
|
281
|
+
children: O.identifier
|
|
282
282
|
}),
|
|
283
|
-
/* @__PURE__ */
|
|
283
|
+
/* @__PURE__ */ N("span", {
|
|
284
284
|
"aria-hidden": "true",
|
|
285
285
|
children: "·"
|
|
286
286
|
}),
|
|
287
|
-
/* @__PURE__ */
|
|
287
|
+
/* @__PURE__ */ N(y, {
|
|
288
288
|
...g(U.kind),
|
|
289
|
-
name:
|
|
289
|
+
name: k(U),
|
|
290
290
|
src: z(U.kind, U.handle),
|
|
291
291
|
size: "xs"
|
|
292
292
|
}),
|
|
293
|
-
/* @__PURE__ */
|
|
293
|
+
/* @__PURE__ */ N("span", {
|
|
294
294
|
className: "truncate",
|
|
295
|
-
children: v("from", { name:
|
|
295
|
+
children: v("from", { name: k(U) })
|
|
296
296
|
}),
|
|
297
|
-
/* @__PURE__ */
|
|
297
|
+
/* @__PURE__ */ N("span", {
|
|
298
298
|
"aria-hidden": "true",
|
|
299
299
|
children: "·"
|
|
300
300
|
}),
|
|
301
|
-
/* @__PURE__ */
|
|
302
|
-
dateTime:
|
|
303
|
-
title: x.full(
|
|
304
|
-
children: x.relative(
|
|
301
|
+
/* @__PURE__ */ N("time", {
|
|
302
|
+
dateTime: O.createdAt,
|
|
303
|
+
title: x.full(O.createdAt),
|
|
304
|
+
children: x.relative(O.createdAt)
|
|
305
305
|
})
|
|
306
306
|
]
|
|
307
307
|
}),
|
|
308
|
-
/* @__PURE__ */
|
|
308
|
+
/* @__PURE__ */ N("h2", {
|
|
309
309
|
className: "mt-1 text-xl font-semibold text-balance",
|
|
310
|
-
children: /* @__PURE__ */
|
|
310
|
+
children: /* @__PURE__ */ N(r, {
|
|
311
311
|
to: "/$workspace/issues/$identifier",
|
|
312
312
|
params: {
|
|
313
|
-
workspace:
|
|
314
|
-
identifier:
|
|
313
|
+
workspace: n,
|
|
314
|
+
identifier: O.identifier
|
|
315
315
|
},
|
|
316
316
|
className: "hover:underline",
|
|
317
|
-
children:
|
|
317
|
+
children: O.title
|
|
318
318
|
})
|
|
319
319
|
}),
|
|
320
|
-
/* @__PURE__ */
|
|
320
|
+
/* @__PURE__ */ P("div", {
|
|
321
321
|
className: "mt-4 flex flex-wrap items-center gap-2",
|
|
322
|
-
children: [V && /* @__PURE__ */ M
|
|
322
|
+
children: [V && /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(b, {
|
|
323
323
|
variant: "primary",
|
|
324
324
|
size: "sm",
|
|
325
325
|
title: v("acceptHelp"),
|
|
@@ -327,7 +327,7 @@ function U({ workspace: r, issue: o, onBack: l, onDecided: p }) {
|
|
|
327
327
|
disabled: H.isPending,
|
|
328
328
|
onClick: () => H.mutate("accept"),
|
|
329
329
|
children: v("accept")
|
|
330
|
-
}), /* @__PURE__ */
|
|
330
|
+
}), /* @__PURE__ */ N(b, {
|
|
331
331
|
variant: "outline",
|
|
332
332
|
size: "sm",
|
|
333
333
|
title: v("declineHelp"),
|
|
@@ -335,11 +335,11 @@ function U({ workspace: r, issue: o, onBack: l, onDecided: p }) {
|
|
|
335
335
|
disabled: H.isPending,
|
|
336
336
|
onClick: () => H.mutate("decline"),
|
|
337
337
|
children: v("decline")
|
|
338
|
-
})] }), /* @__PURE__ */
|
|
338
|
+
})] }), /* @__PURE__ */ N(r, {
|
|
339
339
|
to: "/$workspace/issues/$identifier",
|
|
340
340
|
params: {
|
|
341
|
-
workspace:
|
|
342
|
-
identifier:
|
|
341
|
+
workspace: n,
|
|
342
|
+
identifier: O.identifier
|
|
343
343
|
},
|
|
344
344
|
className: S({
|
|
345
345
|
size: "sm",
|
|
@@ -348,41 +348,41 @@ function U({ workspace: r, issue: o, onBack: l, onDecided: p }) {
|
|
|
348
348
|
children: v("openIssue")
|
|
349
349
|
})]
|
|
350
350
|
}),
|
|
351
|
-
H.error && /* @__PURE__ */
|
|
351
|
+
H.error && /* @__PURE__ */ N("p", {
|
|
352
352
|
className: "mt-2 text-xs text-danger",
|
|
353
353
|
children: C(H.error)
|
|
354
354
|
}),
|
|
355
|
-
/* @__PURE__ */
|
|
355
|
+
/* @__PURE__ */ N("p", {
|
|
356
356
|
className: "mt-3 text-xs text-muted-foreground",
|
|
357
357
|
children: v("duplicateHint")
|
|
358
358
|
}),
|
|
359
|
-
/* @__PURE__ */
|
|
359
|
+
/* @__PURE__ */ P("div", {
|
|
360
360
|
className: "mt-5 flex flex-wrap items-center gap-x-4 gap-y-1 border-y border-border py-2.5 text-xs text-muted-foreground",
|
|
361
361
|
children: [
|
|
362
|
-
/* @__PURE__ */
|
|
362
|
+
/* @__PURE__ */ P("span", {
|
|
363
363
|
className: "inline-flex items-center gap-1.5",
|
|
364
|
-
children: [/* @__PURE__ */
|
|
364
|
+
children: [/* @__PURE__ */ N(l, { category: O.status.category }), O.status.name]
|
|
365
365
|
}),
|
|
366
|
-
/* @__PURE__ */
|
|
366
|
+
/* @__PURE__ */ P("span", {
|
|
367
367
|
className: "inline-flex items-center gap-1.5",
|
|
368
|
-
children: [/* @__PURE__ */
|
|
368
|
+
children: [/* @__PURE__ */ N(c, { priority: O.priority }), T[O.priority]]
|
|
369
369
|
}),
|
|
370
|
-
|
|
370
|
+
O.labels.map((e) => /* @__PURE__ */ P("span", {
|
|
371
371
|
className: "inline-flex items-center gap-1.5",
|
|
372
|
-
children: [/* @__PURE__ */
|
|
372
|
+
children: [/* @__PURE__ */ N("span", {
|
|
373
373
|
className: "size-2 rounded-full",
|
|
374
374
|
style: { background: e.color }
|
|
375
375
|
}), e.name]
|
|
376
376
|
}, e.id))
|
|
377
377
|
]
|
|
378
378
|
}),
|
|
379
|
-
|
|
379
|
+
O.body.trim() ? /* @__PURE__ */ N("div", {
|
|
380
380
|
className: "mt-5 text-sm",
|
|
381
|
-
children: /* @__PURE__ */
|
|
382
|
-
value:
|
|
381
|
+
children: /* @__PURE__ */ N(_, {
|
|
382
|
+
value: O.body,
|
|
383
383
|
editable: !1
|
|
384
384
|
})
|
|
385
|
-
}) : /* @__PURE__ */
|
|
385
|
+
}) : /* @__PURE__ */ N("p", {
|
|
386
386
|
className: "mt-5 text-sm text-muted-foreground",
|
|
387
387
|
children: v("noDescription")
|
|
388
388
|
})
|
package/pages.js
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { routeTree as e } from "./routeTree.gen.js";
|
|
2
|
+
// src/pages.ts
|
|
3
|
+
var t = /* @__PURE__ */ new Set([
|
|
4
|
+
"/",
|
|
5
|
+
"/$workspace",
|
|
6
|
+
"/new",
|
|
7
|
+
"/no-access"
|
|
8
|
+
]);
|
|
9
|
+
function n() {
|
|
10
|
+
let n = e.children, i = n.filter((e) => t.has(r(e)));
|
|
11
|
+
for (let e of i) r(e) === "/$workspace" && (e.options.staticData = {
|
|
12
|
+
...e.options.staticData,
|
|
13
|
+
ownsCommandPalette: !0
|
|
14
|
+
});
|
|
15
|
+
return {
|
|
16
|
+
framed: i,
|
|
17
|
+
frameless: n.filter((e) => !t.has(r(e)))
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
var r = (e) => e.options.path ?? "";
|
|
21
|
+
export { n as splitPages };
|
package/routes/__root.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { ErrorPage as e } from "@parallelworks/ui";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { createRootRouteWithContext as t, lazyRouteComponent as n } from "@tanstack/react-router";
|
|
3
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
4
4
|
// src/routes/__root.tsx
|
|
5
|
-
var i =
|
|
6
|
-
component:
|
|
5
|
+
var i = t()({
|
|
6
|
+
component: n(() => import("../components/AppRoot.js")),
|
|
7
7
|
notFoundComponent: a
|
|
8
8
|
});
|
|
9
9
|
function a() {
|
|
10
|
-
return /* @__PURE__ */
|
|
10
|
+
return /* @__PURE__ */ r("div", {
|
|
11
11
|
className: "flex h-dvh",
|
|
12
|
-
children: /* @__PURE__ */
|
|
12
|
+
children: /* @__PURE__ */ r(e, { status: 404 })
|
|
13
13
|
});
|
|
14
14
|
}
|
|
15
15
|
export { i as Route };
|