@omg-dev/app 0.5.0 → 0.6.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 (113) hide show
  1. package/dist-lib/{ChangelogPage-8lbvM9Pz.js → ChangelogPage-Cjj_DiYL.js} +57 -1
  2. package/dist-lib/{File-B-qYa2zY.js → File-DQRr5F_e.js} +1761 -1826
  3. package/dist-lib/FileEditor-BrI3dfcp.js +6895 -0
  4. package/dist-lib/FileTreePane-J8P-OiHb.js +8413 -0
  5. package/dist-lib/{FileViewer-Clmf04v1.js → FileViewer-DRrfus7c.js} +1 -1
  6. package/dist-lib/{SessionFilesPanel-BKcTU57t.js → SessionFilesPanel-DxVJ43fE.js} +69 -69
  7. package/dist-lib/{TermView-gazV6UMU.js → TermView-B4V-DyD-.js} +521 -530
  8. package/dist-lib/{abnfDiagram-VRR7QNED-Chn1Z_p9.js → abnfDiagram-VRR7QNED-CiXfOnAu.js} +4 -4
  9. package/dist-lib/{arc-B652oHQ-.js → arc-QOMNKQA5.js} +1 -1
  10. package/dist-lib/{architectureDiagram-ZJ3FMSHR-CMatArpz.js → architectureDiagram-ZJ3FMSHR-BcFBTmfD.js} +2059 -2064
  11. package/dist-lib/{blockDiagram-677ZJIJ3-CEOPfI9A.js → blockDiagram-677ZJIJ3-Qj8-RIV3.js} +920 -925
  12. package/dist-lib/{c4Diagram-LMCZKHZV-DcUHrESL.js → c4Diagram-LMCZKHZV-BpinEmj4.js} +598 -593
  13. package/dist-lib/{channel-B5lJFbed.js → channel-D6YHMmF7.js} +1 -1
  14. package/dist-lib/{chat-engine-83mwx0z2.js → chat-engine-CUiDTHFP.js} +1173 -1218
  15. package/dist-lib/chunk-2Q5K7J3B-CFSi414U.js +18 -0
  16. package/dist-lib/{chunk-32BRIVSS-IYmNSvH8.js → chunk-32BRIVSS-DvywQiCk.js} +1 -1
  17. package/dist-lib/{chunk-5VM5RSS4-DO2g-xIj.js → chunk-5VM5RSS4-xd6XuI9Q.js} +1 -1
  18. package/dist-lib/{chunk-BO2N2NFS-kYiI5SD9.js → chunk-BO2N2NFS-BbJdm-59.js} +4892 -4903
  19. package/dist-lib/{chunk-EX3LRPZG-N96wfks9.js → chunk-EX3LRPZG-BLDKx-Yg.js} +507 -514
  20. package/dist-lib/chunk-JWPE2WC7-DnwG7Xzp.js +8 -0
  21. package/dist-lib/chunk-MOJQB5TN-BrENeFT5.js +670 -0
  22. package/dist-lib/chunk-RYQCIY6F-I-J4fVFd.js +313 -0
  23. package/dist-lib/{chunk-V7JOEXUC-DQwf2vkP.js → chunk-V7JOEXUC-Bkakcs1-.js} +458 -453
  24. package/dist-lib/chunk-VR4S4FIN-BDq3jZ0m.js +19 -0
  25. package/dist-lib/{chunk-XXDRQBXY-Ccv4aRcn.js → chunk-XXDRQBXY-DRKeYnrF.js} +1 -1
  26. package/dist-lib/{classDiagram-v2-EOCWNBFH-DOn-rhuL.js → classDiagram-OUVF2IWQ-DISUfvR5.js} +2 -2
  27. package/dist-lib/{classDiagram-OUVF2IWQ-DOn-rhuL.js → classDiagram-v2-EOCWNBFH-DISUfvR5.js} +2 -2
  28. package/dist-lib/{coding-agents-page-8Nf-IuE2.js → coding-agents-page-DtxZ0nbQ.js} +152 -131
  29. package/dist-lib/computer-page-DIJeFOZz.js +8860 -0
  30. package/dist-lib/{cose-bilkent-JH36ORCC-C-tACTrT.js → cose-bilkent-JH36ORCC-DCfmoChv.js} +281 -281
  31. package/dist-lib/{create-BrnHvSDE.js → create-CBk9uwJH.js} +2 -2
  32. package/dist-lib/cynefin-VYW2F7L2-XAY3mHv8.js +24430 -0
  33. package/dist-lib/{cynefinDiagram-TSTJHNR4-Be7CamD2.js → cynefinDiagram-TSTJHNR4-CrgvPEr1.js} +3 -3
  34. package/dist-lib/{cytoscape.esm-B0ledd6M.js → cytoscape.esm-BB6Ga9He.js} +3 -3
  35. package/dist-lib/dagre-VKFMJZFB-CE5k06mJ.js +343 -0
  36. package/dist-lib/{diagram-FQU43EPY-Jg12ow4Z.js → diagram-FQU43EPY-gOcCiJEN.js} +136 -139
  37. package/dist-lib/diagram-G47NLZAW-BVJLfRsd.js +531 -0
  38. package/dist-lib/diagram-NH7WQ7WH-u6QnHasL.js +145 -0
  39. package/dist-lib/diagram-OA4YK3LP-D4Kcl3uM.js +350 -0
  40. package/dist-lib/{diagram-WEI45ONY-D1kKPOc_.js → diagram-WEI45ONY-6a__oIb0.js} +38 -42
  41. package/dist-lib/{ebnfDiagram-CCIWWBDH-BhQWrGMc.js → ebnfDiagram-CCIWWBDH-PXSrB6lG.js} +4 -4
  42. package/dist-lib/{embedded-BmrQsEvQ.js → embedded-PUsgcSTE.js} +13043 -13082
  43. package/dist-lib/{engine-compile-BeDRSL6Y.js → engine-compile-D_stzVMa.js} +2939 -2991
  44. package/dist-lib/{erDiagram-Q63AITRT-D2q6Nmwa.js → erDiagram-Q63AITRT-BbsttUCs.js} +286 -284
  45. package/dist-lib/flowDiagram-23GEKE2U-CX5x3zVA.js +1641 -0
  46. package/dist-lib/{ganttDiagram-NO4QXBWP-C_Lj-cJB.js → ganttDiagram-NO4QXBWP-Bq0aSPs8.js} +2 -2
  47. package/dist-lib/gitGraphDiagram-IHSO6WYX-BjAezjIv.js +815 -0
  48. package/dist-lib/{graph-B68L3K2T.js → graph-DAHC4kPm.js} +2 -2
  49. package/dist-lib/{highlighted-body-OFNGDK62-C2DGVKV8.js → highlighted-body-OFNGDK62-DWhG_ijx.js} +1 -1
  50. package/dist-lib/index-B0neMIbR.js +16520 -0
  51. package/dist-lib/index-BBC0E3Qg.js +4994 -0
  52. package/dist-lib/{index-Dtkd4mEk.js → index-CE7H8LiZ.js} +2 -2
  53. package/dist-lib/{index-DWkBvb-9.js → index-FgVvPpIY.js} +2 -2
  54. package/dist-lib/index.js +1 -1
  55. package/dist-lib/{infoDiagram-FWYZ7A6U-BbUkT0KS.js → infoDiagram-FWYZ7A6U-Bo_FNR91.js} +2 -2
  56. package/dist-lib/ishikawaDiagram-FXEZZL3T-C5bGD-Eb.js +624 -0
  57. package/dist-lib/{journeyDiagram-5HDEW3XC-CgykmVSC.js → journeyDiagram-5HDEW3XC-C8qM7SxF.js} +4 -4
  58. package/dist-lib/kanban-definition-HUTT4EX6-C-EK5Puz.js +724 -0
  59. package/dist-lib/{katex-jHfnQmlp.js → katex-DoRnZ_sp.js} +1 -1
  60. package/dist-lib/{layout-BGrtsiRL.js → layout-DBbo_M5I.js} +2 -2
  61. package/dist-lib/{linear-B5ZSwawJ.js → linear-zGzX0-I0.js} +1 -1
  62. package/dist-lib/{map-hbfFlSln.js → map-DRdzG8Ho.js} +1 -1
  63. package/dist-lib/mermaid-GHXKKRXX-hOE9C3qW.js +4 -0
  64. package/dist-lib/{mindmap-definition-LN4V7U3C-CfhfeEht.js → mindmap-definition-LN4V7U3C-DlVCRx6k.js} +310 -311
  65. package/dist-lib/{pegDiagram-2B236MQR-CYDAJHPF.js → pegDiagram-2B236MQR-DrKNikeG.js} +4 -4
  66. package/dist-lib/{pieDiagram-ENE6RG2P-udKxQm4p.js → pieDiagram-ENE6RG2P-Fm_jc0HL.js} +83 -84
  67. package/dist-lib/quadrantDiagram-ABIIQ3AL-zDRY0VtB.js +1029 -0
  68. package/dist-lib/{railroadDiagram-RFXS5EU6-q0Svkmuy.js → railroadDiagram-RFXS5EU6-BQuFX39y.js} +4 -4
  69. package/dist-lib/{requirementDiagram-TGXJPOKE-tNxRI1gc.js → requirementDiagram-TGXJPOKE-BWwBQZXn.js} +269 -268
  70. package/dist-lib/{resume-session-sheet-Dr_81Gfm.js → resume-session-sheet-DTe_2QtJ.js} +2 -3
  71. package/dist-lib/sankeyDiagram-HTMAVEWB-BjRyuB6L.js +859 -0
  72. package/dist-lib/{sequenceDiagram-DBY2YBRQ-Dvl2_CXL.js → sequenceDiagram-DBY2YBRQ-69pcw_2M.js} +892 -899
  73. package/dist-lib/{session-token-usage-CGhHZ3lT.js → session-token-usage-DY4vFlfs.js} +82 -83
  74. package/dist-lib/{shadow-text-size-CBCTdbYU.js → shadow-text-size-smWA4wIU.js} +1 -2
  75. package/dist-lib/{shipped-page-p3oulUiM.js → shipped-page-B-ruG8li.js} +233 -236
  76. package/dist-lib/sizeCapture-X5ZJPWSS-DqkV8s1N.js +46 -0
  77. package/dist-lib/{stateDiagram-2N3HPSRC-CnWB7HvU.js → stateDiagram-2N3HPSRC-0vE3REl_.js} +4 -4
  78. package/dist-lib/{stateDiagram-v2-6OUMAXLB-DnZ0UI2p.js → stateDiagram-v2-6OUMAXLB-u_56Obsh.js} +2 -2
  79. package/dist-lib/{streamdown-response-Dbn0PKUH.js → streamdown-response-BQy3geXs.js} +290 -297
  80. package/dist-lib/styles.css +1 -1
  81. package/dist-lib/swimlanes-5IMT3BWC-H0raIBd1.js +5332 -0
  82. package/dist-lib/{swimlanesDiagram-G3AALYLV-CKyOeqF_.js → swimlanesDiagram-G3AALYLV-By52HaDu.js} +2 -2
  83. package/dist-lib/timeline-definition-FHXFAJF6-h1LLYUQk.js +1055 -0
  84. package/dist-lib/vennDiagram-L72KCM5P-B4wDw_Kh.js +1578 -0
  85. package/dist-lib/wardleyDiagram-EHGQE667-DLMBGiwD.js +678 -0
  86. package/dist-lib/{xychartDiagram-FW5EYKEG-m3s7caPv.js → xychartDiagram-FW5EYKEG-BHvf5Noj.js} +526 -496
  87. package/package.json +4 -3
  88. package/dist-lib/FileEditor-BIz0qCyW.js +0 -6892
  89. package/dist-lib/FileTreePane-BG2k7gTc.js +0 -8422
  90. package/dist-lib/chunk-2Q5K7J3B-Ex8Ly28R.js +0 -15
  91. package/dist-lib/chunk-JWPE2WC7-DFPBClX_.js +0 -9
  92. package/dist-lib/chunk-MOJQB5TN-dusfI9ob.js +0 -664
  93. package/dist-lib/chunk-RYQCIY6F-fkeERzIG.js +0 -315
  94. package/dist-lib/chunk-VR4S4FIN-hOZG7eF3.js +0 -20
  95. package/dist-lib/cynefin-VYW2F7L2-DQXPWaog.js +0 -23853
  96. package/dist-lib/dagre-VKFMJZFB-BhCjK7XQ.js +0 -346
  97. package/dist-lib/diagram-G47NLZAW-C3_z2t6T.js +0 -530
  98. package/dist-lib/diagram-NH7WQ7WH-DUdK08IT.js +0 -143
  99. package/dist-lib/diagram-OA4YK3LP-TUUyRYY3.js +0 -353
  100. package/dist-lib/flowDiagram-23GEKE2U-DU3S3biU.js +0 -1645
  101. package/dist-lib/gitGraphDiagram-IHSO6WYX-CvGu0XAR.js +0 -828
  102. package/dist-lib/index-DcwavxA1.js +0 -5062
  103. package/dist-lib/index-JkCQXUYs.js +0 -16566
  104. package/dist-lib/ishikawaDiagram-FXEZZL3T-D_Y6Tuyb.js +0 -622
  105. package/dist-lib/kanban-definition-HUTT4EX6-CPFLTskY.js +0 -726
  106. package/dist-lib/mermaid-GHXKKRXX-Ox_2d3uB.js +0 -4
  107. package/dist-lib/quadrantDiagram-ABIIQ3AL-BmDmLczk.js +0 -1025
  108. package/dist-lib/sankeyDiagram-HTMAVEWB-B9Bl7f2P.js +0 -847
  109. package/dist-lib/sizeCapture-X5ZJPWSS-B1EeO3N9.js +0 -47
  110. package/dist-lib/swimlanes-5IMT3BWC-CvqDJcS9.js +0 -5353
  111. package/dist-lib/timeline-definition-FHXFAJF6-b15X0Oru.js +0 -1066
  112. package/dist-lib/vennDiagram-L72KCM5P-C4lh5m77.js +0 -1585
  113. package/dist-lib/wardleyDiagram-EHGQE667-Cev6fT_D.js +0 -684
@@ -1,14 +1,14 @@
1
- import { jsxs as l, jsx as r, Fragment as me } from "react/jsx-runtime";
2
- import { useState as f, useEffect as w, useRef as fe, useContext as _e, useMemo as $e } from "react";
3
- import { y as ze, z as he, E as Te, F as S, H as ge, I as Se, J as je, N as Fe, B as Pe, L as pe, O as Ye, j as q, C as Ge, R as Be, T as Ke, Q as Ue, u as be, o as He, U as Ve, a as R, V as k, W as L, v as M, Y as W, Z as Je, _ as Qe, $ as Xe, a0 as qe, m as We, a1 as Ze } from "./embedded-BmrQsEvQ.js";
4
- import { cn as j } from "cnfast";
1
+ import { jsxs as o, jsx as r, Fragment as ce } from "react/jsx-runtime";
2
+ import { useState as f, useEffect as v, useRef as ue, useContext as _e, useMemo as $e } from "react";
3
+ import { z as ze, E as me, F as Se, H as _, I as fe, J as Te, N as Pe, O as je, B as Fe, L as he, Q as Ge, j as Q, C as Ye, R as Be, T as Ke, U as Ue, u as pe, p as He, V as Ve, a as C, W as N, Y as D, v as R, Z as X, _ as Je, $ as Qe, a0 as Xe, a1 as qe, m as Oe, a2 as We } from "./embedded-PUsgcSTE.js";
4
+ import { cn as $ } from "cnfast";
5
5
  /**
6
6
  * @license lucide-react v0.577.0 - ISC
7
7
  *
8
8
  * This source code is licensed under the ISC license.
9
9
  * See the LICENSE file in the root directory of this source tree.
10
10
  */
11
- const Oe = [
11
+ const Ze = [
12
12
  [
13
13
  "path",
14
14
  {
@@ -19,168 +19,168 @@ const Oe = [
19
19
  ["path", { d: "M7 11h10", key: "1twpyw" }],
20
20
  ["path", { d: "M7 15h6", key: "d9of3u" }],
21
21
  ["path", { d: "M7 7h8", key: "af5zfr" }]
22
- ], et = ze("message-square-text", Oe), O = "lfg-notification-read-state", tt = "lfg_notification_reads_v1:";
23
- function ve(s) {
24
- return `${tt}${(s == null ? void 0 : s.trim().toLowerCase()) || "__device__"}`;
22
+ ], et = ze("message-square-text", Ze), O = "lfg-notification-read-state", tt = "lfg_notification_reads_v1:";
23
+ function be(n) {
24
+ return `${tt}${n?.trim().toLowerCase() || "__device__"}`;
25
25
  }
26
- function rt(s) {
27
- if (!s || typeof s != "object") return null;
28
- const i = s, c = typeof i.through == "number" && Number.isFinite(i.through) ? Math.max(0, i.through) : 0, o = Array.isArray(i.ids) ? i.ids.filter((m) => typeof m == "string").slice(-500) : [];
29
- return { through: c, ids: [...new Set(o)] };
26
+ function rt(n) {
27
+ if (!n || typeof n != "object") return null;
28
+ const i = n, c = typeof i.through == "number" && Number.isFinite(i.through) ? Math.max(0, i.through) : 0, l = Array.isArray(i.ids) ? i.ids.filter((u) => typeof u == "string").slice(-500) : [];
29
+ return { through: c, ids: [...new Set(l)] };
30
30
  }
31
- function _(s) {
31
+ function L(n) {
32
32
  if (typeof window > "u") return null;
33
33
  try {
34
- return rt(JSON.parse(localStorage.getItem(ve(s)) ?? "null"));
34
+ return rt(JSON.parse(localStorage.getItem(be(n)) ?? "null"));
35
35
  } catch {
36
36
  return null;
37
37
  }
38
38
  }
39
- function ye(s, i) {
40
- return typeof window > "u" || (localStorage.setItem(ve(s), JSON.stringify(i)), window.dispatchEvent(
39
+ function xe(n, i) {
40
+ return typeof window > "u" || (localStorage.setItem(be(n), JSON.stringify(i)), window.dispatchEvent(
41
41
  new CustomEvent(O, {
42
- detail: { identity: (s == null ? void 0 : s.trim().toLowerCase()) || "__device__" }
42
+ detail: { identity: n?.trim().toLowerCase() || "__device__" }
43
43
  })
44
44
  )), i;
45
45
  }
46
- function F(s) {
47
- return `shipped:${s.id}:${s.rev}`;
46
+ function z(n) {
47
+ return `shipped:${n.id}:${n.rev}`;
48
48
  }
49
- function Z(s, i) {
50
- return s ? i.ts > s.through && !s.ids.includes(i.id) : !1;
49
+ function q(n, i) {
50
+ return n ? i.ts > n.through && !n.ids.includes(i.id) : !1;
51
51
  }
52
- function st(s, i) {
53
- const c = _(s) ?? { through: 0, ids: [] };
54
- return c.ids.includes(i) ? c : ye(s, {
52
+ function st(n, i) {
53
+ const c = L(n) ?? { through: 0, ids: [] };
54
+ return c.ids.includes(i) ? c : xe(n, {
55
55
  ...c,
56
56
  ids: [...c.ids, i].slice(-500)
57
57
  });
58
58
  }
59
- function xe(s, i) {
60
- const c = _(s) ?? { through: 0, ids: [] };
61
- return ye(s, {
59
+ function ge(n, i) {
60
+ const c = L(n) ?? { through: 0, ids: [] };
61
+ return xe(n, {
62
62
  through: Math.max(c.through, i),
63
63
  ids: c.ids
64
64
  });
65
65
  }
66
66
  function nt({
67
- path: s,
67
+ path: n,
68
68
  cacheKey: i,
69
69
  children: c
70
70
  }) {
71
- return /* @__PURE__ */ l("div", { className: "relative h-32 w-full overflow-hidden bg-background", children: [
72
- /* @__PURE__ */ r(Qe, { path: s, cacheKey: i, className: "h-full w-full" }),
71
+ return /* @__PURE__ */ o("div", { className: "relative h-32 w-full overflow-hidden bg-background", children: [
72
+ /* @__PURE__ */ r(Qe, { path: n, cacheKey: i, className: "h-full w-full" }),
73
73
  c
74
74
  ] });
75
75
  }
76
76
  function at({
77
- items: s,
77
+ items: n,
78
78
  total: i,
79
79
  onExpand: c
80
80
  }) {
81
- const o = s[0];
82
- if (!o) return null;
83
- const m = Math.max(0, i - 1);
84
- return /* @__PURE__ */ l(
81
+ const l = n[0];
82
+ if (!l) return null;
83
+ const u = Math.max(0, i - 1);
84
+ return /* @__PURE__ */ o(
85
85
  "button",
86
86
  {
87
87
  type: "button",
88
- onClick: () => c == null ? void 0 : c({
89
- url: o.url,
90
- kind: o.kind,
91
- caption: o.caption,
92
- name: o.name,
93
- version: o.version,
94
- cacheKey: o.updatedAt
88
+ onClick: () => c?.({
89
+ url: l.url,
90
+ kind: l.kind,
91
+ caption: l.caption,
92
+ name: l.name,
93
+ version: l.version,
94
+ cacheKey: l.updatedAt
95
95
  }),
96
- "aria-label": `Open ${o.caption || o.name}`,
97
- title: o.caption || o.name,
96
+ "aria-label": `Open ${l.caption || l.name}`,
97
+ title: l.caption || l.name,
98
98
  className: "relative size-[52px] shrink-0 overflow-hidden rounded-lg border border-border/60 bg-muted transition-transform active:scale-[0.97]",
99
99
  children: [
100
- o.kind === "image" ? /* @__PURE__ */ r(
100
+ l.kind === "image" ? /* @__PURE__ */ r(
101
101
  Xe,
102
102
  {
103
- path: o.url,
104
- alt: o.caption || o.name,
103
+ path: l.url,
104
+ alt: l.caption || l.name,
105
105
  thumb: !0,
106
106
  className: "size-full object-cover"
107
107
  }
108
- ) : o.kind === "html" ? (
108
+ ) : l.kind === "html" ? (
109
109
  // Deliberately an icon, not a live preview. A document scaled into a
110
110
  // 52px box is two words of giant text — unreadable, and it costs a
111
111
  // fetch + parse per row. The Artifacts page is where previews belong.
112
112
  /* @__PURE__ */ r("span", { className: "flex size-full items-center justify-center bg-primary/10 text-primary", children: /* @__PURE__ */ r(qe, { className: "size-4" }) })
113
- ) : /* @__PURE__ */ r("span", { className: "flex size-full items-center justify-center bg-black/80 text-white/80", children: /* @__PURE__ */ r(We, { className: "size-4" }) }),
114
- m > 0 ? /* @__PURE__ */ l("span", { className: "absolute inset-x-0 bottom-0 bg-black/55 py-0.5 text-center text-[9px] font-semibold text-white", children: [
113
+ ) : /* @__PURE__ */ r("span", { className: "flex size-full items-center justify-center bg-black/80 text-white/80", children: /* @__PURE__ */ r(Oe, { className: "size-4" }) }),
114
+ u > 0 ? /* @__PURE__ */ o("span", { className: "absolute inset-x-0 bottom-0 bg-black/55 py-0.5 text-center text-[9px] font-semibold text-white", children: [
115
115
  "+",
116
- m
116
+ u
117
117
  ] }) : null
118
118
  ]
119
119
  }
120
120
  );
121
121
  }
122
- function it(s, i) {
122
+ function it(n, i) {
123
123
  const c = (p) => {
124
- const v = new Date(p);
125
- return new Date(v.getFullYear(), v.getMonth(), v.getDate()).getTime();
126
- }, o = Math.round((c(i) - c(s)) / 864e5);
127
- if (o <= 0) return "Today";
128
- if (o === 1) return "Yesterday";
129
- const m = new Date(s);
130
- return m.toLocaleDateString(void 0, {
124
+ const g = new Date(p);
125
+ return new Date(g.getFullYear(), g.getMonth(), g.getDate()).getTime();
126
+ }, l = Math.round((c(i) - c(n)) / 864e5);
127
+ if (l <= 0) return "Today";
128
+ if (l === 1) return "Yesterday";
129
+ const u = new Date(n);
130
+ return u.toLocaleDateString(void 0, {
131
131
  month: "long",
132
132
  day: "numeric",
133
- ...m.getFullYear() === new Date(i).getFullYear() ? {} : { year: "numeric" }
133
+ ...u.getFullYear() === new Date(i).getFullYear() ? {} : { year: "numeric" }
134
134
  });
135
135
  }
136
136
  function ut({
137
- onOpenSession: s,
137
+ onOpenSession: n,
138
138
  onOpenArtifactSession: i,
139
139
  onReviewSession: c,
140
- liveSessionIds: o,
141
- notificationIdentity: m,
140
+ liveSessionIds: l,
141
+ notificationIdentity: u,
142
142
  artifactsOnly: p = !1,
143
- active: v = !0
143
+ active: g = !0
144
144
  }) {
145
- const h = p ? "artifacts" : "feed", b = p ? he(L) : null, x = p ? null : he(W), [u, P] = f(() => (x == null ? void 0 : x.items) ?? null), [Y, ee] = f(() => (x == null ? void 0 : x.total) ?? 0), [G, te] = f(!1), [A, I] = f(
146
- () => p ? null : _(m)
147
- ), [B, re] = f(!1), [K, se] = f(null), { questions: y, busy: Ne, dismissAll: we } = Te(), [U, $] = f(!1);
148
- w(() => {
149
- $(!1);
150
- }, [y.length]);
151
- const [N, E] = f(() => (b == null ? void 0 : b.items) ?? null), [C, H] = f(() => (b == null ? void 0 : b.total) ?? 0), [V, ne] = f(!1), [ae, ie] = f(null), [le, oe] = f(null), de = "&kind=html", D = fe(Math.max(S, (b == null ? void 0 : b.items.length) ?? 0)), J = fe(Math.max(ge, (x == null ? void 0 : x.items.length) ?? 0)), ce = _e(Se), ke = je();
152
- w(() => {
153
- h === "feed" && I(_(m));
154
- }, [m, h]), w(() => {
155
- if (h !== "feed" || u === null || A) return;
156
- const e = u.reduce((t, d) => Math.max(t, d.ts), Date.now());
157
- I(xe(m, e));
158
- }, [m, A, u, h]), w(() => {
145
+ const h = p ? "artifacts" : "feed", S = p ? me(D) : null, T = p ? null : me(X), [m, P] = f(() => T?.items ?? null), [j, W] = f(() => T?.total ?? 0), [F, Z] = f(!1), [w, k] = f(
146
+ () => p ? null : L(u)
147
+ ), [G, ee] = f(!1), [Y, te] = f(null), { questions: b, busy: ye, dismissAll: ve } = Se(), [B, M] = f(!1);
148
+ v(() => {
149
+ M(!1);
150
+ }, [b.length]);
151
+ const [y, A] = f(() => S?.items ?? null), [E, K] = f(() => S?.total ?? 0), [U, re] = f(!1), [se, ne] = f(null), [ae, ie] = f(null), oe = "&kind=html", I = ue(Math.max(_, S?.items.length ?? 0)), H = ue(Math.max(fe, T?.items.length ?? 0)), le = _e(Te), Ne = Pe();
152
+ v(() => {
153
+ h === "feed" && k(L(u));
154
+ }, [u, h]), v(() => {
155
+ if (h !== "feed" || m === null || w) return;
156
+ const e = m.reduce((t, d) => Math.max(t, d.ts), Date.now());
157
+ k(ge(u, e));
158
+ }, [u, w, m, h]), v(() => {
159
159
  if (h !== "feed") return;
160
- const e = () => I(_(m));
160
+ const e = () => k(L(u));
161
161
  return window.addEventListener("storage", e), window.addEventListener(O, e), () => {
162
162
  window.removeEventListener("storage", e), window.removeEventListener(O, e);
163
163
  };
164
- }, [m, h]), w(() => {
164
+ }, [u, h]), v(() => {
165
165
  if (h !== "artifacts") return;
166
166
  let e = !0;
167
167
  const t = async () => {
168
168
  try {
169
- const a = await R(
170
- `/api/artifacts?limit=${S}${de}`,
169
+ const a = await C(
170
+ `/api/artifacts?limit=${_}${oe}`,
171
171
  { cache: "no-store" }
172
172
  );
173
173
  if (!e) return;
174
- const n = Array.isArray(a.artifacts) ? a.artifacts : [], g = a.total ?? n.length;
175
- E((z) => {
176
- const T = new Set(n.map((X) => X.id)), Me = (z ?? []).filter((X) => !T.has(X.id)), Q = [...n, ...Me];
177
- return D.current = Math.max(S, Q.length), k(L, Q, g), Q;
178
- }), H(g);
174
+ const s = Array.isArray(a.artifacts) ? a.artifacts : [], x = a.total ?? s.length;
175
+ A((Re) => {
176
+ const Le = new Set(s.map((J) => J.id)), Me = (Re ?? []).filter((J) => !Le.has(J.id)), V = [...s, ...Me];
177
+ return I.current = Math.max(_, V.length), N(D, V, x), V;
178
+ }), K(x);
179
179
  } catch {
180
- e && E((a) => a ?? []);
180
+ e && A((a) => a ?? []);
181
181
  }
182
182
  };
183
- if (t(), !v)
183
+ if (t(), !g)
184
184
  return () => {
185
185
  e = !1;
186
186
  };
@@ -188,182 +188,179 @@ function ut({
188
188
  return () => {
189
189
  e = !1, clearInterval(d);
190
190
  };
191
- }, [h, v]);
192
- const Ae = async () => {
193
- if (!V) {
194
- ne(!0);
191
+ }, [h, g]);
192
+ const we = async () => {
193
+ if (!U) {
194
+ re(!0);
195
195
  try {
196
- const e = await R(
197
- `/api/artifacts?limit=${S}&offset=${D.current}${de}`,
196
+ const e = await C(
197
+ `/api/artifacts?limit=${_}&offset=${I.current}${oe}`,
198
198
  { cache: "no-store" }
199
199
  );
200
- E((t) => {
201
- const d = new Set((t ?? []).map((n) => n.id)), a = [...t ?? [], ...e.artifacts.filter((n) => !d.has(n.id))];
202
- return D.current = a.length, k(L, a, e.total ?? C), a;
203
- }), H((t) => e.total ?? t);
200
+ A((t) => {
201
+ const d = new Set((t ?? []).map((s) => s.id)), a = [...t ?? [], ...e.artifacts.filter((s) => !d.has(s.id))];
202
+ return I.current = a.length, N(D, a, e.total ?? E), a;
203
+ }), K((t) => e.total ?? t);
204
204
  } catch {
205
205
  } finally {
206
- ne(!1);
206
+ re(!1);
207
207
  }
208
208
  }
209
- }, Ie = async (e) => {
209
+ }, ke = async (e) => {
210
210
  const t = e.title || e.caption || e.name;
211
- if (await ke.confirm({
211
+ if (await Ne.confirm({
212
212
  title: `Delete ${t}?`,
213
213
  description: "This permanently removes the artifact and stops its automatic refresh schedule.",
214
214
  confirmLabel: "Delete artifact",
215
215
  destructive: !0
216
216
  })) {
217
- oe(e.id);
217
+ ie(e.id);
218
218
  try {
219
- await R(
219
+ await C(
220
220
  `/api/sessions/${encodeURIComponent(e.sessionId ?? "")}/artifacts/${encodeURIComponent(e.id)}`,
221
221
  {
222
222
  method: "DELETE",
223
223
  headers: { "X-LFG-Session-ID": e.sessionId ?? "" }
224
224
  }
225
- ), E((a) => {
226
- const n = (a == null ? void 0 : a.filter((g) => g.id !== e.id)) ?? null;
227
- return n && k(L, n, Math.max(0, C - 1)), n;
228
- }), H((a) => Math.max(0, a - 1)), D.current = Math.max(0, D.current - 1), M.success("Artifact deleted");
225
+ ), A((a) => {
226
+ const s = a?.filter((x) => x.id !== e.id) ?? null;
227
+ return s && N(D, s, Math.max(0, E - 1)), s;
228
+ }), K((a) => Math.max(0, a - 1)), I.current = Math.max(0, I.current - 1), R.success("Artifact deleted");
229
229
  } catch (a) {
230
- M.error(a instanceof Error ? a.message : "Couldn't delete artifact");
230
+ R.error(a instanceof Error ? a.message : "Couldn't delete artifact");
231
231
  } finally {
232
- oe(null);
232
+ ie(null);
233
233
  }
234
234
  }
235
- }, Ee = async (e) => {
235
+ }, Ae = async (e) => {
236
236
  if (!(!e.sessionId || e.refreshEnabled === void 0)) {
237
- ie(e.id);
237
+ ne(e.id);
238
238
  try {
239
- const t = await R(
239
+ const t = await C(
240
240
  `/api/sessions/${encodeURIComponent(e.sessionId)}/artifacts/html/${encodeURIComponent(e.id)}/refresh`,
241
241
  {
242
242
  method: "POST",
243
243
  headers: { "X-LFG-Session-ID": e.sessionId }
244
244
  }
245
245
  );
246
- E((d) => {
247
- const a = (d == null ? void 0 : d.map((n) => {
248
- var g, z, T;
249
- return n.id === e.id ? {
250
- ...n,
251
- ts: t.artifact.updatedAt ?? n.ts,
252
- version: t.artifact.version ?? n.version,
253
- size: t.artifact.size ?? n.size,
254
- lastRefreshedAt: ((g = t.artifact.refresh) == null ? void 0 : g.lastSuccessAt) ?? n.lastRefreshedAt,
255
- refreshStatus: ((z = t.artifact.refresh) == null ? void 0 : z.status) ?? n.refreshStatus,
256
- refreshEnabled: ((T = t.artifact.refresh) == null ? void 0 : T.enabled) ?? n.refreshEnabled
257
- } : n;
258
- })) ?? null;
259
- return a && k(L, a, C), a;
260
- }), M.success("Artifact refreshed");
246
+ A((d) => {
247
+ const a = d?.map((s) => s.id === e.id ? {
248
+ ...s,
249
+ ts: t.artifact.updatedAt ?? s.ts,
250
+ version: t.artifact.version ?? s.version,
251
+ size: t.artifact.size ?? s.size,
252
+ lastRefreshedAt: t.artifact.refresh?.lastSuccessAt ?? s.lastRefreshedAt,
253
+ refreshStatus: t.artifact.refresh?.status ?? s.refreshStatus,
254
+ refreshEnabled: t.artifact.refresh?.enabled ?? s.refreshEnabled
255
+ } : s) ?? null;
256
+ return a && N(D, a, E), a;
257
+ }), R.success("Artifact refreshed");
261
258
  } catch (t) {
262
- M.error(t instanceof Error ? t.message : "Couldn't refresh artifact");
259
+ R.error(t instanceof Error ? t.message : "Couldn't refresh artifact");
263
260
  } finally {
264
- ie(null);
261
+ ne(null);
265
262
  }
266
263
  }
267
264
  };
268
- w(() => {
269
- if (!(h !== "feed" || !v))
270
- return Fe((e) => {
265
+ v(() => {
266
+ if (!(h !== "feed" || !g))
267
+ return je((e) => {
271
268
  if (!e.ok) {
272
- P((t) => (t === null && se(e.error), t));
269
+ P((t) => (t === null && te(e.error), t));
273
270
  return;
274
271
  }
275
272
  P((t) => {
276
- const d = new Set(e.posts.map((g) => g.id)), a = (t ?? []).filter((g) => !d.has(g.id)), n = [...e.posts, ...a];
277
- return J.current = Math.max(Ze, n.length), k(W, n, e.total), n;
278
- }), ee(e.total), se(null);
273
+ const d = new Set(e.posts.map((x) => x.id)), a = (t ?? []).filter((x) => !d.has(x.id)), s = [...e.posts, ...a];
274
+ return H.current = Math.max(We, s.length), N(X, s, e.total), s;
275
+ }), W(e.total), te(null);
279
276
  });
280
- }, [h, v]);
281
- const Ce = async () => {
282
- if (!G) {
283
- te(!0);
277
+ }, [h, g]);
278
+ const Ee = async () => {
279
+ if (!F) {
280
+ Z(!0);
284
281
  try {
285
- const e = await R(
286
- `/api/shipped?limit=${ge}&offset=${J.current}`,
282
+ const e = await C(
283
+ `/api/shipped?limit=${fe}&offset=${H.current}`,
287
284
  { cache: "no-store" }
288
285
  );
289
286
  P((t) => {
290
- const d = new Set((t ?? []).map((n) => n.id)), a = [...t ?? [], ...e.posts.filter((n) => !d.has(n.id))];
291
- return J.current = a.length, k(W, a, e.total ?? Y), a;
292
- }), ee((t) => e.total ?? t);
287
+ const d = new Set((t ?? []).map((s) => s.id)), a = [...t ?? [], ...e.posts.filter((s) => !d.has(s.id))];
288
+ return H.current = a.length, N(X, a, e.total ?? j), a;
289
+ }), W((t) => e.total ?? t);
293
290
  } catch {
294
291
  } finally {
295
- te(!1);
292
+ Z(!1);
296
293
  }
297
294
  }
298
- }, ue = (u == null ? void 0 : u.filter(
299
- (e) => Z(A, {
300
- id: F(e),
295
+ }, de = m?.filter(
296
+ (e) => q(w, {
297
+ id: z(e),
301
298
  ts: e.ts
302
299
  })
303
- ).length) ?? 0, De = $e(() => {
304
- if (!(u != null && u.length)) return [];
300
+ ).length ?? 0, Ie = $e(() => {
301
+ if (!m?.length) return [];
305
302
  const e = Date.now(), t = [];
306
- for (const d of u) {
307
- const a = it(d.ts, e), n = t[t.length - 1];
308
- n && n.label === a ? n.items.push(d) : t.push({ label: a, items: [d] });
303
+ for (const d of m) {
304
+ const a = it(d.ts, e), s = t[t.length - 1];
305
+ s && s.label === a ? s.items.push(d) : t.push({ label: a, items: [d] });
309
306
  }
310
307
  return t;
311
- }, [u]), Re = (e) => {
312
- Z(A, {
313
- id: F(e),
308
+ }, [m]), Ce = (e) => {
309
+ q(w, {
310
+ id: z(e),
314
311
  ts: e.ts
315
- }) && I(
316
- st(m, F(e))
312
+ }) && k(
313
+ st(u, z(e))
317
314
  );
318
- }, Le = async () => {
319
- if (!B) {
320
- re(!0);
315
+ }, De = async () => {
316
+ if (!G) {
317
+ ee(!0);
321
318
  try {
322
- const e = Math.max(Date.now(), ...(u ?? []).map((t) => t.ts));
323
- I(xe(m, e)), await Je(), M.success("Notifications marked read");
319
+ const e = Math.max(Date.now(), ...(m ?? []).map((t) => t.ts));
320
+ k(ge(u, e)), await Je(), R.success("Notifications marked read");
324
321
  } finally {
325
- re(!1);
322
+ ee(!1);
326
323
  }
327
324
  }
328
325
  };
329
- return /* @__PURE__ */ l("div", { className: "mx-auto max-w-xl space-y-4 pb-10", "data-lfg-page-column": !0, children: [
330
- /* @__PURE__ */ l("div", { className: "flex items-center justify-between px-1", children: [
331
- /* @__PURE__ */ l("div", { children: [
326
+ return /* @__PURE__ */ o("div", { className: "mx-auto max-w-xl space-y-4 pb-10", "data-lfg-page-column": !0, children: [
327
+ /* @__PURE__ */ o("div", { className: "flex items-center justify-between px-1", children: [
328
+ /* @__PURE__ */ o("div", { children: [
332
329
  /* @__PURE__ */ r("h1", { className: "text-lg font-semibold tracking-[-0.01em]", children: p ? "Artifacts" : "Notifications" }),
333
- p ? /* @__PURE__ */ r("p", { className: "mt-0.5 text-xs text-muted-foreground", children: "Interactive reports and live dashboards" }) : /* @__PURE__ */ r("p", { className: "mt-0.5 text-xs text-muted-foreground", children: y.length ? `${y.length} waiting on you` : ue ? `${ue} unread` : "You're all caught up" })
330
+ p ? /* @__PURE__ */ r("p", { className: "mt-0.5 text-xs text-muted-foreground", children: "Interactive reports and live dashboards" }) : /* @__PURE__ */ r("p", { className: "mt-0.5 text-xs text-muted-foreground", children: b.length ? `${b.length} waiting on you` : de ? `${de} unread` : "You're all caught up" })
334
331
  ] }),
335
- !p && u !== null ? (
332
+ !p && m !== null ? (
336
333
  // Icon only. It is a rare, undoable housekeeping action — it does not
337
334
  // need to be the second-loudest thing on the page.
338
335
  /* @__PURE__ */ r(
339
- Pe,
336
+ Fe,
340
337
  {
341
338
  size: "icon-sm",
342
339
  variant: "ghost",
343
340
  "aria-label": "Mark all read",
344
341
  title: "Mark all read — clears the app icon badge",
345
- disabled: B,
346
- onClick: () => void Le(),
347
- children: B ? /* @__PURE__ */ r(pe, { className: "size-4 animate-spin" }) : /* @__PURE__ */ r(Ye, { className: "size-4" })
342
+ disabled: G,
343
+ onClick: () => void De(),
344
+ children: G ? /* @__PURE__ */ r(he, { className: "size-4 animate-spin" }) : /* @__PURE__ */ r(Ge, { className: "size-4" })
348
345
  }
349
346
  )
350
347
  ) : null
351
348
  ] }),
352
- h === "artifacts" ? /* @__PURE__ */ l(me, { children: [
353
- N === null ? /* @__PURE__ */ r("div", { className: "py-10 text-center text-sm text-muted-foreground", children: "Loading…" }) : N.length === 0 ? /* @__PURE__ */ l("div", { className: "rounded-2xl border border-border bg-card/40 px-4 py-10 text-center text-sm text-muted-foreground", children: [
349
+ h === "artifacts" ? /* @__PURE__ */ o(ce, { children: [
350
+ y === null ? /* @__PURE__ */ r("div", { className: "py-10 text-center text-sm text-muted-foreground", children: "Loading…" }) : y.length === 0 ? /* @__PURE__ */ o("div", { className: "rounded-2xl border border-border bg-card/40 px-4 py-10 text-center text-sm text-muted-foreground", children: [
354
351
  "No artifacts yet — agents create them with ",
355
352
  /* @__PURE__ */ r("code", { children: "omg_publish_artifact" }),
356
353
  "."
357
- ] }) : /* @__PURE__ */ r("div", { className: "grid grid-cols-2 gap-2 sm:grid-cols-3", children: N.map((e) => /* @__PURE__ */ l(
354
+ ] }) : /* @__PURE__ */ r("div", { className: "grid grid-cols-2 gap-2 sm:grid-cols-3", children: y.map((e) => /* @__PURE__ */ o(
358
355
  "div",
359
356
  {
360
357
  className: "group relative overflow-hidden rounded-xl border border-border bg-card/40 text-left shadow-sm transition-colors hover:border-foreground/20",
361
358
  children: [
362
- /* @__PURE__ */ l(
359
+ /* @__PURE__ */ o(
363
360
  "button",
364
361
  {
365
362
  type: "button",
366
- onClick: () => ce({
363
+ onClick: () => le({
367
364
  url: e.url,
368
365
  kind: e.kind,
369
366
  title: e.title,
@@ -374,54 +371,54 @@ function ut({
374
371
  }),
375
372
  className: "block w-full text-left active:scale-[0.99]",
376
373
  children: [
377
- /* @__PURE__ */ r(nt, { path: e.url, cacheKey: e.ts, children: (e.version ?? 1) > 1 ? /* @__PURE__ */ l("span", { className: "absolute left-1.5 top-1.5 flex items-center gap-1 rounded-full bg-emerald-500/15 px-1.5 py-0.5 text-[10px] font-medium text-emerald-600 backdrop-blur dark:text-emerald-400", children: [
374
+ /* @__PURE__ */ r(nt, { path: e.url, cacheKey: e.ts, children: (e.version ?? 1) > 1 ? /* @__PURE__ */ o("span", { className: "absolute left-1.5 top-1.5 flex items-center gap-1 rounded-full bg-emerald-500/15 px-1.5 py-0.5 text-[10px] font-medium text-emerald-600 backdrop-blur dark:text-emerald-400", children: [
378
375
  /* @__PURE__ */ r("span", { className: "size-1.5 rounded-full bg-emerald-500" }),
379
376
  "live · v",
380
377
  e.version
381
378
  ] }) : null }),
382
- /* @__PURE__ */ l("div", { className: "px-2.5 py-2 pr-9", children: [
379
+ /* @__PURE__ */ o("div", { className: "px-2.5 py-2 pr-9", children: [
383
380
  /* @__PURE__ */ r("div", { className: "truncate text-xs font-medium", children: e.title || e.caption || e.name }),
384
- /* @__PURE__ */ r("div", { className: "mt-0.5 truncate text-[10px] text-muted-foreground", children: e.lastRefreshedAt ? `Refreshed ${q(e.lastRefreshedAt)}` : `Published ${q(e.ts)}` })
381
+ /* @__PURE__ */ r("div", { className: "mt-0.5 truncate text-[10px] text-muted-foreground", children: e.lastRefreshedAt ? `Refreshed ${Q(e.lastRefreshedAt)}` : `Published ${Q(e.ts)}` })
385
382
  ] })
386
383
  ]
387
384
  }
388
385
  ),
389
- e.sessionId ? /* @__PURE__ */ l(
386
+ e.sessionId ? /* @__PURE__ */ o(
390
387
  "button",
391
388
  {
392
389
  type: "button",
393
- onClick: () => i == null ? void 0 : i(e),
390
+ onClick: () => i?.(e),
394
391
  "aria-label": `Open related session for ${e.title || e.caption || e.name}`,
395
392
  title: e.sessionTitle || e.project || "Open related session",
396
393
  className: "flex w-full items-center gap-1.5 border-t border-border/60 px-2.5 py-2 text-[10px] font-medium text-muted-foreground transition-colors hover:bg-foreground/[0.03] hover:text-foreground",
397
394
  children: [
398
395
  /* @__PURE__ */ r(et, { className: "size-3 shrink-0", "aria-hidden": !0 }),
399
396
  /* @__PURE__ */ r("span", { className: "min-w-0 flex-1 truncate text-left", children: e.sessionTitle || e.project || "Related session" }),
400
- /* @__PURE__ */ r(Ge, { className: "size-3 shrink-0", "aria-hidden": !0 })
397
+ /* @__PURE__ */ r(Ye, { className: "size-3 shrink-0", "aria-hidden": !0 })
401
398
  ]
402
399
  }
403
400
  ) : null,
404
- /* @__PURE__ */ l("div", { className: "absolute right-1.5 top-1.5 flex items-center gap-0.5 rounded-full bg-background/80 backdrop-blur", children: [
401
+ /* @__PURE__ */ o("div", { className: "absolute right-1.5 top-1.5 flex items-center gap-0.5 rounded-full bg-background/80 backdrop-blur", children: [
405
402
  e.refreshEnabled !== void 0 ? /* @__PURE__ */ r(
406
403
  "button",
407
404
  {
408
405
  type: "button",
409
- onClick: () => void Ee(e),
410
- disabled: ae === e.id,
406
+ onClick: () => void Ae(e),
407
+ disabled: se === e.id,
411
408
  "aria-label": `Refresh ${e.title || e.caption || e.name}`,
412
409
  className: "flex size-7 items-center justify-center rounded-full text-muted-foreground opacity-100 transition-[color,background-color,transform,opacity] duration-150 hover:bg-foreground/[0.06] hover:text-foreground active:scale-[0.94] disabled:opacity-50 sm:opacity-0 sm:group-hover:opacity-100 sm:focus:opacity-100",
413
- children: /* @__PURE__ */ r(Be, { className: j("size-3.5", ae === e.id && "animate-spin") })
410
+ children: /* @__PURE__ */ r(Be, { className: $("size-3.5", se === e.id && "animate-spin") })
414
411
  }
415
412
  ) : null,
416
413
  /* @__PURE__ */ r(
417
414
  "button",
418
415
  {
419
416
  type: "button",
420
- onClick: () => void Ie(e),
421
- disabled: le === e.id,
417
+ onClick: () => void ke(e),
418
+ disabled: ae === e.id,
422
419
  "aria-label": `Delete ${e.title || e.caption || e.name}`,
423
420
  className: "flex size-7 items-center justify-center rounded-full text-muted-foreground opacity-100 transition-[color,background-color,transform,opacity] duration-150 hover:bg-destructive/10 hover:text-destructive active:scale-[0.94] disabled:opacity-50 sm:opacity-0 sm:group-hover:opacity-100 sm:focus:opacity-100",
424
- children: le === e.id ? /* @__PURE__ */ r(pe, { className: "size-3.5 animate-spin" }) : /* @__PURE__ */ r(Ke, { className: "size-3.5" })
421
+ children: ae === e.id ? /* @__PURE__ */ r(he, { className: "size-3.5 animate-spin" }) : /* @__PURE__ */ r(Ke, { className: "size-3.5" })
425
422
  }
426
423
  )
427
424
  ] })
@@ -429,82 +426,82 @@ function ut({
429
426
  },
430
427
  e.id
431
428
  )) }),
432
- N !== null && N.length < C ? /* @__PURE__ */ r(
429
+ y !== null && y.length < E ? /* @__PURE__ */ r(
433
430
  "button",
434
431
  {
435
432
  type: "button",
436
- onClick: () => void Ae(),
437
- disabled: V,
433
+ onClick: () => void we(),
434
+ disabled: U,
438
435
  className: "w-full rounded-xl border border-border bg-card/40 px-4 py-2.5 text-sm font-medium text-muted-foreground transition-colors hover:border-foreground/20 hover:text-foreground disabled:opacity-60",
439
- children: V ? "Loading…" : `Load more · ${C - N.length} left`
436
+ children: U ? "Loading…" : `Load more · ${E - y.length} left`
440
437
  }
441
438
  ) : null
442
- ] }) : /* @__PURE__ */ l(me, { children: [
443
- K ? /* @__PURE__ */ r("div", { className: "rounded-xl border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive", children: K }) : null,
444
- u === null && !K ? /* @__PURE__ */ r("div", { className: "py-10 text-center text-sm text-muted-foreground", children: "Loading…" }) : null,
445
- y.length ? /* @__PURE__ */ l("section", { className: "space-y-1.5", children: [
446
- /* @__PURE__ */ l("div", { className: "flex items-center justify-between gap-2 px-1", children: [
439
+ ] }) : /* @__PURE__ */ o(ce, { children: [
440
+ Y ? /* @__PURE__ */ r("div", { className: "rounded-xl border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive", children: Y }) : null,
441
+ m === null && !Y ? /* @__PURE__ */ r("div", { className: "py-10 text-center text-sm text-muted-foreground", children: "Loading…" }) : null,
442
+ b.length ? /* @__PURE__ */ o("section", { className: "space-y-1.5", children: [
443
+ /* @__PURE__ */ o("div", { className: "flex items-center justify-between gap-2 px-1", children: [
447
444
  /* @__PURE__ */ r("h2", { className: "text-[11px] font-semibold uppercase tracking-wide text-primary", children: "Needs you" }),
448
- y.length > 1 ? /* @__PURE__ */ r(
445
+ b.length > 1 ? /* @__PURE__ */ r(
449
446
  "button",
450
447
  {
451
448
  type: "button",
452
- disabled: Ne,
449
+ disabled: ye,
453
450
  onClick: () => {
454
- if (!U) {
455
- $(!0);
451
+ if (!B) {
452
+ M(!0);
456
453
  return;
457
454
  }
458
- $(!1), we();
455
+ M(!1), ve();
459
456
  },
460
- onBlur: () => $(!1),
461
- className: j(
457
+ onBlur: () => M(!1),
458
+ className: $(
462
459
  "-my-1 rounded-full px-2 py-1 text-[11px] font-medium transition-colors disabled:opacity-50",
463
- U ? "bg-destructive/10 text-destructive" : "text-muted-foreground hover:text-foreground"
460
+ B ? "bg-destructive/10 text-destructive" : "text-muted-foreground hover:text-foreground"
464
461
  ),
465
- children: U ? `Dismiss all ${y.length}?` : "Dismiss all"
462
+ children: B ? `Dismiss all ${b.length}?` : "Dismiss all"
466
463
  }
467
464
  ) : null
468
465
  ] }),
469
- /* @__PURE__ */ r("div", { className: "overflow-hidden rounded-2xl border border-primary/25 bg-primary/[0.03] shadow-sm", children: [...y].sort((e, t) => t.createdAt - e.createdAt).map((e) => /* @__PURE__ */ r(Ue, { q: e, onOpenSession: s }, e.id)) })
466
+ /* @__PURE__ */ r("div", { className: "overflow-hidden rounded-2xl border border-primary/25 bg-primary/[0.03] shadow-sm", children: [...b].sort((e, t) => t.createdAt - e.createdAt).map((e) => /* @__PURE__ */ r(Ue, { q: e, onOpenSession: n }, e.id)) })
470
467
  ] }) : null,
471
- u !== null && u.length === 0 && !y.length ? /* @__PURE__ */ r("div", { className: "rounded-2xl border border-border bg-card/40 px-4 py-10 text-center text-sm text-muted-foreground", children: "No notifications yet — verified results and future activity will collect here." }) : null,
472
- De.map((e) => /* @__PURE__ */ l("section", { className: "space-y-1.5", children: [
468
+ m !== null && m.length === 0 && !b.length ? /* @__PURE__ */ r("div", { className: "rounded-2xl border border-border bg-card/40 px-4 py-10 text-center text-sm text-muted-foreground", children: "No notifications yet — verified results and future activity will collect here." }) : null,
469
+ Ie.map((e) => /* @__PURE__ */ o("section", { className: "space-y-1.5", children: [
473
470
  /* @__PURE__ */ r("h2", { className: "px-1 text-[11px] font-semibold uppercase tracking-wide text-muted-foreground", children: e.label }),
474
471
  /* @__PURE__ */ r("div", { className: "overflow-hidden rounded-2xl border border-border bg-card/40 shadow-sm", children: e.items.map((t) => {
475
- const d = !!t.sessionId && o.has(t.sessionId), a = Z(A, {
476
- id: F(t),
472
+ const d = !!t.sessionId && l.has(t.sessionId), a = q(w, {
473
+ id: z(t),
477
474
  ts: t.ts
478
- }), n = t.mediaItems.length > 0;
479
- return /* @__PURE__ */ l("article", { className: "relative border-b border-border/50 last:border-b-0", children: [
480
- /* @__PURE__ */ l(
475
+ }), s = t.mediaItems.length > 0;
476
+ return /* @__PURE__ */ o("article", { className: "relative border-b border-border/50 last:border-b-0", children: [
477
+ /* @__PURE__ */ o(
481
478
  "button",
482
479
  {
483
480
  type: "button",
484
481
  onClick: () => {
485
- Re(t), t.sessionId && (c ? c(t) : d && s(t.sessionId));
482
+ Ce(t), t.sessionId && (c ? c(t) : d && n(t.sessionId));
486
483
  },
487
- className: j(
484
+ className: $(
488
485
  "flex w-full items-start gap-2.5 py-2.5 pl-2.5 text-left transition-colors hover:bg-foreground/[0.02]",
489
- n ? "pr-[4.75rem]" : "pr-3.5"
486
+ s ? "pr-[4.75rem]" : "pr-3.5"
490
487
  ),
491
488
  children: [
492
489
  /* @__PURE__ */ r(
493
490
  "span",
494
491
  {
495
- className: j(
492
+ className: $(
496
493
  "mt-3 size-1.5 shrink-0 rounded-full",
497
494
  a && "bg-primary"
498
495
  ),
499
496
  title: a ? "Unread" : void 0
500
497
  }
501
498
  ),
502
- /* @__PURE__ */ l("span", { className: "relative mt-0.5 shrink-0", children: [
499
+ /* @__PURE__ */ o("span", { className: "relative mt-0.5 shrink-0", children: [
503
500
  /* @__PURE__ */ r(
504
501
  "img",
505
502
  {
506
503
  src: He(t.agent),
507
- alt: be(t.agent),
504
+ alt: pe(t.agent),
508
505
  className: "size-7 rounded-full border border-border bg-background p-1"
509
506
  }
510
507
  ),
@@ -516,14 +513,14 @@ function ut({
516
513
  }
517
514
  ) : null
518
515
  ] }),
519
- /* @__PURE__ */ l("div", { className: "min-w-0 flex-1", children: [
520
- /* @__PURE__ */ l("div", { className: "flex items-baseline gap-1.5 text-[11px] text-muted-foreground", children: [
521
- /* @__PURE__ */ r("span", { className: "min-w-0 shrink truncate font-medium text-foreground/75", children: be(t.agent) }),
522
- t.project ? /* @__PURE__ */ l("span", { className: "min-w-0 shrink truncate", children: [
516
+ /* @__PURE__ */ o("div", { className: "min-w-0 flex-1", children: [
517
+ /* @__PURE__ */ o("div", { className: "flex items-baseline gap-1.5 text-[11px] text-muted-foreground", children: [
518
+ /* @__PURE__ */ r("span", { className: "min-w-0 shrink truncate font-medium text-foreground/75", children: pe(t.agent) }),
519
+ t.project ? /* @__PURE__ */ o("span", { className: "min-w-0 shrink truncate", children: [
523
520
  "· ",
524
521
  t.project
525
522
  ] }) : null,
526
- /* @__PURE__ */ r("span", { className: "ml-auto shrink-0 tabular-nums", children: q(t.ts) })
523
+ /* @__PURE__ */ r("span", { className: "ml-auto shrink-0 tabular-nums", children: Q(t.ts) })
527
524
  ] }),
528
525
  /* @__PURE__ */ r("h3", { className: "mt-0.5 line-clamp-2 text-[13.5px] font-semibold leading-snug tracking-[-0.01em]", children: t.title }),
529
526
  t.summary ? (
@@ -536,25 +533,25 @@ function ut({
536
533
  ]
537
534
  }
538
535
  ),
539
- n ? /* @__PURE__ */ r("div", { className: "absolute right-3.5 top-2.5", children: /* @__PURE__ */ r(
536
+ s ? /* @__PURE__ */ r("div", { className: "absolute right-3.5 top-2.5", children: /* @__PURE__ */ r(
540
537
  at,
541
538
  {
542
539
  items: t.mediaItems,
543
540
  total: t.mediaTotal ?? t.mediaItems.length,
544
- onExpand: ce
541
+ onExpand: le
545
542
  }
546
543
  ) }) : null
547
544
  ] }, t.id);
548
545
  }) })
549
546
  ] }, e.label)),
550
- u !== null && u.length < Y ? /* @__PURE__ */ r(
547
+ m !== null && m.length < j ? /* @__PURE__ */ r(
551
548
  "button",
552
549
  {
553
550
  type: "button",
554
- onClick: () => void Ce(),
555
- disabled: G,
551
+ onClick: () => void Ee(),
552
+ disabled: F,
556
553
  className: "w-full rounded-xl border border-border bg-card/40 px-4 py-2.5 text-sm font-medium text-muted-foreground transition-colors hover:border-foreground/20 hover:text-foreground disabled:opacity-60",
557
- children: G ? "Loading…" : `Load more · ${Y - u.length} left`
554
+ children: F ? "Loading…" : `Load more · ${j - m.length} left`
558
555
  }
559
556
  ) : null
560
557
  ] })