@parallelworks/tandem-web 0.141.0 → 0.141.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_virtual/_virtual_i18n/en/common.js +0 -1
- package/_virtual/_virtual_i18n/es/common.js +0 -1
- package/_virtual/_virtual_i18n/ja/common.js +0 -1
- package/_virtual/_virtual_i18n/ko/common.js +0 -1
- package/_virtual/_virtual_i18n/zh/common.js +0 -1
- package/package.json +1 -1
- package/pages/projects.js +6 -3
- package/routes/_workspace/notifications2.js +205 -234
|
@@ -1178,7 +1178,6 @@ var e = {
|
|
|
1178
1178
|
invalid_project_parent: "A project goes under another project of this workspace, never under itself or a project under it, and projects nest at most {max} levels deep."
|
|
1179
1179
|
},
|
|
1180
1180
|
notifications: {
|
|
1181
|
-
alsoHappened: "Also on this issue",
|
|
1182
1181
|
title: "Notifications",
|
|
1183
1182
|
unreadCount: "{count, plural, =0 {All caught up} other {# unread}}",
|
|
1184
1183
|
more: "+{count} more",
|
|
@@ -1178,7 +1178,6 @@ var e = {
|
|
|
1178
1178
|
invalid_project_parent: "Un proyecto va bajo otro proyecto de este espacio de trabajo, nunca bajo sí mismo ni bajo uno de sus subproyectos, y los proyectos se anidan como máximo {max} niveles."
|
|
1179
1179
|
},
|
|
1180
1180
|
notifications: {
|
|
1181
|
-
alsoHappened: "También en esta incidencia",
|
|
1182
1181
|
title: "Notificaciones",
|
|
1183
1182
|
unreadCount: "{count, plural, =0 {Todo al día} one {# sin leer} other {# sin leer}}",
|
|
1184
1183
|
more: "+{count} más",
|
|
@@ -1178,7 +1178,6 @@ var e = {
|
|
|
1178
1178
|
invalid_project_parent: "プロジェクトは、このワークスペースの別のプロジェクトの下に置けます。自分自身や自分の下のプロジェクトの下には置けず、入れ子は最大 {max} 階層までです。"
|
|
1179
1179
|
},
|
|
1180
1180
|
notifications: {
|
|
1181
|
-
alsoHappened: "この課題のその他の動き",
|
|
1182
1181
|
title: "通知",
|
|
1183
1182
|
unreadCount: "{count, plural, =0 {すべて確認済み} other {未読 # 件}}",
|
|
1184
1183
|
more: "他 {count} 件",
|
|
@@ -1178,7 +1178,6 @@ var e = {
|
|
|
1178
1178
|
invalid_project_parent: "프로젝트는 이 워크스페이스의 다른 프로젝트 아래에 둘 수 있으며, 자기 자신이나 그 아래 프로젝트 아래에는 둘 수 없고, 최대 {max}단계까지 중첩됩니다."
|
|
1179
1179
|
},
|
|
1180
1180
|
notifications: {
|
|
1181
|
-
alsoHappened: "이 이슈의 다른 활동",
|
|
1182
1181
|
title: "알림",
|
|
1183
1182
|
unreadCount: "{count, plural, =0 {모두 확인함} other {#개 읽지 않음}}",
|
|
1184
1183
|
more: "+{count}개 더",
|
|
@@ -1178,7 +1178,6 @@ var e = {
|
|
|
1178
1178
|
invalid_project_parent: "项目可以放在此工作区的另一个项目之下,但不能放在自身或其下级项目之下,且最多嵌套 {max} 层。"
|
|
1179
1179
|
},
|
|
1180
1180
|
notifications: {
|
|
1181
|
-
alsoHappened: "此问题的其他动态",
|
|
1182
1181
|
title: "通知",
|
|
1183
1182
|
unreadCount: "{count, plural, =0 {已全部读完} other {# 条未读}}",
|
|
1184
1183
|
more: "还有 {count} 条",
|
package/package.json
CHANGED
package/pages/projects.js
CHANGED
|
@@ -484,7 +484,7 @@ function ge({ workspace: e, projects: n, rowProps: r }) {
|
|
|
484
484
|
/* @__PURE__ */ R("ul", {
|
|
485
485
|
className: "relative",
|
|
486
486
|
children: u.map(({ p: n, start: i, end: a }) => {
|
|
487
|
-
let o = i !== void 0 && a !== void 0, c = o ? m(i) : 0, u = o ? Math.max(m(a + K), c + 24) : 0, d = o && u < s.left, f = o && c > s.left + s.width, p = o ? Math.min(Math.max(m(l) - c, 0), u - c) : 0;
|
|
487
|
+
let o = i !== void 0 && a !== void 0, c = o ? m(i) : 0, u = o ? Math.max(m(a + K), c + 24) : 0, d = o && u < s.left, f = o && c > s.left + s.width, p = o ? Math.min(Math.max(m(l) - c, 0), u - c) : 0, g = Math.min(Math.max(s.left + 8 - c, 0), Math.max(u - c - 80, 0));
|
|
488
488
|
return /* @__PURE__ */ z("li", {
|
|
489
489
|
className: "group flex hover:bg-muted/40",
|
|
490
490
|
style: { height: J },
|
|
@@ -505,8 +505,11 @@ function ge({ workspace: e, projects: n, rowProps: r }) {
|
|
|
505
505
|
width: u - c
|
|
506
506
|
},
|
|
507
507
|
children: [/* @__PURE__ */ R("span", {
|
|
508
|
-
className: "block truncate px-0.5 text-xs font-medium",
|
|
509
|
-
style: {
|
|
508
|
+
className: "block self-start truncate px-0.5 text-xs font-medium",
|
|
509
|
+
style: {
|
|
510
|
+
marginLeft: g,
|
|
511
|
+
maxWidth: Math.max(h - c - g, u - c - g)
|
|
512
|
+
},
|
|
510
513
|
children: n.name
|
|
511
514
|
}), /* @__PURE__ */ z("span", {
|
|
512
515
|
className: "relative block h-6 overflow-hidden rounded-md border border-border",
|
|
@@ -1,28 +1,26 @@
|
|
|
1
1
|
import { usePageTitle as e } from "../../lib/pageTitle.js";
|
|
2
2
|
import { Link as t, useNavigate as n } from "../../lib/router.js";
|
|
3
3
|
import { Route as r } from "./notifications.js";
|
|
4
|
-
import {
|
|
5
|
-
import { ArchiveIcon as
|
|
6
|
-
import { copyItem as
|
|
7
|
-
import { usePeople as
|
|
8
|
-
import { PersonHoverCard as
|
|
9
|
-
import { Editor as
|
|
10
|
-
import { useArchiveNotifications as ee, useReadNotifications as
|
|
11
|
-
import { useShortcuts as
|
|
12
|
-
import { parseApproval as
|
|
13
|
-
import { DecisionCard as
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import { useQuery as H, useSuspenseQuery as oe } from "@tanstack/react-query";
|
|
22
|
-
import { ListFilterMenu as se, useListView as U } from "@parallelworks/ui/list";
|
|
4
|
+
import { issueDecisionsQuery as i, issueQuery as a, notificationsQuery as o, teamsQuery as s } from "../../api/queries.js";
|
|
5
|
+
import { ArchiveIcon as c, CheckIcon as l, FileTextIcon as u, InboxIcon as d, PriorityIcon as f, ProjectIcon as p, StatusIcon as m, usePriorityNames as h } from "../../components/icons.js";
|
|
6
|
+
import { copyItem as g, useLinkItems as _ } from "../../lib/menus.js";
|
|
7
|
+
import { usePeople as v } from "../../lib/people.js";
|
|
8
|
+
import { PersonHoverCard as y } from "../../components/PersonHoverCard.js";
|
|
9
|
+
import { Editor as b } from "../../components/Editor.js";
|
|
10
|
+
import { useArchiveNotifications as ee, useReadNotifications as te, useUnreadNotifications as ne } from "../../lib/notifications.js";
|
|
11
|
+
import { useShortcuts as re } from "../../lib/shortcuts.js";
|
|
12
|
+
import { parseApproval as x } from "../../lib/approval.js";
|
|
13
|
+
import { DecisionCard as S } from "../../components/AgentWork.js";
|
|
14
|
+
import { plainText as C } from "../../lib/plainText.js";
|
|
15
|
+
import { Avatar as w, Button as T, Card as E, EmptyState as D, IconButton as O, RelativeTime as k, buttonClasses as A, menuDivider as j, useOpenMenu as M } from "@parallelworks/ui";
|
|
16
|
+
import { useEffect as ie, useMemo as N, useRef as P, useState as F } from "react";
|
|
17
|
+
import { useTranslations as I } from "use-intl";
|
|
18
|
+
import { Fragment as L, jsx as R, jsxs as z } from "react/jsx-runtime";
|
|
19
|
+
import { useQuery as B, useSuspenseQuery as ae } from "@tanstack/react-query";
|
|
20
|
+
import { ListFilterMenu as oe, useListView as V } from "@parallelworks/ui/list";
|
|
23
21
|
// src/routes/$workspace/notifications.tsx?tsr-split=component
|
|
24
|
-
var
|
|
25
|
-
function
|
|
22
|
+
var H = (...e) => e.filter(Boolean).join(" ");
|
|
23
|
+
function se(e, t) {
|
|
26
24
|
let n = /* @__PURE__ */ new Map();
|
|
27
25
|
for (let r of t) {
|
|
28
26
|
let t = r.projectId ? "project" : r.documentId ? "doc" : "issue", i = r.projectId ? `project:${r.projectId}` : r.documentId ? `doc:${r.documentId}` : r.identifier, a = n.get(i);
|
|
@@ -42,7 +40,7 @@ function ce(e, t) {
|
|
|
42
40
|
}
|
|
43
41
|
return [...n.values()];
|
|
44
42
|
}
|
|
45
|
-
var
|
|
43
|
+
var U = {
|
|
46
44
|
decisions: ["decision_requested"],
|
|
47
45
|
assigned: ["assigned"],
|
|
48
46
|
comments: ["commented"],
|
|
@@ -51,9 +49,9 @@ var G = {
|
|
|
51
49
|
updates: ["update_posted"],
|
|
52
50
|
reminders: ["reminder"],
|
|
53
51
|
mentions: ["mentioned"]
|
|
54
|
-
},
|
|
55
|
-
function
|
|
56
|
-
let n =
|
|
52
|
+
}, W = (e) => e.reason === "reminder" && e.excerpt ? /* @__PURE__ */ new Date(`${e.excerpt}T00:00:00`) : /* @__PURE__ */ new Date(0), G = (e) => e.slice(0, e.lastIndexOf("-"));
|
|
53
|
+
function ce(e, t) {
|
|
54
|
+
let n = I("notifications"), r = N(() => {
|
|
57
55
|
let e = [{
|
|
58
56
|
key: "state",
|
|
59
57
|
label: n("show"),
|
|
@@ -65,11 +63,11 @@ function le(e, t) {
|
|
|
65
63
|
}, {
|
|
66
64
|
key: "kind",
|
|
67
65
|
label: n("kind"),
|
|
68
|
-
options: Object.keys(
|
|
66
|
+
options: Object.keys(U).map((e) => ({
|
|
69
67
|
value: e,
|
|
70
68
|
label: n(`kinds.${e}`)
|
|
71
69
|
})),
|
|
72
|
-
matches: (e, t) => t.some((t) =>
|
|
70
|
+
matches: (e, t) => t.some((t) => U[t].includes(e.reason))
|
|
73
71
|
}], r = t.filter((e) => !e.archivedAt);
|
|
74
72
|
return r.length > 1 && e.push({
|
|
75
73
|
key: "team",
|
|
@@ -78,120 +76,120 @@ function le(e, t) {
|
|
|
78
76
|
value: e.key,
|
|
79
77
|
label: e.name
|
|
80
78
|
})),
|
|
81
|
-
matches: (e, t) => !!e.identifier && t.includes(
|
|
79
|
+
matches: (e, t) => !!e.identifier && t.includes(G(e.identifier))
|
|
82
80
|
}), e;
|
|
83
81
|
}, [n, t]);
|
|
84
|
-
return
|
|
82
|
+
return V({
|
|
85
83
|
storageKey: `notifications:${e}`,
|
|
86
84
|
columns: [],
|
|
87
85
|
facets: r
|
|
88
86
|
});
|
|
89
87
|
}
|
|
90
|
-
function
|
|
91
|
-
let { workspace: t } = r.useParams(), { issue: i } = r.useSearch(), a =
|
|
88
|
+
function K() {
|
|
89
|
+
let { workspace: t } = r.useParams(), { issue: i } = r.useSearch(), a = I("notifications"), u = n(), { data: { notifications: f, unread: p } } = ae(o(t));
|
|
92
90
|
e(p > 0 ? `${a("title")} (${p})` : a("title"));
|
|
93
|
-
let m =
|
|
94
|
-
let e =
|
|
95
|
-
return
|
|
91
|
+
let m = te(t), h = ne(t), g = ee(t), { data: _ = [] } = B(s(t)), v = ce(t, _), y = v.activeFilterCount > 0, b = (v.filters.state ?? []).includes("unread"), x = v.filters.kind ?? [], S = v.filters.team ?? [], C = N(() => {
|
|
92
|
+
let e = f.filter((e) => (x.length === 0 || x.some((t) => U[t]?.includes(e.reason))) && (S.length === 0 || !!e.identifier && S.includes(G(e.identifier))));
|
|
93
|
+
return se(t, e).filter((e) => !b || e.unread.length > 0 || e.key === i);
|
|
96
94
|
}, [
|
|
97
95
|
t,
|
|
98
|
-
|
|
96
|
+
f,
|
|
99
97
|
b,
|
|
100
98
|
x,
|
|
101
|
-
|
|
99
|
+
S,
|
|
102
100
|
i
|
|
103
|
-
]),
|
|
104
|
-
|
|
101
|
+
]), w = C.findIndex((e) => e.key === i), E = w >= 0 ? C[w] : void 0, [k, A] = F(/* @__PURE__ */ new Set()), j = P(null), M = N(() => C.filter((e) => k.has(e.key)), [C, k]), V = (e) => {
|
|
102
|
+
u({
|
|
105
103
|
to: "/$workspace/notifications",
|
|
106
104
|
params: { workspace: t },
|
|
107
105
|
search: e ? { issue: e.key } : {},
|
|
108
106
|
replace: !0
|
|
109
107
|
}), e && e.unread.length > 0 && m.mutate(e.unread);
|
|
110
|
-
},
|
|
108
|
+
}, W = (e) => {
|
|
111
109
|
let t = e.flatMap((e) => e.unread);
|
|
112
110
|
t.length > 0 ? m.mutate(t) : h.mutate(e.flatMap((e) => e.items.map((e) => e.id)));
|
|
113
|
-
},
|
|
114
|
-
if (g.mutate(e.flatMap((e) => e.items.map((e) => e.id))),
|
|
115
|
-
let t =
|
|
116
|
-
|
|
111
|
+
}, K = (e) => {
|
|
112
|
+
if (g.mutate(e.flatMap((e) => e.items.map((e) => e.id))), A(/* @__PURE__ */ new Set()), E && e.includes(E)) {
|
|
113
|
+
let t = C.filter((t) => !e.includes(t));
|
|
114
|
+
V(t[t.findIndex((e) => C.indexOf(e) > w)] ?? t.at(-1));
|
|
117
115
|
}
|
|
118
|
-
},
|
|
116
|
+
}, q = (e) => u({ to: e.href }), J = M.length > 0 ? M : E ? [E] : [], Y = (e) => A((t) => {
|
|
119
117
|
let n = new Set(t);
|
|
120
118
|
return n.has(e.key) ? n.delete(e.key) : n.add(e.key), n;
|
|
121
|
-
}),
|
|
119
|
+
}), X = (e, t) => {
|
|
122
120
|
let [n, r] = e < t ? [e, t] : [t, e];
|
|
123
|
-
|
|
124
|
-
}, X = (e, t) => {
|
|
125
|
-
let n = w.indexOf(t);
|
|
126
|
-
e.metaKey || e.ctrlKey ? (J(t), A.current = n) : e.shiftKey ? Y(A.current ?? (T >= 0 ? T : n), n) : (O(/* @__PURE__ */ new Set()), A.current = n, P(t));
|
|
121
|
+
A(new Set(C.slice(n, r + 1).map((e) => e.key)));
|
|
127
122
|
}, Z = (e, t) => {
|
|
128
|
-
let n =
|
|
129
|
-
|
|
123
|
+
let n = C.indexOf(t);
|
|
124
|
+
e.metaKey || e.ctrlKey ? (Y(t), j.current = n) : e.shiftKey ? X(j.current ?? (w >= 0 ? w : n), n) : (A(/* @__PURE__ */ new Set()), j.current = n, V(t));
|
|
125
|
+
}, Q = (e, t) => {
|
|
126
|
+
let n = Math.min(Math.max(w + e, 0), C.length - 1);
|
|
127
|
+
t && ((j.current === null || k.size === 0) && (j.current = Math.max(w, 0)), X(j.current, n)), V(C[n]);
|
|
130
128
|
};
|
|
131
|
-
|
|
132
|
-
j: () =>
|
|
133
|
-
k: () =>
|
|
134
|
-
J: () =>
|
|
135
|
-
K: () =>
|
|
136
|
-
ArrowDown: (e) =>
|
|
137
|
-
ArrowUp: (e) =>
|
|
129
|
+
re({
|
|
130
|
+
j: () => Q(1, !1),
|
|
131
|
+
k: () => Q(-1, !1),
|
|
132
|
+
J: () => Q(1, !0),
|
|
133
|
+
K: () => Q(-1, !0),
|
|
134
|
+
ArrowDown: (e) => Q(1, e.shiftKey),
|
|
135
|
+
ArrowUp: (e) => Q(-1, e.shiftKey),
|
|
138
136
|
x: () => {
|
|
139
|
-
E && (
|
|
137
|
+
E && (Y(E), j.current = w);
|
|
140
138
|
},
|
|
141
|
-
Enter: () => E &&
|
|
142
|
-
e: () =>
|
|
143
|
-
u: () =>
|
|
144
|
-
Escape: () =>
|
|
145
|
-
}),
|
|
139
|
+
Enter: () => E && q(E),
|
|
140
|
+
e: () => J.length > 0 && K(J),
|
|
141
|
+
u: () => J.length > 0 && W(J),
|
|
142
|
+
Escape: () => k.size > 0 ? A(/* @__PURE__ */ new Set()) : V(void 0)
|
|
143
|
+
}), ie(() => {
|
|
146
144
|
document.getElementById(`inbox-${E?.key}`)?.scrollIntoView({ block: "nearest" });
|
|
147
145
|
}, [E]);
|
|
148
|
-
let
|
|
149
|
-
select:
|
|
150
|
-
toggleRead:
|
|
151
|
-
archiveGroups:
|
|
152
|
-
openIssue:
|
|
153
|
-
clickRow:
|
|
154
|
-
targetsOf: (e) =>
|
|
146
|
+
let $ = {
|
|
147
|
+
select: V,
|
|
148
|
+
toggleRead: W,
|
|
149
|
+
archiveGroups: K,
|
|
150
|
+
openIssue: q,
|
|
151
|
+
clickRow: Z,
|
|
152
|
+
targetsOf: (e) => k.has(e.key) ? M : (A(/* @__PURE__ */ new Set()), [e])
|
|
155
153
|
};
|
|
156
|
-
return /* @__PURE__ */
|
|
154
|
+
return /* @__PURE__ */ z("div", {
|
|
157
155
|
className: "flex h-full flex-col",
|
|
158
156
|
children: [
|
|
159
|
-
/* @__PURE__ */
|
|
157
|
+
/* @__PURE__ */ z("header", {
|
|
160
158
|
className: "@container flex min-h-12 shrink-0 flex-wrap items-center gap-2 border-b border-border px-4 py-2 md:px-5",
|
|
161
159
|
children: [
|
|
162
|
-
/* @__PURE__ */
|
|
160
|
+
/* @__PURE__ */ R("h1", {
|
|
163
161
|
className: "text-sm font-semibold",
|
|
164
162
|
children: a("title")
|
|
165
163
|
}),
|
|
166
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ R("span", {
|
|
167
165
|
className: "min-w-0 flex-1 truncate text-xs text-muted-foreground",
|
|
168
166
|
children: a("unreadCount", { count: p })
|
|
169
167
|
}),
|
|
170
|
-
/* @__PURE__ */
|
|
171
|
-
p > 0 && /* @__PURE__ */
|
|
168
|
+
/* @__PURE__ */ R(oe, { view: v }),
|
|
169
|
+
p > 0 && /* @__PURE__ */ z(L, { children: [/* @__PURE__ */ R(T, {
|
|
172
170
|
type: "button",
|
|
173
171
|
size: "sm",
|
|
174
172
|
loading: m.isPending,
|
|
175
173
|
onClick: () => m.mutate(void 0),
|
|
176
174
|
className: "@max-3xl:hidden",
|
|
177
175
|
children: a("markAllRead")
|
|
178
|
-
}), /* @__PURE__ */
|
|
179
|
-
icon: /* @__PURE__ */
|
|
176
|
+
}), /* @__PURE__ */ R(O, {
|
|
177
|
+
icon: /* @__PURE__ */ R(l, {}),
|
|
180
178
|
label: a("markAllRead"),
|
|
181
179
|
size: "sm",
|
|
182
180
|
disabled: m.isPending,
|
|
183
181
|
onClick: () => m.mutate(void 0),
|
|
184
182
|
className: "@3xl:hidden"
|
|
185
183
|
})] }),
|
|
186
|
-
|
|
184
|
+
C.some((e) => e.unread.length === 0) && /* @__PURE__ */ z(L, { children: [/* @__PURE__ */ R(T, {
|
|
187
185
|
type: "button",
|
|
188
186
|
size: "sm",
|
|
189
187
|
loading: g.isPending,
|
|
190
188
|
onClick: () => g.mutate(void 0),
|
|
191
189
|
className: "@max-3xl:hidden",
|
|
192
190
|
children: a("archiveRead")
|
|
193
|
-
}), /* @__PURE__ */
|
|
194
|
-
icon: /* @__PURE__ */
|
|
191
|
+
}), /* @__PURE__ */ R(O, {
|
|
192
|
+
icon: /* @__PURE__ */ R(c, {}),
|
|
195
193
|
label: a("archiveRead"),
|
|
196
194
|
size: "sm",
|
|
197
195
|
disabled: g.isPending,
|
|
@@ -200,44 +198,44 @@ function J() {
|
|
|
200
198
|
})] })
|
|
201
199
|
]
|
|
202
200
|
}),
|
|
203
|
-
|
|
201
|
+
M.length > 0 && /* @__PURE__ */ z("div", {
|
|
204
202
|
className: "flex min-h-9 shrink-0 flex-wrap items-center gap-x-3 gap-y-1 border-b border-border bg-human-soft px-4 py-1 text-xs md:px-5",
|
|
205
203
|
children: [
|
|
206
|
-
/* @__PURE__ */
|
|
204
|
+
/* @__PURE__ */ R("span", {
|
|
207
205
|
className: "font-medium text-human",
|
|
208
|
-
children: a("selected", { count:
|
|
206
|
+
children: a("selected", { count: M.length })
|
|
209
207
|
}),
|
|
210
|
-
|
|
208
|
+
M.length < C.length && /* @__PURE__ */ R("button", {
|
|
211
209
|
type: "button",
|
|
212
|
-
onClick: () =>
|
|
210
|
+
onClick: () => A(new Set(C.map((e) => e.key))),
|
|
213
211
|
className: "hover:underline",
|
|
214
|
-
children: a("selectAll", { count:
|
|
212
|
+
children: a("selectAll", { count: C.length })
|
|
215
213
|
}),
|
|
216
|
-
/* @__PURE__ */
|
|
214
|
+
/* @__PURE__ */ z("div", {
|
|
217
215
|
className: "ml-auto flex items-center gap-1.5",
|
|
218
216
|
children: [
|
|
219
|
-
/* @__PURE__ */
|
|
217
|
+
/* @__PURE__ */ R(T, {
|
|
220
218
|
type: "button",
|
|
221
219
|
size: "sm",
|
|
222
|
-
onClick: () => m.mutate(
|
|
223
|
-
disabled:
|
|
220
|
+
onClick: () => m.mutate(M.flatMap((e) => e.unread)),
|
|
221
|
+
disabled: M.every((e) => e.unread.length === 0),
|
|
224
222
|
children: a("markRead")
|
|
225
223
|
}),
|
|
226
|
-
/* @__PURE__ */
|
|
224
|
+
/* @__PURE__ */ R(T, {
|
|
227
225
|
type: "button",
|
|
228
226
|
size: "sm",
|
|
229
|
-
onClick: () => h.mutate(
|
|
227
|
+
onClick: () => h.mutate(M.flatMap((e) => e.items.map((e) => e.id))),
|
|
230
228
|
children: a("markUnread")
|
|
231
229
|
}),
|
|
232
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ R(T, {
|
|
233
231
|
type: "button",
|
|
234
232
|
size: "sm",
|
|
235
|
-
onClick: () =>
|
|
233
|
+
onClick: () => K(M),
|
|
236
234
|
children: a("archive")
|
|
237
235
|
}),
|
|
238
|
-
/* @__PURE__ */
|
|
236
|
+
/* @__PURE__ */ R("button", {
|
|
239
237
|
type: "button",
|
|
240
|
-
onClick: () =>
|
|
238
|
+
onClick: () => A(/* @__PURE__ */ new Set()),
|
|
241
239
|
className: "shrink-0 px-1 hover:underline",
|
|
242
240
|
children: a("clear")
|
|
243
241
|
})
|
|
@@ -245,43 +243,43 @@ function J() {
|
|
|
245
243
|
})
|
|
246
244
|
]
|
|
247
245
|
}),
|
|
248
|
-
|
|
246
|
+
C.length === 0 ? /* @__PURE__ */ R("div", {
|
|
249
247
|
className: "min-h-0 flex-1 overflow-y-auto p-6",
|
|
250
|
-
children: y ? /* @__PURE__ */
|
|
251
|
-
icon: /* @__PURE__ */
|
|
248
|
+
children: y ? /* @__PURE__ */ R(D, {
|
|
249
|
+
icon: /* @__PURE__ */ R(d, {}),
|
|
252
250
|
title: a("noneMatch"),
|
|
253
|
-
action: /* @__PURE__ */
|
|
251
|
+
action: /* @__PURE__ */ R(T, {
|
|
254
252
|
type: "button",
|
|
255
253
|
size: "sm",
|
|
256
254
|
onClick: v.clearFilters,
|
|
257
255
|
children: a("showEverything")
|
|
258
256
|
})
|
|
259
|
-
}) : /* @__PURE__ */
|
|
260
|
-
icon: /* @__PURE__ */
|
|
257
|
+
}) : /* @__PURE__ */ R(D, {
|
|
258
|
+
icon: /* @__PURE__ */ R(d, {}),
|
|
261
259
|
title: a("emptyTitle"),
|
|
262
260
|
description: a("emptyDescription")
|
|
263
261
|
})
|
|
264
|
-
}) : /* @__PURE__ */
|
|
262
|
+
}) : /* @__PURE__ */ z("div", {
|
|
265
263
|
className: "flex min-h-0 flex-1",
|
|
266
|
-
children: [/* @__PURE__ */
|
|
264
|
+
children: [/* @__PURE__ */ R("ul", {
|
|
267
265
|
"aria-label": a("title"),
|
|
268
|
-
className:
|
|
269
|
-
children:
|
|
266
|
+
className: H("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", E ? "hidden" : "flex"),
|
|
267
|
+
children: C.map((e) => /* @__PURE__ */ R(le, {
|
|
270
268
|
workspace: t,
|
|
271
269
|
group: e,
|
|
272
270
|
selected: e === E,
|
|
273
|
-
picked:
|
|
274
|
-
actions:
|
|
271
|
+
picked: k.has(e.key),
|
|
272
|
+
actions: $
|
|
275
273
|
}, e.key))
|
|
276
|
-
}), /* @__PURE__ */
|
|
277
|
-
className:
|
|
278
|
-
children: E ? /* @__PURE__ */
|
|
274
|
+
}), /* @__PURE__ */ R("div", {
|
|
275
|
+
className: H("min-w-0 flex-1 overflow-y-auto md:block", E ? "block" : "hidden"),
|
|
276
|
+
children: E ? /* @__PURE__ */ R(ue, {
|
|
279
277
|
workspace: t,
|
|
280
278
|
group: E,
|
|
281
|
-
actions:
|
|
282
|
-
}) : /* @__PURE__ */
|
|
279
|
+
actions: $
|
|
280
|
+
}) : /* @__PURE__ */ R("div", {
|
|
283
281
|
className: "px-6 py-24",
|
|
284
|
-
children: /* @__PURE__ */
|
|
282
|
+
children: /* @__PURE__ */ R(D, {
|
|
285
283
|
title: a("noneSelected"),
|
|
286
284
|
description: a("shortcuts")
|
|
287
285
|
})
|
|
@@ -291,8 +289,8 @@ function J() {
|
|
|
291
289
|
]
|
|
292
290
|
});
|
|
293
291
|
}
|
|
294
|
-
function
|
|
295
|
-
let t =
|
|
292
|
+
function q(e) {
|
|
293
|
+
let t = I("notifications"), n = _();
|
|
296
294
|
return (r) => {
|
|
297
295
|
let [i] = r;
|
|
298
296
|
return [
|
|
@@ -307,22 +305,22 @@ function Y(e) {
|
|
|
307
305
|
onClick: () => e.archiveGroups(r)
|
|
308
306
|
},
|
|
309
307
|
...r.length === 1 && i ? [
|
|
310
|
-
|
|
308
|
+
j,
|
|
311
309
|
...n(i.href),
|
|
312
|
-
...i.identifier ? [
|
|
310
|
+
...i.identifier ? [g(t("copyId"), i.identifier)] : []
|
|
313
311
|
] : []
|
|
314
312
|
];
|
|
315
313
|
};
|
|
316
314
|
}
|
|
317
|
-
function
|
|
318
|
-
let { actorName: t } =
|
|
315
|
+
function J(e) {
|
|
316
|
+
let { actorName: t } = v(e);
|
|
319
317
|
return (e) => e.actor.kind === "agent" && e.agentName ? e.agentName : t(e.actor);
|
|
320
318
|
}
|
|
321
|
-
function
|
|
322
|
-
let o =
|
|
323
|
-
return /* @__PURE__ */
|
|
319
|
+
function le({ workspace: e, group: n, selected: r, picked: i, actions: a }) {
|
|
320
|
+
let o = I("notifications"), { avatarOf: s } = v(e), c = J(e), l = M(), u = q(a), d = n.items[0], f = c(d), p = n.unread.length > 0;
|
|
321
|
+
return /* @__PURE__ */ R("li", {
|
|
324
322
|
id: `inbox-${n.key}`,
|
|
325
|
-
children: /* @__PURE__ */
|
|
323
|
+
children: /* @__PURE__ */ z(t, {
|
|
326
324
|
to: "/$workspace/notifications",
|
|
327
325
|
params: { workspace: e },
|
|
328
326
|
search: { issue: n.key },
|
|
@@ -332,59 +330,59 @@ function ue({ workspace: e, group: n, selected: r, picked: i, actions: a }) {
|
|
|
332
330
|
},
|
|
333
331
|
onContextMenu: (e) => l(e, u(a.targetsOf(n))),
|
|
334
332
|
"aria-current": r || void 0,
|
|
335
|
-
className:
|
|
333
|
+
className: H("relative flex gap-3 px-2 py-2.5 select-none", i ? "bg-human-soft" : H("rounded-md hover:bg-muted", r && "bg-muted")),
|
|
336
334
|
children: [
|
|
337
|
-
i && /* @__PURE__ */
|
|
335
|
+
i && /* @__PURE__ */ z(L, { children: [/* @__PURE__ */ R("span", {
|
|
338
336
|
className: "absolute inset-y-0 left-0 w-0.5 bg-human",
|
|
339
337
|
"aria-hidden": !0
|
|
340
|
-
}), /* @__PURE__ */
|
|
338
|
+
}), /* @__PURE__ */ R("span", {
|
|
341
339
|
className: "sr-only",
|
|
342
340
|
children: o("picked")
|
|
343
341
|
})] }),
|
|
344
|
-
/* @__PURE__ */
|
|
342
|
+
/* @__PURE__ */ R("span", {
|
|
345
343
|
className: "flex w-2 shrink-0 justify-center pt-2.5",
|
|
346
|
-
children: p && /* @__PURE__ */
|
|
344
|
+
children: p && /* @__PURE__ */ R("span", {
|
|
347
345
|
role: "img",
|
|
348
346
|
"aria-label": o("unread"),
|
|
349
347
|
className: "size-2 rounded-full bg-primary"
|
|
350
348
|
})
|
|
351
349
|
}),
|
|
352
|
-
/* @__PURE__ */
|
|
353
|
-
className:
|
|
354
|
-
children: /* @__PURE__ */
|
|
350
|
+
/* @__PURE__ */ R("span", {
|
|
351
|
+
className: H("h-fit shrink-0 rounded-full", i && "ring-1 ring-human/40"),
|
|
352
|
+
children: /* @__PURE__ */ R(w, {
|
|
355
353
|
name: f,
|
|
356
354
|
src: s(d.actor.kind, d.actor.handle),
|
|
357
355
|
size: "sm",
|
|
358
356
|
decorative: !0
|
|
359
357
|
})
|
|
360
358
|
}),
|
|
361
|
-
/* @__PURE__ */
|
|
359
|
+
/* @__PURE__ */ z("span", {
|
|
362
360
|
className: "min-w-0 flex-1",
|
|
363
|
-
children: [/* @__PURE__ */
|
|
361
|
+
children: [/* @__PURE__ */ z("span", {
|
|
364
362
|
className: "flex items-baseline gap-2 text-sm",
|
|
365
363
|
children: [
|
|
366
|
-
/* @__PURE__ */
|
|
367
|
-
/* @__PURE__ */
|
|
368
|
-
className:
|
|
364
|
+
/* @__PURE__ */ R($, { group: n }),
|
|
365
|
+
/* @__PURE__ */ R("span", {
|
|
366
|
+
className: H("flex-1 truncate", p && "font-medium"),
|
|
369
367
|
children: n.issueTitle
|
|
370
368
|
}),
|
|
371
|
-
/* @__PURE__ */
|
|
369
|
+
/* @__PURE__ */ R(k, {
|
|
372
370
|
value: d.createdAt,
|
|
373
371
|
format: "compact",
|
|
374
372
|
exact: "medium",
|
|
375
373
|
className: "shrink-0 text-xs text-muted-foreground"
|
|
376
374
|
})
|
|
377
375
|
]
|
|
378
|
-
}), /* @__PURE__ */
|
|
376
|
+
}), /* @__PURE__ */ z("span", {
|
|
379
377
|
className: "mt-0.5 flex gap-2 text-xs text-muted-foreground",
|
|
380
|
-
children: [/* @__PURE__ */
|
|
378
|
+
children: [/* @__PURE__ */ z("span", {
|
|
381
379
|
className: "flex-1 truncate",
|
|
382
380
|
children: [o(d.reason, {
|
|
383
381
|
actor: f,
|
|
384
382
|
agent: d.agentName ?? f,
|
|
385
|
-
date:
|
|
386
|
-
}), d.excerpt && d.reason !== "reminder" && /* @__PURE__ */
|
|
387
|
-
}), n.items.length > 1 && /* @__PURE__ */
|
|
383
|
+
date: W(d)
|
|
384
|
+
}), d.excerpt && d.reason !== "reminder" && /* @__PURE__ */ z(L, { children: [": ", /* @__PURE__ */ R(Z, { text: d.excerpt })] })]
|
|
385
|
+
}), n.items.length > 1 && /* @__PURE__ */ R("span", {
|
|
388
386
|
className: "shrink-0",
|
|
389
387
|
children: o("more", { count: n.items.length - 1 })
|
|
390
388
|
})]
|
|
@@ -394,82 +392,82 @@ function ue({ workspace: e, group: n, selected: r, picked: i, actions: a }) {
|
|
|
394
392
|
})
|
|
395
393
|
});
|
|
396
394
|
}
|
|
397
|
-
function
|
|
398
|
-
let { data: n } =
|
|
399
|
-
return n ? /* @__PURE__ */
|
|
395
|
+
function Y({ workspace: e, identifier: t }) {
|
|
396
|
+
let { data: n } = B(a(e, t)), r = h(), { nameOf: i, avatarOf: o } = v(e);
|
|
397
|
+
return n ? /* @__PURE__ */ z("section", {
|
|
400
398
|
className: "mt-5 rounded-lg border border-border px-4 py-3",
|
|
401
|
-
children: [/* @__PURE__ */
|
|
399
|
+
children: [/* @__PURE__ */ z("div", {
|
|
402
400
|
className: "flex flex-wrap items-center gap-x-4 gap-y-1 text-xs text-muted-foreground",
|
|
403
401
|
children: [
|
|
404
|
-
/* @__PURE__ */
|
|
402
|
+
/* @__PURE__ */ z("span", {
|
|
405
403
|
className: "inline-flex items-center gap-1.5",
|
|
406
|
-
children: [/* @__PURE__ */
|
|
404
|
+
children: [/* @__PURE__ */ R(m, { category: n.status.category }), n.status.name]
|
|
407
405
|
}),
|
|
408
|
-
n.priority > 0 && /* @__PURE__ */
|
|
406
|
+
n.priority > 0 && /* @__PURE__ */ z("span", {
|
|
409
407
|
className: "inline-flex items-center gap-1.5",
|
|
410
|
-
children: [/* @__PURE__ */
|
|
408
|
+
children: [/* @__PURE__ */ R(f, { priority: n.priority }), r[n.priority]]
|
|
411
409
|
}),
|
|
412
|
-
n.assignees.map((e) => /* @__PURE__ */
|
|
410
|
+
n.assignees.map((e) => /* @__PURE__ */ z("span", {
|
|
413
411
|
className: "inline-flex items-center gap-1.5",
|
|
414
|
-
children: [/* @__PURE__ */
|
|
412
|
+
children: [/* @__PURE__ */ R(w, {
|
|
415
413
|
name: i(e.kind, e.handle),
|
|
416
|
-
src:
|
|
414
|
+
src: o(e.kind, e.handle),
|
|
417
415
|
size: "xs",
|
|
418
416
|
decorative: !0
|
|
419
417
|
}), i(e.kind, e.handle)]
|
|
420
418
|
}, `${e.kind}:${e.handle}`))
|
|
421
419
|
]
|
|
422
|
-
}), n.body.trim() && /* @__PURE__ */
|
|
420
|
+
}), n.body.trim() && /* @__PURE__ */ R("div", {
|
|
423
421
|
className: "mt-3 max-h-72 overflow-y-auto text-sm",
|
|
424
|
-
children: /* @__PURE__ */
|
|
422
|
+
children: /* @__PURE__ */ R(b, {
|
|
425
423
|
value: n.body,
|
|
426
424
|
editable: !1
|
|
427
425
|
})
|
|
428
426
|
})]
|
|
429
427
|
}) : null;
|
|
430
428
|
}
|
|
431
|
-
function
|
|
432
|
-
let i =
|
|
433
|
-
return /* @__PURE__ */
|
|
429
|
+
function ue({ workspace: e, group: n, actions: r }) {
|
|
430
|
+
let i = I("notifications"), { avatarOf: a } = v(e), o = J(e), s = M(), c = q(r);
|
|
431
|
+
return /* @__PURE__ */ z("article", {
|
|
434
432
|
className: "w-full px-4 py-5 md:px-8",
|
|
435
433
|
onContextMenu: (e) => s(e, c([n])),
|
|
436
434
|
children: [
|
|
437
|
-
/* @__PURE__ */
|
|
435
|
+
/* @__PURE__ */ R("button", {
|
|
438
436
|
type: "button",
|
|
439
437
|
onClick: () => r.select(void 0),
|
|
440
438
|
className: "mb-3 text-xs text-muted-foreground hover:text-foreground md:hidden",
|
|
441
439
|
children: i("back")
|
|
442
440
|
}),
|
|
443
|
-
/* @__PURE__ */
|
|
441
|
+
/* @__PURE__ */ R("p", {
|
|
444
442
|
className: "text-xs text-muted-foreground",
|
|
445
|
-
children: /* @__PURE__ */
|
|
443
|
+
children: /* @__PURE__ */ R($, { group: n })
|
|
446
444
|
}),
|
|
447
|
-
/* @__PURE__ */
|
|
445
|
+
/* @__PURE__ */ R("h2", {
|
|
448
446
|
className: "mt-0.5 text-sm font-semibold",
|
|
449
|
-
children: /* @__PURE__ */
|
|
447
|
+
children: /* @__PURE__ */ R(t, {
|
|
450
448
|
to: n.href,
|
|
451
449
|
className: "hover:underline",
|
|
452
450
|
children: n.issueTitle
|
|
453
451
|
})
|
|
454
452
|
}),
|
|
455
|
-
/* @__PURE__ */
|
|
453
|
+
/* @__PURE__ */ z("div", {
|
|
456
454
|
className: "mt-3 flex flex-wrap gap-2",
|
|
457
455
|
children: [
|
|
458
|
-
/* @__PURE__ */
|
|
456
|
+
/* @__PURE__ */ R(t, {
|
|
459
457
|
to: n.href,
|
|
460
|
-
className:
|
|
458
|
+
className: A({
|
|
461
459
|
variant: "primary",
|
|
462
460
|
size: "sm"
|
|
463
461
|
}),
|
|
464
462
|
children: i(n.kind === "project" ? "openProject" : n.kind === "doc" ? "openDoc" : "openIssue")
|
|
465
463
|
}),
|
|
466
|
-
/* @__PURE__ */
|
|
464
|
+
/* @__PURE__ */ R(T, {
|
|
467
465
|
type: "button",
|
|
468
466
|
size: "sm",
|
|
469
467
|
onClick: () => r.toggleRead([n]),
|
|
470
468
|
children: n.unread.length > 0 ? i("markRead") : i("markUnread")
|
|
471
469
|
}),
|
|
472
|
-
/* @__PURE__ */
|
|
470
|
+
/* @__PURE__ */ R(T, {
|
|
473
471
|
type: "button",
|
|
474
472
|
size: "sm",
|
|
475
473
|
onClick: () => r.archiveGroups([n]),
|
|
@@ -477,138 +475,111 @@ function de({ workspace: e, group: n, actions: r }) {
|
|
|
477
475
|
})
|
|
478
476
|
]
|
|
479
477
|
}),
|
|
480
|
-
n.identifier && /* @__PURE__ */
|
|
478
|
+
n.identifier && /* @__PURE__ */ z(L, { children: [/* @__PURE__ */ R(Y, {
|
|
481
479
|
workspace: e,
|
|
482
480
|
identifier: n.identifier
|
|
483
|
-
}), /* @__PURE__ */
|
|
481
|
+
}), /* @__PURE__ */ R(Q, {
|
|
484
482
|
workspace: e,
|
|
485
483
|
identifier: n.identifier
|
|
486
484
|
})] }),
|
|
487
|
-
/* @__PURE__ */
|
|
485
|
+
/* @__PURE__ */ R(E, {
|
|
488
486
|
size: "fill",
|
|
489
487
|
padding: "none",
|
|
490
488
|
divided: !0,
|
|
491
489
|
interactive: !1,
|
|
492
|
-
render: /* @__PURE__ */
|
|
490
|
+
render: /* @__PURE__ */ R("ol", {}),
|
|
493
491
|
className: "mt-5 overflow-hidden",
|
|
494
492
|
children: n.items.map((t) => {
|
|
495
493
|
let n = o(t);
|
|
496
|
-
return /* @__PURE__ */
|
|
494
|
+
return /* @__PURE__ */ z("li", {
|
|
497
495
|
className: "flex gap-3 px-3 py-3",
|
|
498
|
-
children: [/* @__PURE__ */
|
|
496
|
+
children: [/* @__PURE__ */ R(y, {
|
|
499
497
|
workspace: e,
|
|
500
498
|
kind: t.actor.kind,
|
|
501
499
|
handle: t.actor.handle,
|
|
502
500
|
className: "inline-flex shrink-0 self-start",
|
|
503
|
-
children: /* @__PURE__ */
|
|
501
|
+
children: /* @__PURE__ */ R(w, {
|
|
504
502
|
name: n,
|
|
505
503
|
src: a(t.actor.kind, t.actor.handle),
|
|
506
504
|
size: "sm"
|
|
507
505
|
})
|
|
508
|
-
}), /* @__PURE__ */
|
|
506
|
+
}), /* @__PURE__ */ z("div", {
|
|
509
507
|
className: "min-w-0 flex-1",
|
|
510
|
-
children: [/* @__PURE__ */
|
|
508
|
+
children: [/* @__PURE__ */ z("p", {
|
|
511
509
|
className: "flex items-baseline gap-2 text-sm",
|
|
512
|
-
children: [/* @__PURE__ */
|
|
513
|
-
className:
|
|
510
|
+
children: [/* @__PURE__ */ R("span", {
|
|
511
|
+
className: H("flex-1", !t.readAt && "font-medium"),
|
|
514
512
|
children: i(t.reason, {
|
|
515
513
|
actor: n,
|
|
516
514
|
agent: t.agentName ?? n,
|
|
517
|
-
date:
|
|
515
|
+
date: W(t)
|
|
518
516
|
})
|
|
519
|
-
}), /* @__PURE__ */
|
|
517
|
+
}), /* @__PURE__ */ R(k, {
|
|
520
518
|
value: t.createdAt,
|
|
521
519
|
format: "compact",
|
|
522
520
|
exact: "medium",
|
|
523
521
|
className: "text-xs text-muted-foreground"
|
|
524
522
|
})]
|
|
525
|
-
}), t.excerpt && t.reason !== "reminder" && /* @__PURE__ */
|
|
523
|
+
}), t.excerpt && t.reason !== "reminder" && /* @__PURE__ */ R(X, { text: t.excerpt })]
|
|
526
524
|
})]
|
|
527
525
|
}, t.id);
|
|
528
526
|
})
|
|
529
|
-
}),
|
|
530
|
-
n.identifier && /* @__PURE__ */ B(fe, {
|
|
531
|
-
workspace: e,
|
|
532
|
-
identifier: n.identifier,
|
|
533
|
-
since: n.items.at(-1)?.createdAt ?? ""
|
|
534
527
|
})
|
|
535
528
|
]
|
|
536
529
|
});
|
|
537
530
|
}
|
|
538
|
-
|
|
539
|
-
"
|
|
540
|
-
"
|
|
541
|
-
"decision.requested"
|
|
542
|
-
]);
|
|
543
|
-
function fe({ workspace: e, identifier: t, since: n }) {
|
|
544
|
-
let r = R("notifications"), { data: a = [] } = H(i(e, t)), o = a.filter((e) => e.createdAt >= n && !Q.has(e.type) && !e.type.startsWith("comment.") && !e.type.startsWith("issue.reaction_") && e.type !== "issue.body_changed");
|
|
545
|
-
return o.length === 0 ? null : /* @__PURE__ */ V("section", {
|
|
546
|
-
className: "mt-6",
|
|
547
|
-
"aria-label": r("alsoHappened"),
|
|
548
|
-
children: [/* @__PURE__ */ B("h3", {
|
|
549
|
-
className: "text-xs font-medium text-muted-foreground",
|
|
550
|
-
children: r("alsoHappened")
|
|
551
|
-
}), /* @__PURE__ */ B(T, {
|
|
552
|
-
className: "mt-2",
|
|
553
|
-
children: o.map((t) => /* @__PURE__ */ B(E, {
|
|
554
|
-
workspace: e,
|
|
555
|
-
event: t
|
|
556
|
-
}, t.id))
|
|
557
|
-
})]
|
|
558
|
-
});
|
|
559
|
-
}
|
|
560
|
-
function pe({ text: e }) {
|
|
561
|
-
let t = R("agentWork"), n = C(e);
|
|
562
|
-
return n ? /* @__PURE__ */ V("div", {
|
|
531
|
+
function X({ text: e }) {
|
|
532
|
+
let t = I("agentWork"), n = x(e);
|
|
533
|
+
return n ? /* @__PURE__ */ z("div", {
|
|
563
534
|
className: "mt-1 min-w-0 text-sm text-muted-foreground",
|
|
564
535
|
children: [
|
|
565
|
-
/* @__PURE__ */
|
|
566
|
-
/* @__PURE__ */
|
|
536
|
+
/* @__PURE__ */ R("p", { children: n.agent ? t("approveCommandFor", { agent: n.agent }) : t("approveCommand") }),
|
|
537
|
+
/* @__PURE__ */ R("code", {
|
|
567
538
|
className: "mt-1 block rounded-md bg-muted px-2 py-1 font-mono text-xs break-all whitespace-pre-wrap text-foreground",
|
|
568
539
|
children: n.command
|
|
569
540
|
}),
|
|
570
|
-
n.reason && /* @__PURE__ */
|
|
541
|
+
n.reason && /* @__PURE__ */ R("p", {
|
|
571
542
|
className: "mt-1",
|
|
572
543
|
children: n.reason
|
|
573
544
|
})
|
|
574
545
|
]
|
|
575
|
-
}) : /* @__PURE__ */
|
|
546
|
+
}) : /* @__PURE__ */ R("div", {
|
|
576
547
|
className: "mt-1 min-w-0 text-sm text-muted-foreground",
|
|
577
|
-
children: /* @__PURE__ */
|
|
548
|
+
children: /* @__PURE__ */ R(b, {
|
|
578
549
|
value: e.replace(/<!--[\s\S]*?(-->|$)/g, "").trim(),
|
|
579
550
|
editable: !1
|
|
580
551
|
})
|
|
581
552
|
});
|
|
582
553
|
}
|
|
583
|
-
function
|
|
584
|
-
let t =
|
|
585
|
-
return t ? /* @__PURE__ */
|
|
554
|
+
function Z({ text: e }) {
|
|
555
|
+
let t = x(e);
|
|
556
|
+
return t ? /* @__PURE__ */ R("code", {
|
|
586
557
|
className: "font-mono",
|
|
587
558
|
children: t.command
|
|
588
|
-
}) :
|
|
559
|
+
}) : C(e);
|
|
589
560
|
}
|
|
590
|
-
function
|
|
591
|
-
let n =
|
|
592
|
-
return
|
|
561
|
+
function Q({ workspace: e, identifier: t }) {
|
|
562
|
+
let n = I("notifications"), { data: r = [] } = B(i(e, t)), a = r.filter((e) => !e.answer && !e.canceled);
|
|
563
|
+
return a.length === 0 ? null : /* @__PURE__ */ z("section", {
|
|
593
564
|
"aria-label": n("waitingOnYou"),
|
|
594
565
|
className: "mt-5 space-y-3",
|
|
595
|
-
children: [/* @__PURE__ */
|
|
566
|
+
children: [/* @__PURE__ */ R("h3", {
|
|
596
567
|
className: "text-xs font-medium text-muted-foreground",
|
|
597
568
|
children: n("waitingOnYou")
|
|
598
|
-
}),
|
|
569
|
+
}), a.map((t) => /* @__PURE__ */ R(S, {
|
|
599
570
|
workspace: e,
|
|
600
571
|
decision: t
|
|
601
572
|
}, t.id))]
|
|
602
573
|
});
|
|
603
574
|
}
|
|
604
575
|
function $({ group: e }) {
|
|
605
|
-
let t =
|
|
606
|
-
return e.identifier ? /* @__PURE__ */
|
|
576
|
+
let t = I("notifications");
|
|
577
|
+
return e.identifier ? /* @__PURE__ */ R("span", {
|
|
607
578
|
className: "shrink-0 text-xs text-muted-foreground",
|
|
608
579
|
children: e.identifier
|
|
609
|
-
}) : /* @__PURE__ */
|
|
580
|
+
}) : /* @__PURE__ */ z("span", {
|
|
610
581
|
className: "inline-flex shrink-0 items-center gap-1 text-xs text-muted-foreground",
|
|
611
|
-
children: [e.kind === "doc" ? /* @__PURE__ */
|
|
582
|
+
children: [e.kind === "doc" ? /* @__PURE__ */ R(u, { className: "size-3" }) : /* @__PURE__ */ R(p, { className: "size-3" }), t(e.kind === "doc" ? "aboutDoc" : "aboutProject")]
|
|
612
583
|
});
|
|
613
584
|
}
|
|
614
|
-
export {
|
|
585
|
+
export { K as component };
|