@nextclaw/ui 0.15.10 → 0.15.12
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/CHANGELOG.md +53 -0
- package/dist/assets/{abnfDiagram-VRR7QNED-BYpK0F5F.js → abnfDiagram-VRR7QNED-M4g_AyR8.js} +1 -1
- package/dist/assets/{aiden0z-pptx-renderer.es-D87ywFdC.js → aiden0z-pptx-renderer.es-Bd99vut2.js} +1 -1
- package/dist/assets/api-Bw1oLhwf.js +13 -0
- package/dist/assets/app-presenter-provider-DSN90VJw.js +106 -0
- package/dist/assets/appearance-settings-page-BDpels6a.js +1 -0
- package/dist/assets/{arc-DFELHWM2.js → arc-IO7WNWOB.js} +1 -1
- package/dist/assets/architecture-TIHT7OUA-Cii4JyA2.js +1 -0
- package/dist/assets/{architectureDiagram-ZJ3FMSHR-CvRhdovL.js → architectureDiagram-ZJ3FMSHR-Dc-lvdUh.js} +1 -1
- package/dist/assets/{blockDiagram-677ZJIJ3-DVYNkbR_.js → blockDiagram-677ZJIJ3-CcsoWpIY.js} +1 -1
- package/dist/assets/{book-open-w3160PZf.js → book-open-D-oLp0QJ.js} +1 -1
- package/dist/assets/{c4Diagram-LMCZKHZV-B1w-iwRe.js → c4Diagram-LMCZKHZV-Bsrtg6b2.js} +1 -1
- package/dist/assets/card-CA3ozZwW.js +1 -0
- package/dist/assets/channel-BSKkTPe8.js +1 -0
- package/dist/assets/channels-list-page-B44EWctT.js +8 -0
- package/dist/assets/chat-page-CH8ypOKO.js +1 -0
- package/dist/assets/chunk-2Q5K7J3B-CDMOR1xZ.js +1 -0
- package/dist/assets/{chunk-32BRIVSS-kG3lg0bC.js → chunk-32BRIVSS-Bt08t8oG.js} +1 -1
- package/dist/assets/{chunk-52WLFC77-BLeB7iGk.js → chunk-52WLFC77-Ddx68Xzx.js} +1 -1
- package/dist/assets/{chunk-5FCAYU7R-BQga1Rr7.js → chunk-5FCAYU7R-B7p9_q55.js} +1 -1
- package/dist/assets/{chunk-5HE753X5-DU81hkcF.js → chunk-5HE753X5-D52KvdTm.js} +1 -1
- package/dist/assets/{chunk-5JV3BV7I-C2bAx0m7.js → chunk-5JV3BV7I-C329h8nI.js} +1 -1
- package/dist/assets/{chunk-5TONJI2A-BExIIgWY.js → chunk-5TONJI2A-BZyUBxWt.js} +1 -1
- package/dist/assets/{chunk-5VM5RSS4-C3XB05yh.js → chunk-5VM5RSS4-BUiYXZmu.js} +1 -1
- package/dist/assets/{chunk-7BUUIJ7U-JiyRtrGu.js → chunk-7BUUIJ7U-B7o-mn4r.js} +1 -1
- package/dist/assets/{chunk-BIQX33UG-BZRV20pI.js → chunk-BIQX33UG-Bey9GoRP.js} +1 -1
- package/dist/assets/{chunk-C7G6YPKG-AsyDSQ9j.js → chunk-C7G6YPKG-C6tosszM.js} +1 -1
- package/dist/assets/{chunk-CQNSW5MT-iN-fiXVA.js → chunk-CQNSW5MT-BNrdkgGQ.js} +1 -1
- package/dist/assets/{chunk-CYSBUYHQ-DhC_TRzI.js → chunk-CYSBUYHQ-DHODFeyB.js} +1 -1
- package/dist/assets/{chunk-EMLP6XTP-QFLK8R6d.js → chunk-EMLP6XTP-BcmLjrcq.js} +1 -1
- package/dist/assets/{chunk-EX3LRPZG-DzUwhkCz.js → chunk-EX3LRPZG-r-_eEtJI.js} +1 -1
- package/dist/assets/{chunk-FWX5IMBZ-DFelpZBy.js → chunk-FWX5IMBZ-DOObDWbf.js} +2 -2
- package/dist/assets/{chunk-HOUHSVGY-BMPwFEwN.js → chunk-HOUHSVGY-Bd0FnbWZ.js} +1 -1
- package/dist/assets/{chunk-ICXQ74PX-DH8NJMok.js → chunk-ICXQ74PX-ntNwAm4_.js} +1 -1
- package/dist/assets/{chunk-JG7HCLWE-D-95AsO4.js → chunk-JG7HCLWE-YtRpblZN.js} +1 -1
- package/dist/assets/{chunk-JWPE2WC7-DIaTv8kx.js → chunk-JWPE2WC7-De5-D9ta.js} +1 -1
- package/dist/assets/{chunk-MOJQB5TN-BPFLzWgj.js → chunk-MOJQB5TN-CdvKhyp2.js} +1 -1
- package/dist/assets/{chunk-MOZMSUNE-DR_fzxG0.js → chunk-MOZMSUNE-DJMMN_lu.js} +1 -1
- package/dist/assets/{chunk-OGEWGWER-TIcEoPPH.js → chunk-OGEWGWER-DOFWVw3O.js} +1 -1
- package/dist/assets/{chunk-OSBZ3O6U-BALNvSfG.js → chunk-OSBZ3O6U-DZkrIN9r.js} +1 -1
- package/dist/assets/{chunk-PUDLZKDR-I-EXhf_k.js → chunk-PUDLZKDR-D1wma2Yf.js} +1 -1
- package/dist/assets/{chunk-Q4XR5HBZ-uvIGstBS.js → chunk-Q4XR5HBZ-CjPy94Lz.js} +1 -1
- package/dist/assets/{chunk-QBLGF6JB-r-TjLdxa.js → chunk-QBLGF6JB-Hy1bEgS-.js} +1 -1
- package/dist/assets/{chunk-R7FJI6CG-N-1LDgvy.js → chunk-R7FJI6CG-CUPIHyh-.js} +1 -1
- package/dist/assets/{chunk-RYQCIY6F-jxNASx65.js → chunk-RYQCIY6F-D5Ua4pcv.js} +1 -1
- package/dist/assets/{chunk-U6XO7XAA-Cphbuc7q.js → chunk-U6XO7XAA-DaUQcqb7.js} +1 -1
- package/dist/assets/{chunk-V7JOEXUC-BLEuBf1s.js → chunk-V7JOEXUC-DX2zLfQe.js} +1 -1
- package/dist/assets/chunk-VAUOI2AC-BRvqNW76.js +1 -0
- package/dist/assets/{chunk-VR4S4FIN-BAUbR0ke.js → chunk-VR4S4FIN-CFA-WQik.js} +1 -1
- package/dist/assets/{chunk-WYO6CB5R-Do6SJrnY.js → chunk-WYO6CB5R-Bk2HeDvJ.js} +2 -2
- package/dist/assets/chunk-XXDRQBXY-CwX_mqJ3.js +1 -0
- package/dist/assets/{chunk-YOTPTUD7-CQqvMTCr.js → chunk-YOTPTUD7-DUG4FpBN.js} +1 -1
- package/dist/assets/{chunk-ZGVPDNZ5-B7kWWaXv.js → chunk-ZGVPDNZ5-70JdIGo0.js} +1 -1
- package/dist/assets/{chunk-ZIRB5QZD-DTU0cDNh.js → chunk-ZIRB5QZD-XZdgBt5L.js} +1 -1
- package/dist/assets/classDiagram-OUVF2IWQ-RzbGxG77.js +1 -0
- package/dist/assets/classDiagram-v2-EOCWNBFH-C_gWB7WT.js +1 -0
- package/dist/assets/config-split-page-DskB5yAV.js +1 -0
- package/dist/assets/confirm-dialog-BRQpFnvD.js +5 -0
- package/dist/assets/{cose-bilkent-JH36ORCC-B9LrtV-q.js → cose-bilkent-JH36ORCC-B-PQoGX-.js} +1 -1
- package/dist/assets/cynefin-VYW2F7L2-fSLIS0X3.js +1 -0
- package/dist/assets/{cynefinDiagram-TSTJHNR4-BfjvW4su.js → cynefinDiagram-TSTJHNR4-BoLCPEM0.js} +1 -1
- package/dist/assets/{dagre-DkiXZKkL.js → dagre-D7Ie4eXr.js} +1 -1
- package/dist/assets/{dagre-VKFMJZFB-B1pQKQSY.js → dagre-VKFMJZFB-CKRrwZA-.js} +1 -1
- package/dist/assets/desktop-update-config-se0OEu06.js +1 -0
- package/dist/assets/{diagram-FQU43EPY-cB4EZdaP.js → diagram-FQU43EPY-CASL1J3_.js} +1 -1
- package/dist/assets/{diagram-G47NLZAW-CtW8im1B.js → diagram-G47NLZAW-CvLPBIzf.js} +1 -1
- package/dist/assets/{diagram-NH7WQ7WH-BDCtrCCm.js → diagram-NH7WQ7WH-Ba6fGdYP.js} +1 -1
- package/dist/assets/{diagram-OA4YK3LP-DEMJ42Gt.js → diagram-OA4YK3LP-DkpfgEjM.js} +1 -1
- package/dist/assets/{diagram-WEI45ONY-CdCcxSYU.js → diagram-WEI45ONY-BP5UMVsN.js} +1 -1
- package/dist/assets/{dist-DEJlYi0E.js → dist-f6aZEsu8.js} +1 -1
- package/dist/assets/doc-browser-BRiAfy_N.js +1 -0
- package/dist/assets/doc-browser-DW7afLXs.js +1 -0
- package/dist/assets/{doc-browser-context-CpvHiuQG.js → doc-browser-context-DhTa-zP_.js} +1 -1
- package/dist/assets/{docx-preview-zis3U0Fa.js → docx-preview-D0tp3a9T.js} +1 -1
- package/dist/assets/{ebnfDiagram-CCIWWBDH-DBZETBwE.js → ebnfDiagram-CCIWWBDH-TJKbUcmc.js} +1 -1
- package/dist/assets/{erDiagram-Q63AITRT-y2zDXprP.js → erDiagram-Q63AITRT-DzGPKkKH.js} +1 -1
- package/dist/assets/eventmodeling-45OFAUF4-XVcQGgha.js +1 -0
- package/dist/assets/eye-DMGpISEo.js +1 -0
- package/dist/assets/flowDiagram-23GEKE2U-BiFSctqz.js +1 -0
- package/dist/assets/{form-actions-5OsDRt0g.js → form-actions-SgP78YnZ.js} +1 -1
- package/dist/assets/{ganttDiagram-NO4QXBWP-D2DP344e.js → ganttDiagram-NO4QXBWP-JhJzsGp2.js} +1 -1
- package/dist/assets/gitGraph-TEB2WS4Q-C014uXqS.js +1 -0
- package/dist/assets/{gitGraphDiagram-IHSO6WYX-D37uiwA2.js → gitGraphDiagram-IHSO6WYX-DZ1CKMj8.js} +1 -1
- package/dist/assets/index-B2YF-7Yw.css +1 -0
- package/dist/assets/index-CBD4zQ_A.js +2 -0
- package/dist/assets/info-DKCQHKI2-CQ2qjGhU.js +1 -0
- package/dist/assets/{infoDiagram-FWYZ7A6U-CG-WAIRi.js → infoDiagram-FWYZ7A6U-BNXNKfRQ.js} +1 -1
- package/dist/assets/{ishikawaDiagram-FXEZZL3T-WeCTnW0f.js → ishikawaDiagram-FXEZZL3T-DoiEfjNw.js} +1 -1
- package/dist/assets/{journeyDiagram-5HDEW3XC-DUFBW9Td.js → journeyDiagram-5HDEW3XC-D6oK2HSy.js} +1 -1
- package/dist/assets/{kanban-definition-HUTT4EX6-B0lxgMpg.js → kanban-definition-HUTT4EX6-B2UnLOH-.js} +1 -1
- package/dist/assets/{line-B78frP_c.js → line-BM7PoxY5.js} +1 -1
- package/dist/assets/{linear-C6lVEcb2.js → linear-B3DiqMjk.js} +1 -1
- package/dist/assets/loader-circle-DEQ2CflP.js +1 -0
- package/dist/assets/{logo-badge-TdPa95AC.js → logo-badge-BZnxuJYW.js} +1 -1
- package/dist/assets/{map-Bdri5UL5.js → map-BAAdHTqR.js} +1 -1
- package/dist/assets/mcp-marketplace-page-B8eWiT9H.js +1 -0
- package/dist/assets/{mcp-marketplace-page-cm3ifaKu.js → mcp-marketplace-page-Dm08nf11.js} +2 -2
- package/dist/assets/{mermaid-parser.core-Cue18vLo.js → mermaid-parser.core-BeMviefY.js} +2 -2
- package/dist/assets/{mermaid.core-CXwWRh5i.js → mermaid.core-D0Q77r9I.js} +3 -3
- package/dist/assets/{mindmap-definition-LN4V7U3C-CFxz0P0-.js → mindmap-definition-LN4V7U3C-BQ7r7bR8.js} +1 -1
- package/dist/assets/model-config-page-k_tCjGlK.js +1 -0
- package/dist/assets/navigation-link-CJ3fpUBN.js +1 -0
- package/dist/assets/{ordinal-Cbd8t4LB.js → ordinal-Bt2N4IkA.js} +1 -1
- package/dist/assets/packet-7NZHBO7P-6IFyydij.js +1 -0
- package/dist/assets/{pegDiagram-2B236MQR-B_Qt9zyT.js → pegDiagram-2B236MQR-B-C9-LGz.js} +1 -1
- package/dist/assets/pie-RZYD4A2V-spXQC_wr.js +1 -0
- package/dist/assets/{pieDiagram-ENE6RG2P-CRQdSuwS.js → pieDiagram-ENE6RG2P-CtirZLtn.js} +1 -1
- package/dist/assets/plus-9_9Q74qc.js +1 -0
- package/dist/assets/{popover-EulxhA0q.js → popover-Cq_oB7HI.js} +1 -1
- package/dist/assets/provider-scoped-model-input-Cwv5zw0Z.js +1 -0
- package/dist/assets/providers-config-page-D82jX13I.js +1 -0
- package/dist/assets/{quadrantDiagram-ABIIQ3AL-D5kPpttq.js → quadrantDiagram-ABIIQ3AL-DiBWAzDU.js} +1 -1
- package/dist/assets/radar-I7S5WNFK-DWVA8lvY.js +1 -0
- package/dist/assets/railroad-3IZDKUUU-Ce51u8y1.js +1 -0
- package/dist/assets/railroad-abnf-AHOZXSZD-D7i7cqI_.js +1 -0
- package/dist/assets/railroad-ebnf-EBAXGLYW-BEg2hcPs.js +1 -0
- package/dist/assets/railroad-peg-LSFZ7HO6-CxROSzbi.js +1 -0
- package/dist/assets/{railroadDiagram-RFXS5EU6-DGh_TGlQ.js → railroadDiagram-RFXS5EU6-CP6b3PBI.js} +1 -1
- package/dist/assets/{react-Bb0EYsLS.js → react-BjpVlGAu.js} +1 -1
- package/dist/assets/{refresh-cw-CexL11m1.js → refresh-cw-CYyWovQ1.js} +1 -1
- package/dist/assets/remote-C2MGMI2j.js +1 -0
- package/dist/assets/{requirementDiagram-TGXJPOKE-EmFph0H_.js → requirementDiagram-TGXJPOKE-D8YV0-Jz.js} +1 -1
- package/dist/assets/rotate-cw-BkGMTudQ.js +1 -0
- package/dist/assets/runtime-config-page-OS6ZT2b0.js +1 -0
- package/dist/assets/{sankeyDiagram-HTMAVEWB-BXWB5Ugi.js → sankeyDiagram-HTMAVEWB-C2vA4ojE.js} +1 -1
- package/dist/assets/{save-DtccrZld.js → save-B0V_M-kz.js} +1 -1
- package/dist/assets/search-config-page-IzK1hMQX.js +1 -0
- package/dist/assets/{search-BArc_WOX.js → search-vFYD1SOf.js} +1 -1
- package/dist/assets/secrets-config-page-Cm3IXYpK.js +3 -0
- package/dist/assets/security-config-DfzQ8txL.js +1 -0
- package/dist/assets/{select-C9FB0jlt.js → select-BAYdPRVG.js} +1 -1
- package/dist/assets/{sequenceDiagram-DBY2YBRQ-ClKnO7v0.js → sequenceDiagram-DBY2YBRQ-B9LBmpUo.js} +1 -1
- package/dist/assets/settings-2-QX-FHs_i.js +1 -0
- package/dist/assets/{sizeCapture-X5ZJPWSS-DSo-t5ou.js → sizeCapture-X5ZJPWSS-9UIfya9-.js} +1 -1
- package/dist/assets/skeleton-2eczb2co.js +1 -0
- package/dist/assets/{src-Dad2ZbCt.js → src-DKf77Yzo.js} +1 -1
- package/dist/assets/{stateDiagram-2N3HPSRC-BvAalBfz.js → stateDiagram-2N3HPSRC-oTW44vds.js} +1 -1
- package/dist/assets/stateDiagram-v2-6OUMAXLB-Bui4RXQK.js +1 -0
- package/dist/assets/{swimlanes-5IMT3BWC-DdVqVa1a.js → swimlanes-5IMT3BWC-Cf7lcsay.js} +2 -2
- package/dist/assets/swimlanesDiagram-G3AALYLV-DTwUsCBz.js +8 -0
- package/dist/assets/{tabs-D_mjyOOf.js → tabs-Ddprun22.js} +1 -1
- package/dist/assets/{tag-chip-C011rd9q.js → tag-chip-C9SLhljq.js} +1 -1
- package/dist/assets/{timeline-definition-FHXFAJF6-D4ar8IQY.js → timeline-definition-FHXFAJF6-DoCuWKDJ.js} +1 -1
- package/dist/assets/{trash-2-bDhfsO1O.js → trash-2-CODUwc31.js} +1 -1
- package/dist/assets/treeView-QDETBFTQ-D5zsTiuL.js +1 -0
- package/dist/assets/treemap-6X3UGDF4-CR3dxqNs.js +1 -0
- package/dist/assets/{use-config-BNrlfEck.js → use-config-C5OKT3lk.js} +1 -1
- package/dist/assets/use-confirm-dialog-B_ZW-WgC.js +1 -0
- package/dist/assets/{use-viewport-layout-P0q6Nt_N.js → use-viewport-layout-OtzTlg5U.js} +1 -1
- package/dist/assets/{vennDiagram-L72KCM5P-CDXJ_i3p.js → vennDiagram-L72KCM5P-CpU0pzGe.js} +1 -1
- package/dist/assets/wardley-OPB4EBWU-LatRT_Lx.js +1 -0
- package/dist/assets/{wardleyDiagram-EHGQE667-D-dSuT_7.js → wardleyDiagram-EHGQE667-CkN6nn6-.js} +1 -1
- package/dist/assets/x-Cbfpb-Zm.js +1 -0
- package/dist/assets/{xychartDiagram-FW5EYKEG-C9JCzsZF.js → xychartDiagram-FW5EYKEG-DATpapm2.js} +1 -1
- package/dist/index.html +31 -32
- package/dist/runtime-icons/opencode.svg +16 -0
- package/package.json +10 -9
- package/public/runtime-icons/opencode.svg +16 -0
- package/src/app/components/layout/__tests__/settings-entry-page.test.tsx +6 -4
- package/src/app/components/layout/__tests__/sidebar.layout.test.tsx +24 -12
- package/src/app/components/layout/sidebar-items.tsx +11 -2
- package/src/app/components/layout/sidebar.tsx +33 -234
- package/src/app/configs/app-navigation.config.ts +10 -24
- package/src/app/index.tsx +0 -5
- package/src/features/channels/components/config/channel-form.tsx +26 -26
- package/src/features/channels/components/config/weixin-channel-auth-section.tsx +6 -7
- package/src/features/channels/pages/__tests__/channels-list-page.test.tsx +2 -2
- package/src/features/channels/pages/channels-list-page.tsx +33 -32
- package/src/features/chat/components/conversation/__tests__/chat-conversation-content.test.tsx +68 -7
- package/src/features/chat/components/conversation/__tests__/chat-conversation-header-section.test.tsx +27 -0
- package/src/features/chat/components/conversation/__tests__/chat-conversation-panel.test.tsx +0 -8
- package/src/features/chat/components/conversation/chat-conversation-content.tsx +65 -21
- package/src/features/chat/components/conversation/chat-conversation-header-section.tsx +36 -12
- package/src/features/chat/components/conversation/chat-conversation-panel.tsx +0 -7
- package/src/features/chat/components/layout/__tests__/chat-sidebar-toolbar.test.tsx +0 -1
- package/src/features/chat/components/layout/__tests__/chat-sidebar.test.tsx +17 -8
- package/src/features/chat/components/layout/chat-page-shell.tsx +2 -2
- package/src/features/chat/components/layout/chat-sidebar-toolbar.tsx +2 -23
- package/src/features/chat/components/layout/chat-sidebar.tsx +3 -12
- package/src/features/chat/features/conversation/components/__tests__/session-conversation-area.test.tsx +155 -93
- package/src/features/chat/features/conversation/components/session-conversation-area.tsx +126 -93
- package/src/features/chat/features/conversation/hooks/__tests__/use-session-conversation-input-state.test.tsx +8 -0
- package/src/features/chat/features/conversation/hooks/use-session-conversation-input-state.ts +27 -13
- package/src/features/chat/features/message/components/__tests__/chat-inline-file-preview.test.tsx +15 -9
- package/src/features/chat/features/message/components/__tests__/chat-inline-panel-app-card.test.tsx +127 -49
- package/src/features/chat/features/message/components/__tests__/chat-message-list.container.test.tsx +186 -20
- package/src/features/chat/features/message/components/chat-inline-content-surface.tsx +55 -0
- package/src/features/chat/features/message/components/chat-inline-file-preview.tsx +49 -71
- package/src/features/chat/features/message/components/chat-inline-panel-app-card.tsx +65 -55
- package/src/features/chat/features/message/components/chat-message-list.container.tsx +275 -267
- package/src/features/chat/features/message/hooks/__tests__/use-chat-message-virtualizer.test.tsx +163 -0
- package/src/features/chat/features/message/hooks/use-chat-message-virtualizer.ts +68 -0
- package/src/features/chat/features/message/utils/__tests__/chat-message-execution-summary.utils.test.ts +200 -0
- package/src/features/chat/features/message/utils/__tests__/chat-message-texts.utils.test.ts +14 -1
- package/src/features/chat/features/message/utils/__tests__/chat-message.utils.test.ts +33 -0
- package/src/features/chat/features/message/utils/chat-inline-panel-app-card.utils.ts +24 -9
- package/src/features/chat/features/message/utils/chat-message-execution-summary.utils.ts +173 -0
- package/src/features/chat/features/message/utils/chat-message-texts.utils.ts +43 -0
- package/src/features/chat/features/message/utils/chat-message-timeline.utils.ts +194 -0
- package/src/features/chat/features/message/utils/chat-message.utils.ts +5 -0
- package/src/features/chat/features/ncp/hooks/__tests__/use-ncp-session-conversation.test.tsx +151 -13
- package/src/features/chat/features/ncp/hooks/use-ncp-session-conversation.ts +44 -70
- package/src/features/chat/features/ncp/hooks/use-ncp-session-message-history.ts +197 -0
- package/src/features/chat/features/session/components/__tests__/chat-sidebar-session-item.test.tsx +21 -3
- package/src/features/chat/features/session/components/chat-sidebar-project-groups.tsx +7 -7
- package/src/features/chat/features/session/components/chat-sidebar-session-item.tsx +2 -2
- package/src/features/chat/features/session/components/session-context-icon.tsx +1 -1
- package/src/features/chat/features/session-type/components/__tests__/chat-session-type-option-item.test.tsx +5 -1
- package/src/features/chat/features/session-type/components/chat-session-type-option-item.tsx +1 -1
- package/src/features/chat/features/workspace/components/__tests__/workspace-file-content-preview.test.tsx +32 -10
- package/src/features/chat/features/workspace/components/workspace-file-content-preview.tsx +5 -15
- package/src/features/chat/features/workspace/utils/__tests__/chat-workspace-panel-view-model.utils.test.ts +62 -9
- package/src/features/chat/features/workspace/utils/chat-thread-workspace-session.utils.ts +6 -1
- package/src/features/chat/features/workspace/utils/chat-workspace-panel-view-model.utils.ts +1 -25
- package/src/features/chat/managers/__tests__/chat-session-list.manager.test.ts +190 -109
- package/src/features/chat/managers/__tests__/chat-thread-workspace.manager.test.ts +9 -10
- package/src/features/chat/managers/chat-session-list.manager.ts +68 -27
- package/src/features/cron/components/__tests__/cron-config.test.tsx +260 -0
- package/src/features/cron/components/cron-config.tsx +392 -388
- package/src/features/cron/components/cron-job-detail-dialog.tsx +210 -0
- package/src/features/cron/components/cron-job-row.tsx +271 -0
- package/src/features/cron/components/cron-task-discovery.tsx +152 -0
- package/src/features/cron/hooks/use-cron-jobs.ts +3 -1
- package/src/features/marketplace/components/__tests__/marketplace-page.test.tsx +3 -2
- package/src/features/marketplace/components/marketplace-external-skill-source-action.tsx +8 -6
- package/src/features/marketplace/components/mcp/mcp-marketplace-page.tsx +26 -40
- package/src/features/pwa/components/pwa-install-entry.tsx +45 -58
- package/src/features/remote/components/remote-access-page.tsx +128 -208
- package/src/features/settings/components/config/provider-auth-section.tsx +32 -17
- package/src/features/settings/components/config/provider-form.tsx +6 -6
- package/src/features/settings/components/config/provider-models-section.tsx +52 -46
- package/src/features/settings/components/config/secrets-config-form.tsx +78 -84
- package/src/features/settings/index.ts +0 -1
- package/src/features/settings/pages/__tests__/appearance-settings-page.test.tsx +35 -1
- package/src/features/settings/pages/__tests__/model-config-page.test.tsx +18 -1
- package/src/features/settings/pages/__tests__/search-config-page.test.tsx +8 -0
- package/src/features/settings/pages/__tests__/secrets-config-page.test.tsx +18 -17
- package/src/features/settings/pages/appearance-settings-page.tsx +87 -64
- package/src/features/settings/pages/model-config-page.tsx +75 -70
- package/src/features/settings/pages/providers-config-page.tsx +107 -73
- package/src/features/settings/pages/search-config-page.tsx +159 -152
- package/src/features/settings/pages/secrets-config-page.tsx +6 -1
- package/src/features/system-status/components/config/runtime-agent-list-card.tsx +23 -22
- package/src/features/system-status/components/config/runtime-binding-list-card.tsx +23 -22
- package/src/features/system-status/components/config/runtime-config-editor.tsx +17 -7
- package/src/features/system-status/components/config/runtime-config-overview.tsx +0 -3
- package/src/features/system-status/components/config/runtime-entry-list-card.tsx +24 -23
- package/src/features/system-status/components/config/runtime-settings-card.tsx +59 -52
- package/src/features/system-status/components/desktop-update-config.tsx +117 -112
- package/src/features/system-status/components/runtime-control-card.tsx +62 -59
- package/src/features/system-status/components/runtime-presence-card.tsx +79 -98
- package/src/features/system-status/components/runtime-security-card.tsx +74 -62
- package/src/features/system-status/components/security-config.tsx +3 -4
- package/src/features/system-status/pages/runtime-config-page.tsx +6 -1
- package/src/platforms/desktop/components/desktop-app-shell.tsx +1 -1
- package/src/platforms/mobile/components/mobile-settings-shell.tsx +2 -2
- package/src/shared/components/__tests__/config-split-page.test.tsx +15 -3
- package/src/shared/components/__tests__/settings-page.test.tsx +31 -0
- package/src/shared/components/actions/__tests__/navigation-link.test.tsx +47 -0
- package/src/shared/components/actions/navigation-link.tsx +116 -0
- package/src/shared/components/common/__tests__/brand-header.test.tsx +5 -5
- package/src/shared/components/common/__tests__/searchable-model-input.test.tsx +24 -0
- package/src/shared/components/common/brand-header.tsx +12 -10
- package/src/shared/components/common/searchable-model-input.tsx +9 -10
- package/src/shared/components/config-split-page.tsx +70 -65
- package/src/shared/components/doc-browser/doc-browser-panel-parts.tsx +6 -7
- package/src/shared/components/settings/setting-row.tsx +61 -30
- package/src/shared/components/settings/settings-page.tsx +34 -0
- package/src/shared/components/ui/actions/__tests__/icon-action-button.test.tsx +23 -2
- package/src/shared/components/ui/actions/icon-action-button.tsx +9 -2
- package/src/shared/components/ui/overlays/sheet.tsx +142 -0
- package/src/shared/lib/api/ncp-session.types.ts +8 -2
- package/src/shared/lib/api/types.ts +22 -1
- package/src/shared/lib/api/utils/config.utils.ts +2 -1
- package/src/shared/lib/api/utils/ncp-session.utils.ts +25 -11
- package/src/shared/lib/i18n/locales/en-US/chat.json +31 -1
- package/src/shared/lib/i18n/locales/en-US/core.json +3 -3
- package/src/shared/lib/i18n/locales/en-US/cron.json +87 -17
- package/src/shared/lib/i18n/locales/zh-CN/chat.json +33 -3
- package/src/shared/lib/i18n/locales/zh-CN/core.json +6 -6
- package/src/shared/lib/i18n/locales/zh-CN/cron.json +80 -10
- package/src/shared/lib/transport/__tests__/remote.transport.test.ts +16 -4
- package/dist/assets/api-D0U10BcF.js +0 -13
- package/dist/assets/app-presenter-provider-Dffdm_Ek.js +0 -106
- package/dist/assets/appearance-settings-page-sfusZc2d.js +0 -1
- package/dist/assets/architecture-TIHT7OUA-ClwVFq-K.js +0 -1
- package/dist/assets/channel-BEHOSFc5.js +0 -1
- package/dist/assets/channels-list-page-Dkfe87Zq.js +0 -8
- package/dist/assets/chat-page-CeapbQnG.js +0 -1
- package/dist/assets/chunk-2Q5K7J3B-DrIhesSX.js +0 -1
- package/dist/assets/chunk-VAUOI2AC-Dpcz6BhT.js +0 -1
- package/dist/assets/chunk-XXDRQBXY-C2QjjwYX.js +0 -1
- package/dist/assets/classDiagram-OUVF2IWQ-DESMaY3_.js +0 -1
- package/dist/assets/classDiagram-v2-EOCWNBFH-DwOlByYH.js +0 -1
- package/dist/assets/config-split-page-CnQI8cKT.js +0 -1
- package/dist/assets/confirm-dialog-RZUWA_j9.js +0 -5
- package/dist/assets/cynefin-VYW2F7L2-CzjeeOq9.js +0 -1
- package/dist/assets/desktop-update-config-CbSYQMYz.js +0 -1
- package/dist/assets/doc-browser-DwXHr-mm.js +0 -1
- package/dist/assets/doc-browser-jVTq8iY_2.js +0 -1
- package/dist/assets/download-BP7ZxrwI.js +0 -1
- package/dist/assets/eventmodeling-45OFAUF4-C38BqG8w.js +0 -1
- package/dist/assets/external-link-DvHCEe3h.js +0 -1
- package/dist/assets/eye-C--6dxv_.js +0 -1
- package/dist/assets/flowDiagram-23GEKE2U-BoKk8RRq.js +0 -1
- package/dist/assets/folder-BfeO1zCY.js +0 -1
- package/dist/assets/gitGraph-TEB2WS4Q-IsQHHJuS.js +0 -1
- package/dist/assets/index-BlKbckX4.css +0 -1
- package/dist/assets/index-DoZR11Nh.js +0 -2
- package/dist/assets/info-DKCQHKI2-ofy2qlHI.js +0 -1
- package/dist/assets/loader-circle-BWdgwVnn.js +0 -1
- package/dist/assets/mcp-marketplace-page-XnRWiC8c.js +0 -1
- package/dist/assets/model-config-page-CXnqSbSI.js +0 -1
- package/dist/assets/packet-7NZHBO7P-Rfopfa1o.js +0 -1
- package/dist/assets/pie-RZYD4A2V-CJR1xKEv.js +0 -1
- package/dist/assets/plus-BeApS21t.js +0 -1
- package/dist/assets/provider-scoped-model-input-ll_Btc9h.js +0 -1
- package/dist/assets/providers-config-page-Bcuhqkdl.js +0 -1
- package/dist/assets/radar-I7S5WNFK-CDg8Z-1r.js +0 -1
- package/dist/assets/railroad-3IZDKUUU-BHnNmjxO.js +0 -1
- package/dist/assets/railroad-abnf-AHOZXSZD-DGtNcusW.js +0 -1
- package/dist/assets/railroad-ebnf-EBAXGLYW-BRFtsQmm.js +0 -1
- package/dist/assets/railroad-peg-LSFZ7HO6-Bj5IypCA.js +0 -1
- package/dist/assets/remote-CqKpuOP9.js +0 -1
- package/dist/assets/rotate-cw-DHXoiqFB.js +0 -1
- package/dist/assets/runtime-config-page-D-Aqxizs.js +0 -1
- package/dist/assets/search-config-page-XTKf5rc0.js +0 -1
- package/dist/assets/secrets-config-page-Cx-qptcj.js +0 -3
- package/dist/assets/security-config-DWGFM2u9.js +0 -1
- package/dist/assets/setting-row-DFvioO2a.js +0 -1
- package/dist/assets/settings-2-RMWqf-ey.js +0 -1
- package/dist/assets/skeleton-DQ5WhuDG.js +0 -1
- package/dist/assets/stateDiagram-v2-6OUMAXLB-CfMU38yc.js +0 -1
- package/dist/assets/swimlanesDiagram-G3AALYLV-D9Zb9X57.js +0 -8
- package/dist/assets/treeView-QDETBFTQ-Uy7M0WvH.js +0 -1
- package/dist/assets/treemap-6X3UGDF4-BJfGV7KX.js +0 -1
- package/dist/assets/use-confirm-dialog-CTNA1PC0.js +0 -1
- package/dist/assets/wardley-OPB4EBWU-q263iF3K.js +0 -1
- package/dist/assets/x-qvh05iyu.js +0 -1
- package/src/features/chat/components/conversation/chat-conversation-skeleton.tsx +0 -86
- package/src/features/settings/pages/__tests__/language-settings-page.test.tsx +0 -36
- package/src/features/settings/pages/language-settings-page.tsx +0 -56
- package/src/shared/components/actions/action-link.tsx +0 -49
- /package/dist/assets/{array-BqYdCIE6.js → array-CAkJT3no.js} +0 -0
- /package/dist/assets/{chunk-KEIR6QF5-A3jEqwzn.js → chunk-KEIR6QF5-BgdDoWEH.js} +0 -0
- /package/dist/assets/{chunk-Y2CYZVJY-BGrd8tLy.js → chunk-Y2CYZVJY-pTllD0P3.js} +0 -0
- /package/dist/assets/{config-hints-LxG80Uj5.js → config-hints-S3g-UVZb.js} +0 -0
- /package/dist/assets/{cytoscape.esm-CRW8q92n.js → cytoscape.esm-DmURt-5G.js} +0 -0
- /package/dist/assets/{defaultLocale-Cdv9x6q7.js → defaultLocale-BKy_KP3O.js} +0 -0
- /package/dist/assets/{dist-dw-gAfM_.js → dist-IgNNB7K9.js} +0 -0
- /package/dist/assets/{graphlib-BcNFQr5y.js → graphlib-xw_TBHyH.js} +0 -0
- /package/dist/assets/{host-capabilities-CFbAfrrA.js → host-capabilities-B-TtABsP.js} +0 -0
- /package/dist/assets/{init-D8TjIqfm.js → init-C9xlLIAu.js} +0 -0
- /package/dist/assets/{jszip.min-CP5uPNQa.js → jszip.min-Das2IAnb.js} +0 -0
- /package/dist/assets/{katex-wEmrEFTg.js → katex-DSy1eD2d.js} +0 -0
- /package/dist/assets/{middleware-CAXxl-af.js → middleware-Df-a4x-q.js} +0 -0
- /package/dist/assets/{path-DzBnMI1r.js → path-DB0USYHi.js} +0 -0
- /package/dist/assets/{provider-models-BoUhFo9R.js → provider-models-CXUgDxGR.js} +0 -0
- /package/dist/assets/{rough.esm-wJ1d3nQl.js → rough.esm-B1B52ZQS.js} +0 -0
- /package/dist/assets/{xlsx-DUqJhg5u.js → xlsx-DfjC_iml.js} +0 -0
|
@@ -13,30 +13,30 @@ const mocks = vi.hoisted(() => ({
|
|
|
13
13
|
enabled: true,
|
|
14
14
|
defaults: {
|
|
15
15
|
env: 'vault-env',
|
|
16
|
-
file: 'vault-file'
|
|
16
|
+
file: 'vault-file'
|
|
17
17
|
},
|
|
18
18
|
providers: {
|
|
19
19
|
'vault-env': { source: 'env', prefix: 'NEXTCLAW_' },
|
|
20
|
-
'vault-file': { source: 'file', path: '/tmp/secrets.json', format: 'json' }
|
|
20
|
+
'vault-file': { source: 'file', path: '/tmp/secrets.json', format: 'json' }
|
|
21
21
|
},
|
|
22
22
|
refs: {
|
|
23
23
|
'agents.defaults.model': {
|
|
24
24
|
source: 'env',
|
|
25
25
|
provider: 'vault-env',
|
|
26
|
-
id: 'DEFAULT_MODEL'
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
26
|
+
id: 'DEFAULT_MODEL'
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
32
|
}));
|
|
33
33
|
|
|
34
34
|
vi.mock('@/shared/hooks/use-config', () => ({
|
|
35
35
|
useConfig: () => mocks.useConfigData,
|
|
36
36
|
useUpdateSecrets: () => ({
|
|
37
37
|
mutate: mocks.mutate,
|
|
38
|
-
isPending: false
|
|
39
|
-
})
|
|
38
|
+
isPending: false
|
|
39
|
+
})
|
|
40
40
|
}));
|
|
41
41
|
|
|
42
42
|
describe('SecretsConfigPage', () => {
|
|
@@ -59,7 +59,8 @@ describe('SecretsConfigPage', () => {
|
|
|
59
59
|
|
|
60
60
|
render(<SecretsConfigPage />);
|
|
61
61
|
|
|
62
|
-
expect(screen.getByText('
|
|
62
|
+
expect(screen.getByText('密钥提供器')).toBeTruthy();
|
|
63
|
+
expect(screen.getByText('密钥引用')).toBeTruthy();
|
|
63
64
|
expect(screen.getByDisplayValue('vault-env')).toBeTruthy();
|
|
64
65
|
expect(screen.getByDisplayValue('NEXTCLAW_')).toBeTruthy();
|
|
65
66
|
|
|
@@ -71,20 +72,20 @@ describe('SecretsConfigPage', () => {
|
|
|
71
72
|
defaults: {
|
|
72
73
|
env: 'vault-env',
|
|
73
74
|
file: 'vault-file',
|
|
74
|
-
exec: null
|
|
75
|
+
exec: null
|
|
75
76
|
},
|
|
76
77
|
providers: {
|
|
77
78
|
'vault-env': { source: 'env', prefix: 'NEXTCLAW_' },
|
|
78
|
-
'vault-file': { source: 'file', path: '/tmp/secrets.json', format: 'json' }
|
|
79
|
+
'vault-file': { source: 'file', path: '/tmp/secrets.json', format: 'json' }
|
|
79
80
|
},
|
|
80
81
|
refs: {
|
|
81
82
|
'agents.defaults.model': {
|
|
82
83
|
source: 'env',
|
|
83
84
|
provider: 'vault-env',
|
|
84
|
-
id: 'DEFAULT_MODEL'
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
85
|
+
id: 'DEFAULT_MODEL'
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
88
89
|
});
|
|
89
90
|
});
|
|
90
91
|
});
|
|
@@ -1,18 +1,16 @@
|
|
|
1
|
-
import type { ChatMessageLayout } from
|
|
2
|
-
import { Check
|
|
3
|
-
import {
|
|
4
|
-
import { useChatMessageLayoutStore } from
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
} from
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import { t } from "@/shared/lib/i18n";
|
|
15
|
-
import { cn } from "@/shared/lib/utils";
|
|
1
|
+
import type { ChatMessageLayout } from '@nextclaw/agent-chat-ui';
|
|
2
|
+
import { Check } from 'lucide-react';
|
|
3
|
+
import { useTheme } from '@/app/components/theme-provider';
|
|
4
|
+
import { useChatMessageLayoutStore } from '@/features/chat';
|
|
5
|
+
import { useLanguagePreference } from '@/features/settings/hooks/use-language-preference';
|
|
6
|
+
import { SettingRow, SettingsGroup, SettingsSection } from '@/shared/components/settings/setting-row';
|
|
7
|
+
import { SettingsPage } from '@/shared/components/settings/settings-page';
|
|
8
|
+
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '@/shared/components/ui/select';
|
|
9
|
+
import { Switch } from '@/shared/components/ui/switch';
|
|
10
|
+
import { useSideDockStore } from '@/features/side-dock';
|
|
11
|
+
import { t } from '@/shared/lib/i18n';
|
|
12
|
+
import { THEME_OPTIONS, type UiTheme } from '@/shared/lib/theme';
|
|
13
|
+
import { cn } from '@/shared/lib/utils';
|
|
16
14
|
|
|
17
15
|
const CHAT_MESSAGE_LAYOUT_OPTIONS: Array<{
|
|
18
16
|
value: ChatMessageLayout;
|
|
@@ -20,78 +18,103 @@ const CHAT_MESSAGE_LAYOUT_OPTIONS: Array<{
|
|
|
20
18
|
descriptionKey: string;
|
|
21
19
|
}> = [
|
|
22
20
|
{
|
|
23
|
-
value:
|
|
24
|
-
labelKey:
|
|
25
|
-
descriptionKey:
|
|
21
|
+
value: 'card',
|
|
22
|
+
labelKey: 'chatMessageLayoutCard',
|
|
23
|
+
descriptionKey: 'chatMessageLayoutCardDescription'
|
|
26
24
|
},
|
|
27
25
|
{
|
|
28
|
-
value:
|
|
29
|
-
labelKey:
|
|
30
|
-
descriptionKey:
|
|
31
|
-
}
|
|
26
|
+
value: 'flat',
|
|
27
|
+
labelKey: 'chatMessageLayoutFlat',
|
|
28
|
+
descriptionKey: 'chatMessageLayoutFlatDescription'
|
|
29
|
+
}
|
|
32
30
|
];
|
|
33
31
|
|
|
34
32
|
export function AppearanceSettingsPage() {
|
|
33
|
+
const { theme, setTheme } = useTheme();
|
|
34
|
+
const { currentLanguage, languageOptions, selectLanguage } = useLanguagePreference();
|
|
35
35
|
const messageLayout = useChatMessageLayoutStore((state) => state.layout);
|
|
36
|
-
const setMessageLayout = useChatMessageLayoutStore(
|
|
37
|
-
(state) => state.setLayout,
|
|
38
|
-
);
|
|
36
|
+
const setMessageLayout = useChatMessageLayoutStore((state) => state.setLayout);
|
|
39
37
|
const isSideDockVisible = useSideDockStore((state) => state.isVisible);
|
|
40
38
|
const setSideDockVisible = useSideDockStore((state) => state.setVisible);
|
|
41
39
|
|
|
42
40
|
return (
|
|
43
|
-
<
|
|
44
|
-
<
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
41
|
+
<SettingsPage title={t('appearance')}>
|
|
42
|
+
<SettingsSection>
|
|
43
|
+
<SettingsGroup>
|
|
44
|
+
<SettingRow
|
|
45
|
+
title={t('theme')}
|
|
46
|
+
control={
|
|
47
|
+
<Select value={theme} onValueChange={(value) => setTheme(value as UiTheme)}>
|
|
48
|
+
<SelectTrigger aria-label={t('theme')} className='w-36 sm:w-44'>
|
|
49
|
+
<SelectValue />
|
|
50
|
+
</SelectTrigger>
|
|
51
|
+
<SelectContent>
|
|
52
|
+
{THEME_OPTIONS.map((option) => (
|
|
53
|
+
<SelectItem key={option.value} value={option.value}>
|
|
54
|
+
{t(option.labelKey)}
|
|
55
|
+
</SelectItem>
|
|
56
|
+
))}
|
|
57
|
+
</SelectContent>
|
|
58
|
+
</Select>
|
|
59
|
+
}
|
|
60
|
+
/>
|
|
53
61
|
<SettingRow
|
|
54
|
-
title={t(
|
|
55
|
-
|
|
62
|
+
title={t('language')}
|
|
63
|
+
control={
|
|
64
|
+
<Select
|
|
65
|
+
value={currentLanguage}
|
|
66
|
+
onValueChange={(value) => selectLanguage(value as typeof currentLanguage)}
|
|
67
|
+
>
|
|
68
|
+
<SelectTrigger aria-label={t('language')} className='w-36 sm:w-44'>
|
|
69
|
+
<SelectValue />
|
|
70
|
+
</SelectTrigger>
|
|
71
|
+
<SelectContent>
|
|
72
|
+
{languageOptions.map((option) => (
|
|
73
|
+
<SelectItem key={option.value} value={option.value}>
|
|
74
|
+
{option.label}
|
|
75
|
+
</SelectItem>
|
|
76
|
+
))}
|
|
77
|
+
</SelectContent>
|
|
78
|
+
</Select>
|
|
79
|
+
}
|
|
80
|
+
/>
|
|
81
|
+
<SettingRow
|
|
82
|
+
title={t('chatMessageLayoutTitle')}
|
|
83
|
+
description={t('chatMessageLayoutDescription')}
|
|
84
|
+
layout='stacked'
|
|
56
85
|
>
|
|
57
86
|
<div
|
|
58
|
-
role=
|
|
59
|
-
aria-label={t(
|
|
60
|
-
className=
|
|
87
|
+
role='radiogroup'
|
|
88
|
+
aria-label={t('chatMessageLayoutTitle')}
|
|
89
|
+
className='grid gap-1 rounded-xl bg-background/65 p-1 sm:grid-cols-2'
|
|
61
90
|
>
|
|
62
91
|
{CHAT_MESSAGE_LAYOUT_OPTIONS.map((option) => {
|
|
63
92
|
const selected = option.value === messageLayout;
|
|
64
93
|
return (
|
|
65
94
|
<button
|
|
66
95
|
key={option.value}
|
|
67
|
-
type=
|
|
68
|
-
role=
|
|
96
|
+
type='button'
|
|
97
|
+
role='radio'
|
|
69
98
|
aria-checked={selected}
|
|
70
99
|
onClick={() => setMessageLayout(option.value)}
|
|
71
100
|
className={cn(
|
|
72
|
-
|
|
101
|
+
'flex min-w-0 items-start gap-3 rounded-lg px-3 py-2.5 text-left transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/40',
|
|
73
102
|
selected
|
|
74
|
-
?
|
|
75
|
-
:
|
|
103
|
+
? 'bg-card text-foreground shadow-sm'
|
|
104
|
+
: 'text-muted-foreground hover:bg-card/60 hover:text-foreground'
|
|
76
105
|
)}
|
|
77
106
|
>
|
|
78
107
|
<span
|
|
79
108
|
className={cn(
|
|
80
|
-
|
|
81
|
-
selected
|
|
82
|
-
? "border-primary bg-primary text-primary-foreground"
|
|
83
|
-
: "border-border bg-background",
|
|
109
|
+
'mt-0.5 flex h-4 w-4 shrink-0 items-center justify-center rounded-full ring-1',
|
|
110
|
+
selected ? 'bg-primary text-primary-foreground ring-primary' : 'bg-background ring-border'
|
|
84
111
|
)}
|
|
85
112
|
>
|
|
86
|
-
{selected ?
|
|
87
|
-
<Check className="h-2.5 w-2.5" strokeWidth={3} />
|
|
88
|
-
) : null}
|
|
113
|
+
{selected ? <Check className='h-2.5 w-2.5' strokeWidth={3} /> : null}
|
|
89
114
|
</span>
|
|
90
|
-
<span className=
|
|
91
|
-
<span className=
|
|
92
|
-
|
|
93
|
-
</span>
|
|
94
|
-
<span className="mt-1 block text-xs leading-5 text-muted-foreground">
|
|
115
|
+
<span className='min-w-0'>
|
|
116
|
+
<span className='block text-sm font-medium'>{t(option.labelKey)}</span>
|
|
117
|
+
<span className='mt-1 block text-xs leading-5 text-muted-foreground'>
|
|
95
118
|
{t(option.descriptionKey)}
|
|
96
119
|
</span>
|
|
97
120
|
</span>
|
|
@@ -101,19 +124,19 @@ export function AppearanceSettingsPage() {
|
|
|
101
124
|
</div>
|
|
102
125
|
</SettingRow>
|
|
103
126
|
<SettingRow
|
|
104
|
-
title={t(
|
|
105
|
-
description={t(
|
|
127
|
+
title={t('sideDockVisibilityTitle')}
|
|
128
|
+
description={t('sideDockVisibilityDescription')}
|
|
106
129
|
control={
|
|
107
130
|
<Switch
|
|
108
|
-
id=
|
|
109
|
-
aria-label={t(
|
|
131
|
+
id='appearance-side-dock-visible'
|
|
132
|
+
aria-label={t('sideDockVisibilityTitle')}
|
|
110
133
|
checked={isSideDockVisible}
|
|
111
134
|
onCheckedChange={setSideDockVisible}
|
|
112
135
|
/>
|
|
113
136
|
}
|
|
114
137
|
/>
|
|
115
|
-
</
|
|
116
|
-
</
|
|
117
|
-
</
|
|
138
|
+
</SettingsGroup>
|
|
139
|
+
</SettingsSection>
|
|
140
|
+
</SettingsPage>
|
|
118
141
|
);
|
|
119
142
|
}
|
|
@@ -1,17 +1,24 @@
|
|
|
1
1
|
import { Button } from '@/shared/components/ui/button';
|
|
2
|
-
import {
|
|
2
|
+
import { NavigationLink } from '@/shared/components/actions/navigation-link';
|
|
3
3
|
import { Input } from '@/shared/components/ui/input';
|
|
4
4
|
import { Label } from '@/shared/components/ui/label';
|
|
5
5
|
import { Skeleton } from '@/shared/components/ui/skeleton';
|
|
6
6
|
import { FormActions } from '@/shared/components/ui/actions/form-actions';
|
|
7
|
+
import { SettingRow, SettingsGroup, SettingsSection } from '@/shared/components/settings/setting-row';
|
|
8
|
+
import { SettingsPage } from '@/shared/components/settings/settings-page';
|
|
7
9
|
import { ProviderScopedModelInput } from '@/shared/components/common/provider-scoped-model-input';
|
|
8
|
-
import {
|
|
10
|
+
import {
|
|
11
|
+
useConfig,
|
|
12
|
+
useConfigSchema,
|
|
13
|
+
useProviderTemplates,
|
|
14
|
+
useProviders,
|
|
15
|
+
useUpdateModel
|
|
16
|
+
} from '@/shared/hooks/use-config';
|
|
9
17
|
import { hintForPath } from '@/shared/lib/config-hints';
|
|
10
18
|
import { t } from '@/shared/lib/i18n';
|
|
11
19
|
import { buildProviderModelCatalog } from '@/shared/lib/provider-models';
|
|
12
|
-
import { PageLayout, PageHeader } from '@/app/components/layout/page-layout';
|
|
13
20
|
import { getDocsUrl } from '@/shared/components/doc-browser/doc-browser-context';
|
|
14
|
-
import { BookOpen,
|
|
21
|
+
import { BookOpen, Loader2 } from 'lucide-react';
|
|
15
22
|
import { useMemo, useState } from 'react';
|
|
16
23
|
|
|
17
24
|
const DEFAULT_MODEL_INPUT_PLACEHOLDER = 'provider/model';
|
|
@@ -21,14 +28,21 @@ function ModelConfigForm(props: {
|
|
|
21
28
|
initialWorkspace: string;
|
|
22
29
|
isPending: boolean;
|
|
23
30
|
modelHelpText: string;
|
|
24
|
-
modelLabel: string;
|
|
25
31
|
modelPlaceholder: string;
|
|
26
32
|
onSubmit: (payload: { model: string; workspace: string }) => void;
|
|
27
33
|
providerCatalog: ReturnType<typeof buildProviderModelCatalog>;
|
|
28
|
-
workspaceLabel: string;
|
|
29
34
|
workspacePlaceholder: string;
|
|
30
35
|
}) {
|
|
31
|
-
const {
|
|
36
|
+
const {
|
|
37
|
+
initialModel,
|
|
38
|
+
initialWorkspace,
|
|
39
|
+
isPending,
|
|
40
|
+
modelHelpText,
|
|
41
|
+
modelPlaceholder,
|
|
42
|
+
onSubmit,
|
|
43
|
+
providerCatalog,
|
|
44
|
+
workspacePlaceholder
|
|
45
|
+
} = props;
|
|
32
46
|
const [model, setModel] = useState(initialModel);
|
|
33
47
|
const [workspace, setWorkspace] = useState(initialWorkspace);
|
|
34
48
|
|
|
@@ -38,46 +52,42 @@ function ModelConfigForm(props: {
|
|
|
38
52
|
event.preventDefault();
|
|
39
53
|
onSubmit({ model, workspace });
|
|
40
54
|
}}
|
|
41
|
-
className=
|
|
55
|
+
className='space-y-5'
|
|
42
56
|
>
|
|
43
|
-
<
|
|
44
|
-
<
|
|
45
|
-
<
|
|
46
|
-
<div className=
|
|
47
|
-
<
|
|
57
|
+
<SettingsSection>
|
|
58
|
+
<SettingsGroup>
|
|
59
|
+
<SettingRow title={t('defaultModel')} description={modelHelpText} layout='stacked'>
|
|
60
|
+
<div className='space-y-2'>
|
|
61
|
+
<Label htmlFor='model' className='sr-only'>{t('defaultModel')}</Label>
|
|
62
|
+
<ProviderScopedModelInput
|
|
63
|
+
id='model'
|
|
64
|
+
value={model}
|
|
65
|
+
onChange={setModel}
|
|
66
|
+
providerCatalog={providerCatalog}
|
|
67
|
+
modelPlaceholder={modelPlaceholder}
|
|
68
|
+
/>
|
|
69
|
+
<NavigationLink href={getDocsUrl('/guide/model-selection')} external icon={BookOpen} size='xs'>
|
|
70
|
+
{t('channelsGuideTitle')}
|
|
71
|
+
</NavigationLink>
|
|
48
72
|
</div>
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
</a>
|
|
61
|
-
</div>
|
|
62
|
-
</div>
|
|
63
|
-
<div className="rounded-2xl border border-border/75 bg-card p-6">
|
|
64
|
-
<div className="mb-6 flex items-center gap-3">
|
|
65
|
-
<div className="flex h-9 w-9 items-center justify-center rounded-lg bg-muted text-muted-foreground">
|
|
66
|
-
<Folder className="h-4 w-4" />
|
|
73
|
+
</SettingRow>
|
|
74
|
+
<SettingRow title={t('workspace')} layout='stacked'>
|
|
75
|
+
<div className='space-y-2'>
|
|
76
|
+
<Label htmlFor='workspace' className='sr-only'>{t('workspace')}</Label>
|
|
77
|
+
<Input
|
|
78
|
+
id='workspace'
|
|
79
|
+
value={workspace}
|
|
80
|
+
onChange={(event) => setWorkspace(event.target.value)}
|
|
81
|
+
placeholder={workspacePlaceholder}
|
|
82
|
+
className='rounded-xl'
|
|
83
|
+
/>
|
|
67
84
|
</div>
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
<Label htmlFor="workspace" className="text-xs font-medium text-muted-foreground">
|
|
72
|
-
{workspaceLabel}
|
|
73
|
-
</Label>
|
|
74
|
-
<Input id="workspace" value={workspace} onChange={(event) => setWorkspace(event.target.value)} placeholder={workspacePlaceholder} className="rounded-xl" />
|
|
75
|
-
</div>
|
|
76
|
-
</div>
|
|
77
|
-
</div>
|
|
85
|
+
</SettingRow>
|
|
86
|
+
</SettingsGroup>
|
|
87
|
+
</SettingsSection>
|
|
78
88
|
<FormActions>
|
|
79
|
-
<Button type=
|
|
80
|
-
{isPending ? <Loader2 className=
|
|
89
|
+
<Button type='submit' disabled={isPending} size='sm'>
|
|
90
|
+
{isPending ? <Loader2 className='h-3.5 w-3.5 animate-spin' /> : t('saveChanges')}
|
|
81
91
|
</Button>
|
|
82
92
|
</FormActions>
|
|
83
93
|
</form>
|
|
@@ -95,7 +105,13 @@ export function ModelConfigPage() {
|
|
|
95
105
|
const workspaceHint = hintForPath('agents.defaults.workspace', uiHints);
|
|
96
106
|
|
|
97
107
|
const providerCatalog = useMemo(
|
|
98
|
-
() =>
|
|
108
|
+
() =>
|
|
109
|
+
buildProviderModelCatalog({
|
|
110
|
+
providersView,
|
|
111
|
+
templatesView,
|
|
112
|
+
config,
|
|
113
|
+
onlyConfigured: true
|
|
114
|
+
}),
|
|
99
115
|
[config, providersView, templatesView]
|
|
100
116
|
);
|
|
101
117
|
const modelHelpText = t('modelIdentifierHelp') || modelHint?.help || '';
|
|
@@ -104,50 +120,39 @@ export function ModelConfigPage() {
|
|
|
104
120
|
|
|
105
121
|
if (isLoading) {
|
|
106
122
|
return (
|
|
107
|
-
<
|
|
108
|
-
<div className=
|
|
109
|
-
<
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
<Card hover={false} className="rounded-2xl border-border/75 p-6 shadow-none">
|
|
113
|
-
<div className="mb-6 flex items-center gap-3">
|
|
114
|
-
<Skeleton className="h-9 w-9 rounded-lg" />
|
|
115
|
-
<div className="space-y-2">
|
|
116
|
-
<Skeleton className="h-5 w-24" />
|
|
117
|
-
<Skeleton className="h-3 w-32" />
|
|
118
|
-
</div>
|
|
123
|
+
<SettingsPage title={t('modelPageTitle')} description={t('modelPageDescription')}>
|
|
124
|
+
<div className='divide-y divide-border/55 overflow-hidden rounded-2xl bg-muted/45'>
|
|
125
|
+
<div className='space-y-3 p-4'>
|
|
126
|
+
<Skeleton className='h-5 w-24' />
|
|
127
|
+
<Skeleton className='h-10 w-full rounded-xl' />
|
|
119
128
|
</div>
|
|
120
|
-
<
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
</Card>
|
|
127
|
-
</div>
|
|
129
|
+
<div className='space-y-3 p-4'>
|
|
130
|
+
<Skeleton className='h-5 w-24' />
|
|
131
|
+
<Skeleton className='h-10 w-full rounded-xl' />
|
|
132
|
+
</div>
|
|
133
|
+
</div>
|
|
134
|
+
</SettingsPage>
|
|
128
135
|
);
|
|
129
136
|
}
|
|
130
137
|
|
|
131
138
|
return (
|
|
132
|
-
<
|
|
133
|
-
<PageHeader title={t('modelPageTitle')} description={t('modelPageDescription')} />
|
|
139
|
+
<SettingsPage title={t('modelPageTitle')} description={t('modelPageDescription')}>
|
|
134
140
|
<ModelConfigForm
|
|
135
141
|
key={`${initialModel}::${initialWorkspace}`}
|
|
136
142
|
initialModel={initialModel}
|
|
137
143
|
initialWorkspace={initialWorkspace}
|
|
138
144
|
isPending={updateModel.isPending}
|
|
139
145
|
modelHelpText={modelHelpText}
|
|
140
|
-
modelLabel={modelHint?.label ?? 'Model Name'}
|
|
141
146
|
modelPlaceholder={modelHint?.placeholder ?? DEFAULT_MODEL_INPUT_PLACEHOLDER}
|
|
142
147
|
onSubmit={({ model, workspace }) =>
|
|
143
148
|
updateModel.mutate({
|
|
144
149
|
model,
|
|
145
150
|
workspace
|
|
146
|
-
})
|
|
151
|
+
})
|
|
152
|
+
}
|
|
147
153
|
providerCatalog={providerCatalog}
|
|
148
|
-
workspaceLabel={workspaceHint?.label ?? 'Default Path'}
|
|
149
154
|
workspacePlaceholder={workspaceHint?.placeholder ?? '/path/to/workspace'}
|
|
150
155
|
/>
|
|
151
|
-
</
|
|
156
|
+
</SettingsPage>
|
|
152
157
|
);
|
|
153
158
|
}
|