@locusgraph/loop 0.2.1 → 0.3.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.
Files changed (66) hide show
  1. package/dist/agent/pulse/gradient-label.js +64 -12
  2. package/dist/agent/pulse/marks/bars-mark.js +39 -15
  3. package/dist/agent/pulse/marks/glyph-mark.js +56 -15
  4. package/dist/agent/pulse/marks/locus-mark.js +38 -12
  5. package/dist/agent/pulse/marks/orb-mark.js +21 -9
  6. package/dist/agent/pulse/pulse.js +1 -1
  7. package/dist/agent/pulse/use-loop-animation.js +35 -12
  8. package/dist/agent/thinking/thinking.js +2 -2
  9. package/dist/agent/tool/tool-status.js +1 -1
  10. package/dist/approval/inbox/inbox-row.js +303 -76
  11. package/dist/approval/inbox/inbox.js +192 -39
  12. package/dist/approval/inbox/virtual-inbox-list.js +104 -26
  13. package/dist/approval/memory/memory-review.js +172 -36
  14. package/dist/approval/memory/memory-row.js +187 -50
  15. package/dist/approval/plan/plan-review.js +225 -73
  16. package/dist/approval/plan/plan-step-row.js +182 -76
  17. package/dist/approval/plan/question-choices.js +132 -44
  18. package/dist/approval/plan/question.js +156 -38
  19. package/dist/approval/run/run-bar.js +125 -39
  20. package/dist/approval/shared/use-focus-on-mount.js +23 -5
  21. package/dist/approval/spend/raise-cap-form.js +223 -48
  22. package/dist/approval/spend/spend-gate.js +157 -40
  23. package/dist/approval/spend/spend-meter.js +1 -1
  24. package/dist/approval/tool/approval.js +196 -35
  25. package/dist/approval/tool/args/args-editor.js +206 -46
  26. package/dist/approval/tool/args/args-field.js +240 -55
  27. package/dist/approval/tool/deny-form.js +125 -36
  28. package/dist/approval/tool/tool-inputs.js +91 -24
  29. package/dist/chat/chat/use-stick-to-bottom.js +115 -60
  30. package/dist/chat/chat/virtual-chat-items.js +129 -34
  31. package/dist/chat/composer/composer-actions.d.ts +1 -2
  32. package/dist/chat/composer/composer-actions.js +132 -49
  33. package/dist/chat/composer/composer-status.d.ts +2 -0
  34. package/dist/chat/composer/composer-status.js +3 -0
  35. package/dist/chat/composer/composer.d.ts +1 -1
  36. package/dist/chat/composer/composer.js +2 -1
  37. package/dist/chat/composer/use-auto-grow.js +25 -8
  38. package/dist/chat/files/files.js +293 -66
  39. package/dist/chat/index.d.ts +1 -1
  40. package/dist/chat/index.js +1 -1
  41. package/dist/chat/reply/markdown-components.js +2 -2
  42. package/dist/cost/context.js +1 -1
  43. package/dist/cost/cost.js +1 -1
  44. package/dist/cost/model-picker.js +174 -42
  45. package/dist/cost/shared/context-breakdown.js +1 -1
  46. package/dist/memory/cite.js +181 -58
  47. package/dist/memory/memorized.js +197 -43
  48. package/dist/memory/recall.js +265 -68
  49. package/dist/memory/shared/disclosure.d.ts +2 -2
  50. package/dist/memory/shared/disclosure.js +1 -1
  51. package/dist/memory/sources.js +232 -52
  52. package/dist/shared/panel.js +1 -1
  53. package/dist/shared/virtual/use-list-virtualizer.js +2 -0
  54. package/dist/thread/actions/branch-switcher.js +97 -21
  55. package/dist/thread/canvas/canvas.js +1 -1
  56. package/dist/thread/canvas/version-switcher.js +128 -31
  57. package/dist/thread/code/code.js +2 -2
  58. package/dist/thread/code/copy-code-button.js +58 -24
  59. package/dist/thread/history/history.js +1 -1
  60. package/dist/thread/history/row/history-row.js +99 -18
  61. package/dist/thread/history/row/thread-item-menu.js +74 -19
  62. package/dist/thread/history/row/thread-title-editor.js +74 -29
  63. package/dist/thread/history/virtual-history-list.js +84 -46
  64. package/dist/thread/starters/starters.js +89 -27
  65. package/dist/thread/use-copied.js +40 -10
  66. package/package.json +3 -3
@@ -1,3 +1,6 @@
1
+ "use client";
2
+
3
+ import { c as _c } from "react/compiler-runtime";
1
4
  import { Checkmark as CheckIcon, Locked as LockIcon, Close as XIcon } from "@carbon/icons-react";
2
5
  import { Button, Checkbox, cn } from "@locusgraph/components";
3
6
  import { riskLabels } from "../shared/risk-badge.js";
@@ -8,24 +11,62 @@ const riskDot = {
8
11
  write: "bg-warn",
9
12
  destructive: "bg-destructive"
10
13
  };
11
- export function InboxRow({
12
- item,
13
- now,
14
- selected,
15
- onSelect,
16
- onApprove,
17
- onDeny,
18
- className,
19
- ...props
20
- }) {
14
+ export function InboxRow(t0) {
15
+ const $ = _c(70);
16
+ let className;
17
+ let item;
18
+ let now;
19
+ let onApprove;
20
+ let onDeny;
21
+ let onSelect;
22
+ let props;
23
+ let selected;
24
+ if ($[0] !== t0) {
25
+ ({
26
+ item,
27
+ now,
28
+ selected,
29
+ onSelect,
30
+ onApprove,
31
+ onDeny,
32
+ className,
33
+ ...props
34
+ } = t0);
35
+ $[0] = t0;
36
+ $[1] = className;
37
+ $[2] = item;
38
+ $[3] = now;
39
+ $[4] = onApprove;
40
+ $[5] = onDeny;
41
+ $[6] = onSelect;
42
+ $[7] = props;
43
+ $[8] = selected;
44
+ } else {
45
+ className = $[1];
46
+ item = $[2];
47
+ now = $[3];
48
+ onApprove = $[4];
49
+ onDeny = $[5];
50
+ onSelect = $[6];
51
+ props = $[7];
52
+ selected = $[8];
53
+ }
21
54
  const destructive = item.risk === "destructive";
22
- return /*#__PURE__*/_jsxs("li", {
23
- "data-slot": "inbox-item",
24
- "data-risk": item.risk,
25
- "data-selected": selected || undefined,
26
- className: cn("group flex items-center gap-3 px-5 py-2.5 motion-safe:transition-colors", selected ? "bg-accent" : "hover:bg-accent/50", className),
27
- ...props,
28
- children: [destructive ? /*#__PURE__*/_jsxs("span", {
55
+ const t1 = item.risk;
56
+ const t2 = selected || undefined;
57
+ const t3 = selected ? "bg-accent" : "hover:bg-accent/50";
58
+ let t4;
59
+ if ($[9] !== className || $[10] !== t3) {
60
+ t4 = cn("group flex items-center gap-3 px-5 py-2.5 motion-safe:transition-colors", t3, className);
61
+ $[9] = className;
62
+ $[10] = t3;
63
+ $[11] = t4;
64
+ } else {
65
+ t4 = $[11];
66
+ }
67
+ let t5;
68
+ if ($[12] !== destructive || $[13] !== item.title || $[14] !== onSelect || $[15] !== selected) {
69
+ t5 = destructive ? /*#__PURE__*/_jsxs("span", {
29
70
  className: "flex size-4 shrink-0 items-center justify-center text-muted-foreground",
30
71
  children: [/*#__PURE__*/_jsx(LockIcon, {
31
72
  "aria-hidden": true,
@@ -38,66 +79,252 @@ export function InboxRow({
38
79
  "aria-label": `Select ${item.title}`,
39
80
  checked: selected,
40
81
  onCheckedChange: checked => onSelect(checked === true)
41
- }), /*#__PURE__*/_jsxs("div", {
42
- className: "flex min-w-0 flex-1 flex-col gap-0.5",
43
- children: [/*#__PURE__*/_jsxs("p", {
44
- className: "flex min-w-0 items-baseline gap-2 text-sm",
45
- children: [/*#__PURE__*/_jsx("span", {
46
- className: "truncate font-medium",
47
- children: item.title
48
- }), /*#__PURE__*/_jsx("span", {
49
- className: "hidden shrink-0 truncate text-xs text-muted-foreground sm:inline",
50
- children: item.runName
51
- })]
52
- }), /*#__PURE__*/_jsxs("p", {
53
- className: "flex min-w-0 items-center gap-1.5 text-xs text-muted-foreground",
54
- children: [/*#__PURE__*/_jsx("span", {
55
- "aria-hidden": true,
56
- className: cn("size-1.5 shrink-0 rounded-full", riskDot[item.risk])
57
- }), /*#__PURE__*/_jsx("span", {
58
- className: "shrink-0",
59
- children: riskLabels[item.risk]
60
- }), item.summary && /*#__PURE__*/_jsxs(_Fragment, {
61
- children: [/*#__PURE__*/_jsx("span", {
62
- "aria-hidden": true,
63
- children: "\xB7"
64
- }), /*#__PURE__*/_jsx("span", {
65
- className: "truncate",
66
- children: item.summary
67
- })]
68
- })]
69
- }), /*#__PURE__*/_jsx("p", {
70
- className: "truncate text-xs text-muted-foreground sm:hidden",
71
- children: item.runName
82
+ });
83
+ $[12] = destructive;
84
+ $[13] = item.title;
85
+ $[14] = onSelect;
86
+ $[15] = selected;
87
+ $[16] = t5;
88
+ } else {
89
+ t5 = $[16];
90
+ }
91
+ let t6;
92
+ if ($[17] !== item.title) {
93
+ t6 = /*#__PURE__*/_jsx("span", {
94
+ className: "truncate font-medium",
95
+ children: item.title
96
+ });
97
+ $[17] = item.title;
98
+ $[18] = t6;
99
+ } else {
100
+ t6 = $[18];
101
+ }
102
+ let t7;
103
+ if ($[19] !== item.runName) {
104
+ t7 = /*#__PURE__*/_jsx("span", {
105
+ className: "hidden shrink-0 truncate text-xs text-muted-foreground sm:inline",
106
+ children: item.runName
107
+ });
108
+ $[19] = item.runName;
109
+ $[20] = t7;
110
+ } else {
111
+ t7 = $[20];
112
+ }
113
+ let t8;
114
+ if ($[21] !== t6 || $[22] !== t7) {
115
+ t8 = /*#__PURE__*/_jsxs("p", {
116
+ className: "flex min-w-0 items-baseline gap-2 text-sm",
117
+ children: [t6, t7]
118
+ });
119
+ $[21] = t6;
120
+ $[22] = t7;
121
+ $[23] = t8;
122
+ } else {
123
+ t8 = $[23];
124
+ }
125
+ const t9 = riskDot[item.risk];
126
+ let t10;
127
+ if ($[24] !== t9) {
128
+ t10 = cn("size-1.5 shrink-0 rounded-full", t9);
129
+ $[24] = t9;
130
+ $[25] = t10;
131
+ } else {
132
+ t10 = $[25];
133
+ }
134
+ let t11;
135
+ if ($[26] !== t10) {
136
+ t11 = /*#__PURE__*/_jsx("span", {
137
+ "aria-hidden": true,
138
+ className: t10
139
+ });
140
+ $[26] = t10;
141
+ $[27] = t11;
142
+ } else {
143
+ t11 = $[27];
144
+ }
145
+ const t12 = riskLabels[item.risk];
146
+ let t13;
147
+ if ($[28] !== t12) {
148
+ t13 = /*#__PURE__*/_jsx("span", {
149
+ className: "shrink-0",
150
+ children: t12
151
+ });
152
+ $[28] = t12;
153
+ $[29] = t13;
154
+ } else {
155
+ t13 = $[29];
156
+ }
157
+ let t14;
158
+ if ($[30] !== item.summary) {
159
+ t14 = item.summary && /*#__PURE__*/_jsxs(_Fragment, {
160
+ children: [/*#__PURE__*/_jsx("span", {
161
+ "aria-hidden": true,
162
+ children: "\xB7"
163
+ }), /*#__PURE__*/_jsx("span", {
164
+ className: "truncate",
165
+ children: item.summary
72
166
  })]
73
- }), /*#__PURE__*/_jsx("time", {
74
- dateTime: isoOf(item.requestedAt),
167
+ });
168
+ $[30] = item.summary;
169
+ $[31] = t14;
170
+ } else {
171
+ t14 = $[31];
172
+ }
173
+ let t15;
174
+ if ($[32] !== t11 || $[33] !== t13 || $[34] !== t14) {
175
+ t15 = /*#__PURE__*/_jsxs("p", {
176
+ className: "flex min-w-0 items-center gap-1.5 text-xs text-muted-foreground",
177
+ children: [t11, t13, t14]
178
+ });
179
+ $[32] = t11;
180
+ $[33] = t13;
181
+ $[34] = t14;
182
+ $[35] = t15;
183
+ } else {
184
+ t15 = $[35];
185
+ }
186
+ let t16;
187
+ if ($[36] !== item.runName) {
188
+ t16 = /*#__PURE__*/_jsx("p", {
189
+ className: "truncate text-xs text-muted-foreground sm:hidden",
190
+ children: item.runName
191
+ });
192
+ $[36] = item.runName;
193
+ $[37] = t16;
194
+ } else {
195
+ t16 = $[37];
196
+ }
197
+ let t17;
198
+ if ($[38] !== t15 || $[39] !== t16 || $[40] !== t8) {
199
+ t17 = /*#__PURE__*/_jsxs("div", {
200
+ className: "flex min-w-0 flex-1 flex-col gap-0.5",
201
+ children: [t8, t15, t16]
202
+ });
203
+ $[38] = t15;
204
+ $[39] = t16;
205
+ $[40] = t8;
206
+ $[41] = t17;
207
+ } else {
208
+ t17 = $[41];
209
+ }
210
+ let t18;
211
+ if ($[42] !== item.requestedAt) {
212
+ t18 = isoOf(item.requestedAt);
213
+ $[42] = item.requestedAt;
214
+ $[43] = t18;
215
+ } else {
216
+ t18 = $[43];
217
+ }
218
+ let t19;
219
+ if ($[44] !== item.requestedAt || $[45] !== now) {
220
+ t19 = formatWaiting(item.requestedAt, now);
221
+ $[44] = item.requestedAt;
222
+ $[45] = now;
223
+ $[46] = t19;
224
+ } else {
225
+ t19 = $[46];
226
+ }
227
+ let t20;
228
+ if ($[47] !== t18 || $[48] !== t19) {
229
+ t20 = /*#__PURE__*/_jsx("time", {
230
+ dateTime: t18,
75
231
  className: "w-12 shrink-0 text-right font-mono text-[11px] text-muted-foreground tabular-nums",
76
- children: formatWaiting(item.requestedAt, now)
77
- }), /*#__PURE__*/_jsxs("span", {
232
+ children: t19
233
+ });
234
+ $[47] = t18;
235
+ $[48] = t19;
236
+ $[49] = t20;
237
+ } else {
238
+ t20 = $[49];
239
+ }
240
+ const t21 = `Approve ${item.title}`;
241
+ let t22;
242
+ if ($[50] === Symbol.for("react.memo_cache_sentinel")) {
243
+ t22 = /*#__PURE__*/_jsx(CheckIcon, {
244
+ "aria-hidden": true
245
+ });
246
+ $[50] = t22;
247
+ } else {
248
+ t22 = $[50];
249
+ }
250
+ let t23;
251
+ if ($[51] !== onApprove || $[52] !== t21) {
252
+ t23 = /*#__PURE__*/_jsx(Button, {
253
+ type: "button",
254
+ size: "icon-xs",
255
+ variant: "outline",
256
+ "aria-label": t21,
257
+ title: "Approve",
258
+ onClick: onApprove,
259
+ children: t22
260
+ });
261
+ $[51] = onApprove;
262
+ $[52] = t21;
263
+ $[53] = t23;
264
+ } else {
265
+ t23 = $[53];
266
+ }
267
+ const t24 = `Deny ${item.title}`;
268
+ let t25;
269
+ if ($[54] === Symbol.for("react.memo_cache_sentinel")) {
270
+ t25 = /*#__PURE__*/_jsx(XIcon, {
271
+ "aria-hidden": true
272
+ });
273
+ $[54] = t25;
274
+ } else {
275
+ t25 = $[54];
276
+ }
277
+ let t26;
278
+ if ($[55] !== onDeny || $[56] !== t24) {
279
+ t26 = /*#__PURE__*/_jsx(Button, {
280
+ type: "button",
281
+ size: "icon-xs",
282
+ variant: "ghost",
283
+ "aria-label": t24,
284
+ title: "Deny",
285
+ className: "text-muted-foreground hover:text-foreground",
286
+ onClick: onDeny,
287
+ children: t25
288
+ });
289
+ $[55] = onDeny;
290
+ $[56] = t24;
291
+ $[57] = t26;
292
+ } else {
293
+ t26 = $[57];
294
+ }
295
+ let t27;
296
+ if ($[58] !== t23 || $[59] !== t26) {
297
+ t27 = /*#__PURE__*/_jsxs("span", {
78
298
  className: "flex shrink-0 gap-1",
79
- children: [/*#__PURE__*/_jsx(Button, {
80
- type: "button",
81
- size: "icon-xs",
82
- variant: "outline",
83
- "aria-label": `Approve ${item.title}`,
84
- title: "Approve",
85
- onClick: onApprove,
86
- children: /*#__PURE__*/_jsx(CheckIcon, {
87
- "aria-hidden": true
88
- })
89
- }), /*#__PURE__*/_jsx(Button, {
90
- type: "button",
91
- size: "icon-xs",
92
- variant: "ghost",
93
- "aria-label": `Deny ${item.title}`,
94
- title: "Deny",
95
- className: "text-muted-foreground hover:text-foreground",
96
- onClick: onDeny,
97
- children: /*#__PURE__*/_jsx(XIcon, {
98
- "aria-hidden": true
99
- })
100
- })]
101
- })]
102
- });
299
+ children: [t23, t26]
300
+ });
301
+ $[58] = t23;
302
+ $[59] = t26;
303
+ $[60] = t27;
304
+ } else {
305
+ t27 = $[60];
306
+ }
307
+ let t28;
308
+ if ($[61] !== item.risk || $[62] !== props || $[63] !== t17 || $[64] !== t2 || $[65] !== t20 || $[66] !== t27 || $[67] !== t4 || $[68] !== t5) {
309
+ t28 = /*#__PURE__*/_jsxs("li", {
310
+ "data-slot": "inbox-item",
311
+ "data-risk": t1,
312
+ "data-selected": t2,
313
+ className: t4,
314
+ ...props,
315
+ children: [t5, t17, t20, t27]
316
+ });
317
+ $[61] = item.risk;
318
+ $[62] = props;
319
+ $[63] = t17;
320
+ $[64] = t2;
321
+ $[65] = t20;
322
+ $[66] = t27;
323
+ $[67] = t4;
324
+ $[68] = t5;
325
+ $[69] = t28;
326
+ } else {
327
+ t28 = $[69];
328
+ }
329
+ return t28;
103
330
  }
@@ -1,3 +1,6 @@
1
+ "use client";
2
+
3
+ import { c as _c } from "react/compiler-runtime";
1
4
  import { MailAll as InboxIcon } from "@carbon/icons-react";
2
5
  import { Button, Checkbox, Label } from "@locusgraph/components";
3
6
  import { pluralize } from "@locusgraph/utils";
@@ -9,43 +12,118 @@ import { InboxRow } from "./inbox-row.js";
9
12
  import { bulkApprovable, selectAllState, selectedIn, toggled } from "./inbox-selection.js";
10
13
  import { VirtualInboxList } from "./virtual-inbox-list.js";
11
14
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
12
- export function Inbox({
13
- items,
14
- now = Date.now(),
15
- title = "Waiting for approval",
16
- onApprove,
17
- onDeny,
18
- onApproveAll,
19
- virtualize = true,
20
- className
21
- }) {
15
+ export function Inbox(t0) {
16
+ const $ = _c(53);
17
+ const {
18
+ items,
19
+ now: t1,
20
+ title: t2,
21
+ onApprove,
22
+ onDeny,
23
+ onApproveAll,
24
+ virtualize: t3,
25
+ className
26
+ } = t0;
27
+ let t4;
28
+ if ($[0] !== t1) {
29
+ t4 = t1 === undefined ? Date.now() : t1;
30
+ $[0] = t1;
31
+ $[1] = t4;
32
+ } else {
33
+ t4 = $[1];
34
+ }
35
+ const now = t4;
36
+ const title = t2 === undefined ? "Waiting for approval" : t2;
37
+ const virtualize = t3 === undefined ? true : t3;
22
38
  const selectAllId = useId();
23
- const [selected, setSelected] = useState(() => new Set());
24
- const selectable = bulkApprovable(items);
25
- const selectedIds = selectedIn(items, selected);
26
- const allState = selectAllState(selectable.length, selectedIds.length);
39
+ const [selected, setSelected] = useState(_temp);
40
+ let selectable;
41
+ let selectedIds;
42
+ let t5;
43
+ if ($[2] !== items || $[3] !== selected) {
44
+ selectable = bulkApprovable(items);
45
+ selectedIds = selectedIn(items, selected);
46
+ t5 = selectAllState(selectable.length, selectedIds.length);
47
+ $[2] = items;
48
+ $[3] = selected;
49
+ $[4] = selectable;
50
+ $[5] = selectedIds;
51
+ $[6] = t5;
52
+ } else {
53
+ selectable = $[4];
54
+ selectedIds = $[5];
55
+ t5 = $[6];
56
+ }
57
+ const allState = t5;
27
58
  const hasDestructive = selectable.length < items.length;
28
59
  const empty = items.length === 0;
29
- const rowHandlers = {
30
- isSelected: id => selected.has(id),
31
- onSelect: (id, on) => setSelected(current => toggled(current, id, on)),
32
- onApprove,
33
- onDeny
34
- };
35
- return /*#__PURE__*/_jsxs(ApprovalPanel, {
36
- "data-slot": "inbox",
37
- "aria-label": title,
38
- className: className,
39
- children: [/*#__PURE__*/_jsx(PanelHeader, {
40
- icon: /*#__PURE__*/_jsx(InboxIcon, {
60
+ let t6;
61
+ if ($[7] !== selected) {
62
+ t6 = id => selected.has(id);
63
+ $[7] = selected;
64
+ $[8] = t6;
65
+ } else {
66
+ t6 = $[8];
67
+ }
68
+ let t7;
69
+ if ($[9] === Symbol.for("react.memo_cache_sentinel")) {
70
+ t7 = (id_0, on) => setSelected(current => toggled(current, id_0, on));
71
+ $[9] = t7;
72
+ } else {
73
+ t7 = $[9];
74
+ }
75
+ let T0;
76
+ let t10;
77
+ let t11;
78
+ let t12;
79
+ let t13;
80
+ let t8;
81
+ let t9;
82
+ if ($[10] !== allState || $[11] !== className || $[12] !== empty || $[13] !== hasDestructive || $[14] !== items || $[15] !== now || $[16] !== onApprove || $[17] !== onApproveAll || $[18] !== onDeny || $[19] !== selectAllId || $[20] !== selectable || $[21] !== selectedIds || $[22] !== t6 || $[23] !== title || $[24] !== virtualize) {
83
+ const rowHandlers = {
84
+ isSelected: t6,
85
+ onSelect: t7,
86
+ onApprove,
87
+ onDeny
88
+ };
89
+ T0 = ApprovalPanel;
90
+ t8 = "inbox";
91
+ t9 = title;
92
+ t10 = className;
93
+ let t14;
94
+ if ($[32] === Symbol.for("react.memo_cache_sentinel")) {
95
+ t14 = /*#__PURE__*/_jsx(InboxIcon, {
41
96
  "aria-hidden": true
42
- }),
43
- eyebrow: "Approvals",
44
- status: empty ? "All clear" : `${items.length} waiting`,
45
- tone: empty ? "done" : "waiting"
46
- }), /*#__PURE__*/_jsx(PanelTitle, {
47
- children: title
48
- }), empty ? /*#__PURE__*/_jsx(PanelEmpty, {
97
+ });
98
+ $[32] = t14;
99
+ } else {
100
+ t14 = $[32];
101
+ }
102
+ const t15 = empty ? "All clear" : `${items.length} waiting`;
103
+ const t16 = empty ? "done" : "waiting";
104
+ if ($[33] !== t15 || $[34] !== t16) {
105
+ t11 = /*#__PURE__*/_jsx(PanelHeader, {
106
+ icon: t14,
107
+ eyebrow: "Approvals",
108
+ status: t15,
109
+ tone: t16
110
+ });
111
+ $[33] = t15;
112
+ $[34] = t16;
113
+ $[35] = t11;
114
+ } else {
115
+ t11 = $[35];
116
+ }
117
+ if ($[36] !== title) {
118
+ t12 = /*#__PURE__*/_jsx(PanelTitle, {
119
+ children: title
120
+ });
121
+ $[36] = title;
122
+ $[37] = t12;
123
+ } else {
124
+ t12 = $[37];
125
+ }
126
+ t13 = empty ? /*#__PURE__*/_jsx(PanelEmpty, {
49
127
  "data-slot": "inbox-empty",
50
128
  icon: /*#__PURE__*/_jsx(InboxIcon, {
51
129
  "aria-hidden": true
@@ -63,7 +141,7 @@ export function Inbox({
63
141
  item: item,
64
142
  now: now,
65
143
  selected: rowHandlers.isSelected(item.id),
66
- onSelect: on => rowHandlers.onSelect(item.id, on),
144
+ onSelect: on_0 => rowHandlers.onSelect(item.id, on_0),
67
145
  onApprove: () => onApprove(item.id),
68
146
  onDeny: () => onDeny(item.id)
69
147
  }, item.id))
@@ -74,7 +152,7 @@ export function Inbox({
74
152
  children: [selectable.length > 0 && /*#__PURE__*/_jsx(Checkbox, {
75
153
  id: selectAllId,
76
154
  checked: allState,
77
- onCheckedChange: checked => setSelected(checked === true ? new Set(selectable.map(item => item.id)) : new Set())
155
+ onCheckedChange: checked => setSelected(checked === true ? new Set(selectable.map(_temp2)) : new Set())
78
156
  }), /*#__PURE__*/_jsxs(Label, {
79
157
  htmlFor: selectAllId,
80
158
  className: "flex min-w-0 flex-col items-start gap-0 font-normal",
@@ -100,8 +178,83 @@ export function Inbox({
100
178
  children: selectedIds.length > 0 ? `Approve ${selectedIds.length} selected` : "Approve selected"
101
179
  })]
102
180
  })]
103
- }), /*#__PURE__*/_jsx(LiveStatus, {
104
- message: empty ? "No approvals waiting" : `${pluralize(items.length, "approval")} waiting, ${selectedIds.length} selected`
105
- })]
106
- });
181
+ });
182
+ $[10] = allState;
183
+ $[11] = className;
184
+ $[12] = empty;
185
+ $[13] = hasDestructive;
186
+ $[14] = items;
187
+ $[15] = now;
188
+ $[16] = onApprove;
189
+ $[17] = onApproveAll;
190
+ $[18] = onDeny;
191
+ $[19] = selectAllId;
192
+ $[20] = selectable;
193
+ $[21] = selectedIds;
194
+ $[22] = t6;
195
+ $[23] = title;
196
+ $[24] = virtualize;
197
+ $[25] = T0;
198
+ $[26] = t10;
199
+ $[27] = t11;
200
+ $[28] = t12;
201
+ $[29] = t13;
202
+ $[30] = t8;
203
+ $[31] = t9;
204
+ } else {
205
+ T0 = $[25];
206
+ t10 = $[26];
207
+ t11 = $[27];
208
+ t12 = $[28];
209
+ t13 = $[29];
210
+ t8 = $[30];
211
+ t9 = $[31];
212
+ }
213
+ let t14;
214
+ if ($[38] !== empty || $[39] !== items.length || $[40] !== selectedIds) {
215
+ t14 = empty ? "No approvals waiting" : `${pluralize(items.length, "approval")} waiting, ${selectedIds.length} selected`;
216
+ $[38] = empty;
217
+ $[39] = items.length;
218
+ $[40] = selectedIds;
219
+ $[41] = t14;
220
+ } else {
221
+ t14 = $[41];
222
+ }
223
+ let t15;
224
+ if ($[42] !== t14) {
225
+ t15 = /*#__PURE__*/_jsx(LiveStatus, {
226
+ message: t14
227
+ });
228
+ $[42] = t14;
229
+ $[43] = t15;
230
+ } else {
231
+ t15 = $[43];
232
+ }
233
+ let t16;
234
+ if ($[44] !== T0 || $[45] !== t10 || $[46] !== t11 || $[47] !== t12 || $[48] !== t13 || $[49] !== t15 || $[50] !== t8 || $[51] !== t9) {
235
+ t16 = /*#__PURE__*/_jsxs(T0, {
236
+ "data-slot": t8,
237
+ "aria-label": t9,
238
+ className: t10,
239
+ children: [t11, t12, t13, t15]
240
+ });
241
+ $[44] = T0;
242
+ $[45] = t10;
243
+ $[46] = t11;
244
+ $[47] = t12;
245
+ $[48] = t13;
246
+ $[49] = t15;
247
+ $[50] = t8;
248
+ $[51] = t9;
249
+ $[52] = t16;
250
+ } else {
251
+ t16 = $[52];
252
+ }
253
+ return t16;
254
+ }
255
+ function _temp2(item_0) {
256
+ return item_0.id;
257
+ }
258
+ function _temp() {
259
+ return new Set();
107
260
  }