@kabmo-labs/kabmo 0.60.0 → 0.62.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 (506) hide show
  1. package/README.md +53 -49
  2. package/dist/client/index.html +1 -1
  3. package/dist/client/index.js +1157 -825
  4. package/dist/client/static/js/{Body-p82s28sj.js → Body-z6kstvk6.js} +3 -3
  5. package/dist/client/static/js/{CsvGrid-erc5mcvc.js → CsvGrid-f73c0s4e.js} +2 -2
  6. package/dist/client/static/js/{DocxView-x3faj0jv.js → DocxView-a1pb7nsb.js} +3 -3
  7. package/dist/client/static/js/{DrawioView-t7fh3ens.js → DrawioView-r61gcg24.js} +2 -2
  8. package/dist/client/static/js/{HtmlPreview-zy7x7jmm.js → HtmlPreview-vt7j0b05.js} +1 -1
  9. package/dist/client/static/js/ImageView-4nhr5dtm.js +1 -0
  10. package/dist/client/static/js/LayoutWrapper-vwhy0vhj.js +2 -0
  11. package/dist/client/static/js/MergeDiffView-f4h9ss71.js +1 -0
  12. package/dist/client/static/js/Modal-cadmjkak.js +60 -0
  13. package/dist/client/static/js/{PdfView-kqx472q7.js → PdfView-mppt2gkd.js} +1 -1
  14. package/dist/client/static/js/SessionsView-vvsaw9f0.js +1 -0
  15. package/dist/client/static/js/{SheetView-0n9fze50.js → SheetView-5s9zfx9g.js} +9 -9
  16. package/dist/client/static/js/{SvgPreview-6xc6ts46.js → SvgPreview-ff78xn3e.js} +1 -1
  17. package/dist/client/static/js/{abnfDiagram-O67JEVCF-2xdkkqwg.js → abnfDiagram-O67JEVCF-p29sh3w2.js} +1 -1
  18. package/dist/client/static/js/architecture-7GRP2DOG-83w3kytq.js +1 -0
  19. package/dist/client/static/js/{architectureDiagram-NJMV4G6O-ja8cx19z.js → architectureDiagram-NJMV4G6O-nbpdyea3.js} +3 -3
  20. package/dist/client/static/js/{astro-yphdvdty.js → astro-qtfmc8x7.js} +1 -1
  21. package/dist/client/static/js/bash-wcy12qjx.js +1 -0
  22. package/dist/client/static/js/{blockDiagram-BEXU5L5S-ytf7s99c.js → blockDiagram-BEXU5L5S-t8xbexa6.js} +6 -6
  23. package/dist/client/static/js/c-vvantfth.js +1 -0
  24. package/dist/client/static/js/{c4Diagram-YGBWAQC7-5a0kdx0z.js → c4Diagram-YGBWAQC7-9fwf2zxk.js} +3 -3
  25. package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-hd98dvjw.js → classDiagram-v2-NBCMYWYE-nbapgqbs.js} +4 -4
  26. package/dist/client/static/js/{cose-bilkent-JH36ORCC-man3fqcj.js → cose-bilkent-JH36ORCC-k54mmydp.js} +1 -1
  27. package/dist/client/static/js/cpp-5x63r6g0.js +1 -0
  28. package/dist/client/static/js/css-j2j6f03w.js +1 -0
  29. package/dist/client/static/js/css-qk59j6rj.js +1 -0
  30. package/dist/client/static/js/cynefin-OW5HDTMX-80z02zrj.js +1 -0
  31. package/dist/client/static/js/{cynefinDiagram-VND7K2PF-2f0kbbv2.js → cynefinDiagram-VND7K2PF-qdg32wah.js} +1 -1
  32. package/dist/client/static/js/{dagre-6A5THRUB-k7pyhgzn.js → dagre-6A5THRUB-qzshg1vs.js} +2 -2
  33. package/dist/client/static/js/{diagram-22UHCM2B-qx0afa2m.js → diagram-22UHCM2B-197hemfa.js} +11 -11
  34. package/dist/client/static/js/{diagram-3UASUU5V-ydpe77sv.js → diagram-3UASUU5V-236gnjr6.js} +1 -1
  35. package/dist/client/static/js/{diagram-ATOU4E4O-e63v984n.js → diagram-ATOU4E4O-vjgpyaaq.js} +3 -3
  36. package/dist/client/static/js/{diagram-CDSNMT55-8c765h3a.js → diagram-CDSNMT55-ywvzcx7z.js} +4 -4
  37. package/dist/client/static/js/{diagram-MLGK6HIB-3pq0n7v8.js → diagram-MLGK6HIB-9ey7ev7j.js} +1 -1
  38. package/dist/client/static/js/{diagram-MPIPVDR6-638atzxz.js → diagram-MPIPVDR6-vrqbb6r7.js} +2 -2
  39. package/dist/client/static/js/{dockerfile-yehc914q.js → dockerfile-4nked309.js} +1 -1
  40. package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-3gv43zvm.js → ebnfDiagram-ZINNZB2B-hvnkevqy.js} +1 -1
  41. package/dist/client/static/js/{elixir-3nwnd9yw.js → elixir-3jvh6v4k.js} +1 -1
  42. package/dist/client/static/js/{elk-276RUBZZ-6s5pggfc.js → elk-276RUBZZ-nej6yy1c.js} +1 -1
  43. package/dist/client/static/js/{erDiagram-OPXOYQCR-x7cqyb89.js → erDiagram-OPXOYQCR-ww453xcy.js} +5 -5
  44. package/dist/client/static/js/{erlang-p5c4n3t0.js → erlang-4fz73a1q.js} +1 -1
  45. package/dist/client/static/js/eventmodeling-NTZA5JFV-y9pq2709.js +1 -0
  46. package/dist/client/static/js/flowDiagram-KWPJA3E3-e6v7513q.js +1 -0
  47. package/dist/client/static/js/{ganttDiagram-FUAMR5RP-g97te4v1.js → ganttDiagram-FUAMR5RP-abc5wy70.js} +3 -3
  48. package/dist/client/static/js/gitGraph-4MIJSDKK-fzaf9azs.js +1 -0
  49. package/dist/client/static/js/{gitGraphDiagram-X574FWY7-sw4f94tc.js → gitGraphDiagram-X574FWY7-4acqzj2h.js} +7 -7
  50. package/dist/client/static/js/graphql-hpkvdvk7.js +1 -0
  51. package/dist/client/static/js/html-x12gb1wk.js +1 -0
  52. package/dist/client/static/js/{index-v88m5sva.js → index-0g82ph6h.js} +2 -2
  53. package/dist/client/static/js/{index-vejz38qt.js → index-0w1jzang.js} +5 -5
  54. package/dist/client/static/js/{index-bpcg34jp.js → index-1svt0cdw.js} +2 -2
  55. package/dist/client/static/js/{index-hgfyx8dt.js → index-1tb4py5v.js} +2 -2
  56. package/dist/client/static/js/index-2gt9krtj.js +4 -0
  57. package/dist/client/static/js/index-2x9m7s1a.js +1 -0
  58. package/dist/client/static/js/index-3fvqmz3m.js +4 -0
  59. package/dist/client/static/js/{index-pdz6j2g2.js → index-42wvbkm5.js} +2 -2
  60. package/dist/client/static/js/index-477vtt51.js +2 -0
  61. package/dist/client/static/js/{index-ca6tmamh.js → index-4px56qaz.js} +2 -2
  62. package/dist/client/static/js/{index-excgtjhx.js → index-5anvw7xg.js} +36 -36
  63. package/dist/client/static/js/index-5nb9k2ph.js +1 -0
  64. package/dist/client/static/js/{index-97sw4d9n.js → index-615je3km.js} +2 -2
  65. package/dist/client/static/js/{index-111bq6rs.js → index-66qxrh5n.js} +1 -1
  66. package/dist/client/static/js/{index-a145x0w2.js → index-7kct1sz1.js} +2 -2
  67. package/dist/client/static/js/{index-hwv7bfxc.js → index-8e0d8y30.js} +2 -2
  68. package/dist/client/static/js/{index-s4j2ghmx.js → index-90bq56xw.js} +2 -2
  69. package/dist/client/static/js/{index-wsy6y5em.js → index-b1gzh60t.js} +11 -11
  70. package/dist/client/static/js/{index-10vzyga1.js → index-bypkmjrz.js} +2 -2
  71. package/dist/client/static/js/{index-n8r7r86r.js → index-c1vd63yd.js} +2 -2
  72. package/dist/client/static/js/index-c9f0hejv.js +3 -0
  73. package/dist/client/static/js/{index-2dmew334.js → index-cgqj15g0.js} +2 -2
  74. package/dist/client/static/js/{index-mtav0rpf.js → index-cts5re1t.js} +2 -2
  75. package/dist/client/static/js/index-dxc14kmm.js +1 -0
  76. package/dist/client/static/js/{index-hwdkxe4n.js → index-dxyjxhm1.js} +2 -2
  77. package/dist/client/static/js/{index-43gmn7yb.js → index-edpyqz9f.js} +1 -1
  78. package/dist/client/static/js/{index-pdgc9ccr.js → index-eesepb70.js} +2 -2
  79. package/dist/client/static/js/{index-vec7m1yd.js → index-evh437bz.js} +2 -2
  80. package/dist/client/static/js/index-ey6v4t5b.js +1 -0
  81. package/dist/client/static/js/{index-025s3fp8.js → index-fsd7n336.js} +2 -2
  82. package/dist/client/static/js/{index-yfcy4cf6.js → index-h7a7fqag.js} +2 -2
  83. package/dist/client/static/js/{index-11qn05g9.js → index-hffgwnvz.js} +2 -2
  84. package/dist/client/static/js/index-j734ev6q.js +482 -0
  85. package/dist/client/static/js/{index-vcq6zfxx.js → index-jcbp1d9d.js} +6 -6
  86. package/dist/client/static/js/index-jg5h18sm.js +2 -0
  87. package/dist/client/static/js/{index-6qn9kygb.js → index-jtdve6xw.js} +7 -7
  88. package/dist/client/static/js/{index-4xbc0j7t.js → index-k0bqrb1y.js} +1 -1
  89. package/dist/client/static/js/{index-bdtftrym.js → index-kegevd10.js} +2 -2
  90. package/dist/client/static/js/{index-fr6wsqk8.js → index-kqcfxkch.js} +2 -2
  91. package/dist/client/static/js/{index-2n2evsg0.js → index-kv1xnem9.js} +2 -2
  92. package/dist/client/static/js/{index-8zct30zd.js → index-m54ctmxr.js} +1 -1
  93. package/dist/client/static/js/index-mgzbypt5.js +314 -0
  94. package/dist/client/static/js/{index-cf69bhjx.js → index-mh52531j.js} +2 -2
  95. package/dist/client/static/js/{index-0ze5bwvw.js → index-mhz5ywa4.js} +5 -5
  96. package/dist/client/static/js/{index-3j2he86h.js → index-nnwdbg3t.js} +2 -2
  97. package/dist/client/static/js/{index-9rz6kzsv.js → index-nxd6z7f9.js} +2 -2
  98. package/dist/client/static/js/{index-jfqd838j.js → index-pjrbt77c.js} +2 -2
  99. package/dist/client/static/js/index-r7h4pm42.js +2 -0
  100. package/dist/client/static/js/index-ratrdgc9.js +2 -0
  101. package/dist/client/static/js/{index-cfvc1zpk.js → index-rhmvh9w5.js} +2 -2
  102. package/dist/client/static/js/{index-twwsn91p.js → index-sqzjwy9h.js} +2 -2
  103. package/dist/client/static/js/{index-37apvxgj.js → index-tckzkw0f.js} +2 -2
  104. package/dist/client/static/js/index-tza9h3q6.css +1 -0
  105. package/dist/client/static/js/{index-qccydkze.js → index-vhjfr093.js} +2 -2
  106. package/dist/client/static/js/{index-z8k42dwz.js → index-w0j96eyy.js} +8 -8
  107. package/dist/client/static/js/{index-qkqkygrf.js → index-ws04kxy9.js} +1 -1
  108. package/dist/client/static/js/{index-a3bpmw2r.js → index-x1yqmzpr.js} +2 -2
  109. package/dist/client/static/js/{index-fb2fjndj.js → index-x2f7wykb.js} +6 -6
  110. package/dist/client/static/js/index-y8405hdg.js +10 -0
  111. package/dist/client/static/js/{index-sx83ans2.js → index-yxk7dgnb.js} +2 -2
  112. package/dist/client/static/js/{index-bkn6jtn1.js → index-zavecxak.js} +2 -2
  113. package/dist/client/static/js/{index-dv01prse.js → index-zg7q3kcb.js} +2 -2
  114. package/dist/client/static/js/{index-enm77k5z.js → index-zhn9vv3z.js} +2 -2
  115. package/dist/client/static/js/{index-ywp0sd1e.js → index-zy963qbh.js} +1 -1
  116. package/dist/client/static/js/info-A6RAGUB7-t7pbg7rt.js +1 -0
  117. package/dist/client/static/js/{infoDiagram-VRGFBTTK-pw2qaa27.js → infoDiagram-VRGFBTTK-9pe7w3r5.js} +2 -2
  118. package/dist/client/static/js/ini-522adp5a.js +1 -0
  119. package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-d13jhvxy.js → ishikawaDiagram-OU5B5YK6-38arfrx5.js} +2 -2
  120. package/dist/client/static/js/java-z0rgs7v6.js +1 -0
  121. package/dist/client/static/js/javascript-fv87f565.js +1 -0
  122. package/dist/client/static/js/{journeyDiagram-ZHPQQLJL-20gb8a04.js → journeyDiagram-ZHPQQLJL-kcwzjgtz.js} +4 -4
  123. package/dist/client/static/js/json-1czq1ped.js +1 -0
  124. package/dist/client/static/js/jsx-1fch2jyr.js +1 -0
  125. package/dist/client/static/js/{julia-rpd1y9vh.js → julia-pzzxbptm.js} +1 -1
  126. package/dist/client/static/js/{kanban-definition-PNTS6WVX-s78e158c.js → kanban-definition-PNTS6WVX-nmegwy9w.js} +15 -15
  127. package/dist/client/static/js/lua-nn8bpjev.js +1 -0
  128. package/dist/client/static/js/markdown-38tqrgkn.js +1 -0
  129. package/dist/client/static/js/{mermaid.core-xbm27k28.js → mermaid.core-3aae27b9.js} +7 -7
  130. package/dist/client/static/js/{mindmap-definition-NLK3R4M7-6y7xe2zm.js → mindmap-definition-NLK3R4M7-zsaq4e65.js} +12 -12
  131. package/dist/client/static/js/one-dark-pro-trnff03z.js +1 -0
  132. package/dist/client/static/js/one-light-ck31ptqs.js +1 -0
  133. package/dist/client/static/js/packet-AYTQ26CC-rwac7scq.js +1 -0
  134. package/dist/client/static/js/{pegDiagram-GJSIUBJH-dmvewetf.js → pegDiagram-GJSIUBJH-2b6whj1p.js} +1 -1
  135. package/dist/client/static/js/{perl-kmtz9dnv.js → perl-zdkbbjd2.js} +1 -1
  136. package/dist/client/static/js/{php-bttrsbxy.js → php-ktaxff6g.js} +1 -1
  137. package/dist/client/static/js/pie-WAS4IAKB-gjz20apz.js +1 -0
  138. package/dist/client/static/js/{pieDiagram-5QR66LMP-1q9e7rcm.js → pieDiagram-5QR66LMP-y09ar7vz.js} +3 -3
  139. package/dist/client/static/js/properties-kncqeqhn.js +1 -0
  140. package/dist/client/static/js/python-gx8ggmyh.js +1 -0
  141. package/dist/client/static/js/{quadrantDiagram-O4NWA36T-mvrem3n6.js → quadrantDiagram-O4NWA36T-mapfzs06.js} +3 -3
  142. package/dist/client/static/js/r-x8rftkm3.js +1 -0
  143. package/dist/client/static/js/radar-RG4KPBEZ-akwdknab.js +1 -0
  144. package/dist/client/static/js/railroad-74A4TZTK-m5v4rfhx.js +1 -0
  145. package/dist/client/static/js/railroad-abnf-HS5TGJTU-k2gmqcjb.js +1 -0
  146. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-1zdsfjf4.js +1 -0
  147. package/dist/client/static/js/railroad-peg-WCYAUIDC-e98evqb6.js +1 -0
  148. package/dist/client/static/js/{railroadDiagram-XR7U4H2S-axttcfhw.js → railroadDiagram-XR7U4H2S-70qy7qdh.js} +1 -1
  149. package/dist/client/static/js/{requirementDiagram-PLB6GJNP-5qx7erta.js → requirementDiagram-PLB6GJNP-2vb2gp3e.js} +3 -3
  150. package/dist/client/static/js/{ruby-dve3y59w.js → ruby-ytqv3pqz.js} +1 -1
  151. package/dist/client/static/js/{rust-b3ckax3e.js → rust-6sddyxnt.js} +1 -1
  152. package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-es87a3j6.js → sankeyDiagram-IPEJSGJF-9jd8ebrn.js} +3 -3
  153. package/dist/client/static/js/{sass-emxqt5p2.js → sass-dvbra5b6.js} +1 -1
  154. package/dist/client/static/js/{scss-4j4t3r6y.js → scss-sy7w8916.js} +1 -1
  155. package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-dgpnjrtk.js → sequenceDiagram-PO4LG4MO-w7z84f80.js} +7 -7
  156. package/dist/client/static/js/{sizeCapture-INFHLROL-kyw0p86n.js → sizeCapture-INFHLROL-q8w7ehgx.js} +1 -1
  157. package/dist/client/static/js/sql-99y0qnag.js +1 -0
  158. package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-vnsbw8y9.js → stateDiagram-v2-GCMORJYK-4978hapr.js} +3 -3
  159. package/dist/client/static/js/{svelte-dbsx1ehx.js → svelte-xvs3fkza.js} +1 -1
  160. package/dist/client/static/js/{swimlanes-2SLR337P-060q1rep.js → swimlanes-2SLR337P-eshg5fjy.js} +1 -1
  161. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-914e28hd.js +8 -0
  162. package/dist/client/static/js/timeline-definition-EJHVYXUP-5h5q357k.js +120 -0
  163. package/dist/client/static/js/treeView-Q6P3EWNA-fkm3a7gx.js +1 -0
  164. package/dist/client/static/js/treemap-WGGIJYW6-hm4ktxjf.js +1 -0
  165. package/dist/client/static/js/tsx-phngprp0.js +1 -0
  166. package/dist/client/static/js/typescript-m62a7zr2.js +1 -0
  167. package/dist/client/static/js/{usecaseDiagram-POWQR4AR-18sp73v7.js → usecaseDiagram-POWQR4AR-4j69y3zx.js} +20 -20
  168. package/dist/client/static/js/vennDiagram-UO4OBE2U-pa9p5jpw.js +34 -0
  169. package/dist/client/static/js/{vue-hyr58df9.js → vue-p4g4avm3.js} +1 -1
  170. package/dist/client/static/js/wardley-WFR3VGLG-3y2rvdmy.js +1 -0
  171. package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-q0kwmbzh.js → wardleyDiagram-VNRHLVJA-hjddd656.js} +3 -3
  172. package/dist/client/static/js/xml-59n0cjn6.js +1 -0
  173. package/dist/client/static/js/{xychartDiagram-PMCCYNJV-y0gpmg6m.js → xychartDiagram-PMCCYNJV-8ng5m849.js} +4 -4
  174. package/dist/client/static/js/yaml-9fw908s4.js +1 -0
  175. package/dist/client/tailwindcss-oxide.linux-x64-gnu-c0fa36dv.node +0 -0
  176. package/dist/client/tailwindcss-oxide.linux-x64-musl-kr04sh0e.node +0 -0
  177. package/marketplace/plugins/command-runner/package.json +2 -2
  178. package/marketplace/plugins/command-runner/src/app.tsx +2 -5
  179. package/marketplace/plugins/command-runner/src/panel/CustomForm.tsx +35 -52
  180. package/marketplace/plugins/command-runner/src/panel/Groups.tsx +6 -5
  181. package/marketplace/plugins/command-runner/src/panel/Header.tsx +18 -54
  182. package/marketplace/plugins/command-runner/src/panel/Output.tsx +3 -7
  183. package/marketplace/plugins/command-runner/src/panel/Row.tsx +19 -38
  184. package/marketplace/plugins/command-runner/src/panel/index.tsx +1 -4
  185. package/marketplace/plugins/git-forge/package.json +2 -2
  186. package/marketplace/plugins/git-forge/src/app.tsx +2 -0
  187. package/marketplace/plugins/git-forge/src/panel/Credential.tsx +8 -15
  188. package/marketplace/plugins/git-forge/src/panel/Header.tsx +35 -66
  189. package/marketplace/plugins/git-forge/src/panel/ItemView.tsx +7 -13
  190. package/marketplace/plugins/git-forge/src/panel/List.tsx +28 -56
  191. package/marketplace/plugins/git-forge/src/panel/Row.tsx +7 -9
  192. package/marketplace/plugins/git-forge/src/panel/Sidebar.tsx +21 -31
  193. package/marketplace/plugins/git-forge/src/panel/Write.tsx +26 -40
  194. package/marketplace/plugins/git-forge/src/panel/index.tsx +0 -1
  195. package/marketplace/plugins/github-actions/package.json +2 -2
  196. package/marketplace/plugins/github-actions/src/app.tsx +2 -0
  197. package/marketplace/plugins/github-actions/src/panel/Actions.tsx +9 -17
  198. package/marketplace/plugins/github-actions/src/panel/LogView.tsx +4 -13
  199. package/marketplace/plugins/github-actions/src/panel/Row.tsx +4 -5
  200. package/marketplace/plugins/github-actions/src/panel/RunView.tsx +8 -15
  201. package/marketplace/plugins/github-actions/src/panel/index.test.tsx +3 -2
  202. package/marketplace/plugins/github-actions/src/panel/index.tsx +31 -37
  203. package/marketplace/plugins/kanban/package.json +2 -2
  204. package/marketplace/plugins/kanban/src/app.tsx +2 -0
  205. package/marketplace/plugins/kanban/src/panel/CardSheet.tsx +88 -98
  206. package/marketplace/plugins/kanban/src/panel/CardTile.tsx +6 -10
  207. package/marketplace/plugins/kanban/src/panel/StageColumn.tsx +22 -18
  208. package/marketplace/plugins/kanban/src/panel/StageSheet.tsx +59 -70
  209. package/marketplace/plugins/kanban/src/panel/index.tsx +37 -52
  210. package/marketplace/plugins/kanban/src/panel/use-board.ts +2 -0
  211. package/marketplace/plugins/session-info/package.json +2 -2
  212. package/marketplace/plugins/session-info/src/app.tsx +6 -3
  213. package/marketplace/plugins/stats/package.json +2 -2
  214. package/marketplace/plugins/stats/src/KillConfirm.test.tsx +6 -4
  215. package/marketplace/plugins/stats/src/KillConfirm.tsx +26 -76
  216. package/marketplace/plugins/stats/src/ProcessTable.tsx +8 -6
  217. package/marketplace/plugins/stats/src/RefreshButton.tsx +7 -5
  218. package/marketplace/plugins/stats/src/app.tsx +11 -9
  219. package/package.json +10 -10
  220. package/src/cli/lib/commands/plugin.js +8 -5
  221. package/src/client/bootstrap.d.ts +5 -0
  222. package/src/client/chat-title-overlay.test.ts +53 -0
  223. package/src/client/components/auth/login-screen/index.tsx +31 -3
  224. package/src/client/components/common/SignOutButton.tsx +4 -5
  225. package/src/client/components/common/account-badge/index.tsx +31 -0
  226. package/src/client/components/common/footer-version/index.tsx +40 -0
  227. package/src/client/components/common/fullscreen-viewer/fullscreen-viewer.test.tsx +24 -0
  228. package/src/client/components/common/fullscreen-viewer/index.tsx +22 -31
  229. package/src/client/components/common/header-controls/MoreMenu.tsx +5 -56
  230. package/src/client/components/common/header-controls/index.test.tsx +2 -6
  231. package/src/client/components/common/header-controls/index.tsx +9 -25
  232. package/src/client/components/common/header-controls/phone-row.test.tsx +3 -16
  233. package/src/client/components/common/shell-update-button/index.tsx +2 -2
  234. package/src/client/components/common/zoom-pan-stage/index.tsx +54 -50
  235. package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +4 -5
  236. package/src/client/components/layout/desktop-layout/index.tsx +2 -4
  237. package/src/client/components/layout/left-bar/index.tsx +25 -3
  238. package/src/client/components/layout/rail-toggle.test.tsx +112 -0
  239. package/src/client/components/layout/session-sidebar/CategoryHeader.accent.test.tsx +81 -0
  240. package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +11 -3
  241. package/src/client/components/layout/session-sidebar/Footer.test.tsx +36 -0
  242. package/src/client/components/layout/session-sidebar/Footer.tsx +42 -61
  243. package/src/client/components/layout/session-sidebar/FooterHost.tsx +5 -1
  244. package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +30 -10
  245. package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +4 -0
  246. package/src/client/components/layout/session-sidebar/modern/index.tsx +8 -1
  247. package/src/client/components/layout/session-sidebar/modern/workspace-header.test.tsx +25 -4
  248. package/src/client/components/layout/session-title-bar/index.tsx +13 -5
  249. package/src/client/components/layout/top-bars.test.tsx +4 -2
  250. package/src/client/components/mobile/LayoutWrapper.tsx +3 -1
  251. package/src/client/components/mobile/RightSidebar.tsx +12 -3
  252. package/src/client/components/mobile/SessionSidebar.tsx +6 -2
  253. package/src/client/components/mobile/drawer-layout.test.tsx +7 -3
  254. package/src/client/components/mobile/drawer-strip.tsx +9 -2
  255. package/src/client/components/mobile/mobile-main-view/Header.test.tsx +29 -9
  256. package/src/client/components/mobile/mobile-main-view/Header.tsx +43 -12
  257. package/src/client/components/mobile/mobile-right-sidebar/Chrome.tsx +12 -1
  258. package/src/client/components/mobile/mobile-right-sidebar/FullDiff.tsx +9 -2
  259. package/src/client/components/mobile/mobile-right-sidebar/FullEditor.tsx +1 -0
  260. package/src/client/components/mobile/mobile-right-sidebar/Header.tsx +9 -1
  261. package/src/client/components/mobile/mobile-right-sidebar/StatusBar.tsx +4 -2
  262. package/src/client/components/mobile/mobile-session-sidebar/Body.tsx +1 -1
  263. package/src/client/components/mobile/mobile-session-sidebar/Footer.tsx +48 -46
  264. package/src/client/components/mobile/mobile-session-sidebar/Header.tsx +18 -1
  265. package/src/client/components/mobile/mobile-session-sidebar/Item.test.tsx +4 -0
  266. package/src/client/components/mobile/mobile-session-sidebar/Item.tsx +4 -6
  267. package/src/client/components/mobile/right-drawer-nav.test.tsx +53 -1
  268. package/src/client/components/settings/Band.tsx +5 -2
  269. package/src/client/components/settings/Modal.tsx +8 -5
  270. package/src/client/components/settings/Sidebar.tsx +5 -3
  271. package/src/client/components/settings/apply-side-effects.ts +5 -0
  272. package/src/client/components/settings/categories/AccountSettings.tsx +266 -0
  273. package/src/client/components/settings/categories/ProjectSettings.tsx +2 -0
  274. package/src/client/components/settings/categories/account-settings/Dialogs.tsx +223 -0
  275. package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.test.tsx +3 -4
  276. package/src/client/components/settings/categories/appearance-settings/ChromeStyleSection.tsx +66 -39
  277. package/src/client/components/settings/categories/connect-settings/DeviceTable.tsx +7 -4
  278. package/src/client/components/settings/categories/project-settings/DetailsForm.tsx +14 -1
  279. package/src/client/components/settings/categories/project-settings/ProjectSharing.tsx +130 -0
  280. package/src/client/components/settings/categories/project-settings/SidebarList.tsx +5 -0
  281. package/src/client/components/settings/category-content.tsx +3 -0
  282. package/src/client/components/workspace/chat-timeline/AiMessageFooterSheet.tsx +3 -1
  283. package/src/client/components/workspace/chat-timeline/ComposerDockFrame.tsx +2 -1
  284. package/src/client/components/workspace/chat-timeline/EmptyWorkspacePrompt.tsx +3 -1
  285. package/src/client/components/workspace/chat-timeline/SessionSkeleton.tsx +1 -1
  286. package/src/client/components/workspace/chat-timeline/TimelineBody.tsx +1 -0
  287. package/src/client/components/workspace/chat-timeline/chat-input/ComposerRows.tsx +9 -2
  288. package/src/client/components/workspace/chat-timeline/chat-input/expansion.test.ts +1 -1
  289. package/src/client/components/workspace/chat-timeline/chat-input/expansion.ts +2 -1
  290. package/src/client/components/workspace/chat-timeline/chat-input/narrow.test.tsx +34 -0
  291. package/src/client/components/workspace/chat-timeline/composer-dock-frame.test.tsx +9 -0
  292. package/src/client/components/workspace/chat-timeline/tool-renderers/styles/styles.test.tsx +4 -1
  293. package/src/client/components/workspace/editor/Tab.tsx +19 -26
  294. package/src/client/components/workspace/editor/Tabs.test.ts +13 -7
  295. package/src/client/components/workspace/git-panel/commit-modal/Header.tsx +1 -0
  296. package/src/client/components/workspace/git-panel/commit-modal/floating.test.ts +46 -0
  297. package/src/client/components/workspace/git-panel/commit-modal/index.tsx +2 -0
  298. package/src/client/components/workspace/model-dropdown/Fullscreen.tsx +4 -5
  299. package/src/client/components/workspace/panel-tabs/TabChip.tsx +40 -37
  300. package/src/client/components/workspace/panel-tabs/TabStrip.connected.test.tsx +76 -49
  301. package/src/client/components/workspace/panel-tabs/TabStrip.test.tsx +9 -9
  302. package/src/client/components/workspace/panel-tabs/TabStrip.tsx +14 -1
  303. package/src/client/components/workspace/panel-tabs/index.tsx +1 -1
  304. package/src/client/components/workspace/plugin-panel/catalog.tsx +22 -5
  305. package/src/client/components/workspace/plugin-panel/chrome.test.tsx +89 -0
  306. package/src/client/components/workspace/plugin-panel/chrome.tsx +62 -0
  307. package/src/client/data/settings/omp-schema.json +40 -4
  308. package/src/client/floating-phone.test.ts +189 -0
  309. package/src/client/floating.css +205 -2
  310. package/src/client/floating.test.ts +43 -0
  311. package/src/client/glass.css +47 -0
  312. package/src/client/hooks/chat/omp/index.ts +6 -5
  313. package/src/client/hooks/chat/omp/prompt-send.test.ts +18 -0
  314. package/src/client/hooks/chat/omp/prompt-send.ts +26 -8
  315. package/src/client/hooks/chat/omp/session-list.tsx +20 -8
  316. package/src/client/hooks/chat/timeline/deferred-model.ts +13 -5
  317. package/src/client/hooks/chat/timeline/index.ts +2 -0
  318. package/src/client/hooks/chat/timeline/send-props.ts +14 -0
  319. package/src/client/hooks/chat/timeline/send-steer.test.ts +11 -2
  320. package/src/client/hooks/chat/timeline/send-switch.test.ts +92 -0
  321. package/src/client/hooks/chat/timeline/send.test-util.ts +37 -7
  322. package/src/client/hooks/chat/timeline/send.test.ts +11 -2
  323. package/src/client/hooks/chat/timeline/send.ts +62 -42
  324. package/src/client/hooks/editor/image-generation.ts +24 -0
  325. package/src/client/hooks/editor/resolve-viewer.test.ts +26 -20
  326. package/src/client/hooks/editor/resolve-viewer.ts +14 -5
  327. package/src/client/hooks/editor/use-file-editor.test.ts +34 -0
  328. package/src/client/hooks/editor/use-file-editor.ts +6 -2
  329. package/src/client/hooks/settings/accounts.ts +162 -0
  330. package/src/client/hooks/ui/auth.ts +58 -3
  331. package/src/client/hooks/ui/border-style.test.ts +5 -4
  332. package/src/client/hooks/ui/border-style.ts +3 -2
  333. package/src/client/hooks/ui/mobile-chrome-style.ts +68 -0
  334. package/src/client/hooks/ui/navbar-controls.test.ts +1 -2
  335. package/src/client/hooks/ui/navbar-controls.ts +0 -3
  336. package/src/client/hooks/ui/zoom-gesture.ts +104 -0
  337. package/src/client/lib/desktop/titlebar.test.ts +21 -0
  338. package/src/client/lib/desktop/titlebar.ts +34 -0
  339. package/src/client/lib/plugins/bootstrap.test.ts +20 -0
  340. package/src/client/lib/plugins/bootstrap.tsx +10 -15
  341. package/src/client/lib/plugins/kit-components.test.tsx +119 -0
  342. package/src/client/lib/plugins/kit-components.tsx +79 -0
  343. package/src/client/lib/plugins/kit.ts +8 -0
  344. package/src/client/lib/plugins/slots.test.ts +34 -0
  345. package/src/client/lib/plugins/slots.ts +31 -4
  346. package/src/client/lib/plugins/stylesheets.ts +10 -11
  347. package/src/client/lib/ui/pinch.test.ts +74 -0
  348. package/src/client/lib/ui/pinch.ts +104 -0
  349. package/src/client/lib/ui/safe-area.test.ts +25 -0
  350. package/src/client/lib/ui/safe-area.ts +23 -0
  351. package/src/client/main.tsx +8 -1
  352. package/src/client/tailwind.css +54 -1
  353. package/src/server/index.ts +2 -0
  354. package/src/server/lib/assets/shell-attributes.server.ts +12 -4
  355. package/src/server/lib/assets/shell-attributes.test.ts +19 -18
  356. package/src/server/lib/auth/client-address.test.ts +2 -2
  357. package/src/server/lib/auth/guard.test.ts +2 -2
  358. package/src/server/lib/auth/guard.ts +81 -97
  359. package/src/server/lib/auth/handover-guard.test.ts +1 -1
  360. package/src/server/lib/auth/rate-limit.test.ts +2 -2
  361. package/src/server/lib/auth/token.test.ts +1 -1
  362. package/src/server/lib/auth/workspace-gate.server.ts +34 -0
  363. package/src/server/lib/bundler/css.test.ts +16 -0
  364. package/src/server/lib/connect/devices.server.test.ts +12 -0
  365. package/src/server/lib/connect/devices.server.ts +63 -19
  366. package/src/server/lib/connect/pairing.server.ts +5 -3
  367. package/src/server/lib/connect/status.server.ts +2 -2
  368. package/src/server/lib/db/schema.test.ts +3 -3
  369. package/src/server/lib/db/schema.ts +6 -0
  370. package/src/server/lib/harness/update-spawn.server.test.ts +97 -0
  371. package/src/server/lib/harness/update-spawn.server.ts +10 -0
  372. package/src/server/lib/models/provider-icon-override.server.test.ts +140 -0
  373. package/src/server/lib/models/provider-icon-override.server.ts +197 -0
  374. package/src/server/lib/models/provider-icon-store.server.ts +8 -0
  375. package/src/server/lib/models/provider-icon.server.ts +31 -6
  376. package/src/server/lib/omp/session/artifacts.server.test.ts +11 -7
  377. package/src/server/lib/omp/session/artifacts.server.ts +21 -17
  378. package/src/server/lib/panels/build.server.ts +19 -2
  379. package/src/server/lib/panels/css.server.test.ts +141 -0
  380. package/src/server/lib/panels/css.server.ts +255 -0
  381. package/src/server/lib/panels/plugin-ui-contract.test.ts +64 -0
  382. package/src/server/lib/panels/registry-stylesheet.server.test.ts +69 -0
  383. package/src/server/lib/panels/scan.server.ts +13 -7
  384. package/src/server/lib/panels/source-warnings.server.test.ts +65 -0
  385. package/src/server/lib/panels/source-warnings.server.ts +71 -0
  386. package/src/server/lib/realtime/topics/catalog.server.ts +3 -0
  387. package/src/server/lib/realtime/topics.server.ts +14 -0
  388. package/src/server/lib/sessions/last-opened-client.server.ts +1 -1
  389. package/src/server/lib/workspace/access.server.ts +108 -0
  390. package/src/server/lib/workspace/project-patch.server.ts +4 -2
  391. package/src/server/lib/workspace/register-folder.server.ts +19 -5
  392. package/src/server/lib/workspace/session-access.server.ts +55 -0
  393. package/src/server/lib/workspace/tenancy-schema.server.ts +40 -0
  394. package/src/server/plugins/ssr.ts +19 -3
  395. package/src/server/routes/accounts/index.ts +8 -0
  396. package/src/server/routes/accounts/management.test.ts +174 -0
  397. package/src/server/routes/accounts/management.ts +166 -0
  398. package/src/server/routes/auth/login.ts +22 -8
  399. package/src/server/routes/auth/logout.ts +1 -1
  400. package/src/server/routes/auth/password.ts +40 -33
  401. package/src/server/routes/auth/revoke.test.ts +1 -1
  402. package/src/server/routes/auth/revoke.ts +26 -8
  403. package/src/server/routes/auth/routes.test.ts +3 -3
  404. package/src/server/routes/auth/state.ts +14 -7
  405. package/src/server/routes/connect/devices.ts +7 -4
  406. package/src/server/routes/connect/pair.ts +4 -3
  407. package/src/server/routes/connect/status.ts +4 -2
  408. package/src/server/routes/connect/tunnels.ts +2 -1
  409. package/src/server/routes/folders/batch-delete.ts +12 -0
  410. package/src/server/routes/folders/clone.ts +7 -2
  411. package/src/server/routes/folders/create.ts +3 -1
  412. package/src/server/routes/folders/folder.ts +44 -4
  413. package/src/server/routes/folders/index.ts +3 -0
  414. package/src/server/routes/folders/shares.ts +62 -0
  415. package/src/server/routes/index.ts +2 -0
  416. package/src/server/routes/panels/build.ts +1 -1
  417. package/src/server/routes/panels/css.test.ts +22 -0
  418. package/src/server/routes/panels/css.ts +5 -7
  419. package/src/server/routes/realtime/ws.ts +16 -1
  420. package/src/server/routes/sessions/list.ts +3 -2
  421. package/src/server/routes/settings/projects.ts +46 -7
  422. package/src/server/routes/settings/provider-icon.ts +18 -0
  423. package/src/shared/lib/chat/timeline/tool-render-mode.test.ts +2 -2
  424. package/src/shared/lib/chat/timeline/tool-render-mode.ts +6 -3
  425. package/src/shared/lib/icons/tint-hues.generated.ts +38 -37
  426. package/src/shared/lib/omp/config/schema-releases-19-4.test.ts +27 -1
  427. package/src/shared/lib/omp/session/prewarm-misc.test.ts +1 -1
  428. package/src/shared/lib/realtime/protocol.ts +16 -0
  429. package/src/shared/lib/settings/defaults.ts +2 -1
  430. package/src/shared/lib/settings/sections.ts +1 -1
  431. package/src/shared/lib/theme/border-style.test.ts +11 -9
  432. package/src/shared/lib/theme/border-style.ts +7 -7
  433. package/src/shared/lib/theme/chrome-style.test.ts +15 -0
  434. package/src/shared/lib/theme/chrome-style.ts +16 -1
  435. package/src/shared/types/index.ts +1 -0
  436. package/src/shared/types/settings/state.ts +6 -5
  437. package/src/test-support/file-editor.test-util.ts +25 -6
  438. package/tsconfig.json +21 -0
  439. package/dist/client/static/js/ImageView-xc90jc1c.js +0 -1
  440. package/dist/client/static/js/LayoutWrapper-wyqe98kf.js +0 -2
  441. package/dist/client/static/js/MergeDiffView-bng34cpr.js +0 -1
  442. package/dist/client/static/js/Modal-89jk7wff.js +0 -60
  443. package/dist/client/static/js/SessionsView-6bpz1faj.js +0 -1
  444. package/dist/client/static/js/architecture-7GRP2DOG-sxrkxwbq.js +0 -1
  445. package/dist/client/static/js/bash-bcbct9gc.js +0 -1
  446. package/dist/client/static/js/c-fn9jz26e.js +0 -1
  447. package/dist/client/static/js/cpp-a1q64mke.js +0 -1
  448. package/dist/client/static/js/css-b92azee8.js +0 -1
  449. package/dist/client/static/js/css-sn00sq6v.js +0 -1
  450. package/dist/client/static/js/cynefin-OW5HDTMX-g1xwa8b9.js +0 -1
  451. package/dist/client/static/js/eventmodeling-NTZA5JFV-05p61bka.js +0 -1
  452. package/dist/client/static/js/flowDiagram-KWPJA3E3-7sn6nwjv.js +0 -1
  453. package/dist/client/static/js/gitGraph-4MIJSDKK-z1yehwys.js +0 -1
  454. package/dist/client/static/js/graphql-8d8bn59j.js +0 -1
  455. package/dist/client/static/js/html-6hdrwtz2.js +0 -1
  456. package/dist/client/static/js/index-4h2zkrk1.js +0 -2
  457. package/dist/client/static/js/index-5nm8hm4k.js +0 -2
  458. package/dist/client/static/js/index-95jfphx5.js +0 -481
  459. package/dist/client/static/js/index-9pw441wc.js +0 -4
  460. package/dist/client/static/js/index-bjz54ht6.js +0 -1
  461. package/dist/client/static/js/index-bqapt2e8.js +0 -2
  462. package/dist/client/static/js/index-ddkjgv5h.js +0 -2
  463. package/dist/client/static/js/index-dekvtt2a.js +0 -314
  464. package/dist/client/static/js/index-fnwaxc6r.js +0 -1
  465. package/dist/client/static/js/index-h65zrhva.js +0 -1
  466. package/dist/client/static/js/index-hxsqw7sz.js +0 -4
  467. package/dist/client/static/js/index-hxy1sadd.js +0 -2
  468. package/dist/client/static/js/index-ja0ajnvq.js +0 -10
  469. package/dist/client/static/js/index-qkyy563e.js +0 -1
  470. package/dist/client/static/js/index-t6nqy2n5.css +0 -1
  471. package/dist/client/static/js/index-wrk99kks.js +0 -3
  472. package/dist/client/static/js/info-A6RAGUB7-dqyaxjc1.js +0 -1
  473. package/dist/client/static/js/ini-g6a5xsaw.js +0 -1
  474. package/dist/client/static/js/java-n596am4c.js +0 -1
  475. package/dist/client/static/js/javascript-zc1qnyyp.js +0 -1
  476. package/dist/client/static/js/json-7k70qbkj.js +0 -1
  477. package/dist/client/static/js/jsx-sndenqrc.js +0 -1
  478. package/dist/client/static/js/lua-djd3g9q5.js +0 -1
  479. package/dist/client/static/js/markdown-r2tpvxpn.js +0 -1
  480. package/dist/client/static/js/one-dark-pro-7bgqnyhm.js +0 -1
  481. package/dist/client/static/js/one-light-47y6etng.js +0 -1
  482. package/dist/client/static/js/packet-AYTQ26CC-7jxzax4z.js +0 -1
  483. package/dist/client/static/js/pie-WAS4IAKB-wc9wxr7f.js +0 -1
  484. package/dist/client/static/js/properties-brn72zdk.js +0 -1
  485. package/dist/client/static/js/python-g9mghwgm.js +0 -1
  486. package/dist/client/static/js/r-e247x4mw.js +0 -1
  487. package/dist/client/static/js/radar-RG4KPBEZ-kwj5padj.js +0 -1
  488. package/dist/client/static/js/railroad-74A4TZTK-h8sdx3w5.js +0 -1
  489. package/dist/client/static/js/railroad-abnf-HS5TGJTU-2wmwx246.js +0 -1
  490. package/dist/client/static/js/railroad-ebnf-LZEXJU2U-h4cdgw3y.js +0 -1
  491. package/dist/client/static/js/railroad-peg-WCYAUIDC-q7m0tfd0.js +0 -1
  492. package/dist/client/static/js/sql-0kar81jy.js +0 -1
  493. package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-y77g9dq0.js +0 -8
  494. package/dist/client/static/js/timeline-definition-EJHVYXUP-8a3yqmx0.js +0 -120
  495. package/dist/client/static/js/treeView-Q6P3EWNA-yv9640h3.js +0 -1
  496. package/dist/client/static/js/treemap-WGGIJYW6-7kpzjg21.js +0 -1
  497. package/dist/client/static/js/tsx-gjxfjnbk.js +0 -1
  498. package/dist/client/static/js/typescript-bm89v3gk.js +0 -1
  499. package/dist/client/static/js/vennDiagram-UO4OBE2U-gf4y1r3s.js +0 -34
  500. package/dist/client/static/js/wardley-WFR3VGLG-mggay64p.js +0 -1
  501. package/dist/client/static/js/xml-b7824nx0.js +0 -1
  502. package/dist/client/static/js/yaml-kqqktdv1.js +0 -1
  503. package/src/server/lib/auth/client-address.ts +0 -89
  504. package/src/server/lib/auth/config.ts +0 -133
  505. package/src/server/lib/auth/rate-limit.ts +0 -146
  506. package/src/server/lib/auth/token.ts +0 -220
@@ -19,7 +19,9 @@ import { Window } from 'happy-dom';
19
19
  import { h, render } from 'preact';
20
20
  import { act } from 'preact/test-utils';
21
21
  import { MobileHeader } from '@/client/components/mobile/mobile-main-view/Header';
22
+ import { SidebarDataProvider } from '@/client/hooks/chat/omp/session-list';
22
23
  import { SessionStateProvider } from '@/client/components/common/session-state-provider/index';
24
+ import type { WorkspaceFolderData } from '@/shared/types';
23
25
  import { primeKabmoSettings } from '@/shared/lib/settings/client';
24
26
  import { silenceRealtime, restoreRealtime } from '@/test-support/silent-socket';
25
27
 
@@ -27,6 +29,12 @@ const DOM_GLOBALS = [
27
29
  'window', 'document', 'navigator', 'Node', 'Element', 'HTMLElement',
28
30
  'Event', 'MouseEvent', 'KeyboardEvent',
29
31
  ] as const;
32
+
33
+ const FOLDER = {
34
+ id: 1,
35
+ name: 'kabmo',
36
+ sessions: [{ id: 'session-picker', title: 'Shell' }],
37
+ } as unknown as WorkspaceFolderData;
30
38
  const nativeGlobals: Partial<Record<(typeof DOM_GLOBALS)[number], unknown>> = {};
31
39
 
32
40
  let win: Window;
@@ -57,15 +65,18 @@ beforeEach(async () => {
57
65
  document.body.appendChild(container);
58
66
  await act(async () => {
59
67
  render(
60
- h(SessionStateProvider, {
61
- sessionId: 'session-picker',
62
- children: h(MobileHeader, {
63
- activeSessionTitle: 'Shell',
64
- activeSessionId: 'session-picker',
65
- onOpenSessionSidebar: () => {},
66
- onOpenRightSidebar: () => {},
67
- onNewSession: () => {},
68
- onSelectSession: () => {},
68
+ h(SidebarDataProvider, {
69
+ initialFolders: [FOLDER],
70
+ children: h(SessionStateProvider, {
71
+ sessionId: 'session-picker',
72
+ children: h(MobileHeader, {
73
+ activeSessionTitle: 'Shell',
74
+ activeSessionId: 'session-picker',
75
+ onOpenSessionSidebar: () => {},
76
+ onOpenRightSidebar: () => {},
77
+ onNewSession: () => {},
78
+ onSelectSession: () => {},
79
+ }) as never,
69
80
  }) as never,
70
81
  }),
71
82
  container,
@@ -88,6 +99,15 @@ const panel = () => [...document.body.children]
88
99
  .find((child) => child?.textContent?.includes('Recent Sessions')) ?? null;
89
100
 
90
101
  describe('phone session picker', () => {
102
+ test('the title names the session workspace with its folder mark', () => {
103
+ const picker = container.querySelector('[data-testid="session-picker"]') as HTMLElement;
104
+ const label = picker.querySelector('span[title="kabmo"]') as HTMLElement | null;
105
+ expect(label?.textContent).toBe('kabmo');
106
+ // The mark is the project's glyph, not a generic folder icon: the shared
107
+ // `WorkspaceMark` paints it with the project accent.
108
+ expect(picker.querySelector('svg.project-accent-mark')).not.toBeNull();
109
+ });
110
+
91
111
  test('it opens a panel in the document, placed below its trigger', () => {
92
112
  expect(panel()).toBeNull();
93
113
 
@@ -7,6 +7,7 @@ import { useAgentStreamStatus } from '@/client/hooks/chat/omp/status';
7
7
  import { useSessionRenaming } from '@/client/hooks/workspace/renaming-sessions';
8
8
  import { StreamStatusDot } from '@/client/components/common/StreamStatusDot';
9
9
  import { BrandWordmark } from '@/client/components/common/brand-wordmark';
10
+ import { WorkspaceMark } from '@/client/components/common/workspace-mark';
10
11
  import { HeaderControls } from '@/client/components/common/header-controls';
11
12
  import { useHeaderEntries } from '@/client/components/common/header-panel-buttons/entries';
12
13
  import { AnchoredMenu } from '@/client/components/common/anchored-menu';
@@ -17,6 +18,7 @@ import { anchorRectOf, type AnchorRect } from '@/shared/lib/ui/menu-anchor';
17
18
  import { dragRegionProps } from '@/client/lib/desktop/titlebar';
18
19
  import { phoneRowStyle } from '@/client/lib/ui/phone-row';
19
20
  import { CONTROL_CLUSTER_GAP } from '@/client/lib/ui/control-plate';
21
+ import { activeProjectForSession } from '@/shared/lib/workspace/active-project';
20
22
 
21
23
  interface MobileHeaderProps {
22
24
  activeSessionTitle: string;
@@ -50,6 +52,10 @@ export function MobileHeader({
50
52
  onSelectSession,
51
53
  }: MobileHeaderProps) {
52
54
  const { folders } = useSidebarData();
55
+ const activeFolder = useMemo(
56
+ () => activeProjectForSession(folders, activeSessionId).folder,
57
+ [folders, activeSessionId],
58
+ );
53
59
  const streamStatus = useAgentStreamStatus();
54
60
  // The drawer's row spins from the same store, so the two surfaces cannot
55
61
  // disagree about whether a rename is running.
@@ -102,10 +108,15 @@ export function MobileHeader({
102
108
 
103
109
  return (
104
110
  <header
111
+ data-mobile-header-row=""
105
112
  className={`flex-shrink-0 bg-canvas border-b border-ink/10 flex items-center justify-between ${CONTROL_CLUSTER_GAP} px-3 z-20 titlebar-drag-region select-none`}
106
113
  {...dragRegionProps()}
107
114
  {...visibility.surfaceProps}
108
- style={phoneRowStyle()}
115
+ // The floating split cards sit at the window's gutter, so the row's
116
+ // horizontal inset is a CSS variable the floating rule lowers from the
117
+ // classic 12px to the 5px gutter. `phoneRowStyle` still contributes the
118
+ // shell and safe-area floors around it.
119
+ style={phoneRowStyle('var(--mobile-header-inset, 0.75rem)')}
109
120
  >
110
121
  {/* Left: hamburger, app title & session dropdown.
111
122
  `flex-1 min-w-0` is what makes the title the ONLY part that gives up
@@ -122,7 +133,7 @@ export function MobileHeader({
122
133
  390, 59px at 360. The earlier rule dropped the wordmark below 420px
123
134
  and kept reload/lock in the row instead; the brand was drawn on every
124
135
  other surface, so a phone read as a different app. */}
125
- <div className="flex items-center space-x-2 flex-1 min-w-0 titlebar-no-drag">
136
+ <div data-mobile-header-card="menu" className="flex flex-shrink-0 items-center">
126
137
  <button
127
138
  type="button"
128
139
  onClick={onOpenSessionSidebar}
@@ -132,7 +143,9 @@ export function MobileHeader({
132
143
  >
133
144
  <Menu size={20} strokeWidth={2} />
134
145
  </button>
146
+ </div>
135
147
 
148
+ <div data-mobile-header-title className="flex items-center space-x-2 flex-1 min-w-0 titlebar-no-drag">
136
149
  {/* The wordmark is drawn at EVERY width. The width it needs was bought
137
150
  back from the control cluster instead: reload and sign out moved
138
151
  into the `⋯` menu (`HeaderControls`), which is what pays for the
@@ -146,7 +159,7 @@ export function MobileHeader({
146
159
 
147
160
  <span className="text-ink/25 font-light text-xs flex-shrink-0 select-none">/</span>
148
161
 
149
- <div className="relative min-w-0 flex-1 max-w-[150px]" data-testid="session-picker">
162
+ <div className="relative min-w-0 flex-1" data-testid="session-picker">
150
163
  <button
151
164
  type="button"
152
165
  onClick={(event: TargetedMouseEvent<HTMLButtonElement>) => {
@@ -157,7 +170,23 @@ export function MobileHeader({
157
170
  aria-haspopup="menu"
158
171
  aria-expanded={pickerAnchor !== null}
159
172
  >
160
- <span className="truncate">{displayTitle}</span>
173
+ {/* The desktop session title leads with `FOLDER / title` so two
174
+ chats with the same name are told apart; the phone's title is
175
+ the same line, with the folder name capped to leave the session
176
+ title the rest of the row. */}
177
+ {activeSessionTitle && activeFolder ? (
178
+ <span className="flex min-w-0 items-center gap-1">
179
+ <WorkspaceMark folder={activeFolder} size={12} className="text-ink/50" />
180
+ <span
181
+ className="min-w-0 max-w-[4.5rem] truncate text-[10px] uppercase tracking-wide text-ink/45"
182
+ title={activeFolder.name}
183
+ >
184
+ {activeFolder.name}
185
+ </span>
186
+ <span className="shrink-0 text-ink/35" aria-hidden="true">/</span>
187
+ </span>
188
+ ) : null}
189
+ <span className="min-w-0 flex-1 truncate">{displayTitle}</span>
161
190
  {/* The phone's drawer row spins too, but the drawer is closed while
162
191
  the user reads the chat — and "Rename with AI" is reachable from
163
192
  the drawer alone, so without this the click would look like it
@@ -227,14 +256,16 @@ export function MobileHeader({
227
256
  </div>
228
257
 
229
258
  {/* Right: the same cluster, in the same order as the desktop navbar. */}
230
- <HeaderControls
231
- layout="mobile"
232
- sessionId={activeSessionId == null ? null : String(activeSessionId)}
233
- showRightPanel={false}
234
- onToggleRightPanel={onOpenRightSidebar}
235
- entries={headerEntries}
236
- hidden={hidden}
237
- />
259
+ <div data-mobile-header-card="tools" className="flex flex-shrink-0 items-center">
260
+ <HeaderControls
261
+ layout="mobile"
262
+ sessionId={activeSessionId == null ? null : String(activeSessionId)}
263
+ showRightPanel={false}
264
+ onToggleRightPanel={onOpenRightSidebar}
265
+ entries={headerEntries}
266
+ hidden={hidden}
267
+ />
268
+ </div>
238
269
 
239
270
  {visibility.anchor ? (
240
271
  <VisibilityMenu
@@ -47,10 +47,21 @@ export function DrawerHeader({
47
47
  }) {
48
48
  return (
49
49
  <div
50
+ data-mobile-drawer-chrome=""
50
51
  className="border-b border-ink/10 flex items-center justify-between px-3 flex-shrink-0 bg-canvas titlebar-drag-region select-none"
51
52
  {...dragRegionProps()}
52
53
  {...menuProps}
53
- style={phoneRowStyle()}
54
+ style={{
55
+ ...phoneRowStyle(),
56
+ // In the floating chrome this header sits inside the right drawer's
57
+ // single card and must be exactly as tall as the chat header's cards
58
+ // (2.5rem). The notch moves to the drawer card's padding, because a
59
+ // 40px row cannot carry a 47px inset. Classic keeps the phone-row
60
+ // height and inset through the fallbacks.
61
+ height:
62
+ 'var(--mobile-right-drawer-header-height, calc(3.5rem + env(safe-area-inset-top, 0px)))',
63
+ paddingTop: 'var(--mobile-right-drawer-header-padding-top, env(safe-area-inset-top, 0px))',
64
+ }}
54
65
  >
55
66
  {/* The header is a drag region, so its controls must say so —
56
67
  `app-region` inherits, and a control inside a drag region is a drag
@@ -35,10 +35,17 @@ export function MobileFullDiff({ diff, onClose, onFileSaved }: MobileFullDiffPro
35
35
  const statusInfo = getGitStatusInfo(status, isStaged);
36
36
 
37
37
  return (
38
- <div className="fixed inset-x-0 top-0 h-dvh z-[60] bg-paper flex flex-col">
38
+ <div data-mobile-diff="" className="fixed inset-x-0 top-0 h-dvh z-[60] bg-paper flex flex-col">
39
39
  <header
40
+ data-mobile-diff-header=""
40
41
  className="bg-canvas border-b border-ink/10 flex items-center justify-between px-3 flex-shrink-0"
41
- style={phoneRowStyle()}
42
+ style={{
43
+ ...phoneRowStyle(),
44
+ // Same rule as the editor header: the floating card owns the notch.
45
+ height:
46
+ 'var(--mobile-editor-header-height, calc(3.5rem + env(safe-area-inset-top, 0px)))',
47
+ paddingTop: 'var(--mobile-editor-header-padding-top, env(safe-area-inset-top, 0px))',
48
+ }}
42
49
  >
43
50
  <div className="flex items-center space-x-2 min-w-0 pr-2">
44
51
  <button
@@ -186,6 +186,7 @@ export function MobileFullEditor({ file, missing = false, onClose, onFileSaved,
186
186
 
187
187
  return (
188
188
  <div
189
+ data-mobile-editor=""
189
190
  className="fixed inset-x-0 top-0 h-dvh z-[60] bg-paper flex flex-col font-mono text-xs select-none"
190
191
  {...drop.dropProps}
191
192
  {...drop.captureDropProps}
@@ -127,8 +127,16 @@ export function EditorHeader({
127
127
 
128
128
  return (
129
129
  <header
130
+ data-mobile-editor-header=""
130
131
  className="bg-canvas border-b border-ink/10 flex items-center justify-between gap-1 px-3 flex-shrink-0 titlebar-drag-region"
131
- style={phoneRowStyle()}
132
+ style={{
133
+ ...phoneRowStyle(),
134
+ // The floating card owns the notch, so its header is the same 40px row
135
+ // the rest of the phone chrome draws. Classic keeps the phone row.
136
+ height:
137
+ 'var(--mobile-editor-header-height, calc(3.5rem + env(safe-area-inset-top, 0px)))',
138
+ paddingTop: 'var(--mobile-editor-header-padding-top, env(safe-area-inset-top, 0px))',
139
+ }}
132
140
  >
133
141
  <div className="flex items-center gap-1 min-w-0 titlebar-no-drag">
134
142
  <EditorAction label="Close editor" onClick={onClose}>
@@ -19,6 +19,7 @@
19
19
  import { Loader2 } from 'lucide-preact';
20
20
  import { VIEWER_LABELS, type ViewerKind } from '@/shared/lib/fs/document-kind';
21
21
  import type { FileEditorSaveStatus } from '@/client/hooks/editor/use-file-editor';
22
+ import { SAFE_BOTTOM } from '@/client/lib/ui/safe-area';
22
23
 
23
24
  interface EditorStatusBarProps {
24
25
  isImage: boolean;
@@ -46,10 +47,11 @@ export function EditorStatusBar({
46
47
  }: EditorStatusBarProps) {
47
48
  return (
48
49
  <footer
50
+ data-mobile-editor-status=""
49
51
  className="bg-canvas border-t border-ink/10 px-3 flex items-center justify-between text-[10px] text-ink/60 flex-shrink-0 font-mono"
50
52
  style={{
51
- height: 'calc(1.75rem + env(safe-area-inset-bottom, 0px))',
52
- paddingBottom: 'env(safe-area-inset-bottom, 0px)',
53
+ height: `calc(1.75rem + ${SAFE_BOTTOM})`,
54
+ paddingBottom: SAFE_BOTTOM,
53
55
  paddingLeft: 'max(0.75rem, env(safe-area-inset-left, 0px))',
54
56
  paddingRight: 'max(0.75rem, env(safe-area-inset-right, 0px))',
55
57
  }}
@@ -147,7 +147,7 @@ export function DrawerBody({
147
147
  <>
148
148
  <div className={dock.showingSessions ? 'contents' : 'hidden'}>
149
149
  {sidebarStyle === 'modern' ? (
150
- <ModernSidebarView {...modernProps} touch />
150
+ <ModernSidebarView {...modernProps} touch surface={dock.tabsMode ? 'paper' : 'canvas'} />
151
151
  ) : (
152
152
  <ClassicDrawer
153
153
  folders={processedFolders}
@@ -1,7 +1,11 @@
1
1
  import { Info, Keyboard, Monitor, Settings } from 'lucide-preact';
2
- import packageJson from '@/../package.json';
2
+ import { FooterVersionInfo } from '@/client/components/common/footer-version';
3
3
  import type { ShellDownload } from '@/client/hooks/ui/updates/shell-download';
4
4
  import { ShellUpdateButton } from '@/client/components/common/shell-update-button';
5
+ import { AccountBadge } from '@/client/components/common/account-badge';
6
+ import { SignOutButton } from '@/client/components/common/SignOutButton';
7
+ import { useAccountCount } from '@/client/hooks/ui/auth';
8
+ import { safeBottom } from '@/client/lib/ui/safe-area';
5
9
 
6
10
  interface MobileSessionFooterProps {
7
11
  onSettings: () => void;
@@ -9,13 +13,11 @@ interface MobileSessionFooterProps {
9
13
  onAbout: () => void;
10
14
  updateAvailable?: boolean;
11
15
  onUpdateClick?: () => void;
12
- /** The native-shell artifact to offer, or null. Set inside a shell (an update) or on an Android browser (an install). */
13
16
  shellDownload?: ShellDownload | null;
14
- /** Switch the app to the desktop layout for this page session only. The
15
- * choice is not persisted, so the next load re-detects the device. */
16
17
  onDesktopToggle?: () => void;
17
18
  }
18
19
 
20
+ /** The mobile drawer's footer: navigation actions, account and sign out. */
19
21
  export function MobileSessionFooter({
20
22
  onSettings,
21
23
  onKeyBindings,
@@ -25,73 +27,73 @@ export function MobileSessionFooter({
25
27
  onDesktopToggle,
26
28
  shellDownload,
27
29
  }: MobileSessionFooterProps) {
30
+ const multiAccount = useAccountCount() > 1;
31
+
32
+
33
+
34
+ // No `bg-canvas` on the footer row for the same reason the drawer title row
35
+ // carries none: in the floating chrome this row lives inside its own CARD
36
+ // (`[data-mobile-drawer-card='footer']`), whose fill is `--float-surface`.
37
+ // An opaque canvas row painted over that card made the footer darker than the
38
+ // header and the session-list card in the classic surface (measured
39
+ // `rgb(33,37,43)` against the cards' `rgb(40,44,52)`). Under the glass
40
+ // surface the well rule already hid it, so this is the classic fix.
28
41
  return (
29
42
  <div
30
- className="px-3 pt-3 border-t border-ink/10 flex items-center justify-between flex-shrink-0 bg-canvas text-xs text-ink/60"
31
- style={{ paddingBottom: 'max(0.75rem, env(safe-area-inset-bottom, 0px))' }}
43
+ className="@container px-3 pt-3 border-t border-ink/10 flex flex-nowrap items-center justify-between gap-2 flex-shrink-0 text-xs text-ink/60"
44
+ style={{ paddingBottom: safeBottom('0.75rem') }}
32
45
  >
33
- <div className="flex items-center space-x-3">
46
+ <div className="flex min-w-0 items-center gap-1">
34
47
  <button
35
48
  type="button"
36
49
  onClick={onSettings}
37
- className="flex items-center space-x-1 hover:text-ink transition-colors"
50
+ title="Settings"
51
+ aria-label="Settings"
52
+ className="flex shrink-0 items-center space-x-1 p-1 rounded hover:text-ink hover:bg-ink/5 transition-colors"
38
53
  >
39
54
  <Settings size={14} />
40
- <span>Settings</span>
55
+ <span className="hidden @[600px]:inline">Settings</span>
41
56
  </button>
42
57
  <button
43
58
  type="button"
44
59
  onClick={onKeyBindings}
45
- className="flex items-center space-x-1 hover:text-ink transition-colors"
60
+ title="Keyboard shortcuts"
61
+ aria-label="Keyboard shortcuts"
62
+ className="flex shrink-0 items-center space-x-1 p-1 rounded hover:text-ink hover:bg-ink/5 transition-colors"
46
63
  >
47
64
  <Keyboard size={14} />
48
- <span>Keys</span>
65
+ <span className="hidden @[600px]:inline">Keys</span>
49
66
  </button>
50
- <button
51
- type="button"
52
- onClick={onAbout}
53
- className="flex items-center space-x-1 hover:text-ink transition-colors"
54
- >
55
- <Info size={14} />
56
- <span>About</span>
57
- </button>
58
- {shellDownload && (
59
- // Directly after About, matching the desktop footer.
60
- //
61
- // The visible word is the OFFER, not the file type: `APK` told a
62
- // reader what the bytes are but not what the control does, and on a
63
- // browser it is the only place the native shell is ever mentioned. An
64
- // iOS update is an IPA, so the word names the platform instead of a
65
- // file extension.
66
- //
67
- // The shared control decides link-versus-button: a desktop shell that
68
- // knows its architecture installs the artifact itself, and a link
69
- // there would leave the file in Downloads.
70
- <ShellUpdateButton download={shellDownload} variant="label" />
71
- )}
67
+ {shellDownload && <ShellUpdateButton download={shellDownload} variant="label" />}
72
68
  {onDesktopToggle && (
73
69
  <button
74
70
  type="button"
75
71
  onClick={onDesktopToggle}
76
- className="flex items-center space-x-1 hover:text-ink transition-colors"
77
72
  title="Switch to desktop view"
73
+ aria-label="Switch to desktop view"
74
+ className="flex shrink-0 items-center space-x-1 p-1 rounded hover:text-ink hover:bg-ink/5 transition-colors"
78
75
  >
79
76
  <Monitor size={14} />
80
- <span>Desktop</span>
77
+ <span className="hidden @[600px]:inline">Desktop</span>
81
78
  </button>
82
79
  )}
80
+ <button
81
+ type="button"
82
+ onClick={onAbout}
83
+ title="About Kabmo"
84
+ aria-label="About Kabmo"
85
+ className="flex shrink-0 items-center space-x-1 p-1 rounded hover:text-ink hover:bg-ink/5 transition-colors"
86
+ >
87
+ <Info size={14} />
88
+ <span className="hidden @[600px]:inline">About</span>
89
+ </button>
90
+ {multiAccount && <FooterVersionInfo updateAvailable={updateAvailable} onUpdateClick={onUpdateClick} />}
83
91
  </div>
84
- <div className="flex items-center gap-2">
85
- <span className="font-mono text-[10px] text-ink/40">v{packageJson.version}</span>
86
- {updateAvailable && (
87
- <button
88
- type="button"
89
- onClick={onUpdateClick}
90
- className="px-2 py-0.5 rounded-full border border-ink/20 text-[10px] font-semibold text-ink hover:border-ink/40"
91
- >
92
- update
93
- </button>
94
- )}
92
+
93
+ <div className="flex shrink-0 items-center gap-1">
94
+ <AccountBadge labelClassName="hidden @[600px]:inline" />
95
+ <SignOutButton size={16} className="p-1 rounded hover:text-ink hover:bg-ink/5 cursor-pointer transition-colors" />
96
+ {!multiAccount && <FooterVersionInfo updateAvailable={updateAvailable} onUpdateClick={onUpdateClick} />}
95
97
  </div>
96
98
  </div>
97
99
  );
@@ -36,9 +36,18 @@ export function MobileSessionHeader({
36
36
  /** The drawer's right-click surface: a long press opens the panel switch. */
37
37
  menuProps?: VisibilityMenuSurfaceProps;
38
38
  }) {
39
+ // NO `bg-canvas` on the title row, deliberately. Under the glass surface the
40
+ // canvas well rule (`[data-surface="glass"] .app-window .bg-canvas`, (0,6,0))
41
+ // outbids the floating card's fill (0,4,1), so a canvas row made this header
42
+ // card transparent while the session-list card beside it painted
43
+ // `--glass-card`. Without the class the card marker owns the fill in the
44
+ // floating chrome, and the drawer root's own canvas shows through in the flat
45
+ // chrome — the same pixel either way.
39
46
  return (
40
47
  <div
41
- className="border-b border-ink/10 flex items-center justify-between px-3 flex-shrink-0 bg-canvas titlebar-drag-region select-none"
48
+ data-mobile-drawer-chrome=""
49
+ data-mobile-drawer-card="header"
50
+ className="border-b border-ink/10 flex items-center justify-between px-3 flex-shrink-0 titlebar-drag-region select-none"
42
51
  {...dragRegionProps()}
43
52
  {...menuProps}
44
53
  style={{
@@ -51,6 +60,14 @@ export function MobileSessionHeader({
51
60
  // (`lib/ui/phone-row`), so this drawer cannot drift from the chat
52
61
  // header it is opened from.
53
62
  ...phoneRowStyle(),
63
+ // In the floating chrome this header is one CARD beside the two other
64
+ // drawer cards, and it must be exactly as tall as the chat header's
65
+ // cards (2.5rem). The notch moves to the drawer root's padding there,
66
+ // because a 40px card cannot carry a 47px inset. Classic keeps the
67
+ // phone-row height and inset through the fallbacks.
68
+ height:
69
+ 'var(--mobile-drawer-header-height, calc(3.5rem + env(safe-area-inset-top, 0px)))',
70
+ paddingTop: 'var(--mobile-drawer-header-padding-top, env(safe-area-inset-top, 0px))',
54
71
  }}
55
72
  >
56
73
  <div className="flex items-center space-x-2.5 titlebar-no-drag min-w-0">
@@ -36,6 +36,7 @@ function mount(activeSessionId: string | null = null) {
36
36
  sessions: [],
37
37
  hasMore: false,
38
38
  totalSessions: 0,
39
+ accentColor: '#38bdf8',
39
40
  } as unknown as WorkspaceFolderData;
40
41
  render(
41
42
  h(MobileSessionCategory, {
@@ -68,6 +69,9 @@ describe('phone classic folder row', () => {
68
69
  expect(count.textContent?.trim()).toBe('0');
69
70
  expect(disclosure.querySelector('svg')).not.toBeNull();
70
71
  expect(workspace.getAttribute('aria-label')).toBe('Open workspace panels for kabmo');
72
+ const folderGlyph = workspace.querySelector('svg') as SVGElement;
73
+ expect(folderGlyph.getAttribute('class')).toContain('project-accent-mark');
74
+ expect(folderGlyph.getAttribute('style')).toContain('--project-accent');
71
75
  expect(newChat.getAttribute('aria-label')).toBe('New session in kabmo');
72
76
  expect(options.querySelector('[aria-label="Options for kabmo"]')).not.toBeNull();
73
77
  });
@@ -13,6 +13,7 @@ import { useWorkspaceFolderActions } from '@/client/hooks/workspace/workspace-fo
13
13
  import { useSessionDelete } from '@/client/hooks/workspace/session-delete';
14
14
  import { SessionDeleteModal } from '@/client/components/common/session-delete-modal';
15
15
  import { getProjectIcon } from '@/shared/lib/workspace/project-icon';
16
+ import { projectAccentStyle } from '@/shared/lib/workspace/project-accent';
16
17
  import { formatFullDate, relativeTimeAgo } from '@/shared/lib/workspace/relative-time';
17
18
  import { isPendingSessionId } from '@kabmo-labs/kabmo-omp/session-core/default-title';
18
19
  import { workspaceSessionId } from '@/shared/lib/workspace/workspace-session';
@@ -102,6 +103,7 @@ export function MobileSessionCategory({
102
103
  showArchived ? s.is_archived === 1 : s.is_archived !== 1
103
104
  );
104
105
  const ProjectIcon = getProjectIcon(folder.icon);
106
+ const accentStyle = projectAccentStyle(folder.accentColor) as unknown as Record<string, string>;
105
107
 
106
108
  // Batch rules are shared with the desktop category (`folderBatchState`), so
107
109
  // the phone cannot offer a different scope, summary or pagination rule.
@@ -207,11 +209,7 @@ export function MobileSessionCategory({
207
209
  ) : folder.iconType === 'chat' ? (
208
210
  <MessageSquare size={15} className="text-ink/80" />
209
211
  ) : (
210
- <ProjectIcon
211
- size={15}
212
- className="text-ink/80"
213
- style={{ color: folder.accentColor || undefined }}
214
- />
212
+ <ProjectIcon size={15} className="project-accent-mark text-ink/80" style={accentStyle} />
215
213
  )}
216
214
  </span>
217
215
  </>
@@ -252,7 +250,7 @@ export function MobileSessionCategory({
252
250
  aria-label={`Open workspace panels for ${folder.name}`}
253
251
  aria-pressed={String(activeSessionId) === workspaceSessionId(folder.id)}
254
252
  >
255
- <FolderOpen size={15} />
253
+ <FolderOpen size={15} className="project-accent-mark" style={accentStyle} />
256
254
  </button>
257
255
 
258
256
  <button
@@ -30,10 +30,12 @@ import { SessionStateProvider } from '@/client/components/common/session-state-p
30
30
  import { primeKabmoSettings } from '@/shared/lib/settings/client';
31
31
  import { resetSessionStateStore } from '@/shared/lib/workspace/session-state/store';
32
32
  import { silenceRealtime, restoreRealtime } from '@/test-support/silent-socket';
33
+ import { MOBILE_CHROME_ATTRIBUTE } from '@/shared/lib/theme/chrome-style';
34
+ import { applyMobileChromeStyle } from '@/client/hooks/ui/mobile-chrome-style';
33
35
 
34
36
  const DOM_GLOBALS = [
35
37
  'window', 'document', 'navigator', 'Node', 'Element', 'HTMLElement',
36
- 'Event', 'MouseEvent', 'KeyboardEvent',
38
+ 'Event', 'MouseEvent', 'KeyboardEvent', 'CustomEvent',
37
39
  ] as const;
38
40
  const nativeGlobals: Partial<Record<(typeof DOM_GLOBALS)[number], unknown>> = {};
39
41
  const realFetch = globalThis.fetch;
@@ -70,6 +72,8 @@ beforeEach(() => {
70
72
  // The store is a module singleton: a close left behind by one test would
71
73
  // otherwise seed the next one's drawer.
72
74
  resetSessionStateStore();
75
+ // Classic is the absence of the phone chrome attribute; start every case there.
76
+ document.documentElement.removeAttribute(MOBILE_CHROME_ATTRIBUTE);
73
77
  container = document.createElement('div');
74
78
  document.body.appendChild(container);
75
79
  primeKabmoSettings({});
@@ -131,6 +135,54 @@ describe('the drawer chrome follows the setting', () => {
131
135
  // The header's own chips are gone: the strip is the only list of views.
132
136
  expect(container.textContent).not.toContain('Sessions');
133
137
  });
138
+
139
+ test('floating phone chrome connects the active tab', async () => {
140
+ document.documentElement.setAttribute(MOBILE_CHROME_ATTRIBUTE, 'floating');
141
+ await mount('tabs');
142
+ const card = container.querySelector('[aria-label^="Buka "]') as HTMLElement | null;
143
+ expect(card).not.toBeNull();
144
+ await act(() => {
145
+ card?.click();
146
+ });
147
+ await settle();
148
+ const active = container.querySelector('[role="tab"][aria-selected="true"]') as HTMLElement;
149
+ expect(active.className).toContain('h-full');
150
+ expect(active.className).toContain('border-ink/20');
151
+ expect(active.style.borderTopLeftRadius).toBe('8px');
152
+ });
153
+
154
+ test('classic phone chrome keeps the 36px chip', async () => {
155
+ await mount('tabs');
156
+ const card = container.querySelector('[aria-label^="Buka "]') as HTMLElement | null;
157
+ expect(card).not.toBeNull();
158
+ await act(() => {
159
+ card?.click();
160
+ });
161
+ await settle();
162
+ const active = container.querySelector('[role="tab"][aria-selected="true"]') as HTMLElement;
163
+ expect(active.className).toContain('h-9');
164
+ expect(active.className).toContain('rounded-md');
165
+ expect(active.style.borderTopLeftRadius).toBe('');
166
+ });
167
+
168
+ test('a live chrome switch swaps the tab language', async () => {
169
+ document.documentElement.setAttribute(MOBILE_CHROME_ATTRIBUTE, 'floating');
170
+ await mount('tabs');
171
+ const card = container.querySelector('[aria-label^="Buka "]') as HTMLElement | null;
172
+ await act(() => {
173
+ card?.click();
174
+ });
175
+ await settle();
176
+ const connected = container.querySelector('[role="tab"][aria-selected="true"]') as HTMLElement;
177
+ expect(connected.className).toContain('h-full');
178
+ await act(() => {
179
+ applyMobileChromeStyle('classic');
180
+ });
181
+ await settle();
182
+ const chip = container.querySelector('[role="tab"][aria-selected="true"]') as HTMLElement;
183
+ expect(chip.className).toContain('h-9');
184
+ expect(chip.style.borderTopLeftRadius).toBe('');
185
+ });
134
186
  });
135
187
 
136
188
  describe('the home page is the empty state', () => {
@@ -49,8 +49,11 @@ export function SettingsBand({
49
49
  <div
50
50
  className={`${SETTINGS_BAND} justify-between px-4 md:px-6`}
51
51
  style={{
52
- height: SETTINGS_BAND_HEIGHT_INSET,
53
- paddingTop: 'env(safe-area-inset-top, 0px)',
52
+ // A floating phone card carries the notch on its root, so the band
53
+ // falls back to the plain 4rem row there. The classic sheet keeps the
54
+ // inset height through the fallback.
55
+ height: 'var(--settings-band-height, ' + SETTINGS_BAND_HEIGHT_INSET + ')',
56
+ paddingTop: 'var(--settings-band-padding-top, env(safe-area-inset-top, 0px))',
54
57
  paddingLeft: 'max(1rem, env(safe-area-inset-left, 0px))',
55
58
  paddingRight: 'max(1rem, env(safe-area-inset-right, 0px))',
56
59
  }}