@kabmo-labs/kabmo 0.44.0 → 0.45.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 (253) hide show
  1. package/dist/client/index.html +1 -1
  2. package/dist/client/index.js +1 -1
  3. package/dist/client/static/js/{CsvGrid-1t2q46rg.js → CsvGrid-z74weshk.js} +2 -2
  4. package/dist/client/static/js/{DocxView-301hxnwk.js → DocxView-dpe5x9ab.js} +5 -5
  5. package/dist/client/static/js/{DrawioView-47bwea5t.js → DrawioView-ftzwjf8v.js} +2 -2
  6. package/dist/client/static/js/{ImageView-68zdx5ex.js → ImageView-vchn6wyq.js} +1 -1
  7. package/dist/client/static/js/LayoutWrapper-1x0gnppc.js +2 -0
  8. package/dist/client/static/js/{Modal-fb9b4gq6.js → Modal-tteg7vtb.js} +18 -18
  9. package/dist/client/static/js/{PdfView-m64ksepp.js → PdfView-vjec8z3z.js} +1 -1
  10. package/dist/client/static/js/{SessionsView-zyjwhpzm.js → SessionsView-g7z3fxbp.js} +1 -1
  11. package/dist/client/static/js/{SheetView-e88sqprx.js → SheetView-hhtfkdhe.js} +25 -25
  12. package/dist/client/static/js/{SvgPreview-hs9a713t.js → SvgPreview-48n3ex6p.js} +1 -1
  13. package/dist/client/static/js/{abnfDiagram-O67JEVCF-fnr5kyqk.js → abnfDiagram-O67JEVCF-bpvzdara.js} +1 -1
  14. package/dist/client/static/js/architecture-7GRP2DOG-bch3nye9.js +1 -0
  15. package/dist/client/static/js/{architectureDiagram-NJMV4G6O-7v003363.js → architectureDiagram-NJMV4G6O-xw62cr7j.js} +3 -3
  16. package/dist/client/static/js/{astro-t9vjc0mc.js → astro-56b0as3q.js} +1 -1
  17. package/dist/client/static/js/bash-mevzaywf.js +1 -0
  18. package/dist/client/static/js/{blockDiagram-BEXU5L5S-k4mwbw3d.js → blockDiagram-BEXU5L5S-x3a6cgar.js} +4 -4
  19. package/dist/client/static/js/{c4Diagram-YGBWAQC7-688zq6f4.js → c4Diagram-YGBWAQC7-katvaxbj.js} +2 -2
  20. package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-h0s16pxr.js → classDiagram-v2-NBCMYWYE-bjz4mqqh.js} +3 -3
  21. package/dist/client/static/js/{cose-bilkent-JH36ORCC-qb2t8qq5.js → cose-bilkent-JH36ORCC-fsn80psf.js} +1 -1
  22. package/dist/client/static/js/cpp-wk9z0c5g.js +1 -0
  23. package/dist/client/static/js/css-3w3p9s67.js +1 -0
  24. package/dist/client/static/js/cynefin-OW5HDTMX-vqy5jtnk.js +1 -0
  25. package/dist/client/static/js/{cynefinDiagram-VND7K2PF-syhtcr7b.js → cynefinDiagram-VND7K2PF-cfhbsnkm.js} +2 -2
  26. package/dist/client/static/js/{dagre-6A5THRUB-7wgbx6cm.js → dagre-6A5THRUB-j2wt7ns6.js} +2 -2
  27. package/dist/client/static/js/{diagram-22UHCM2B-951cmp5h.js → diagram-22UHCM2B-abrdj714.js} +8 -8
  28. package/dist/client/static/js/{diagram-3UASUU5V-mvdbqt7b.js → diagram-3UASUU5V-dbn15bxn.js} +1 -1
  29. package/dist/client/static/js/{diagram-ATOU4E4O-hkvdtgdm.js → diagram-ATOU4E4O-y79pwf7w.js} +3 -3
  30. package/dist/client/static/js/{diagram-CDSNMT55-bkkz35ca.js → diagram-CDSNMT55-f8ryt86n.js} +2 -2
  31. package/dist/client/static/js/{diagram-MLGK6HIB-z6pcrkc3.js → diagram-MLGK6HIB-ws7wn3q9.js} +1 -1
  32. package/dist/client/static/js/{diagram-MPIPVDR6-mkwf8j4m.js → diagram-MPIPVDR6-zmznrg13.js} +2 -2
  33. package/dist/client/static/js/{dockerfile-7gd570bm.js → dockerfile-qgc921kw.js} +1 -1
  34. package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-trym26ts.js → ebnfDiagram-ZINNZB2B-y5q7hy1v.js} +1 -1
  35. package/dist/client/static/js/{elixir-z77c7tfn.js → elixir-12pgbgtq.js} +1 -1
  36. package/dist/client/static/js/{elk-276RUBZZ-gkhz67v6.js → elk-276RUBZZ-vddwbn6q.js} +1 -1
  37. package/dist/client/static/js/{erDiagram-OPXOYQCR-gkyr5cqs.js → erDiagram-OPXOYQCR-qdqcx4g4.js} +6 -6
  38. package/dist/client/static/js/{erlang-6vrvh2m6.js → erlang-811btv6p.js} +1 -1
  39. package/dist/client/static/js/eventmodeling-NTZA5JFV-65ph4s3m.js +1 -0
  40. package/dist/client/static/js/flowDiagram-KWPJA3E3-nh2tb65b.js +1 -0
  41. package/dist/client/static/js/{ganttDiagram-FUAMR5RP-1qpme6ks.js → ganttDiagram-FUAMR5RP-763hk9rm.js} +1 -1
  42. package/dist/client/static/js/gitGraph-4MIJSDKK-t45ekjb6.js +1 -0
  43. package/dist/client/static/js/{gitGraphDiagram-X574FWY7-wbg3kqak.js → gitGraphDiagram-X574FWY7-bgx1q5nw.js} +4 -4
  44. package/dist/client/static/js/graphql-027z8sc0.js +1 -0
  45. package/dist/client/static/js/html-fqda6wxx.js +1 -0
  46. package/dist/client/static/js/{index-ks23y2cd.js → index-03j5j1j0.js} +2 -2
  47. package/dist/client/static/js/{index-czedkbmb.js → index-05hx4ftf.js} +2 -2
  48. package/dist/client/static/js/index-0vk6v4y4.js +2 -0
  49. package/dist/client/static/js/{index-83pwa9c0.js → index-1nwwvv29.js} +1 -1
  50. package/dist/client/static/js/{index-31hntzse.js → index-228yzebd.js} +5 -5
  51. package/dist/client/static/js/{index-xf36nmbm.js → index-2b1wnvez.js} +2 -2
  52. package/dist/client/static/js/{index-6t21c6jt.js → index-34ff2vq6.js} +2 -2
  53. package/dist/client/static/js/{index-1923aj4g.js → index-3d21hpk7.js} +2 -2
  54. package/dist/client/static/js/{index-hfsvwfgw.js → index-3h2mr90j.js} +2 -2
  55. package/dist/client/static/js/{index-svmzgtcx.js → index-3sqndc9n.js} +2 -2
  56. package/dist/client/static/js/{index-6gyk52ff.js → index-47wn2gjx.js} +1 -1
  57. package/dist/client/static/js/{index-6ah5sj5y.js → index-4b5b6g0k.js} +1 -1
  58. package/dist/client/static/js/{index-53ysgsd2.js → index-5b2vsbcf.js} +1 -1
  59. package/dist/client/static/js/{index-qm92sf9w.js → index-5mrqfs82.js} +12 -12
  60. package/dist/client/static/js/{index-62ng8tkj.js → index-61j9qkck.js} +3 -3
  61. package/dist/client/static/js/index-6bm4pw90.css +1 -0
  62. package/dist/client/static/js/{index-fj4k07zt.js → index-6sqmhdyv.js} +2 -2
  63. package/dist/client/static/js/{index-gtkhz0hj.js → index-8dtp7mt0.js} +2 -2
  64. package/dist/client/static/js/index-a11ptyzf.js +1 -0
  65. package/dist/client/static/js/{index-nvevymac.js → index-acphtw1r.js} +2 -2
  66. package/dist/client/static/js/{index-pxm44qfd.js → index-cj39b26c.js} +1 -1
  67. package/dist/client/static/js/{index-wytdbvax.js → index-dgjerk4w.js} +3 -3
  68. package/dist/client/static/js/{index-ad4x44d6.js → index-dn6pqym4.js} +6 -6
  69. package/dist/client/static/js/{index-nr8s5xm9.js → index-ehg2ftnp.js} +2 -2
  70. package/dist/client/static/js/{index-jbkkwa2q.js → index-f51jxezc.js} +2 -2
  71. package/dist/client/static/js/index-f7paep2f.js +2 -0
  72. package/dist/client/static/js/{index-qkjx6521.js → index-f98dhbt4.js} +4 -4
  73. package/dist/client/static/js/{index-92n96mgd.js → index-fbct0jcf.js} +2 -2
  74. package/dist/client/static/js/{index-bjqz7swa.js → index-fqatn0vh.js} +1 -1
  75. package/dist/client/static/js/{index-tzdm1y3z.js → index-gcwmpfr4.js} +2 -2
  76. package/dist/client/static/js/{index-v5npdwy2.js → index-gmq5pbcv.js} +51 -51
  77. package/dist/client/static/js/{index-fbpc1wx6.js → index-gzafyqsr.js} +21 -21
  78. package/dist/client/static/js/{index-4y4hshcx.js → index-gzp4j2h5.js} +2 -2
  79. package/dist/client/static/js/{index-nqjd3hh5.js → index-h0rmkz9n.js} +2 -2
  80. package/dist/client/static/js/{index-8trggh1z.js → index-jpp0zm7t.js} +7 -7
  81. package/dist/client/static/js/{index-qf9x7yet.js → index-kg2sk8cf.js} +1 -1
  82. package/dist/client/static/js/{index-rpzxrr2d.js → index-mrw7qweg.js} +1 -1
  83. package/dist/client/static/js/{index-s8bktzpg.js → index-mwm8aptp.js} +1 -1
  84. package/dist/client/static/js/{index-c3v62nvt.js → index-n1ga63de.js} +2 -2
  85. package/dist/client/static/js/{index-22whvfdw.js → index-nzhwd6t3.js} +2 -2
  86. package/dist/client/static/js/{index-tr2pkfs6.js → index-p21mvqc2.js} +2 -2
  87. package/dist/client/static/js/{index-qsw5edtk.js → index-pfj3sd1n.js} +5 -5
  88. package/dist/client/static/js/{index-pysqpc5n.js → index-pxq4v81r.js} +2 -2
  89. package/dist/client/static/js/{index-07yh7qx0.js → index-q76jfb54.js} +1 -1
  90. package/dist/client/static/js/{index-6s4mrdew.js → index-qt9jc4ck.js} +2 -2
  91. package/dist/client/static/js/{index-ehacfgwm.js → index-r6e44vkx.js} +1 -1
  92. package/dist/client/static/js/{index-232nsp2c.js → index-szk3vk8h.js} +1 -1
  93. package/dist/client/static/js/{index-e6rm5xzj.js → index-t0yv1375.js} +1 -1
  94. package/dist/client/static/js/{index-n0matkz9.js → index-vgcm2g0g.js} +2 -2
  95. package/dist/client/static/js/{index-kwpaz891.js → index-vkerrwpa.js} +2 -2
  96. package/dist/client/static/js/{index-v7bcgh77.js → index-w57zbym7.js} +2 -2
  97. package/dist/client/static/js/{index-yfjvx4yf.js → index-wqrdgt1g.js} +2 -2
  98. package/dist/client/static/js/{index-barbpakv.js → index-x2wvq4ae.js} +2 -2
  99. package/dist/client/static/js/{index-3w845q50.js → index-x7rfmwg8.js} +2 -2
  100. package/dist/client/static/js/{index-cq98p2rb.js → index-xkwybnf3.js} +179 -179
  101. package/dist/client/static/js/info-A6RAGUB7-mw29xbwf.js +1 -0
  102. package/dist/client/static/js/{infoDiagram-VRGFBTTK-yebngg8c.js → infoDiagram-VRGFBTTK-e66pw8d9.js} +1 -1
  103. package/dist/client/static/js/ini-3cx6tmv4.js +1 -0
  104. package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-kh4nqj6q.js → ishikawaDiagram-OU5B5YK6-ehc0q24d.js} +1 -1
  105. package/dist/client/static/js/java-zs6qh1dm.js +1 -0
  106. package/dist/client/static/js/javascript-b9mkygak.js +1 -0
  107. package/dist/client/static/js/{journeyDiagram-ZHPQQLJL-4khnf8x1.js → journeyDiagram-ZHPQQLJL-hye05qtd.js} +2 -2
  108. package/dist/client/static/js/jsx-gahhfczw.js +1 -0
  109. package/dist/client/static/js/{julia-svwxx41e.js → julia-mgsev9df.js} +1 -1
  110. package/dist/client/static/js/{kanban-definition-PNTS6WVX-snmq3wq4.js → kanban-definition-PNTS6WVX-vce614m8.js} +6 -6
  111. package/dist/client/static/js/lua-d8enp14s.js +1 -0
  112. package/dist/client/static/js/markdown-qetaj4vp.js +1 -0
  113. package/dist/client/static/js/{mermaid.core-yctw30sk.js → mermaid.core-gc79re5p.js} +7 -7
  114. package/dist/client/static/js/{mindmap-definition-NLK3R4M7-atfv66wq.js → mindmap-definition-NLK3R4M7-ft1whaf5.js} +3 -3
  115. package/dist/client/static/js/one-dark-pro-rvg5xm1a.js +1 -0
  116. package/dist/client/static/js/one-light-2b5w3ksh.js +1 -0
  117. package/dist/client/static/js/packet-AYTQ26CC-md85wpjq.js +1 -0
  118. package/dist/client/static/js/{pegDiagram-GJSIUBJH-hpbtxjht.js → pegDiagram-GJSIUBJH-2s4ykhaa.js} +1 -1
  119. package/dist/client/static/js/{perl-mr0ds2ex.js → perl-6n93vjsa.js} +1 -1
  120. package/dist/client/static/js/{php-5h3wt6tv.js → php-w23nmbtc.js} +1 -1
  121. package/dist/client/static/js/pie-WAS4IAKB-4grcqnp8.js +1 -0
  122. package/dist/client/static/js/{pieDiagram-5QR66LMP-9zrtkdr2.js → pieDiagram-5QR66LMP-7h8dp0z3.js} +2 -2
  123. package/dist/client/static/js/properties-g6tpq003.js +1 -0
  124. package/dist/client/static/js/python-cy06fzhg.js +1 -0
  125. package/dist/client/static/js/{quadrantDiagram-O4NWA36T-xq970vx1.js → quadrantDiagram-O4NWA36T-pteyxjxr.js} +2 -2
  126. package/dist/client/static/js/r-vw8berfv.js +1 -0
  127. package/dist/client/static/js/radar-RG4KPBEZ-7j9prhg1.js +1 -0
  128. package/dist/client/static/js/railroad-74A4TZTK-g8x2jps1.js +1 -0
  129. package/dist/client/static/js/railroad-abnf-HS5TGJTU-cbg7k68h.js +1 -0
  130. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-xfvjk9f8.js +1 -0
  131. package/dist/client/static/js/railroad-peg-WCYAUIDC-7w97805z.js +1 -0
  132. package/dist/client/static/js/{railroadDiagram-XR7U4H2S-1g9jchbk.js → railroadDiagram-XR7U4H2S-68z9wdt0.js} +1 -1
  133. package/dist/client/static/js/{requirementDiagram-PLB6GJNP-ntt088y4.js → requirementDiagram-PLB6GJNP-c08nmey6.js} +3 -3
  134. package/dist/client/static/js/{ruby-nn836rtq.js → ruby-ag3b3t9t.js} +1 -1
  135. package/dist/client/static/js/{rust-eygk56y5.js → rust-ke5ec0w5.js} +1 -1
  136. package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-95k8c5v6.js → sankeyDiagram-IPEJSGJF-2r3kvjs5.js} +3 -3
  137. package/dist/client/static/js/{sass-c2bk03e4.js → sass-x0eez0kp.js} +1 -1
  138. package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-qfvxrwfa.js → sequenceDiagram-PO4LG4MO-ctjycd88.js} +6 -6
  139. package/dist/client/static/js/{sizeCapture-INFHLROL-0m7dc5nd.js → sizeCapture-INFHLROL-97ndea95.js} +1 -1
  140. package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-femwcn7n.js → stateDiagram-v2-GCMORJYK-aqnmsb96.js} +3 -3
  141. package/dist/client/static/js/{svelte-bfy1rq5g.js → svelte-tg19by0f.js} +1 -1
  142. package/dist/client/static/js/{swimlanes-2SLR337P-5n1qq48r.js → swimlanes-2SLR337P-v50cx1nx.js} +1 -1
  143. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-e227mz39.js +8 -0
  144. package/dist/client/static/js/{timeline-definition-EJHVYXUP-vdsj18be.js → timeline-definition-EJHVYXUP-1ggrtdcj.js} +4 -4
  145. package/dist/client/static/js/treeView-Q6P3EWNA-xhf1r6c3.js +1 -0
  146. package/dist/client/static/js/treemap-WGGIJYW6-4n3j7ekq.js +1 -0
  147. package/dist/client/static/js/tsx-3dzv8h6k.js +1 -0
  148. package/dist/client/static/js/typescript-44vs0wn4.js +1 -0
  149. package/dist/client/static/js/{usecaseDiagram-POWQR4AR-psjbrprk.js → usecaseDiagram-POWQR4AR-ybcwhpzs.js} +19 -19
  150. package/dist/client/static/js/{vennDiagram-UO4OBE2U-4yn9kac9.js → vennDiagram-UO4OBE2U-p9ggrt07.js} +4 -4
  151. package/dist/client/static/js/{vue-0fwtgwj4.js → vue-mhj4sme0.js} +1 -1
  152. package/dist/client/static/js/wardley-WFR3VGLG-fb0py35r.js +1 -0
  153. package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-js0tbpca.js → wardleyDiagram-VNRHLVJA-v79nb9kx.js} +2 -2
  154. package/dist/client/static/js/xml-yvv5fn3k.js +1 -0
  155. package/dist/client/static/js/{xychartDiagram-PMCCYNJV-svr38ygh.js → xychartDiagram-PMCCYNJV-43thqscz.js} +2 -2
  156. package/dist/client/static/js/yaml-avewh7n5.js +1 -0
  157. package/marketplace/marketplace.json +7 -0
  158. package/marketplace/plugins/github-actions/README.md +142 -0
  159. package/marketplace/plugins/github-actions/icon.svg +12 -0
  160. package/marketplace/plugins/github-actions/package.json +30 -0
  161. package/marketplace/plugins/github-actions/settings-schema.json +27 -0
  162. package/marketplace/plugins/github-actions/src/app.tsx +32 -0
  163. package/marketplace/plugins/github-actions/src/panel/Actions.tsx +105 -0
  164. package/marketplace/plugins/github-actions/src/panel/LogView.tsx +76 -0
  165. package/marketplace/plugins/github-actions/src/panel/Row.tsx +59 -0
  166. package/marketplace/plugins/github-actions/src/panel/RunView.tsx +197 -0
  167. package/marketplace/plugins/github-actions/src/panel/format.ts +74 -0
  168. package/marketplace/plugins/github-actions/src/panel/index.test.tsx +86 -0
  169. package/marketplace/plugins/github-actions/src/panel/index.tsx +256 -0
  170. package/marketplace/plugins/github-actions/src/panel/picker.test.tsx +68 -0
  171. package/marketplace/plugins/github-actions/src/panel/test-fixtures.ts +98 -0
  172. package/marketplace/plugins/github-actions/src/panel/test-harness.tsx +175 -0
  173. package/marketplace/plugins/github-actions/src/protocol.ts +156 -0
  174. package/marketplace/plugins/github-actions/src/server/github.test.ts +264 -0
  175. package/marketplace/plugins/github-actions/src/server/github.ts +309 -0
  176. package/marketplace/plugins/github-actions/src/server/http.test.ts +150 -0
  177. package/marketplace/plugins/github-actions/src/server/http.ts +202 -0
  178. package/marketplace/plugins/github-actions/src/server/json.ts +44 -0
  179. package/marketplace/plugins/github-actions/src/server/logtext.test.ts +84 -0
  180. package/marketplace/plugins/github-actions/src/server/logtext.ts +59 -0
  181. package/marketplace/plugins/github-actions/src/server/progress.test.ts +96 -0
  182. package/marketplace/plugins/github-actions/src/server/progress.ts +62 -0
  183. package/marketplace/plugins/github-actions/src/server/remote.ts +84 -0
  184. package/marketplace/plugins/github-actions/src/server/scope.ts +51 -0
  185. package/marketplace/plugins/github-actions/src/server/token.ts +84 -0
  186. package/marketplace/plugins/github-actions/src/server.ts +163 -0
  187. package/marketplace/plugins/github-actions/src/state.test.ts +55 -0
  188. package/marketplace/plugins/github-actions/src/state.ts +63 -0
  189. package/marketplace/plugins/github-actions/tsconfig.json +16 -0
  190. package/package.json +1 -1
  191. package/src/client/components/mobile/RightSidebar.tsx +164 -66
  192. package/src/client/components/mobile/header-titlebar.test.tsx +92 -0
  193. package/src/client/components/mobile/mobile-right-sidebar/Chrome.tsx +179 -0
  194. package/src/client/components/mobile/panel-chips.test.tsx +12 -0
  195. package/src/client/components/mobile/panel-chips.tsx +5 -1
  196. package/src/client/components/mobile/right-drawer-nav.test.tsx +258 -0
  197. package/src/client/components/settings/apply-side-effects.ts +6 -0
  198. package/src/client/components/settings/categories/appearance-settings/PanelNavSection.tsx +123 -2
  199. package/src/client/components/workspace/panel-tabs/Home.tsx +14 -2
  200. package/src/client/components/workspace/panel-tabs/TabChip.tsx +173 -0
  201. package/src/client/components/workspace/panel-tabs/TabStrip.test.tsx +118 -0
  202. package/src/client/components/workspace/panel-tabs/TabStrip.tsx +89 -102
  203. package/src/client/components/workspace/panel-tabs/index.tsx +9 -1
  204. package/src/client/hooks/workspace/mobile-right-panel-nav.ts +63 -0
  205. package/src/client/hooks/workspace/panel-nav.test.ts +39 -1
  206. package/src/client/lib/ui/control-plate.ts +33 -0
  207. package/src/server/lib/bundler/titlebar-css.test.ts +5 -3
  208. package/src/shared/lib/settings/defaults.ts +2 -1
  209. package/src/shared/lib/workspace/panel-nav.test.ts +36 -0
  210. package/src/shared/lib/workspace/panel-nav.ts +43 -0
  211. package/src/shared/types/settings/state.ts +9 -1
  212. package/dist/client/static/js/LayoutWrapper-vw54s8ra.js +0 -2
  213. package/dist/client/static/js/architecture-7GRP2DOG-mq93vqx9.js +0 -1
  214. package/dist/client/static/js/bash-fjzhxy10.js +0 -1
  215. package/dist/client/static/js/cpp-9f6zkdd4.js +0 -1
  216. package/dist/client/static/js/css-y4y3qtsb.js +0 -1
  217. package/dist/client/static/js/cynefin-OW5HDTMX-qyg5rjr5.js +0 -1
  218. package/dist/client/static/js/eventmodeling-NTZA5JFV-15yz245z.js +0 -1
  219. package/dist/client/static/js/flowDiagram-KWPJA3E3-n1sapfye.js +0 -1
  220. package/dist/client/static/js/gitGraph-4MIJSDKK-xtjwv160.js +0 -1
  221. package/dist/client/static/js/graphql-amk52c95.js +0 -1
  222. package/dist/client/static/js/html-2y935m7r.js +0 -1
  223. package/dist/client/static/js/index-19ffgf9a.js +0 -2
  224. package/dist/client/static/js/index-204ae4vs.js +0 -2
  225. package/dist/client/static/js/index-n6fbd265.js +0 -1
  226. package/dist/client/static/js/index-sc7r305t.css +0 -1
  227. package/dist/client/static/js/info-A6RAGUB7-e31s2xvj.js +0 -1
  228. package/dist/client/static/js/ini-kemnmt16.js +0 -1
  229. package/dist/client/static/js/java-caqpfm88.js +0 -1
  230. package/dist/client/static/js/javascript-zegm06a1.js +0 -1
  231. package/dist/client/static/js/jsx-bvterpm5.js +0 -1
  232. package/dist/client/static/js/lua-1hcfm8ya.js +0 -1
  233. package/dist/client/static/js/markdown-n6na4ykv.js +0 -1
  234. package/dist/client/static/js/one-dark-pro-c1vnxka7.js +0 -1
  235. package/dist/client/static/js/one-light-mbxx52p5.js +0 -1
  236. package/dist/client/static/js/packet-AYTQ26CC-mtzmsrk4.js +0 -1
  237. package/dist/client/static/js/pie-WAS4IAKB-85nwadmj.js +0 -1
  238. package/dist/client/static/js/properties-nxcks67c.js +0 -1
  239. package/dist/client/static/js/python-58p0gqn0.js +0 -1
  240. package/dist/client/static/js/r-eyn8en0g.js +0 -1
  241. package/dist/client/static/js/radar-RG4KPBEZ-ae3jdajx.js +0 -1
  242. package/dist/client/static/js/railroad-74A4TZTK-3m0s7cse.js +0 -1
  243. package/dist/client/static/js/railroad-abnf-HS5TGJTU-pz22c3eb.js +0 -1
  244. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-cgqgqq15.js +0 -1
  245. package/dist/client/static/js/railroad-peg-WCYAUIDC-ts0nmcxb.js +0 -1
  246. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-n85hawg8.js +0 -8
  247. package/dist/client/static/js/treeView-Q6P3EWNA-fvpt3hm8.js +0 -1
  248. package/dist/client/static/js/treemap-WGGIJYW6-4z9s24je.js +0 -1
  249. package/dist/client/static/js/tsx-fnzxsv25.js +0 -1
  250. package/dist/client/static/js/typescript-0ppbqrb6.js +0 -1
  251. package/dist/client/static/js/wardley-WFR3VGLG-73mrhkmy.js +0 -1
  252. package/dist/client/static/js/xml-v1ytr8qz.js +0 -1
  253. package/dist/client/static/js/yaml-txrqz62t.js +0 -1
@@ -37,6 +37,8 @@ import { MobileHeader } from '@/client/components/mobile/mobile-main-view/Header
37
37
  import { MobileSessionHeader } from '@/client/components/mobile/mobile-session-sidebar/Header';
38
38
  import { MobileRightSidebar } from '@/client/components/mobile/RightSidebar';
39
39
  import { SessionStateProvider } from '@/client/components/common/session-state-provider/index';
40
+ import { primeKabmoSettings } from '@/shared/lib/settings/client';
41
+ import { CONTROL_ROW_HEIGHT, CONTROL_ROW_INSET } from '@/client/lib/ui/control-plate';
40
42
  import { silenceRealtime, restoreRealtime } from '@/test-support/silent-socket';
41
43
 
42
44
  const DOM_GLOBALS = [
@@ -104,6 +106,9 @@ beforeEach(() => {
104
106
  // origin answers nothing, and a refused dial fails asynchronously — after
105
107
  // this suite has restored the globals, which reports against the NEXT file.
106
108
  silenceRealtime();
109
+ // Settings are primed per mount; a suite-level default keeps a style written
110
+ // by one test from deciding the next one's chrome.
111
+ primeKabmoSettings({});
107
112
  container = document.createElement('div');
108
113
  document.body.appendChild(container);
109
114
  });
@@ -176,6 +181,7 @@ describe('phone headers as a shell title bar', () => {
176
181
  });
177
182
 
178
183
  test('the right drawer header is a drag region whose controls are not', async () => {
184
+ // `classic` still has a header — the chip strip lives in it.
179
185
  await mountAsMacShell(() =>
180
186
  h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
181
187
  );
@@ -189,6 +195,30 @@ describe('phone headers as a shell title bar', () => {
189
195
  expect(close.className).toContain('titlebar-no-drag');
190
196
  });
191
197
 
198
+ /**
199
+ * Under `tabs` there is no header: the strip above the body is the whole
200
+ * chrome, exactly as on the desktop. It inherits the window contract the
201
+ * header used to carry, and the close control moves into its trailing
202
+ * actions — so a narrowed shell window still has a handle AND a way out.
203
+ */
204
+ test('under tabs the strip is the title bar and owns the close control', async () => {
205
+ primeKabmoSettings({ mobileRightPanelNav: 'tabs' });
206
+ await mountAsMacShell(() =>
207
+ h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
208
+ );
209
+ const drag = container.querySelector('[data-drag-region]') as HTMLElement;
210
+ expect(drag).toBeTruthy();
211
+ expect(drag.getAttribute('role')).toBe('tablist');
212
+ expect(drag.className).toContain('titlebar-drag-region');
213
+ expect(drag.style.paddingLeft).toContain('5rem');
214
+ // No second row: the only horizontal chrome is the strip.
215
+ expect(container.querySelectorAll('header').length).toBe(0);
216
+ // The close control is still here, now in the strip's trailing actions.
217
+ const close = drag.querySelector('button[aria-label="Close right sidebar"]') as HTMLElement;
218
+ expect(close).toBeTruthy();
219
+ expect(close.closest('.titlebar-no-drag')).not.toBeNull();
220
+ });
221
+
192
222
  test('a right-click on the right drawer header opens the panel switch', async () => {
193
223
  await mountAsMacShell(() =>
194
224
  h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
@@ -206,6 +236,68 @@ describe('phone headers as a shell title bar', () => {
206
236
  menu!.parentElement?.remove();
207
237
  });
208
238
 
239
+ test('under tabs a right-click on the strip opens the same switch', async () => {
240
+ primeKabmoSettings({ mobileRightPanelNav: 'tabs' });
241
+ await mountAsMacShell(() =>
242
+ h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
243
+ );
244
+ const strip = container.querySelector('[role="tablist"]') as HTMLElement;
245
+ act(() => {
246
+ strip.dispatchEvent(new win.MouseEvent('contextmenu', { bubbles: true, cancelable: true }) as unknown as Event);
247
+ });
248
+ const menu = document.querySelector('[role="menu"][aria-label="Panels visibility"]');
249
+ expect(menu).not.toBeNull();
250
+ menu!.parentElement?.remove();
251
+ });
252
+
253
+ /**
254
+ * The strip is the phone's title bar, so it carries the SAFE AREA the way
255
+ * every other phone header does — `height: calc(row + inset)` AND
256
+ * `padding-top: inset`.
257
+ *
258
+ * Both are load-bearing and they are not interchangeable: with only the
259
+ * height, the row grows but its content stays pinned to y=0, so every chip
260
+ * sits under the status bar; with only the padding, `box-sizing: border-box`
261
+ * eats the padding out of the row and the chips are squeezed into a 16px
262
+ * content box. `MobileHeader` and `MobileSessionHeader` state the pair, and
263
+ * this strip is their peer.
264
+ */
265
+ test('the tabs strip reserves the notch as height AND padding, like the other headers', async () => {
266
+ primeKabmoSettings({ mobileRightPanelNav: 'tabs' });
267
+ await mountAsMacShell(() =>
268
+ h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
269
+ );
270
+ const strip = container.querySelector('[role="tablist"]') as HTMLElement;
271
+ // Asserted against the SHARED constants, not a class spelling: the row
272
+ // height is the phone header's 56px plus the notch, stated once in
273
+ // `control-plate.ts` so this strip cannot drift to a third density.
274
+ expect(strip.className).toContain(CONTROL_ROW_HEIGHT.mobile);
275
+ expect(strip.className).toContain(CONTROL_ROW_INSET.mobile);
276
+ // Both halves of the notch are in that one string: height AND padding.
277
+ expect(CONTROL_ROW_HEIGHT.mobile).toContain('3.5rem');
278
+ expect(CONTROL_ROW_HEIGHT.mobile).toContain('pt-[env(safe-area-inset-top,0px)]');
279
+ });
280
+
281
+ /**
282
+ * The close control is the plain panel mark, NOT `PanelRightClose`.
283
+ *
284
+ * That icon draws a chevron inside the panel (`m8 9 3 3-3 3`), which reads as
285
+ * "collapse this column" — a second meaning on a strip whose chips already
286
+ * carry their own `X`. Asserted on the rendered glyph so swapping the import
287
+ * back cannot pass.
288
+ */
289
+ test('the strip close control draws the plain panel icon, with no chevron', async () => {
290
+ primeKabmoSettings({ mobileRightPanelNav: 'tabs' });
291
+ await mountAsMacShell(() =>
292
+ h(MobileRightSidebar, { enabled: false, onClose: () => {} }),
293
+ );
294
+ const close = container.querySelector('button[aria-label="Close right sidebar"]') as HTMLElement;
295
+ expect(close).not.toBeNull();
296
+ const paths = [...close.querySelectorAll('path')].map((p) => p.getAttribute('d') ?? '');
297
+ expect(paths).toContain('M15 3v18');
298
+ expect(paths.some((d) => d.includes('3-3'))).toBe(false);
299
+ });
300
+
209
301
  /** A browser tab has no shell, so nothing is reserved and nothing is marked. */
210
302
  test('a browser marks no drag region and reserves nothing', async () => {
211
303
  await act(async () => {
@@ -0,0 +1,179 @@
1
+ /**
2
+ * @license
3
+ * SPDX-License-Identifier: MIT
4
+ */
5
+
6
+ /**
7
+ * The phone right drawer's two chromes, as components.
8
+ *
9
+ * Extracted from `RightSidebar` when that file crossed the 350-line ceiling.
10
+ * The split is by QUESTION, not by line count: the drawer owns state (which
11
+ * view, which tabs, whether the terminal wants the keyboard) and these own the
12
+ * two shapes of chrome that state is drawn in.
13
+ *
14
+ * - `DrawerHeader` is the `classic` chrome: a real header row holding the whole
15
+ * catalog as chips. It must be tall enough for the 44px touch floor, and it is
16
+ * the window's title bar while this drawer is the mounted screen.
17
+ * - `TabsChrome` is the `tabs` chrome: the strip alone, which inherits that same
18
+ * window contract (`data-drag-region`, the shell's traffic-light inset, the
19
+ * safe-area top) because there is no header left to carry it, and whose
20
+ * trailing action is the drawer's close control.
21
+ *
22
+ * The `PanelRightClose` glyph rather than an `X` is deliberate: the control
23
+ * closes the DRAWER, not the view, and an `X` beside eleven chips reads as
24
+ * "close this tab".
25
+ */
26
+
27
+ import { Suspense } from 'preact/compat';
28
+ import type { CSSProperties } from 'preact/compat';
29
+ import { PanelRight, X } from 'lucide-preact';
30
+ import { PanelHostProvider } from '@kabmo-labs/kabmo-ui';
31
+ import type { ResolvedPanel } from '@/client/components/workspace/plugin-panel/catalog';
32
+ import type { PanelBodyProps } from '@/client/components/workspace/panels/builtin';
33
+ import { PanelChips } from '@/client/components/mobile/panel-chips';
34
+ import { dragRegionProps, titlebarInsetLeft } from '@/client/lib/desktop/titlebar';
35
+ import type { VisibilityMenuSurfaceProps } from '@/client/hooks/ui/visibility-menu-trigger';
36
+ import { titlebarPaddingLeft, titlebarPaddingRight } from '@/shared/lib/ui/titlebar';
37
+ import { CONTROL_BOX, CONTROL_GLYPH_PX } from '@/client/lib/ui/control-plate';
38
+
39
+ /** The height a `classic` header needs to hold a 44px chip and its padding. */
40
+ const HEADER_HEIGHT = 'calc(3.5rem + env(safe-area-inset-top, 0px))';
41
+
42
+ export function DrawerHeader({
43
+ catalog,
44
+ activeId,
45
+ onSelect,
46
+ hasGitChanges,
47
+ onClose,
48
+ menuProps,
49
+ }: {
50
+ catalog: readonly ResolvedPanel[];
51
+ activeId: string;
52
+ onSelect: (id: string) => void;
53
+ hasGitChanges: boolean;
54
+ onClose: () => void;
55
+ menuProps: VisibilityMenuSurfaceProps;
56
+ }) {
57
+ return (
58
+ <div
59
+ className="border-b border-ink/10 flex items-center justify-between px-3 flex-shrink-0 bg-canvas titlebar-drag-region select-none"
60
+ {...dragRegionProps()}
61
+ {...menuProps}
62
+ style={{
63
+ height: HEADER_HEIGHT,
64
+ paddingTop: 'env(safe-area-inset-top, 0px)',
65
+ paddingLeft: titlebarInsetLeft(titlebarPaddingLeft('0.75rem', true)),
66
+ paddingRight: titlebarPaddingRight('0.75rem', true),
67
+ }}
68
+ >
69
+ {/* The header is a drag region, so its controls must say so —
70
+ `app-region` inherits, and a control inside a drag region is a drag
71
+ handle that swallows its own click on Windows. */}
72
+ <div className="flex items-center min-w-0 titlebar-no-drag">
73
+ <PanelChips
74
+ panels={catalog}
75
+ activeId={activeId}
76
+ onSelect={onSelect}
77
+ hasGitChanges={hasGitChanges}
78
+ />
79
+ </div>
80
+
81
+ <button
82
+ type="button"
83
+ onClick={onClose}
84
+ className="p-1.5 rounded-lg hover:bg-ink/5 active:bg-ink/10 text-ink transition-colors flex-shrink-0 ml-2 titlebar-no-drag"
85
+ title="Close right sidebar"
86
+ aria-label="Close right sidebar"
87
+ >
88
+ <X size={20} strokeWidth={1.8} />
89
+ </button>
90
+ </div>
91
+ );
92
+ }
93
+
94
+ /**
95
+ * The `tabs` chrome's strip props: the window contract the removed header
96
+ * carried, and nothing else.
97
+ */
98
+ export function drawerStripProps(menuProps: VisibilityMenuSurfaceProps): {
99
+ dragRegion: boolean;
100
+ layout: 'mobile';
101
+ rootProps: Record<string, unknown>;
102
+ style: CSSProperties;
103
+ } {
104
+ return {
105
+ dragRegion: true,
106
+ // The PHONE density, stated rather than inferred from `dragRegion`: this
107
+ // drawer is the phone layout's own screen, and its row must match the
108
+ // phone header above the chat (56px, 36px controls) — measured before this,
109
+ // the strip drew 40px/28px against a 56px/36px header and read as a broken
110
+ // edge.
111
+ layout: 'mobile',
112
+ // The ATTRIBUTE the shells hit-test, plus the drawer's long-press menu
113
+ // handlers: this row is what the header used to be, so it inherits both
114
+ // jobs. `dragRegionProps` is empty in a browser tab, where nothing may be
115
+ // dragged.
116
+ rootProps: { ...dragRegionProps(), ...menuProps } as unknown as Record<string, unknown>,
117
+ // The row's height and the notch live in the strip's own classes
118
+ // (`TabStrip`): a `padding-top: env()` written here is dropped by
119
+ // happy-dom, and the two values belong together with the height they
120
+ // modify. Only the HORIZONTAL insets are this caller's business.
121
+ style: {
122
+ paddingLeft: titlebarInsetLeft(titlebarPaddingLeft('0.75rem', true)),
123
+ paddingRight: titlebarPaddingRight('0.75rem', true),
124
+ },
125
+ };
126
+ }
127
+
128
+ /**
129
+ * The active view's body, and the "nothing selected" sentence.
130
+ *
131
+ * A plugin component renders in the host's tree like any other view, so it needs
132
+ * no workspace folder and no session: it reads whatever the host published and
133
+ * draws what it can. Gating it here would hide a panel that works.
134
+ */
135
+ export function DrawerBody({ panel, body }: { panel?: ResolvedPanel; body: PanelBodyProps }) {
136
+ if (!panel) {
137
+ return (
138
+ <div className="h-full flex items-center justify-center text-ink/40">
139
+ <span className="text-xs font-mono text-muted">No session selected</span>
140
+ </div>
141
+ );
142
+ }
143
+ return (
144
+ <Suspense
145
+ fallback={
146
+ <div className="h-full flex items-center justify-center text-ink/40">
147
+ <span className="text-xs font-mono">Loading…</span>
148
+ </div>
149
+ }
150
+ >
151
+ <PanelHostProvider value={body}>{panel.render(body)}</PanelHostProvider>
152
+ </Suspense>
153
+ );
154
+ }
155
+
156
+ /**
157
+ * The drawer's close control, for the strip's trailing edge.
158
+ *
159
+ * `PanelRight`, NOT `PanelRightClose`: the latter draws a chevron inside the
160
+ * panel (`m8 9 3 3-3 3`), and the arrow reads as "collapse this column" — a
161
+ * second meaning beside a strip whose chips each carry their own `X`. The plain
162
+ * panel mark says what the control acts on and nothing more.
163
+ */
164
+ export function DrawerCloseAction({ onClose }: { onClose: () => void }) {
165
+ return (
166
+ <button
167
+ type="button"
168
+ onClick={onClose}
169
+ /* The SAME box and glyph as every other control in the phone header row:
170
+ a 28px box here sat 4px left of the header's 36px one, which is the
171
+ misalignment a reader sees as a strip that does not line up. */
172
+ className={`${CONTROL_BOX.mobile} flex-none cursor-pointer rounded-lg text-ink/60 transition-colors hover:bg-ink/5 hover:text-ink titlebar-no-drag`}
173
+ title="Tutup panel kanan"
174
+ aria-label="Close right sidebar"
175
+ >
176
+ <PanelRight size={CONTROL_GLYPH_PX.mobile} strokeWidth={1.8} />
177
+ </button>
178
+ );
179
+ }
@@ -112,6 +112,18 @@ async function mountStrip(panels: ResolvedPanel[], activeId: string, onSelect =
112
112
  });
113
113
  }
114
114
 
115
+ describe('PanelChips touch target', () => {
116
+ test('every chip carries the touch floor, active and idle alike', () => {
117
+ // Measured in Chromium at 390px without it: 32x32 idle and 73x28 active —
118
+ // the active chip is the SHORTER one, so a thumb aiming at the view it is
119
+ // already on had the least to hit.
120
+ render(h(PanelChips, { panels: [panel('files'), panel('git')], activeId: 'files', onSelect: () => {} }), container);
121
+ const chips = [...container.querySelectorAll('[aria-pressed]')];
122
+ expect(chips.length).toBe(2);
123
+ for (const chip of chips) expect(chip.className).toContain('tap-chip');
124
+ });
125
+ });
126
+
115
127
  describe('PanelChips', () => {
116
128
  test('draws one chip per panel, in the order it is given', async () => {
117
129
  await mountStrip([panel('sessions'), panel('plugin:demo:rightPanel', { builtin: false, name: 'demo', title: 'Demo — demo' })], 'sessions');
@@ -133,7 +133,11 @@ export function PanelChips({ panels, activeId, onSelect, hasGitChanges = false }
133
133
  // "Resources" after it — a control that renames itself when used is
134
134
  // unusable to a screen reader and unfindable to a spec.
135
135
  aria-label={panel.title}
136
- className={`relative flex shrink-0 items-center transition-all cursor-pointer ${
136
+ /* `tap-chip` is the app's touch floor (44x44 under
137
+ `@media (pointer:coarse)`). Measured without it in Chromium at
138
+ 390px: an idle chip was 32x32 and the ACTIVE one 73x28 — a
139
+ control that is only 28px tall is a control a thumb misses. */
140
+ className={`tap-chip relative flex shrink-0 items-center transition-all cursor-pointer ${
137
141
  active
138
142
  ? 'space-x-1.5 px-3 py-1.5 rounded-lg text-xs font-semibold bg-ink text-canvas shadow-sm'
139
143
  : 'p-2 rounded-lg text-ink/70 hover:bg-ink/5'
@@ -0,0 +1,258 @@
1
+ /**
2
+ * @license
3
+ * SPDX-License-Identifier: MIT
4
+ */
5
+
6
+ /**
7
+ * The phone's right drawer, in each of its two chromes.
8
+ *
9
+ * The drawer used to show EVERY view as a chip, so it opened on eleven chips the
10
+ * user had to read through. `mobileRightPanelNav` adds the desktop's working set
11
+ * to the phone: the strip holds only what was opened, a home page lists the
12
+ * rest, and the drawer reopens where the user left it. `classic` stays the
13
+ * default so an upgrade rearranges nothing.
14
+ *
15
+ * Three properties, and each is what makes the mode honest rather than cosmetic:
16
+ *
17
+ * - the chrome is CHOSEN by the setting, and the other one is absent (not merely
18
+ * hidden) — two strips would be two answers to one question;
19
+ * - the home page appears when nothing is open and disappearing once a card is
20
+ * picked, so a suggestion is not left over the body forever;
21
+ * - closing the last tab returns to the home page instead of a blank drawer.
22
+ */
23
+
24
+ import { afterAll, afterEach, beforeAll, beforeEach, describe, expect, test } from 'bun:test';
25
+ import { Window } from 'happy-dom';
26
+ import { h, render } from 'preact';
27
+ import { act } from 'preact/test-utils';
28
+ import { MobileRightSidebar } from '@/client/components/mobile/RightSidebar';
29
+ import { SessionStateProvider } from '@/client/components/common/session-state-provider/index';
30
+ import { primeKabmoSettings } from '@/shared/lib/settings/client';
31
+ import { resetSessionStateStore } from '@/shared/lib/workspace/session-state/store';
32
+ import { silenceRealtime, restoreRealtime } from '@/test-support/silent-socket';
33
+
34
+ const DOM_GLOBALS = [
35
+ 'window', 'document', 'navigator', 'Node', 'Element', 'HTMLElement',
36
+ 'Event', 'MouseEvent', 'KeyboardEvent',
37
+ ] as const;
38
+ const nativeGlobals: Partial<Record<(typeof DOM_GLOBALS)[number], unknown>> = {};
39
+ const realFetch = globalThis.fetch;
40
+
41
+ let win: Window;
42
+ let container: HTMLElement;
43
+
44
+ beforeAll(() => {
45
+ globalThis.fetch = (async () =>
46
+ new Response(JSON.stringify({ state: {} }), { status: 200 })) as unknown as typeof fetch;
47
+ win = new Window({ url: 'http://localhost' });
48
+ const target = globalThis as unknown as Record<string, unknown>;
49
+ for (const key of DOM_GLOBALS) {
50
+ if (!(key in nativeGlobals)) nativeGlobals[key] = target[key];
51
+ target[key] = (win as unknown as Record<string, unknown>)[key];
52
+ }
53
+ });
54
+
55
+ afterAll(async () => {
56
+ await act(async () => {
57
+ await Bun.sleep(60);
58
+ });
59
+ globalThis.fetch = realFetch;
60
+ const target = globalThis as unknown as Record<string, unknown>;
61
+ for (const key of DOM_GLOBALS) {
62
+ const value = nativeGlobals[key];
63
+ if (value === undefined) delete target[key];
64
+ else target[key] = value;
65
+ }
66
+ });
67
+
68
+ beforeEach(() => {
69
+ silenceRealtime();
70
+ // The store is a module singleton: a close left behind by one test would
71
+ // otherwise seed the next one's drawer.
72
+ resetSessionStateStore();
73
+ container = document.createElement('div');
74
+ document.body.appendChild(container);
75
+ primeKabmoSettings({});
76
+ });
77
+
78
+ afterEach(async () => {
79
+ if (container) {
80
+ await act(() => {
81
+ render(null, container);
82
+ });
83
+ container.remove();
84
+ }
85
+ restoreRealtime();
86
+ });
87
+
88
+ async function mount(style: 'classic' | 'tabs') {
89
+ primeKabmoSettings({ mobileRightPanelNav: style });
90
+ await act(async () => {
91
+ render(
92
+ h(SessionStateProvider, {
93
+ sessionId: 'session-drawer-nav',
94
+ children: h(MobileRightSidebar, {
95
+ enabled: false,
96
+ onClose: () => {},
97
+ }),
98
+ }),
99
+ container,
100
+ );
101
+ });
102
+ // The provider loads its blob and settles its first commit after mount, and
103
+ // the strip renders from the hook's first post-load value: without a drain the
104
+ // assertions read the pre-ready tree.
105
+ await settle();
106
+ }
107
+
108
+ /** Let Preact's deferred commit and the provider's load continuation run. */
109
+ async function settle() {
110
+ await act(async () => {
111
+ await Bun.sleep(40);
112
+ });
113
+ }
114
+
115
+ const stripChips = () =>
116
+ [...container.querySelectorAll('[role="tablist"] [role="tab"]')].map((chip) =>
117
+ chip.textContent?.trim(),
118
+ );
119
+
120
+ describe('the drawer chrome follows the setting', () => {
121
+ test('classic lists views as chips in the header', async () => {
122
+ await mount('classic');
123
+ // `PanelChips` marks its buttons pressed; the tab strip uses roles.
124
+ expect(container.querySelector('[role="tablist"]')).toBeNull();
125
+ expect(container.querySelectorAll('[aria-pressed]').length).toBeGreaterThan(1);
126
+ });
127
+
128
+ test('tabs draws the strip and NO full chip list', async () => {
129
+ await mount('tabs');
130
+ expect(container.querySelector('[role="tablist"]')).not.toBeNull();
131
+ // The header's own chips are gone: the strip is the only list of views.
132
+ expect(container.textContent).not.toContain('Sessions');
133
+ });
134
+ });
135
+
136
+ describe('the home page is the empty state', () => {
137
+ test('nothing open shows the catalog, not a blank body', async () => {
138
+ await mount('tabs');
139
+ expect(container.textContent).toContain('Klik kartu');
140
+ });
141
+
142
+ test('the home page is gone once a view is open', async () => {
143
+ await mount('tabs');
144
+ const card = [...container.querySelectorAll('[aria-pressed]')].find((element) =>
145
+ element.getAttribute('aria-label')?.startsWith('Buka '),
146
+ ) as HTMLElement | undefined;
147
+ expect(card).toBeDefined();
148
+ await act(() => {
149
+ card?.click();
150
+ });
151
+ await settle();
152
+ expect(container.textContent).not.toContain('Klik kartu');
153
+ expect(stripChips().length).toBe(1);
154
+ });
155
+
156
+ test('closing the last tab returns to the catalog', async () => {
157
+ await mount('tabs');
158
+ const card = [...container.querySelectorAll('[aria-pressed]')].find((element) =>
159
+ element.getAttribute('aria-label')?.startsWith('Buka '),
160
+ ) as HTMLElement | undefined;
161
+ await act(() => {
162
+ card?.click();
163
+ });
164
+ await settle();
165
+ const close = container.querySelector('[aria-label^="Tutup tab"]') as HTMLElement;
166
+ expect(close).not.toBeNull();
167
+ await act(() => {
168
+ close.click();
169
+ });
170
+ await settle();
171
+ expect(stripChips().length).toBe(0);
172
+ expect(container.textContent).toContain('Klik kartu');
173
+ });
174
+
175
+ test('classic has no home page at all', async () => {
176
+ await mount('classic');
177
+ expect(container.textContent).not.toContain('Klik kartu');
178
+ });
179
+ });
180
+
181
+ /**
182
+ * A tab the user closed must stay closed, and the next open must not bring it
183
+ * back.
184
+ *
185
+ * `layout.mobileRightPanel` is TWO things at once: the mirror of the strip's
186
+ * selection, and the slot an outside caller writes to ask for a view. Closing a
187
+ * tab writes the neighbour into it, but the mirror (`activeTab`) is one render
188
+ * behind — so the seed effect read the just-closed id as a request and reopened
189
+ * it. That is the reported pair of symptoms: the active tab would not close, and
190
+ * opening a new panel brought the previous one back with it.
191
+ *
192
+ * Both cases are here, and each fails without the drawer marking its own
193
+ * gestures (`ownGesture`).
194
+ */
195
+ describe('closing a tab', () => {
196
+ /** Click a home-page card by its view title. */
197
+ async function openCard(title: string) {
198
+ const card = [...container.querySelectorAll('[aria-label^="Buka "]')].find(
199
+ (element) => element.getAttribute('aria-label') === `Buka ${title}`,
200
+ ) as HTMLElement | undefined;
201
+ expect(card).toBeDefined();
202
+ await act(() => {
203
+ card?.click();
204
+ });
205
+ await settle();
206
+ }
207
+
208
+ /** Re-open the catalog from the strip's add control. */
209
+ async function showCatalog() {
210
+ const add = container.querySelector('[aria-label="Tambah tab"]') as HTMLElement | undefined;
211
+ expect(add).not.toBeNull();
212
+ await act(() => {
213
+ add?.click();
214
+ });
215
+ await settle();
216
+ }
217
+
218
+ /** Two tabs open, the second one on screen. */
219
+ async function openTwoTabs() {
220
+ await mount('tabs');
221
+ await openCard('Files');
222
+ await showCatalog();
223
+ await openCard('Source Control');
224
+ expect(stripChips().length).toBe(2);
225
+ }
226
+
227
+ test('closing the ACTIVE tab removes it', async () => {
228
+ await openTwoTabs();
229
+ // The chip states the view's LABEL, and the close control is named after it.
230
+ const active = stripChips()[1] ?? '';
231
+ const close = container.querySelector(`[aria-label="Tutup tab ${active}"]`) as
232
+ | HTMLElement
233
+ | null;
234
+ expect(close).not.toBeNull();
235
+ await act(() => {
236
+ close?.click();
237
+ });
238
+ await settle();
239
+ expect(stripChips()).toEqual(['Files']);
240
+ });
241
+
242
+ test('a closed tab does not reopen when the next one is opened', async () => {
243
+ await openTwoTabs();
244
+ const active = stripChips()[1] ?? '';
245
+ const close = container.querySelector(`[aria-label="Tutup tab ${active}"]`) as
246
+ | HTMLElement
247
+ | null;
248
+ await act(() => {
249
+ close?.click();
250
+ });
251
+ await settle();
252
+
253
+ // The report's second half: opening another view must not resurrect it.
254
+ await showCatalog();
255
+ await openCard('Search');
256
+ expect(stripChips()).toEqual(['Files', 'Search']);
257
+ });
258
+ });
@@ -34,6 +34,7 @@ import { applyToolRenderMode } from '@/client/hooks/chat/timeline/tool-render-mo
34
34
  import { applyShowChangedFiles } from '@/client/hooks/chat/timeline/changed-files-setting';
35
35
  import { applySidebarStyle } from '@/client/hooks/workspace/sidebar-style';
36
36
  import { applyPanelNav } from '@/client/hooks/workspace/panel-nav';
37
+ import { applyMobileRightPanelNav } from '@/client/hooks/workspace/mobile-right-panel-nav';
37
38
  import { applyComposerStyle } from '@/client/hooks/chat/composer/style';
38
39
  import { applySurfaceStyle } from '@/client/hooks/ui/surface-style';
39
40
  import { applyBorderStyle } from '@/client/hooks/ui/border-style';
@@ -104,6 +105,11 @@ export function applySettingsSideEffects(previous: SettingsState, next: Settings
104
105
  if (next.rightPanelNav !== previous.rightPanelNav) {
105
106
  applyPanelNav('right', next.rightPanelNav);
106
107
  }
108
+ // The phone's drawer is its own screen and may not be mounted behind the
109
+ // modal, so this event is what keeps a mounted one honest.
110
+ if (next.mobileRightPanelNav !== previous.mobileRightPanelNav) {
111
+ applyMobileRightPanelNav(next.mobileRightPanelNav);
112
+ }
107
113
 
108
114
  // The composer style reorders the card's rows. The composer is NOT visible
109
115
  // behind the settings modal, so this only has to keep the next render