@kabmo-labs/kabmo 0.59.0 → 0.60.0

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 (384) hide show
  1. package/dist/client/index.html +1 -1
  2. package/dist/client/index.js +397 -397
  3. package/dist/client/static/js/{Body-jqq4654r.js → Body-p82s28sj.js} +3 -3
  4. package/dist/client/static/js/{CsvGrid-avw0taqb.js → CsvGrid-erc5mcvc.js} +2 -2
  5. package/dist/client/static/js/{DocxView-d221vr6g.js → DocxView-x3faj0jv.js} +3 -3
  6. package/dist/client/static/js/{DrawioView-gjsy7p01.js → DrawioView-t7fh3ens.js} +2 -2
  7. package/dist/client/static/js/{HtmlPreview-949393v1.js → HtmlPreview-zy7x7jmm.js} +1 -1
  8. package/dist/client/static/js/ImageView-xc90jc1c.js +1 -0
  9. package/dist/client/static/js/LayoutWrapper-wyqe98kf.js +2 -0
  10. package/dist/client/static/js/MergeDiffView-bng34cpr.js +1 -0
  11. package/dist/client/static/js/Modal-89jk7wff.js +60 -0
  12. package/dist/client/static/js/{PdfView-dzj2s6rj.js → PdfView-kqx472q7.js} +1 -1
  13. package/dist/client/static/js/SessionsView-6bpz1faj.js +1 -0
  14. package/dist/client/static/js/{SheetView-jpc178g5.js → SheetView-0n9fze50.js} +9 -9
  15. package/dist/client/static/js/{SvgPreview-94fap32p.js → SvgPreview-6xc6ts46.js} +1 -1
  16. package/dist/client/static/js/{abnfDiagram-O67JEVCF-a6eyfzrj.js → abnfDiagram-O67JEVCF-2xdkkqwg.js} +1 -1
  17. package/dist/client/static/js/architecture-7GRP2DOG-sxrkxwbq.js +1 -0
  18. package/dist/client/static/js/{architectureDiagram-NJMV4G6O-pgmyfncy.js → architectureDiagram-NJMV4G6O-ja8cx19z.js} +11 -11
  19. package/dist/client/static/js/{astro-ryr2ajmg.js → astro-yphdvdty.js} +1 -1
  20. package/dist/client/static/js/bash-bcbct9gc.js +1 -0
  21. package/dist/client/static/js/{blockDiagram-BEXU5L5S-rf51jyb2.js → blockDiagram-BEXU5L5S-ytf7s99c.js} +8 -8
  22. package/dist/client/static/js/c-fn9jz26e.js +1 -0
  23. package/dist/client/static/js/{c4Diagram-YGBWAQC7-0faj48jp.js → c4Diagram-YGBWAQC7-5a0kdx0z.js} +5 -5
  24. package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-bvzsws8x.js → classDiagram-v2-NBCMYWYE-hd98dvjw.js} +6 -6
  25. package/dist/client/static/js/{cose-bilkent-JH36ORCC-j1amnd3m.js → cose-bilkent-JH36ORCC-man3fqcj.js} +1 -1
  26. package/dist/client/static/js/cpp-a1q64mke.js +1 -0
  27. package/dist/client/static/js/css-b92azee8.js +1 -0
  28. package/dist/client/static/js/cynefin-OW5HDTMX-g1xwa8b9.js +1 -0
  29. package/dist/client/static/js/{cynefinDiagram-VND7K2PF-f73w6zzz.js → cynefinDiagram-VND7K2PF-2f0kbbv2.js} +2 -2
  30. package/dist/client/static/js/{dagre-6A5THRUB-a5vgvjsg.js → dagre-6A5THRUB-k7pyhgzn.js} +2 -2
  31. package/dist/client/static/js/{diagram-22UHCM2B-6y9efamp.js → diagram-22UHCM2B-qx0afa2m.js} +15 -15
  32. package/dist/client/static/js/{diagram-3UASUU5V-2mycy7xm.js → diagram-3UASUU5V-ydpe77sv.js} +2 -2
  33. package/dist/client/static/js/{diagram-ATOU4E4O-10zgjb66.js → diagram-ATOU4E4O-e63v984n.js} +2 -2
  34. package/dist/client/static/js/{diagram-CDSNMT55-bewa52yf.js → diagram-CDSNMT55-8c765h3a.js} +4 -4
  35. package/dist/client/static/js/{diagram-MLGK6HIB-mh3b7gd3.js → diagram-MLGK6HIB-3pq0n7v8.js} +2 -2
  36. package/dist/client/static/js/{diagram-MPIPVDR6-gvdrbdm5.js → diagram-MPIPVDR6-638atzxz.js} +2 -2
  37. package/dist/client/static/js/{dockerfile-6bn19kg0.js → dockerfile-yehc914q.js} +1 -1
  38. package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-2prre93c.js → ebnfDiagram-ZINNZB2B-3gv43zvm.js} +1 -1
  39. package/dist/client/static/js/{elixir-fyxw6d70.js → elixir-3nwnd9yw.js} +1 -1
  40. package/dist/client/static/js/{elk-276RUBZZ-9t6t9kc6.js → elk-276RUBZZ-6s5pggfc.js} +1 -1
  41. package/dist/client/static/js/{erDiagram-OPXOYQCR-etcggr5n.js → erDiagram-OPXOYQCR-x7cqyb89.js} +3 -3
  42. package/dist/client/static/js/{erlang-97ayje6m.js → erlang-p5c4n3t0.js} +1 -1
  43. package/dist/client/static/js/eventmodeling-NTZA5JFV-05p61bka.js +1 -0
  44. package/dist/client/static/js/flowDiagram-KWPJA3E3-7sn6nwjv.js +1 -0
  45. package/dist/client/static/js/{ganttDiagram-FUAMR5RP-cdc4mwhs.js → ganttDiagram-FUAMR5RP-g97te4v1.js} +5 -5
  46. package/dist/client/static/js/gitGraph-4MIJSDKK-z1yehwys.js +1 -0
  47. package/dist/client/static/js/{gitGraphDiagram-X574FWY7-55d0fa7x.js → gitGraphDiagram-X574FWY7-sw4f94tc.js} +14 -14
  48. package/dist/client/static/js/graphql-8d8bn59j.js +1 -0
  49. package/dist/client/static/js/html-6hdrwtz2.js +1 -0
  50. package/dist/client/static/js/{index-5e4e18tg.js → index-025s3fp8.js} +2 -2
  51. package/dist/client/static/js/{index-pgy7ree5.js → index-0ze5bwvw.js} +5 -5
  52. package/dist/client/static/js/{index-f13ern5e.js → index-111bq6rs.js} +1 -1
  53. package/dist/client/static/js/{index-8tzt0dek.js → index-11qn05g9.js} +2 -2
  54. package/dist/client/static/js/{index-np2rfq06.js → index-2dmew334.js} +2 -2
  55. package/dist/client/static/js/index-2n2evsg0.js +2 -0
  56. package/dist/client/static/js/{index-trq7bdvk.js → index-37apvxgj.js} +2 -2
  57. package/dist/client/static/js/{index-6bsez5n6.js → index-43gmn7yb.js} +1 -1
  58. package/dist/client/static/js/index-4h2zkrk1.js +2 -0
  59. package/dist/client/static/js/{index-xe447cw3.js → index-4xbc0j7t.js} +1 -1
  60. package/dist/client/static/js/index-5nm8hm4k.js +2 -0
  61. package/dist/client/static/js/{index-mx5y9vt9.js → index-6qn9kygb.js} +7 -7
  62. package/dist/client/static/js/{index-jpvng27a.js → index-8zct30zd.js} +1 -1
  63. package/dist/client/static/js/{index-eggbcdwx.js → index-95jfphx5.js} +197 -197
  64. package/dist/client/static/js/{index-yrwm437g.js → index-97sw4d9n.js} +2 -2
  65. package/dist/client/static/js/{index-8z9aqgf3.js → index-9pw441wc.js} +4 -4
  66. package/dist/client/static/js/{index-27gwghmp.js → index-9rz6kzsv.js} +1 -1
  67. package/dist/client/static/js/{index-y4cx8cqf.js → index-a145x0w2.js} +2 -2
  68. package/dist/client/static/js/{index-mhrkjbjq.js → index-bdtftrym.js} +2 -2
  69. package/dist/client/static/js/index-bjz54ht6.js +1 -0
  70. package/dist/client/static/js/{index-db6s66jr.js → index-bkn6jtn1.js} +2 -2
  71. package/dist/client/static/js/{index-rw84kefb.js → index-bpcg34jp.js} +2 -2
  72. package/dist/client/static/js/{index-f6t91mpp.js → index-bqapt2e8.js} +1 -1
  73. package/dist/client/static/js/{index-ndqtff48.js → index-ca6tmamh.js} +2 -2
  74. package/dist/client/static/js/{index-fyt8m8ah.js → index-cf69bhjx.js} +2 -2
  75. package/dist/client/static/js/{index-yh7gngsh.js → index-cfvc1zpk.js} +2 -2
  76. package/dist/client/static/js/{index-nnwcbp2d.js → index-ddkjgv5h.js} +2 -2
  77. package/dist/client/static/js/{index-60cxxnpk.js → index-dekvtt2a.js} +87 -87
  78. package/dist/client/static/js/{index-ax8gaayq.js → index-dv01prse.js} +2 -2
  79. package/dist/client/static/js/{index-sg65xdey.js → index-enm77k5z.js} +2 -2
  80. package/dist/client/static/js/{index-nf4hq5tg.js → index-excgtjhx.js} +14 -14
  81. package/dist/client/static/js/{index-51rbgeh9.js → index-fb2fjndj.js} +5 -5
  82. package/dist/client/static/js/index-fnwaxc6r.js +1 -0
  83. package/dist/client/static/js/{index-vs2y8gxr.js → index-fr6wsqk8.js} +2 -2
  84. package/dist/client/static/js/index-h65zrhva.js +1 -0
  85. package/dist/client/static/js/{index-fr91ghwb.js → index-hgfyx8dt.js} +2 -2
  86. package/dist/client/static/js/{index-gcad7b6g.js → index-hwdkxe4n.js} +2 -2
  87. package/dist/client/static/js/{index-69mnn71v.js → index-hwv7bfxc.js} +2 -2
  88. package/dist/client/static/js/index-hxsqw7sz.js +4 -0
  89. package/dist/client/static/js/{index-461ga40v.js → index-hxy1sadd.js} +2 -2
  90. package/dist/client/static/js/{index-c253x7vt.js → index-ja0ajnvq.js} +7 -7
  91. package/dist/client/static/js/{index-2f6afhze.js → index-jfqd838j.js} +2 -2
  92. package/dist/client/static/js/{index-d9sfavx1.js → index-mtav0rpf.js} +2 -2
  93. package/dist/client/static/js/{index-58z2hatp.js → index-n8r7r86r.js} +1 -1
  94. package/dist/client/static/js/{index-j1ksa4x2.js → index-pdgc9ccr.js} +1 -1
  95. package/dist/client/static/js/{index-s9ts6qbj.js → index-pdz6j2g2.js} +2 -2
  96. package/dist/client/static/js/{index-jct0jryd.js → index-qccydkze.js} +2 -2
  97. package/dist/client/static/js/{index-yg38s8t3.js → index-qkqkygrf.js} +1 -1
  98. package/dist/client/static/js/index-qkyy563e.js +1 -0
  99. package/dist/client/static/js/{index-92h38pwg.js → index-s4j2ghmx.js} +2 -2
  100. package/dist/client/static/js/{index-z82nd2bd.js → index-sx83ans2.js} +2 -2
  101. package/dist/client/static/js/index-t6nqy2n5.css +1 -0
  102. package/dist/client/static/js/{index-fsa18ns9.js → index-twwsn91p.js} +2 -2
  103. package/dist/client/static/js/{index-nwbr15b3.js → index-v88m5sva.js} +2 -2
  104. package/dist/client/static/js/{index-a5ecn5yx.js → index-vcq6zfxx.js} +6 -6
  105. package/dist/client/static/js/{index-3akjcs82.js → index-vec7m1yd.js} +2 -2
  106. package/dist/client/static/js/{index-mngpcca7.js → index-vejz38qt.js} +9 -9
  107. package/dist/client/static/js/{index-9rvjegmy.js → index-wrk99kks.js} +2 -2
  108. package/dist/client/static/js/{index-q3k8r0ms.js → index-wsy6y5em.js} +9 -9
  109. package/dist/client/static/js/{index-h1xbx74w.js → index-yfcy4cf6.js} +2 -2
  110. package/dist/client/static/js/{index-pa70qj4p.js → index-ywp0sd1e.js} +1 -1
  111. package/dist/client/static/js/{index-njhrm5qa.js → index-z8k42dwz.js} +9 -9
  112. package/dist/client/static/js/info-A6RAGUB7-dqyaxjc1.js +1 -0
  113. package/dist/client/static/js/{infoDiagram-VRGFBTTK-9xph6cr5.js → infoDiagram-VRGFBTTK-pw2qaa27.js} +1 -1
  114. package/dist/client/static/js/ini-g6a5xsaw.js +1 -0
  115. package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-3gshs3v8.js → ishikawaDiagram-OU5B5YK6-d13jhvxy.js} +3 -3
  116. package/dist/client/static/js/java-n596am4c.js +1 -0
  117. package/dist/client/static/js/{journeyDiagram-ZHPQQLJL-fa8x56mf.js → journeyDiagram-ZHPQQLJL-20gb8a04.js} +4 -4
  118. package/dist/client/static/js/json-7k70qbkj.js +1 -0
  119. package/dist/client/static/js/jsx-sndenqrc.js +1 -0
  120. package/dist/client/static/js/{julia-agc5kfvg.js → julia-rpd1y9vh.js} +1 -1
  121. package/dist/client/static/js/{kanban-definition-PNTS6WVX-fybp2hh4.js → kanban-definition-PNTS6WVX-s78e158c.js} +5 -5
  122. package/dist/client/static/js/lua-djd3g9q5.js +1 -0
  123. package/dist/client/static/js/markdown-r2tpvxpn.js +1 -0
  124. package/dist/client/static/js/{mermaid.core-jjh5ggp0.js → mermaid.core-xbm27k28.js} +6 -6
  125. package/dist/client/static/js/{mindmap-definition-NLK3R4M7-gtfbg619.js → mindmap-definition-NLK3R4M7-6y7xe2zm.js} +7 -7
  126. package/dist/client/static/js/one-dark-pro-7bgqnyhm.js +1 -0
  127. package/dist/client/static/js/one-light-47y6etng.js +1 -0
  128. package/dist/client/static/js/packet-AYTQ26CC-7jxzax4z.js +1 -0
  129. package/dist/client/static/js/{pegDiagram-GJSIUBJH-1a51sbqv.js → pegDiagram-GJSIUBJH-dmvewetf.js} +1 -1
  130. package/dist/client/static/js/{perl-v5vbtzgf.js → perl-kmtz9dnv.js} +1 -1
  131. package/dist/client/static/js/{php-83qwy98t.js → php-bttrsbxy.js} +1 -1
  132. package/dist/client/static/js/pie-WAS4IAKB-wc9wxr7f.js +1 -0
  133. package/dist/client/static/js/{pieDiagram-5QR66LMP-zd9svyyn.js → pieDiagram-5QR66LMP-1q9e7rcm.js} +2 -2
  134. package/dist/client/static/js/properties-brn72zdk.js +1 -0
  135. package/dist/client/static/js/python-g9mghwgm.js +1 -0
  136. package/dist/client/static/js/{quadrantDiagram-O4NWA36T-5gtw2m6s.js → quadrantDiagram-O4NWA36T-mvrem3n6.js} +4 -4
  137. package/dist/client/static/js/r-e247x4mw.js +1 -0
  138. package/dist/client/static/js/radar-RG4KPBEZ-kwj5padj.js +1 -0
  139. package/dist/client/static/js/railroad-74A4TZTK-h8sdx3w5.js +1 -0
  140. package/dist/client/static/js/railroad-abnf-HS5TGJTU-2wmwx246.js +1 -0
  141. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-h4cdgw3y.js +1 -0
  142. package/dist/client/static/js/railroad-peg-WCYAUIDC-q7m0tfd0.js +1 -0
  143. package/dist/client/static/js/{railroadDiagram-XR7U4H2S-3ccwpfzz.js → railroadDiagram-XR7U4H2S-axttcfhw.js} +1 -1
  144. package/dist/client/static/js/{requirementDiagram-PLB6GJNP-sasndrrp.js → requirementDiagram-PLB6GJNP-5qx7erta.js} +12 -12
  145. package/dist/client/static/js/{ruby-994n5j6e.js → ruby-dve3y59w.js} +1 -1
  146. package/dist/client/static/js/{rust-n9z2c9m3.js → rust-b3ckax3e.js} +1 -1
  147. package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-2ahb4sda.js → sankeyDiagram-IPEJSGJF-es87a3j6.js} +4 -4
  148. package/dist/client/static/js/{sass-p6g7qdv2.js → sass-emxqt5p2.js} +1 -1
  149. package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-bfj90kz1.js → sequenceDiagram-PO4LG4MO-dgpnjrtk.js} +21 -21
  150. package/dist/client/static/js/{sizeCapture-INFHLROL-5tygxmtc.js → sizeCapture-INFHLROL-kyw0p86n.js} +1 -1
  151. package/dist/client/static/js/sql-0kar81jy.js +1 -0
  152. package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-533xw76e.js → stateDiagram-v2-GCMORJYK-vnsbw8y9.js} +3 -3
  153. package/dist/client/static/js/{svelte-bek3h1sz.js → svelte-dbsx1ehx.js} +1 -1
  154. package/dist/client/static/js/{swimlanes-2SLR337P-gd3d04pk.js → swimlanes-2SLR337P-060q1rep.js} +1 -1
  155. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-y77g9dq0.js +8 -0
  156. package/dist/client/static/js/{timeline-definition-EJHVYXUP-fvqvgqvg.js → timeline-definition-EJHVYXUP-8a3yqmx0.js} +6 -6
  157. package/dist/client/static/js/treeView-Q6P3EWNA-yv9640h3.js +1 -0
  158. package/dist/client/static/js/treemap-WGGIJYW6-7kpzjg21.js +1 -0
  159. package/dist/client/static/js/typescript-bm89v3gk.js +1 -0
  160. package/dist/client/static/js/{usecaseDiagram-POWQR4AR-tm1f0m4x.js → usecaseDiagram-POWQR4AR-18sp73v7.js} +51 -51
  161. package/dist/client/static/js/{vennDiagram-UO4OBE2U-2vdvv1hd.js → vennDiagram-UO4OBE2U-gf4y1r3s.js} +5 -5
  162. package/dist/client/static/js/{vue-y44m889c.js → vue-hyr58df9.js} +1 -1
  163. package/dist/client/static/js/wardley-WFR3VGLG-mggay64p.js +1 -0
  164. package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-7avcjznx.js → wardleyDiagram-VNRHLVJA-q0kwmbzh.js} +5 -5
  165. package/dist/client/static/js/xml-b7824nx0.js +1 -0
  166. package/dist/client/static/js/{xychartDiagram-PMCCYNJV-g39y526n.js → xychartDiagram-PMCCYNJV-y0gpmg6m.js} +6 -6
  167. package/dist/client/static/js/yaml-kqqktdv1.js +1 -0
  168. package/package.json +4 -4
  169. package/src/client/borders.css +28 -15
  170. package/src/client/components/common/Modal.tsx +10 -2
  171. package/src/client/components/common/Toast.tsx +8 -3
  172. package/src/client/components/common/anchored-menu/index.tsx +10 -3
  173. package/src/client/components/common/command-palette/index.tsx +9 -3
  174. package/src/client/components/common/fullscreen-viewer/index.tsx +1 -1
  175. package/src/client/components/common/header-controls/index.test.tsx +40 -3
  176. package/src/client/components/common/header-controls/index.tsx +106 -56
  177. package/src/client/components/common/search-select/search-select.test.tsx +10 -1
  178. package/src/client/components/common/session-row/TrailingSlot.tsx +8 -1
  179. package/src/client/components/common/session-row/index.tsx +4 -0
  180. package/src/client/components/common/session-row/session-row.test.tsx +5 -0
  181. package/src/client/components/common/workspace-mark/index.test.tsx +67 -0
  182. package/src/client/components/common/workspace-mark/index.tsx +48 -0
  183. package/src/client/components/layout/ActivityBar.test.ts +1 -1
  184. package/src/client/components/layout/ActivityBarDrag.test.ts +1 -1
  185. package/src/client/components/layout/LeftActivityBar.test.ts +48 -3
  186. package/src/client/components/layout/LeftDock.tsx +33 -14
  187. package/src/client/components/layout/PanelButton.test.tsx +119 -0
  188. package/src/client/components/layout/PanelButton.tsx +2 -4
  189. package/src/client/components/layout/activity-bar/Row.tsx +125 -0
  190. package/src/client/components/layout/{ActivityBar.tsx → activity-bar/index.tsx} +81 -20
  191. package/src/client/components/layout/controls-bar/index.tsx +183 -0
  192. package/src/client/components/layout/desktop-layout/BarSlot.tsx +18 -0
  193. package/src/client/components/layout/desktop-layout/LeftColumn.test.tsx +187 -0
  194. package/src/client/components/layout/desktop-layout/LeftColumn.tsx +81 -64
  195. package/src/client/components/layout/desktop-layout/LeftRail.tsx +60 -0
  196. package/src/client/components/layout/desktop-layout/LeftTabsColumn.tsx +91 -0
  197. package/src/client/components/layout/desktop-layout/ResizeHandle.tsx +19 -3
  198. package/src/client/components/layout/desktop-layout/RightColumn.test.tsx +60 -0
  199. package/src/client/components/layout/desktop-layout/RightColumn.tsx +77 -28
  200. package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +114 -104
  201. package/src/client/components/layout/desktop-layout/index.tsx +48 -45
  202. package/src/client/components/layout/desktop-layout/resizer/index.tsx +25 -83
  203. package/src/client/components/layout/desktop-layout/resizer/panel-motion.ts +61 -0
  204. package/src/client/components/layout/desktop-layout/resizer/panel.test.ts +40 -2
  205. package/src/client/components/layout/desktop-layout/resizer/separator.tsx +89 -0
  206. package/src/client/components/layout/left-bar/index.tsx +88 -0
  207. package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +5 -2
  208. package/src/client/components/layout/session-sidebar/Footer.tsx +28 -11
  209. package/src/client/components/layout/session-sidebar/FooterHost.tsx +167 -0
  210. package/src/client/components/layout/session-sidebar/SessionItem.tsx +2 -2
  211. package/src/client/components/layout/session-sidebar/about-modal/index.tsx +8 -3
  212. package/src/client/components/layout/session-sidebar/footer-host.test.tsx +133 -0
  213. package/src/client/components/layout/session-sidebar/modern/RevealRow.tsx +36 -5
  214. package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +5 -2
  215. package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +1 -0
  216. package/src/client/components/layout/session-sidebar/modern/reveal-row.test.tsx +28 -1
  217. package/src/client/components/layout/session-title-bar/index.tsx +199 -0
  218. package/src/client/components/layout/top-bars.test.tsx +338 -0
  219. package/src/client/components/mobile/LayoutWrapper.tsx +13 -2
  220. package/src/client/components/mobile/SessionSidebar.tsx +10 -8
  221. package/src/client/components/mobile/drawer-layout.test.tsx +67 -0
  222. package/src/client/components/mobile/drawer-strip.tsx +37 -14
  223. package/src/client/components/mobile/left-drawer-nav.test.tsx +19 -127
  224. package/src/client/components/settings/LazyModal.tsx +8 -2
  225. package/src/client/components/settings/Modal.tsx +6 -2
  226. package/src/client/components/settings/apply-side-effects.ts +5 -0
  227. package/src/client/components/settings/categories/AppearanceSettings.test.tsx +1 -0
  228. package/src/client/components/settings/categories/AppearanceSettings.tsx +2 -0
  229. package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.test.tsx +6 -5
  230. package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.tsx +2 -2
  231. package/src/client/components/settings/categories/appearance-settings/ChromeStyleSection.tsx +105 -0
  232. package/src/client/components/settings/categories/appearance-settings/groups.ts +3 -2
  233. package/src/client/components/settings/categories/mcp-settings/ImportModal.tsx +1 -1
  234. package/src/client/components/settings/categories/voice-settings/SpeechSettings.test.tsx +2 -2
  235. package/src/client/components/workspace/chat-timeline/AiMessageFooter.tsx +2 -2
  236. package/src/client/components/workspace/chat-timeline/AiMessageFooterSheet.tsx +2 -2
  237. package/src/client/components/workspace/chat-timeline/GeneratingIndicator.tsx +1 -1
  238. package/src/client/components/workspace/chat-timeline/NewChatModal.tsx +1 -1
  239. package/src/client/components/workspace/chat-timeline/UndoConfirmModal.tsx +1 -1
  240. package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.test.ts +8 -1
  241. package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.test.tsx +8 -1
  242. package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.test.tsx +9 -2
  243. package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.tsx +1 -25
  244. package/src/client/components/workspace/editor/SaveDeletedFileModal.tsx +1 -1
  245. package/src/client/components/workspace/editor/Tab.tsx +160 -0
  246. package/src/client/components/workspace/editor/Tabs.test.ts +40 -0
  247. package/src/client/components/workspace/editor/Tabs.tsx +52 -102
  248. package/src/client/components/workspace/editor/index.tsx +2 -0
  249. package/src/client/components/workspace/editor/props.ts +6 -0
  250. package/src/client/components/workspace/file-explorer/OutlineResize.test.tsx +225 -0
  251. package/src/client/components/workspace/file-explorer/OutlineSection.tsx +43 -3
  252. package/src/client/components/workspace/file-explorer/index.tsx +1 -1
  253. package/src/client/components/workspace/model-dropdown/CloseButton.tsx +2 -2
  254. package/src/client/components/workspace/model-dropdown/Fullscreen.tsx +2 -2
  255. package/src/client/components/workspace/model-dropdown/HarnessTabs.tsx +10 -1
  256. package/src/client/components/workspace/model-dropdown/Header.tsx +27 -20
  257. package/src/client/components/workspace/model-dropdown/Panel.tsx +2 -2
  258. package/src/client/components/workspace/model-dropdown/SpecsTooltip.tsx +1 -1
  259. package/src/client/components/workspace/model-dropdown/harness-tabs.test.tsx +18 -0
  260. package/src/client/components/workspace/model-dropdown/picker-close.test.tsx +34 -4
  261. package/src/client/components/workspace/panel-tabs/TabChip.tsx +48 -20
  262. package/src/client/components/workspace/panel-tabs/TabStrip.connected.test.tsx +163 -0
  263. package/src/client/components/workspace/panel-tabs/TabStrip.tsx +18 -9
  264. package/src/client/components/workspace/search-panel/Body.tsx +3 -3
  265. package/src/client/components/workspace/terminal-panel/RealtimeTerminalView.tsx +1 -1
  266. package/src/client/data/settings/omp-schema.json +205 -9
  267. package/src/client/floating.css +276 -0
  268. package/src/client/floating.test.ts +151 -0
  269. package/src/client/hooks/chat/timeline/session-pagination.ts +13 -9
  270. package/src/client/hooks/editor/use-outline-resize.ts +145 -0
  271. package/src/client/hooks/ui/border-style.test.ts +19 -7
  272. package/src/client/hooks/ui/border-style.ts +2 -3
  273. package/src/client/hooks/ui/chrome-style.test.ts +140 -0
  274. package/src/client/hooks/ui/chrome-style.ts +75 -0
  275. package/src/client/hooks/ui/media-query.ts +29 -0
  276. package/src/client/hooks/ui/presence.test.ts +104 -0
  277. package/src/client/hooks/ui/presence.ts +62 -0
  278. package/src/client/hooks/ui/style-attributes.test.ts +7 -6
  279. package/src/client/hooks/ui/surface-style.ts +2 -2
  280. package/src/client/hooks/ui/titlebar-inset.test.ts +56 -0
  281. package/src/client/hooks/ui/titlebar-inset.ts +31 -0
  282. package/src/client/hooks/workspace/available-width.ts +25 -1
  283. package/src/client/hooks/workspace/panel-peek.test.ts +124 -0
  284. package/src/client/hooks/workspace/panel-peek.ts +151 -0
  285. package/src/client/hooks/workspace/panel-rail.test.ts +86 -0
  286. package/src/client/hooks/workspace/panel-rail.ts +108 -0
  287. package/src/client/hooks/workspace/panel-resize.ts +8 -2
  288. package/src/client/hooks/workspace/rail-peek.test.ts +119 -0
  289. package/src/client/hooks/workspace/rail-peek.ts +68 -0
  290. package/src/client/hooks/workspace/right-panel-card.test.ts +71 -0
  291. package/src/client/hooks/workspace/right-panel-card.ts +69 -0
  292. package/src/client/hooks/workspace/right-panel-geometry.ts +172 -0
  293. package/src/client/hooks/workspace/right-side.ts +7 -0
  294. package/src/client/lib/desktop/titlebar.test.ts +6 -0
  295. package/src/client/lib/desktop/titlebar.ts +16 -0
  296. package/src/client/main.tsx +11 -0
  297. package/src/client/motion.test.ts +36 -0
  298. package/src/client/tailwind.css +67 -0
  299. package/src/server/lib/assets/shell-attributes.server.ts +14 -4
  300. package/src/server/lib/assets/shell-attributes.test.ts +35 -21
  301. package/src/server/lib/bundler/titlebar-css.test.ts +3 -2
  302. package/src/server/lib/realtime/topics/peer-relay.server.test.ts +19 -3
  303. package/src/server/lib/updates/omp.test.ts +40 -1
  304. package/src/server/lib/updates/omp.ts +29 -2
  305. package/src/server/plugins/ssr.ts +2 -0
  306. package/src/server/routes/settings/mcp.test.ts +16 -0
  307. package/src/server/routes/settings/mcp.ts +4 -0
  308. package/src/shared/lib/code/outline/resize.test.ts +57 -0
  309. package/src/shared/lib/code/outline/resize.ts +67 -0
  310. package/src/shared/lib/models/provider/glyph.test.ts +3 -1
  311. package/src/shared/lib/models/provider/glyph.ts +1 -0
  312. package/src/shared/lib/omp/config/schema-releases-19-4.test.ts +103 -3
  313. package/src/shared/lib/omp/config/schema.test.ts +9 -0
  314. package/src/shared/lib/omp/config/schema.ts +8 -0
  315. package/src/shared/lib/settings/defaults.ts +2 -0
  316. package/src/shared/lib/theme/border-style.test.ts +12 -14
  317. package/src/shared/lib/theme/border-style.ts +25 -18
  318. package/src/shared/lib/theme/chrome-style.test.ts +31 -0
  319. package/src/shared/lib/theme/chrome-style.ts +74 -0
  320. package/src/shared/lib/theme/surface-style.test.ts +4 -5
  321. package/src/shared/lib/theme/surface-style.ts +6 -5
  322. package/src/shared/lib/ui/motion.ts +29 -0
  323. package/src/shared/lib/workspace/floating-chrome.ts +23 -0
  324. package/src/shared/lib/workspace/session-state/store.ts +3 -0
  325. package/src/shared/lib/workspace/workspace-panel-widths.test.ts +73 -0
  326. package/src/shared/lib/workspace/workspace-panel-widths.ts +79 -17
  327. package/src/shared/types/settings/state.ts +10 -9
  328. package/src/test-support/left-drawer-harness.test-util.ts +169 -0
  329. package/src/test-support/peer-harness.ts +44 -36
  330. package/dist/client/static/js/ImageView-pan9pqtm.js +0 -1
  331. package/dist/client/static/js/LayoutWrapper-p0qmghgt.js +0 -2
  332. package/dist/client/static/js/MergeDiffView-swt467g7.js +0 -1
  333. package/dist/client/static/js/Modal-4spmcn44.js +0 -60
  334. package/dist/client/static/js/SessionsView-b6szjdg5.js +0 -1
  335. package/dist/client/static/js/architecture-7GRP2DOG-bwn1drdz.js +0 -1
  336. package/dist/client/static/js/bash-zknkkwkw.js +0 -1
  337. package/dist/client/static/js/c-0w02jkxb.js +0 -1
  338. package/dist/client/static/js/cpp-p5b4vean.js +0 -1
  339. package/dist/client/static/js/css-9jzbvdyz.js +0 -1
  340. package/dist/client/static/js/cynefin-OW5HDTMX-jbc50ks8.js +0 -1
  341. package/dist/client/static/js/eventmodeling-NTZA5JFV-b37ey01t.js +0 -1
  342. package/dist/client/static/js/flowDiagram-KWPJA3E3-7c2ncsw7.js +0 -1
  343. package/dist/client/static/js/gitGraph-4MIJSDKK-mvqq7tcs.js +0 -1
  344. package/dist/client/static/js/graphql-xzykn0ba.js +0 -1
  345. package/dist/client/static/js/html-2zc3shky.js +0 -1
  346. package/dist/client/static/js/index-537m8a3x.js +0 -2
  347. package/dist/client/static/js/index-me0b6wkw.js +0 -1
  348. package/dist/client/static/js/index-mttx9327.css +0 -1
  349. package/dist/client/static/js/index-pe5f2gmn.js +0 -1
  350. package/dist/client/static/js/index-pzwf6hwe.js +0 -4
  351. package/dist/client/static/js/index-skvfxcd8.js +0 -1
  352. package/dist/client/static/js/index-sx2yz2wx.js +0 -1
  353. package/dist/client/static/js/index-wwyjzhgs.js +0 -2
  354. package/dist/client/static/js/index-y09de44h.js +0 -2
  355. package/dist/client/static/js/info-A6RAGUB7-zkv4crz7.js +0 -1
  356. package/dist/client/static/js/ini-62r3vxaf.js +0 -1
  357. package/dist/client/static/js/java-kacycary.js +0 -1
  358. package/dist/client/static/js/json-yrwpn6bd.js +0 -1
  359. package/dist/client/static/js/jsx-b40ag8q1.js +0 -1
  360. package/dist/client/static/js/lua-bk961f37.js +0 -1
  361. package/dist/client/static/js/markdown-b7rgzgd6.js +0 -1
  362. package/dist/client/static/js/one-dark-pro-vht9rv39.js +0 -1
  363. package/dist/client/static/js/one-light-arxc5whh.js +0 -1
  364. package/dist/client/static/js/packet-AYTQ26CC-dgpge627.js +0 -1
  365. package/dist/client/static/js/pie-WAS4IAKB-b8pgsqrd.js +0 -1
  366. package/dist/client/static/js/properties-k8gbzggp.js +0 -1
  367. package/dist/client/static/js/python-343tspad.js +0 -1
  368. package/dist/client/static/js/r-ycdwmv8g.js +0 -1
  369. package/dist/client/static/js/radar-RG4KPBEZ-fmfe5y27.js +0 -1
  370. package/dist/client/static/js/railroad-74A4TZTK-b5tks4ce.js +0 -1
  371. package/dist/client/static/js/railroad-abnf-HS5TGJTU-0sf4m0ze.js +0 -1
  372. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-pjfy3pt7.js +0 -1
  373. package/dist/client/static/js/railroad-peg-WCYAUIDC-nr8ngt42.js +0 -1
  374. package/dist/client/static/js/sql-kwpd5w07.js +0 -1
  375. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-xxmvdyg4.js +0 -8
  376. package/dist/client/static/js/treeView-Q6P3EWNA-23r9fa68.js +0 -1
  377. package/dist/client/static/js/treemap-WGGIJYW6-mxxzdrj6.js +0 -1
  378. package/dist/client/static/js/typescript-4dchbnya.js +0 -1
  379. package/dist/client/static/js/wardley-WFR3VGLG-cbqtax1x.js +0 -1
  380. package/dist/client/static/js/xml-xs6qz3ya.js +0 -1
  381. package/dist/client/static/js/yaml-174nk5bn.js +0 -1
  382. package/src/client/components/layout/desktop-layout/TopNavbar.tsx +0 -238
  383. package/src/client/components/layout/session-sidebar/Header.test.ts +0 -98
  384. package/src/client/components/layout/session-sidebar/Header.tsx +0 -60
@@ -1 +0,0 @@
1
- import{d,n,o,i,ce,e,Re,Ie,p,ft,f,C,le,gt,tt,yn,de,Ye,sr,L,S,U,h,At,bt,Me,ze,Ue,ff,Ir,Gc,jd,gf,Ao,st,ut,ga,Fl,Ze,Ns,ja,Yo,Jo,Zo,Qt,dr,Ms,Xo,ei,ti,vo,zl,Ul,Gl,jl}from"./index-eggbcdwx.js";import{Hs,Wa,Hr,Ku,Vu,ii,Yu,qs,xp,VA,YA,Ws,Ks,qr,Vs,Ys,si,Js,Zs,Xs,el,tl,Gi,li,nl,rl,Ju,Zu,Xu,ed,td,nd,rd}from"./index-pzwf6hwe.js";import{Ld,ls}from"./index-nnwcbp2d.js";var re="shrink-0 w-7 h-7 inline-flex items-center justify-center rounded border transition-colors cursor-pointer",ae="border-ink/15 bg-paper text-ink/70 hover:bg-ink/5 hover:text-ink",fe="border-ink/30 bg-ink/10 text-ink";function Ce({isSearchVisible:t,searchQuery:l,showArchived:c,optionsOpen:m,sortOption:T,onToggleSearch:N,onSearchChange:y,onToggleArchived:D,onHideArchived:O,onToggleOptions:_,onCloseOptions:A,onSortChange:v,onNewSession:z,onNewWorkspace:P,onScheduler:R,scheduledCount:k,onRefresh:x,refreshing:H,onSelectWorkspaces:V,selecting:W}){let{ref:E,width:B}=qs(VA),j=YA(B),r=new Set(xp.slice(0,j)),b=xp.slice(j),M=c?"Hide Archive":"Show Archive",u=k>0?`Scheduled tasks (${k} armed)`:"Scheduled tasks",w=[];if(b.includes("new-workspace"))w.push({id:"new-workspace",label:"New Workspace",icon:yn,onSelect:P});if(b.includes("refresh"))w.push({id:"refresh",label:"Refresh sessions",icon:S,onSelect:x});if(b.includes("search"))w.push({id:"search",label:"Search sessions",icon:U,onSelect:N,active:t});if(b.includes("archive"))w.push({id:"archive",label:M,icon:ft,onSelect:D,active:c});if(b.includes("select"))w.push({id:"select",label:W?"Cancel selection":"Select workspaces",icon:Hr,onSelect:V,active:W});if(b.includes("scheduler"))w.push({id:"scheduler",label:u,icon:Wa,onSelect:R});return e("div",{className:"p-3 border-b border-ink/10 flex flex-col space-y-3",children:[e("div",{ref:E,className:"flex items-center justify-between gap-2 px-1 text-ink/60",children:[e("div",{className:"flex flex-1 min-w-0 items-center gap-1.5",children:[e("button",{type:"button",title:"New Session","aria-label":"New Session",onClick:z,className:"flex-1 min-w-[52px] h-7 flex items-center justify-center space-x-1.5 px-2 rounded bg-ink text-canvas text-xs font-semibold hover:bg-ink/90 transition-colors cursor-pointer",children:[e(L,{size:14,className:"shrink-0"}),e("span",{className:"truncate",children:"New Session"})]}),r.has("new-workspace")&&e("button",{type:"button",title:"New Workspace","aria-label":"New Workspace",onClick:P,className:`${re} ${ae}`,children:e(yn,{size:14})}),r.has("scheduler")&&e("button",{type:"button",title:u,"aria-label":k>0?`Scheduled tasks, ${k} armed`:"Scheduled tasks",onClick:R,className:`relative ${re} ${ae}`,children:[e(Wa,{size:14}),k>0&&e("span",{className:"absolute -top-1 -right-1 min-w-[10px] h-[10px] px-[2px] rounded-full bg-ink text-canvas text-[7px] leading-[10px] text-center font-semibold",children:k>9?"9+":k})]}),r.has("refresh")&&e("button",{type:"button",title:"Refresh sessions",onClick:x,className:`${re} ${ae}`,"aria-label":"Refresh sessions","aria-busy":H,children:e(S,{size:14,className:H?"animate-spin":""})})]}),e("div",{className:"ml-auto flex items-center gap-1.5 shrink-0",children:[r.has("search")&&e("button",{type:"button",title:t?"Hide search":"Search sessions","aria-label":t?"Hide search":"Search sessions","aria-pressed":t,onClick:N,className:`${re} ${t?fe:ae}`,children:e(U,{size:14})}),r.has("select")&&e("button",{type:"button",title:W?"Cancel selection":"Select workspaces","aria-label":W?"Cancel selection":"Select workspaces","aria-pressed":W,onClick:V,className:`${re} ${W?fe:ae}`,children:e(Hr,{size:14})}),r.has("archive")&&e("button",{type:"button",title:M,"aria-label":M,"aria-pressed":c,onClick:D,className:`${re} ${c?fe:ae}`,children:e(ft,{size:14})}),r.has("sort")&&e("div",{className:"relative",children:[e("button",{type:"button",title:"Sort workspaces","aria-label":"Sort workspaces","aria-haspopup":"menu","aria-expanded":m,onClick:_,className:`${re} ${m||T!=="A-Z"?fe:ae}`,children:e(Hs,{size:14})}),m&&e("div",{className:"glass-popover absolute right-0 top-full mt-2 w-48 bg-paper border border-ink/15 rounded-lg shadow-lg z-50 py-1",onMouseLeave:A,children:e(ii,{variant:"desktop",sortOption:T,onSortChange:v})})]}),w.length>0&&e(Yu,{actions:w,sortHidden:b.includes("sort"),sortOption:T,onSortChange:v})]})]}),t&&e("div",{className:"pt-1",children:e("input",{type:"text",placeholder:"Search workspaces & sessions...",value:l,onChange:(K)=>y(K.currentTarget.value),autoFocus:!0,className:"w-full bg-ink/5 border border-ink/10 rounded px-2.5 py-1.5 outline-none focus:border-ink/30 text-xs text-ink placeholder-ink/40 transition-colors"})}),c&&e("div",{className:"flex items-center justify-between bg-warning/10 border border-warning/25 text-warning-text rounded px-2.5 py-1.5 text-[10px] font-medium",children:[e("div",{className:"flex items-center space-x-1.5",children:[e(ft,{size:10}),e("span",{children:"Showing Archived"})]}),e("button",{className:"hover:text-warning-text",onClick:O,children:e(h,{size:10})})]})]})}var Oe={inset:"px-2",insetPx:8,slotWidth:16,markGap:8,padding:"py-1.5",glyph:ut.compact};function Ae({sessionId:t,title:l,harness:c,isActive:m=!1,isArchived:T=!1,status:N,awaitingInput:y=!1,timeAgo:D,timeTitle:O,runStartedAt:_,onClick:A,onArchive:v,onDelete:z,onRename:P,onRenameWithAi:R,expandable:k=!1,isExpanded:x=!1,onToggleExpand:H,isChild:V=!1,folderId:W,waitingFor:E,onCancelWait:B,worktree:j,selectable:r=!1,selected:b=!1,onToggleSelect:M}){let u=ja(t),w=Boolean(k&&H),K=Boolean(E),G=w&&!(y||N==="stream"||K)&&!u,J=Boolean(u||y||N)&&!G,{isEditing:q,draft:F,setDraft:I,inputRef:ee,startRename:ne,handleKeyDown:te,handleBlur:Q}=Zo(l,P),Y=Xo(),se=Y.anchor!==null,ie=Boolean(P||v||z||B);return e(d,{children:[e("div",{"data-testid":"session-item","data-session-id":String(t),"data-selected":r&&b?"true":void 0,"data-menu-open":se?"true":void 0,onClick:q?void 0:r?M:A,onContextMenu:ie&&!q&&!r?Y.openAtCursor:void 0,className:`group/item relative flex items-center w-full rounded-lg px-2 py-1.5 cursor-pointer text-xs transition-colors select-none ${r&&b||se?Zs:m?"bg-ink/10 font-medium text-ink":"text-ink/75 hover:text-ink hover:bg-ink/5"}`,children:[r?e(d,{children:[e(qr,{checked:b,label:`Select ${l}`,onChange:()=>M?.()}),e("span",{className:"w-2 shrink-0"})]}):e(d,{children:[e("span",{className:"relative w-4 h-4 shrink-0",children:[w&&H&&e("button",{type:"button",onClick:(Z)=>{Z.stopPropagation(),H(Z)},title:x?"Collapse sessions and subagents":"Expand sessions and subagents","aria-expanded":x,className:`peer absolute inset-0 flex items-center justify-center rounded cursor-pointer transition-opacity ${G?"text-ink/60 hover:text-ink":"text-ink/40 hover:text-ink pointer-events-none opacity-0 group-hover/item:pointer-events-auto group-hover/item:opacity-100 focus-visible:opacity-100"}`,children:x?e(C,{size:13}):e(le,{size:13})}),J&&e("span",{className:`pointer-events-none absolute inset-0 flex items-center justify-center text-ink/60 transition-opacity ${w?"group-hover/item:opacity-0 peer-focus-visible:opacity-0":""}`,children:u?e("span",{role:"status","aria-label":"Generating a name…",children:e(p,{size:12,className:"animate-spin"})}):y?e(Re,{size:12,className:"animate-pulse text-ink/80"}):K?e("span",{role:"status","aria-label":`Waiting for ${E?.title??"another session"}`,children:e(Ye,{size:12,className:"animate-pulse text-ink/60"})}):N==="stream"?e("span",{role:"status","aria-label":"Running",children:e(p,{size:12,className:"animate-spin"})}):e(f,{size:12})}),V&&!w&&!J&&e("span",{"data-testid":"child-indicator","aria-hidden":"true",className:"pointer-events-none absolute inset-0 flex items-center justify-center text-ink/35",children:e(de,{size:12,"aria-hidden":"true"})})]}),e("span",{className:"w-2 shrink-0"})]}),c&&e("span",{className:"mr-1.5 flex shrink-0 items-center",children:e(st,{harness:c,size:ut.compact})}),q?e("input",{ref:ee,autoFocus:!0,value:F,onChange:(Z)=>I(Z.currentTarget.value),onClick:(Z)=>Z.stopPropagation(),onKeyDown:te,onBlur:Q,className:"flex-1 min-w-0 bg-paper border border-ink/25 rounded px-1 py-0.5 text-xs text-ink outline-none focus:border-ink/50"}):e("span",{className:"flex-1 min-w-0 flex flex-col leading-snug",children:[e("span",{className:"min-w-0 truncate",children:l.charAt(0).toUpperCase()+l.slice(1)}),K&&e("span",{className:"truncate text-[10px] text-ink/40 font-normal",children:["waiting for ",E?.title??"another session"]}),j&&!q&&e(Vs,{worktree:j})]}),!q&&e(Js,{timeAgo:D,timeTitle:O,runStartedAt:_,className:"shrink-0 ml-2 font-mono text-[10px]"}),!q&&ie&&!r&&e("button",{type:"button",onClick:Y.openBelow,title:"Session actions","aria-label":"Session actions","aria-haspopup":"menu","aria-expanded":se,className:"shrink-0 ml-1 p-1 text-ink/40 hover:text-ink hover:bg-ink/10 rounded cursor-pointer",children:e(Ie,{size:14})})]}),Y.anchor&&e(ei,{anchor:Y.anchor,sessionId:t,...c?{harness:c}:{},...W!==void 0?{folderId:W}:{},isArchived:T,onRename:P?ne:void 0,onRenameWithAi:R,onArchive:v,onDelete:z,onCancelWait:B,onClose:Y.close})]})}function Pe({folder:t,isOpen:l,onToggleFolder:c,checkbox:m,batchActive:T,showMenu:N,onToggleMenu:y,onCloseMenu:D,onNewSession:O,onOpenWorkspacePanels:_,workspaceActive:A=!1,onNewWorktreeSession:v,onOpenFolder:z,onSelectSessions:P,confirmDelete:R,onPin:k,onDelete:x,onRequestDelete:H,onCancelDelete:V}){let W=ga(t.icon),[E,B]=n(!1),j=Boolean(v&&t.project_path),r=i(null),[b,M]=n(null);return e("div",{className:"group flex items-center justify-between h-7 text-xs font-semibold text-ink px-2 hover:bg-ink/5 rounded-md transition-colors select-none",children:[e("div",{className:"flex-1 h-full flex items-center cursor-pointer min-w-0",onClick:T?void 0:c,children:[m?e(d,{children:[e(qr,{size:"md",checked:m.checked,indeterminate:m.indeterminate,label:m.label,onChange:m.onChange}),e("span",{className:"w-2 shrink-0"})]}):e(d,{children:[e("span",{className:"relative w-4 h-4 flex items-center justify-center shrink-0",children:[e("span",{className:"absolute inset-0 flex items-center justify-center transition-opacity group-hover:opacity-0 touch-hidden",children:t.customIconUrl?e("img",{src:t.customIconUrl,alt:"",className:"w-[15px] h-[15px] rounded-xs object-contain shrink-0",referrerPolicy:"no-referrer"}):e(W,{size:15,className:"project-accent-mark text-ink/75",style:Fl(t.accentColor)})}),e("span",{className:"absolute inset-0 flex items-center justify-center text-ink/60 opacity-0 transition-opacity group-hover:opacity-100 touch-visible",children:l?e(C,{size:13}):e(le,{size:13})})]}),e("span",{className:"w-2 shrink-0"})]}),t.isPinned&&e(sr,{size:11,className:"text-ink/60 shrink-0 mr-1.5"}),e("span",{className:"truncate text-[13px] font-semibold tracking-tight",children:t.name})]}),!T&&e("div",{className:"flex items-center space-x-0.5 pl-1",children:[e("button",{type:"button",title:`Workspace panels for ${t.name}`,"aria-label":`Open workspace panels for ${t.name}`,"aria-pressed":A,className:`w-5 h-5 flex items-center justify-center rounded cursor-pointer transition-colors ${A?el:"text-ink/40 hover:text-ink hover:bg-ink/10"}`,onClick:(u)=>{u.stopPropagation(),_()},children:e(tt,{size:12})}),e("button",{type:"button",title:"New Session","aria-label":`New session in ${t.name}`,className:"w-5 h-5 flex items-center justify-center text-ink/40 hover:text-ink hover:bg-ink/10 rounded cursor-pointer transition-colors",onClick:(u)=>{u.stopPropagation(),O()},children:e(L,{size:12})}),e("div",{className:"relative flex items-center",children:[e("button",{ref:r,type:"button",title:`Options for ${t.name}`,"aria-label":`Options for ${t.name}`,"aria-haspopup":"menu","aria-expanded":N,className:"w-5 h-5 flex items-center justify-center text-ink/40 hover:text-ink hover:bg-ink/10 rounded cursor-pointer transition-colors",onClick:(u)=>{if(u.stopPropagation(),r.current)M(Me(r.current));y()},children:e(Ie,{size:12})}),e(ze,{anchor:N?b:null,align:"end",ariaLabel:`Options for ${t.name}`,className:"glass-popover w-44 rounded-md border border-ink/15 bg-paper py-1 text-xs shadow-lg",onClose:D,children:e(Xs,{variant:"desktop",isPinned:t.isPinned,onOpenFolder:z,onSelectSessions:P,onNewWorktree:j?()=>{y(),B(!0)}:void 0,confirmDelete:R,onPin:k,onDelete:x,onRequestDelete:H,onCancelDelete:V})})]})]}),j&&e(ti,{isOpen:E,onClose:()=>B(!1),root:t.project_path??null,folderId:t.id,folderName:t.name,onCreated:(u)=>{B(!1),v?.(t.id,u.path)}})]})}function We({folder:t,activeSessionId:l,onSelectSession:c,onNewSessionForFolder:m,onOpenWorkspacePanels:T,onNewWorktreeSession:N,forceExpanded:y=!1,showArchived:D=!1,sessionStatus:O={},onToast:_,batch:A,onStartSessionSelection:v,onCancelWait:z}){let[P,R]=n(t.isExpanded||!1),[k,x]=n(!1),{visibleCount:H,showMore:V,showLess:W,canShowLess:E}=ls(),[B]=ce(),j=B.get("subagent"),r=B.get("sessionId"),{expandedSessionIds:b,toggleSession:M}=Ms();o(()=>{if(typeof t.isExpanded==="boolean")R(t.isExpanded)},[t.isExpanded]);let{refresh:u,runStartedAtMap:w}=Ze(),K=bt(),{confirmDelete:pe,requestDelete:G,cancelDelete:J,handlePin:q,handleDelete:F,handleArchive:I,handleRename:ee,handleRenameWithAi:ne,handleOpenFolder:te}=Ks(t,u,_),Q=Yo(),Y=()=>{x(!1),J()},se=t.sessions,ie=()=>{let s=!P;if(R(s),typeof t.id!=="number")return;K.submit({isExpanded:String(s)},{method:"POST",action:`/api/folders/${t.id}/toggle`})},Z=()=>{q(),x(!1)},Se=()=>{F(),x(!1)},be=te?()=>{te(),x(!1)}:void 0,he=y||P,ue=(se||[]).filter((s)=>D?s.is_archived===1:s.is_archived!==1),{folderCheckbox:a,sessionCheckboxes:g,folderSummary:oe,toggleFolderSelection:ge,rendered:Ee,hiddenCount:xe}=nl({batch:A,folder:t,sessions:ue,showArchived:D,visibleCount:H,activeSessionId:l,sessionStatus:O}),ve=li(Ee),Be=he||g,we=xe>0,Ne=(s,me)=>{let X=String(s.id),ye=l!==null?String(l)===X:s.is_active===1,Le=ye&&r===X&&Boolean(j),ke=Qt(X);return e(Ae,{sessionId:s.id,title:s.title,harness:s.harness,folderId:s.folder_id,isActive:ye&&!Le,isArchived:s.is_archived===1,status:O[X],awaitingInput:Boolean(s.awaitingInput),worktree:s.worktree,timeAgo:Ys(s.updated_at??s.created_at),timeTitle:si(s.updated_at??s.created_at),runStartedAt:O[X]==="stream"?w[X]:void 0,onClick:()=>c(s.id),onArchive:()=>I(s),onDelete:ke?void 0:()=>Q.requestDelete(s),onRename:ke?void 0:($e)=>void ee(s,$e),onRenameWithAi:ke?void 0:()=>void ne(s),expandable:me.expandable,isChild:me.isChild,isExpanded:me.isExpanded,onToggleExpand:me.onToggleExpand,waitingFor:s.waitingFor?{title:s.waitingFor.title}:void 0,onCancelWait:s.waitingFor?()=>z?.(s.waitingFor.waitId):void 0,selectable:g,selected:Boolean(A?.selected.includes(X)),onToggleSelect:A?()=>A.toggle(X):void 0})},_e=(s)=>tl(s,ve.childrenOf,b,M);return e("div",{className:"space-y-1",children:[e(Pe,{folder:t,isOpen:he,onToggleFolder:ie,checkbox:a&&oe?{checked:oe.all,indeterminate:oe.some,label:`Select ${t.name}`,onChange:ge}:null,batchActive:Boolean(A),showMenu:k,onToggleMenu:()=>x(!k),onCloseMenu:Y,onNewSession:()=>m(t.id),onOpenWorkspacePanels:()=>T(t.id),workspaceActive:String(l)===Ir(t.id),onNewWorktreeSession:N,onOpenFolder:be,onSelectSessions:v?()=>{x(!1),v(t.id)}:void 0,confirmDelete:pe,onPin:Z,onDelete:Se,onRequestDelete:G,onCancelDelete:J}),Be&&e("div",{className:"space-y-0.5",children:[ve.roots.map((s)=>{let me=String(s.id),X=_e(s);return e("div",{className:"space-y-0.5",children:[Ne(s,X),X.isExpanded&&e(Gi,{parentId:me,hasSubagents:Boolean(s.hasSubagents),childrenOf:ve.childrenOf,expandedIds:b,onToggle:M,activeSessionId:l===null?null:String(l),renderSession:Ne,style:Oe})]},s.id)}),(we||E)&&!g&&e("div",{className:"flex items-center gap-1",children:[we&&e("button",{type:"button",onClick:V,className:"flex items-center min-w-0 text-xs text-ink/45 hover:text-ink/80 py-1.5 px-2 rounded-lg hover:bg-ink/5 transition-colors cursor-pointer select-none",children:[e("span",{className:"w-4 h-4 shrink-0 flex items-center justify-center",children:e(C,{size:12})}),e("span",{className:"w-2 shrink-0"}),e("span",{className:"truncate leading-snug",children:["Show more sessions (",xe,")"]})]}),E&&e("button",{type:"button",onClick:W,className:"ml-auto shrink-0 flex items-center gap-1 text-xs text-ink/45 hover:text-ink/80 py-1.5 px-2 rounded-lg hover:bg-ink/5 transition-colors cursor-pointer select-none",children:[e(gt,{size:12}),e("span",{className:"truncate leading-snug",children:"Show less"})]})]}),ue.length===0&&e("div",{className:"px-3 py-2 text-[11px] text-ink/40 italic",children:D?"No archived sessions.":"No sessions."})]}),e(Jo,{session:Q.pending,isDeleting:Q.isDeleting,error:Q.error,onClose:Q.cancelDelete,onConfirm:()=>void Q.confirmDelete()})]})}function Te({folders:t,activeSessionId:l,searchQuery:c,showArchived:m,harnessFilter:T,sessionStatus:N,onSelectSession:y,onNewSessionForFolder:D,onOpenWorkspacePanels:O,onNewWorktreeSession:_,onToast:A,batch:v,onStartSessionSelection:z,onCancelWait:P}){return e("div",{className:"flex-1 scrollbar-overlay-container p-2 space-y-4",children:t.length===0?e("div",{className:"text-center py-8 text-xs text-muted",children:c?"No results found.":T?`No chats on ${Ao(T)}.`:"No workspaces available."}):t.map((R)=>e(We,{folder:R,activeSessionId:l,onSelectSession:y,onNewSessionForFolder:D,onOpenWorkspacePanels:O,onNewWorktreeSession:_,forceExpanded:c.trim().length>0,showArchived:m,sessionStatus:N,onToast:A,batch:v,onStartSessionSelection:z,onCancelWait:P},R.id))})}var He=[3,2];function De(){return e("div",{className:"flex-1 p-2 space-y-4","aria-hidden":"true",children:He.map((t,l)=>e("div",{className:"space-y-1.5",children:[e("div",{className:"flex items-center gap-2 px-1 py-1.5",children:[e("span",{className:"w-3.5 h-3.5 rounded-sm animate-pulse bg-ink/10"}),e("span",{className:"h-3 w-24 rounded animate-pulse bg-ink/10"})]}),Array.from({length:t},(c,m)=>e("div",{className:"flex items-center gap-2 rounded px-2 py-1.5",children:[e("span",{className:"w-4 h-4 rounded-full animate-pulse bg-ink/10"}),e("span",{className:"h-3 rounded animate-pulse bg-ink/10",style:{width:`${58-m%3*12}%`}})]},m))]},l))})}function Fe({className:t="",folders:l,initializing:c,failed:m,activeSessionId:T,sessionStatus:N,searchQuery:y,onSearchChange:D,showArchived:O,onToggleArchived:_,sortOption:A,optionsOpen:v,onToggleOptions:z,onCloseOptions:P,onSortChange:R,harnessFilter:k,onHarnessFilterChange:x,harnessOptions:H,onRefresh:V,refreshing:W,scheduledCount:E,onNewSession:B,onNewWorkspace:j,onScheduler:r,onSelectSession:b,onNewSessionForFolder:M,onOpenWorkspacePanels:u,onNewWorktreeSession:w,onToast:K,onCancelWait:pe,batch:G,onSelectWorkspaces:J,onStartSessionSelection:q}){let[F,I]=n(!1),ee=F||y.length>0,ne=Boolean(G);return e("div",{className:`flex flex-col ${t}`,children:[e(Ce,{isSearchVisible:ee,searchQuery:y,showArchived:O,optionsOpen:v,sortOption:A,onToggleSearch:()=>{if(ee)I(!1),D("");else I(!0)},onSearchChange:D,onToggleArchived:_,onHideArchived:_,onToggleOptions:z,onCloseOptions:P,onSortChange:R,onNewSession:B,onNewWorkspace:j,onScheduler:r,scheduledCount:E,onRefresh:V,refreshing:W,onSelectWorkspaces:J,selecting:ne}),e("div",{className:"px-3 pt-2 pb-1",children:e(Ws,{options:H,value:k,onChange:x})}),m?e(rl,{onRetry:V,refreshing:W}):c?e(De,{}):e(Te,{folders:l,activeSessionId:T,searchQuery:y,showArchived:O,harnessFilter:k,sessionStatus:N,onSelectSession:b,onNewSessionForFolder:M,onOpenWorkspacePanels:u,onNewWorktreeSession:w,onToast:K,batch:G,onStartSessionSelection:q,onCancelWait:pe})]})}function In({className:t="",appSettings:l={}}){let{folders:c,initializing:m,failed:T,refreshNow:N,isRefreshing:y,activeSessionId:D,sessionParam:O,searchQuery:_,setSearchQuery:A,showArchived:v,setShowArchived:z,optionsOpen:P,setOptionsOpen:R,sortOption:k,handleSortChange:x,harnessFilter:H,setHarnessFilter:V,harnessOptions:W,processedFolders:E,sessionStatus:B,handleSelectSession:j}=Zu(l,{expandSearchMatches:!0}),[,r]=ce(),b=Ld(),[M,u]=n(!1),[w,K]=n(!1),pe=Ku(),{pushToast:G}=Ue(),J=Ul(G);Xu({onNotice:G});let q=td(E,v,N),{selection:F,deleteRun:I,archiveRun:ee,binding:ne,scopeFolder:te,available:Q,selected:Y}=q,se=()=>{ee.archive(Y).then((a)=>{if(!a)return;let g=ed(a);if(g)G(g.message,g.tone);if(!a.error)F.end()})},ie=(a)=>{let g=zl(c,O,a);if(g)vo(g)},Z=()=>{gf({replace:!0})},Se=(a,g)=>{ie(a);let oe=dr(a);At(oe,"chat.spawnTarget",{folderId:a,worktreePath:g}),r((ge)=>Gc(ge,oe,a),{replace:!0})},be=(a)=>{ie(a),r((g)=>Gc(g,dr(a),a),{replace:!0})},he=(a)=>{let g=Ir(a);At(g,"layout.showRightPanel",!0),At(g,"layout.rightSideHidden",!1),r((oe)=>jd(oe,a),{replace:!0}),window.dispatchEvent(new CustomEvent(ff,{detail:{folderId:String(a)}}))},ue={className:`flex-1 min-h-0 w-full ${t}`,folders:E,initializing:m,failed:T,activeSessionId:D,sessionStatus:B,searchQuery:_,onSearchChange:A,showArchived:v,onToggleArchived:()=>z(!v),sortOption:k,optionsOpen:P,onToggleOptions:()=>R(!P),onCloseOptions:()=>R(!1),onSortChange:x,harnessFilter:H,onHarnessFilterChange:V,harnessOptions:W,onRefresh:N,refreshing:y,scheduledCount:pe,onNewSession:Z,onNewWorkspace:()=>u(!0),onScheduler:()=>K(!0),onSelectSession:j,onNewSessionForFolder:be,onOpenWorkspacePanels:he,onNewWorktreeSession:Se,onToast:G,onCancelWait:J,batch:ne,onSelectWorkspaces:q.toggleWorkspaceSelection,onStartSessionSelection:(a)=>F.begin("session",a)};return e(d,{children:[e("div",{className:"flex flex-col h-full",children:[b==="modern"?e(Ju,{...ue}):e(Fe,{...ue}),F.mode&&e(nd,{mode:F.mode,count:Y.length,total:Q.length,busy:I.isDeleting,archiving:ee.isArchiving,scopeLabel:te?.name,onSelectAll:()=>F.selectAllOf(Q),onUnselectAll:()=>F.unselectAllOf(Q),onDelete:()=>I.request(Y),onArchive:se,onCancel:F.end})]}),e(rd,{mode:F.mode??"session",count:I.pending.length,scopeLabel:te?.name,isDeleting:I.isDeleting,progress:I.progress,outcome:I.outcome,onClose:()=>{let a=I.outcome?.refused.length??0;if(I.cancel(),I.outcome&&a===0)F.end()},onConfirm:()=>{let a=F.mode??"session";I.confirm(a).then((g)=>{if(g&&g.refused.length===0)F.end()})}}),e(Ns,{isOpen:M,onClose:()=>u(!1),onCreate:Gl,onClone:jl}),e(Vu,{isOpen:w,onClose:()=>K(!1),activeSessionId:typeof O==="string"?O:null,onToast:G})]})}export{In as SessionsView};
@@ -1 +0,0 @@
1
- import{Ug}from"./index-nf4hq5tg.js";export{Ug as createArchitectureServices};
@@ -1 +0,0 @@
1
- import{Mm}from"./index-d9sfavx1.js";export{Mm as default};
@@ -1 +0,0 @@
1
- import{bi}from"./index-8tzt0dek.js";export{bi as default};
@@ -1 +0,0 @@
1
- import{Qc}from"./index-58z2hatp.js";import"./index-8tzt0dek.js";export{Qc as default};
@@ -1 +0,0 @@
1
- import{fp,Gs,Tb,Db,Nb,Qb}from"./index-np2rfq06.js";export{Tb as css,Qb as gss,Gs as keywords,Nb as less,fp as mkCSS,Db as sCSS};
@@ -1 +0,0 @@
1
- import{Mg}from"./index-nf4hq5tg.js";export{Mg as createCynefinServices};
@@ -1 +0,0 @@
1
- import{Gg}from"./index-nf4hq5tg.js";export{Gg as createEventModelingServices};
@@ -1 +0,0 @@
1
- import"./index-60cxxnpk.js";import"./index-rw84kefb.js";import{Sb}from"./index-njhrm5qa.js";export{Sb as diagram};
@@ -1 +0,0 @@
1
- import{Fg}from"./index-nf4hq5tg.js";export{Fg as createGitGraphServices};
@@ -1 +0,0 @@
1
- import{uA}from"./index-db6s66jr.js";import"./index-yrwm437g.js";import"./index-3j2he86h.js";import"./index-a3bpmw2r.js";import"./index-92h38pwg.js";export{uA as default};
@@ -1 +0,0 @@
1
- import{qn}from"./index-sg65xdey.js";import"./index-a3bpmw2r.js";import"./index-10vzyga1.js";export{qn as default};
@@ -1,2 +0,0 @@
1
- import{d,n,o,i,u,a,e,s,p,B,ia,us,f,ae,tt,de,S,U,$o,jm,X,Tt,yA,Vm,Od}from"./index-eggbcdwx.js";var I={name:"folder-git-2",size:24,node:[["path",{d:"M18 19a5 5 0 0 1-5-5v8",key:"sz5oeg"}],["path",{d:"M9 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v5",key:"1w6njk"}],["circle",{cx:"13",cy:"12",r:"2",key:"1j92g6"}],["circle",{cx:"20",cy:"19",r:"2",key:"1obnsp"}]]},Lm=s(I);function O({row:t,active:r,name:l,loading:h,onSelect:c,onCopyPath:g,onReveal:N}){return e("div",{className:"grid grid-cols-[1rem_minmax(0,1fr)_3.5rem] items-start gap-x-2 px-4 py-2 border-b border-ink/5 last:border-b-0 hover:bg-ink/[0.02] group/row transition-colors",children:[e("div",{className:"h-5 flex items-center justify-center",children:r&&e(f,{size:12,className:"text-ink","aria-label":"Selected repository"})}),e("button",{type:"button",onClick:c,disabled:r||!t.isRepo,title:!t.isRepo?t.error??"Not a git repository":r?"Already showing this repository":`Show ${t.path}`,className:"min-w-0 text-left cursor-pointer disabled:cursor-default",children:e("div",{className:"h-5 flex items-center gap-1.5 min-w-0",children:[e(de,{size:11,className:r?"text-ink/60 flex-shrink-0":"text-ink/40 flex-shrink-0"}),e("span",{className:`truncate text-xs ${r?"font-semibold text-ink":"text-ink/90"}`,children:l})]})}),e("div",{className:"h-5 flex items-center justify-end gap-0.5 touch-visible opacity-0 group-hover/row:opacity-100",children:[e("button",{type:"button",onClick:g,disabled:h,title:`Copy the absolute path of ${t.path}`,"aria-label":`Copy path of ${t.path}`,className:"w-5 h-5 flex items-center justify-center rounded text-ink/40 hover:text-ink hover:bg-ink/10 cursor-pointer transition-colors disabled:opacity-30 disabled:cursor-default",children:e(ae,{size:11})}),e("button",{type:"button",onClick:N,title:`Reveal ${t.path} in the file manager`,"aria-label":`Reveal ${t.path}`,className:"w-5 h-5 flex items-center justify-center rounded text-ink/40 hover:text-ink hover:bg-ink/10 cursor-pointer transition-colors",children:e(tt,{size:11})})]}),e("div",{className:"col-start-2 col-span-2 flex flex-wrap items-center gap-x-2 gap-y-0.5 min-w-0 mt-0.5",children:[t.isRepo?e(d,{children:[e("span",{className:`text-[10px] font-mono truncate ${t.detached?"text-warning-text":"text-ink/50"}`,title:t.detached?`Detached HEAD at ${t.branch}`:`On branch ${t.branch}`,children:t.branch}),e("span",{className:"text-[10px] text-ink/25","aria-hidden":!0,children:"·"}),e(Q,{row:t})]}):e("span",{className:"text-[10px] text-ink/40 truncate",children:t.error??"Not a git repository"}),t.isRepo&&t.subject&&e(d,{children:[e("span",{className:"text-[10px] text-ink/25","aria-hidden":!0,children:"·"}),e("span",{className:"text-[10px] text-ink/40 truncate min-w-0",title:t.subject,children:t.subject})]})]})]})}function Q({row:t}){let r=[];if(t.operation)r.push(e("span",{className:"flex flex-shrink-0 items-center gap-0.5 rounded border border-warning/30 px-1 text-[10px] font-mono text-warning-text",title:t.operation==="stash-pop"?`A stash pop stopped on ${t.conflicts} conflict(s)`:`A ${$o[t.operation]} is in progress, stopped on ${t.conflicts} conflict(s)`,children:[e(B,{size:9}),$o[t.operation]]},"operation"));else if(t.conflicts>0)r.push(e("span",{className:"flex flex-shrink-0 items-center gap-0.5 rounded border border-warning/30 px-1 text-[10px] font-mono text-warning-text",title:`${t.conflicts} conflicted path(s)`,children:[e(B,{size:9}),t.conflicts]},"conflicts"));if(t.changed>0||t.untracked>0)r.push(e("span",{className:"flex-shrink-0 rounded border border-info/30 px-1 text-[10px] font-mono tabular-nums text-info-text",title:`${t.changed} changed, ${t.untracked} untracked`,children:[t.changed>0?`${t.changed}±`:"",t.changed>0&&t.untracked>0?" ":"",t.untracked>0?`${t.untracked}?`:""]},"dirty"));if(t.gone)r.push(e("span",{className:"flex-shrink-0 rounded border border-warning/30 px-1 text-[10px] font-mono text-warning-text",title:`${t.upstream} no longer exists on the remote — fetch --prune to drop it`,children:"gone"},"gone"));else if(t.upstream&&(t.ahead>0||t.behind>0))r.push(e("span",{className:"flex flex-shrink-0 items-center gap-0.5 text-[10px] font-mono tabular-nums text-ink/60",title:`${t.ahead} ahead of, ${t.behind} behind ${t.upstream}`,children:[t.ahead>0&&e("span",{className:"flex items-center",children:[e(us,{size:9}),t.ahead]}),t.behind>0&&e("span",{className:"flex items-center",children:[e(ia,{size:9}),t.behind]})]},"track"));if(r.length===0)return e("span",{className:"text-[10px] font-mono text-ink/30",title:"Nothing to report: clean and in sync",children:"clean, in sync"});return e(d,{children:r})}function H(t){let{open:r,rootPath:l,scanning:h}=t,[c,g]=n([]),[N,k]=n(!1),[C,A]=n(!1),[z,y]=n(null),[D,E]=n(0),j=t.repos.join("\x00"),G=i(!0),b=i(null);o(()=>(G.current=!0,()=>{G.current=!1,b.current?.abort(),b.current=null}),[]);let M=a(async()=>{b.current?.abort();let v=new AbortController;b.current=v,A(!0),k(!0);try{let R=new URLSearchParams({repoDetails:"1"});if(l)R.set("root",l);let w=await fetch(`/api/fs/git?${R.toString()}`,{signal:v.signal}),F=await w.json();if(!G.current||b.current!==v)return;if(!w.ok||!Array.isArray(F.details)){y(F.error||`Failed to read repositories (HTTP ${w.status})`);return}g(F.details),y(null)}catch(R){if(!G.current||b.current!==v)return;if(R instanceof Error&&R.name==="AbortError")return;y(R instanceof Error?R.message:"Failed to read repositories")}finally{if(G.current&&b.current===v)b.current=null,A(!1),k(!1)}},[l]);o(()=>{if(!r){g([]),y(null),k(!1);return}M()},[r,M,j,h,D]);let L=a(()=>E((v)=>v+1),[]);return{details:c,loading:N,reading:C,error:z,refresh:L}}function _(t){let r=new Map;for(let l of t){if(!l||l==="."){if(!r.has(""))r.set("",{key:"",label:null,paths:[]});r.get("").paths.push(".");continue}let h=l.indexOf("/"),c=h===-1?"":l.slice(0,h),g=r.get(c);if(!g)g={key:c,label:c===""?null:c,paths:[]},r.set(c,g);g.paths.push(l)}for(let l of r.values())l.paths.sort((h,c)=>h==="."?-1:c==="."?1:h.localeCompare(c));return[...r.values()].sort((l,h)=>{if(l.key==="")return-1;if(h.key==="")return 1;return l.key.localeCompare(h.key)})}function W(t,r){if(t===".")return"workspace root";if(r==="")return t;return t.slice(r.length+1)}function q({isOpen:t,rootPath:r,activeRepo:l,repos:h,scanning:c,onSelectRepo:g,onRefreshRepos:N,onClose:k}){let[C,A]=n(""),[z,y]=n(null),{details:D,loading:E,reading:j,error:G,refresh:b}=H({open:t,rootPath:r,repos:h,scanning:c});o(()=>{if(!t)A(""),y(null)},[t]);let M=u(()=>{let x=C.trim().toLowerCase();if(!x)return D;return D.filter((m)=>m.path.toLowerCase().includes(x))},[D,C]),L=u(()=>_(M.map((x)=>x.path)),[M]),v=u(()=>{let x=new Map;for(let m of D)x.set(m.path,m);return x},[D]),R=a(()=>{N(),b()},[N,b]),w=a(async(x)=>{let m=r?Od(r,x==="."?"":x):x,P=await Tt(m);y(P?{text:`Copied ${m}`,kind:"success"}:{text:"Clipboard unavailable",kind:"error"})},[r]),F=a(async(x)=>{let m=new FormData;if(m.append("actionType","open_explorer"),m.append("path","."),m.append("repo",x),r)m.append("root",r);try{let P=await fetch("/api/fs/action",{method:"POST",body:m}),T=await P.json();if(!P.ok||T.error)y({text:T.error||"Could not open the file manager",kind:"error"})}catch{y({text:"Could not open the file manager",kind:"error"})}},[r]);if(!t)return null;return e(X,{onClose:k,maxWidthClass:"max-w-[min(96vw,720px)]",header:e("div",{className:"flex items-center gap-2 min-w-0",children:[e(Lm,{size:14,className:"text-ink/60 flex-shrink-0"}),e("h2",{className:"text-sm font-semibold text-ink",children:"Repositories"}),e("span",{className:"text-[10px] font-mono text-ink/50 truncate",children:[h.length," in this workspace"]})]}),children:[e("div",{className:"px-5 py-3 flex items-center gap-2 border-b border-ink/10",children:[e(U,{size:12,className:"text-ink/40 flex-shrink-0"}),e("input",{type:"text",value:C,onChange:(x)=>A(x.currentTarget.value),placeholder:"Filter repositories…","aria-label":"Filter repositories",className:"flex-1 min-w-0 bg-transparent outline-none text-xs text-ink placeholder-ink/40",autoFocus:!0}),e("button",{type:"button",onClick:R,disabled:j||c,title:"Re-discover repositories and re-read their state","aria-label":"Refresh repositories",className:"text-ink/40 hover:text-ink transition-colors cursor-pointer disabled:opacity-40 flex-shrink-0",children:e(S,{size:12,className:j||c?"animate-spin":""})})]}),c&&e("div",{className:"px-5 py-1.5 border-b border-ink/10 text-[10px] font-mono text-ink/50 flex items-center gap-1.5",children:[e(p,{size:10,className:"animate-spin"}),"Still discovering repositories in this workspace…"]}),z&&e("div",{className:`px-5 py-1.5 border-b border-ink/10 text-[10px] font-mono truncate ${z.kind==="error"?"text-error-text":"text-ink/60"}`,title:z.text,role:"status",children:z.text}),e("div",{className:"min-h-[40vh] max-h-[60vh] overflow-y-auto scrollbar-overlay-container",children:E&&D.length===0?e("div",{className:"flex items-center justify-center gap-2 py-12 text-xs text-ink/50 font-mono",children:[e(p,{size:14,className:"animate-spin text-info-text"}),"Reading repositories…"]}):G?e("div",{className:"py-12 px-6 text-center text-xs text-error-text font-mono",children:G}):M.length===0?e("div",{className:"py-12 text-center text-xs text-ink/40 font-mono",children:C.trim()?"No matching repositories.":"No repositories in this workspace."}):L.map((x)=>e("div",{children:[e("div",{className:"px-4 py-1 text-[10px] uppercase tracking-wider text-ink/40 font-semibold bg-canvas/40 border-b border-ink/5 sticky top-0",children:x.label??yA(".",r)}),x.paths.map((m)=>{let P=v.get(m);if(!P)return null;return e(O,{row:P,active:m===l,name:W(m,x.key),loading:j,onSelect:()=>{g(m),k()},onCopyPath:()=>void w(m),onReveal:()=>void F(m)},m)})]},x.key))})]})}function Qr({rootPath:t,activeRepo:r,onSelectRepo:l,repos:h,scanning:c,onRefreshRepos:g}){let[N,k]=n(!1),C=u(()=>({root:t??null,repo:r,rows:Vm(t,h),scanning:c,ready:!0,setRepo:l,refresh:g}),[t,r,h,c,l,g]),A=a(()=>k(!0),[]);return e("div",{className:"relative min-w-0",children:[e(jm,{scope:C,onManage:A}),e(q,{isOpen:N,rootPath:t,activeRepo:r,repos:h,scanning:c,onSelectRepo:l,onRefreshRepos:g,onClose:()=>k(!1)})]})}
2
- export{Lm,Qr};
@@ -1 +0,0 @@
1
- import{d,n,o,K,i,u,a,un,e,Ie,ds,f,ps,ms,fs,U,As,h,T,wr,Cr,Bt,uo,$e,Ti,Tl,ht,bt,yt,zd,Fc}from"./index-eggbcdwx.js";import{Qr}from"./index-537m8a3x.js";var fe=2000,W=new Map;function me(s){if(s.length===0)return"";let r="";for(let t of s)r+=`${t.start}-${t.end},`;return r}function ee(s,r,t){let c=Ti(r),m=`${r}\x00${me(t)}\x00${s}`;if(c){let S=W.get(m);if(S!==void 0)return W.delete(m),W.set(m,S),S}let l=Tl(s,r,{marks:t});if(!c)return l;if(W.set(m,l),W.size>fe){let S=W.keys().next();if(!S.done)W.delete(S.value)}return l}function te(s,r,t){let c=[],m=0;for(let l of r){if(l.start<m||l.end<=l.start||l.end>s.length)continue;if(l.start>m)c.push({text:s.slice(m,l.start),kind:"plain"});if(c.push({text:s.slice(l.start,l.end),kind:"removed"}),t)c.push({text:t,kind:"inserted"});m=l.end}if(m<s.length)c.push({text:s.slice(m),kind:"plain"});return c}function ge({file:s,result:r,replacement:t,showReplacePreview:c,onOpen:m}){let l=r.ranges??[],S=c&&t.length>0;return e("button",{type:"button",onClick:()=>m(r),className:"flex w-full items-start gap-2 rounded px-1 py-0.5 text-left hover:bg-ink/5 cursor-pointer",title:`Open ${s}:${r.line}`,children:[e("span",{className:"w-6 flex-shrink-0 text-right font-mono text-ink/40",children:r.line}),S?e("span",{className:"min-w-0 truncate font-mono text-ink",children:te(r.content,l,t).map((k,b)=>k.kind==="plain"?e("span",{children:k.text},b):k.kind==="removed"?e("del",{className:"search-replace-old",children:k.text},b):e("ins",{className:"search-replace-new",children:k.text},b))}):e("span",{className:"min-w-0 truncate font-mono text-ink",dangerouslySetInnerHTML:{__html:ee(r.content,yt(s),l)}})]})}var re=un(ge);var Z={header:4,hit:4,group:16},ne={headerBox:16,hitBox:20},se=5000;function oe(s){let r=[],t=null;for(let c of s){if(!t||t.file!==c.file)t={file:c.file,results:[]},r.push(t);t.results.push(c)}return r}function ie(s){let r=[];for(let t of s){r.push({kind:"group",file:t.file,count:t.results.length});for(let c=0;c<t.results.length;c++)r.push({kind:"hit",file:t.file,result:t.results[c],last:c===t.results.length-1})}return r}function be(s,r){if(s.kind==="group")return r.headerBox+Z.header;return r.hitBox+(s.last?Z.group:Z.hit)}function ae(s,r){let t=Array(s.length),c=Array(s.length),m=0;for(let l=0;l<s.length;l++){let S=be(s[l],r);t[l]=m,c[l]=S,m+=S}return{offsets:t,heights:c,total:m}}function le(s,r,t,c,m=240){if(s.length===0)return{start:0,end:0};let l=Math.max(0,t),S=l-m,k=l+c+m,b=0,x=s.length-1;while(b<x){let g=b+x>>1;if(s[g]+r[g]>S)x=g;else b=g+1}let C=b;b=C,x=s.length;while(b<x){let g=b+x>>1;if(s[g]>=k)x=g;else b=g+1}return{start:C,end:b}}var xe=8,Se=8;function ce({groups:s,replacement:r,showReplacePreview:t,onOpen:c,onReplaceFile:m,replaceBusy:l}){let S=i(null),k=i(null),b=u(()=>ie(s),[s]),[x,C]=n(ne),g=u(()=>ae(b,x),[b,x]),[O,y]=n(()=>({start:0,end:Math.min(b.length,60)})),F=a((p)=>{S.current=p},[]),v=a(()=>{let p=S.current;if(!p)return;let w=le(g.offsets,g.heights,p.scrollTop,p.clientHeight);y((M)=>M.start===w.start&&M.end===w.end?M:w)},[g]),R=a(()=>{v()},[v]);K(()=>{let p=k.current;if(!p)return;let w=p.querySelector("[data-search-header] > div")?.offsetHeight??0,M=p.querySelector("[data-search-hit] > button")?.offsetHeight??0;if(w>0&&w!==x.headerBox)C((N)=>({...N,headerBox:w}));if(M>0&&M!==x.hitBox)C((N)=>({...N,hitBox:M}))},[O,x,b]),K(()=>{v()},[v]),K(()=>{let p=S.current;if(!p||typeof ResizeObserver>"u")return;let w=new ResizeObserver(()=>v());return w.observe(p),()=>w.disconnect()},[v]);let H=b.length===0?0:Math.min(O.start,b.length-1),A=Math.min(O.end,b.length),L=b.slice(H,A),_=A<b.length?g.total-g.offsets[A]:0;return e("div",{ref:F,onScroll:R,className:"flex-1 scrollbar-overlay-container px-3 text-xs",style:{overflowAnchor:"none"},children:[e("div",{style:{height:xe+(g.offsets[H]??0)},"aria-hidden":"true"}),e("div",{ref:k,children:L.map((p,w)=>{let M=H+w,N=g.heights[M];if(p.kind==="group")return e("div",{"data-search-header":"",style:{height:N},children:e("div",{className:"font-semibold text-ink/80 flex items-center justify-between group",children:[e("div",{className:"flex items-center min-w-0",children:[e(ht,{name:p.file,size:12,className:"mr-1.5 flex-shrink-0"}),e("span",{className:"truncate",children:p.file}),e("span",{className:"ml-2 bg-ink/10 text-[10px] px-1.5 py-0.5 rounded-full flex-shrink-0",children:p.count})]}),e("button",{onClick:()=>m(p.file),disabled:l,className:"touch-visible opacity-0 group-hover:opacity-100 p-1 text-ink/40 hover:text-ink rounded hover:bg-ink/5 disabled:opacity-50 flex-shrink-0",title:"Replace in this file",children:e(fs,{size:12})})]})},`group:${p.file}`);return e("div",{"data-search-hit":"",style:{height:N},children:e(re,{file:p.file,result:p.result,replacement:r,showReplacePreview:t,onOpen:c})},`hit:${p.file}:${p.result.line}:${M}`)})}),e("div",{style:{height:Se+_},"aria-hidden":"true"})]})}function ue({className:s,query:r,setQuery:t,replaceQuery:c,setReplaceQuery:m,matchCase:l,setMatchCase:S,wholeWord:k,setWholeWord:b,useRegex:x,setUseRegex:C,includeFiles:g,setIncludeFiles:O,showIncludeField:y,setShowIncludeField:F,showMenu:v,setShowMenu:R,menuRef:H,rootPath:A,activeRepo:L,setActiveRepo:_,repos:p,reposScanning:w,rescanRepos:M,results:N,isSearching:G,truncated:q,error:E,onOpenFile:z,handleReplace:D,replaceBusy:J,tabsMode:Y=!1}){let Q=u(()=>oe(N),[N]),P=i(null),X=i(null),B=a(()=>{t(""),P.current?.focus()},[t]),j=a(()=>{m(""),X.current?.focus()},[m]),V=u(()=>({matchCase:l,wholeWord:k,isRegex:x,inSelection:!1}),[l,k,x]),pe=a((I)=>{zd({path:I.file,line:Number(I.line),query:r,options:V}),z?.({path:I.file,name:I.file.split("/").pop()||I.file,root:A,repo:L})},[r,V,A,L,z]),de=a((I)=>D(I),[D]);return e("div",{className:`flex flex-col h-full bg-paper ${s}`,children:[e(Bt,{left:e(d,{children:[e(uo,{id:"search",tabsMode:Y,children:e("h2",{className:"text-xs font-semibold text-ink uppercase tracking-wider",children:"Search"})}),e(Qr,{rootPath:A,activeRepo:L,onSelectRepo:_,repos:p,scanning:w,onRefreshRepos:M})]}),right:e("div",{className:"relative",ref:H,children:[e("button",{onClick:()=>R(!v),className:`p-1 rounded hover:bg-ink/5 transition-colors ${v||y?"text-ink":"text-ink/40"}`,title:"Search Options",children:e(Ie,{size:14})}),v&&e("div",{className:"glass-popover absolute right-0 top-full mt-1 w-48 bg-paper border border-ink/10 rounded shadow-lg z-10 py-1",children:e("button",{onClick:()=>{if(F(!y),y)O("");R(!1)},className:"w-full px-3 py-1.5 text-left text-xs text-ink hover:bg-ink/5 flex items-center justify-between",children:[e("span",{children:"Files to include"}),y&&e(f,{size:12,className:"text-ink/60"})]})})]})}),e("div",{className:"p-3 flex flex-col gap-2.5 border-b border-ink/10",children:[e("div",{className:"relative",children:e("div",{className:"flex items-center border border-ink/20 rounded bg-paper focus-within:border-ink/40 focus-within:ring-1 focus-within:ring-ink/10 transition-all",children:[e(U,{size:14,className:"ml-2 text-ink/40 flex-shrink-0"}),e("input",{ref:P,type:"text",placeholder:"Search",value:r,onChange:(I)=>t(I.currentTarget.value),className:"w-full bg-transparent border-none text-xs px-2 py-1.5 focus:outline-none text-ink placeholder-ink/35 min-w-0"}),r&&e("button",{type:"button",onClick:B,title:"Clear search","aria-label":"Clear search",className:"p-1 mr-0.5 rounded text-ink/40 hover:text-ink hover:bg-ink/5 flex-shrink-0",children:e(h,{size:12})}),e("div",{className:"flex items-center space-x-0.5 pr-1 text-ink/40 flex-shrink-0",children:[e("button",{onClick:()=>S(!l),className:`p-1 rounded hover:text-ink ${l?"bg-ink/10 text-ink":"hover:bg-ink/5"}`,title:"Match Case",children:e(ds,{size:14})}),e("button",{onClick:()=>b(!k),className:`p-1 rounded hover:text-ink ${k?"bg-ink/10 text-ink":"hover:bg-ink/5"}`,title:"Match Whole Word",children:e(As,{size:14})}),e("button",{onClick:()=>C(!x),className:`p-1 rounded hover:text-ink ${x?"bg-ink/10 text-ink":"hover:bg-ink/5"}`,title:"Use Regular Expression",children:e(ps,{size:14})})]})]})}),e("div",{className:"relative flex items-center space-x-1",children:[e("div",{className:"flex flex-1 min-w-0 items-center border border-ink/20 rounded bg-paper focus-within:border-ink/40 focus-within:ring-1 focus-within:ring-ink/10 transition-all",children:[e("input",{ref:X,type:"text",placeholder:"Replace",value:c,onChange:(I)=>m(I.currentTarget.value),className:"flex-1 min-w-0 bg-transparent border-none text-xs px-2 py-1.5 focus:outline-none text-ink placeholder-ink/35"}),c&&e("button",{type:"button",onClick:j,title:"Clear replace","aria-label":"Clear replace",className:"p-1 mr-0.5 rounded text-ink/40 hover:text-ink hover:bg-ink/5 flex-shrink-0",children:e(h,{size:12})})]}),e("button",{onClick:()=>D(),disabled:N.length===0||J,className:"p-1.5 rounded border border-ink/20 text-ink/60 hover:text-ink hover:bg-ink/5 disabled:opacity-50 disabled:cursor-not-allowed bg-paper",title:"Replace All",children:e(ms,{size:14})})]}),y&&e("div",{className:"relative",children:e("input",{type:"text",value:g,onChange:(I)=>O(I.currentTarget.value),placeholder:"Files to include (e.g. *.js, src/*)",className:"w-full bg-paper border border-ink/20 rounded text-xs px-2 py-1.5 focus:outline-none focus:border-ink/40 focus:ring-1 focus:ring-ink/10 transition-all text-ink placeholder-ink/40"})})]}),E&&N.length===0?e("div",{className:"flex-1 px-3 py-3",role:"alert",children:e("div",{className:"rounded border border-error/30 bg-error/5 px-2.5 py-2",children:[e("div",{className:"text-[11px] font-semibold text-error-text",children:"Search failed"}),e("div",{className:"mt-1 whitespace-pre-wrap break-words font-mono text-[10.5px] text-ink/70",children:E}),x&&e("div",{className:"mt-1 text-[10.5px] text-ink/50",children:["Regex is on — escape metacharacters such as ",e("code",{className:"font-mono",children:"( ) [ ] * ? +"})," or turn it off to search literally."]})]})}):G&&N.length===0?e("div",{className:"flex-1 text-ink/40 italic text-center py-4",children:"Searching..."}):r.trim().length<=2?e("div",{className:"flex-1 text-ink/40 italic text-center py-4",children:"Type at least 3 characters to search."}):N.length===0?e("div",{className:"flex-1 text-ink/40 italic text-center py-4",children:"No results found."}):e(d,{children:[E&&e("div",{className:"px-3 pt-2 text-[10.5px] text-error-text",role:"alert",children:["Search failed: ",e("span",{className:"font-mono",children:E})]}),G&&e("div",{className:"px-3 pt-2 text-ink/40 italic",children:"Searching…"}),q&&e("div",{className:"px-3 pt-2 text-ink/50 italic",children:["Showing the first ",se," matches — refine the query to see the rest."]}),e(ce,{groups:Q,replacement:c,showReplacePreview:c.length>0,onOpen:pe,onReplaceFile:de,replaceBusy:J})]})]})}function he(s){let[r,t]=n({scope:s,results:[],truncated:!1,error:null}),[c,m]=n(!1),l=i(null),S=i(!0),k=i(s);k.current=s,o(()=>(S.current=!0,()=>{S.current=!1,l.current?.abort(),l.current=null}),[]);let b=a(async(x)=>{l.current?.abort();let C=new AbortController;l.current=C;let g=k.current;t({scope:g,results:[],truncated:!1,error:null}),m(!0);try{let O=await fetch("/api/fs/search",{method:"POST",headers:{"content-type":"application/x-www-form-urlencoded"},body:new URLSearchParams(x),signal:C.signal});await Fc(O,(y,F)=>{if(k.current!==g)return;if(y==="done"){let v=!1;try{v=JSON.parse(F)?.truncated===!0}catch{}t((R)=>R.scope===g?{...R,truncated:v}:R);return}if(y==="error"){let v="Search failed";try{v=JSON.parse(F)?.error||v}catch{}t((R)=>R.scope===g?{...R,error:v}:R);return}if(y!=="matches")return;try{let v=JSON.parse(F);if(Array.isArray(v))t((R)=>R.scope===g?{...R,results:[...R.results,...v]}:R)}catch{}},C.signal)}catch{}finally{if(S.current&&l.current===C)l.current=null,m(!1)}},[]);return{results:r.scope===s?r.results:[],isSearching:c&&r.scope===s,truncated:r.scope===s&&r.truncated,error:r.scope===s?r.error:null,start:b}}function it({className:s="",enabled:r=!0,rootPath:t,onOpenFile:c,tabsMode:m=!1}){let[l,S]=T("search.query",""),[k,b]=T("search.replaceQuery",""),[x,C]=T("search.matchCase",!1),[g,O]=T("search.wholeWord",!1),[y,F]=T("search.useRegex",!1),[v,R]=T("search.includeFiles",""),[H,A]=n(!1),[L,_]=T("search.showIncludeField",!1),{activeRepo:p,setActiveRepo:w}=wr(t),{repos:M,scanning:N,rescan:G}=Cr(t,r),q=i(null),E=bt(),{results:z,isSearching:D,truncated:J,error:Y,start:Q}=he(`${t??""}\x00${p}`);$e(q,()=>A(!1));let P=a(()=>{if(!r)return;if(l.trim().length>2)return Q({q:l,matchCase:String(x),wholeWord:String(g),useRegex:String(y),includeFiles:L?v:"",...t?{root:t}:{},...p!=="."?{repo:p}:{}})},[r,l,x,g,y,L,v,t,p,Q]);o(()=>{let B=setTimeout(()=>{P()},300);return()=>clearTimeout(B)},[P]);let X=a((B)=>{if(!l)return;let j=B?[B]:Array.from(new Set(z.map((V)=>V.file)));if(j.length===0)return;E.submit({q:l,replaceWith:k,matchCase:String(x),wholeWord:String(g),useRegex:String(y),files:JSON.stringify(j),...t?{root:t}:{},...p!=="."?{repo:p}:{}},{method:"POST",action:"/api/fs/replace"})},[l,k,x,g,y,z,t,p,E]);if(o(()=>{if(E.state==="idle"&&E.data?.success)P()},[E.state,E.data,P]),!r)return e("div",{className:`flex flex-col h-full bg-paper items-center justify-center text-ink/40 ${s}`,children:e("span",{className:"text-xs font-mono text-muted",children:"No session selected"})});return e(ue,{className:s,tabsMode:m,query:l,setQuery:S,replaceQuery:k,setReplaceQuery:b,matchCase:x,setMatchCase:C,wholeWord:g,setWholeWord:O,useRegex:y,setUseRegex:F,includeFiles:v,setIncludeFiles:R,showIncludeField:L,setShowIncludeField:_,showMenu:H,setShowMenu:A,menuRef:q,rootPath:t,activeRepo:p,setActiveRepo:w,repos:M,reposScanning:N,rescanRepos:G,results:z,isSearching:D,truncated:J,error:Y,onOpenFile:c,handleReplace:X,replaceBusy:E.state!=="idle"})}export{it as SearchPanel};