@kabmo-labs/kabmo 0.58.1 → 0.59.1
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 +513 -495
- package/dist/client/static/js/{Body-ysmhxbvk.js → Body-5yedtmnk.js} +3 -3
- package/dist/client/static/js/{CsvGrid-w90pxyn2.js → CsvGrid-39m8pp1c.js} +2 -2
- package/dist/client/static/js/{DocxView-evxn6kaq.js → DocxView-vd99cv12.js} +3 -3
- package/dist/client/static/js/{DrawioView-tmdevwf4.js → DrawioView-6nq4412n.js} +2 -2
- package/dist/client/static/js/{HtmlPreview-bpsn2z9p.js → HtmlPreview-cs51gszy.js} +1 -1
- package/dist/client/static/js/ImageView-nc2n0w6s.js +1 -0
- package/dist/client/static/js/LayoutWrapper-j7786frq.js +2 -0
- package/dist/client/static/js/MergeDiffView-0rn5zsy5.js +1 -0
- package/dist/client/static/js/Modal-7ag7a9qq.js +60 -0
- package/dist/client/static/js/{PdfView-txxn6qff.js → PdfView-0zab721q.js} +1 -1
- package/dist/client/static/js/SessionsView-t9rhx472.js +1 -0
- package/dist/client/static/js/{SheetView-52b33e6f.js → SheetView-2wdn5hkd.js} +11 -11
- package/dist/client/static/js/{SvgPreview-hrk4pfm1.js → SvgPreview-fmrfxd7z.js} +1 -1
- package/dist/client/static/js/{abnfDiagram-O67JEVCF-at77sybc.js → abnfDiagram-O67JEVCF-41scfh9v.js} +1 -1
- package/dist/client/static/js/architecture-7GRP2DOG-bwn1drdz.js +1 -0
- package/dist/client/static/js/{architectureDiagram-NJMV4G6O-raw33jgg.js → architectureDiagram-NJMV4G6O-fp6etjvt.js} +3 -3
- package/dist/client/static/js/{astro-qha7sceh.js → astro-ryr2ajmg.js} +1 -1
- package/dist/client/static/js/bash-zknkkwkw.js +1 -0
- package/dist/client/static/js/{blockDiagram-BEXU5L5S-b6e90fbk.js → blockDiagram-BEXU5L5S-pespk9mt.js} +4 -4
- package/dist/client/static/js/c-0w02jkxb.js +1 -0
- package/dist/client/static/js/{c4Diagram-YGBWAQC7-msg9y1c6.js → c4Diagram-YGBWAQC7-rt4z91dx.js} +2 -2
- package/dist/client/static/js/{classDiagram-v2-NBCMYWYE-jmrd1h8r.js → classDiagram-v2-NBCMYWYE-6bzaq8sd.js} +4 -4
- package/dist/client/static/js/{cose-bilkent-JH36ORCC-na65ebq3.js → cose-bilkent-JH36ORCC-z3fhgcba.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-9xkkw71m.js → cynefinDiagram-VND7K2PF-8endeh4p.js} +2 -2
- package/dist/client/static/js/{dagre-6A5THRUB-p59f19tv.js → dagre-6A5THRUB-2a2f32dv.js} +2 -2
- package/dist/client/static/js/{diagram-22UHCM2B-2e2rcvn7.js → diagram-22UHCM2B-wgbyr6b7.js} +9 -9
- package/dist/client/static/js/{diagram-3UASUU5V-r9ds8vgr.js → diagram-3UASUU5V-5122b41x.js} +1 -1
- package/dist/client/static/js/{diagram-ATOU4E4O-jgwxv7v8.js → diagram-ATOU4E4O-1gt9fr7e.js} +3 -3
- package/dist/client/static/js/{diagram-CDSNMT55-20m35eqq.js → diagram-CDSNMT55-v6hs59jb.js} +4 -4
- package/dist/client/static/js/{diagram-MLGK6HIB-vt3kxt2m.js → diagram-MLGK6HIB-yey2m5nm.js} +1 -1
- package/dist/client/static/js/{diagram-MPIPVDR6-c47rgxf1.js → diagram-MPIPVDR6-hg4f3q4d.js} +2 -2
- package/dist/client/static/js/{dockerfile-gtcyey0q.js → dockerfile-56tfnp5r.js} +1 -1
- package/dist/client/static/js/{ebnfDiagram-ZINNZB2B-aszw3xy3.js → ebnfDiagram-ZINNZB2B-2mhc9aar.js} +1 -1
- package/dist/client/static/js/{elixir-w92v180e.js → elixir-fyxw6d70.js} +1 -1
- package/dist/client/static/js/{elk-276RUBZZ-gbvr3gry.js → elk-276RUBZZ-wedtvz9y.js} +2 -2
- package/dist/client/static/js/{erDiagram-OPXOYQCR-1hqca8qe.js → erDiagram-OPXOYQCR-1kysnby9.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-vd4z6bvy.js +1 -0
- package/dist/client/static/js/{ganttDiagram-FUAMR5RP-07v22te5.js → ganttDiagram-FUAMR5RP-j4g65rpm.js} +3 -3
- package/dist/client/static/js/gitGraph-4MIJSDKK-mvqq7tcs.js +1 -0
- package/dist/client/static/js/{gitGraphDiagram-X574FWY7-y068jtz9.js → gitGraphDiagram-X574FWY7-vcwmj4b3.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-r8d4bk86.js → index-10vzyga1.js} +2 -2
- package/dist/client/static/js/index-1mkn5fbf.js +481 -0
- package/dist/client/static/js/{index-medk4f18.js → index-2h7xh93h.js} +2 -2
- package/dist/client/static/js/{index-fhtnvqgf.js → index-3j2he86h.js} +2 -2
- package/dist/client/static/js/{index-zhgh7a31.js → index-3kedv94b.js} +2 -2
- package/dist/client/static/js/{index-374xq5a4.js → index-42k78whj.js} +1 -1
- package/dist/client/static/js/{index-c9aqx3ht.js → index-42q5gg7t.js} +1 -1
- 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-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-th61y26d.js → index-69mnn71v.js} +2 -2
- package/dist/client/static/js/index-6vbra7p9.js +1 -0
- package/dist/client/static/js/{index-007sewcn.js → index-7enfdvh0.js} +2 -2
- package/dist/client/static/js/{index-gaa39w5q.js → index-8tzt0dek.js} +2 -2
- package/dist/client/static/js/{index-ewryzs4g.js → index-92h38pwg.js} +2 -2
- package/dist/client/static/js/{index-vw8b29ek.js → index-9mgpbwfr.js} +1 -1
- package/dist/client/static/js/{index-80kx6dm6.js → index-a3bpmw2r.js} +2 -2
- package/dist/client/static/js/{index-fv7nybnf.js → index-a70sk36c.js} +2 -2
- package/dist/client/static/js/index-c5401dqs.js +4 -0
- package/dist/client/static/js/{index-xmg1x6zv.js → index-csxnqgzw.js} +5 -5
- package/dist/client/static/js/{index-qefssj0m.js → index-d201jvs9.js} +1 -1
- package/dist/client/static/js/{index-y0f3wbc3.js → index-d9sfavx1.js} +2 -2
- package/dist/client/static/js/{index-5hvt233n.js → index-db6s66jr.js} +2 -2
- package/dist/client/static/js/index-dbsy29gn.js +2 -0
- package/dist/client/static/js/{index-j830qk07.js → index-dw9epydj.js} +2 -2
- package/dist/client/static/js/{index-s4dpkds5.js → index-e39m185a.js} +2 -2
- package/dist/client/static/js/{index-dxq1tbwm.js → index-fg0ne74z.js} +2 -2
- package/dist/client/static/js/{index-hb7a7m9m.js → index-fnaq8baz.js} +1 -1
- package/dist/client/static/js/{index-tq3t3qm4.js → index-fsa18ns9.js} +2 -2
- package/dist/client/static/js/{index-wxqcnsrq.js → index-fvphmwkf.js} +2 -2
- package/dist/client/static/js/{index-94d416ee.js → index-gajpd90b.js} +2 -2
- package/dist/client/static/js/{index-rxt8sf9a.js → index-h1xbx74w.js} +2 -2
- package/dist/client/static/js/{index-1e0rt7c6.js → index-hgzf4ask.js} +5 -5
- package/dist/client/static/js/{index-wn28m9h7.js → index-hrez92pw.js} +8 -8
- package/dist/client/static/js/{index-zs7kw0be.js → index-jaf968hx.js} +4 -4
- package/dist/client/static/js/{index-sxag9ptg.js → index-jct0jryd.js} +2 -2
- package/dist/client/static/js/{index-5xxbbzqa.js → index-kt77dwsg.js} +7 -7
- package/dist/client/static/js/{index-8d8ce00v.js → index-m62sf9wn.js} +2 -2
- package/dist/client/static/js/{index-6x0kn8pb.js → index-mhrkjbjq.js} +2 -2
- package/dist/client/static/js/index-mttx9327.css +1 -0
- package/dist/client/static/js/{index-1e710snk.js → index-n7bmqeqz.js} +1 -1
- package/dist/client/static/js/{index-3ymw778n.js → index-ndqtff48.js} +2 -2
- package/dist/client/static/js/{index-cmjyet7w.js → index-nf4hq5tg.js} +27 -27
- package/dist/client/static/js/{index-3p732mvs.js → index-np2rfq06.js} +2 -2
- package/dist/client/static/js/{index-2s17netq.js → index-nwbr15b3.js} +2 -2
- package/dist/client/static/js/{index-nptbz7sv.js → index-pn0ja904.js} +1 -1
- package/dist/client/static/js/{index-azz46nwc.js → index-pr8wsq24.js} +2 -2
- package/dist/client/static/js/{index-7sq6cjt1.js → index-q3k8r0ms.js} +11 -11
- package/dist/client/static/js/{index-an7fq7f6.js → index-qc3de995.js} +1 -1
- package/dist/client/static/js/{index-f61c25vn.js → index-r42f3r1p.js} +3 -3
- package/dist/client/static/js/{index-e4nge3f4.js → index-s7p2wdr1.js} +1 -1
- package/dist/client/static/js/{index-vny4ymjf.js → index-sg65xdey.js} +1 -1
- package/dist/client/static/js/index-skp6991n.js +2 -0
- package/dist/client/static/js/index-spnrx2c0.js +2 -0
- package/dist/client/static/js/{index-fe92hqmb.js → index-sqyvj03y.js} +4 -4
- package/dist/client/static/js/{index-cpp43af3.js → index-tz5ewsza.js} +9 -9
- package/dist/client/static/js/{index-v8xhgfeq.js → index-vs2y8gxr.js} +2 -2
- package/dist/client/static/js/{index-e0kahttb.js → index-vs3g6njv.js} +1 -1
- package/dist/client/static/js/index-wkxsypj1.js +2 -0
- package/dist/client/static/js/{index-gqrt766t.js → index-xqz7bqcn.js} +61 -61
- package/dist/client/static/js/{index-jxsha63v.js → index-y4cx8cqf.js} +2 -2
- package/dist/client/static/js/{index-kzzvrqnv.js → index-y5pkqrga.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-1x83h4k4.js → infoDiagram-VRGFBTTK-7craq9x2.js} +2 -2
- package/dist/client/static/js/ini-62r3vxaf.js +1 -0
- package/dist/client/static/js/{ishikawaDiagram-OU5B5YK6-et6z3c28.js → ishikawaDiagram-OU5B5YK6-ncjty2re.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-sw669e7a.js → journeyDiagram-ZHPQQLJL-yx222bzt.js} +2 -2
- 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-z14p8jsx.js → julia-agc5kfvg.js} +1 -1
- package/dist/client/static/js/{kanban-definition-PNTS6WVX-aqxg95kx.js → kanban-definition-PNTS6WVX-a2f84qmn.js} +6 -6
- 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-9vfwthw3.js +12 -0
- package/dist/client/static/js/{mindmap-definition-NLK3R4M7-530anpc4.js → mindmap-definition-NLK3R4M7-fsxysg6f.js} +4 -4
- package/dist/client/static/js/one-dark-pro-7v4by00h.js +1 -0
- package/dist/client/static/js/one-light-5rfzh8p4.js +1 -0
- package/dist/client/static/js/packet-AYTQ26CC-dgpge627.js +1 -0
- package/dist/client/static/js/{pegDiagram-GJSIUBJH-5zar6hvy.js → pegDiagram-GJSIUBJH-77wxmp9g.js} +1 -1
- package/dist/client/static/js/{perl-1na2x6yd.js → perl-v5vbtzgf.js} +1 -1
- package/dist/client/static/js/{php-x75tt7w3.js → php-83qwy98t.js} +1 -1
- package/dist/client/static/js/pie-WAS4IAKB-b8pgsqrd.js +1 -0
- package/dist/client/static/js/{pieDiagram-5QR66LMP-3bx8syvw.js → pieDiagram-5QR66LMP-gvgfhez0.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-yaarpr2e.js → quadrantDiagram-O4NWA36T-9zkbt5h8.js} +2 -2
- 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-ag41q4nt.js → railroadDiagram-XR7U4H2S-w55bsyw6.js} +1 -1
- package/dist/client/static/js/{requirementDiagram-PLB6GJNP-g8sr48h4.js → requirementDiagram-PLB6GJNP-828s1e5g.js} +3 -3
- package/dist/client/static/js/{ruby-3h22qahv.js → ruby-994n5j6e.js} +1 -1
- package/dist/client/static/js/{rust-r27demr5.js → rust-csv5f258.js} +1 -1
- package/dist/client/static/js/{sankeyDiagram-IPEJSGJF-t1wbd1hh.js → sankeyDiagram-IPEJSGJF-34f3fyvg.js} +3 -3
- package/dist/client/static/js/{sass-8bq5r2tz.js → sass-p6g7qdv2.js} +1 -1
- package/dist/client/static/js/{scss-c04ezwnn.js → scss-4j4t3r6y.js} +1 -1
- package/dist/client/static/js/{sequenceDiagram-PO4LG4MO-407mjqty.js → sequenceDiagram-PO4LG4MO-nnta2hn0.js} +7 -7
- package/dist/client/static/js/{sizeCapture-INFHLROL-w38zb9ky.js → sizeCapture-INFHLROL-gpcramga.js} +1 -1
- package/dist/client/static/js/sql-kwpd5w07.js +1 -0
- package/dist/client/static/js/{stateDiagram-v2-GCMORJYK-4cvgymkc.js → stateDiagram-v2-GCMORJYK-3f2en220.js} +3 -3
- package/dist/client/static/js/{svelte-egg3x4tw.js → svelte-bek3h1sz.js} +1 -1
- package/dist/client/static/js/{swimlanes-2SLR337P-w7ts2rzw.js → swimlanes-2SLR337P-jgqt12z9.js} +1 -1
- package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-xx1z57df.js +8 -0
- package/dist/client/static/js/{timeline-definition-EJHVYXUP-nq46nzy9.js → timeline-definition-EJHVYXUP-sgchcs11.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-q144snzb.js → usecaseDiagram-POWQR4AR-znkg9pkq.js} +15 -15
- package/dist/client/static/js/{vennDiagram-UO4OBE2U-2wemak2p.js → vennDiagram-UO4OBE2U-dncg96ej.js} +4 -4
- package/dist/client/static/js/{vue-d7p4wv35.js → vue-y44m889c.js} +1 -1
- package/dist/client/static/js/wardley-WFR3VGLG-cbqtax1x.js +1 -0
- package/dist/client/static/js/{wardleyDiagram-VNRHLVJA-bb2qvvgr.js → wardleyDiagram-VNRHLVJA-77xz2d49.js} +4 -4
- package/dist/client/static/js/xml-xs6qz3ya.js +1 -0
- package/dist/client/static/js/{xychartDiagram-PMCCYNJV-9dr05fdq.js → xychartDiagram-PMCCYNJV-40j1aqyf.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/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 +8 -1
- package/src/client/components/common/session-row/index.tsx +4 -0
- package/src/client/components/common/session-row/session-row.test.tsx +5 -0
- 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/RevealRow.tsx +36 -5
- package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +45 -28
- package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +10 -3
- package/src/client/components/layout/session-sidebar/modern/index.tsx +2 -0
- package/src/client/components/layout/session-sidebar/modern/reveal-row.test.tsx +28 -1
- package/src/client/components/layout/session-sidebar/modern/workspace-header.test.tsx +27 -11
- 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/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/ThinkingSection.test.tsx +17 -0
- package/src/client/components/workspace/chat-timeline/ThinkingSection.tsx +9 -3
- package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.test.ts +39 -2
- package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.tsx +19 -4
- 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 +44 -21
- 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 +24 -0
- package/src/client/components/workspace/chat-timeline/chat-input/SessionModeDropdown.tsx +14 -3
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.test.ts +24 -1
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.tsx +78 -135
- package/src/client/components/workspace/chat-timeline/chat-input/VoiceButton.tsx +58 -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/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/index.tsx +1 -1
- 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/model-dropdown/CloseButton.tsx +2 -2
- package/src/client/components/workspace/model-dropdown/Fullscreen.tsx +2 -2
- package/src/client/components/workspace/model-dropdown/HarnessTabs.tsx +40 -10
- package/src/client/components/workspace/model-dropdown/Header.tsx +33 -18
- package/src/client/components/workspace/model-dropdown/Panel.tsx +19 -1
- 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 +39 -5
- package/src/client/components/workspace/model-dropdown/index.tsx +20 -47
- package/src/client/components/workspace/model-dropdown/picker-close.test.tsx +34 -4
- 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/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/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/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-ssazqckj.js +0 -1
- package/dist/client/static/js/LayoutWrapper-qwpfq4dq.js +0 -2
- package/dist/client/static/js/MergeDiffView-en6aazw8.js +0 -1
- package/dist/client/static/js/Modal-zjnhj9nb.js +0 -60
- package/dist/client/static/js/SessionsView-eryjtmb2.js +0 -1
- package/dist/client/static/js/architecture-7GRP2DOG-v05ap4e3.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-q2k6afe3.js +0 -1
- package/dist/client/static/js/css-sp1cgdbr.js +0 -1
- package/dist/client/static/js/cynefin-OW5HDTMX-sqv0ze38.js +0 -1
- package/dist/client/static/js/eventmodeling-NTZA5JFV-t4dzf5s7.js +0 -1
- package/dist/client/static/js/flowDiagram-KWPJA3E3-c16xmjyv.js +0 -1
- package/dist/client/static/js/gitGraph-4MIJSDKK-0jq8y0qd.js +0 -1
- package/dist/client/static/js/graphql-qx4tt6ze.js +0 -1
- package/dist/client/static/js/html-5e0g8664.js +0 -1
- package/dist/client/static/js/index-4ddgpqm0.css +0 -1
- package/dist/client/static/js/index-5g2j626a.js +0 -1
- package/dist/client/static/js/index-cc7qbfvn.js +0 -477
- package/dist/client/static/js/index-f27wvdky.js +0 -4
- package/dist/client/static/js/index-m5n0zsft.js +0 -2
- package/dist/client/static/js/index-rqt8mem9.js +0 -2
- package/dist/client/static/js/index-s9k82stc.js +0 -2
- package/dist/client/static/js/index-skwem10a.js +0 -2
- package/dist/client/static/js/index-tv9rn2nd.js +0 -2
- package/dist/client/static/js/info-A6RAGUB7-szttx3v5.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-av46zx4c.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-6cgqsgcf.js +0 -12
- package/dist/client/static/js/one-dark-pro-9hnhtkpr.js +0 -1
- package/dist/client/static/js/one-light-2n5y8592.js +0 -1
- package/dist/client/static/js/packet-AYTQ26CC-401149bv.js +0 -1
- package/dist/client/static/js/pie-WAS4IAKB-bgfv8tfz.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-pw720590.js +0 -1
- package/dist/client/static/js/railroad-74A4TZTK-n2a30ngs.js +0 -1
- package/dist/client/static/js/railroad-abnf-HS5TGJTU-rn5rx9qt.js +0 -1
- package/dist/client/static/js/railroad-ebnf-LZEXJU2U-t4yryhtd.js +0 -1
- package/dist/client/static/js/railroad-peg-WCYAUIDC-c4ebgvrr.js +0 -1
- package/dist/client/static/js/sql-sd00wgem.js +0 -1
- package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-v82nym6b.js +0 -8
- package/dist/client/static/js/treeView-Q6P3EWNA-bxgt5yhm.js +0 -1
- package/dist/client/static/js/treemap-WGGIJYW6-hh3595m0.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-6bza7h1b.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.test.tsx +0 -110
- package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.tsx +0 -86
package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.tsx
CHANGED
|
@@ -18,8 +18,17 @@
|
|
|
18
18
|
* model to put the tradeoff there ("short labels, tradeoffs in `description`"),
|
|
19
19
|
* so it is the half of the option that carries the decision — a row that hides
|
|
20
20
|
* it asks the user to pick blind.
|
|
21
|
+
*
|
|
22
|
+
* A label wider than the row is clipped to one line, and the clipped row grows
|
|
23
|
+
* a chevron that reveals the whole label. The model does not always honour
|
|
24
|
+
* "short labels", and an ellipsized choice is a choice the user cannot read —
|
|
25
|
+
* the control only appears when the label actually overflows, measured on the
|
|
26
|
+
* rendered span, so an ordinary row carries no extra chrome.
|
|
21
27
|
*/
|
|
22
28
|
|
|
29
|
+
import { useEffect, useRef, useState } from 'preact/hooks';
|
|
30
|
+
import { ChevronDown } from 'lucide-preact';
|
|
31
|
+
|
|
23
32
|
interface OptionRowProps {
|
|
24
33
|
label: string;
|
|
25
34
|
description?: string;
|
|
@@ -49,37 +58,85 @@ export function OptionRow({
|
|
|
49
58
|
emphasis,
|
|
50
59
|
onClick,
|
|
51
60
|
}: OptionRowProps) {
|
|
61
|
+
const [expanded, setExpanded] = useState(false);
|
|
62
|
+
const [clipped, setClipped] = useState(false);
|
|
63
|
+
const labelRef = useRef<HTMLSpanElement | null>(null);
|
|
64
|
+
|
|
65
|
+
// Measure while the label is clipped; the expanded state is the answer, not
|
|
66
|
+
// a new measurement. `clientWidth === 0` (a collapsed or non-visual host)
|
|
67
|
+
// must not read as "fits": the row keeps the control rather than hiding a
|
|
68
|
+
// label nobody can check.
|
|
69
|
+
useEffect(() => {
|
|
70
|
+
if (expanded) return;
|
|
71
|
+
const node = labelRef.current;
|
|
72
|
+
if (!node) return;
|
|
73
|
+
const measure = () => {
|
|
74
|
+
setClipped(node.clientWidth === 0 || node.scrollWidth > node.clientWidth + 1);
|
|
75
|
+
};
|
|
76
|
+
measure();
|
|
77
|
+
if (typeof ResizeObserver === 'undefined') return;
|
|
78
|
+
const observer = new ResizeObserver(measure);
|
|
79
|
+
observer.observe(node);
|
|
80
|
+
return () => observer.disconnect();
|
|
81
|
+
}, [expanded, label]);
|
|
82
|
+
|
|
52
83
|
return (
|
|
53
|
-
<
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
? '
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
className={`mt-1 h-3 w-3 shrink-0 ${multi ? 'rounded-[3px]' : 'rounded-full'} border ${
|
|
67
|
-
checked ? 'border-ink bg-ink' : 'border-ink/30'
|
|
84
|
+
<div className="relative">
|
|
85
|
+
<button
|
|
86
|
+
type="button"
|
|
87
|
+
disabled={disabled}
|
|
88
|
+
onClick={onClick}
|
|
89
|
+
className={`flex w-full cursor-pointer items-start gap-2 rounded-md border py-1.5 pl-2.5 text-left text-[11.5px] transition-colors disabled:cursor-default ${
|
|
90
|
+
clipped ? 'pr-7' : 'pr-2.5'
|
|
91
|
+
} ${
|
|
92
|
+
checked
|
|
93
|
+
? 'border-ink/30 bg-ink/5 text-ink'
|
|
94
|
+
: emphasis
|
|
95
|
+
? 'border-ink/20 bg-canvas/60 font-medium text-ink hover:border-ink/40'
|
|
96
|
+
: 'border-ink/8 bg-canvas/30 text-ink/80 hover:border-ink/25 hover:bg-ink/5 hover:text-ink'
|
|
68
97
|
}`}
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
98
|
+
>
|
|
99
|
+
<span
|
|
100
|
+
className={`mt-1 h-3 w-3 shrink-0 ${multi ? 'rounded-[3px]' : 'rounded-full'} border ${
|
|
101
|
+
checked ? 'border-ink bg-ink' : 'border-ink/30'
|
|
102
|
+
}`}
|
|
103
|
+
/>
|
|
104
|
+
<span className="min-w-0 flex-1">
|
|
105
|
+
<span className="flex min-w-0 items-center gap-1.5 font-medium">
|
|
106
|
+
<span
|
|
107
|
+
ref={labelRef}
|
|
108
|
+
data-option-label
|
|
109
|
+
className={expanded ? 'min-w-0 break-words' : 'min-w-0 truncate'}
|
|
110
|
+
>
|
|
111
|
+
{label}
|
|
76
112
|
</span>
|
|
113
|
+
{suggested && (
|
|
114
|
+
<span className="shrink-0 rounded-full bg-ink/5 px-1.5 py-px font-mono text-[10px] uppercase tracking-wider text-ink/45">
|
|
115
|
+
suggested
|
|
116
|
+
</span>
|
|
117
|
+
)}
|
|
118
|
+
</span>
|
|
119
|
+
{description && (
|
|
120
|
+
<span className="mt-0.5 block text-[10.5px] leading-relaxed text-ink/50">{description}</span>
|
|
77
121
|
)}
|
|
78
122
|
</span>
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
123
|
+
</button>
|
|
124
|
+
|
|
125
|
+
{/* Outside the row button (a button cannot nest in a button): expanding
|
|
126
|
+
must never count as picking the option. */}
|
|
127
|
+
{clipped && (
|
|
128
|
+
<button
|
|
129
|
+
type="button"
|
|
130
|
+
disabled={disabled}
|
|
131
|
+
aria-expanded={expanded}
|
|
132
|
+
aria-label={expanded ? 'Collapse the option text' : 'Show the full option text'}
|
|
133
|
+
title={expanded ? 'Collapse' : 'Show full text'}
|
|
134
|
+
onClick={() => setExpanded((current) => !current)}
|
|
135
|
+
className="absolute right-1 top-1 flex h-5 w-5 cursor-pointer items-center justify-center rounded text-ink/35 transition-colors hover:bg-ink/5 hover:text-ink/70 disabled:cursor-default disabled:opacity-40"
|
|
136
|
+
>
|
|
137
|
+
<ChevronDown size={11} className={`transition-transform ${expanded ? 'rotate-180' : ''}`} />
|
|
138
|
+
</button>
|
|
139
|
+
)}
|
|
140
|
+
</div>
|
|
84
141
|
);
|
|
85
142
|
}
|
|
@@ -75,6 +75,24 @@ describe('Mcp panel', () => {
|
|
|
75
75
|
expect(text).toContain('ok');
|
|
76
76
|
});
|
|
77
77
|
|
|
78
|
+
test('an antigravity call_mcp_tool envelope names its server/tool and draws Arguments', async () => {
|
|
79
|
+
const el = await mount(tool({
|
|
80
|
+
name: 'call_mcp_tool',
|
|
81
|
+
input: {
|
|
82
|
+
ServerName: 'chrome-devtools-mcp',
|
|
83
|
+
ToolName: 'new_page',
|
|
84
|
+
Arguments: { url: 'http://127.0.0.1:8765' },
|
|
85
|
+
},
|
|
86
|
+
output: '{"ok":true}',
|
|
87
|
+
}));
|
|
88
|
+
const text = el.textContent ?? '';
|
|
89
|
+
expect(text).toContain('chrome-devtools-mcp / new_page');
|
|
90
|
+
expect(text).toContain('url');
|
|
91
|
+
expect(text).toContain('http://127.0.0.1:8765');
|
|
92
|
+
// The envelope's own keys are the header, not arguments.
|
|
93
|
+
expect(text).not.toContain('ServerName');
|
|
94
|
+
});
|
|
95
|
+
|
|
78
96
|
test('the legacy write xd:// shape still parses its content JSON', async () => {
|
|
79
97
|
const el = await mount(tool({
|
|
80
98
|
type: 'write',
|
|
@@ -2,6 +2,7 @@ import { useMemo } from 'preact/hooks';
|
|
|
2
2
|
import { Boxes, Braces } from 'lucide-preact';
|
|
3
3
|
import type { ToolCallData } from '@/shared/types';
|
|
4
4
|
import { soleToolCommand } from '@kabmo-labs/kabmo-chat/tool/tool-commands';
|
|
5
|
+
import { mcpCallArguments, mcpCallIdentity } from '@kabmo-labs/kabmo-chat/tool/render-key';
|
|
5
6
|
import { tryParseJson } from '@/shared/lib/code/syntax-highlight';
|
|
6
7
|
import { isRecord } from '@kabmo-labs/kabmo-guards';
|
|
7
8
|
import { MarkdownRenderer } from '@/client/components/common/MarkdownRenderer';
|
|
@@ -94,17 +95,23 @@ function ObjectNode({ data }: { data: Record<string, unknown> }) {
|
|
|
94
95
|
/** Panel untuk tool MCP. Tiga bentuk pemanggilan, satu panel: `write xd://mcp__<tool>`
|
|
95
96
|
* (sesi sebelum 19.1.0), `mcp__<tool>` top-level, dan tool command
|
|
96
97
|
* (`bash` yang menjalankan `mcp__<tool> --flag …`, dengan argumen terurai di
|
|
97
|
-
* `details.toolCommands[].args`).
|
|
98
|
-
*
|
|
99
|
-
*
|
|
98
|
+
* `details.toolCommands[].args`). The fourth shape is antigravity's
|
|
99
|
+
* `call_mcp_tool` envelope (`{ServerName, ToolName, Arguments}`), whose
|
|
100
|
+
* identity is read structurally from the input. Argumen dirender per key;
|
|
101
|
+
* value non-JSON sebagai markdown; JSON list sebagai list. Output fallback ke
|
|
102
|
+
* FallbackOutput, atau per-key bila hasilnya juga JSON object/list. */
|
|
100
103
|
export function Mcp({ tool }: { tool: ToolCallData }) {
|
|
101
104
|
const inputObj =
|
|
102
105
|
typeof tool.input === 'object' && tool.input !== null ? (tool.input as Record<string, unknown>) : undefined;
|
|
103
106
|
|
|
104
107
|
const command = soleToolCommand(tool);
|
|
108
|
+
const identity = mcpCallIdentity(inputObj);
|
|
109
|
+
const identityArgs = mcpCallArguments(inputObj);
|
|
105
110
|
const path = typeof inputObj?.path === 'string' ? inputObj.path : tool.target || '';
|
|
106
111
|
const name = command?.dispatch.tool ?? (typeof tool.name === 'string' ? tool.name : '');
|
|
107
|
-
const device =
|
|
112
|
+
const device = identity
|
|
113
|
+
? `${identity.server} / ${identity.tool}`
|
|
114
|
+
: (path ? path.replace(/^xd:\/\//, '') : name).replace(/^mcp__/, '');
|
|
108
115
|
// A tool command's arguments were parsed against the tool's schema; the
|
|
109
116
|
// legacy `write` shape carries them as JSON text in `content`.
|
|
110
117
|
const content = command
|
|
@@ -120,7 +127,9 @@ export function Mcp({ tool }: { tool: ToolCallData }) {
|
|
|
120
127
|
// header and result but never the arguments it asked with.
|
|
121
128
|
const argsData = content
|
|
122
129
|
? (parsedArgs.isValid ? parsedArgs.data : undefined)
|
|
123
|
-
:
|
|
130
|
+
: identityArgs !== undefined
|
|
131
|
+
? identityArgs
|
|
132
|
+
: inputObj;
|
|
124
133
|
const argsStructured = isRecord(argsData) || Array.isArray(argsData);
|
|
125
134
|
|
|
126
135
|
const parsedOutput = useMemo(() => (tool.output ? tryParseJson(tool.output) : { isValid: false }), [tool.output]);
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
* strip, so the phone spent TWO chrome rows (85px of an 844px screen) on a
|
|
12
12
|
* surface whose whole job is to list models, and the word named the thing the
|
|
13
13
|
* user had just tapped. The control now rides the strip's trailing edge (or the
|
|
14
|
-
*
|
|
15
|
-
* header at all.
|
|
14
|
+
* Add new provider row when the picker offers no harness tabs), and the frame
|
|
15
|
+
* draws no header at all.
|
|
16
16
|
*
|
|
17
17
|
* One component for both rows, because the button has to look the same wherever
|
|
18
18
|
* the first band lands — a second `X` written inline is how the two would pick
|
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
* content was the word "Model" and a 28px `X`, sitting above a 49px harness tab
|
|
18
18
|
* strip — two chrome rows where every other phone surface has one, and a label
|
|
19
19
|
* that named the thing the user had just tapped. The close control now rides the
|
|
20
|
-
* picker's own first row (the harness tabs, or the
|
|
21
|
-
* offers no tabs), which is what removes the second band without leaving
|
|
20
|
+
* picker's own first row (the harness tabs, or the Add new provider row when the
|
|
21
|
+
* picker offers no tabs), which is what removes the second band without leaving
|
|
22
22
|
* dialog undismissable: `ModelDropdownPanel` renders it into `headerActions`.
|
|
23
23
|
*
|
|
24
24
|
* PORTALLED to `<body>`, not rendered in place. The composer card can become a
|
|
@@ -31,6 +31,7 @@
|
|
|
31
31
|
|
|
32
32
|
import type { ComponentChildren } from 'preact';
|
|
33
33
|
import { HarnessGlyph, HARNESS_GLYPH_SIZE } from '@/client/components/common/harness-glyph';
|
|
34
|
+
import { PICKER_BAND_HEIGHT, PICKER_STRIP_INSET, PICKER_STRIP_SHIFT } from '@/client/components/workspace/model-dropdown/bands';
|
|
34
35
|
import type { HarnessSummary } from '@kabmo-labs/kabmo-app-contracts/harness';
|
|
35
36
|
|
|
36
37
|
interface HarnessTabsProps {
|
|
@@ -134,9 +135,17 @@ export function harnessTabReason(summary: HarnessSummary, title: string): string
|
|
|
134
135
|
* is fixed), the current one is already selected, and the rest switch the pick.
|
|
135
136
|
* `cursor-help` (an earlier value) is drawn on macOS as a question mark, which
|
|
136
137
|
* read as a stray icon over an icon-only tab.
|
|
138
|
+
*
|
|
139
|
+
* The active fill is the app's selected-chip tint (`bg-ink/10`, the same family
|
|
140
|
+
* `TabChip` uses), NOT `bg-paper`: the strip is a translucent band over the
|
|
141
|
+
* popover, so a paper fill and the popover behind it differ by ~2% in the light
|
|
142
|
+
* theme and the selected tab read as an unselected one. The bar is drawn as a
|
|
143
|
+
* real element rather than `shadow-[inset_…]` because the arbitrary shadow
|
|
144
|
+
* resolved to the transparent default in a WebKit build (measured: `--tw-shadow`
|
|
145
|
+
* stayed `0 0 #0000`), leaving no indicator at all.
|
|
137
146
|
*/
|
|
138
147
|
function tabTone(isActive: boolean, blocked: boolean): string {
|
|
139
|
-
if (isActive) return 'bg-
|
|
148
|
+
if (isActive) return 'bg-ink/10 text-ink cursor-pointer';
|
|
140
149
|
return blocked
|
|
141
150
|
? 'text-ink/35 cursor-pointer'
|
|
142
151
|
: 'text-ink/65 hover:bg-ink/5 hover:text-ink cursor-pointer';
|
|
@@ -151,10 +160,19 @@ export function HarnessTabs({ harnesses, active, onSelect, onFix, actions }: Har
|
|
|
151
160
|
// collapsed to 5px — the tabs were in the DOM and painted 1px tall
|
|
152
161
|
// (measured: `elementFromPoint` on the first tab answered the row BELOW
|
|
153
162
|
// it). The list scrolls inside itself; the strip must not.
|
|
154
|
-
className=
|
|
163
|
+
className={`relative flex-none ${PICKER_BAND_HEIGHT} ${PICKER_STRIP_SHIFT} flex items-stretch bg-canvas/40`}
|
|
155
164
|
>
|
|
156
165
|
<div
|
|
157
|
-
|
|
166
|
+
// Horizontal scroll ONLY. `overflow-x-auto` computes `overflow-y` to
|
|
167
|
+
// `auto` too, and `.scrollbar-overlay-container` (which the strip used
|
|
168
|
+
// to carry) states the same axis — so on a browser whose styled 8px
|
|
169
|
+
// scrollbar takes layout space, the track cut the 48px band's content
|
|
170
|
+
// box to 40px while a coarse tab stays 44px: 4px of vertical overflow,
|
|
171
|
+
// measured, and a vertical bar over the harness marks. `no-scrollbar`
|
|
172
|
+
// keeps the horizontal track out of layout entirely (the same choice
|
|
173
|
+
// `TabStrip` makes), and `overflow-y-hidden` keeps a vertical gesture
|
|
174
|
+
// going to the model list instead of this strip.
|
|
175
|
+
className={`no-scrollbar flex min-w-0 flex-1 items-stretch gap-0.5 overflow-x-auto overflow-y-hidden ${PICKER_STRIP_INSET} pr-1`}
|
|
158
176
|
role="tablist"
|
|
159
177
|
aria-label="Harness"
|
|
160
178
|
// The one surface where a harness HUE is not decoration: with no label in
|
|
@@ -211,13 +229,17 @@ export function HarnessTabs({ harnesses, active, onSelect, onFix, actions }: Har
|
|
|
211
229
|
}
|
|
212
230
|
onSelect(summary.id);
|
|
213
231
|
}}
|
|
214
|
-
// `relative` for the ⚠ badge, `p-1.5` so the
|
|
215
|
-
//
|
|
216
|
-
//
|
|
217
|
-
//
|
|
218
|
-
// icon-only tab pressable on a phone.
|
|
232
|
+
// `relative` for the active bar and the ⚠ badge, `p-1.5` so the
|
|
233
|
+
// strip stays compact: the tab is the mark ALONE, so the padding is
|
|
234
|
+
// the whole frame. `tap-chip` still raises it to 44px on a coarse
|
|
235
|
+
// pointer, which is what keeps an icon-only tab pressable on a phone.
|
|
219
236
|
className={`tap-chip relative flex shrink-0 items-center justify-center rounded-t p-1.5 transition-colors ${tabTone(isActive, Boolean(block))}`}
|
|
220
237
|
>
|
|
238
|
+
{/* The selected tab's bar. A real element, not a box-shadow: see
|
|
239
|
+
`tabTone` for the measured reason the shadow never painted. */}
|
|
240
|
+
{isActive && (
|
|
241
|
+
<span aria-hidden="true" className="absolute inset-x-1 bottom-0 h-[2px] rounded-full bg-ink" />
|
|
242
|
+
)}
|
|
221
243
|
{/* `inherit`, because the button's colour is now the only thing that
|
|
222
244
|
says active / muted: the mark used to be one of two children and
|
|
223
245
|
its own `text-ink/55` was the default it shared with every row.
|
|
@@ -234,7 +256,7 @@ export function HarnessTabs({ harnesses, active, onSelect, onFix, actions }: Har
|
|
|
234
256
|
one level up. */}
|
|
235
257
|
<HarnessGlyph
|
|
236
258
|
harness={summary.id}
|
|
237
|
-
size={HARNESS_GLYPH_SIZE.
|
|
259
|
+
size={HARNESS_GLYPH_SIZE.compact}
|
|
238
260
|
inherit
|
|
239
261
|
decorative
|
|
240
262
|
className={block ? 'opacity-40' : ''}
|
|
@@ -257,10 +279,18 @@ export function HarnessTabs({ harnesses, active, onSelect, onFix, actions }: Har
|
|
|
257
279
|
`titlebar-no-drag` because the row above it is the window's handle in a
|
|
258
280
|
native shell. */}
|
|
259
281
|
{actions ? (
|
|
260
|
-
<div className="flex flex-none items-center gap-0.5 px-1.5
|
|
282
|
+
<div className="flex flex-none items-center gap-0.5 px-1.5 titlebar-no-drag">
|
|
261
283
|
{actions}
|
|
262
284
|
</div>
|
|
263
285
|
) : null}
|
|
286
|
+
{/* The strip's bottom rule is DRAWN, not a border: the phone's 36px close
|
|
287
|
+
plate must fit the band's content box exactly, and `border-b` inside
|
|
288
|
+
`h-9` leaves it 35px and pushes the control half a pixel off the
|
|
289
|
+
frame's top edge (measured y = -0.5). */}
|
|
290
|
+
<span
|
|
291
|
+
aria-hidden="true"
|
|
292
|
+
className="pointer-events-none absolute inset-x-0 bottom-0 h-px bg-ink/10"
|
|
293
|
+
/>
|
|
264
294
|
</div>
|
|
265
295
|
);
|
|
266
296
|
}
|
|
@@ -1,14 +1,19 @@
|
|
|
1
1
|
import { Plus, Search, X } from 'lucide-preact';
|
|
2
2
|
import type { ComponentChildren } from 'preact';
|
|
3
|
+
import { PICKER_BAND_HEIGHT } from '@/client/components/workspace/model-dropdown/bands';
|
|
3
4
|
|
|
4
5
|
interface ModelDropdownHeaderProps {
|
|
5
6
|
search: string;
|
|
6
7
|
onSearchChange: (value: string) => void;
|
|
7
8
|
onAddProvider?: () => void;
|
|
8
9
|
/**
|
|
9
|
-
* Trailing controls on the
|
|
10
|
-
* button here when it offers no harness tabs, so the frame never
|
|
11
|
-
* header row of its own.
|
|
10
|
+
* Trailing controls on the Add new provider row. The full-screen picker puts
|
|
11
|
+
* its close button here when it offers no harness tabs, so the frame never
|
|
12
|
+
* needs a header row of its own.
|
|
13
|
+
*
|
|
14
|
+
* This row is a real row — the action button and this slot are SIBLINGS, not
|
|
15
|
+
* a button nested in a button — so pressing the close control cannot also
|
|
16
|
+
* fire `onAddProvider`.
|
|
12
17
|
*/
|
|
13
18
|
actions?: ComponentChildren;
|
|
14
19
|
}
|
|
@@ -20,22 +25,33 @@ export function ModelDropdownHeader({
|
|
|
20
25
|
actions,
|
|
21
26
|
}: ModelDropdownHeaderProps) {
|
|
22
27
|
return (
|
|
23
|
-
<div className="flex flex-col
|
|
24
|
-
{/* Top Add New Provider
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
28
|
+
<div className="flex shrink-0 flex-col bg-canvas/40">
|
|
29
|
+
{/* Top Add New Provider row. The trailing slot holds the picker's close
|
|
30
|
+
control when this row is the frame's first band (the picker offers no
|
|
31
|
+
harness strip). */}
|
|
32
|
+
<div className={`flex ${PICKER_BAND_HEIGHT} items-stretch border-b border-ink/5 pr-2`}>
|
|
33
|
+
<button
|
|
34
|
+
type="button"
|
|
35
|
+
onClick={onAddProvider}
|
|
36
|
+
className="flex min-w-0 flex-1 items-center gap-2 pl-2.5 pr-3 text-xs text-ink/70 hover:text-ink hover:bg-ink/5 transition-colors text-left font-medium cursor-pointer"
|
|
37
|
+
>
|
|
38
|
+
{/* The 18px slot is the picker's icon rail: every band's leading mark
|
|
39
|
+
centres in it (the section heading, the row's grip, the thinking
|
|
40
|
+
strip and the search field), so the marks read as one column. */}
|
|
41
|
+
<span className="inline-flex h-[18px] w-[18px] shrink-0 items-center justify-center">
|
|
42
|
+
<Plus size={14} className="text-ink/60" />
|
|
43
|
+
</span>
|
|
44
|
+
<span>Add new provider</span>
|
|
45
|
+
</button>
|
|
46
|
+
{actions ? <div className="flex flex-none items-center titlebar-no-drag">{actions}</div> : null}
|
|
47
|
+
</div>
|
|
33
48
|
|
|
34
|
-
{/* Search Input.
|
|
35
|
-
|
|
36
|
-
<div className="flex items-center gap-1 p-2 bg-canvas/60">
|
|
49
|
+
{/* Search Input. */}
|
|
50
|
+
<div className={`flex ${PICKER_BAND_HEIGHT} items-center gap-1 pl-2.5 pr-2 border-b border-ink/10 bg-canvas/60`}>
|
|
37
51
|
<div className="flex min-w-0 flex-1 items-center">
|
|
38
|
-
<
|
|
52
|
+
<span className="mr-2 inline-flex h-[18px] w-[18px] shrink-0 items-center justify-center">
|
|
53
|
+
<Search size={13} className="text-ink/40" />
|
|
54
|
+
</span>
|
|
39
55
|
<input
|
|
40
56
|
type="text"
|
|
41
57
|
value={search}
|
|
@@ -55,7 +71,6 @@ export function ModelDropdownHeader({
|
|
|
55
71
|
</button>
|
|
56
72
|
)}
|
|
57
73
|
</div>
|
|
58
|
-
{actions ? <div className="flex flex-none items-center titlebar-no-drag">{actions}</div> : null}
|
|
59
74
|
</div>
|
|
60
75
|
</div>
|
|
61
76
|
);
|
|
@@ -2,6 +2,7 @@ import type { TargetedMouseEvent } from 'preact';
|
|
|
2
2
|
import { useCallback, useLayoutEffect, useRef, useState } from 'preact/hooks';
|
|
3
3
|
import type { AIModelOption } from '@/shared/types';
|
|
4
4
|
import { ModelDropdownHeader } from '@/client/components/workspace/model-dropdown/Header';
|
|
5
|
+
import { ModelThinkingLevels } from '@/client/components/workspace/model-dropdown/ThinkingLevels';
|
|
5
6
|
import { ModelDropdownSection } from '@/client/components/workspace/model-dropdown/Section';
|
|
6
7
|
import { ModelDropdownFooter } from '@/client/components/workspace/model-dropdown/Footer';
|
|
7
8
|
import { ModelDropdownSkeleton } from '@/client/components/workspace/model-dropdown/Skeleton';
|
|
@@ -36,6 +37,10 @@ interface ModelDropdownPanelProps {
|
|
|
36
37
|
onSelect: (model: AIModelOption) => void;
|
|
37
38
|
onToggleFavorite: (model: AIModelOption, e: TargetedMouseEvent<HTMLElement>) => void;
|
|
38
39
|
onCycleThinking: (model: AIModelOption, e: TargetedMouseEvent<HTMLElement>) => void;
|
|
40
|
+
/** Thinking ladder of the selected model, and the level in force. */
|
|
41
|
+
thinkingLevels?: string[];
|
|
42
|
+
currentThinking?: string;
|
|
43
|
+
onSelectThinking?: (level: string) => void;
|
|
39
44
|
/** Row index in the flat list; the panel resolves it to the row it renders. */
|
|
40
45
|
onHoverItem: (index: number) => void;
|
|
41
46
|
onMouseLeave: () => void;
|
|
@@ -88,6 +93,9 @@ export function ModelDropdownPanel({
|
|
|
88
93
|
onSelect,
|
|
89
94
|
onToggleFavorite,
|
|
90
95
|
onCycleThinking,
|
|
96
|
+
thinkingLevels,
|
|
97
|
+
currentThinking,
|
|
98
|
+
onSelectThinking,
|
|
91
99
|
onHoverItem,
|
|
92
100
|
onMouseLeave,
|
|
93
101
|
harnesses = [],
|
|
@@ -171,7 +179,7 @@ export function ModelDropdownPanel({
|
|
|
171
179
|
|
|
172
180
|
In the full-screen placement the strip is the FRAME's first row, so
|
|
173
181
|
it carries the close control when it exists; otherwise the control
|
|
174
|
-
rides the
|
|
182
|
+
rides the Add new provider row. */}
|
|
175
183
|
{showTabs && (
|
|
176
184
|
<HarnessTabs
|
|
177
185
|
harnesses={harnesses}
|
|
@@ -188,6 +196,16 @@ export function ModelDropdownPanel({
|
|
|
188
196
|
{...(fullscreen && !showTabs ? { actions: <PickerCloseButton onClose={onClose} /> } : {})}
|
|
189
197
|
/>
|
|
190
198
|
|
|
199
|
+
{/* The thinking ladder is part of THIS choice: model + level are one
|
|
200
|
+
control, so the strip sits between the search and the rows. */}
|
|
201
|
+
{thinkingLevels && currentThinking && onSelectThinking && (
|
|
202
|
+
<ModelThinkingLevels
|
|
203
|
+
levels={thinkingLevels}
|
|
204
|
+
current={currentThinking}
|
|
205
|
+
onSelect={onSelectThinking}
|
|
206
|
+
/>
|
|
207
|
+
)}
|
|
208
|
+
|
|
191
209
|
{/* Scrollable Model Lists. Deliberately no top padding: Chrome's
|
|
192
210
|
sticky view rectangle is the scrollport's CONTENT box, so a
|
|
193
211
|
`sticky top-0` heading inside a padded list pins below the padding
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Brain } from 'lucide-preact';
|
|
2
|
+
import { PICKER_BAND_HEIGHT } from '@/client/components/workspace/model-dropdown/bands';
|
|
3
|
+
|
|
4
|
+
interface ModelThinkingLevelsProps {
|
|
5
|
+
levels: string[];
|
|
6
|
+
current: string;
|
|
7
|
+
onSelect: (level: string) => void;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* The thinking ladder that used to be its own composer dropdown.
|
|
12
|
+
*
|
|
13
|
+
* It lives INSIDE the model picker now: model and level are one choice, and the
|
|
14
|
+
* panel already owns the selected model's ladder. An empty ladder means the
|
|
15
|
+
* model exposes no level, so the strip is not drawn at all rather than showing
|
|
16
|
+
* a control that cannot change anything.
|
|
17
|
+
*/
|
|
18
|
+
export function ModelThinkingLevels({ levels, current, onSelect }: ModelThinkingLevelsProps) {
|
|
19
|
+
if (levels.length === 0) return null;
|
|
20
|
+
|
|
21
|
+
return (
|
|
22
|
+
<div
|
|
23
|
+
role="group"
|
|
24
|
+
aria-label="Thinking level"
|
|
25
|
+
className={`flex ${PICKER_BAND_HEIGHT} flex-wrap items-center gap-1 border-b border-ink/10 bg-canvas/30 pl-2.5 pr-2`}
|
|
26
|
+
>
|
|
27
|
+
<span className="inline-flex items-center gap-1 pr-1 text-[10px] font-semibold uppercase tracking-wider text-ink/40">
|
|
28
|
+
{/* The same 18px rail the header and the section headings use. */}
|
|
29
|
+
<span className="inline-flex h-[18px] w-[18px] shrink-0 items-center justify-center">
|
|
30
|
+
<Brain size={11} />
|
|
31
|
+
</span>
|
|
32
|
+
Thinking
|
|
33
|
+
</span>
|
|
34
|
+
{levels.map((level) => (
|
|
35
|
+
<button
|
|
36
|
+
key={level}
|
|
37
|
+
type="button"
|
|
38
|
+
aria-pressed={current === level}
|
|
39
|
+
onClick={() => onSelect(level)}
|
|
40
|
+
className={`rounded border px-1.5 py-0.5 font-mono text-[10px] transition-colors cursor-pointer ${
|
|
41
|
+
current === level
|
|
42
|
+
? 'border-ink/20 bg-ink/10 font-semibold text-ink'
|
|
43
|
+
: 'border-ink/10 text-ink/60 hover:bg-ink/5'
|
|
44
|
+
}`}
|
|
45
|
+
>
|
|
46
|
+
{level}
|
|
47
|
+
</button>
|
|
48
|
+
))}
|
|
49
|
+
</div>
|
|
50
|
+
);
|
|
51
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { ChevronDown, Sparkles } from 'lucide-preact';
|
|
2
|
+
import type { AIModelOption } from '@/shared/types';
|
|
3
|
+
import { ProviderIconPlate, type ProviderMarkSource } from '@/client/components/common/provider-icon/Plate';
|
|
4
|
+
import { HarnessGlyph, HARNESS_GLYPH_SIZE } from '@/client/components/common/harness-glyph';
|
|
5
|
+
|
|
6
|
+
interface ModelDropdownTriggerProps {
|
|
7
|
+
selectedModel?: AIModelOption;
|
|
8
|
+
mark: ProviderMarkSource | null;
|
|
9
|
+
harness: string;
|
|
10
|
+
/**
|
|
11
|
+
* Thinking level in force. The picker is the ONE control for model + level, so
|
|
12
|
+
* the level rides the label instead of a second dropdown beside it.
|
|
13
|
+
*/
|
|
14
|
+
thinkingLevel?: string;
|
|
15
|
+
/** The model's ladder. Empty means the model exposes no level to draw. */
|
|
16
|
+
thinkingLevels?: string[];
|
|
17
|
+
onClick: () => void;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The composer's model trigger.
|
|
22
|
+
*
|
|
23
|
+
* Provider and model are two labels with a separator between them. The PROVIDER
|
|
24
|
+
* never truncates: `kenari` and `kenari-jatis` are two accounts, and an ellipsis
|
|
25
|
+
* made them render identically. The MODEL takes the slack, because it is the
|
|
26
|
+
* part the reader is choosing and the only part whose identity survives a cut.
|
|
27
|
+
*
|
|
28
|
+
* The thinking level trails the pair as a small badge: it is the same control's
|
|
29
|
+
* second dimension, not a separate picker.
|
|
30
|
+
*/
|
|
31
|
+
export function ModelDropdownTrigger({
|
|
32
|
+
selectedModel,
|
|
33
|
+
mark,
|
|
34
|
+
harness,
|
|
35
|
+
thinkingLevel,
|
|
36
|
+
thinkingLevels,
|
|
37
|
+
onClick,
|
|
38
|
+
}: ModelDropdownTriggerProps) {
|
|
39
|
+
const showThinking = Boolean(thinkingLevel) && (thinkingLevels?.length ?? 0) > 0;
|
|
40
|
+
const title = selectedModel
|
|
41
|
+
? `${selectedModel.provider} • ${selectedModel.name}${showThinking ? ` • ${thinkingLevel}` : ''}`
|
|
42
|
+
: 'Select a model';
|
|
43
|
+
|
|
44
|
+
return (
|
|
45
|
+
<button
|
|
46
|
+
type="button"
|
|
47
|
+
onClick={onClick}
|
|
48
|
+
className="tap-chip flex items-center space-x-1.5 hover:bg-ink/5 px-2 py-1 rounded transition-colors text-xs text-muted font-medium cursor-pointer min-w-0 max-w-full"
|
|
49
|
+
title={title}
|
|
50
|
+
>
|
|
51
|
+
{selectedModel ? (
|
|
52
|
+
<>
|
|
53
|
+
{/* Harness MARK, then the provider plate: the same two-mark order
|
|
54
|
+
the rows use, so the trigger and the list cannot describe two
|
|
55
|
+
different things. `decorative` for the same measured reason as
|
|
56
|
+
the tabs: a nested `title` is the one the browser shows, so this
|
|
57
|
+
component's "Session runs on omp" replaced the trigger's own
|
|
58
|
+
`provider • model`. */}
|
|
59
|
+
<HarnessGlyph harness={harness} size={HARNESS_GLYPH_SIZE.compact} decorative />
|
|
60
|
+
{selectedModel.isCmdAgent ? (
|
|
61
|
+
<span className="inline-flex items-center justify-center w-[16px] h-[16px] rounded-[4px] border border-ink/20 bg-ink/5 text-ink/70 flex-shrink-0 font-mono text-[10px] font-bold">
|
|
62
|
+
⌘
|
|
63
|
+
</span>
|
|
64
|
+
) : (
|
|
65
|
+
<ProviderIconPlate provider={mark ?? {}} size={16} />
|
|
66
|
+
)}
|
|
67
|
+
{/* Provider, model and level are one dot-separated label. Neither name
|
|
68
|
+
is capped: with room, both show in full. The PROVIDER carries the
|
|
69
|
+
shrink so it yields FIRST when the label is squeezed, with a 4ch
|
|
70
|
+
floor so it never disappears; the MODEL keeps its content until the
|
|
71
|
+
provider is exhausted. The LEVEL never shrinks (`shrink-0`,
|
|
72
|
+
`whitespace-nowrap`) because it is the choice the trigger has to
|
|
73
|
+
report even then. */}
|
|
74
|
+
<span className="flex items-baseline gap-1 min-w-0 text-left">
|
|
75
|
+
<span className="min-w-0 truncate text-muted font-normal" style={{ flex: '0 100 auto', minWidth: '4ch' }}>{selectedModel.provider}</span>
|
|
76
|
+
<span className="text-ink/50 shrink-0">•</span>
|
|
77
|
+
<span className="min-w-0 truncate">{selectedModel.name}</span>
|
|
78
|
+
{showThinking && (
|
|
79
|
+
<>
|
|
80
|
+
<span className="text-ink/50 shrink-0">•</span>
|
|
81
|
+
<span className="shrink-0 whitespace-nowrap text-ink/55">{thinkingLevel}</span>
|
|
82
|
+
</>
|
|
83
|
+
)}
|
|
84
|
+
</span>
|
|
85
|
+
</>
|
|
86
|
+
) : (
|
|
87
|
+
/* No selection yet: the list is still loading or the registry came
|
|
88
|
+
back empty. Show a pulse placeholder rather than a made-up model. */
|
|
89
|
+
<>
|
|
90
|
+
<span className="text-ink/60 flex-shrink-0">
|
|
91
|
+
<Sparkles size={12} className="text-ink/60" />
|
|
92
|
+
</span>
|
|
93
|
+
<span className="h-3 w-28 rounded animate-pulse bg-ink/10" />
|
|
94
|
+
</>
|
|
95
|
+
)}
|
|
96
|
+
<ChevronDown size={12} className="text-ink/40 flex-shrink-0" />
|
|
97
|
+
</button>
|
|
98
|
+
);
|
|
99
|
+
}
|