@rubytech/create-maxy-code 0.1.482 → 0.1.483

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 (179) hide show
  1. package/package.json +1 -1
  2. package/payload/platform/plugins/admin/PLUGIN.md +1 -0
  3. package/payload/platform/plugins/admin/skills/platform-architecture/SKILL.md +27 -1
  4. package/payload/platform/plugins/admin/skills/whats-new/SKILL.md +57 -0
  5. package/payload/platform/plugins/docs/references/admin-ui.md +25 -0
  6. package/payload/platform/plugins/docs/references/neo4j.md +1 -0
  7. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/typed-edge-schema.test.js +8 -0
  8. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/typed-edge-schema.test.js.map +1 -1
  9. package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-schema.d.ts.map +1 -1
  10. package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-schema.js +5 -1
  11. package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-schema.js.map +1 -1
  12. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.js +10 -0
  13. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.js.map +1 -1
  14. package/payload/platform/plugins/memory/references/schema-knowledge-work.md +2 -1
  15. package/payload/server/public/activity.html +6 -6
  16. package/payload/server/public/assets/{AdminLoginScreens-DXYJWXaX.js → AdminLoginScreens-Jw45pvb2.js} +1 -1
  17. package/payload/server/public/assets/AdminShell-DR6AzflZ.js +2 -0
  18. package/payload/server/public/assets/{Checkbox-C08Ulc_a.js → Checkbox-D7_S2EUI.js} +1 -1
  19. package/payload/server/public/assets/activity-CKbv3zFM.js +1 -0
  20. package/payload/server/public/assets/admin-DXUspIjz.js +1 -0
  21. package/payload/server/public/assets/{arc-BHXuzTwg.js → arc-D-QzyndF.js} +1 -1
  22. package/payload/server/public/assets/architecture-YZFGNWBL-CGvD4r9F.js +1 -0
  23. package/payload/server/public/assets/{architectureDiagram-Q4EWVU46-DsN_vxau.js → architectureDiagram-Q4EWVU46-W7f0Us4S.js} +1 -1
  24. package/payload/server/public/assets/{blockDiagram-DXYQGD6D-CvNat1uB.js → blockDiagram-DXYQGD6D-CfPS4FXg.js} +1 -1
  25. package/payload/server/public/assets/bot-GC7iZjtW.js +1 -0
  26. package/payload/server/public/assets/browser-BI-wi3CM.js +1 -0
  27. package/payload/server/public/assets/{c4Diagram-AHTNJAMY-E9yqTPTW.js → c4Diagram-AHTNJAMY-Dq60cLVI.js} +1 -1
  28. package/payload/server/public/assets/calendar-DXnv4F7l.js +1 -0
  29. package/payload/server/public/assets/channel-Bpg-ADC0.js +1 -0
  30. package/payload/server/public/assets/chat-CAdgaPW1.js +1 -0
  31. package/payload/server/public/assets/chevron-down-BCLf1wKu.js +1 -0
  32. package/payload/server/public/assets/chevron-left-BNtL-CjS.js +1 -0
  33. package/payload/server/public/assets/chevron-right-Bu5hsjy5.js +1 -0
  34. package/payload/server/public/assets/{chunk-2KRD3SAO-DpzI_0EY.js → chunk-2KRD3SAO-CXDjuDN0.js} +1 -1
  35. package/payload/server/public/assets/{chunk-336JU56O-eR_I9Eu4.js → chunk-336JU56O-926ox0tj.js} +2 -2
  36. package/payload/server/public/assets/chunk-426QAEUC-1poG7Nd3.js +1 -0
  37. package/payload/server/public/assets/{chunk-4BX2VUAB-D-6xk1t8.js → chunk-4BX2VUAB-C2nrPCfN.js} +1 -1
  38. package/payload/server/public/assets/{chunk-4TB4RGXK-BkqUcFpL.js → chunk-4TB4RGXK-CuW3FOR6.js} +1 -1
  39. package/payload/server/public/assets/{chunk-55IACEB6-ChCl2pSP.js → chunk-55IACEB6-B4_-In90.js} +1 -1
  40. package/payload/server/public/assets/{chunk-5FUZZQ4R-DasGsg54.js → chunk-5FUZZQ4R-DnYGr9CP.js} +1 -1
  41. package/payload/server/public/assets/{chunk-5PVQY5BW-DXlHUX1h.js → chunk-5PVQY5BW-BYCOi9bf.js} +1 -1
  42. package/payload/server/public/assets/{chunk-67CJDMHE-BZfVpTsE.js → chunk-67CJDMHE-CBxsC4JP.js} +1 -1
  43. package/payload/server/public/assets/{chunk-7N4EOEYR-C6U5TIgT.js → chunk-7N4EOEYR-CAACaqFr.js} +1 -1
  44. package/payload/server/public/assets/{chunk-AA7GKIK3-CA7cVDmw.js → chunk-AA7GKIK3-BoamZdS6.js} +1 -1
  45. package/payload/server/public/assets/{chunk-BSJP7CBP-DxN2GC3p.js → chunk-BSJP7CBP-CHk82eFy.js} +1 -1
  46. package/payload/server/public/assets/{chunk-CIAEETIT-C0-4wA8y.js → chunk-CIAEETIT-DdeW9zxl.js} +1 -1
  47. package/payload/server/public/assets/{chunk-EDXVE4YY--kyb1rLc.js → chunk-EDXVE4YY-DJqSRv2w.js} +1 -1
  48. package/payload/server/public/assets/{chunk-ENJZ2VHE-FBN6hR7V.js → chunk-ENJZ2VHE-BRi4BwM5.js} +1 -1
  49. package/payload/server/public/assets/{chunk-FMBD7UC4-Lpge4M5g.js → chunk-FMBD7UC4-OJp2CtUE.js} +1 -1
  50. package/payload/server/public/assets/{chunk-FOC6F5B3-CM1rwOou.js → chunk-FOC6F5B3-BUAQ6spG.js} +1 -1
  51. package/payload/server/public/assets/{chunk-ICPOFSXX-JdYLY3yu.js → chunk-ICPOFSXX-DeRggD-Q.js} +2 -2
  52. package/payload/server/public/assets/{chunk-K5T4RW27-DCUblGBr.js → chunk-K5T4RW27-EHiXZ8Py.js} +1 -1
  53. package/payload/server/public/assets/{chunk-KGLVRYIC-BP_cide2.js → chunk-KGLVRYIC-tOajPcpn.js} +1 -1
  54. package/payload/server/public/assets/{chunk-LIHQZDEY-DjMa1lOl.js → chunk-LIHQZDEY-uwO6oHIU.js} +1 -1
  55. package/payload/server/public/assets/{chunk-ORNJ4GCN-D51eJAoV.js → chunk-ORNJ4GCN-Dpa1_BCA.js} +1 -1
  56. package/payload/server/public/assets/{chunk-OYMX7WX6-4hWIO544.js → chunk-OYMX7WX6-ChdDqaQL.js} +1 -1
  57. package/payload/server/public/assets/chunk-QZHKN3VN-GN1tIO8J.js +1 -0
  58. package/payload/server/public/assets/{chunk-U2HBQHQK-BwdQf9cS.js → chunk-U2HBQHQK-5JgWosPv.js} +1 -1
  59. package/payload/server/public/assets/{chunk-X2U36JSP-DmDxwLOg.js → chunk-X2U36JSP-BGJqysB2.js} +1 -1
  60. package/payload/server/public/assets/{chunk-XPW4576I-JQyAB7ND.js → chunk-XPW4576I-GERE2ekx.js} +1 -1
  61. package/payload/server/public/assets/{chunk-YZCP3GAM-BonLdCzI.js → chunk-YZCP3GAM-BskqX1V5.js} +1 -1
  62. package/payload/server/public/assets/{chunk-ZZ45TVLE-BXKB2wSk.js → chunk-ZZ45TVLE-DG1iY-L9.js} +1 -1
  63. package/payload/server/public/assets/classDiagram-6PBFFD2Q-DMGVq8Jv.js +1 -0
  64. package/payload/server/public/assets/classDiagram-v2-HSJHXN6E-DfddT8UV.js +1 -0
  65. package/payload/server/public/assets/clone-Cc9vFIEk.js +1 -0
  66. package/payload/server/public/assets/{cose-bilkent-S5V4N54A-BDnd4Blw.js → cose-bilkent-S5V4N54A-C8Rl4ykh.js} +1 -1
  67. package/payload/server/public/assets/{dagre-BmexzuER.js → dagre-DTlv-FFy.js} +1 -1
  68. package/payload/server/public/assets/{dagre-KV5264BT-D4WVuwPj.js → dagre-KV5264BT-C0YrJPF3.js} +1 -1
  69. package/payload/server/public/assets/data-D7cYlorm.js +1 -0
  70. package/payload/server/public/assets/{diagram-5BDNPKRD-Bbf4mT8a.js → diagram-5BDNPKRD-Dfk5oepI.js} +1 -1
  71. package/payload/server/public/assets/{diagram-G4DWMVQ6-BpqVTUmx.js → diagram-G4DWMVQ6-QRj55DiB.js} +1 -1
  72. package/payload/server/public/assets/{diagram-MMDJMWI5-DY-k5k6r.js → diagram-MMDJMWI5-BAPKsohU.js} +1 -1
  73. package/payload/server/public/assets/{diagram-TYMM5635-CXHxwacS.js → diagram-TYMM5635-C3iZXPkC.js} +1 -1
  74. package/payload/server/public/assets/{erDiagram-SMLLAGMA-BNKEc3l8.js → erDiagram-SMLLAGMA-DIbI7g_5.js} +1 -1
  75. package/payload/server/public/assets/{flatten-jn8bZgcI.js → flatten-DlAJeN0L.js} +1 -1
  76. package/payload/server/public/assets/{flowDiagram-DWJPFMVM-CbAeuJsi.js → flowDiagram-DWJPFMVM-l3eJJr8R.js} +1 -1
  77. package/payload/server/public/assets/{ganttDiagram-T4ZO3ILL-CeeNnL4l.js → ganttDiagram-T4ZO3ILL-aaEzHxIq.js} +1 -1
  78. package/payload/server/public/assets/gitGraph-7Q5UKJZL-DtjXE0UI.js +1 -0
  79. package/payload/server/public/assets/{gitGraphDiagram-UUTBAWPF-DG8RCtfg.js → gitGraphDiagram-UUTBAWPF-Di-1eg_m.js} +1 -1
  80. package/payload/server/public/assets/graph-Cl72j3UC.js +51 -0
  81. package/payload/server/public/assets/{graph-labels-LeIhl7ZG.js → graph-labels-7p-mVi9M.js} +1 -1
  82. package/payload/server/public/assets/{graphlib-BkDExPQi.js → graphlib-D5awC2yp.js} +1 -1
  83. package/payload/server/public/assets/info-OMHHGYJF-CmArhGYf.js +1 -0
  84. package/payload/server/public/assets/infoDiagram-42DDH7IO-utWz7oZy.js +2 -0
  85. package/payload/server/public/assets/{isEmpty-Dkk6_L-B.js → isEmpty-Dh1dF-tM.js} +1 -1
  86. package/payload/server/public/assets/{ishikawaDiagram-UXIWVN3A-D_iMHV64.js → ishikawaDiagram-UXIWVN3A-CLOd_cNf.js} +1 -1
  87. package/payload/server/public/assets/{journeyDiagram-VCZTEJTY-BvPRpulx.js → journeyDiagram-VCZTEJTY-cGyfW6Tg.js} +1 -1
  88. package/payload/server/public/assets/{kanban-definition-6JOO6SKY-CkWaXWo2.js → kanban-definition-6JOO6SKY-CRTKWPlh.js} +1 -1
  89. package/payload/server/public/assets/{line-BGQT9unx.js → line-B8Brm0TD.js} +1 -1
  90. package/payload/server/public/assets/{linear-DzrYI8-8.js → linear-BHnSKXBe.js} +1 -1
  91. package/payload/server/public/assets/{maximize-2-2MgPSwlx.js → maximize-2-HcfeeOdJ.js} +1 -1
  92. package/payload/server/public/assets/{mermaid-parser.core-DrMY7FMe.js → mermaid-parser.core-BtNpdQct.js} +2 -2
  93. package/payload/server/public/assets/{mermaid.core-BWdf6fZ7.js → mermaid.core-BY87anQZ.js} +3 -3
  94. package/payload/server/public/assets/{mindmap-definition-QFDTVHPH-CgqM9h97.js → mindmap-definition-QFDTVHPH-rUSv9qN1.js} +1 -1
  95. package/payload/server/public/assets/{operator-CZifmNhp.js → operator-C0iaGPNT.js} +1 -1
  96. package/payload/server/public/assets/{ordinal-DuJYM7p1.js → ordinal-Bnl5GL-x.js} +1 -1
  97. package/payload/server/public/assets/packet-4T2RLAQJ-BTfK0Zw4.js +1 -0
  98. package/payload/server/public/assets/page-DPQS0X5M.js +32 -0
  99. package/payload/server/public/assets/page-DsV3rID5.js +1 -0
  100. package/payload/server/public/assets/{pdf-render-riHufgrn.js → pdf-render-CrpAi4Ba.js} +1 -1
  101. package/payload/server/public/assets/pie-ZZUOXDRM-BvtPeMQY.js +1 -0
  102. package/payload/server/public/assets/{pieDiagram-DEJITSTG-BeUGoYS7.js → pieDiagram-DEJITSTG-Cjn9IP-C.js} +1 -1
  103. package/payload/server/public/assets/{public-VtmyYz8E.js → public-DAn13pnw.js} +1 -1
  104. package/payload/server/public/assets/{quadrantDiagram-34T5L4WZ-CX82WgKy.js → quadrantDiagram-34T5L4WZ-BkSHkSsn.js} +1 -1
  105. package/payload/server/public/assets/radar-PYXPWWZC-D2UXvQgn.js +1 -0
  106. package/payload/server/public/assets/{reduce-COyotL2V.js → reduce-Bp5oNw1n.js} +1 -1
  107. package/payload/server/public/assets/{requirementDiagram-MS252O5E-CzqebQXj.js → requirementDiagram-MS252O5E-hLwgyB-F.js} +1 -1
  108. package/payload/server/public/assets/{rotate-ccw-DaZdB2cz.js → rotate-ccw-CCbbX5ef.js} +1 -1
  109. package/payload/server/public/assets/{sankeyDiagram-XADWPNL6-CaHi1yzU.js → sankeyDiagram-XADWPNL6-D6Dl1RIa.js} +1 -1
  110. package/payload/server/public/assets/{sequenceDiagram-FGHM5R23-BF2AeiKW.js → sequenceDiagram-FGHM5R23-j0QBqkbL.js} +1 -1
  111. package/payload/server/public/assets/{stateDiagram-FHFEXIEX-DtUCA8Ih.js → stateDiagram-FHFEXIEX-TvEBNsuV.js} +1 -1
  112. package/payload/server/public/assets/stateDiagram-v2-QKLJ7IA2-Ur4eM6rb.js +1 -0
  113. package/payload/server/public/assets/tasks-_Ij9BdOE.js +1 -0
  114. package/payload/server/public/assets/{time-entry-format-TD-PPEIu.js → time-entry-format-C-By1MbO.js} +1 -1
  115. package/payload/server/public/assets/{timeline-definition-GMOUNBTQ-D3Q1YrKY.js → timeline-definition-GMOUNBTQ-BfivOP-j.js} +1 -1
  116. package/payload/server/public/assets/treeView-SZITEDCU-0dE7FvM2.js +1 -0
  117. package/payload/server/public/assets/treemap-W4RFUUIX-BrwlXpr5.js +1 -0
  118. package/payload/server/public/assets/{triangle-alert-BaLhVNnn.js → triangle-alert-BDtoi5R0.js} +1 -1
  119. package/payload/server/public/assets/useCopyFeedback-CfbJc9iN.js +1 -0
  120. package/payload/server/public/assets/useSubAccountSwitcher-5jQsc23X.css +1 -0
  121. package/payload/server/public/assets/{useSubAccountSwitcher-HEVLb6Z9.js → useSubAccountSwitcher-sPN6lobE.js} +1 -1
  122. package/payload/server/public/assets/useVoiceRecorder-DOFBQ2gP.js +2 -0
  123. package/payload/server/public/assets/{vennDiagram-DHZGUBPP-DnjzQDGf.js → vennDiagram-DHZGUBPP-Bvfw9aFJ.js} +1 -1
  124. package/payload/server/public/assets/wardley-RL74JXVD-CO9HdfJ-.js +1 -0
  125. package/payload/server/public/assets/{wardleyDiagram-NUSXRM2D-T3WHrUvi.js → wardleyDiagram-NUSXRM2D-C9h04G6b.js} +1 -1
  126. package/payload/server/public/assets/{xychartDiagram-5P7HB3ND-2Efyv4h2.js → xychartDiagram-5P7HB3ND-BMvi2m2q.js} +1 -1
  127. package/payload/server/public/brand-defaults.css +4 -0
  128. package/payload/server/public/browser.html +4 -4
  129. package/payload/server/public/calendar.html +6 -5
  130. package/payload/server/public/chat.html +14 -12
  131. package/payload/server/public/data.html +11 -11
  132. package/payload/server/public/graph.html +11 -10
  133. package/payload/server/public/index.html +17 -14
  134. package/payload/server/public/operator.html +16 -14
  135. package/payload/server/public/public.html +14 -12
  136. package/payload/server/public/tasks.html +6 -6
  137. package/payload/server/public/assets/AdminShell-UDgNN4CA.js +0 -2
  138. package/payload/server/public/assets/activity-06gsRDVv.js +0 -1
  139. package/payload/server/public/assets/admin-BhiHyORH.js +0 -1
  140. package/payload/server/public/assets/architecture-YZFGNWBL-Ct5q6ks1.js +0 -1
  141. package/payload/server/public/assets/browser-Cz4IKS47.js +0 -1
  142. package/payload/server/public/assets/calendar-D0xtNqH8.js +0 -1
  143. package/payload/server/public/assets/channel-PE9vBKEQ.js +0 -1
  144. package/payload/server/public/assets/chat-DwLJ830n.js +0 -1
  145. package/payload/server/public/assets/chevron-left-Cv-TFuEf.js +0 -1
  146. package/payload/server/public/assets/chunk-426QAEUC-BDNZtJsz.js +0 -1
  147. package/payload/server/public/assets/chunk-QZHKN3VN-B_Hris8x.js +0 -1
  148. package/payload/server/public/assets/classDiagram-6PBFFD2Q-D8Q05iMI.js +0 -1
  149. package/payload/server/public/assets/classDiagram-v2-HSJHXN6E-Dm3hAxfm.js +0 -1
  150. package/payload/server/public/assets/clone-C-wOwvpY.js +0 -1
  151. package/payload/server/public/assets/data-DUDJfnjI.js +0 -1
  152. package/payload/server/public/assets/gitGraph-7Q5UKJZL-BBHsY16R.js +0 -1
  153. package/payload/server/public/assets/graph-BAoktBcx.js +0 -51
  154. package/payload/server/public/assets/info-OMHHGYJF-C1j5I_zx.js +0 -1
  155. package/payload/server/public/assets/infoDiagram-42DDH7IO-ZWkwHWEu.js +0 -2
  156. package/payload/server/public/assets/packet-4T2RLAQJ-CGiTbe0N.js +0 -1
  157. package/payload/server/public/assets/page-B4kllGd_.js +0 -32
  158. package/payload/server/public/assets/page-DbfE7QwJ.js +0 -1
  159. package/payload/server/public/assets/pie-ZZUOXDRM-BrK023dE.js +0 -1
  160. package/payload/server/public/assets/radar-PYXPWWZC-p7NRamXX.js +0 -1
  161. package/payload/server/public/assets/stateDiagram-v2-QKLJ7IA2-a4FvB3L8.js +0 -1
  162. package/payload/server/public/assets/tasks-CvqVDbfO.js +0 -1
  163. package/payload/server/public/assets/treeView-SZITEDCU-CoWk8VoG.js +0 -1
  164. package/payload/server/public/assets/treemap-W4RFUUIX-BhWeGj8Y.js +0 -1
  165. package/payload/server/public/assets/useCopyFeedback-BhjPzRa3.js +0 -1
  166. package/payload/server/public/assets/useSubAccountSwitcher-CWRpVt1-.css +0 -1
  167. package/payload/server/public/assets/useVoiceRecorder-CfGgj3vm.js +0 -2
  168. package/payload/server/public/assets/wardley-RL74JXVD-C0q3Hqng.js +0 -1
  169. /package/payload/server/public/assets/{_baseFor-Bjj9It3Q.js → _baseFor-BBkmqPEk.js} +0 -0
  170. /package/payload/server/public/assets/{array-BrrxEo12.js → array-Bjtb2C_5.js} +0 -0
  171. /package/payload/server/public/assets/{cytoscape.esm-CTWJxUxo.js → cytoscape.esm-B1dQ664k.js} +0 -0
  172. /package/payload/server/public/assets/{defaultLocale-CFDbRV4k.js → defaultLocale-iwYA7ne8.js} +0 -0
  173. /package/payload/server/public/assets/{dist-BATfy7Sn.js → dist-CLmrZbY7.js} +0 -0
  174. /package/payload/server/public/assets/{init-dXCzGgLP.js → init-CxnBAgcf.js} +0 -0
  175. /package/payload/server/public/assets/{katex-CHA1JFYJ.js → katex-DojHoLIr.js} +0 -0
  176. /package/payload/server/public/assets/{path-CCRpdXhK.js → path-JZiojYzQ.js} +0 -0
  177. /package/payload/server/public/assets/{preload-helper-CH6UZRzu.js → preload-helper-CT1Z6Pdu.js} +0 -0
  178. /package/payload/server/public/assets/{rough.esm-Bud4g4fh.js → rough.esm-D5NinLFK.js} +0 -0
  179. /package/payload/server/public/assets/{src-DNdBRXXx.js → src-DQ0MSD6q.js} +0 -0
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-TPjIAO9U.js";import{B as t,C as n,H as r,L as i,f as a,j as o,z as s}from"./useSubAccountSwitcher-sPN6lobE.js";import{_ as c,t as l,v as u}from"./AdminShell-DR6AzflZ.js";import{t as d}from"./Checkbox-D7_S2EUI.js";import{t as f}from"./triangle-alert-BDtoi5R0.js";var p=t(),m=e(r(),1),h=i(),g=`—`;function _(e){switch(e){case`waiting`:return`Waiting`;case`never-run`:return`Never run`;case`never-succeeded`:return`Never succeeded`;case`failing`:return`Failing`;case`stalled`:return`Stalled`;case`running`:return`Running`;case`ok`:return`Healthy`}}var v={waiting:`Armed and not due yet. It has no start-up run and its first interval has not elapsed, so it has correctly not fired.`,"never-run":`Its interval has elapsed and it still has not fired once. This is not the same as waiting its turn.`,"never-succeeded":`It has fired, and not one run has finished. The work this loop exists to do has never happened.`,failing:`It worked before and is failing now.`,stalled:`It has not started within three of its own intervals. Something is holding it up.`,running:`A run is in progress right now.`,ok:`The last run finished and the next is due within the interval.`},y=new Set([`never-run`,`never-succeeded`,`failing`,`stalled`]),b=10;function x(e){return e===null||!Number.isFinite(e)?g:`${e.toFixed(1)}%`}function S(e){return e<6e4?`${Math.round(e/1e3)}s`:e<36e5?`${Math.round(e/6e4)}m`:`${Math.round(e/36e5)}h`}function C(e,t){if(e===null)return g;let n=t-e;return n<0?`in ${S(-n)}`:n<6e4?`${Math.round(n/1e3)}s ago`:n<36e5?`${Math.round(n/6e4)}m ago`:`${Math.round(n/36e5)}h ago`}function w(e,t){if(e===null)return g;let n=e-t;return n>=0?`in ${S(n)}`:`overdue by ${S(-n)}`}function T({loops:e,nowMs:t=Date.now()}){let[n,r]=(0,m.useState)(!1);if(!e)return(0,h.jsxs)(`section`,{className:`activity-loops`,children:[(0,h.jsx)(`h2`,{className:`activity-loops-heading`,children:`Scheduled work`}),(0,h.jsx)(`p`,{className:`activity-loops-empty`,children:`Scheduled work could not be read from the server.`})]});let i=e.armed-e.rows.length,a=e.rows.filter(e=>y.has(e.state)),o=e.rows.filter(e=>!y.has(e.state)&&typeof e.cpuPct==`number`&&e.cpuPct>=b),s=n?e.rows:[...a,...o];return(0,h.jsxs)(`section`,{className:`activity-loops`,children:[(0,h.jsx)(`h2`,{className:`activity-loops-heading`,children:`Scheduled work`}),(0,h.jsxs)(`p`,{className:`activity-loops-sub`,children:[e.armed,` `,e.armed===1?`loop`:`loops`,` armed`,a.length>0?` · ${a.length} ${a.length===1?`needs`:`need`} attention`:` · all healthy`,o.length>0&&` · ${o.length} using significant processor`,`. `,(0,h.jsx)(`button`,{type:`button`,className:`activity-loops-toggle`,"aria-expanded":n,onClick:()=>r(e=>!e),children:n?`Show less`:`Show all`})]}),typeof e.processPct==`number`&&(0,h.jsxs)(`p`,{className:`activity-loops-cpu`,children:[`Server process at `,e.processPct.toFixed(1),`% of one core`,typeof e.attributedPct==`number`&&(0,h.jsxs)(h.Fragment,{children:[` · these loops explain `,e.attributedPct.toFixed(1),`%`]}),typeof e.unattributedPct==`number`&&e.unattributedPct>=1&&(0,h.jsxs)(h.Fragment,{children:[` · `,(0,h.jsxs)(`strong`,{children:[e.unattributedPct.toFixed(1),`% is not from these loops`]})]})]}),i>0&&(0,h.jsxs)(`p`,{className:`activity-loops-omission`,role:`status`,children:[i,` armed `,i===1?`loop is`:`loops are`,` missing from this list. The server armed `,e.armed,` but sent `,e.rows.length,`.`]}),s.length===0?null:(0,h.jsx)(`div`,{className:`activity-table-scroll`,children:(0,h.jsxs)(`table`,{className:`activity-table`,children:[(0,h.jsx)(`thead`,{children:(0,h.jsxs)(`tr`,{children:[(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Loop`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`State`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Every`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Last run`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Last OK`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Took`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`CPU`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Runs`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Produced`}),(0,h.jsx)(`th`,{scope:`col`,className:`activity-th`,children:`Next due`})]})}),(0,h.jsx)(`tbody`,{children:s.map(e=>(0,h.jsxs)(`tr`,{className:y.has(e.state)?`activity-loop-row activity-loop-unhealthy`:`activity-loop-row`,children:[(0,h.jsx)(`td`,{className:`activity-td`,children:e.name}),(0,h.jsx)(`td`,{className:`activity-td`,title:v[e.state],children:(0,h.jsxs)(`span`,{className:`activity-state`,children:[(0,h.jsx)(`span`,{className:e.state===`ok`?`activity-state-dot is-healthy`:y.has(e.state)?`activity-state-dot is-unhealthy`:`activity-state-dot`,"aria-hidden":`true`}),_(e.state)]})}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,children:S(e.intervalMs)}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,children:C(e.lastStartMs,t)}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,children:C(e.lastSuccessMs,t)}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,children:e.lastDurationMs===null?g:`${e.lastDurationMs} ms`}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,title:e.cpuAttributable?e.detached?`Includes the processor time of the separate process this loop starts.`:void 0:`This loop waits on other work while it runs, so the processor time it uses cannot be separated from the rest of the server.`,children:x(e.cpuPct)}),(0,h.jsxs)(`td`,{className:`activity-td activity-num`,children:[e.successCount,`/`,e.runCount]}),(0,h.jsx)(`td`,{className:`activity-td activity-loop-note`,children:(0,h.jsx)(`span`,{className:`activity-loop-note-text`,title:e.lastError??e.lastNote??void 0,children:e.lastError??e.lastNote??g})}),(0,h.jsx)(`td`,{className:`activity-td activity-num`,children:w(e.nextDueMs,t)})]},e.name))})]})}),(0,h.jsxs)(`dl`,{className:`activity-legend`,children:[(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,children:`Runs`}),(0,h.jsx)(`dd`,{className:`activity-legend-def`,children:`Finished runs out of attempted runs since the server started. 0 out of a large number means it has tried many times and never once finished.`})]}),(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,children:`CPU`}),(0,h.jsx)(`dd`,{className:`activity-legend-def`,children:`Share of one processor core this loop is using, measured between the last two refreshes. It includes any separate process the loop starts, and can pass 100% because those run alongside each other. A dash means it could not be measured: the loop waits on other work while it runs, so its share cannot be separated from the rest of the server.`})]}),(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,children:g}),(0,h.jsx)(`dd`,{className:`activity-legend-def`,children:`Not measured. It does not mean zero.`})]})]})]})}var E=`maxy-admin-session-key`;function D(e){switch(e.costUnavailable){case`metering-failed`:return`Cost could not be calculated: ${e.meteringError??`the transcript could not be read`}`;case`model-not-priced`:return`No published price for this model, so cost cannot be estimated.`;case`no-transcript`:return`This session has no transcript yet, so there is nothing to cost.`;default:return}}var O=[{key:`lastMessageAt`,label:`Last activity`,dir:-1},{key:`activeMsInRange`,label:`Active time`,dir:-1},{key:`costGbp`,label:`Cost`,dir:-1},{key:`accountId`,label:`Account name`,dir:1}],k=[{key:`title`,label:`Session`,help:`The conversation name, or its short id when it has none yet.`},{key:`model`,label:`Model`,help:`The model that answered the most recent turn.`},{key:`status`,label:`Status`,help:`What the process is doing right now.`},{key:`activeMsInRange`,label:`Active`,help:`Time this session spent thinking, writing and running tools inside the selected range. This is worked time, not elapsed time.`},{key:`ageMs`,label:`Age`,help:`How long ago this conversation started. Wall-clock, so it counts every hour nobody was working.`},{key:`lastMessageAt`,label:`Last activity`,help:`The clock time of the most recent message, in your timezone. A date appears once it is not today.`},{key:`turnCount`,label:`Turns`,help:`Messages exchanged. A trailing + means the count is a minimum — the conversation is too long to count exactly.`},{key:`rssKb`,label:`RAM`,help:`Memory held by this session and all its helper processes together.`},{key:`cpuPct`,label:`CPU (avg)`,help:`AVERAGE share of one processor core over the last census interval, up to 60 seconds. It is not a reading of this instant, so a session that answered a turn a minute ago still shows a high figure while sitting quiet now. Can exceed 100% because a session runs many processes at once.`},{key:`tokensInRange`,label:`Tokens`,help:`Total tokens billed inside the selected range, added up across every day in it. A cumulative total, not the size of the conversation the model currently reads back.`},{key:`costGbp`,label:`Cost`,help:`Estimated spend inside the selected range, at published prices for this model.`}],A=[`activeMsInRange`,`lastMessageAt`,`cpuPct`,`tokensInRange`],j={label:`Account`,help:`The business this session belongs to. "untagged" means the session records no account.`};function M(e,t){let n=t?.[e];return n&&n.trim()!==``?n:e.slice(0,8)}var N=`—`;function P(e){if(e===null||!Number.isFinite(e)||e<0)return N;let t=Math.floor(e/1e3);if(t<60)return`${t}s`;let n=Math.floor(t/60);if(n<60)return`${n}m`;let r=Math.floor(n/60);return r<24?`${r}h ${n%60}m`:`${Math.floor(r/24)}d ${r%24}h`}function F(e){return e===null||!Number.isFinite(e)?N:`${(e/1024/1024).toFixed(1)} GB`}function I(e,t){if(!e)return N;let n=Date.parse(e);if(!Number.isFinite(n))return N;let r=new Date(n),i=new Date(t),a=`${String(r.getHours()).padStart(2,`0`)}:${String(r.getMinutes()).padStart(2,`0`)}`;return r.getFullYear()===i.getFullYear()&&r.getMonth()===i.getMonth()&&r.getDate()===i.getDate()?a:`${r.getDate()} ${r.toLocaleString(`en-GB`,{month:`short`})} ${a}`}function L(e){return e===null||!Number.isFinite(e)?N:`${e.toFixed(1)}%`}function R(e){return e===null||!Number.isFinite(e)?N:e<1e3?String(e):e<1e6?`${(e/1e3).toFixed(1)}k`:`${(e/1e6).toFixed(2)}M`}function z(e){return e===null||!Number.isFinite(e)?N:`£${e.toFixed(2)}`}function B(e){if(e===null||!Number.isFinite(e)||e<0)return N;let t=Math.floor(e/6e4);return`${Math.floor(t/60)}h ${t%60}m`}function V(e,t,n,r){let i=e[n],a=t[n];if(i===null&&a===null)return 0;if(i===null)return 1;if(a===null)return-1;if(n===`lastMessageAt`){let e=Date.parse(String(i)),t=Date.parse(String(a));return!Number.isFinite(e)&&!Number.isFinite(t)?0:Number.isFinite(e)?Number.isFinite(t)?(e-t)*r:-1:1}return typeof i==`number`&&typeof a==`number`?(i-a)*r:String(i).localeCompare(String(a))*r}function H(e){return e.toISOString().slice(0,10)}function U(e){let t=e.getUTCFullYear(),n=e.getUTCMonth();return{from:H(new Date(Date.UTC(t,n,1))),to:H(new Date(Date.UTC(t,n+1,0)))}}function W(e,t){let n=new Date(`${e}T00:00:00.000Z`);return U(new Date(Date.UTC(n.getUTCFullYear(),n.getUTCMonth()+t,1)))}function G(e,t){return{from:H(new Date(t-(e-1)*864e5)),to:H(new Date(t))}}function K(e){return new Date(`${e}T00:00:00.000Z`).toLocaleString(`en-GB`,{month:`long`,year:`numeric`,timeZone:`UTC`})}function q(e){if(e===null)return!1;let t=U(new Date(`${e.from}T00:00:00.000Z`));return t.from===e.from&&t.to===e.to}function J(e,t,n){switch(e){case`title`:return t.title??t.sessionId.slice(0,8);case`model`:return t.model??N;case`status`:return t.status??N;case`activeMsInRange`:return B(t.activeMsInRange);case`ageMs`:return P(t.ageMs);case`lastMessageAt`:return I(t.lastMessageAt,n);case`turnCount`:return t.turnCount===null?N:`${t.turnCount}${t.turnCountCapped?`+`:``}`;case`rssKb`:return F(t.rssKb);case`cpuPct`:return L(t.cpuPct);case`tokensInRange`:return R(t.tokensInRange);case`costGbp`:return z(t.costGbp);default:return N}}function Y({adminFetch:e}){let[t,r]=(0,m.useState)(null),[i,a]=(0,m.useState)(null),[s,l]=(0,m.useState)(!1),[u,p]=(0,m.useState)(`lastMessageAt`),[g,_]=(0,m.useState)(-1),[v,y]=(0,m.useState)(()=>U(new Date)),[b,x]=(0,m.useState)(!0),[S,C]=(0,m.useState)(!0),[w,E]=(0,m.useState)(!1),F=(0,m.useRef)(!1),I=(0,m.useRef)(void 0),L=(0,m.useCallback)(async t=>{if(F.current){I.current=t;return}F.current=!0;try{let n=await e(`/api/admin/activity${t?`?from=${t.from}&to=${t.to}`:``}`);if(n.status===403){a(`This view is available to the house account only.`),l(!0);return}if(!n.ok){a(`The session manager did not answer (status ${n.status}).`),l(!0);return}r(await n.json()),a(null)}catch(e){a(e instanceof Error?e.message:String(e))}finally{l(!0),F.current=!1;let e=I.current;I.current=void 0,e!==void 0&&L(e)}},[e]);(0,m.useEffect)(()=>{L(v);let e=setInterval(()=>void L(v),15e3);return()=>clearInterval(e)},[L,v]);let R=(0,m.useMemo)(()=>t?[...t.rows].sort((e,t)=>V(e,t,u,g)):[],[t,u,g]),z=(0,m.useMemo)(()=>R.filter(e=>e.status===`busy`?b:e.status===`idle`?S:!0),[R,b,S]),B=R.length-z.length;if(!s)return(0,h.jsxs)(`div`,{className:`activity-loading`,children:[(0,h.jsx)(n,{size:18,className:`spin`}),` Loading…`]});if(i)return(0,h.jsx)(`div`,{className:`activity-empty`,children:i});if(!t)return(0,h.jsx)(`div`,{className:`activity-empty`,children:`No response.`});let{accounts:H,census:Y,censusAgeMs:X}=t,Z=Date.now(),Q=H.onDisk!==null&&H.onDisk>H.valid,$=t.range===void 0?v:t.range;return(0,h.jsxs)(`div`,{className:`activity-body`,children:[(0,h.jsxs)(`div`,{className:`activity-head`,children:[(0,h.jsxs)(`span`,{className:`activity-title`,children:[(0,h.jsx)(o,{size:16}),` Live sessions`]}),(0,h.jsxs)(`span`,{className:`activity-meta`,children:[B>0?`${z.length} of ${R.length} live · ${B} hidden`:`${R.length} live`,` · `,H.valid,` accounts`,H.untaggedCount>0?` · ${H.untaggedCount} untagged`:``]})]}),(0,h.jsxs)(`div`,{className:`activity-controls`,children:[(0,h.jsxs)(`div`,{className:`activity-control activity-range`,children:[(0,h.jsx)(c,{variant:`secondary`,size:`sm`,"aria-label":`Previous month`,disabled:!q(v),onClick:()=>y(e=>e&&W(e.from,-1)),children:`‹`}),(0,h.jsx)(`span`,{className:`activity-range-label`,children:v===null?`All time`:q(v)?K(v.from):`${v.from} → ${v.to}`}),(0,h.jsx)(c,{variant:`secondary`,size:`sm`,"aria-label":`Next month`,disabled:!q(v),onClick:()=>y(e=>e&&W(e.from,1)),children:`›`})]}),(0,h.jsxs)(`div`,{className:`activity-control activity-presets`,children:[(0,h.jsx)(c,{variant:`secondary`,size:`sm`,"aria-pressed":v!==null&&q(v)&&v.from===U(new Date).from,onClick:()=>y(U(new Date)),children:`This month`}),(0,h.jsx)(c,{variant:`secondary`,size:`sm`,"aria-pressed":v!==null&&!q(v),onClick:()=>y(G(7,Date.now())),children:`Last 7 days`}),(0,h.jsx)(c,{variant:`secondary`,size:`sm`,"aria-pressed":v===null,onClick:()=>y(null),children:`All time`})]}),(0,h.jsxs)(`div`,{className:`activity-control`,children:[(0,h.jsx)(`label`,{className:`activity-control-label`,htmlFor:`activity-sort`,children:`Sort by`}),(0,h.jsx)(`span`,{className:`activity-select-wrap`,children:(0,h.jsx)(`select`,{id:`activity-sort`,className:`activity-select`,value:u,onChange:e=>{let t=O.find(t=>t.key===e.target.value);t&&(p(t.key),_(t.dir))},children:O.map(e=>(0,h.jsx)(`option`,{value:e.key,children:e.label},e.key))})})]}),(0,h.jsxs)(`div`,{className:`activity-control activity-visibility`,children:[(0,h.jsx)(d,{checked:b,onChange:x,label:`Busy`}),(0,h.jsx)(d,{checked:S,onChange:C,label:`Idle`})]})]}),(0,h.jsxs)(`div`,{className:`activity-range-note`,children:[$===null?`Active time, tokens and cost cover each conversation’s whole history.`:`Active time, tokens and cost cover ${$.from} to ${$.to} (UTC), inclusive.`,t.fullRangeFallback&&(0,h.jsxs)(`strong`,{className:`activity-range-rejected`,children:[` `,`The range was not accepted, so these are all-time figures.`]})]}),(0,h.jsx)(`div`,{className:`activity-census`,children:Y===null?`No census collected yet, so memory and CPU are unavailable.`:`Memory and CPU measured ${P(X)} ago, averaged over the minute before that · ${Y.cpuNull} of ${Y.live} without a CPU reading`}),Q&&(0,h.jsxs)(`div`,{className:`activity-warning`,children:[(0,h.jsx)(f,{size:14}),` `,H.onDisk,` account folders on disk but only`,` `,H.valid,` are readable. Sessions belonging to the rest cannot be attributed.`]}),R.length===0?(0,h.jsx)(`div`,{className:`activity-empty`,children:`No sessions are running.`}):z.length===0?(0,h.jsxs)(`div`,{className:`activity-empty`,children:[`All `,R.length,` running sessions are hidden by the Busy and Idle filters.`]}):(0,h.jsx)(`div`,{className:`activity-grid`,children:z.map(e=>(0,h.jsxs)(`article`,{className:`activity-card`,"data-testid":`activity-card`,"data-session-id":e.sessionId,children:[(0,h.jsx)(`h3`,{className:`activity-card-heading`,title:e.accountId??void 0,children:e.accountId===null?(0,h.jsx)(`span`,{className:`activity-untagged`,title:`This session records no account, so it cannot be attributed to a business.`,children:`untagged`}):M(e.accountId,H.names)}),(0,h.jsx)(`dl`,{className:`activity-card-rows`,children:k.map(t=>(0,h.jsxs)(`div`,{className:`activity-card-row`,children:[(0,h.jsx)(`dt`,{className:`activity-card-label`,"data-testid":`activity-card-label`,title:t.help,children:t.label}),(0,h.jsx)(`dd`,{className:`activity-card-value`,title:t.key===`costGbp`?D(e):void 0,children:J(t.key,e,Z)})]},t.key))})]},e.sessionId))}),R.length>0&&(0,h.jsxs)(`div`,{className:`activity-glossary`,children:[(0,h.jsxs)(`dl`,{className:`activity-legend`,children:[w&&(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,"data-testid":`activity-glossary-term`,children:j.label}),(0,h.jsx)(`dd`,{className:`activity-legend-def`,children:j.help})]},`heading`),(w?k:k.filter(e=>A.includes(e.key))).map(e=>(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,"data-testid":`activity-glossary-term`,children:e.label}),(0,h.jsx)(`dd`,{className:`activity-legend-def`,children:e.help})]},e.key)),(0,h.jsxs)(`div`,{className:`activity-legend-item`,children:[(0,h.jsx)(`dt`,{className:`activity-legend-term`,children:N}),(0,h.jsxs)(`dd`,{className:`activity-legend-def`,children:[`Not measured. It does not mean zero — a measured zero is written as a figure, so `,(0,h.jsx)(`em`,{children:`0h 0m`}),` and `,(0,h.jsx)(`em`,{children:`£0.00`}),` are real readings. Hover a dashed value for the reason where one exists.`]})]})]}),(0,h.jsx)(c,{variant:`secondary`,size:`sm`,className:`activity-glossary-toggle`,onClick:()=>E(e=>!e),children:w?`Show fewer`:`Explain every figure`})]}),(0,h.jsx)(T,{loops:t?.loops})]})}function X({cacheKey:e}){let{adminFetch:t}=s({initialCacheKey:e,surface:`activity`});return(0,h.jsx)(Y,{adminFetch:t})}function Z(){let[e,t]=(0,m.useState)(null),[r,i]=(0,m.useState)(!1),[o,s]=(0,m.useState)(void 0),[c,d]=(0,m.useState)(null),[f,p]=(0,m.useState)(null),[g,_]=(0,m.useState)(null),[v,y]=(0,m.useState)(null);(0,m.useEffect)(()=>{let e=!1,n=null;try{n=sessionStorage.getItem(E)}catch{}if(!n){t(null),i(!0);return}return fetch(`/api/admin/session?session_key=${encodeURIComponent(n)}`).then(async r=>{if(!e){if(r.status===401){try{sessionStorage.removeItem(E)}catch{}window.location.href=`/`;return}if(r.ok)try{let e=await r.json();typeof e.businessName==`string`&&s(e.businessName),e.sessionId!==void 0&&d(e.sessionId??null),p(e.role??null),_(e.userName===void 0?null:e.userName),y(e.avatar??null)}catch{}t(n),i(!0)}}).catch(()=>{e||(t(n),i(!0))}),()=>{e=!0}},[]);let b=(0,m.useCallback)(()=>{try{sessionStorage.removeItem(E)}catch{}window.location.href=`/`},[]),[x,S]=(0,m.useState)(!1),C=(0,m.useCallback)(async()=>{S(!0);try{let e=await u();if(e){try{sessionStorage.removeItem(E)}catch{}window.location.href=`/`}return e}finally{S(!1)}},[]);return r?e?(0,h.jsx)(a,{cacheKey:e,surface:`activity`,onSessionExpired:({code:e,path:t})=>{console.warn(`[admin-auth] outcome=session-expired-redirect code=${e} path=${t} surface=activity`);try{sessionStorage.removeItem(E)}catch{}window.location.href=`/`},children:(0,h.jsx)(l,{cacheKey:e,businessName:o,sessionId:c,onLogout:b,onDisconnect:C,disconnecting:x,userName:g,userAvatar:v,role:f,children:(0,h.jsx)(X,{cacheKey:e})})}):(0,h.jsx)(`div`,{className:`activity-page`,children:(0,h.jsxs)(`div`,{className:`activity-empty`,children:[(0,h.jsx)(`p`,{children:`You are not signed in.`}),(0,h.jsxs)(`p`,{children:[`Open the `,(0,h.jsx)(`a`,{href:`/`,className:`activity-link`,children:`main admin page`}),` and log in, then return here.`]})]})}):(0,h.jsx)(`div`,{className:`activity-page`,children:(0,h.jsxs)(`div`,{className:`activity-loading`,children:[(0,h.jsx)(n,{size:18,className:`spin`}),` Loading…`]})})}(0,p.createRoot)(document.getElementById(`root`)).render((0,h.jsx)(Z,{}));
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-TPjIAO9U.js";import{B as t,H as n,L as r,T as i,c as a,f as o,g as s,i as c,o as l,p as u}from"./useSubAccountSwitcher-sPN6lobE.js";import{n as d,t as f}from"./AdminLoginScreens-Jw45pvb2.js";import{S as p,s as m}from"./useVoiceRecorder-DOFBQ2gP.js";import{a as h,t as g}from"./AdminShell-DR6AzflZ.js";import"./Checkbox-D7_S2EUI.js";import{i as _,n as v,r as y}from"./page-DsV3rID5.js";import{t as b}from"./bot-GC7iZjtW.js";import{t as x}from"./chevron-down-BCLf1wKu.js";import{t as S}from"./chevron-right-Bu5hsjy5.js";import"./graph-labels-7p-mVi9M.js";var C=t(),w=e(n(),1),T=r();function E({onOpen:e}){return(0,T.jsx)(`footer`,{className:`admin-footer`,children:(0,T.jsxs)(`div`,{className:`powered-by`,role:`button`,tabIndex:0,onClick:e,onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),e())},"aria-label":`Powered by Claude Code — show details`,children:[(0,T.jsx)(`img`,{src:`/brand/claude.png`,alt:`Claude`,className:`powered-by-icon`}),(0,T.jsx)(`span`,{children:`Powered by Claude Code`})]})})}var D=6e4,O=60*D,k=24*O,A=D,j=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],M=[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`];function N(e){return e<10?`0${e}`:String(e)}function P(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()}function F(e,t){if(!Number.isFinite(e)||e<=0||!Number.isFinite(t))return`—`;let n=t-e;if(n<-A)return`—`;let r=n<0?0:n;if(r<D)return`just now`;if(r<O)return`${Math.floor(r/D)}m`;if(r<k)return`${Math.floor(r/O)}h`;let i=new Date(t),a=new Date(e),o=Math.round((P(i)-P(a))/k);if(o===1)return`yesterday`;if(o>=2&&o<=6)return M[a.getDay()];let s=N(a.getDate()),c=j[a.getMonth()];return a.getFullYear()===i.getFullYear()?`${s} ${c}`:`${s} ${c} ${a.getFullYear()}`}var I={whatsapp:`WhatsApp`,telegram:`Telegram`,webchat:`Web chat`};function L(e){return e<12?`morning`:e<18?`afternoon`:`evening`}function R(e){return e&&e.trim().split(/\s+/)[0]||`there`}function z(e){if(!e)return`everything is running normally.`;let t=e.cpuPct,n=e.memUsedPct;return t!==null&&t>=.98||n!==null&&n>=.98?`system load is critical.`:t!==null&&t>=.9||n!==null&&n>=.9?`system load is high.`:`everything is running normally.`}function B(e){return e==null?`—`:`${Math.round(e*100)}%`}function V(e){return e.operatorName??e.whatsappName??e.senderId??e.title}function H(e,t){if(!e)return!1;let n=Date.parse(e);if(!Number.isFinite(n))return!1;let r=new Date(n),i=new Date(t);return r.getFullYear()===i.getFullYear()&&r.getMonth()===i.getMonth()&&r.getDate()===i.getDate()}function U(e){return e?e.replace(/^claude-/,``):null}function W({cacheKey:e,userName:t,onSelectWhatsappConversation:n}){let r=u(e),[o,d]=(0,w.useState)(null),[f,m]=(0,w.useState)(null),[h,g]=(0,w.useState)(null),[_,v]=(0,w.useState)(null),[C,E]=(0,w.useState)(null),[D,O]=(0,w.useState)(null),[k,A]=(0,w.useState)(new Set),j=Date.now();(0,w.useEffect)(()=>{if(!e)return;let t=!1;async function n(e,n,i){try{let a=await r(e);if(!a.ok)throw Error(`status ${a.status}`);let o=await a.json();t||i(n(o))}catch(t){console.error(`[admin-ui] dashboard-fetch-failed url=${e} reason=${t instanceof Error?t.message:String(t)}`)}}return n(`/api/admin/sidebar-sessions`,e=>e.sessions??[],d),n(`/api/whatsapp-reader/conversations`,e=>e.conversations??[],m),n(`/api/admin/system-stats`,e=>e,v),n(`/api/admin/tasks-list`,e=>e,E),n(`/api/admin/sidebar-artefacts`,e=>e.artefacts??[],O),()=>{t=!0}},[e,r]);let M=(0,w.useMemo)(()=>(o??[]).filter(e=>!e.isSubagent),[o]),N=(0,w.useMemo)(()=>M.filter(e=>e.live),[M]),P=(0,w.useMemo)(()=>(f??[]).filter(e=>H(e.lastMessageAt,j)).length,[f,j]),W=C?.open.length??0,G=(0,w.useMemo)(()=>{let e=new Map;for(let t of f??[]){let n=e.get(t.channel)??[];n.push(t),e.set(t.channel,n)}return[...e.entries()].map(([e,t])=>{let n=t.reduce((e,t)=>t.lastMessageAt&&(!e||Date.parse(t.lastMessageAt)>Date.parse(e.lastMessageAt??``))?t:e,null);return{channel:e,count:t.length,preview:n?V(n):``,rows:t}})},[f]),K=(0,w.useCallback)(async e=>{if(!k.has(e)){A(t=>new Set(t).add(e));try{let t=await r(`/api/admin/session-stop`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({sessionId:e})});if(!t.ok){console.error(`[admin-ui] dashboard-session-stop-failed sessionId=${e} status=${t.status}`);return}console.info(`[admin-ui] dashboard-session-stop sessionId=${e}`),d(t=>(t??[]).map(t=>t.sessionId===e?{...t,live:!1}:t))}catch(t){console.error(`[admin-ui] dashboard-session-stop-failed sessionId=${e} reason=${t instanceof Error?t.message:String(t)}`)}finally{A(t=>{let n=new Set(t);return n.delete(e),n})}}},[r,k]),q=(0,w.useCallback)(t=>{if(!e||!t.downloadPath){console.error(`[admin-ui] dashboard-artefact-download-blocked id=${t.id} reason=${e?`not-downloadable`:`no-cache-key`}`);return}y(e,t.downloadPath,t.downloadRoot??`data`)},[e]);return(0,T.jsxs)(`div`,{className:`dashboard-home`,children:[(0,T.jsx)(`p`,{className:`dashboard-greeting`,children:`Good ${L(new Date(j).getHours())}, ${R(t)} — ${z(_)}`}),(0,T.jsxs)(`div`,{className:`dashboard-stats`,children:[(0,T.jsxs)(`div`,{className:`admin-stat-card dashboard-stat-card`,children:[(0,T.jsx)(`span`,{className:`dashboard-stat-label`,children:`Live sessions`}),(0,T.jsx)(`span`,{className:`dashboard-stat-value`,children:N.length}),(0,T.jsxs)(`span`,{className:`dashboard-stat-delta`,children:[`of `,M.length,` total`]})]}),(0,T.jsxs)(`div`,{className:`admin-stat-card dashboard-stat-card`,children:[(0,T.jsx)(`span`,{className:`dashboard-stat-label`,children:`Messages today`}),(0,T.jsx)(`span`,{className:`dashboard-stat-value`,children:P})]}),(0,T.jsxs)(`div`,{className:`admin-stat-card dashboard-stat-card`,children:[(0,T.jsx)(`span`,{className:`dashboard-stat-label`,children:`Open tasks`}),(0,T.jsx)(`span`,{className:`dashboard-stat-value`,children:W})]}),(0,T.jsxs)(`div`,{className:`admin-stat-card dashboard-stat-card`,children:[(0,T.jsx)(`span`,{className:`dashboard-stat-label`,children:`Host CPU`}),(0,T.jsx)(`span`,{className:`dashboard-stat-value`,children:B(_?.cpuPct??null)}),(0,T.jsxs)(`span`,{className:`dashboard-stat-delta`,children:[`RAM `,B(_?.memUsedPct??null)]})]})]}),(0,T.jsxs)(`div`,{className:`dashboard-columns`,children:[(0,T.jsxs)(`div`,{className:`dashboard-col`,children:[(0,T.jsx)(`span`,{className:`admin-section-label dashboard-col-label`,children:`Live now`}),N.length===0?(0,T.jsx)(`div`,{className:`admin-card dashboard-empty`,children:`No live sessions right now.`}):N.map(e=>{let t=[e.sessionId.slice(0,8),U(e.model),F(Date.parse(e.startedAt),j)].filter(Boolean).join(` · `);return(0,T.jsxs)(`div`,{className:`admin-card dashboard-live-card`,children:[(0,T.jsx)(`span`,{className:`admin-status-dot is-live`}),(0,T.jsxs)(`div`,{className:`dashboard-live-main`,children:[(0,T.jsx)(`span`,{className:`dashboard-live-name`,children:e.title}),(0,T.jsx)(`span`,{className:`dashboard-live-meta`,children:t})]}),(0,T.jsx)(`a`,{className:`admin-btn-cta dashboard-open-btn`,href:`/chat?session=${encodeURIComponent(e.sessionId)}`,children:`Open`}),(0,T.jsx)(`button`,{type:`button`,className:`dashboard-stop-btn`,"aria-label":`Stop ${e.title}`,disabled:k.has(e.sessionId),onClick:()=>void K(e.sessionId),children:(0,T.jsx)(s,{size:12})})]},e.sessionId)}),(0,T.jsx)(`span`,{className:`admin-section-label dashboard-col-label`,children:`Recent artefacts`}),(0,T.jsx)(`div`,{className:`admin-card dashboard-artefacts`,children:(D??[]).length===0?(0,T.jsx)(`div`,{className:`dashboard-empty`,children:`No recent artefacts.`}):(D??[]).slice(0,6).map(e=>(0,T.jsxs)(`button`,{type:`button`,className:`admin-row dashboard-artefact-row`,onClick:()=>q(e),children:[(0,T.jsx)(`span`,{className:`dashboard-artefact-icon`,children:e.kind===`agent-template`?(0,T.jsx)(b,{size:16}):(0,T.jsx)(p,{size:16})}),(0,T.jsx)(`div`,{className:`dashboard-artefact-body`,children:(0,T.jsx)(`span`,{className:`dashboard-artefact-name`,children:e.name})}),(0,T.jsx)(`span`,{className:`dashboard-artefact-time`,children:F(Date.parse(e.updatedAt),j)})]},e.id))})]}),(0,T.jsxs)(`div`,{className:`dashboard-col`,children:[(0,T.jsx)(`span`,{className:`admin-section-label dashboard-col-label`,children:`Channels`}),G.length===0?(0,T.jsx)(`div`,{className:`admin-card dashboard-empty`,children:`No channel activity.`}):G.map(e=>{let t=h===e.channel;return(0,T.jsxs)(`div`,{className:`admin-card dashboard-channel-card`,children:[(0,T.jsxs)(`button`,{type:`button`,className:`dashboard-channel-head`,"aria-expanded":t,onClick:()=>g(t=>t===e.channel?null:e.channel),children:[(0,T.jsx)(`span`,{className:`dashboard-channel-glyph`,children:e.channel===`whatsapp`||e.channel===`telegram`?(0,T.jsx)(a,{channel:e.channel,size:16}):(0,T.jsx)(i,{size:16})}),(0,T.jsx)(`span`,{className:`dashboard-channel-name`,children:I[e.channel]??e.channel}),(0,T.jsx)(`span`,{className:`dashboard-channel-badge`,children:e.count}),(0,T.jsx)(`span`,{className:`dashboard-channel-chevron`,children:t?(0,T.jsx)(x,{size:14}):(0,T.jsx)(S,{size:14})})]}),t?(0,T.jsx)(`div`,{className:`dashboard-channel-convs`,children:e.rows.map(e=>(0,T.jsxs)(`button`,{type:`button`,className:`admin-row dashboard-channel-conv-row`,onClick:()=>n(e),title:e.title,children:[(0,T.jsx)(`span`,{className:`dashboard-channel-conv-name`,children:c(e)}),e.lastMessageAt&&(0,T.jsx)(`span`,{className:`dashboard-channel-conv-time`,children:F(Date.parse(e.lastMessageAt),j)})]},l(e)))}):e.preview&&(0,T.jsx)(`span`,{className:`dashboard-channel-preview`,children:e.preview})]},e.channel)})]})]})]})}function G(){let e=d(),[t,n]=(0,w.useState)(!1);(0,w.useEffect)(()=>{if(!t)return;let e=e=>{e.key===`Escape`&&n(!1)};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let r=(0,w.useCallback)(async()=>{let t=e.claudeInfo!=null;if(n(!0),t){console.info(`[admin-ui] claude-info-open cached=true ms=0`);return}let r=Date.now();try{let t=await fetch(`/api/admin/claude-info`);if(t.ok){let n=await t.json();e.setClaudeInfo(n)}console.info(`[admin-ui] claude-info-open cached=false ms=${Date.now()-r}`)}catch(e){console.error(`[admin-ui] claude-info-fetch-failed ms=${Date.now()-r} error="${e instanceof Error?e.message:String(e)}"`)}},[e]),i=(0,w.useCallback)(({code:t,path:n})=>{console.warn(`[admin-auth] outcome=chat-tab-logout-on-401 code=${t} path=${n}`),e.handleLogout()},[e]);return e.appState===`chat`?(0,T.jsx)(o,{cacheKey:e.cacheKey,onSessionExpired:i,surface:`chat`,children:(0,T.jsx)(g,{cacheKey:e.cacheKey,businessName:e.businessName,sessionId:e.sessionId,onLogout:e.handleLogout,onDisconnect:e.handleDisconnect,disconnecting:e.disconnecting,claudeConnected:e.claudeConnected,onConnectClaude:()=>e.setAppState(`connect-claude`),userName:e.userName,userAvatar:e.userAvatar,role:e.role,footer:(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(E,{onOpen:r}),(0,T.jsx)(h,{show:t,onClose:()=>n(!1),claudeInfo:e.claudeInfo,messages:[],sessionElapsed:0,sessionId:e.sessionId,cacheKey:e.cacheKey})]}),children:t=>(0,T.jsx)(T.Fragment,{children:t.dataOpen&&e.cacheKey?(0,T.jsx)(v,{cacheKey:e.cacheKey}):t.selectedWhatsapp&&e.cacheKey?t.selectedWhatsapp.source===`store`&&t.selectedWhatsapp.remoteJid&&t.selectedWhatsapp.accountId?(0,T.jsx)(_,{accountId:t.selectedWhatsapp.accountId,remoteJid:t.selectedWhatsapp.remoteJid,contactName:c(t.selectedWhatsapp),sessionKey:e.cacheKey},l(t.selectedWhatsapp)):(0,T.jsx)(m,{sessionId:t.selectedWhatsapp.sessionId,projectDir:t.selectedWhatsapp.projectDir,sessionKey:e.cacheKey,forceDeliveredOnly:!0},l(t.selectedWhatsapp)):(0,T.jsx)(W,{cacheKey:e.cacheKey,userName:e.userName,onSelectWhatsappConversation:t.onSelectWhatsappConversation})})})}):(0,T.jsx)(f,{auth:e})}(0,C.createRoot)(document.getElementById(`root`)).render((0,T.jsx)(G,{}));
@@ -1 +1 @@
1
- import{n as e,t}from"./path-CCRpdXhK.js";import{a as n,c as r,d as i,f as a,i as o,l as s,m as c,n as l,o as u,p as d,r as f,u as p}from"./dist-BATfy7Sn.js";function m(e){return e.innerRadius}function h(e){return e.outerRadius}function g(e){return e.startAngle}function _(e){return e.endAngle}function v(e){return e&&e.padAngle}function y(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<1e-12))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function b(e,t,n,r,i,a,o){var c=e-n,l=t-r,u=(o?a:-a)/d(c*c+l*l),f=u*l,p=-u*c,m=e+f,h=t+p,g=n+f,_=r+p,v=(m+g)/2,y=(h+_)/2,b=g-m,x=_-h,S=b*b+x*x,C=i-a,w=m*_-g*h,T=(x<0?-1:1)*d(s(0,C*C*S-w*w)),E=(w*x-b*T)/S,D=(-w*b-x*T)/S,O=(w*x+b*T)/S,k=(-w*b+x*T)/S,A=E-v,j=D-y,M=O-v,N=k-y;return A*A+j*j>M*M+N*N&&(E=O,D=k),{cx:E,cy:D,x01:-f,y01:-p,x11:E*(i/C-1),y11:D*(i/C-1)}}function x(){var s=m,x=h,S=e(0),C=null,w=g,T=_,E=v,D=null,O=t(k);function k(){var e,t,m=+s.apply(this,arguments),h=+x.apply(this,arguments),g=w.apply(this,arguments)-r,_=T.apply(this,arguments)-r,v=l(_-g),k=_>g;if(D||=e=O(),h<m&&(t=h,h=m,m=t),!(h>1e-12))D.moveTo(0,0);else if(v>c-1e-12)D.moveTo(h*u(g),h*a(g)),D.arc(0,0,h,g,_,!k),m>1e-12&&(D.moveTo(m*u(_),m*a(_)),D.arc(0,0,m,_,g,k));else{var A=g,j=_,M=g,N=_,P=v,F=v,I=E.apply(this,arguments)/2,L=I>1e-12&&(C?+C.apply(this,arguments):d(m*m+h*h)),R=p(l(h-m)/2,+S.apply(this,arguments)),z=R,B=R,V,H;if(L>1e-12){var U=o(L/m*a(I)),W=o(L/h*a(I));(P-=U*2)>1e-12?(U*=k?1:-1,M+=U,N-=U):(P=0,M=N=(g+_)/2),(F-=W*2)>1e-12?(W*=k?1:-1,A+=W,j-=W):(F=0,A=j=(g+_)/2)}var G=h*u(A),K=h*a(A),q=m*u(N),J=m*a(N);if(R>1e-12){var Y=h*u(j),X=h*a(j),Z=m*u(M),Q=m*a(M),$;if(v<i)if($=y(G,K,Z,Q,Y,X,q,J)){var ee=G-$[0],te=K-$[1],ne=Y-$[0],re=X-$[1],ie=1/a(f((ee*ne+te*re)/(d(ee*ee+te*te)*d(ne*ne+re*re)))/2),ae=d($[0]*$[0]+$[1]*$[1]);z=p(R,(m-ae)/(ie-1)),B=p(R,(h-ae)/(ie+1))}else z=B=0}F>1e-12?B>1e-12?(V=b(Z,Q,G,K,h,B,k),H=b(Y,X,q,J,h,B,k),D.moveTo(V.cx+V.x01,V.cy+V.y01),B<R?D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,h,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),!k),D.arc(H.cx,H.cy,B,n(H.y11,H.x11),n(H.y01,H.x01),!k))):(D.moveTo(G,K),D.arc(0,0,h,A,j,!k)):D.moveTo(G,K),!(m>1e-12)||!(P>1e-12)?D.lineTo(q,J):z>1e-12?(V=b(q,J,Y,X,m,-z,k),H=b(G,K,Z,Q,m,-z,k),D.lineTo(V.cx+V.x01,V.cy+V.y01),z<R?D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,m,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),k),D.arc(H.cx,H.cy,z,n(H.y11,H.x11),n(H.y01,H.x01),!k))):D.arc(0,0,m,N,M,k)}if(D.closePath(),e)return D=null,e+``||null}return k.centroid=function(){var e=(+s.apply(this,arguments)+ +x.apply(this,arguments))/2,t=(+w.apply(this,arguments)+ +T.apply(this,arguments))/2-i/2;return[u(t)*e,a(t)*e]},k.innerRadius=function(t){return arguments.length?(s=typeof t==`function`?t:e(+t),k):s},k.outerRadius=function(t){return arguments.length?(x=typeof t==`function`?t:e(+t),k):x},k.cornerRadius=function(t){return arguments.length?(S=typeof t==`function`?t:e(+t),k):S},k.padRadius=function(t){return arguments.length?(C=t==null?null:typeof t==`function`?t:e(+t),k):C},k.startAngle=function(t){return arguments.length?(w=typeof t==`function`?t:e(+t),k):w},k.endAngle=function(t){return arguments.length?(T=typeof t==`function`?t:e(+t),k):T},k.padAngle=function(t){return arguments.length?(E=typeof t==`function`?t:e(+t),k):E},k.context=function(e){return arguments.length?(D=e??null,k):D},k}export{x as t};
1
+ import{n as e,t}from"./path-JZiojYzQ.js";import{a as n,c as r,d as i,f as a,i as o,l as s,m as c,n as l,o as u,p as d,r as f,u as p}from"./dist-CLmrZbY7.js";function m(e){return e.innerRadius}function h(e){return e.outerRadius}function g(e){return e.startAngle}function _(e){return e.endAngle}function v(e){return e&&e.padAngle}function y(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<1e-12))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function b(e,t,n,r,i,a,o){var c=e-n,l=t-r,u=(o?a:-a)/d(c*c+l*l),f=u*l,p=-u*c,m=e+f,h=t+p,g=n+f,_=r+p,v=(m+g)/2,y=(h+_)/2,b=g-m,x=_-h,S=b*b+x*x,C=i-a,w=m*_-g*h,T=(x<0?-1:1)*d(s(0,C*C*S-w*w)),E=(w*x-b*T)/S,D=(-w*b-x*T)/S,O=(w*x+b*T)/S,k=(-w*b+x*T)/S,A=E-v,j=D-y,M=O-v,N=k-y;return A*A+j*j>M*M+N*N&&(E=O,D=k),{cx:E,cy:D,x01:-f,y01:-p,x11:E*(i/C-1),y11:D*(i/C-1)}}function x(){var s=m,x=h,S=e(0),C=null,w=g,T=_,E=v,D=null,O=t(k);function k(){var e,t,m=+s.apply(this,arguments),h=+x.apply(this,arguments),g=w.apply(this,arguments)-r,_=T.apply(this,arguments)-r,v=l(_-g),k=_>g;if(D||=e=O(),h<m&&(t=h,h=m,m=t),!(h>1e-12))D.moveTo(0,0);else if(v>c-1e-12)D.moveTo(h*u(g),h*a(g)),D.arc(0,0,h,g,_,!k),m>1e-12&&(D.moveTo(m*u(_),m*a(_)),D.arc(0,0,m,_,g,k));else{var A=g,j=_,M=g,N=_,P=v,F=v,I=E.apply(this,arguments)/2,L=I>1e-12&&(C?+C.apply(this,arguments):d(m*m+h*h)),R=p(l(h-m)/2,+S.apply(this,arguments)),z=R,B=R,V,H;if(L>1e-12){var U=o(L/m*a(I)),W=o(L/h*a(I));(P-=U*2)>1e-12?(U*=k?1:-1,M+=U,N-=U):(P=0,M=N=(g+_)/2),(F-=W*2)>1e-12?(W*=k?1:-1,A+=W,j-=W):(F=0,A=j=(g+_)/2)}var G=h*u(A),K=h*a(A),q=m*u(N),J=m*a(N);if(R>1e-12){var Y=h*u(j),X=h*a(j),Z=m*u(M),Q=m*a(M),$;if(v<i)if($=y(G,K,Z,Q,Y,X,q,J)){var ee=G-$[0],te=K-$[1],ne=Y-$[0],re=X-$[1],ie=1/a(f((ee*ne+te*re)/(d(ee*ee+te*te)*d(ne*ne+re*re)))/2),ae=d($[0]*$[0]+$[1]*$[1]);z=p(R,(m-ae)/(ie-1)),B=p(R,(h-ae)/(ie+1))}else z=B=0}F>1e-12?B>1e-12?(V=b(Z,Q,G,K,h,B,k),H=b(Y,X,q,J,h,B,k),D.moveTo(V.cx+V.x01,V.cy+V.y01),B<R?D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,h,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),!k),D.arc(H.cx,H.cy,B,n(H.y11,H.x11),n(H.y01,H.x01),!k))):(D.moveTo(G,K),D.arc(0,0,h,A,j,!k)):D.moveTo(G,K),!(m>1e-12)||!(P>1e-12)?D.lineTo(q,J):z>1e-12?(V=b(q,J,Y,X,m,-z,k),H=b(G,K,Z,Q,m,-z,k),D.lineTo(V.cx+V.x01,V.cy+V.y01),z<R?D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,m,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),k),D.arc(H.cx,H.cy,z,n(H.y11,H.x11),n(H.y01,H.x01),!k))):D.arc(0,0,m,N,M,k)}if(D.closePath(),e)return D=null,e+``||null}return k.centroid=function(){var e=(+s.apply(this,arguments)+ +x.apply(this,arguments))/2,t=(+w.apply(this,arguments)+ +T.apply(this,arguments))/2-i/2;return[u(t)*e,a(t)*e]},k.innerRadius=function(t){return arguments.length?(s=typeof t==`function`?t:e(+t),k):s},k.outerRadius=function(t){return arguments.length?(x=typeof t==`function`?t:e(+t),k):x},k.cornerRadius=function(t){return arguments.length?(S=typeof t==`function`?t:e(+t),k):S},k.padRadius=function(t){return arguments.length?(C=t==null?null:typeof t==`function`?t:e(+t),k):C},k.startAngle=function(t){return arguments.length?(w=typeof t==`function`?t:e(+t),k):w},k.endAngle=function(t){return arguments.length?(T=typeof t==`function`?t:e(+t),k):T},k.padAngle=function(t){return arguments.length?(E=typeof t==`function`?t:e(+t),k):E},k.context=function(e){return arguments.length?(D=e??null,k):D},k}export{x as t};
@@ -0,0 +1 @@
1
+ import"./chunk-K5T4RW27-EHiXZ8Py.js";import{n as e}from"./chunk-7N4EOEYR-CAACaqFr.js";export{e as createArchitectureServices};