@kabmo-labs/kabmo 0.58.0 → 0.59.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.
- package/dist/client/index.html +1 -1
- package/dist/client/index.js +520 -489
- package/dist/client/static/js/{Body-karkrzkc.js → Body-jqq4654r.js} +3 -3
- package/dist/client/static/js/{CsvGrid-j03knmbe.js → CsvGrid-avw0taqb.js} +2 -2
- package/dist/client/static/js/{DocxView-e8408vzs.js → DocxView-d221vr6g.js} +3 -3
- package/dist/client/static/js/{DrawioView-fj4mfzch.js → DrawioView-gjsy7p01.js} +2 -2
- package/dist/client/static/js/{HtmlPreview-9g8xwzgw.js → HtmlPreview-949393v1.js} +1 -1
- package/dist/client/static/js/ImageView-pan9pqtm.js +1 -0
- package/dist/client/static/js/LayoutWrapper-p0qmghgt.js +2 -0
- package/dist/client/static/js/MergeDiffView-swt467g7.js +1 -0
- package/dist/client/static/js/Modal-4spmcn44.js +60 -0
- package/dist/client/static/js/{PdfView-8jtdx5hd.js → PdfView-dzj2s6rj.js} +1 -1
- package/dist/client/static/js/SessionsView-b6szjdg5.js +1 -0
- package/dist/client/static/js/{SheetView-hwx8s864.js → SheetView-jpc178g5.js} +11 -11
- package/dist/client/static/js/{SvgPreview-ete36nzv.js → SvgPreview-94fap32p.js} +1 -1
- package/dist/client/static/js/{abnfDiagram-O67JEVCF-7nsqzz6z.js → abnfDiagram-O67JEVCF-a6eyfzrj.js} +1 -1
- package/dist/client/static/js/architecture-7GRP2DOG-bwn1drdz.js +1 -0
- package/dist/client/static/js/{architectureDiagram-NJMV4G6O-xvpkfq2f.js → architectureDiagram-NJMV4G6O-pgmyfncy.js} +3 -3
- package/dist/client/static/js/{astro-rsrqgjjx.js → astro-ryr2ajmg.js} +1 -1
- package/dist/client/static/js/bash-zknkkwkw.js +1 -0
- package/dist/client/static/js/{blockDiagram-BEXU5L5S-0saahcs6.js → blockDiagram-BEXU5L5S-rf51jyb2.js} +6 -6
- package/dist/client/static/js/c-0w02jkxb.js +1 -0
- package/dist/client/static/js/{c4Diagram-YGBWAQC7-ktpqnb4a.js → c4Diagram-YGBWAQC7-0faj48jp.js} +2 -2
- package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-x67cz3ms.js → classDiagram-v2-NBCMYWYE-bvzsws8x.js} +6 -6
- package/dist/client/static/js/{cose-bilkent-JH36ORCC-9wzmhkz8.js → cose-bilkent-JH36ORCC-j1amnd3m.js} +1 -1
- package/dist/client/static/js/cpp-p5b4vean.js +1 -0
- package/dist/client/static/js/css-9jzbvdyz.js +1 -0
- package/dist/client/static/js/css-sn00sq6v.js +1 -0
- package/dist/client/static/js/cynefin-OW5HDTMX-jbc50ks8.js +1 -0
- package/dist/client/static/js/{cynefinDiagram-VND7K2PF-dmmgmv99.js → cynefinDiagram-VND7K2PF-f73w6zzz.js} +2 -2
- package/dist/client/static/js/{dagre-6A5THRUB-ygkkms1t.js → dagre-6A5THRUB-a5vgvjsg.js} +2 -2
- package/dist/client/static/js/{diagram-22UHCM2B-qxj0pqb4.js → diagram-22UHCM2B-6y9efamp.js} +12 -12
- package/dist/client/static/js/{diagram-3UASUU5V-77k8w5dt.js → diagram-3UASUU5V-2mycy7xm.js} +2 -2
- package/dist/client/static/js/{diagram-ATOU4E4O-m0h86vf4.js → diagram-ATOU4E4O-10zgjb66.js} +3 -3
- package/dist/client/static/js/{diagram-CDSNMT55-5v28kaeg.js → diagram-CDSNMT55-bewa52yf.js} +4 -4
- package/dist/client/static/js/{diagram-MLGK6HIB-zgcg9gaz.js → diagram-MLGK6HIB-mh3b7gd3.js} +1 -1
- package/dist/client/static/js/{diagram-MPIPVDR6-10c9s6e6.js → diagram-MPIPVDR6-gvdrbdm5.js} +2 -2
- package/dist/client/static/js/{dockerfile-dr9sdsqp.js → dockerfile-6bn19kg0.js} +1 -1
- package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-mz4022dz.js → ebnfDiagram-ZINNZB2B-2prre93c.js} +1 -1
- package/dist/client/static/js/{elixir-3dy25ex8.js → elixir-fyxw6d70.js} +1 -1
- package/dist/client/static/js/{elk-276RUBZZ-ccerbsag.js → elk-276RUBZZ-9t6t9kc6.js} +2 -2
- package/dist/client/static/js/{erDiagram-OPXOYQCR-a8vjyrrw.js → erDiagram-OPXOYQCR-etcggr5n.js} +6 -6
- package/dist/client/static/js/{erlang-v7344938.js → erlang-97ayje6m.js} +1 -1
- package/dist/client/static/js/eventmodeling-NTZA5JFV-b37ey01t.js +1 -0
- package/dist/client/static/js/flowDiagram-KWPJA3E3-7c2ncsw7.js +1 -0
- package/dist/client/static/js/{ganttDiagram-FUAMR5RP-sz1g29fp.js → ganttDiagram-FUAMR5RP-cdc4mwhs.js} +3 -3
- package/dist/client/static/js/gitGraph-4MIJSDKK-mvqq7tcs.js +1 -0
- package/dist/client/static/js/{gitGraphDiagram-X574FWY7-efqk42q0.js → gitGraphDiagram-X574FWY7-55d0fa7x.js} +8 -8
- package/dist/client/static/js/graphql-xzykn0ba.js +1 -0
- package/dist/client/static/js/html-2zc3shky.js +1 -0
- package/dist/client/static/js/{index-mpyd7qxj.js → index-10vzyga1.js} +2 -2
- package/dist/client/static/js/{index-2f6psebk.js → index-27gwghmp.js} +2 -2
- package/dist/client/static/js/{index-t71k3b28.js → index-2f6afhze.js} +2 -2
- package/dist/client/static/js/{index-tnxp90ac.js → index-3akjcs82.js} +1 -1
- package/dist/client/static/js/{index-fhtnvqgf.js → index-3j2he86h.js} +2 -2
- package/dist/client/static/js/index-461ga40v.js +2 -0
- package/dist/client/static/js/{index-9qf2h9jb.js → index-51rbgeh9.js} +12 -12
- package/dist/client/static/js/{index-zh550byg.js → index-537m8a3x.js} +2 -2
- package/dist/client/static/js/{index-tdg7hz80.js → index-58z2hatp.js} +2 -2
- package/dist/client/static/js/{index-4tbdws4r.js → index-5e4e18tg.js} +2 -2
- package/dist/client/static/js/{index-xfyxmaj1.js → index-60cxxnpk.js} +62 -62
- package/dist/client/static/js/{index-th61y26d.js → index-69mnn71v.js} +2 -2
- package/dist/client/static/js/{index-8aqjj2x2.js → index-6bsez5n6.js} +1 -1
- package/dist/client/static/js/{index-gaa39w5q.js → index-8tzt0dek.js} +2 -2
- package/dist/client/static/js/{index-vb5a3g01.js → index-8z9aqgf3.js} +4 -4
- package/dist/client/static/js/{index-ewryzs4g.js → index-92h38pwg.js} +2 -2
- package/dist/client/static/js/{index-7ma44af3.js → index-9rvjegmy.js} +3 -3
- package/dist/client/static/js/{index-q0k1am0g.js → index-a3bpmw2r.js} +2 -2
- package/dist/client/static/js/{index-j863hg0d.js → index-a5ecn5yx.js} +6 -6
- package/dist/client/static/js/{index-6ey6y9em.js → index-ax8gaayq.js} +2 -2
- package/dist/client/static/js/{index-e42ys2q3.js → index-c253x7vt.js} +7 -7
- package/dist/client/static/js/{index-y0f3wbc3.js → index-d9sfavx1.js} +2 -2
- package/dist/client/static/js/{index-5tp3emtg.js → index-db6s66jr.js} +2 -2
- package/dist/client/static/js/index-eggbcdwx.js +481 -0
- package/dist/client/static/js/{index-ts8rhd06.js → index-f13ern5e.js} +1 -1
- package/dist/client/static/js/{index-ver116ed.js → index-f6t91mpp.js} +1 -1
- package/dist/client/static/js/{index-tc07gd33.js → index-fr91ghwb.js} +2 -2
- package/dist/client/static/js/{index-tq3t3qm4.js → index-fsa18ns9.js} +2 -2
- package/dist/client/static/js/{index-k56patms.js → index-fyt8m8ah.js} +2 -2
- package/dist/client/static/js/{index-gw4c5n3a.js → index-gcad7b6g.js} +2 -2
- package/dist/client/static/js/{index-rxt8sf9a.js → index-h1xbx74w.js} +2 -2
- package/dist/client/static/js/{index-q5q8a3qn.js → index-j1ksa4x2.js} +2 -2
- package/dist/client/static/js/{index-sxag9ptg.js → index-jct0jryd.js} +2 -2
- package/dist/client/static/js/{index-r1wrke3j.js → index-jpvng27a.js} +1 -1
- package/dist/client/static/js/{index-w5j1wgcz.js → index-me0b6wkw.js} +1 -1
- package/dist/client/static/js/{index-6x0kn8pb.js → index-mhrkjbjq.js} +2 -2
- package/dist/client/static/js/{index-nzq51nbb.js → index-mngpcca7.js} +5 -5
- package/dist/client/static/js/index-mttx9327.css +1 -0
- package/dist/client/static/js/{index-ssepzdaz.js → index-mx5y9vt9.js} +7 -7
- package/dist/client/static/js/{index-3ymw778n.js → index-ndqtff48.js} +2 -2
- package/dist/client/static/js/{index-wnk9k57k.js → index-nf4hq5tg.js} +55 -55
- package/dist/client/static/js/{index-f31c6jg8.js → index-njhrm5qa.js} +10 -10
- package/dist/client/static/js/index-nnwcbp2d.js +2 -0
- package/dist/client/static/js/{index-3p732mvs.js → index-np2rfq06.js} +2 -2
- package/dist/client/static/js/{index-kc5yt2cd.js → index-nwbr15b3.js} +2 -2
- package/dist/client/static/js/{index-2a0b9ya2.js → index-pa70qj4p.js} +1 -1
- package/dist/client/static/js/index-pe5f2gmn.js +1 -0
- package/dist/client/static/js/{index-qbqm3c91.js → index-pgy7ree5.js} +5 -5
- package/dist/client/static/js/index-pzwf6hwe.js +4 -0
- package/dist/client/static/js/{index-jnxmvxb8.js → index-q3k8r0ms.js} +11 -11
- package/dist/client/static/js/{index-qkcmspxq.js → index-rw84kefb.js} +2 -2
- package/dist/client/static/js/{index-gqsnyh8k.js → index-s9ts6qbj.js} +2 -2
- package/dist/client/static/js/{index-dqf0srrp.js → index-sg65xdey.js} +2 -2
- package/dist/client/static/js/{index-mkp3gwag.js → index-skvfxcd8.js} +1 -1
- package/dist/client/static/js/{index-6qqsy78z.js → index-sx2yz2wx.js} +1 -1
- package/dist/client/static/js/{index-6ac860yz.js → index-trq7bdvk.js} +2 -2
- package/dist/client/static/js/{index-v8xhgfeq.js → index-vs2y8gxr.js} +2 -2
- package/dist/client/static/js/index-wwyjzhgs.js +2 -0
- package/dist/client/static/js/{index-7s4dge1z.js → index-xe447cw3.js} +1 -1
- package/dist/client/static/js/index-y09de44h.js +2 -0
- package/dist/client/static/js/{index-jxsha63v.js → index-y4cx8cqf.js} +2 -2
- package/dist/client/static/js/{index-bkwax812.js → index-yg38s8t3.js} +1 -1
- package/dist/client/static/js/{index-dz18nn65.js → index-yh7gngsh.js} +2 -2
- package/dist/client/static/js/{index-3m1dksmy.js → index-yrwm437g.js} +2 -2
- package/dist/client/static/js/{index-7ynf3s2w.js → index-z82nd2bd.js} +2 -2
- package/dist/client/static/js/info-A6RAGUB7-zkv4crz7.js +1 -0
- package/dist/client/static/js/{infoDiagram-VRGFBTTK-rykcacj5.js → infoDiagram-VRGFBTTK-9xph6cr5.js} +2 -2
- package/dist/client/static/js/ini-62r3vxaf.js +1 -0
- package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-rj752kd8.js → ishikawaDiagram-OU5B5YK6-3gshs3v8.js} +2 -2
- package/dist/client/static/js/java-kacycary.js +1 -0
- package/dist/client/static/js/javascript-zc1qnyyp.js +1 -0
- package/dist/client/static/js/{journeyDiagram-ZHPQQLJL-mtetwn6f.js → journeyDiagram-ZHPQQLJL-fa8x56mf.js} +3 -3
- package/dist/client/static/js/json-yrwpn6bd.js +1 -0
- package/dist/client/static/js/jsx-b40ag8q1.js +1 -0
- package/dist/client/static/js/{julia-mxe3pnz3.js → julia-agc5kfvg.js} +1 -1
- package/dist/client/static/js/{kanban-definition-PNTS6WVX-4h5pw5mm.js → kanban-definition-PNTS6WVX-fybp2hh4.js} +5 -5
- package/dist/client/static/js/lua-bk961f37.js +1 -0
- package/dist/client/static/js/markdown-b7rgzgd6.js +1 -0
- package/dist/client/static/js/mermaid.core-jjh5ggp0.js +12 -0
- package/dist/client/static/js/{mindmap-definition-NLK3R4M7-67s4xy7h.js → mindmap-definition-NLK3R4M7-gtfbg619.js} +5 -5
- package/dist/client/static/js/one-dark-pro-vht9rv39.js +1 -0
- package/dist/client/static/js/one-light-arxc5whh.js +1 -0
- package/dist/client/static/js/packet-AYTQ26CC-dgpge627.js +1 -0
- package/dist/client/static/js/{pegDiagram-GJSIUBJH-qykb6ssk.js → pegDiagram-GJSIUBJH-1a51sbqv.js} +1 -1
- package/dist/client/static/js/{perl-a8eeaqkn.js → perl-v5vbtzgf.js} +1 -1
- package/dist/client/static/js/{php-6gq92zt8.js → php-83qwy98t.js} +1 -1
- package/dist/client/static/js/pie-WAS4IAKB-b8pgsqrd.js +1 -0
- package/dist/client/static/js/{pieDiagram-5QR66LMP-mymrrvck.js → pieDiagram-5QR66LMP-zd9svyyn.js} +3 -3
- package/dist/client/static/js/properties-k8gbzggp.js +1 -0
- package/dist/client/static/js/python-343tspad.js +1 -0
- package/dist/client/static/js/{quadrantDiagram-O4NWA36T-6f8ahd40.js → quadrantDiagram-O4NWA36T-5gtw2m6s.js} +3 -3
- package/dist/client/static/js/r-ycdwmv8g.js +1 -0
- package/dist/client/static/js/radar-RG4KPBEZ-fmfe5y27.js +1 -0
- package/dist/client/static/js/railroad-74A4TZTK-b5tks4ce.js +1 -0
- package/dist/client/static/js/railroad-abnf-HS5TGJTU-0sf4m0ze.js +1 -0
- package/dist/client/static/js/railroad-ebnf-LZEXJU2U-pjfy3pt7.js +1 -0
- package/dist/client/static/js/railroad-peg-WCYAUIDC-nr8ngt42.js +1 -0
- package/dist/client/static/js/{railroadDiagram-XR7U4H2S-c3habpvw.js → railroadDiagram-XR7U4H2S-3ccwpfzz.js} +1 -1
- package/dist/client/static/js/{requirementDiagram-PLB6GJNP-nysqy6te.js → requirementDiagram-PLB6GJNP-sasndrrp.js} +4 -4
- package/dist/client/static/js/{ruby-mc826p2e.js → ruby-994n5j6e.js} +1 -1
- package/dist/client/static/js/{rust-m4f4vpvn.js → rust-n9z2c9m3.js} +1 -1
- package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-s5dtfp3z.js → sankeyDiagram-IPEJSGJF-2ahb4sda.js} +3 -3
- package/dist/client/static/js/{sass-8bq5r2tz.js → sass-p6g7qdv2.js} +1 -1
- package/dist/client/static/js/{scss-9wz47c6t.js → scss-4j4t3r6y.js} +1 -1
- package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-bb3yp049.js → sequenceDiagram-PO4LG4MO-bfj90kz1.js} +7 -7
- package/dist/client/static/js/{sizeCapture-INFHLROL-0m2msee7.js → sizeCapture-INFHLROL-5tygxmtc.js} +1 -1
- package/dist/client/static/js/sql-kwpd5w07.js +1 -0
- package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-cd0qgj6t.js → stateDiagram-v2-GCMORJYK-533xw76e.js} +3 -3
- package/dist/client/static/js/{svelte-5vrwkc13.js → svelte-bek3h1sz.js} +1 -1
- package/dist/client/static/js/{swimlanes-2SLR337P-rpb01f7p.js → swimlanes-2SLR337P-gd3d04pk.js} +1 -1
- package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-xxmvdyg4.js +8 -0
- package/dist/client/static/js/{timeline-definition-EJHVYXUP-tqw2e6y1.js → timeline-definition-EJHVYXUP-fvqvgqvg.js} +3 -3
- package/dist/client/static/js/treeView-Q6P3EWNA-23r9fa68.js +1 -0
- package/dist/client/static/js/treemap-WGGIJYW6-mxxzdrj6.js +1 -0
- package/dist/client/static/js/tsx-gjxfjnbk.js +1 -0
- package/dist/client/static/js/typescript-4dchbnya.js +1 -0
- package/dist/client/static/js/{usecaseDiagram-POWQR4AR-dhf4d5xg.js → usecaseDiagram-POWQR4AR-tm1f0m4x.js} +25 -25
- package/dist/client/static/js/{vennDiagram-UO4OBE2U-ztkk79dv.js → vennDiagram-UO4OBE2U-2vdvv1hd.js} +4 -4
- package/dist/client/static/js/{vue-gmjnxjm3.js → vue-y44m889c.js} +1 -1
- package/dist/client/static/js/wardley-WFR3VGLG-cbqtax1x.js +1 -0
- package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-ahre5tmv.js → wardleyDiagram-VNRHLVJA-7avcjznx.js} +4 -4
- package/dist/client/static/js/xml-xs6qz3ya.js +1 -0
- package/dist/client/static/js/{xychartDiagram-PMCCYNJV-vak2c50n.js → xychartDiagram-PMCCYNJV-g39y526n.js} +4 -4
- package/dist/client/static/js/yaml-174nk5bn.js +1 -0
- package/package.json +7 -7
- package/src/client/borders.css +15 -3
- package/src/client/components/common/ComposerTextarea.test.tsx +13 -1
- package/src/client/components/common/ComposerTextarea.tsx +8 -2
- package/src/client/components/common/MarkdownRenderer.tsx +11 -2
- package/src/client/components/common/anchored-menu/index.tsx +11 -4
- package/src/client/components/common/harness-glyph/harness-glyph.test.ts +0 -4
- package/src/client/components/common/harness-glyph/index.tsx +4 -5
- package/src/client/components/common/markdown-inline-file.test.tsx +90 -15
- package/src/client/components/common/session-actions-menu/index.test.tsx +45 -0
- package/src/client/components/common/session-actions-menu/index.tsx +6 -1
- package/src/client/components/common/session-row/TrailingSlot.tsx +6 -2
- package/src/client/components/common/session-row/index.tsx +32 -16
- package/src/client/components/common/session-row/session-row.test.tsx +56 -18
- package/src/client/components/layout/desktop-layout/RightColumn.tsx +4 -1
- package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +28 -35
- package/src/client/components/layout/desktop-layout/index.tsx +5 -3
- package/src/client/components/layout/desktop-layout/resizer/index.tsx +13 -3
- package/src/client/components/layout/desktop-layout/resizer/panel.test.ts +41 -0
- package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +21 -1
- package/src/client/components/layout/session-sidebar/CategoryHeader.worktree.test.tsx +1 -0
- package/src/client/components/layout/session-sidebar/CategoryItem.tsx +8 -2
- package/src/client/components/layout/session-sidebar/ClassicView.tsx +2 -0
- package/src/client/components/layout/session-sidebar/SessionList.tsx +4 -0
- package/src/client/components/layout/session-sidebar/SessionsView.tsx +22 -1
- package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +46 -8
- package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +9 -3
- package/src/client/components/layout/session-sidebar/modern/index.tsx +2 -0
- package/src/client/components/layout/session-sidebar/modern/workspace-header.test.tsx +36 -0
- package/src/client/components/layout/session-sidebar/search-results.test.tsx +29 -16
- package/src/client/components/layout/session-sidebar/session-list-states.test.tsx +1 -0
- package/src/client/components/layout/session-sidebar/variant-props.ts +2 -0
- package/src/client/components/mobile/LayoutWrapper.tsx +9 -0
- package/src/client/components/mobile/SessionSidebar.tsx +4 -0
- package/src/client/components/mobile/left-drawer-nav.test.tsx +1 -1
- package/src/client/components/mobile/mobile-session-sidebar/Body.tsx +4 -0
- package/src/client/components/mobile/mobile-session-sidebar/ClassicDrawer.tsx +3 -0
- package/src/client/components/mobile/mobile-session-sidebar/Item.test.tsx +85 -0
- package/src/client/components/mobile/mobile-session-sidebar/Item.tsx +30 -14
- package/src/client/components/mobile/mobile-session-sidebar/List.tsx +4 -0
- package/src/client/components/settings/apply-side-effects.test.ts +31 -0
- package/src/client/components/settings/apply-side-effects.ts +7 -0
- package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.tsx +3 -2
- package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.test.tsx +95 -0
- package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.tsx +35 -0
- package/src/client/components/workspace/chat-timeline/ChatOverlays.tsx +1 -0
- package/src/client/components/workspace/chat-timeline/EmptyWorkspacePrompt.tsx +1 -0
- package/src/client/components/workspace/chat-timeline/MessageItem.gutter.test.ts +26 -0
- package/src/client/components/workspace/chat-timeline/MessageItem.tsx +6 -3
- package/src/client/components/workspace/chat-timeline/NewChatModal.tsx +5 -0
- package/src/client/components/workspace/chat-timeline/OrchestrationNotice.tsx +81 -162
- package/src/client/components/workspace/chat-timeline/SystemNotice.tsx +7 -3
- package/src/client/components/workspace/chat-timeline/ThinkingSection.test.tsx +17 -0
- package/src/client/components/workspace/chat-timeline/ThinkingSection.tsx +21 -7
- package/src/client/components/workspace/chat-timeline/ToolCallingSection.tsx +1 -0
- package/src/client/components/workspace/chat-timeline/UserTurn.test.tsx +24 -6
- package/src/client/components/workspace/chat-timeline/UserTurn.tsx +17 -4
- package/src/client/components/workspace/chat-timeline/block-chrome.test.tsx +16 -0
- package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.test.ts +104 -11
- package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.tsx +120 -43
- package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.tsx +28 -21
- package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.wait.test.tsx +48 -0
- package/src/client/components/workspace/chat-timeline/chat-input/ComposerRows.tsx +47 -22
- package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.test.ts +24 -0
- package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.tsx +44 -18
- package/src/client/components/workspace/chat-timeline/chat-input/GoalSurfaces.tsx +2 -1
- package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.test.ts +35 -0
- package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.tsx +33 -12
- package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.test.tsx +26 -2
- package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.tsx +67 -37
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.test.ts +86 -1
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.tsx +90 -135
- package/src/client/components/workspace/chat-timeline/chat-input/VoiceButton.tsx +58 -0
- package/src/client/components/workspace/chat-timeline/chat-input/access-capability.test.tsx +151 -0
- package/src/client/components/workspace/chat-timeline/chat-input/action-base.ts +42 -0
- package/src/client/components/workspace/chat-timeline/chat-input/index.tsx +1 -0
- package/src/client/components/workspace/chat-timeline/chat-input/mode-icons.test.ts +108 -0
- package/src/client/components/workspace/chat-timeline/chat-input/mode-icons.tsx +122 -0
- package/src/client/components/workspace/chat-timeline/chat-input/modes-props.ts +5 -0
- package/src/client/components/workspace/chat-timeline/chat-input/narrow.test.tsx +78 -20
- package/src/client/components/workspace/chat-timeline/chat-input/styles/index.tsx +11 -5
- package/src/client/components/workspace/chat-timeline/chat-input/styles.test.tsx +19 -0
- package/src/client/components/workspace/chat-timeline/composer-dock-frame.test.tsx +9 -0
- package/src/client/components/workspace/chat-timeline/fork-preview.test.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/index.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/target-picker/ParentSessionPicker.test.tsx +21 -5
- package/src/client/components/workspace/chat-timeline/target-picker/ParentSessionPicker.tsx +100 -71
- package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.test.tsx +9 -9
- package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.tsx +83 -66
- package/src/client/components/workspace/chat-timeline/target-picker/WorktreePicker.test.tsx +3 -3
- package/src/client/components/workspace/chat-timeline/target-picker/WorktreePicker.tsx +36 -15
- package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.test.tsx +125 -0
- package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.tsx +84 -27
- package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Mcp.test.tsx +18 -0
- package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Mcp.tsx +14 -5
- package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ArtifactChip.tsx +7 -3
- package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolRowActions.tsx +10 -2
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Card.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Compact.tsx +11 -6
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Minimal.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Trace.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Tui.test.tsx +5 -3
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Tui.tsx +19 -12
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/parity.test.tsx +50 -2
- package/src/client/components/workspace/chat-timeline/tool-renderers/styles/props.ts +2 -0
- package/src/client/components/workspace/model-dropdown/HarnessTabs.tsx +31 -10
- package/src/client/components/workspace/model-dropdown/Header.tsx +13 -5
- package/src/client/components/workspace/model-dropdown/Panel.tsx +18 -0
- package/src/client/components/workspace/model-dropdown/ThinkingLevels.tsx +51 -0
- package/src/client/components/workspace/model-dropdown/Trigger.tsx +99 -0
- package/src/client/components/workspace/model-dropdown/bands.ts +51 -0
- package/src/client/components/workspace/model-dropdown/harness-tabs.test.tsx +21 -5
- package/src/client/components/workspace/model-dropdown/index.tsx +20 -47
- package/src/client/components/workspace/model-dropdown/thinking-levels.test.tsx +108 -0
- package/src/client/components/workspace/model-dropdown/trigger.test.ts +54 -8
- package/src/client/hooks/chat/composer/attachments.test.ts +12 -0
- package/src/client/hooks/chat/composer/attachments.ts +16 -4
- package/src/client/hooks/chat/composer/pipeline.test.ts +14 -0
- package/src/client/hooks/chat/composer/pipeline.ts +15 -6
- package/src/client/hooks/chat/omp/session-list.activity.test.ts +20 -0
- package/src/client/hooks/chat/omp/session-merges.ts +18 -6
- package/src/client/hooks/chat/omp/session-sidebar-controller.ts +4 -0
- package/src/client/hooks/chat/timeline/access-ladder-wiring.test.ts +111 -0
- package/src/client/hooks/chat/timeline/access-ladder.test.ts +66 -0
- package/src/client/hooks/chat/timeline/access-ladder.ts +72 -0
- package/src/client/hooks/chat/timeline/access-mode.ts +11 -1
- package/src/client/hooks/chat/timeline/index.ts +4 -5
- package/src/client/hooks/chat/timeline/modes-contract.ts +10 -1
- package/src/client/hooks/chat/timeline/modes.ts +10 -2
- package/src/client/hooks/chat/timeline/scope.test.ts +17 -0
- package/src/client/hooks/chat/timeline/scope.ts +6 -1
- package/src/client/hooks/chat/timeline/send-refusal.test.ts +19 -0
- package/src/client/hooks/chat/timeline/send-steer.test.ts +17 -0
- package/src/client/hooks/chat/timeline/send.ts +17 -0
- package/src/client/hooks/editor/quick-open.ts +41 -0
- package/src/client/hooks/ui/border-style.test.ts +13 -0
- package/src/client/hooks/ui/markdown-render.ts +11 -6
- package/src/client/hooks/ui/open-inline-file.test.ts +16 -0
- package/src/client/hooks/ui/open-inline-file.ts +4 -2
- package/src/client/hooks/ui/show-more.ts +11 -1
- package/src/client/hooks/ui/ui-feedback.test.ts +11 -0
- package/src/client/hooks/ui/verified-inline-files.test.tsx +143 -0
- package/src/client/hooks/ui/verified-inline-files.ts +165 -0
- package/src/client/hooks/workspace/mobile-workspace-panels.test.tsx +116 -0
- package/src/client/hooks/workspace/mobile-workspace-panels.ts +73 -0
- package/src/client/hooks/workspace/panel-resize.test.ts +127 -0
- package/src/client/hooks/workspace/panel-resize.ts +81 -0
- package/src/client/hooks/workspace/session-list-limit.test.ts +80 -0
- package/src/client/hooks/workspace/session-list-limit.ts +69 -0
- package/src/client/hooks/workspace/session-pin.ts +58 -0
- package/src/client/hooks/workspace/workspace-panels-mode.test.tsx +87 -0
- package/src/client/hooks/workspace/workspace-panels-mode.ts +76 -0
- package/src/client/lib/router/branch-params.test.ts +17 -1
- package/src/client/lib/router/branch-params.ts +18 -0
- package/src/client/lib/ui/pressed.ts +15 -0
- package/src/client/tailwind.css +30 -10
- package/src/server/lib/connect/cloudflared.lifecycle.test.ts +25 -9
- package/src/server/lib/db/schema.test.ts +1 -1
- package/src/server/lib/db/schema.ts +17 -0
- package/src/server/lib/harness/activity.server.test.ts +81 -0
- package/src/server/lib/harness/activity.server.ts +55 -0
- package/src/server/lib/harness/spawn.server.ts +9 -0
- package/src/server/lib/omp/session/delete.server.ts +4 -2
- package/src/server/lib/omp/session/sidebar-activity.server.test.ts +24 -2
- package/src/server/lib/omp/session/sidebar-data.canonical.test.ts +14 -0
- package/src/server/lib/realtime/topics/session-data.server.ts +6 -5
- package/src/server/lib/realtime/topics/session-data.test.ts +35 -0
- package/src/server/lib/sessions/last-opened.server.test.ts +17 -0
- package/src/server/lib/sessions/last-opened.server.ts +18 -1
- package/src/server/routes/sessions/index.ts +3 -2
- package/src/server/routes/sessions/routes.test.ts +29 -46
- package/src/server/routes/sessions/session.ts +40 -62
- package/src/server/routes/sessions/state.test.ts +89 -0
- package/src/server/routes/sessions/state.ts +86 -0
- package/src/shared/lib/chat/attachment-budget.test.ts +74 -0
- package/src/shared/lib/chat/attachment-budget.ts +111 -0
- package/src/shared/lib/chat/attachments.test.ts +0 -17
- package/src/shared/lib/chat/attachments.ts +0 -53
- package/src/shared/lib/chat/orchestration/outcome-markdown.test.ts +57 -0
- package/src/shared/lib/chat/orchestration/outcome-markdown.ts +74 -0
- package/src/shared/lib/chat/timeline/block-chrome.test.ts +35 -0
- package/src/shared/lib/chat/timeline/block-chrome.ts +21 -0
- package/src/shared/lib/markdown/degenerate-emphasis.test.ts +64 -0
- package/src/shared/lib/markdown/degenerate-emphasis.ts +90 -0
- package/src/shared/lib/markdown/inline-file.test.ts +79 -22
- package/src/shared/lib/markdown/inline-file.ts +57 -25
- package/src/shared/lib/markdown/marked.ts +5 -1
- package/src/shared/lib/settings/defaults.ts +2 -0
- package/src/shared/lib/theme/border-style.ts +1 -1
- package/src/shared/lib/workspace/active-project.test.ts +17 -1
- package/src/shared/lib/workspace/active-project.ts +9 -0
- package/src/shared/lib/workspace/project-settings-delete.test.ts +97 -0
- package/src/shared/lib/workspace/project-settings.test.ts +2 -34
- package/src/shared/lib/workspace/project-settings.ts +6 -0
- package/src/shared/lib/workspace/session-list-limit.test.ts +31 -0
- package/src/shared/lib/workspace/session-list-limit.ts +32 -0
- package/src/shared/lib/workspace/sidebar-sort.test.ts +21 -0
- package/src/shared/lib/workspace/workspace-panel-widths.ts +1 -1
- package/src/shared/lib/workspace/workspace-session.test.ts +34 -0
- package/src/shared/lib/workspace/workspace-session.ts +40 -0
- package/src/shared/types/settings/state.ts +10 -0
- package/dist/client/static/js/ImageView-sz4fzz9k.js +0 -1
- package/dist/client/static/js/LayoutWrapper-q6q4h04a.js +0 -2
- package/dist/client/static/js/MergeDiffView-b8f013ws.js +0 -1
- package/dist/client/static/js/Modal-ahecatp5.js +0 -60
- package/dist/client/static/js/SessionsView-jwp8xvw5.js +0 -1
- package/dist/client/static/js/architecture-7GRP2DOG-dc7zys46.js +0 -1
- package/dist/client/static/js/bash-n5d0esqg.js +0 -1
- package/dist/client/static/js/c-pk766wx0.js +0 -1
- package/dist/client/static/js/cpp-3pt91jvm.js +0 -1
- package/dist/client/static/js/css-9gak6bze.js +0 -1
- package/dist/client/static/js/css-sp1cgdbr.js +0 -1
- package/dist/client/static/js/cynefin-OW5HDTMX-9fx59e89.js +0 -1
- package/dist/client/static/js/eventmodeling-NTZA5JFV-61d2ee91.js +0 -1
- package/dist/client/static/js/flowDiagram-KWPJA3E3-104ywb7w.js +0 -1
- package/dist/client/static/js/gitGraph-4MIJSDKK-zkb30q0t.js +0 -1
- package/dist/client/static/js/graphql-2ntm7jyh.js +0 -1
- package/dist/client/static/js/html-mt2yb43b.js +0 -1
- package/dist/client/static/js/index-6h46r2de.js +0 -1
- package/dist/client/static/js/index-f44k9k8d.css +0 -1
- package/dist/client/static/js/index-k1576e2m.js +0 -2
- package/dist/client/static/js/index-k4qshngy.js +0 -4
- package/dist/client/static/js/index-rr79n77k.js +0 -470
- package/dist/client/static/js/index-vf01q99d.js +0 -2
- package/dist/client/static/js/index-x7h04xzf.js +0 -2
- package/dist/client/static/js/index-xygk0v3e.js +0 -2
- package/dist/client/static/js/info-A6RAGUB7-xxvyt8p8.js +0 -1
- package/dist/client/static/js/ini-bdk46a3d.js +0 -1
- package/dist/client/static/js/java-3g3925cf.js +0 -1
- package/dist/client/static/js/javascript-0mqgcvps.js +0 -1
- package/dist/client/static/js/json-hdyzmffz.js +0 -1
- package/dist/client/static/js/jsx-y8r9mrdq.js +0 -1
- package/dist/client/static/js/lua-wf5k6p3r.js +0 -1
- package/dist/client/static/js/markdown-9bf16dx7.js +0 -1
- package/dist/client/static/js/mermaid.core-bs542jma.js +0 -12
- package/dist/client/static/js/one-dark-pro-541ed4b7.js +0 -1
- package/dist/client/static/js/one-light-nr79mykt.js +0 -1
- package/dist/client/static/js/packet-AYTQ26CC-cm8jeesg.js +0 -1
- package/dist/client/static/js/pie-WAS4IAKB-8b9xgcxv.js +0 -1
- package/dist/client/static/js/properties-xk4dn00p.js +0 -1
- package/dist/client/static/js/python-7sgz05n4.js +0 -1
- package/dist/client/static/js/r-w4qxm0pv.js +0 -1
- package/dist/client/static/js/radar-RG4KPBEZ-fxr2x2mf.js +0 -1
- package/dist/client/static/js/railroad-74A4TZTK-5qd45xk1.js +0 -1
- package/dist/client/static/js/railroad-abnf-HS5TGJTU-6fa00vpk.js +0 -1
- package/dist/client/static/js/railroad-ebnf-LZEXJU2U-pcbtg7tj.js +0 -1
- package/dist/client/static/js/railroad-peg-WCYAUIDC-r0fdhdtp.js +0 -1
- package/dist/client/static/js/sql-sd00wgem.js +0 -1
- package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-zx36y2c8.js +0 -8
- package/dist/client/static/js/treeView-Q6P3EWNA-9sn2h4ea.js +0 -1
- package/dist/client/static/js/treemap-WGGIJYW6-9fzms0pq.js +0 -1
- package/dist/client/static/js/tsx-h5yzg80q.js +0 -1
- package/dist/client/static/js/typescript-qy1sbhea.js +0 -1
- package/dist/client/static/js/wardley-WFR3VGLG-vy6rp5gp.js +0 -1
- package/dist/client/static/js/xml-mrk4xakv.js +0 -1
- package/dist/client/static/js/yaml-xaza6dra.js +0 -1
- package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.tsx +0 -67
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { useCallback, useState } from 'preact/hooks';
|
|
2
2
|
import { useSearchParams } from '@/client/lib/router/search-params';
|
|
3
3
|
import { clearBranchParams, newSessionParams } from '@/client/lib/router/branch-params';
|
|
4
|
+
import { useMobileWorkspacePanels } from '@/client/hooks/workspace/mobile-workspace-panels';
|
|
4
5
|
import { useKabmoEvent } from '@/client/hooks/ui/window-event';
|
|
5
6
|
import { useMobileBackStack } from '@/client/hooks/workspace/mobile-back';
|
|
6
7
|
import { useMobileDrawerReveals, type MobileScreen } from '@/client/components/mobile/mobile-drawer-reveals';
|
|
@@ -194,6 +195,13 @@ export function MobileLayoutWrapper({ onDesktopToggle, appSettings = {} }: Mobil
|
|
|
194
195
|
setCurrentScreen('main');
|
|
195
196
|
};
|
|
196
197
|
|
|
198
|
+
const handleOpenWorkspacePanels = useMobileWorkspacePanels({
|
|
199
|
+
stateSessionId,
|
|
200
|
+
drawers,
|
|
201
|
+
setSearchParams,
|
|
202
|
+
setCurrentScreen,
|
|
203
|
+
});
|
|
204
|
+
|
|
197
205
|
// Desktop parity: a worktree made from the phone's folder menu starts its chat
|
|
198
206
|
// in it. The sequence lives in one module so both layouts share it.
|
|
199
207
|
const handleNewWorktreeSession = (targetFolderId: number, worktreePath: string) =>
|
|
@@ -250,6 +258,7 @@ export function MobileLayoutWrapper({ onDesktopToggle, appSettings = {} }: Mobil
|
|
|
250
258
|
onSelectSession={handleSelectSession}
|
|
251
259
|
onNewSession={handleNewSession}
|
|
252
260
|
onNewSessionForFolder={handleNewSessionForFolder}
|
|
261
|
+
onOpenWorkspacePanels={handleOpenWorkspacePanels}
|
|
253
262
|
onNewWorktreeSession={handleNewWorktreeSession}
|
|
254
263
|
onClose={() => setCurrentScreen('main')}
|
|
255
264
|
onDesktopToggle={onDesktopToggle}
|
|
@@ -46,6 +46,8 @@ interface MobileSessionSidebarProps {
|
|
|
46
46
|
onSelectSession: (id: number | string) => void;
|
|
47
47
|
onNewSession: () => void;
|
|
48
48
|
onNewSessionForFolder: (folderId: number) => void;
|
|
49
|
+
/** Open this folder's panels under its per-folder workspace session. */
|
|
50
|
+
onOpenWorkspacePanels: (folderId: number) => void;
|
|
49
51
|
/** Start a chat in a worktree made from this folder. */
|
|
50
52
|
onNewWorktreeSession?: (folderId: number, worktreePath: string) => void;
|
|
51
53
|
onClose: () => void;
|
|
@@ -74,6 +76,7 @@ export function MobileSessionSidebar({
|
|
|
74
76
|
onSelectSession,
|
|
75
77
|
onNewSession,
|
|
76
78
|
onNewSessionForFolder,
|
|
79
|
+
onOpenWorkspacePanels,
|
|
77
80
|
onNewWorktreeSession,
|
|
78
81
|
onClose,
|
|
79
82
|
onDesktopToggle,
|
|
@@ -191,6 +194,7 @@ export function MobileSessionSidebar({
|
|
|
191
194
|
onScheduler={() => setSchedulerOpen(true)}
|
|
192
195
|
onToggleArchived={handleToggleArchived}
|
|
193
196
|
onNewSessionForFolder={handleNewSessionForFolderAndClose}
|
|
197
|
+
onOpenWorkspacePanels={onOpenWorkspacePanels}
|
|
194
198
|
{...(closeAfterWorktree ? { onNewWorktreeSession: closeAfterWorktree } : {})}
|
|
195
199
|
onToast={pushToast}
|
|
196
200
|
onArchiveSelected={handleArchiveSelected}
|
|
@@ -119,6 +119,7 @@ async function mount(style: 'classic' | 'tabs', railEnabled = true) {
|
|
|
119
119
|
onSelectSession: () => {},
|
|
120
120
|
onNewSession: () => {},
|
|
121
121
|
onNewSessionForFolder: () => {},
|
|
122
|
+
onOpenWorkspacePanels: () => {},
|
|
122
123
|
onClose: () => {},
|
|
123
124
|
// The drawer's `onRefresh` is the WORKSPACE refresh the layout hands
|
|
124
125
|
// down (`LayoutWrapper` passes `handleWorkspaceChanged`), so counting
|
|
@@ -337,7 +338,6 @@ describe('the drawer keeps its title bar and footer in both chromes', () => {
|
|
|
337
338
|
expect(container.querySelector('[aria-label="Close sidebar"]')).not.toBeNull();
|
|
338
339
|
});
|
|
339
340
|
});
|
|
340
|
-
|
|
341
341
|
/**
|
|
342
342
|
* The rail switch is what the style hangs on, exactly as on the desktop: with
|
|
343
343
|
* no rail there is no strip, so a tab style has nothing to open a view from.
|
|
@@ -46,6 +46,7 @@ export interface DrawerBodyProps {
|
|
|
46
46
|
onScheduler: () => void;
|
|
47
47
|
onToggleArchived: () => void;
|
|
48
48
|
onNewSessionForFolder: (folderId: number) => void;
|
|
49
|
+
onOpenWorkspacePanels: (folderId: number) => void;
|
|
49
50
|
onNewWorktreeSession?: (folderId: number, worktreePath: string) => void;
|
|
50
51
|
onToast: (message: string, tone?: ToastTone) => void;
|
|
51
52
|
onArchiveSelected: () => void;
|
|
@@ -68,6 +69,7 @@ export function DrawerBody({
|
|
|
68
69
|
onScheduler,
|
|
69
70
|
onToggleArchived,
|
|
70
71
|
onNewSessionForFolder,
|
|
72
|
+
onOpenWorkspacePanels,
|
|
71
73
|
onNewWorktreeSession,
|
|
72
74
|
onToast,
|
|
73
75
|
onArchiveSelected,
|
|
@@ -132,6 +134,7 @@ export function DrawerBody({
|
|
|
132
134
|
onScheduler,
|
|
133
135
|
onSelectSession: handleSelectSession,
|
|
134
136
|
onNewSessionForFolder,
|
|
137
|
+
onOpenWorkspacePanels,
|
|
135
138
|
onNewWorktreeSession,
|
|
136
139
|
onToast,
|
|
137
140
|
onCancelWait,
|
|
@@ -179,6 +182,7 @@ export function DrawerBody({
|
|
|
179
182
|
onSelectWorkspaces={batch.toggleWorkspaceSelection}
|
|
180
183
|
onSelectSession={handleSelectSession}
|
|
181
184
|
onNewSessionForFolder={onNewSessionForFolder}
|
|
185
|
+
onOpenWorkspacePanels={onOpenWorkspacePanels}
|
|
182
186
|
onNewWorktreeSession={onNewWorktreeSession}
|
|
183
187
|
onToggleFolder={onToggleFolder}
|
|
184
188
|
onToast={onToast}
|
|
@@ -60,6 +60,7 @@ export interface ClassicDrawerProps {
|
|
|
60
60
|
onSelectWorkspaces: () => void;
|
|
61
61
|
onSelectSession: (id: number | string) => void;
|
|
62
62
|
onNewSessionForFolder: (folderId: number) => void;
|
|
63
|
+
onOpenWorkspacePanels: (folderId: number) => void;
|
|
63
64
|
onNewWorktreeSession?: (folderId: number, worktreePath: string) => void;
|
|
64
65
|
onToggleFolder: (folderId: number) => void;
|
|
65
66
|
onToast: (message: string, type?: ToastTone) => void;
|
|
@@ -100,6 +101,7 @@ export function ClassicDrawer({
|
|
|
100
101
|
onSelectWorkspaces,
|
|
101
102
|
onSelectSession,
|
|
102
103
|
onNewSessionForFolder,
|
|
104
|
+
onOpenWorkspacePanels,
|
|
103
105
|
onNewWorktreeSession,
|
|
104
106
|
onToggleFolder,
|
|
105
107
|
onToast,
|
|
@@ -153,6 +155,7 @@ export function ClassicDrawer({
|
|
|
153
155
|
sessionStatus={sessionStatus}
|
|
154
156
|
onSelectSession={onSelectSession}
|
|
155
157
|
onNewSessionForFolder={onNewSessionForFolder}
|
|
158
|
+
onOpenWorkspacePanels={onOpenWorkspacePanels}
|
|
156
159
|
onNewWorktreeSession={onNewWorktreeSession}
|
|
157
160
|
onToggleFolder={onToggleFolder}
|
|
158
161
|
onToast={onToast}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* SPDX-License-Identifier: MIT
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* The phone's classic folder row states the same action order as the modern
|
|
8
|
+
* header: disclosure, workspace panels, new chat, options. A folder button on
|
|
9
|
+
* the wrong side of the chevron is the regression this pins.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
import { afterAll, afterEach, beforeAll, describe, expect, test } from 'bun:test';
|
|
13
|
+
import { Window } from 'happy-dom';
|
|
14
|
+
import { h, render } from 'preact';
|
|
15
|
+
|
|
16
|
+
import { MobileSessionCategory } from '@/client/components/mobile/mobile-session-sidebar/Item';
|
|
17
|
+
import { installDomGlobals, restoreDomGlobals } from '@/test-support/pristine-globals';
|
|
18
|
+
import type { WorkspaceFolderData } from '@/shared/types';
|
|
19
|
+
|
|
20
|
+
let container: HTMLElement | undefined;
|
|
21
|
+
|
|
22
|
+
beforeAll(() => {
|
|
23
|
+
installDomGlobals(new Window({ url: 'http://localhost' }));
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
afterAll(() => {
|
|
27
|
+
restoreDomGlobals();
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
function mount(activeSessionId: string | null = null) {
|
|
31
|
+
container = document.body.appendChild(document.createElement('div'));
|
|
32
|
+
const folder = {
|
|
33
|
+
id: 7,
|
|
34
|
+
name: 'kabmo',
|
|
35
|
+
isExpanded: true,
|
|
36
|
+
sessions: [],
|
|
37
|
+
hasMore: false,
|
|
38
|
+
totalSessions: 0,
|
|
39
|
+
} as unknown as WorkspaceFolderData;
|
|
40
|
+
render(
|
|
41
|
+
h(MobileSessionCategory, {
|
|
42
|
+
folder,
|
|
43
|
+
activeSessionId,
|
|
44
|
+
onSelectSession: () => {},
|
|
45
|
+
onNewSessionForFolder: () => {},
|
|
46
|
+
onOpenWorkspacePanels: () => {},
|
|
47
|
+
isExpanded: true,
|
|
48
|
+
onToggleExpand: () => {},
|
|
49
|
+
}),
|
|
50
|
+
container,
|
|
51
|
+
);
|
|
52
|
+
return container;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
afterEach(() => {
|
|
56
|
+
if (container) render(null, container);
|
|
57
|
+
container?.remove();
|
|
58
|
+
container = undefined;
|
|
59
|
+
});
|
|
60
|
+
|
|
61
|
+
describe('phone classic folder row', () => {
|
|
62
|
+
test('the action cluster is chevron · folder · + · options', () => {
|
|
63
|
+
const host = mount();
|
|
64
|
+
const header = host.querySelector('[data-testid="session-folder"] > div') as HTMLElement;
|
|
65
|
+
const actions = header.lastElementChild as HTMLElement;
|
|
66
|
+
const [count, disclosure, workspace, newChat, options] = Array.from(actions.children) as HTMLElement[];
|
|
67
|
+
|
|
68
|
+
expect(count.textContent?.trim()).toBe('0');
|
|
69
|
+
expect(disclosure.querySelector('svg')).not.toBeNull();
|
|
70
|
+
expect(workspace.getAttribute('aria-label')).toBe('Open workspace panels for kabmo');
|
|
71
|
+
expect(newChat.getAttribute('aria-label')).toBe('New session in kabmo');
|
|
72
|
+
expect(options.querySelector('[aria-label="Options for kabmo"]')).not.toBeNull();
|
|
73
|
+
});
|
|
74
|
+
|
|
75
|
+
test('the folder button looks pressed while this workspace is open', () => {
|
|
76
|
+
const host = mount('workspace-7');
|
|
77
|
+
const header = host.querySelector('[data-testid="session-folder"] > div') as HTMLElement;
|
|
78
|
+
const actions = header.lastElementChild as HTMLElement;
|
|
79
|
+
const workspace = actions.children[2] as HTMLElement;
|
|
80
|
+
|
|
81
|
+
expect(workspace.getAttribute('aria-pressed')).toBe('true');
|
|
82
|
+
expect(workspace.className).toContain('bg-ink/15');
|
|
83
|
+
expect(workspace.className).toContain('shadow-inner');
|
|
84
|
+
});
|
|
85
|
+
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChevronDown, ChevronRight, GitBranch, MessageSquare, Plus } from 'lucide-preact';
|
|
1
|
+
import { ChevronDown, ChevronRight, FolderOpen, GitBranch, MessageSquare, Plus } from 'lucide-preact';
|
|
2
2
|
import { FolderItemMenu } from '@/client/components/mobile/mobile-session-sidebar/ItemMenu';
|
|
3
3
|
import { useSearchParams } from '@/client/lib/router/search-params';
|
|
4
4
|
import { MobileSessionRow, MOBILE_BRANCH_STYLE } from '@/client/components/mobile/mobile-session-sidebar/SessionRow';
|
|
@@ -7,7 +7,7 @@ import type { BranchControl } from '@/client/components/common/session-branch';
|
|
|
7
7
|
import type { ToastTone } from '@/shared/lib/ui/toast-duration';
|
|
8
8
|
import { buildSessionTree } from '@/shared/lib/workspace/session-tree';
|
|
9
9
|
import { useWorktreeDialog } from '@/client/components/mobile/mobile-session-sidebar/WorktreeDialog';
|
|
10
|
-
import {
|
|
10
|
+
import { useSessionListShowMore } from '@/client/hooks/workspace/session-list-limit';
|
|
11
11
|
import { useExpandedSessions } from '@/client/hooks/workspace/expanded-sessions';
|
|
12
12
|
import { useWorkspaceFolderActions } from '@/client/hooks/workspace/workspace-folder-actions';
|
|
13
13
|
import { useSessionDelete } from '@/client/hooks/workspace/session-delete';
|
|
@@ -15,6 +15,7 @@ import { SessionDeleteModal } from '@/client/components/common/session-delete-mo
|
|
|
15
15
|
import { getProjectIcon } from '@/shared/lib/workspace/project-icon';
|
|
16
16
|
import { formatFullDate, relativeTimeAgo } from '@/shared/lib/workspace/relative-time';
|
|
17
17
|
import { isPendingSessionId } from '@kabmo-labs/kabmo-omp/session-core/default-title';
|
|
18
|
+
import { workspaceSessionId } from '@/shared/lib/workspace/workspace-session';
|
|
18
19
|
import { useSidebarData } from '@/client/hooks/chat/omp/session-list';
|
|
19
20
|
import type { SessionItemData, WorkspaceFolderData } from '@/shared/types';
|
|
20
21
|
import type { BatchBinding } from '@/client/components/common/batch-selection/types';
|
|
@@ -22,12 +23,15 @@ import { folderBatchState } from '@/client/components/common/batch-selection/fol
|
|
|
22
23
|
import { SelectionCheckbox } from '@/client/components/common/batch-selection/SelectionCheckbox';
|
|
23
24
|
import { SessionRevealRow } from '@/client/components/mobile/mobile-session-sidebar/RevealRow';
|
|
24
25
|
import { folderGroupGap } from '@/client/components/mobile/mobile-session-sidebar/folder-gap';
|
|
26
|
+
import { PRESSED_TOGGLE_CLASS } from '@/client/lib/ui/pressed';
|
|
25
27
|
|
|
26
28
|
interface MobileSessionCategoryProps {
|
|
27
29
|
folder: WorkspaceFolderData;
|
|
28
30
|
activeSessionId: number | string | null;
|
|
29
31
|
onSelectSession: (id: number | string) => void;
|
|
30
32
|
onNewSessionForFolder: (folderId: number) => void;
|
|
33
|
+
/** Open this folder's panels under its per-folder workspace session. */
|
|
34
|
+
onOpenWorkspacePanels: (folderId: number) => void;
|
|
31
35
|
/** Start a chat in a worktree made from this folder. */
|
|
32
36
|
onNewWorktreeSession?: (folderId: number, worktreePath: string) => void;
|
|
33
37
|
isExpanded: boolean;
|
|
@@ -48,6 +52,7 @@ export function MobileSessionCategory({
|
|
|
48
52
|
activeSessionId,
|
|
49
53
|
onSelectSession,
|
|
50
54
|
onNewSessionForFolder,
|
|
55
|
+
onOpenWorkspacePanels,
|
|
51
56
|
onNewWorktreeSession,
|
|
52
57
|
isExpanded,
|
|
53
58
|
onToggleExpand,
|
|
@@ -58,7 +63,7 @@ export function MobileSessionCategory({
|
|
|
58
63
|
onStartSessionSelection,
|
|
59
64
|
onCancelWait,
|
|
60
65
|
}: MobileSessionCategoryProps) {
|
|
61
|
-
const { visibleCount, showMore, showLess, canShowLess } =
|
|
66
|
+
const { visibleCount, showMore, showLess, canShowLess } = useSessionListShowMore();
|
|
62
67
|
// The phone's folder row opens the same dialog the desktop one does. Its state
|
|
63
68
|
// lives in a hook so this row stays under the size ceiling.
|
|
64
69
|
const worktreeDialog = useWorktreeDialog(folder, (worktreePath) =>
|
|
@@ -228,6 +233,28 @@ export function MobileSessionCategory({
|
|
|
228
233
|
|
|
229
234
|
{!batch && (
|
|
230
235
|
<>
|
|
236
|
+
<span className="flex items-center justify-center">
|
|
237
|
+
{isExpanded ? <ChevronDown size={14} /> : <ChevronRight size={14} />}
|
|
238
|
+
</span>
|
|
239
|
+
|
|
240
|
+
<button
|
|
241
|
+
type="button"
|
|
242
|
+
onClick={(event) => {
|
|
243
|
+
event.stopPropagation();
|
|
244
|
+
onOpenWorkspacePanels(folder.id);
|
|
245
|
+
}}
|
|
246
|
+
className={`p-1.5 rounded-lg transition-colors ${
|
|
247
|
+
String(activeSessionId) === workspaceSessionId(folder.id)
|
|
248
|
+
? PRESSED_TOGGLE_CLASS
|
|
249
|
+
: 'hover:bg-ink/10 active:bg-ink/15 text-ink/60 hover:text-ink'
|
|
250
|
+
}`}
|
|
251
|
+
title="Workspace panels"
|
|
252
|
+
aria-label={`Open workspace panels for ${folder.name}`}
|
|
253
|
+
aria-pressed={String(activeSessionId) === workspaceSessionId(folder.id)}
|
|
254
|
+
>
|
|
255
|
+
<FolderOpen size={15} />
|
|
256
|
+
</button>
|
|
257
|
+
|
|
231
258
|
<button
|
|
232
259
|
type="button"
|
|
233
260
|
onClick={(event) => {
|
|
@@ -255,17 +282,6 @@ export function MobileSessionCategory({
|
|
|
255
282
|
onRequestDelete={requestDelete}
|
|
256
283
|
onCancelDelete={cancelDelete}
|
|
257
284
|
/>
|
|
258
|
-
|
|
259
|
-
{/* The disclosure glyph's BOX ends on the list's content edge — the
|
|
260
|
-
same x the toolbar row's last control ends on above it — and its
|
|
261
|
-
ink sits 4px inside it (`pr-1`), which is the inset a session
|
|
262
|
-
row's `⋯` / roster chevron uses. So the drawer's right column is
|
|
263
|
-
one line of INK, not just one line of boxes: measured before, the
|
|
264
|
-
folder chevron's ink ran 6px further right than every row glyph
|
|
265
|
-
beneath it. */}
|
|
266
|
-
<span className="flex items-center justify-center pr-1">
|
|
267
|
-
{isExpanded ? <ChevronDown size={14} /> : <ChevronRight size={14} />}
|
|
268
|
-
</span>
|
|
269
285
|
</>
|
|
270
286
|
)}
|
|
271
287
|
</div>
|
|
@@ -11,6 +11,8 @@ interface MobileSessionListProps {
|
|
|
11
11
|
sessionStatus: Record<string, 'stream' | 'finish' | 'abort'>;
|
|
12
12
|
onSelectSession: (id: number | string) => void;
|
|
13
13
|
onNewSessionForFolder: (folderId: number) => void;
|
|
14
|
+
/** Open this folder's panels under its per-folder workspace session. */
|
|
15
|
+
onOpenWorkspacePanels: (folderId: number) => void;
|
|
14
16
|
/** Start a chat in a worktree made from this folder. */
|
|
15
17
|
onNewWorktreeSession?: (folderId: number, worktreePath: string) => void;
|
|
16
18
|
onToggleFolder: (folderId: number) => void;
|
|
@@ -31,6 +33,7 @@ export function MobileSessionList({
|
|
|
31
33
|
sessionStatus,
|
|
32
34
|
onSelectSession,
|
|
33
35
|
onNewSessionForFolder,
|
|
36
|
+
onOpenWorkspacePanels,
|
|
34
37
|
onNewWorktreeSession,
|
|
35
38
|
onToggleFolder,
|
|
36
39
|
onToast,
|
|
@@ -59,6 +62,7 @@ export function MobileSessionList({
|
|
|
59
62
|
activeSessionId={activeSessionId}
|
|
60
63
|
onSelectSession={onSelectSession}
|
|
61
64
|
onNewSessionForFolder={onNewSessionForFolder}
|
|
65
|
+
onOpenWorkspacePanels={onOpenWorkspacePanels}
|
|
62
66
|
onNewWorktreeSession={onNewWorktreeSession}
|
|
63
67
|
isExpanded={expandedFolders[folder.id] ?? true}
|
|
64
68
|
onToggleExpand={() => onToggleFolder(folder.id)}
|
|
@@ -23,6 +23,7 @@ import { Window } from 'happy-dom';
|
|
|
23
23
|
import { applySettingsSideEffects } from '@/client/components/settings/apply-side-effects';
|
|
24
24
|
import { DEFAULT_SETTINGS } from '@/shared/lib/settings/defaults';
|
|
25
25
|
import { SIDEBAR_STYLE_CHANGED_EVENT } from '@/client/hooks/workspace/sidebar-style';
|
|
26
|
+
import { SESSION_LIST_LIMIT_CHANGED_EVENT } from '@/client/hooks/workspace/session-list-limit';
|
|
26
27
|
import { CHANGED_FILES_CHANGED_EVENT } from '@/client/hooks/chat/timeline/changed-files-setting';
|
|
27
28
|
import { EDITOR_FONT_CHANGED_EVENT } from '@/client/hooks/editor/font';
|
|
28
29
|
import { RIGHT_SIDE_HIDDEN_SCOPE_CHANGED_EVENT } from '@/client/hooks/workspace/right-side';
|
|
@@ -81,6 +82,36 @@ describe('applySettingsSideEffects', () => {
|
|
|
81
82
|
expect(seen).toEqual([]);
|
|
82
83
|
});
|
|
83
84
|
|
|
85
|
+
test('announces the session list page size so the open list repaginates', () => {
|
|
86
|
+
const win = installDom();
|
|
87
|
+
const seen: unknown[] = [];
|
|
88
|
+
win.addEventListener(SESSION_LIST_LIMIT_CHANGED_EVENT, (event) =>
|
|
89
|
+
seen.push((event as unknown as CustomEvent).detail),
|
|
90
|
+
);
|
|
91
|
+
|
|
92
|
+
applySettingsSideEffects(
|
|
93
|
+
state({ sidebarSessionLimit: 5 }),
|
|
94
|
+
state({ sidebarSessionLimit: 25 }),
|
|
95
|
+
);
|
|
96
|
+
|
|
97
|
+
expect(seen).toEqual([25]);
|
|
98
|
+
});
|
|
99
|
+
|
|
100
|
+
test('does not announce a page size that did not move', () => {
|
|
101
|
+
const win = installDom();
|
|
102
|
+
const seen: unknown[] = [];
|
|
103
|
+
win.addEventListener(SESSION_LIST_LIMIT_CHANGED_EVENT, (event) =>
|
|
104
|
+
seen.push((event as unknown as CustomEvent).detail),
|
|
105
|
+
);
|
|
106
|
+
|
|
107
|
+
applySettingsSideEffects(
|
|
108
|
+
state({ sidebarSessionLimit: 10 }),
|
|
109
|
+
state({ sidebarSessionLimit: 10 }),
|
|
110
|
+
);
|
|
111
|
+
|
|
112
|
+
expect(seen).toEqual([]);
|
|
113
|
+
});
|
|
114
|
+
|
|
84
115
|
test('announces the changed-files toggle so the open timeline redraws', () => {
|
|
85
116
|
const win = installDom();
|
|
86
117
|
const seen: unknown[] = [];
|
|
@@ -35,6 +35,7 @@ import { applyChatWidthMode } from '@/client/hooks/chat/timeline/width-mode';
|
|
|
35
35
|
import { applyToolRenderMode } from '@/client/hooks/chat/timeline/tool-render-mode';
|
|
36
36
|
import { applyShowChangedFiles } from '@/client/hooks/chat/timeline/changed-files-setting';
|
|
37
37
|
import { applySidebarStyle } from '@/client/hooks/workspace/sidebar-style';
|
|
38
|
+
import { applySessionListLimit } from '@/client/hooks/workspace/session-list-limit';
|
|
38
39
|
import { applyPanelNav } from '@/client/hooks/workspace/panel-nav';
|
|
39
40
|
import { applyMobilePanelNav } from '@/client/hooks/workspace/mobile-panel-nav';
|
|
40
41
|
import { applyRightSideHiddenScope } from '@/client/hooks/workspace/right-side';
|
|
@@ -106,6 +107,12 @@ export function applySettingsSideEffects(previous: SettingsState, next: Settings
|
|
|
106
107
|
applySidebarStyle(next.sidebarStyle);
|
|
107
108
|
}
|
|
108
109
|
|
|
110
|
+
// The page size is a count the open list is currently drawing, so a saved
|
|
111
|
+
// value has to reach the sidebars without a reload.
|
|
112
|
+
if (next.sidebarSessionLimit !== previous.sidebarSessionLimit) {
|
|
113
|
+
applySessionListLimit(next.sidebarSessionLimit);
|
|
114
|
+
}
|
|
115
|
+
|
|
109
116
|
// A panel column's navigation picks a Preact tree over one column, and both
|
|
110
117
|
// columns are visible behind this modal — so a change repaints on the click.
|
|
111
118
|
// Each side is announced separately: one value must not re-mount the other
|
package/src/client/components/settings/categories/appearance-settings/BorderStyleSection.tsx
CHANGED
|
@@ -89,8 +89,9 @@ export function BorderStyleSection({ settings, onUpdate }: BorderStyleSectionPro
|
|
|
89
89
|
<div>
|
|
90
90
|
<h4 className="text-sm font-semibold text-ink">Rules</h4>
|
|
91
91
|
<p className="mt-0.5 text-[11px] text-ink/60">
|
|
92
|
-
Whether the 1px rules between panels, columns and rows are painted.
|
|
93
|
-
edge either way, and so do validation colours,
|
|
92
|
+
Whether the 1px rules between panels, columns and rows are painted. The chat transcript
|
|
93
|
+
keeps its own rules, controls keep their edge either way, and so do validation colours,
|
|
94
|
+
drop zones and the focus ring.
|
|
94
95
|
</p>
|
|
95
96
|
</div>
|
|
96
97
|
|
package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.test.tsx
ADDED
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* SPDX-License-Identifier: MIT
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* The Session sidebar section carries a COUNT as well as the two style cards.
|
|
8
|
+
* The count must survive as a number — a cleared field must not write `0`
|
|
9
|
+
* (which would draw an empty workspace) — and must be clamped to the range the
|
|
10
|
+
* sidebar can actually draw.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
import { afterAll, afterEach, beforeAll, describe, expect, test } from 'bun:test';
|
|
14
|
+
import { Window } from 'happy-dom';
|
|
15
|
+
import { h, render } from 'preact';
|
|
16
|
+
import { act } from 'preact/test-utils';
|
|
17
|
+
|
|
18
|
+
import { SidebarStyleSection } from '@/client/components/settings/categories/appearance-settings/SidebarStyleSection';
|
|
19
|
+
import { DEFAULT_SETTINGS } from '@/shared/lib/settings/defaults';
|
|
20
|
+
import type { SettingsState } from '@/shared/types';
|
|
21
|
+
import { installDomGlobals, restoreDomGlobals } from '@/test-support/pristine-globals';
|
|
22
|
+
|
|
23
|
+
let container: HTMLElement | null = null;
|
|
24
|
+
let lastUpdate: Partial<SettingsState> | null = null;
|
|
25
|
+
|
|
26
|
+
beforeAll(() => {
|
|
27
|
+
installDomGlobals(new Window({ url: 'http://localhost' }));
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
afterEach(() => {
|
|
31
|
+
if (container) render(null, container);
|
|
32
|
+
container?.remove();
|
|
33
|
+
container = null;
|
|
34
|
+
lastUpdate = null;
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
afterAll(() => {
|
|
38
|
+
restoreDomGlobals();
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
function mount(limit = 10): HTMLInputElement {
|
|
42
|
+
container = document.body.appendChild(document.createElement('div'));
|
|
43
|
+
const onUpdate = (patch: Partial<SettingsState>) => {
|
|
44
|
+
lastUpdate = patch;
|
|
45
|
+
};
|
|
46
|
+
act(() => {
|
|
47
|
+
render(
|
|
48
|
+
h(SidebarStyleSection, {
|
|
49
|
+
settings: { ...DEFAULT_SETTINGS, sidebarSessionLimit: limit },
|
|
50
|
+
onUpdate: onUpdate as (
|
|
51
|
+
updater: Partial<SettingsState> | ((previous: SettingsState) => SettingsState),
|
|
52
|
+
) => void,
|
|
53
|
+
}),
|
|
54
|
+
container as HTMLElement,
|
|
55
|
+
);
|
|
56
|
+
});
|
|
57
|
+
const input = container.querySelector('input[type="number"]');
|
|
58
|
+
if (!input) throw new Error('session count input missing');
|
|
59
|
+
return input as HTMLInputElement;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
function type(input: HTMLInputElement, value: string) {
|
|
63
|
+
input.value = value;
|
|
64
|
+
act(() => {
|
|
65
|
+
input.dispatchEvent(new Event('input', { bubbles: true }));
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
describe('sidebar session count', () => {
|
|
70
|
+
test('renders the stored count and writes a valid number', () => {
|
|
71
|
+
const input = mount(10);
|
|
72
|
+
expect(input.value).toBe('10');
|
|
73
|
+
|
|
74
|
+
type(input, '25');
|
|
75
|
+
expect(lastUpdate).toEqual({ sidebarSessionLimit: 25 });
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
test('clamps a count below the floor and above the ceiling', () => {
|
|
79
|
+
const input = mount(10);
|
|
80
|
+
|
|
81
|
+
type(input, '0');
|
|
82
|
+
expect(lastUpdate).toEqual({ sidebarSessionLimit: 1 });
|
|
83
|
+
|
|
84
|
+
type(input, '999');
|
|
85
|
+
expect(lastUpdate).toEqual({ sidebarSessionLimit: 100 });
|
|
86
|
+
});
|
|
87
|
+
|
|
88
|
+
test('an empty field writes nothing', () => {
|
|
89
|
+
const input = mount(10);
|
|
90
|
+
|
|
91
|
+
type(input, '');
|
|
92
|
+
|
|
93
|
+
expect(lastUpdate).toBeNull();
|
|
94
|
+
});
|
|
95
|
+
});
|
package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.tsx
CHANGED
|
@@ -27,6 +27,11 @@ import {
|
|
|
27
27
|
resolveSidebarStyle,
|
|
28
28
|
type SidebarStyle,
|
|
29
29
|
} from '@/shared/lib/workspace/sidebar-style';
|
|
30
|
+
import {
|
|
31
|
+
MAX_SESSION_LIST_LIMIT,
|
|
32
|
+
MIN_SESSION_LIST_LIMIT,
|
|
33
|
+
resolveSessionListLimit,
|
|
34
|
+
} from '@/shared/lib/workspace/session-list-limit';
|
|
30
35
|
|
|
31
36
|
interface SidebarStyleSectionProps {
|
|
32
37
|
settings: SettingsState;
|
|
@@ -105,6 +110,15 @@ const MINIATURES: Record<SidebarStyle, ComponentType> = {
|
|
|
105
110
|
|
|
106
111
|
export function SidebarStyleSection({ settings, onUpdate }: SidebarStyleSectionProps) {
|
|
107
112
|
const selected = resolveSidebarStyle(settings.sidebarStyle);
|
|
113
|
+
const sessionLimit = resolveSessionListLimit(settings.sidebarSessionLimit);
|
|
114
|
+
|
|
115
|
+
const changeSessionLimit = (raw: string) => {
|
|
116
|
+
if (raw.trim() === '') return;
|
|
117
|
+
const parsed = Number(raw);
|
|
118
|
+
if (!Number.isFinite(parsed)) return;
|
|
119
|
+
const next = resolveSessionListLimit(parsed);
|
|
120
|
+
if (next !== sessionLimit) onUpdate({ sidebarSessionLimit: next });
|
|
121
|
+
};
|
|
108
122
|
|
|
109
123
|
return (
|
|
110
124
|
<section className="space-y-3">
|
|
@@ -152,6 +166,27 @@ export function SidebarStyleSection({ settings, onUpdate }: SidebarStyleSectionP
|
|
|
152
166
|
);
|
|
153
167
|
})}
|
|
154
168
|
</div>
|
|
169
|
+
|
|
170
|
+
<label className="flex items-center justify-between gap-3 rounded-xl border border-ink/15 bg-paper p-2.5">
|
|
171
|
+
<span className="min-w-0">
|
|
172
|
+
<span className="block text-xs font-semibold text-ink">Sessions per workspace</span>
|
|
173
|
+
<span className="mt-0.5 block text-[11px] leading-relaxed text-ink/60">
|
|
174
|
+
How many sessions each workspace lists first; the current sort decides which ones.
|
|
175
|
+
“Show more” reveals another {sessionLimit}. {MIN_SESSION_LIST_LIMIT}–
|
|
176
|
+
{MAX_SESSION_LIST_LIMIT}.
|
|
177
|
+
</span>
|
|
178
|
+
</span>
|
|
179
|
+
<input
|
|
180
|
+
type="number"
|
|
181
|
+
min={MIN_SESSION_LIST_LIMIT}
|
|
182
|
+
max={MAX_SESSION_LIST_LIMIT}
|
|
183
|
+
step={1}
|
|
184
|
+
value={sessionLimit}
|
|
185
|
+
onInput={(event) => changeSessionLimit(event.currentTarget.value)}
|
|
186
|
+
aria-label="Sessions shown per workspace"
|
|
187
|
+
className="h-8 w-16 shrink-0 rounded-md border border-ink/20 bg-paper px-2 text-right font-mono text-xs text-ink focus:border-ink/40 focus:outline-none"
|
|
188
|
+
/>
|
|
189
|
+
</label>
|
|
155
190
|
</section>
|
|
156
191
|
);
|
|
157
192
|
}
|
|
@@ -245,6 +245,7 @@ export function EmptyWorkspacePrompt({
|
|
|
245
245
|
|
|
246
246
|
return (
|
|
247
247
|
<div
|
|
248
|
+
data-chat-timeline=""
|
|
248
249
|
className={`relative flex flex-col h-full bg-canvas ${docked ? '' : isMobile ? 'px-3 py-4' : 'p-8'} ${className}`}
|
|
249
250
|
style={!docked && isMobile ? { paddingBottom: 'max(1rem, env(safe-area-inset-bottom, 0px))' } : undefined}
|
|
250
251
|
>
|
|
@@ -22,6 +22,7 @@ import { h, render } from 'preact';
|
|
|
22
22
|
import { act } from 'preact/test-utils';
|
|
23
23
|
import { ChatMessageItem } from '@/client/components/workspace/chat-timeline/MessageItem';
|
|
24
24
|
import { SessionStateProvider } from '@/client/components/common/session-state-provider';
|
|
25
|
+
import { primeKabmoSettings } from '@/shared/lib/settings/client';
|
|
25
26
|
import type { ChatMessageData } from '@/shared/types';
|
|
26
27
|
|
|
27
28
|
const DOM_GLOBALS = ['window', 'document', 'navigator', 'Node', 'Element', 'HTMLElement', 'HTMLInputElement', 'Event', 'MouseEvent', 'KeyboardEvent'] as const;
|
|
@@ -53,6 +54,8 @@ beforeEach(() => {
|
|
|
53
54
|
if (container) render(null, container);
|
|
54
55
|
container?.remove();
|
|
55
56
|
container = null;
|
|
57
|
+
// A suite that primes `tui` must not leave the next file drawing that style.
|
|
58
|
+
primeKabmoSettings({});
|
|
56
59
|
});
|
|
57
60
|
|
|
58
61
|
/** A user row, and an AI row carrying one tool call — the two framed blocks. */
|
|
@@ -119,4 +122,27 @@ describe('transcript block gutter', () => {
|
|
|
119
122
|
const desktopSection = desktop.querySelector('[data-tool-section]') as HTMLElement;
|
|
120
123
|
expect(desktopSection.className).toContain('mx-3');
|
|
121
124
|
});
|
|
125
|
+
|
|
126
|
+
test('in tui the answer shares the tool row’s edge, on the phone and on desktop', async () => {
|
|
127
|
+
primeKabmoSettings({ kabmo_settings: { toolRenderStyle: 'tui' } });
|
|
128
|
+
|
|
129
|
+
const phone = await mount(toolRow, true);
|
|
130
|
+
const phoneAnswer = phone.querySelector('div.bg-transparent') as HTMLElement;
|
|
131
|
+
// The section adds no gutter on a phone; the TUI row itself starts at
|
|
132
|
+
// `px-1`, so the answer must carry exactly that.
|
|
133
|
+
expect(phone.querySelector('[data-tool-section]')?.className).not.toContain('mx-3');
|
|
134
|
+
expect(phoneAnswer.className).toContain('px-1');
|
|
135
|
+
expect(phoneAnswer.className).not.toContain('px-3');
|
|
136
|
+
render(null, phone);
|
|
137
|
+
phone.remove();
|
|
138
|
+
|
|
139
|
+
const desktop = await mount(toolRow, false);
|
|
140
|
+
const desktopAnswer = desktop.querySelector('div.bg-transparent') as HTMLElement;
|
|
141
|
+
// Desktop insets the section by `mx-3`, so the answer takes the same inset
|
|
142
|
+
// plus the row's `px-1` — the row's visible left edge, not the prose column.
|
|
143
|
+
expect(desktop.querySelector('[data-tool-section]')?.className).toContain('mx-3');
|
|
144
|
+
expect(desktopAnswer.className).toContain('mx-3');
|
|
145
|
+
expect(desktopAnswer.className).toContain('px-1');
|
|
146
|
+
expect(desktopAnswer.className).not.toContain('px-3');
|
|
147
|
+
});
|
|
122
148
|
});
|