@parallelworks/tandem-web 0.168.2 → 0.169.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/_virtual/_virtual_i18n/en/common.js +2 -0
- package/_virtual/_virtual_i18n/es/common.js +2 -0
- package/_virtual/_virtual_i18n/ja/common.js +2 -0
- package/_virtual/_virtual_i18n/ko/common.js +2 -0
- package/_virtual/_virtual_i18n/zh/common.js +2 -0
- package/api/queries.js +2 -1
- package/components/CycleSwitcher.js +46 -0
- package/lib/cycleSwitcher.js +14 -0
- package/lib/triageSeen.js +5 -0
- package/package.json +1 -1
- package/pages/triage.js +162 -158
- package/routes/_workspace/teams/_key/cycles/_number2.js +124 -122
- package/routes/_workspace/teams/_key/triage3.js +3 -4
- package/routes/_workspace/triage3.js +3 -4
package/api/queries.js
CHANGED
|
@@ -932,7 +932,8 @@ var a = i({
|
|
|
932
932
|
queryFn: async ({ signal: r }) => n(await t.GET("/api/v1/workspaces/{workspace}/triage/visits", {
|
|
933
933
|
params: { path: { workspace: e } },
|
|
934
934
|
signal: r
|
|
935
|
-
})).issueIds
|
|
935
|
+
})).issueIds,
|
|
936
|
+
retry: !1
|
|
936
937
|
}), Ne = (e, r) => i({
|
|
937
938
|
queryKey: [
|
|
938
939
|
"workspace",
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { useNavigate as e } from "../lib/router.js";
|
|
2
|
+
import { ChevronDownIcon as t, ChevronRightIcon as n } from "./icons.js";
|
|
3
|
+
import { useTime as r } from "../lib/time.js";
|
|
4
|
+
import { byStart as i } from "../lib/cycleOrder.js";
|
|
5
|
+
import { cycleChoices as a } from "../lib/cycleSwitcher.js";
|
|
6
|
+
import { Combobox as o } from "@parallelworks/ui";
|
|
7
|
+
import { useTranslations as s } from "use-intl";
|
|
8
|
+
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
9
|
+
// src/components/CycleSwitcher.tsx
|
|
10
|
+
function u({ workspace: u, teamKey: d, cycles: f, cycle: p }) {
|
|
11
|
+
let m = s("planning"), h = r(), g = e(), _ = (e) => e.name ? m("cycleNamed", {
|
|
12
|
+
number: e.number,
|
|
13
|
+
name: e.name
|
|
14
|
+
}) : m("cycle", { number: e.number }), v = a([...f].sort(i), _, (e) => h.dayRange(e.startsOn, e.endsOn), (e) => m(`states.${e}`));
|
|
15
|
+
return /* @__PURE__ */ l("span", {
|
|
16
|
+
className: "flex min-w-0 items-center gap-1.5 text-[13px] leading-none",
|
|
17
|
+
children: [/* @__PURE__ */ c(n, {
|
|
18
|
+
"aria-hidden": "true",
|
|
19
|
+
className: "size-3 shrink-0 text-muted-foreground opacity-60 rtl:rotate-180"
|
|
20
|
+
}), /* @__PURE__ */ c(o, {
|
|
21
|
+
"aria-label": m("switchCycle"),
|
|
22
|
+
placeholder: m("findCycle"),
|
|
23
|
+
items: v,
|
|
24
|
+
value: String(p.number),
|
|
25
|
+
onValueChange: (e) => {
|
|
26
|
+
e !== null && e !== String(p.number) && g({
|
|
27
|
+
to: "/$workspace/teams/$key/cycles/$number",
|
|
28
|
+
params: {
|
|
29
|
+
workspace: u,
|
|
30
|
+
key: d,
|
|
31
|
+
number: e
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
},
|
|
35
|
+
trigger: /* @__PURE__ */ l("button", {
|
|
36
|
+
type: "button",
|
|
37
|
+
className: "flex min-w-0 cursor-pointer items-center gap-1 rounded-sm px-1 py-0.5 font-medium text-foreground hover:bg-muted",
|
|
38
|
+
children: [/* @__PURE__ */ c("span", {
|
|
39
|
+
className: "truncate",
|
|
40
|
+
children: _(p)
|
|
41
|
+
}), /* @__PURE__ */ c(t, { className: "size-3.5 shrink-0 text-muted-foreground" })]
|
|
42
|
+
})
|
|
43
|
+
})]
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
export { u as CycleSwitcher };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// src/lib/cycleSwitcher.ts
|
|
2
|
+
function e(e, t, n, r) {
|
|
3
|
+
let i = [], a = "";
|
|
4
|
+
for (let o of e) (o.state !== a || i.length === 0) && (i.push({
|
|
5
|
+
label: r(o.state),
|
|
6
|
+
items: []
|
|
7
|
+
}), a = o.state), i[i.length - 1]?.items.push({
|
|
8
|
+
value: String(o.number),
|
|
9
|
+
label: t(o),
|
|
10
|
+
hint: n(o)
|
|
11
|
+
});
|
|
12
|
+
return i;
|
|
13
|
+
}
|
|
14
|
+
export { e as cycleChoices };
|
package/package.json
CHANGED
package/pages/triage.js
CHANGED
|
@@ -6,34 +6,38 @@ import { triageQuery as c, useVisitTriage as l } from "../lib/triage.js";
|
|
|
6
6
|
import { AddIcon as u, PriorityIcon as d, StatusIcon as f, TriageIcon as p, usePriorityNames as m } from "../components/icons.js";
|
|
7
7
|
import { usePeople as h } from "../lib/people.js";
|
|
8
8
|
import { useTime as g } from "../lib/time.js";
|
|
9
|
-
import { EntityIcon as
|
|
10
|
-
import { useCanTriage as
|
|
11
|
-
import { actorAvatar as
|
|
12
|
-
import { Editor as
|
|
13
|
-
import { useShortcuts as
|
|
14
|
-
import { ActorAvatar as
|
|
9
|
+
import { EntityIcon as ee } from "../components/EntityIcon.js";
|
|
10
|
+
import { useCanTriage as _ } from "../lib/roles.js";
|
|
11
|
+
import { actorAvatar as v } from "../lib/avatar.js";
|
|
12
|
+
import { Editor as y } from "../components/Editor.js";
|
|
13
|
+
import { useShortcuts as b } from "../lib/shortcuts.js";
|
|
14
|
+
import { ActorAvatar as x } from "../components/ActorAvatar.js";
|
|
15
|
+
import { unseen as S } from "../lib/triageSeen.js";
|
|
15
16
|
import { Avatar as C, Button as w, EmptyState as T, RelativeTime as E, buttonClasses as D, toast as O } from "@parallelworks/ui";
|
|
16
|
-
import { useParams as
|
|
17
|
-
import { useCallback as
|
|
18
|
-
import { useErrorMessage as
|
|
19
|
-
import { useTranslations as
|
|
20
|
-
import { Fragment as
|
|
21
|
-
import { useMutation as
|
|
17
|
+
import { useParams as te, useSearch as k } from "@tanstack/react-router";
|
|
18
|
+
import { useCallback as A, useEffect as j, useRef as M, useState as N } from "react";
|
|
19
|
+
import { useErrorMessage as P } from "@parallelworks/problem/react";
|
|
20
|
+
import { useTranslations as F } from "use-intl";
|
|
21
|
+
import { Fragment as I, jsx as L, jsxs as R } from "react/jsx-runtime";
|
|
22
|
+
import { useMutation as z, useQuery as B, useQueryClient as V, useSuspenseQuery as H } from "@tanstack/react-query";
|
|
22
23
|
// src/pages/triage.tsx
|
|
23
|
-
function
|
|
24
|
-
let r =
|
|
24
|
+
function U() {
|
|
25
|
+
let r = F("triage"), { workspace: a, key: o } = te({ strict: !1 }), { issue: u } = k({ strict: !1 }), { data: d } = H(c(a, o));
|
|
25
26
|
n(r("title"));
|
|
26
|
-
let f = d.issues, m =
|
|
27
|
-
|
|
28
|
-
}, []),
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
27
|
+
let f = d.issues, m = P(), h = V(), [g, ee] = N(/* @__PURE__ */ new Set()), [_, v] = N(/* @__PURE__ */ new Set()), y = A((e, t) => {
|
|
28
|
+
ee((n) => n.has(e) === t ? n : t ? new Set(n).add(e) : G(n, e));
|
|
29
|
+
}, []), x = f.filter((e) => g.has(e.id)), C = x.filter((e) => _.has(e.id)), E = i(), D = f.findIndex((e) => e.identifier === u?.toUpperCase()), I = M(null), U = f[D], { data: K, isError: ie } = B(s(a)), ae = {
|
|
30
|
+
data: K,
|
|
31
|
+
failed: ie
|
|
32
|
+
}, { mutate: q } = l(a), J = M(/* @__PURE__ */ new Set());
|
|
33
|
+
j(() => {
|
|
34
|
+
U && K && !K.includes(U.id) && !J.current.has(U.id) && (J.current.add(U.id), q({
|
|
35
|
+
id: U.id,
|
|
36
|
+
identifier: U.identifier
|
|
33
37
|
}));
|
|
34
38
|
}, [
|
|
35
|
-
|
|
36
|
-
|
|
39
|
+
U,
|
|
40
|
+
K,
|
|
37
41
|
q
|
|
38
42
|
]);
|
|
39
43
|
let Y = (e) => E({
|
|
@@ -41,22 +45,22 @@ function W() {
|
|
|
41
45
|
search: e ? { issue: e.identifier.toLowerCase() } : {},
|
|
42
46
|
replace: !0
|
|
43
47
|
}), X = (e) => {
|
|
44
|
-
g.has(e.id) &&
|
|
48
|
+
g.has(e.id) && v((t) => t.has(e.id) ? G(t, e.id) : new Set(t).add(e.id));
|
|
45
49
|
}, Z = (e, t) => {
|
|
46
50
|
let [n, r] = e < t ? [e, t] : [t, e];
|
|
47
|
-
|
|
48
|
-
},
|
|
51
|
+
v(new Set(f.slice(n, r + 1).filter((e) => g.has(e.id)).map((e) => e.id)));
|
|
52
|
+
}, oe = (e, t) => {
|
|
49
53
|
let n = f[t];
|
|
50
|
-
n && (e.metaKey || e.ctrlKey ? (e.preventDefault(), X(n),
|
|
54
|
+
n && (e.metaKey || e.ctrlKey ? (e.preventDefault(), X(n), I.current = t) : e.shiftKey && (e.preventDefault(), Z(I.current ?? (D >= 0 ? D : t), t)));
|
|
51
55
|
}, Q = (e, t) => {
|
|
52
56
|
if (f.length === 0) return;
|
|
53
57
|
let n = D < 0 ? 0 : Math.min(Math.max(D + e, 0), f.length - 1);
|
|
54
|
-
t && ((
|
|
55
|
-
},
|
|
58
|
+
t && ((I.current === null || _.size === 0) && (I.current = Math.max(D, 0)), Z(I.current, n)), Y(f[n]);
|
|
59
|
+
}, se = (e) => {
|
|
56
60
|
let t = f.findIndex((t) => t.id === e.id);
|
|
57
|
-
e.id ===
|
|
61
|
+
e.id === U?.id && Y(f[t + 1] ?? f[t - 1]);
|
|
58
62
|
};
|
|
59
|
-
|
|
63
|
+
b({
|
|
60
64
|
j: () => Q(1, !1),
|
|
61
65
|
k: () => Q(-1, !1),
|
|
62
66
|
J: () => Q(1, !0),
|
|
@@ -64,23 +68,23 @@ function W() {
|
|
|
64
68
|
ArrowDown: (e) => Q(1, e.shiftKey),
|
|
65
69
|
ArrowUp: (e) => Q(-1, e.shiftKey),
|
|
66
70
|
x: () => {
|
|
67
|
-
|
|
71
|
+
U && (X(U), I.current = D);
|
|
68
72
|
},
|
|
69
|
-
Enter: () =>
|
|
73
|
+
Enter: () => U && E({
|
|
70
74
|
to: "/$workspace/issues/$identifier",
|
|
71
75
|
params: {
|
|
72
76
|
workspace: a,
|
|
73
|
-
identifier:
|
|
77
|
+
identifier: U.identifier
|
|
74
78
|
}
|
|
75
79
|
}),
|
|
76
|
-
"Mod+a": () =>
|
|
77
|
-
"Shift+Mod+a": () =>
|
|
78
|
-
Escape: () =>
|
|
79
|
-
}),
|
|
80
|
-
let e =
|
|
80
|
+
"Mod+a": () => v(new Set(f.map((e) => e.id))),
|
|
81
|
+
"Shift+Mod+a": () => v(/* @__PURE__ */ new Set()),
|
|
82
|
+
Escape: () => _.size > 0 ? v(/* @__PURE__ */ new Set()) : Y(void 0)
|
|
83
|
+
}), j(() => {
|
|
84
|
+
let e = U && document.getElementById(`triage-${U.id}`);
|
|
81
85
|
e && (e.scrollIntoView({ block: "nearest" }), e.parentElement?.contains(document.activeElement) && e.querySelector("a")?.focus({ preventScroll: !0 }));
|
|
82
|
-
}, [
|
|
83
|
-
let $ =
|
|
86
|
+
}, [U]);
|
|
87
|
+
let $ = z({
|
|
84
88
|
mutationFn: async (n) => (await Promise.allSettled(C.map(async (r) => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/triage", {
|
|
85
89
|
params: { path: {
|
|
86
90
|
workspace: a,
|
|
@@ -89,11 +93,11 @@ function W() {
|
|
|
89
93
|
body: { decision: n }
|
|
90
94
|
}))))).filter((e) => e.status === "rejected"),
|
|
91
95
|
onSuccess: (e) => {
|
|
92
|
-
if (
|
|
93
|
-
let e = (e) => !
|
|
96
|
+
if (U && _.has(U.id)) {
|
|
97
|
+
let e = (e) => !_.has(e.id);
|
|
94
98
|
Y(f.slice(D + 1).find(e) ?? f.slice(0, D).findLast(e));
|
|
95
99
|
}
|
|
96
|
-
|
|
100
|
+
v(/* @__PURE__ */ new Set());
|
|
97
101
|
let t = e[0];
|
|
98
102
|
t && O.error(r("bulkFailed", {
|
|
99
103
|
count: e.length,
|
|
@@ -106,39 +110,39 @@ function W() {
|
|
|
106
110
|
"issues"
|
|
107
111
|
] })
|
|
108
112
|
});
|
|
109
|
-
return /* @__PURE__ */
|
|
113
|
+
return /* @__PURE__ */ R("div", {
|
|
110
114
|
className: "flex h-full flex-col",
|
|
111
|
-
children: [/* @__PURE__ */
|
|
115
|
+
children: [/* @__PURE__ */ R("header", {
|
|
112
116
|
className: "flex h-12 shrink-0 items-center gap-3 border-b border-border px-4 md:px-5",
|
|
113
117
|
children: [
|
|
114
|
-
/* @__PURE__ */
|
|
118
|
+
/* @__PURE__ */ L("h1", {
|
|
115
119
|
className: "text-sm font-semibold",
|
|
116
120
|
children: r("title")
|
|
117
121
|
}),
|
|
118
|
-
/* @__PURE__ */
|
|
122
|
+
/* @__PURE__ */ L("span", {
|
|
119
123
|
className: "text-xs text-muted-foreground tabular-nums",
|
|
120
124
|
children: f.length
|
|
121
125
|
}),
|
|
122
|
-
C.length > 0 && /* @__PURE__ */
|
|
126
|
+
C.length > 0 && /* @__PURE__ */ R("div", {
|
|
123
127
|
className: "ml-auto flex items-center gap-2",
|
|
124
128
|
children: [
|
|
125
|
-
/* @__PURE__ */
|
|
129
|
+
/* @__PURE__ */ L("span", {
|
|
126
130
|
className: "text-xs font-medium text-human",
|
|
127
131
|
children: r("selected", { count: C.length })
|
|
128
132
|
}),
|
|
129
|
-
C.length <
|
|
133
|
+
C.length < x.length && /* @__PURE__ */ L("button", {
|
|
130
134
|
type: "button",
|
|
131
|
-
onClick: () =>
|
|
135
|
+
onClick: () => v(new Set(x.map((e) => e.id))),
|
|
132
136
|
className: "text-xs hover:underline",
|
|
133
137
|
children: r("selectAll")
|
|
134
138
|
}),
|
|
135
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ L("button", {
|
|
136
140
|
type: "button",
|
|
137
|
-
onClick: () =>
|
|
141
|
+
onClick: () => v(/* @__PURE__ */ new Set()),
|
|
138
142
|
className: "text-xs hover:underline",
|
|
139
143
|
children: r("clear")
|
|
140
144
|
}),
|
|
141
|
-
/* @__PURE__ */
|
|
145
|
+
/* @__PURE__ */ L(w, {
|
|
142
146
|
variant: "outline",
|
|
143
147
|
size: "sm",
|
|
144
148
|
title: r("declineHelp"),
|
|
@@ -147,7 +151,7 @@ function W() {
|
|
|
147
151
|
onClick: () => $.mutate("decline"),
|
|
148
152
|
children: r("declineCount", { count: C.length })
|
|
149
153
|
}),
|
|
150
|
-
/* @__PURE__ */
|
|
154
|
+
/* @__PURE__ */ L(w, {
|
|
151
155
|
variant: "primary",
|
|
152
156
|
size: "sm",
|
|
153
157
|
title: r("acceptHelp"),
|
|
@@ -159,37 +163,37 @@ function W() {
|
|
|
159
163
|
]
|
|
160
164
|
})
|
|
161
165
|
]
|
|
162
|
-
}), f.length === 0 ? /* @__PURE__ */
|
|
166
|
+
}), f.length === 0 ? /* @__PURE__ */ L("div", {
|
|
163
167
|
className: "min-h-0 flex-1 overflow-y-auto p-6",
|
|
164
|
-
children: /* @__PURE__ */
|
|
165
|
-
icon: /* @__PURE__ */
|
|
168
|
+
children: /* @__PURE__ */ L(T, {
|
|
169
|
+
icon: /* @__PURE__ */ L(p, {}),
|
|
166
170
|
title: r("empty"),
|
|
167
171
|
description: r("emptyDescription")
|
|
168
172
|
})
|
|
169
|
-
}) : /* @__PURE__ */
|
|
173
|
+
}) : /* @__PURE__ */ R("div", {
|
|
170
174
|
className: "flex min-h-0 flex-1",
|
|
171
|
-
children: [/* @__PURE__ */
|
|
175
|
+
children: [/* @__PURE__ */ L("ul", {
|
|
172
176
|
"aria-label": r("title"),
|
|
173
|
-
className:
|
|
174
|
-
children: f.map((e, t) => /* @__PURE__ */
|
|
177
|
+
className: W("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", U ? "hidden" : "flex"),
|
|
178
|
+
children: f.map((e, t) => /* @__PURE__ */ L(ne, {
|
|
175
179
|
workspace: a,
|
|
176
180
|
issue: e,
|
|
177
|
-
onEligible:
|
|
178
|
-
picked:
|
|
181
|
+
onEligible: y,
|
|
182
|
+
picked: _.has(e.id) && g.has(e.id),
|
|
179
183
|
current: t === D,
|
|
180
|
-
unread:
|
|
181
|
-
onClick: (e) =>
|
|
184
|
+
unread: S(e.id, ae),
|
|
185
|
+
onClick: (e) => oe(e, t)
|
|
182
186
|
}, e.id))
|
|
183
|
-
}), /* @__PURE__ */
|
|
184
|
-
className:
|
|
185
|
-
children:
|
|
187
|
+
}), /* @__PURE__ */ L("div", {
|
|
188
|
+
className: W("min-w-0 flex-1 overflow-y-auto md:block", U ? "block" : "hidden"),
|
|
189
|
+
children: U ? /* @__PURE__ */ L(re, {
|
|
186
190
|
workspace: a,
|
|
187
|
-
issue:
|
|
191
|
+
issue: U,
|
|
188
192
|
onBack: () => Y(void 0),
|
|
189
|
-
onDecided:
|
|
190
|
-
},
|
|
193
|
+
onDecided: se
|
|
194
|
+
}, U.id) : /* @__PURE__ */ L("div", {
|
|
191
195
|
className: "px-6 py-24",
|
|
192
|
-
children: /* @__PURE__ */
|
|
196
|
+
children: /* @__PURE__ */ L(T, {
|
|
193
197
|
title: r("noneSelected"),
|
|
194
198
|
description: r("shortcuts")
|
|
195
199
|
})
|
|
@@ -198,75 +202,75 @@ function W() {
|
|
|
198
202
|
})]
|
|
199
203
|
});
|
|
200
204
|
}
|
|
201
|
-
var
|
|
202
|
-
function
|
|
205
|
+
var W = (...e) => e.filter(Boolean).join(" ");
|
|
206
|
+
function G(e, t) {
|
|
203
207
|
let n = new Set(e);
|
|
204
208
|
return n.delete(t), n;
|
|
205
209
|
}
|
|
206
|
-
function
|
|
207
|
-
let c =
|
|
208
|
-
|
|
210
|
+
function ne({ workspace: e, issue: t, onEligible: n, picked: i, current: a, unread: o, onClick: s }) {
|
|
211
|
+
let c = F("triage"), { actorName: l, avatarOf: d } = h(e), p = _(e, t.teamId);
|
|
212
|
+
j(() => n(t.id, p), [
|
|
209
213
|
n,
|
|
210
214
|
t.id,
|
|
211
215
|
p
|
|
212
216
|
]);
|
|
213
217
|
let m = t.creator;
|
|
214
|
-
return /* @__PURE__ */
|
|
218
|
+
return /* @__PURE__ */ L("li", {
|
|
215
219
|
id: `triage-${t.id}`,
|
|
216
220
|
"data-picked": i || void 0,
|
|
217
|
-
children: /* @__PURE__ */
|
|
221
|
+
children: /* @__PURE__ */ R(r, {
|
|
218
222
|
to: ".",
|
|
219
223
|
search: { issue: t.identifier.toLowerCase() },
|
|
220
224
|
replace: !0,
|
|
221
225
|
onClick: s,
|
|
222
226
|
"aria-current": a || void 0,
|
|
223
|
-
className:
|
|
227
|
+
className: W("flex gap-3 px-2 py-2.5 select-none", i ? "bg-human-soft" : W("rounded-md", a ? "bg-muted" : "hover:bg-muted")),
|
|
224
228
|
children: [
|
|
225
|
-
/* @__PURE__ */
|
|
229
|
+
/* @__PURE__ */ L("span", {
|
|
226
230
|
className: "flex w-2 shrink-0 justify-center pt-2.5",
|
|
227
|
-
children: o && /* @__PURE__ */
|
|
231
|
+
children: o && /* @__PURE__ */ L("span", {
|
|
228
232
|
role: "img",
|
|
229
233
|
"aria-label": c("unseen"),
|
|
230
234
|
className: "size-2 rounded-full bg-primary"
|
|
231
235
|
})
|
|
232
236
|
}),
|
|
233
|
-
/* @__PURE__ */
|
|
234
|
-
className:
|
|
235
|
-
children: /* @__PURE__ */
|
|
237
|
+
/* @__PURE__ */ L("span", {
|
|
238
|
+
className: W("h-fit shrink-0 rounded-full", i && "ring-1 ring-human/40"),
|
|
239
|
+
children: /* @__PURE__ */ L(x, {
|
|
236
240
|
actor: m,
|
|
237
241
|
name: l(m),
|
|
238
242
|
src: d(m.kind, m.handle),
|
|
239
|
-
badge: /* @__PURE__ */
|
|
243
|
+
badge: /* @__PURE__ */ L(u, {})
|
|
240
244
|
})
|
|
241
245
|
}),
|
|
242
|
-
/* @__PURE__ */
|
|
246
|
+
/* @__PURE__ */ R("span", {
|
|
243
247
|
className: "min-w-0 flex-1",
|
|
244
|
-
children: [/* @__PURE__ */
|
|
248
|
+
children: [/* @__PURE__ */ R("span", {
|
|
245
249
|
className: "flex items-baseline gap-2 text-sm",
|
|
246
|
-
children: [/* @__PURE__ */
|
|
247
|
-
className:
|
|
250
|
+
children: [/* @__PURE__ */ L("span", {
|
|
251
|
+
className: W("shrink-0 text-xs tabular-nums", o ? "font-medium text-foreground" : "text-muted-foreground"),
|
|
248
252
|
children: t.identifier
|
|
249
|
-
}), /* @__PURE__ */
|
|
250
|
-
className:
|
|
253
|
+
}), /* @__PURE__ */ L("span", {
|
|
254
|
+
className: W("min-w-0 flex-1 truncate", o ? "font-medium text-foreground" : "text-muted-foreground"),
|
|
251
255
|
children: t.title
|
|
252
256
|
})]
|
|
253
|
-
}), /* @__PURE__ */
|
|
257
|
+
}), /* @__PURE__ */ L("span", {
|
|
254
258
|
className: "mt-0.5 block truncate text-xs text-muted-foreground",
|
|
255
259
|
children: c("from", { name: l(m) })
|
|
256
260
|
})]
|
|
257
261
|
}),
|
|
258
|
-
/* @__PURE__ */
|
|
262
|
+
/* @__PURE__ */ R("span", {
|
|
259
263
|
className: "flex shrink-0 flex-col items-end gap-1 pt-0.5",
|
|
260
|
-
children: [/* @__PURE__ */
|
|
264
|
+
children: [/* @__PURE__ */ R("span", {
|
|
261
265
|
className: "flex h-4 items-center",
|
|
262
|
-
children: [/* @__PURE__ */
|
|
266
|
+
children: [/* @__PURE__ */ L(f, {
|
|
263
267
|
category: t.status.category,
|
|
264
268
|
step: t.status.step
|
|
265
|
-
}), /* @__PURE__ */
|
|
269
|
+
}), /* @__PURE__ */ L("span", {
|
|
266
270
|
className: "sr-only",
|
|
267
271
|
children: t.status.name
|
|
268
272
|
})]
|
|
269
|
-
}), /* @__PURE__ */
|
|
273
|
+
}), /* @__PURE__ */ L(E, {
|
|
270
274
|
value: t.createdAt,
|
|
271
275
|
format: "compact",
|
|
272
276
|
exact: "medium",
|
|
@@ -277,104 +281,104 @@ function ee({ workspace: e, issue: t, onEligible: n, picked: i, current: a, unre
|
|
|
277
281
|
})
|
|
278
282
|
});
|
|
279
283
|
}
|
|
280
|
-
function
|
|
281
|
-
let l =
|
|
284
|
+
function re({ workspace: n, issue: i, onBack: s, onDecided: c }) {
|
|
285
|
+
let l = F("triage"), u = g(), p = P(), b = V(), x = m(), { data: S } = H(o(n)), { data: T } = B(a(n, i.identifier)), E = T ?? i, { actorName: O, avatarOf: te } = h(n), k = S.find((e) => e.id === E.teamId), A = _(n, E.teamId), j = z({
|
|
282
286
|
mutationFn: async (r) => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/triage", {
|
|
283
287
|
params: { path: {
|
|
284
288
|
workspace: n,
|
|
285
|
-
identifier:
|
|
289
|
+
identifier: E.identifier
|
|
286
290
|
} },
|
|
287
291
|
body: { decision: r }
|
|
288
292
|
})),
|
|
289
293
|
onSuccess: () => {
|
|
290
|
-
c(i),
|
|
294
|
+
c(i), b.invalidateQueries({ queryKey: [
|
|
291
295
|
"workspace",
|
|
292
296
|
n,
|
|
293
297
|
"issues"
|
|
294
298
|
] });
|
|
295
299
|
}
|
|
296
|
-
}),
|
|
297
|
-
return /* @__PURE__ */
|
|
300
|
+
}), M = E.creator;
|
|
301
|
+
return /* @__PURE__ */ R("article", {
|
|
298
302
|
className: "mx-auto w-full max-w-3xl px-4 py-5 md:px-8",
|
|
299
303
|
children: [
|
|
300
|
-
/* @__PURE__ */
|
|
304
|
+
/* @__PURE__ */ L("button", {
|
|
301
305
|
type: "button",
|
|
302
306
|
onClick: s,
|
|
303
307
|
className: "mb-3 text-xs text-muted-foreground hover:text-foreground md:hidden",
|
|
304
308
|
children: l("back")
|
|
305
309
|
}),
|
|
306
|
-
/* @__PURE__ */
|
|
310
|
+
/* @__PURE__ */ R("p", {
|
|
307
311
|
className: "flex items-center gap-1.5 text-xs text-muted-foreground",
|
|
308
312
|
children: [
|
|
309
|
-
|
|
310
|
-
icon:
|
|
311
|
-
name:
|
|
313
|
+
k && /* @__PURE__ */ L(ee, {
|
|
314
|
+
icon: k.icon,
|
|
315
|
+
name: k.name,
|
|
312
316
|
className: "size-3.5"
|
|
313
317
|
}),
|
|
314
|
-
/* @__PURE__ */
|
|
318
|
+
/* @__PURE__ */ L("span", {
|
|
315
319
|
className: "tabular-nums",
|
|
316
|
-
children:
|
|
320
|
+
children: E.identifier
|
|
317
321
|
}),
|
|
318
|
-
/* @__PURE__ */
|
|
322
|
+
/* @__PURE__ */ L("span", {
|
|
319
323
|
"aria-hidden": "true",
|
|
320
324
|
children: "·"
|
|
321
325
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
323
|
-
...
|
|
324
|
-
name:
|
|
325
|
-
src:
|
|
326
|
+
/* @__PURE__ */ L(C, {
|
|
327
|
+
...v(M.kind),
|
|
328
|
+
name: O(M),
|
|
329
|
+
src: te(M.kind, M.handle),
|
|
326
330
|
size: "xs"
|
|
327
331
|
}),
|
|
328
|
-
/* @__PURE__ */
|
|
332
|
+
/* @__PURE__ */ L("span", {
|
|
329
333
|
className: "truncate",
|
|
330
|
-
children: l("from", { name:
|
|
334
|
+
children: l("from", { name: O(M) })
|
|
331
335
|
}),
|
|
332
|
-
/* @__PURE__ */
|
|
336
|
+
/* @__PURE__ */ L("span", {
|
|
333
337
|
"aria-hidden": "true",
|
|
334
338
|
children: "·"
|
|
335
339
|
}),
|
|
336
|
-
/* @__PURE__ */
|
|
337
|
-
dateTime:
|
|
338
|
-
title: u.full(
|
|
339
|
-
children: u.relative(
|
|
340
|
+
/* @__PURE__ */ L("time", {
|
|
341
|
+
dateTime: E.createdAt,
|
|
342
|
+
title: u.full(E.createdAt),
|
|
343
|
+
children: u.relative(E.createdAt)
|
|
340
344
|
})
|
|
341
345
|
]
|
|
342
346
|
}),
|
|
343
|
-
/* @__PURE__ */
|
|
347
|
+
/* @__PURE__ */ L("h2", {
|
|
344
348
|
className: "mt-1 text-xl font-semibold text-balance",
|
|
345
|
-
children: /* @__PURE__ */
|
|
349
|
+
children: /* @__PURE__ */ L(r, {
|
|
346
350
|
to: "/$workspace/issues/$identifier",
|
|
347
351
|
params: {
|
|
348
352
|
workspace: n,
|
|
349
|
-
identifier:
|
|
353
|
+
identifier: E.identifier
|
|
350
354
|
},
|
|
351
355
|
className: "hover:underline",
|
|
352
|
-
children:
|
|
356
|
+
children: E.title
|
|
353
357
|
})
|
|
354
358
|
}),
|
|
355
|
-
/* @__PURE__ */
|
|
359
|
+
/* @__PURE__ */ R("div", {
|
|
356
360
|
className: "mt-4 flex flex-wrap items-center gap-2",
|
|
357
|
-
children: [
|
|
361
|
+
children: [A && /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(w, {
|
|
358
362
|
variant: "primary",
|
|
359
363
|
size: "sm",
|
|
360
364
|
title: l("acceptHelp"),
|
|
361
|
-
loading:
|
|
362
|
-
disabled:
|
|
363
|
-
onClick: () =>
|
|
365
|
+
loading: j.isPending && j.variables === "accept",
|
|
366
|
+
disabled: j.isPending,
|
|
367
|
+
onClick: () => j.mutate("accept"),
|
|
364
368
|
children: l("accept")
|
|
365
|
-
}), /* @__PURE__ */
|
|
369
|
+
}), /* @__PURE__ */ L(w, {
|
|
366
370
|
variant: "outline",
|
|
367
371
|
size: "sm",
|
|
368
372
|
title: l("declineHelp"),
|
|
369
|
-
loading:
|
|
370
|
-
disabled:
|
|
371
|
-
onClick: () =>
|
|
373
|
+
loading: j.isPending && j.variables === "decline",
|
|
374
|
+
disabled: j.isPending,
|
|
375
|
+
onClick: () => j.mutate("decline"),
|
|
372
376
|
children: l("decline")
|
|
373
|
-
})] }), /* @__PURE__ */
|
|
377
|
+
})] }), /* @__PURE__ */ L(r, {
|
|
374
378
|
to: "/$workspace/issues/$identifier",
|
|
375
379
|
params: {
|
|
376
380
|
workspace: n,
|
|
377
|
-
identifier:
|
|
381
|
+
identifier: E.identifier
|
|
378
382
|
},
|
|
379
383
|
className: D({
|
|
380
384
|
size: "sm",
|
|
@@ -383,48 +387,48 @@ function te({ workspace: n, issue: i, onBack: s, onDecided: c }) {
|
|
|
383
387
|
children: l("openIssue")
|
|
384
388
|
})]
|
|
385
389
|
}),
|
|
386
|
-
|
|
390
|
+
j.error && /* @__PURE__ */ L("p", {
|
|
387
391
|
className: "mt-2 text-xs text-danger",
|
|
388
|
-
children: p(
|
|
392
|
+
children: p(j.error)
|
|
389
393
|
}),
|
|
390
|
-
/* @__PURE__ */
|
|
394
|
+
/* @__PURE__ */ L("p", {
|
|
391
395
|
className: "mt-3 text-xs text-muted-foreground",
|
|
392
396
|
children: l("duplicateHint")
|
|
393
397
|
}),
|
|
394
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ R("div", {
|
|
395
399
|
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",
|
|
396
400
|
children: [
|
|
397
|
-
/* @__PURE__ */
|
|
401
|
+
/* @__PURE__ */ R("span", {
|
|
398
402
|
className: "inline-flex items-center gap-1.5",
|
|
399
|
-
children: [/* @__PURE__ */
|
|
400
|
-
category:
|
|
401
|
-
step:
|
|
402
|
-
}),
|
|
403
|
+
children: [/* @__PURE__ */ L(f, {
|
|
404
|
+
category: E.status.category,
|
|
405
|
+
step: E.status.step
|
|
406
|
+
}), E.status.name]
|
|
403
407
|
}),
|
|
404
|
-
/* @__PURE__ */
|
|
408
|
+
/* @__PURE__ */ R("span", {
|
|
405
409
|
className: "inline-flex items-center gap-1.5",
|
|
406
|
-
children: [/* @__PURE__ */
|
|
410
|
+
children: [/* @__PURE__ */ L(d, { priority: E.priority }), x[E.priority]]
|
|
407
411
|
}),
|
|
408
|
-
|
|
412
|
+
E.labels.map((e) => /* @__PURE__ */ R("span", {
|
|
409
413
|
className: "inline-flex items-center gap-1.5",
|
|
410
|
-
children: [/* @__PURE__ */
|
|
414
|
+
children: [/* @__PURE__ */ L("span", {
|
|
411
415
|
className: "size-2 rounded-full",
|
|
412
416
|
style: { background: e.color }
|
|
413
417
|
}), e.name]
|
|
414
418
|
}, e.id))
|
|
415
419
|
]
|
|
416
420
|
}),
|
|
417
|
-
|
|
421
|
+
E.body.trim() ? /* @__PURE__ */ L("div", {
|
|
418
422
|
className: "mt-5 text-sm",
|
|
419
|
-
children: /* @__PURE__ */
|
|
420
|
-
value:
|
|
423
|
+
children: /* @__PURE__ */ L(y, {
|
|
424
|
+
value: E.body,
|
|
421
425
|
editable: !1
|
|
422
426
|
})
|
|
423
|
-
}) : /* @__PURE__ */
|
|
427
|
+
}) : /* @__PURE__ */ L("p", {
|
|
424
428
|
className: "mt-5 text-sm text-muted-foreground",
|
|
425
429
|
children: l("noDescription")
|
|
426
430
|
})
|
|
427
431
|
]
|
|
428
432
|
});
|
|
429
433
|
}
|
|
430
|
-
export {
|
|
434
|
+
export { U as TriagePage };
|
|
@@ -1,201 +1,203 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../../../api/client.js";
|
|
2
2
|
import { NotFound as n } from "../../../../../components/status.js";
|
|
3
|
-
import { usePageTitle as
|
|
4
|
-
import { useNavigate as
|
|
5
|
-
import { cyclesQuery as
|
|
6
|
-
import { invalidateIssueViews as
|
|
7
|
-
import { CloseIcon as
|
|
8
|
-
import { addDays as
|
|
9
|
-
import { ProgressBar as
|
|
10
|
-
import { useCan as
|
|
11
|
-
import { teamPath as
|
|
12
|
-
import { Route as
|
|
13
|
-
import { FavoriteStar as
|
|
14
|
-
import { BurnUp as
|
|
3
|
+
import { usePageTitle as ee } from "../../../../../lib/pageTitle.js";
|
|
4
|
+
import { useNavigate as r } from "../../../../../lib/router.js";
|
|
5
|
+
import { cyclesQuery as i, issuesQuery as a, teamsQuery as o } from "../../../../../api/queries.js";
|
|
6
|
+
import { invalidateIssueViews as s } from "../../../../../api/mutations.js";
|
|
7
|
+
import { CloseIcon as c, CycleIcon as l } from "../../../../../components/icons.js";
|
|
8
|
+
import { addDays as u, today as d, useTime as f } from "../../../../../lib/time.js";
|
|
9
|
+
import { ProgressBar as p } from "../../../../../components/Planning.js";
|
|
10
|
+
import { useCan as m } from "../../../../../lib/roles.js";
|
|
11
|
+
import { teamPath as h } from "../../../../../lib/teamPaths.js";
|
|
12
|
+
import { Route as g } from "./_number.js";
|
|
13
|
+
import { FavoriteStar as te } from "../../../../../components/FavoriteStar.js";
|
|
14
|
+
import { BurnUp as ne } from "../../../../../components/Reports.js";
|
|
15
15
|
import { IssueBreakdown as _, breakdownKeys as re } from "../../../../../components/IssueBreakdown.js";
|
|
16
16
|
import { StatusGroups as ie } from "../../../../../components/IssueGroup.js";
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
17
|
+
import { CycleSwitcher as ae } from "../../../../../components/CycleSwitcher.js";
|
|
18
|
+
import { Button as oe, Card as se, EmptyState as v, ErrorText as y, IconButton as b, PageHeader as x } from "@parallelworks/ui";
|
|
19
|
+
import { useState as S } from "react";
|
|
20
|
+
import { useErrorMessage as C } from "@parallelworks/problem/react";
|
|
21
|
+
import { useTranslations as w } from "use-intl";
|
|
22
|
+
import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
|
|
23
|
+
import { useMutation as O, useQuery as k, useQueryClient as A, useSuspenseQuery as j } from "@tanstack/react-query";
|
|
23
24
|
// src/routes/$workspace/teams/$key/cycles/$number.tsx?tsr-split=component
|
|
24
|
-
var
|
|
25
|
+
var M = [
|
|
25
26
|
"assignees",
|
|
26
27
|
"labels",
|
|
27
28
|
"priority",
|
|
28
29
|
"projects"
|
|
29
30
|
];
|
|
30
|
-
function
|
|
31
|
-
let { workspace:
|
|
32
|
-
|
|
33
|
-
number:
|
|
34
|
-
name:
|
|
35
|
-
}) :
|
|
36
|
-
let
|
|
37
|
-
...
|
|
38
|
-
enabled: !!
|
|
39
|
-
}),
|
|
31
|
+
function N() {
|
|
32
|
+
let { workspace: N, key: P, number: F } = g.useParams(), I = w("planning"), ce = C(), L = f(), R = r(), { data: z } = j(o(N)), { data: B } = j(i(N, P)), V = B.find((e) => String(e.number) === F), H = z.find((e) => e.key === P);
|
|
33
|
+
ee(V && (V.name ? I("cycleNamed", {
|
|
34
|
+
number: V.number,
|
|
35
|
+
name: V.name
|
|
36
|
+
}) : I("cycle", { number: V.number })), H?.name);
|
|
37
|
+
let U = m(N, "manage_cycles", { team: P }), W = A(), [G, le] = S(null), [K, q] = S("assignees"), [J, Y] = S(null), { data: ue } = k({
|
|
38
|
+
...a(N, { cycle: V?.id ?? "" }),
|
|
39
|
+
enabled: !!V
|
|
40
|
+
}), X = O({
|
|
40
41
|
mutationFn: async () => t(await e.POST("/api/v1/workspaces/{workspace}/teams/{key}/cycles/{number}/move-unfinished", { params: { path: {
|
|
41
|
-
workspace:
|
|
42
|
-
key:
|
|
43
|
-
number: Number(
|
|
42
|
+
workspace: N,
|
|
43
|
+
key: P,
|
|
44
|
+
number: Number(F)
|
|
44
45
|
} } })),
|
|
45
|
-
onSuccess: (e) =>
|
|
46
|
-
onSettled: () =>
|
|
46
|
+
onSuccess: (e) => le(e.moved),
|
|
47
|
+
onSettled: () => s(W, N)
|
|
47
48
|
});
|
|
48
|
-
if (!
|
|
49
|
-
let
|
|
50
|
-
number:
|
|
51
|
-
name:
|
|
52
|
-
}) :
|
|
53
|
-
return /* @__PURE__ */
|
|
49
|
+
if (!V) return /* @__PURE__ */ E(n, { title: I("noSuchCycle") });
|
|
50
|
+
let Z = ue?.issues ?? [], Q = J ? Z.filter((e) => re(e, J.tab).includes(J.key)) : Z, $ = Z.filter((e) => e.status.category !== "completed" && e.status.category !== "canceled").length, de = V.state === "past" || V.state === "current" && u(d(), 2) >= V.endsOn, fe = V.name ? I("cycleNamed", {
|
|
51
|
+
number: V.number,
|
|
52
|
+
name: V.name
|
|
53
|
+
}) : I("cycle", { number: V.number });
|
|
54
|
+
return /* @__PURE__ */ D("div", {
|
|
54
55
|
className: "flex h-full min-h-0 flex-col",
|
|
55
|
-
children: [/* @__PURE__ */
|
|
56
|
+
children: [/* @__PURE__ */ E(x, {
|
|
56
57
|
heading: !1,
|
|
57
|
-
breadcrumbs: [
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
58
|
+
breadcrumbs: [{
|
|
59
|
+
label: H?.name ?? P,
|
|
60
|
+
href: h(N, P, "issues")
|
|
61
|
+
}, {
|
|
62
|
+
label: I("cycles"),
|
|
63
|
+
href: h(N, P, "cycles")
|
|
64
|
+
}],
|
|
65
|
+
titleActions: /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(ae, {
|
|
66
|
+
workspace: N,
|
|
67
|
+
teamKey: P,
|
|
68
|
+
cycles: B,
|
|
69
|
+
cycle: V
|
|
70
|
+
}), /* @__PURE__ */ E(te, {
|
|
71
|
+
workspace: N,
|
|
70
72
|
kind: "cycle",
|
|
71
|
-
target:
|
|
72
|
-
})
|
|
73
|
-
}), /* @__PURE__ */
|
|
73
|
+
target: V.id
|
|
74
|
+
})] })
|
|
75
|
+
}), /* @__PURE__ */ D("div", {
|
|
74
76
|
className: "flex min-h-0 flex-1 flex-col overflow-y-auto xl:flex-row xl:overflow-hidden",
|
|
75
|
-
children: [/* @__PURE__ */
|
|
77
|
+
children: [/* @__PURE__ */ D("div", {
|
|
76
78
|
className: "w-full min-w-0 px-4 py-6 md:px-8 md:py-8 xl:flex-1 xl:overflow-y-auto",
|
|
77
79
|
children: [
|
|
78
|
-
/* @__PURE__ */
|
|
80
|
+
/* @__PURE__ */ D("div", {
|
|
79
81
|
className: "flex flex-wrap items-center gap-3",
|
|
80
82
|
children: [
|
|
81
|
-
/* @__PURE__ */
|
|
82
|
-
/* @__PURE__ */
|
|
83
|
+
/* @__PURE__ */ E(l, { className: `size-5 shrink-0 ${V.state === "current" ? "text-status-started" : "text-muted-foreground"}` }),
|
|
84
|
+
/* @__PURE__ */ E("h1", {
|
|
83
85
|
className: "text-xl font-semibold tracking-tight",
|
|
84
|
-
children:
|
|
86
|
+
children: fe
|
|
85
87
|
}),
|
|
86
|
-
/* @__PURE__ */
|
|
88
|
+
/* @__PURE__ */ E("span", {
|
|
87
89
|
className: "rounded-md border border-border px-1.5 py-0.5 text-xs text-muted-foreground",
|
|
88
|
-
children:
|
|
90
|
+
children: I(`states.${V.state}`)
|
|
89
91
|
}),
|
|
90
|
-
/* @__PURE__ */
|
|
92
|
+
/* @__PURE__ */ E("span", {
|
|
91
93
|
className: "text-sm text-muted-foreground",
|
|
92
|
-
children:
|
|
94
|
+
children: L.dayRange(V.startsOn, V.endsOn)
|
|
93
95
|
}),
|
|
94
|
-
|
|
96
|
+
V.carriedIn > 0 && /* @__PURE__ */ E("span", {
|
|
95
97
|
className: "text-sm text-muted-foreground",
|
|
96
|
-
children:
|
|
98
|
+
children: I("carriedIn", { count: V.carriedIn })
|
|
97
99
|
}),
|
|
98
|
-
|
|
100
|
+
V.carriedOut > 0 && /* @__PURE__ */ E("span", {
|
|
99
101
|
className: "text-sm text-muted-foreground",
|
|
100
|
-
children:
|
|
102
|
+
children: I("carriedOut", { count: V.carriedOut })
|
|
101
103
|
}),
|
|
102
|
-
|
|
104
|
+
U && $ > 0 && de && /* @__PURE__ */ E(oe, {
|
|
103
105
|
type: "button",
|
|
104
|
-
onClick: () =>
|
|
105
|
-
loading:
|
|
106
|
+
onClick: () => X.mutate(),
|
|
107
|
+
loading: X.isPending,
|
|
106
108
|
className: "ml-auto",
|
|
107
|
-
children:
|
|
109
|
+
children: I("moveUnfinished", { count: $ })
|
|
108
110
|
})
|
|
109
111
|
]
|
|
110
112
|
}),
|
|
111
|
-
|
|
113
|
+
X.isError && /* @__PURE__ */ E(y, {
|
|
112
114
|
size: "md",
|
|
113
115
|
className: "mt-2",
|
|
114
|
-
children:
|
|
116
|
+
children: ce(X.error)
|
|
115
117
|
}),
|
|
116
|
-
|
|
118
|
+
G !== null && X.data && /* @__PURE__ */ D("p", {
|
|
117
119
|
className: "mt-2 text-sm text-muted-foreground",
|
|
118
120
|
role: "status",
|
|
119
121
|
children: [
|
|
120
|
-
|
|
122
|
+
I("moved", { count: G }),
|
|
121
123
|
" ",
|
|
122
|
-
/* @__PURE__ */
|
|
124
|
+
/* @__PURE__ */ E("button", {
|
|
123
125
|
type: "button",
|
|
124
126
|
className: "text-primary hover:underline",
|
|
125
|
-
onClick: () =>
|
|
127
|
+
onClick: () => R({
|
|
126
128
|
to: "/$workspace/teams/$key/cycles/$number",
|
|
127
129
|
params: {
|
|
128
|
-
workspace:
|
|
129
|
-
key:
|
|
130
|
-
number: String(
|
|
130
|
+
workspace: N,
|
|
131
|
+
key: P,
|
|
132
|
+
number: String(X.data.cycle.number)
|
|
131
133
|
}
|
|
132
134
|
}),
|
|
133
|
-
children:
|
|
135
|
+
children: I("openCycle", { number: X.data.cycle.number })
|
|
134
136
|
})
|
|
135
137
|
]
|
|
136
138
|
}),
|
|
137
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ E("section", {
|
|
138
140
|
className: "mt-6",
|
|
139
|
-
"aria-label":
|
|
140
|
-
children: /* @__PURE__ */
|
|
141
|
+
"aria-label": I("progressTitle"),
|
|
142
|
+
children: /* @__PURE__ */ E(p, { progress: V.progress })
|
|
141
143
|
}),
|
|
142
|
-
/* @__PURE__ */
|
|
144
|
+
/* @__PURE__ */ E("section", {
|
|
143
145
|
className: "mt-6 rounded-xl border border-border bg-card p-4",
|
|
144
|
-
children: /* @__PURE__ */
|
|
145
|
-
workspace:
|
|
146
|
-
teamKey:
|
|
147
|
-
cycle:
|
|
146
|
+
children: /* @__PURE__ */ E(ne, {
|
|
147
|
+
workspace: N,
|
|
148
|
+
teamKey: P,
|
|
149
|
+
cycle: V
|
|
148
150
|
})
|
|
149
151
|
}),
|
|
150
|
-
|
|
152
|
+
Z.length > 0 && /* @__PURE__ */ E("div", {
|
|
151
153
|
className: "mt-8 xl:hidden",
|
|
152
|
-
children: /* @__PURE__ */
|
|
153
|
-
workspace:
|
|
154
|
-
issues:
|
|
155
|
-
tabs:
|
|
156
|
-
tab:
|
|
157
|
-
onTabChange:
|
|
158
|
-
focus:
|
|
159
|
-
onFocus: (e) =>
|
|
154
|
+
children: /* @__PURE__ */ E(_, {
|
|
155
|
+
workspace: N,
|
|
156
|
+
issues: Z,
|
|
157
|
+
tabs: M,
|
|
158
|
+
tab: K,
|
|
159
|
+
onTabChange: q,
|
|
160
|
+
focus: J,
|
|
161
|
+
onFocus: (e) => Y(e)
|
|
160
162
|
})
|
|
161
163
|
}),
|
|
162
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ D("section", {
|
|
163
165
|
className: "mt-8",
|
|
164
|
-
children: [
|
|
166
|
+
children: [J && /* @__PURE__ */ D("div", {
|
|
165
167
|
className: "mb-3 flex items-center gap-2 text-sm text-muted-foreground",
|
|
166
168
|
role: "status",
|
|
167
|
-
children: [
|
|
169
|
+
children: [I("issueBreakdown.showing", { count: Q.length }), /* @__PURE__ */ E(b, {
|
|
168
170
|
size: "sm",
|
|
169
171
|
variant: "ghost",
|
|
170
|
-
label:
|
|
171
|
-
icon: /* @__PURE__ */
|
|
172
|
-
onClick: () =>
|
|
172
|
+
label: I("issueBreakdown.showAll"),
|
|
173
|
+
icon: /* @__PURE__ */ E(c, {}),
|
|
174
|
+
onClick: () => Y(null)
|
|
173
175
|
})]
|
|
174
|
-
}),
|
|
176
|
+
}), Q.length === 0 ? /* @__PURE__ */ E(v, { title: I("noIssuesInCycle") }) : /* @__PURE__ */ E(se, {
|
|
175
177
|
size: "fill",
|
|
176
178
|
padding: "none",
|
|
177
179
|
className: "overflow-hidden",
|
|
178
|
-
children: /* @__PURE__ */
|
|
179
|
-
workspace:
|
|
180
|
-
issues:
|
|
180
|
+
children: /* @__PURE__ */ E(ie, {
|
|
181
|
+
workspace: N,
|
|
182
|
+
issues: Q
|
|
181
183
|
})
|
|
182
184
|
})]
|
|
183
185
|
})
|
|
184
186
|
]
|
|
185
|
-
}),
|
|
186
|
-
"aria-label":
|
|
187
|
+
}), Z.length > 0 && /* @__PURE__ */ E("aside", {
|
|
188
|
+
"aria-label": I("issueBreakdown.label"),
|
|
187
189
|
className: "hidden w-80 shrink-0 overflow-y-auto border-l border-border px-4 py-6 xl:block",
|
|
188
|
-
children: /* @__PURE__ */
|
|
189
|
-
workspace:
|
|
190
|
-
issues:
|
|
191
|
-
tabs:
|
|
192
|
-
tab:
|
|
193
|
-
onTabChange:
|
|
194
|
-
focus:
|
|
195
|
-
onFocus: (e) =>
|
|
190
|
+
children: /* @__PURE__ */ E(_, {
|
|
191
|
+
workspace: N,
|
|
192
|
+
issues: Z,
|
|
193
|
+
tabs: M,
|
|
194
|
+
tab: K,
|
|
195
|
+
onTabChange: q,
|
|
196
|
+
focus: J,
|
|
197
|
+
onFocus: (e) => Y(e)
|
|
196
198
|
})
|
|
197
199
|
})]
|
|
198
200
|
})]
|
|
199
201
|
});
|
|
200
202
|
}
|
|
201
|
-
export {
|
|
203
|
+
export { N as component };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { triageQuery as t } from "../../../../lib/triage.js";
|
|
1
|
+
import { triageQuery as e } from "../../../../lib/triage.js";
|
|
3
2
|
// src/routes/$workspace/teams/$key/triage.tsx?tsr-split=loader
|
|
4
|
-
var
|
|
5
|
-
export {
|
|
3
|
+
var t = ({ context: { queryClient: t }, params: { workspace: n, key: r } }) => t.ensureQueryData(e(n, r));
|
|
4
|
+
export { t as loader };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { triageQuery as t } from "../../lib/triage.js";
|
|
1
|
+
import { triageQuery as e } from "../../lib/triage.js";
|
|
3
2
|
// src/routes/$workspace/triage.tsx?tsr-split=loader
|
|
4
|
-
var
|
|
5
|
-
export {
|
|
3
|
+
var t = ({ context: { queryClient: t }, params: { workspace: n } }) => t.ensureQueryData(e(n));
|
|
4
|
+
export { t as loader };
|