@pheem49/mint 1.16.0 → 1.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Cargo.lock +6 -6
- package/Cargo.toml +2 -2
- package/README.md +8 -2
- package/Release_Note.md +222 -72
- package/apps/mint-companion/src-tauri/src/compact.rs +69 -0
- package/apps/mint-companion/src-tauri/src/main.rs +218 -11
- package/apps/mint-companion/vite.config.ts +2 -1
- package/crates/mint-cli/src/agent/diff_render.rs +66 -44
- package/crates/mint-cli/src/agent/live_status.rs +64 -6
- package/crates/mint-cli/src/agent/markdown_render.rs +342 -5
- package/crates/mint-cli/src/agent.rs +202 -47
- package/crates/mint-cli/src/commands/agent.rs +223 -117
- package/crates/mint-cli/src/commands/browser.rs +114 -0
- package/crates/mint-cli/src/commands/config.rs +14 -1
- package/crates/mint-cli/src/commands/integrations.rs +3 -3
- package/crates/mint-cli/src/commands/knowledge.rs +16 -2
- package/crates/mint-cli/src/commands/mod.rs +15 -4
- package/crates/mint-cli/src/commands/tailnet_web.rs +3 -7
- package/crates/mint-cli/src/companion_navigation.rs +268 -0
- package/crates/mint-cli/src/interactive/chat_tui/dialog.rs +572 -0
- package/crates/mint-cli/src/interactive/chat_tui/mod.rs +1427 -0
- package/crates/mint-cli/src/interactive/chat_tui/render.rs +1524 -0
- package/crates/mint-cli/src/interactive/chat_tui/selection.rs +401 -0
- package/crates/mint-cli/src/interactive/chat_tui/state.rs +1833 -0
- package/crates/mint-cli/src/interactive/chat_tui/tests.rs +3414 -0
- package/crates/mint-cli/src/interactive/chat_tui/thought.rs +202 -0
- package/crates/mint-cli/src/interactive/chat_tui/transcript.rs +728 -0
- package/crates/mint-cli/src/interactive/chat_tui/watermark.rs +148 -0
- package/crates/mint-cli/src/interactive/command_ui.rs +92 -5
- package/crates/mint-cli/src/interactive/composer.rs +186 -0
- package/crates/mint-cli/src/interactive/format.rs +78 -3
- package/crates/mint-cli/src/interactive/input_box.rs +61 -1
- package/crates/mint-cli/src/interactive/resume_picker.rs +367 -25
- package/crates/mint-cli/src/interactive/slash_commands.rs +758 -373
- package/crates/mint-cli/src/interactive/tool_activity.rs +468 -56
- package/crates/mint-cli/src/interactive.rs +74 -5
- package/crates/mint-cli/src/main.rs +26 -2
- package/crates/mint-cli/src/markdown.rs +2 -37
- package/crates/mint-cli/src/onboard.rs +3897 -1321
- package/crates/mint-cli/src/setup.rs +1342 -624
- package/crates/mint-cli/src/terminal_theme.rs +159 -35
- package/crates/mint-cli/tests/library_intake.rs +1 -0
- package/crates/mint-cli/tests/mods_testing.rs +5 -1
- package/crates/mint-companion-protocol/src/lib.rs +113 -0
- package/crates/mint-core/src/agent/chat/anthropic.rs +318 -0
- package/crates/mint-core/src/agent/chat/custom.rs +149 -0
- package/crates/mint-core/src/agent/chat/gemini.rs +518 -0
- package/crates/mint-core/src/agent/chat/mod.rs +857 -0
- package/crates/mint-core/src/agent/chat/ollama.rs +321 -0
- package/crates/mint-core/src/agent/chat/openai.rs +582 -0
- package/crates/mint-core/src/agent/chat/streaming.rs +469 -0
- package/crates/mint-core/src/agent/chat/tests.rs +1479 -0
- package/crates/mint-core/src/agent/memory.rs +129 -8
- package/crates/mint-core/src/agent/safety.rs +56 -4
- package/crates/mint-core/src/agent/skill_inventory.rs +3 -1
- package/crates/mint-core/src/agent/skills.rs +1 -0
- package/crates/mint-core/src/agent/tasks.rs +2 -2
- package/crates/mint-core/src/api_server/routes/auth.rs +1 -4
- package/crates/mint-core/src/api_server/routes/chat.rs +53 -17
- package/crates/mint-core/src/api_server/routes/gemini_live.rs +14 -1
- package/crates/mint-core/src/api_server/routes/html_preview.rs +1 -8
- package/crates/mint-core/src/api_server/routes/misc.rs +116 -0
- package/crates/mint-core/src/api_server/routes/profile_oauth.rs +43 -26
- package/crates/mint-core/src/api_server/routes/sessions.rs +114 -76
- package/crates/mint-core/src/api_server/routes/skills_subagents.rs +11 -7
- package/crates/mint-core/src/api_server/routes/status_health.rs +18 -8
- package/crates/mint-core/src/api_server.rs +211 -65
- package/crates/mint-core/src/avatar_bridge.rs +5 -24
- package/crates/mint-core/src/browser/cdp.rs +92 -30
- package/crates/mint-core/src/browser/headless.rs +582 -0
- package/crates/mint-core/src/browser/input.rs +7 -62
- package/crates/mint-core/src/browser/interact.rs +0 -14
- package/crates/mint-core/src/browser/mod.rs +10 -30
- package/crates/mint-core/src/browser/navigate.rs +83 -44
- package/crates/mint-core/src/browser/runtime.rs +282 -0
- package/crates/mint-core/src/browser/session.rs +240 -400
- package/crates/mint-core/src/browser/workflow.rs +496 -0
- package/crates/mint-core/src/companion/navigation.rs +115 -0
- package/crates/mint-core/src/companion.rs +109 -1
- package/crates/mint-core/src/cron/store.rs +2 -2
- package/crates/mint-core/src/integrations/mcp.rs +6 -8
- package/crates/mint-core/src/integrations/mcp_result.rs +45 -0
- package/crates/mint-core/src/lib.rs +10 -11
- package/crates/mint-core/src/media/gemini_live.rs +636 -86
- package/crates/mint-core/src/media/image_proxy.rs +563 -0
- package/crates/mint-core/src/media/library/migration.rs +26 -0
- package/crates/mint-core/src/media/library/tests.rs +1 -1
- package/crates/mint-core/src/media/library/thumbnails.rs +8 -2
- package/crates/mint-core/src/media/pictures.rs +1 -1
- package/crates/mint-core/src/media/tool_images.rs +287 -0
- package/crates/mint-core/src/media/tts/playback.rs +609 -0
- package/crates/mint-core/src/media/tts.rs +1 -0
- package/crates/mint-core/src/media.rs +2 -0
- package/crates/mint-core/src/mods/manager.rs +101 -35
- package/crates/mint-core/src/orchestration/context_render.rs +878 -44
- package/crates/mint-core/src/orchestration/decision_parsing.rs +536 -39
- package/crates/mint-core/src/orchestration/diagnostics.rs +307 -0
- package/crates/mint-core/src/orchestration/full_skill_result_tests.rs +12 -0
- package/crates/mint-core/src/orchestration/image_regressions.rs +379 -0
- package/crates/mint-core/src/orchestration/loop_guard.rs +479 -0
- package/crates/mint-core/src/orchestration/mcp_outcome_tests.rs +864 -0
- package/crates/mint-core/src/orchestration/memory_skill.rs +88 -28
- package/crates/mint-core/src/orchestration/mod.rs +859 -4244
- package/crates/mint-core/src/orchestration/reliability.rs +581 -0
- package/crates/mint-core/src/orchestration/repeated_failures.rs +8 -0
- package/crates/mint-core/src/orchestration/review_regressions.rs +179 -28
- package/crates/mint-core/src/orchestration/tests.rs +1665 -0
- package/crates/mint-core/src/orchestration/tools/dispatch.rs +967 -0
- package/crates/mint-core/src/orchestration/tools/files.rs +32 -3
- package/crates/mint-core/src/orchestration/tools/mod.rs +5 -1
- package/crates/mint-core/src/orchestration/tools/planning.rs +102 -42
- package/crates/mint-core/src/orchestration/tools/plugins_mcp.rs +19 -4
- package/crates/mint-core/src/orchestration/tools/project.rs +1 -1
- package/crates/mint-core/src/orchestration/tools/shell.rs +157 -62
- package/crates/mint-core/src/orchestration/tools/web.rs +5 -1
- package/crates/mint-core/src/orchestration/trajectory_schema.rs +353 -0
- package/crates/mint-core/src/orchestration/truncation.rs +368 -0
- package/crates/mint-core/src/orchestration/types.rs +648 -0
- package/crates/mint-core/src/orchestration/verification.rs +36 -9
- package/crates/mint-core/src/orchestration/workspace_helpers.rs +76 -27
- package/crates/mint-core/src/prompts/agent.rs +69 -102
- package/crates/mint-core/src/prompts/tool_catalog.rs +104 -153
- package/crates/mint-core/src/search/files.rs +20 -0
- package/crates/mint-core/src/search/web_search.rs +44 -3
- package/crates/mint-core/src/slash/mod.rs +481 -55
- package/crates/mint-core/src/slash/models.rs +6 -1
- package/crates/mint-core/src/swarm/batch.rs +643 -0
- package/crates/mint-core/src/swarm/dossier.rs +152 -0
- package/crates/mint-core/src/swarm/labels.rs +100 -0
- package/crates/mint-core/src/swarm/mod.rs +158 -0
- package/crates/mint-core/src/swarm/permissions.rs +167 -0
- package/crates/mint-core/src/system/auth.rs +156 -7
- package/crates/mint-core/src/system/bg_shell.rs +78 -9
- package/crates/mint-core/src/system/config.rs +266 -35
- package/crates/mint-core/src/system/mint_web.rs +33 -12
- package/crates/mint-core/src/system/shell.rs +179 -10
- package/crates/mint-core/src/system/workspace.rs +204 -0
- package/crates/mint-core/tests/background_retention.rs +1 -1
- package/crates/mint-core/tests/memory_persistence.rs +27 -0
- package/crates/mint-mod-runtime/src/lib.rs +37 -23
- package/out/web/assets/ArtifactPreviewPanel-Cx6BVOOF.js +2 -0
- package/out/web/assets/ArtifactPreviewPanel-DAT_Y7i0.css +1 -0
- package/out/web/assets/CalculationCard-D2E74u5q.js +1 -0
- package/out/web/assets/CliSessionsView-ZbdtSjvK.css +1 -0
- package/out/web/assets/CliSessionsView-z5i6qGyb.js +1 -0
- package/out/web/assets/CodeReviewPage-BK2bOScd.css +1 -0
- package/out/web/assets/CodeReviewPage-Dp6zHuHu.js +2 -0
- package/out/web/assets/CommandPalette-DaKlzbKs.js +1 -0
- package/out/web/assets/ImageGenCard-BMCJHP9O.js +1 -0
- package/out/web/assets/ImageSearchCard-Cld_SOUg.js +1 -0
- package/out/web/assets/ImageStudioPanel-B5N7TjeB.js +1 -0
- package/out/web/assets/LibraryPage-CMB89rJ0.css +1 -0
- package/out/web/assets/LibraryPage-DbZEi4W_.js +2 -0
- package/out/web/assets/LinkedFoldersView-9B9DIPoZ.js +1 -0
- package/out/web/assets/McpRegistryPicker-DnXPlzI7.js +1 -0
- package/out/web/assets/McpServersView-CiNBNUl4.js +1 -0
- package/out/web/assets/MermaidCard-BBDNEXbY.js +2 -0
- package/out/web/assets/MintDashboard-C_UYPoNV.js +119 -0
- package/out/web/assets/MintDashboard-DTd8C_c8.css +1 -0
- package/out/web/assets/PlanCard-C2x5pajq.js +1 -0
- package/out/web/assets/PluginsView-DoTg9MVa.js +1 -0
- package/out/web/assets/RewindModal-B5oowrR0.js +1 -0
- package/out/web/assets/ScheduledTasksView-BD5DVPkZ.js +1 -0
- package/out/web/assets/SelectField-Cy6CghrU.js +1 -0
- package/out/web/assets/SelectField-lFEkkWCU.css +1 -0
- package/out/web/assets/SettingsWindow-BYl_oCFh.js +4 -0
- package/out/web/assets/SettingsWindow-Ckcgnjt8.css +1 -0
- package/out/web/assets/SkillsView-CIeWwq5z.js +2 -0
- package/out/web/assets/StockCard-DxUciKyp.js +1 -0
- package/out/web/assets/ToolSurfacePage-qBgs_VHq.css +1 -0
- package/out/web/assets/ToolSurfacePage-saVbVrkE.js +38 -0
- package/out/web/assets/UiFeatureCard-CdY0hGWy.js +1 -0
- package/out/web/assets/UiGridCard-BBK3I5hC.js +1 -0
- package/out/web/assets/UiMockupWidget-CpR9EDuc.js +1 -0
- package/out/web/assets/{VeoStudioPanel-DOj7_WR3.css → VeoStudioPanel-9kU9YLEN.css} +1 -1
- package/out/web/assets/VeoStudioPanel-Co6-wEWM.js +4 -0
- package/out/web/assets/WeatherCard-Buzi7Vfu.js +1 -0
- package/out/web/assets/WorkspacePanel-BfHKkulU.js +1 -0
- package/out/web/assets/WorkspacePdfPreview-Bi8Zzyir.js +2 -0
- package/out/web/assets/abnfDiagram-VCTEODGH-CMfR95N2.js +1 -0
- package/out/web/assets/architecture-7GRP2DOG-DhAM4HyO.js +1 -0
- package/out/web/assets/architectureDiagram-5GKGNRK7-Yk3TUJ_F.js +36 -0
- package/out/web/assets/{blockDiagram-NRAW4CY4-BrrqzHW5.js → blockDiagram-I7D4REHJ-X9fBgJik.js} +4 -4
- package/out/web/assets/c4Diagram-7LVT6UL2-Bk9x7N-8.js +38 -0
- package/out/web/assets/chunk-2Q5K7J3B-D2JLPQzF.js +1 -0
- package/out/web/assets/{chunk-TEH6E4GO-G4Cdlyrt.js → chunk-4HAMMTFA-Dx5fk1_0.js} +3 -3
- package/out/web/assets/{chunk-5VM5RSS4-BiPuE0io.js → chunk-5VM5RSS4-BZ2oBPYQ.js} +1 -1
- package/out/web/assets/chunk-75Z2AOVW-BszTQoM4.js +2 -0
- package/out/web/assets/chunk-DU6HZSFF-DK-As3rk.js +128 -0
- package/out/web/assets/chunk-F27PBJKO-LmncZZIS.js +1 -0
- package/out/web/assets/chunk-FOHPRMQF-JXEeeJ9r.js +161 -0
- package/out/web/assets/{chunk-GMAD6QVW-BuhEcgHq.js → chunk-GMAD6QVW-DSQ_sDRJ.js} +12 -12
- package/out/web/assets/chunk-GVQU2GXP-Cno3ulje.js +1 -0
- package/out/web/assets/chunk-IMKFNOWR-bIzfY9Jc.js +231 -0
- package/out/web/assets/chunk-JWPE2WC7-BeEMUFDw.js +1 -0
- package/out/web/assets/chunk-L3NEJ4N5-Dl6eOa0D.js +1 -0
- package/out/web/assets/chunk-OSK3NFVY-BaUGJ-cM.js +10 -0
- package/out/web/assets/chunk-P2QGCYS3-_066ndhH.js +1 -0
- package/out/web/assets/chunk-POPQ4Y6H-YT1AKhTv.js +1 -0
- package/out/web/assets/chunk-PWAF6VOD-CrEgDsxh.js +1 -0
- package/out/web/assets/chunk-SHT3W25Y-_KwaRLOl.js +168 -0
- package/out/web/assets/{chunk-SVP7TREG-Bu_yYb-V.js → chunk-SVP7TREG-BQ1qb32L.js} +1 -1
- package/out/web/assets/{chunk-LCL6LL3I-BhXV9zyH.js → chunk-TICWLB2K-BDyehCtg.js} +4 -4
- package/out/web/assets/chunk-XXDRQBXY-B9YlhOkE.js +1 -0
- package/out/web/assets/chunk-Y2CYZVJY-BxCWjNVG.js +1 -0
- package/out/web/assets/classDiagram-ZZMXUADV-BoSpzRCJ.js +1 -0
- package/out/web/assets/classDiagram-v2-VYDZK3BY-BoSpzRCJ.js +1 -0
- package/out/web/assets/config-2suVFPZg.css +1 -0
- package/out/web/assets/config-CkRCdkxn.js +2 -0
- package/out/web/assets/core-Mi3s5D4_.js +1 -0
- package/out/web/assets/cose-bilkent-JH36ORCC-qlna31ty.js +1 -0
- package/out/web/assets/cynefin-OW5HDTMX-Dl_31aaN.js +1 -0
- package/out/web/assets/cynefinDiagram-5FMLGOSQ-Bpir8jha.js +62 -0
- package/out/web/assets/cytoscape.esm-DWtAUG0r.js +321 -0
- package/out/web/assets/dagre-CnWJJM5f.js +1 -0
- package/out/web/assets/dagre-GXQ25YYZ-D9xu3nsq.js +4 -0
- package/out/web/assets/diagram-S7CK7UJ4-DeveoEeB.js +30 -0
- package/out/web/assets/diagram-UQ7AKVKN-p4xWRESV.js +41 -0
- package/out/web/assets/{diagram-VSXAHHWV-BJ86Ov2Y.js → diagram-VSXAHHWV-C7qz9NDF.js} +1 -1
- package/out/web/assets/diagram-VX7I27RA-DRiCa3Vd.js +24 -0
- package/out/web/assets/diagram-Z3DM3KII-Bt7zduQX.js +24 -0
- package/out/web/assets/dist-9ISJ7r-g.js +1 -0
- package/out/web/assets/dist-js-BV3mI7uw.js +1 -0
- package/out/web/assets/ebnfDiagram-PWID7BFC-DV9WpwdR.js +1 -0
- package/out/web/assets/{erDiagram-SSCWMZ5O-CzzmnZWT.js → erDiagram-RLTQ6QDP-BJ_nwG2m.js} +3 -3
- package/out/web/assets/event-D7D-EBy9.js +1 -0
- package/out/web/assets/eventmodeling-NTZA5JFV-BTBMrfVa.js +1 -0
- package/out/web/assets/flowDiagram-HODETNUW-Cdlq3cJL.js +1 -0
- package/out/web/assets/ganttDiagram-EL5Y4UJY-DQLdsXrC.js +292 -0
- package/out/web/assets/gitGraph-4MIJSDKK-CL1OEOQ_.js +1 -0
- package/out/web/assets/gitGraphDiagram-WWUBYQGX-8cSi42H7.js +106 -0
- package/out/web/assets/graphlib-Bh9gHply.js +1 -0
- package/out/web/assets/index-BocxnrDG.js +168 -0
- package/out/web/assets/index-yeh_r55a.css +1 -0
- package/out/web/assets/info-A6RAGUB7-C1zsX5sc.js +1 -0
- package/out/web/assets/infoDiagram-27XIBGKW-DsRYtIyI.js +2 -0
- package/out/web/assets/{ishikawaDiagram-5VMMS53U-s38yo28y.js → ishikawaDiagram-5VMMS53U-B2crwIXj.js} +4 -4
- package/out/web/assets/journeyDiagram-3NMN7TZE-BTH-GyVR.js +139 -0
- package/out/web/assets/jsx-runtime-DmUwWVTj.js +1 -0
- package/out/web/assets/{kanban-definition-3QL26DDD-DodjgySL.js → kanban-definition-UXKFOSKX-BeRfCnuA.js} +6 -6
- package/out/web/assets/katex-MCdQaEAD.js +257 -0
- package/out/web/assets/mermaid-parser.core-BJwgCBBc.js +7 -0
- package/out/web/assets/mermaid.core-CsDDodN8.js +44 -0
- package/out/web/assets/{mindmap-definition-FBJOCRG2-260WBDxZ.js → mindmap-definition-YA3MSWOX-B42efOQ1.js} +4 -4
- package/out/web/assets/modelManager-B3ZFMh8v.js +2 -0
- package/out/web/assets/oauthManager-Ch5Du2fF.js +1 -0
- package/out/web/assets/packet-AYTQ26CC-B6xUyE6r.js +1 -0
- package/out/web/assets/pdf-Bcahc2yC.js +56 -0
- package/out/web/assets/pdf.worker.min-Dkey6ZUl.mjs +27 -0
- package/out/web/assets/pegDiagram-XKGWAZYB-1LabVycL.js +1 -0
- package/out/web/assets/pie-WAS4IAKB-DJwo-nf_.js +1 -0
- package/out/web/assets/pieDiagram-E7YTZNPT-icmAqzy4.js +39 -0
- package/out/web/assets/{quadrantDiagram-AXDQQJYC-B8D3gU5d.js → quadrantDiagram-AXDQQJYC-CZ-wEx41.js} +4 -4
- package/out/web/assets/radar-RG4KPBEZ-D7d-Xriw.js +1 -0
- package/out/web/assets/railroad-74A4TZTK-viuhdYbs.js +1 -0
- package/out/web/assets/railroad-abnf-HS5TGJTU-DNXiCNea.js +1 -0
- package/out/web/assets/railroad-ebnf-LZEXJU2U-nkSu1-0C.js +1 -0
- package/out/web/assets/railroad-peg-WCYAUIDC-BhbMeQzz.js +1 -0
- package/out/web/assets/railroadDiagram-O6MQD6OU-CLpG1jUX.js +1 -0
- package/out/web/assets/{requirementDiagram-EFPCY7ZU-D2X-Ewik.js → requirementDiagram-BXWQKSXE-kRDrvWrc.js} +3 -3
- package/out/web/assets/rolldown-runtime-CNOWq4Kh.js +1 -0
- package/out/web/assets/rough.esm-CNnFptCR.js +1 -0
- package/out/web/assets/sankeyDiagram-P5KCCOFB-DxAwmq4x.js +40 -0
- package/out/web/assets/sequenceDiagram-WJ2MYXX4-aLgY-6Wz.js +162 -0
- package/out/web/assets/sizeCapture-INFHLROL-C8Q8DbV5.js +1 -0
- package/out/web/assets/src-CRDfRlHM.js +1 -0
- package/out/web/assets/stateDiagram-D77RDMKH-D5QWfOhp.js +1 -0
- package/out/web/assets/stateDiagram-v2-MP3YSRHH-D6OiZoAP.js +1 -0
- package/out/web/assets/studio-BBZQ_-QK.js +1 -0
- package/out/web/assets/swimlanes-42K2YHIH-CRs5UyA-.js +1 -0
- package/out/web/assets/swimlanesDiagram-VR7AAH4N-UgEXIsV0.js +8 -0
- package/out/web/assets/syntaxHighlight-C-wAGT84.js +3 -0
- package/out/web/assets/timeline-definition-24CTP7MA-Denqd9qb.js +120 -0
- package/out/web/assets/treeView-Q6P3EWNA-0my3Z3s4.js +1 -0
- package/out/web/assets/treemap-WGGIJYW6-B_EjkLYq.js +1 -0
- package/out/web/assets/vennDiagram-4TSXK5OY-DxVg3Ewr.js +34 -0
- package/out/web/assets/wardley-WFR3VGLG-CGD-Tj4p.js +1 -0
- package/out/web/assets/{wardleyDiagram-VM6X3IG4-DAdXELbQ.js → wardleyDiagram-VM6X3IG4-CmfS39Xm.js} +35 -35
- package/out/web/assets/window-CkUOP7t0.js +1 -0
- package/out/web/assets/workspaces-SYPrmbgC.js +1 -0
- package/out/web/assets/{xychartDiagram-S5SC5T6Z-IZIXf3Vo.js → xychartDiagram-S5SC5T6Z-BVM9bKis.js} +4 -4
- package/out/web/index-web.html +4 -4
- package/out/web/index.html +4 -4
- package/out/web/pdfjs/cmaps/78-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78ms-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/78ms-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/83pv-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90ms-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90ms-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90msp-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90msp-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90pv-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/90pv-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Add-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Add-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Add-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Add-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-0.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-1.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-3.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-4.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-5.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-6.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-CNS1-UCS2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-0.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-1.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-3.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-4.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-5.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-GB1-UCS2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-0.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-1.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-3.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-4.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-5.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-6.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Japan1-UCS2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Korea1-0.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Korea1-1.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Korea1-2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Adobe-Korea1-UCS2.bcmap +0 -0
- package/out/web/pdfjs/cmaps/B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/B5pc-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/B5pc-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS1-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS1-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS2-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/CNS2-V.bcmap +3 -0
- package/out/web/pdfjs/cmaps/ETHK-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/ETHK-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/ETen-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/ETen-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/ETenms-B5-H.bcmap +3 -0
- package/out/web/pdfjs/cmaps/ETenms-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Ext-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Ext-RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Ext-RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Ext-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GB-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GB-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GB-H.bcmap +4 -0
- package/out/web/pdfjs/cmaps/GB-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBK-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBK-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBK2K-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBK2K-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBKp-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBKp-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBT-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBT-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBT-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBT-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBTpc-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBTpc-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBpc-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/GBpc-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKdla-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKdla-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKdlb-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKdlb-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKgccs-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKgccs-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKm314-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKm314-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKm471-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKm471-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKscs-B5-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/HKscs-B5-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Hankaku.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Hiragana.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-Johab-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-Johab-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCms-UHC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCms-UHC-HW-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCms-UHC-HW-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCms-UHC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCpc-EUC-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/KSCpc-EUC-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Katakana.bcmap +0 -0
- package/out/web/pdfjs/cmaps/LICENSE +36 -0
- package/out/web/pdfjs/cmaps/NWP-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/NWP-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/RKSJ-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/RKSJ-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/Roman.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UCS2-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UCS2-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF16-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF16-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF8-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniCNS-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UCS2-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UCS2-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF16-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF16-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF8-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniGB-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UCS2-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UCS2-HW-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UCS2-HW-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UCS2-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF16-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF16-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF8-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF16-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF16-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF8-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJIS2004-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISPro-UCS2-HW-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISPro-UCS2-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISPro-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISX0213-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISX0213-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISX02132004-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniJISX02132004-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UCS2-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UCS2-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF16-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF16-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF32-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF32-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF8-H.bcmap +0 -0
- package/out/web/pdfjs/cmaps/UniKS-UTF8-V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/V.bcmap +0 -0
- package/out/web/pdfjs/cmaps/WP-Symbol.bcmap +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitDingbats.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitFixed.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitFixedBold.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitFixedBoldItalic.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitFixedItalic.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitSerif.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitSerifBold.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitSerifBoldItalic.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitSerifItalic.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/FoxitSymbol.pfb +0 -0
- package/out/web/pdfjs/standard_fonts/LICENSE_FOXIT +27 -0
- package/out/web/pdfjs/standard_fonts/LICENSE_LIBERATION +363 -0
- package/out/web/pdfjs/standard_fonts/LiberationSans-Bold.ttf +0 -0
- package/out/web/pdfjs/standard_fonts/LiberationSans-BoldItalic.ttf +0 -0
- package/out/web/pdfjs/standard_fonts/LiberationSans-Italic.ttf +0 -0
- package/out/web/pdfjs/standard_fonts/LiberationSans-Regular.ttf +0 -0
- package/out/web/pdfjs/wasm/LICENSE_JBIG2 +196 -0
- package/out/web/pdfjs/wasm/LICENSE_OPENJPEG +39 -0
- package/out/web/pdfjs/wasm/LICENSE_PDFJS_JBIG2 +13 -0
- package/out/web/pdfjs/wasm/LICENSE_PDFJS_OPENJPEG +22 -0
- package/out/web/pdfjs/wasm/LICENSE_PDFJS_QCMS +19 -0
- package/out/web/pdfjs/wasm/LICENSE_QCMS +21 -0
- package/out/web/pdfjs/wasm/jbig2.wasm +0 -0
- package/out/web/pdfjs/wasm/jbig2_nowasm_fallback.js +15 -0
- package/out/web/pdfjs/wasm/openjpeg.wasm +0 -0
- package/out/web/pdfjs/wasm/openjpeg_nowasm_fallback.js +17 -0
- package/out/web/pdfjs/wasm/qcms_bg.wasm +0 -0
- package/out/web/pdfjs/wasm/quickjs-eval.js +16 -0
- package/out/web/pdfjs/wasm/quickjs-eval.wasm +0 -0
- package/package.json +6 -4
- package/shared-modules/CODEOWNERS +3 -3
- package/shared-modules/SDL2/SDL2_mixer.json +27 -0
- package/shared-modules/appstream/README.md +13 -0
- package/shared-modules/appstream/appstream-compose.json +111 -0
- package/shared-modules/dbus-glib/dbus-glib.json +2 -2
- package/shared-modules/libportal/libportal.json +23 -0
- package/shared-modules/linux-audio/fluidsynth2-static.json +2 -2
- package/shared-modules/linux-audio/fluidsynth2.json +2 -2
- package/shared-modules/linux-audio/libinstpatch.json +2 -2
- package/shared-modules/linux-audio/liblo-static.json +3 -0
- package/shared-modules/luajit/luajit.json +2 -2
- package/shared-modules/squashfs-tools/squashfs-tools.json +0 -3
- package/slash-commands.json +14 -3
- package/src/bin/index.js +4 -1
- package/src/bin/pdfjs-assets.mjs +31 -0
- package/src/renderer/node_modules/.vite/vitest/CACHEDIR.TAG +3 -0
- package/src/renderer/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -1
- package/src/renderer/shared/agentProgress.ts +62 -5
- package/src/renderer/shared/components/Settings/AgentsTab.tsx +70 -6
- package/src/renderer/shared/components/Settings/AudioTab.tsx +1 -1
- package/src/renderer/shared/components/Settings/AutomationTab.tsx +32 -29
- package/src/renderer/shared/components/Settings/AvatarCropModal.tsx +32 -12
- package/src/renderer/shared/components/Settings/CustomProviderLogoPicker.test.tsx +65 -0
- package/src/renderer/shared/components/Settings/CustomProviderLogoPicker.tsx +456 -0
- package/src/renderer/shared/components/Settings/GeneralTab.tsx +65 -94
- package/src/renderer/shared/components/Settings/PluginsTab.tsx +101 -24
- package/src/renderer/shared/components/Settings/ProfileTab.tsx +1 -1
- package/src/renderer/shared/components/Settings/SettingsWindow.tsx +796 -0
- package/src/renderer/shared/components/Settings/ThemeTab.test.tsx +45 -0
- package/src/renderer/shared/components/Settings/ThemeTab.tsx +119 -4
- package/src/renderer/shared/components/activity/AgentActivityDrawer.tsx +270 -0
- package/src/renderer/shared/components/activity/AgentActivityTable.tsx +582 -0
- package/src/renderer/shared/components/activity/AskUserActivityCard.test.tsx +122 -0
- package/src/renderer/shared/components/activity/AskUserActivityCard.tsx +70 -0
- package/src/renderer/shared/components/{McpToolResults.tsx → activity/McpToolResults.tsx} +69 -13
- package/src/renderer/shared/components/{PlanChecklistWidget.tsx → activity/PlanChecklistWidget.tsx} +2 -2
- package/src/renderer/shared/components/activity/RunSummaryDashboard.test.tsx +127 -0
- package/src/renderer/shared/components/activity/RunSummaryDashboard.tsx +222 -0
- package/src/renderer/shared/components/activity/SubagentDagView.test.ts +123 -0
- package/src/renderer/shared/components/{SubagentDagView.tsx → activity/SubagentDagView.tsx} +104 -50
- package/src/renderer/shared/components/activity/SubagentStatusStrip.test.tsx +82 -0
- package/src/renderer/shared/components/activity/SubagentStatusStrip.tsx +107 -0
- package/src/renderer/shared/components/activity/ViewedImages.tsx +179 -0
- package/src/renderer/shared/components/{AuthGate.tsx → app/AuthGate.tsx} +3 -3
- package/src/renderer/shared/components/{ChunkErrorBoundary.tsx → app/ChunkErrorBoundary.tsx} +13 -13
- package/src/renderer/shared/components/{CommandPalette.tsx → app/CommandPalette.tsx} +30 -30
- package/src/renderer/shared/components/{DashboardSidebar.tsx → app/DashboardSidebar.tsx} +7 -5
- package/src/renderer/shared/components/{DesktopTitlebar.tsx → app/DesktopTitlebar.tsx} +9 -26
- package/src/renderer/shared/components/{ErrorNotice.tsx → app/ErrorNotice.tsx} +1 -1
- package/src/renderer/shared/components/{MintDashboard.tsx → app/MintDashboard.tsx} +217 -228
- package/src/renderer/shared/components/{ModalErrorBoundary.tsx → app/ModalErrorBoundary.tsx} +8 -8
- package/src/renderer/shared/components/{CalculationCard.tsx → cards/CalculationCard.tsx} +16 -30
- package/src/renderer/shared/components/{ImageGenCard.tsx → cards/ImageGenCard.tsx} +11 -24
- package/src/renderer/shared/components/{ImageSearchCard.tsx → cards/ImageSearchCard.tsx} +11 -24
- package/src/renderer/shared/components/{MermaidCard.tsx → cards/MermaidCard.tsx} +38 -22
- package/src/renderer/shared/components/cards/PlanCard.test.tsx +41 -0
- package/src/renderer/shared/components/cards/PlanCard.tsx +32 -0
- package/src/renderer/shared/components/cards/ReleaseNotesCard.test.tsx +29 -0
- package/src/renderer/shared/components/cards/ReleaseNotesCard.tsx +137 -0
- package/src/renderer/shared/components/{StockCard.tsx → cards/StockCard.tsx} +22 -38
- package/src/renderer/shared/components/cards/ToolResultCards.tsx +94 -0
- package/src/renderer/shared/components/{UiFeatureCard.tsx → cards/UiFeatureCard.tsx} +6 -6
- package/src/renderer/shared/components/{UiGridCard.tsx → cards/UiGridCard.tsx} +3 -3
- package/src/renderer/shared/components/{UiMockupWidget.tsx → cards/UiMockupWidget.tsx} +4 -4
- package/src/renderer/shared/components/{WeatherCard.tsx → cards/WeatherCard.tsx} +6 -6
- package/src/renderer/shared/components/{ApprovalCard.test.tsx → chat/ApprovalCard.test.tsx} +12 -1
- package/src/renderer/shared/components/{ApprovalCard.tsx → chat/ApprovalCard.tsx} +26 -7
- package/src/renderer/shared/components/chat/ArtifactCards.test.tsx +69 -0
- package/src/renderer/shared/components/chat/ArtifactCards.tsx +238 -0
- package/src/renderer/shared/components/chat/AttachedDocumentCard.test.tsx +39 -0
- package/src/renderer/shared/components/chat/AttachedDocumentCard.tsx +220 -0
- package/src/renderer/shared/components/chat/ChatCodeBlock.test.tsx +33 -0
- package/src/renderer/shared/components/{ChatCodeBlock.tsx → chat/ChatCodeBlock.tsx} +16 -2
- package/src/renderer/shared/components/chat/ChatMessageItem.test.tsx +183 -0
- package/src/renderer/shared/components/chat/ChatMessageItem.tsx +388 -0
- package/src/renderer/shared/components/chat/ChatModeSelector.css +227 -0
- package/src/renderer/shared/components/chat/ChatModeSelector.test.tsx +45 -0
- package/src/renderer/shared/components/chat/ChatModeSelector.tsx +198 -0
- package/src/renderer/shared/components/chat/ChatPanel.test.tsx +53 -0
- package/src/renderer/shared/components/{ChatPanel.tsx → chat/ChatPanel.tsx} +462 -537
- package/src/renderer/shared/components/{CollapsiblePasteInput.tsx → chat/CollapsiblePasteInput.tsx} +2 -2
- package/src/renderer/shared/components/{DiffReviewModal.tsx → chat/DiffReviewModal.tsx} +44 -44
- package/src/renderer/shared/components/chat/GeminiLiveOverlay.test.tsx +165 -0
- package/src/renderer/shared/components/{GeminiLiveOverlay.tsx → chat/GeminiLiveOverlay.tsx} +47 -5
- package/src/renderer/shared/components/{ModelSelectorPopover.tsx → chat/ModelSelectorPopover.tsx} +44 -16
- package/src/renderer/shared/components/chat/QueuedMessagesBanner.test.tsx +89 -0
- package/src/renderer/shared/components/chat/QueuedMessagesBanner.tsx +201 -0
- package/src/renderer/shared/components/{RewindModal.tsx → chat/RewindModal.tsx} +14 -14
- package/src/renderer/shared/components/{SlashChoicePanel.tsx → chat/SlashChoicePanel.tsx} +2 -2
- package/src/renderer/shared/components/{SlashSuggestions.test.tsx → chat/SlashSuggestions.test.tsx} +14 -0
- package/src/renderer/shared/components/{SlashSuggestions.tsx → chat/SlashSuggestions.tsx} +4 -4
- package/src/renderer/shared/components/chat/SourcesBlock.test.tsx +53 -0
- package/src/renderer/shared/components/{SourcesBlock.tsx → chat/SourcesBlock.tsx} +262 -123
- package/src/renderer/shared/components/{ThinkingBlock.tsx → chat/ThinkingBlock.tsx} +1 -1
- package/src/renderer/shared/components/chat/TurnFileChanges.test.tsx +130 -0
- package/src/renderer/shared/components/chat/TurnFileChanges.tsx +463 -0
- package/src/renderer/shared/components/{VoicePill.css → chat/VoicePill.css} +1 -1
- package/src/renderer/shared/components/{VoicePill.jsx → chat/VoicePill.jsx} +3 -2
- package/src/renderer/shared/components/{CliSessionsView.test.tsx → extensions/CliSessionsView.test.tsx} +2 -2
- package/src/renderer/shared/components/{CliSessionsView.tsx → extensions/CliSessionsView.tsx} +19 -16
- package/src/renderer/shared/components/{LinkedFoldersView.tsx → extensions/LinkedFoldersView.tsx} +3 -3
- package/src/renderer/shared/components/{McpRegistryPicker.tsx → extensions/McpRegistryPicker.tsx} +6 -6
- package/src/renderer/shared/components/{McpServersView.tsx → extensions/McpServersView.tsx} +105 -36
- package/src/renderer/shared/components/{McpToolAllowlist.tsx → extensions/McpToolAllowlist.tsx} +2 -2
- package/src/renderer/shared/components/{ModUi.test.tsx → extensions/ModUi.test.tsx} +9 -4
- package/src/renderer/shared/components/{ModsPanel.tsx → extensions/ModsPanel.tsx} +59 -7
- package/src/renderer/shared/components/{PluginsView.tsx → extensions/PluginsView.tsx} +6 -6
- package/src/renderer/shared/components/{ScheduledTasksView.tsx → extensions/ScheduledTasksView.tsx} +5 -5
- package/src/renderer/shared/components/extensions/SkillsView.test.tsx +31 -0
- package/src/renderer/shared/components/{SkillsView.tsx → extensions/SkillsView.tsx} +20 -4
- package/src/renderer/shared/components/{ImageStudioPanel.tsx → studio/ImageStudioPanel.tsx} +6 -6
- package/src/renderer/shared/components/{LibraryItemCard.tsx → studio/LibraryItemCard.tsx} +2 -2
- package/src/renderer/shared/components/{LibraryPage.tsx → studio/LibraryPage.tsx} +53 -10
- package/src/renderer/shared/components/{LibraryPreview.tsx → studio/LibraryPreview.tsx} +2 -2
- package/src/renderer/shared/components/{VeoStudioPanel.tsx → studio/VeoStudioPanel.tsx} +7 -7
- package/src/renderer/shared/components/{GlideSelect.css → ui/GlideSelect.css} +7 -6
- package/src/renderer/shared/components/ui/ProviderBrandIcon.test.tsx +67 -0
- package/src/renderer/shared/components/ui/ProviderBrandIcon.tsx +167 -0
- package/src/renderer/shared/components/ui/SelectField.tsx +506 -0
- package/src/renderer/shared/components/ui/error-recovery.css +10 -10
- package/src/renderer/shared/components/ui/error-recovery.tsx +1 -1
- package/src/renderer/shared/components/{ArtifactPreviewPanel.tsx → workspace/ArtifactPreviewPanel.tsx} +374 -118
- package/src/renderer/shared/components/workspace/BackgroundTerminals.test.tsx +63 -0
- package/src/renderer/shared/components/{BackgroundTerminals.tsx → workspace/BackgroundTerminals.tsx} +40 -9
- package/src/renderer/shared/components/workspace/CodeReviewPage.test.tsx +50 -0
- package/src/renderer/shared/components/{CodeReviewPage.tsx → workspace/CodeReviewPage.tsx} +124 -24
- package/src/renderer/shared/components/{GitBranchSelector.tsx → workspace/GitBranchSelector.tsx} +80 -24
- package/src/renderer/shared/components/workspace/SessionSources.tsx +113 -0
- package/src/renderer/shared/components/{TerminalDock.tsx → workspace/TerminalDock.tsx} +5 -2
- package/src/renderer/shared/components/workspace/ToolSurfacePage.test.tsx +81 -0
- package/src/renderer/shared/components/{ToolSurfacePage.tsx → workspace/ToolSurfacePage.tsx} +361 -90
- package/src/renderer/shared/components/{ToolsPanelToggle.tsx → workspace/ToolsPanelToggle.tsx} +1 -1
- package/src/renderer/shared/components/workspace/WorkspaceFileInfo.tsx +28 -0
- package/src/renderer/shared/components/workspace/WorkspaceMediaPreview.tsx +17 -0
- package/src/renderer/shared/components/{WorkspacePaneResizer.tsx → workspace/WorkspacePaneResizer.tsx} +1 -1
- package/src/renderer/shared/components/workspace/WorkspacePdfPreview.tsx +308 -0
- package/src/renderer/shared/components/workspace/WorkspacePreviewActions.test.tsx +101 -0
- package/src/renderer/shared/components/{WorkspacePreviewActions.tsx → workspace/WorkspacePreviewActions.tsx} +3 -3
- package/src/renderer/shared/components/{WorkspaceSelector.tsx → workspace/WorkspaceSelector.tsx} +99 -7
- package/src/renderer/shared/components/{background-terminals.css → workspace/background-terminals.css} +11 -11
- package/src/renderer/shared/components/{workspace-selector.css → workspace/workspace-selector.css} +84 -2
- package/src/renderer/shared/constants/config.ts +6 -3
- package/src/renderer/shared/constants/models.test.ts +51 -0
- package/src/renderer/shared/constants/models.ts +139 -32
- package/src/renderer/shared/conversation/coordinator.test.ts +46 -0
- package/src/renderer/shared/conversation/coordinator.ts +50 -2
- package/src/renderer/shared/conversation/lifecycle.test.ts +254 -4
- package/src/renderer/shared/conversation/lifecycle.ts +268 -12
- package/src/renderer/shared/conversation/progressiveStream.test.ts +83 -0
- package/src/renderer/shared/conversation/progressiveStream.ts +219 -0
- package/src/renderer/shared/conversation/projectNavigation.test.ts +18 -0
- package/src/renderer/shared/conversation/projectNavigation.ts +11 -0
- package/src/renderer/shared/conversation/transport.test.ts +20 -0
- package/src/renderer/shared/conversation/transport.ts +51 -9
- package/src/renderer/shared/conversation/useConversationCoordinator.ts +42 -12
- package/src/renderer/shared/css/agent-observability.css +205 -11
- package/src/renderer/shared/css/chat-ui-cards.css +48 -48
- package/src/renderer/shared/css/code-review.css +139 -110
- package/src/renderer/shared/css/code-sessions.css +56 -27
- package/src/renderer/shared/css/collapsed-paste.css +1 -1
- package/src/renderer/shared/css/error-notice.css +1 -1
- package/src/renderer/shared/css/file-changes.css +298 -51
- package/src/renderer/shared/css/library.css +105 -10
- package/src/renderer/shared/css/management-views.css +79 -38
- package/src/renderer/shared/css/mcp-results.css +48 -5
- package/src/renderer/shared/css/model-selector.css +18 -18
- package/src/renderer/shared/css/mods.css +7 -7
- package/src/renderer/shared/css/notification-notice.css +2 -2
- package/src/renderer/shared/css/queued-messages.css +221 -0
- package/src/renderer/shared/css/session-sources.css +12 -7
- package/src/renderer/shared/css/settings/agents.css +2 -2
- package/src/renderer/{src → shared}/css/settings/base.css +101 -107
- package/src/renderer/shared/css/settings/general.css +397 -100
- package/src/renderer/shared/css/settings/plugins.css +8 -8
- package/src/renderer/shared/css/settings/profile.css +5 -5
- package/src/renderer/shared/css/settings/theme.css +49 -37
- package/src/renderer/shared/css/slash-choice.css +2 -2
- package/src/renderer/shared/css/slash-suggestions.css +3 -3
- package/src/renderer/shared/css/sources-block.css +41 -2
- package/src/renderer/shared/css/tools-panel.css +2 -2
- package/src/renderer/shared/css/ui-tailwind.css +10 -2
- package/src/renderer/shared/css/veo-studio.css +2 -2
- package/src/renderer/shared/css/viewed-images.css +93 -4
- package/src/renderer/shared/css/workspace-file-info.css +12 -0
- package/src/renderer/shared/css/workspace-media-preview.css +13 -0
- package/src/renderer/shared/env.d.ts +9 -0
- package/src/renderer/shared/platform.test.ts +143 -0
- package/src/renderer/shared/platform.ts +12 -5
- package/src/renderer/shared/speech/player.ts +160 -0
- package/src/renderer/shared/speech/types.ts +11 -0
- package/src/renderer/shared/theme/themeManager.test.ts +37 -0
- package/src/renderer/shared/theme/themeManager.ts +24 -5
- package/src/renderer/shared/theme/themes.ts +71 -4
- package/src/renderer/shared/theme/tokens.css +452 -53
- package/src/renderer/shared/types.ts +57 -2
- package/src/renderer/shared/utils/agentActivity.test.ts +633 -8
- package/src/renderer/shared/utils/agentActivity.ts +776 -59
- package/src/renderer/shared/utils/artifactBrowser.test.ts +37 -32
- package/src/renderer/shared/utils/artifactBrowser.ts +18 -20
- package/src/renderer/shared/utils/artifacts.ts +55 -0
- package/src/renderer/shared/utils/attachedDocument.test.ts +73 -0
- package/src/renderer/shared/utils/attachedDocument.ts +49 -0
- package/src/renderer/shared/utils/contextCompaction.test.tsx +1 -1
- package/src/renderer/shared/utils/externalLinks.ts +91 -0
- package/src/renderer/shared/utils/fileIcons.test.ts +59 -0
- package/src/renderer/shared/utils/fileIcons.ts +149 -16
- package/src/renderer/shared/utils/lazyWithRetry.ts +13 -0
- package/src/renderer/shared/utils/markdown.tsx +238 -51
- package/src/renderer/shared/utils/markdown.webImages.test.tsx +140 -2
- package/src/renderer/shared/utils/mcpResults.test.tsx +53 -1
- package/src/renderer/shared/utils/pdfRange.ts +16 -0
- package/src/renderer/shared/utils/previewObjectUrls.ts +20 -0
- package/src/renderer/shared/utils/sessionSources.test.ts +41 -1
- package/src/renderer/shared/utils/sessionSources.ts +2 -0
- package/src/renderer/shared/utils/slashCommandProcessor.ts +7 -1
- package/src/renderer/shared/utils/speech.ts +18 -4
- package/src/renderer/shared/utils/syntaxHighlight.test.tsx +11 -1
- package/src/renderer/shared/utils/syntaxHighlight.tsx +51 -3
- package/src/renderer/shared/utils/useGeminiLiveVoice.ts +324 -51
- package/src/renderer/shared/utils/useNativeVoiceInput.ts +19 -5
- package/src/renderer/shared/utils/useSessionSources.ts +4 -0
- package/src/renderer/shared/utils/viewedImages.test.ts +129 -0
- package/src/renderer/shared/utils/viewedImages.ts +81 -10
- package/src/renderer/shared/utils/workspaceDrag.test.ts +153 -0
- package/src/renderer/shared/utils/workspaceDrag.ts +172 -0
- package/src/renderer/shared/utils/workspaceImage.ts +17 -0
- package/src/renderer/shared/utils/workspaceListPreferences.test.ts +64 -0
- package/src/renderer/shared/utils/workspaceListPreferences.ts +54 -0
- package/src/renderer/shared/utils/workspaceMedia.ts +49 -0
- package/src/renderer/shared/utils/workspacePreview.test.ts +147 -2
- package/src/renderer/shared/utils/workspacePreview.ts +34 -3
- package/src/renderer/shared/utils/workspaces.ts +3 -2
- package/src/renderer/src/App.tsx +20 -16
- package/src/renderer/src/agentProgress.ts +1 -0
- package/src/renderer/src/components/ChatPanel.tsx +1 -1
- package/src/renderer/src/components/DashboardSidebar.tsx +2 -2
- package/src/renderer/src/components/ImageStudioPanel.tsx +1 -1
- package/src/renderer/src/components/LiveTranslateControls.tsx +1 -1
- package/src/renderer/src/components/MintDashboard.tsx +1 -1
- package/src/renderer/src/components/ProactiveGlow.tsx +1 -1
- package/src/renderer/src/components/ScreenPicker.css +1 -1
- package/src/renderer/src/components/ScreenPicker.tsx +1 -1
- package/src/renderer/src/components/SettingsWindow.tsx +6 -830
- package/src/renderer/src/components/SpotlightWindow.tsx +4 -32
- package/src/renderer/src/components/VeoStudioPanel.tsx +1 -1
- package/src/renderer/src/components/WorkspacePanel.tsx +49 -15
- package/src/renderer/src/components/browser-suggestions-popup.css +8 -8
- package/src/renderer/src/css/app-shell.css +26 -106
- package/src/renderer/src/css/chat.css +1499 -292
- package/src/renderer/src/css/desktop-tools.css +17 -348
- package/src/renderer/src/css/sidebar-workspace.css +22 -2
- package/src/renderer/src/css/spotlight.css +2 -2
- package/src/renderer/src/css/tool-surfaces.css +335 -65
- package/src/renderer/src/css/widget.css +6 -5
- package/src/renderer/src/env.d.ts +13 -0
- package/src/renderer/src/index.css +53 -83
- package/src/renderer/src/tauri.ts +99 -13
- package/src/renderer/src/voiceInput.ts +3 -1
- package/src/renderer/src-web/App.tsx +20 -8
- package/src/renderer/src-web/agentProgress.ts +1 -0
- package/src/renderer/src-web/components/ChatPanel.tsx +1 -1
- package/src/renderer/src-web/components/DashboardSidebar.tsx +2 -2
- package/src/renderer/src-web/components/ImageStudioPanel.tsx +1 -1
- package/src/renderer/src-web/components/MintDashboard.tsx +1 -1
- package/src/renderer/src-web/components/SettingsWindow.tsx +6 -851
- package/src/renderer/src-web/components/VeoStudioPanel.tsx +1 -1
- package/src/renderer/src-web/css/app-shell.css +20 -104
- package/src/renderer/src-web/css/chat.css +1536 -261
- package/src/renderer/src-web/css/mobile.css +29 -13
- package/src/renderer/src-web/css/settings/mobile.css +2 -2
- package/src/renderer/src-web/css/sidebar-workspace.css +21 -1
- package/src/renderer/src-web/env.d.ts +14 -0
- package/src/renderer/src-web/index.css +53 -83
- package/src/renderer/src-web/tauri.ts +93 -15
- package/src/renderer/tests/browserArtifacts.browser.html +1 -0
- package/src/renderer/tests/browserArtifacts.browser.tsx +68 -0
- package/src/renderer/tests/chatEscape.browser.html +1 -0
- package/src/renderer/tests/chatEscape.browser.tsx +25 -0
- package/src/renderer/tests/chatPerformance.browser.html +1 -1
- package/src/renderer/tests/collapsedPaste.browser.html +1 -1
- package/src/renderer/tests/composerMenus.browser.html +3 -3
- package/src/renderer/tests/contextCompaction.browser.html +1 -1
- package/src/renderer/tests/errorRecovery.browser.html +1 -1
- package/src/renderer/tests/fixtures/preview.webm +0 -0
- package/src/renderer/tests/glideSelect.browser.html +1 -2
- package/src/renderer/tests/glideSelect.preview.html +1 -1
- package/src/renderer/tests/library.browser.tsx +4 -1
- package/src/renderer/tests/liveOrb.browser.html +1 -1
- package/src/renderer/tests/liveVoice.browser.html +1 -0
- package/src/renderer/tests/mediaFixtures.ts +32 -0
- package/src/renderer/tests/modInput.browser.html +1 -1
- package/src/renderer/tests/sessionSources.browser.tsx +76 -15
- package/src/renderer/tests/toolsPanel.browser.tsx +5 -5
- package/src/renderer/tests/viewedImages.browser.tsx +3 -3
- package/src/renderer/tests/voiceDictation.browser.html +101 -0
- package/src/renderer/tests/voicePill.browser.html +3 -3
- package/src/renderer/tests/voicePill.preview.html +1 -1
- package/src/renderer/tests/webSources.browser.tsx +2 -98
- package/src/renderer/tests/workspaceDrop.browser.html +1 -0
- package/src/renderer/tests/workspaceDrop.browser.tsx +183 -0
- package/src/renderer/tests/workspaceExpansion.browser.html +1 -0
- package/src/renderer/tests/workspaceExpansion.browser.tsx +66 -0
- package/src/renderer/tests/workspaceRemoval.browser.html +66 -0
- package/src/renderer/tests/workspaceUndo.browser.html +10 -2
- package/src-tauri/src/app/lifecycle.rs +45 -15
- package/src-tauri/src/background/headless.rs +14 -8
- package/src-tauri/src/commands/conversation.rs +137 -73
- package/src-tauri/src/commands/integrations.rs +7 -1
- package/src-tauri/src/commands/media.rs +7 -0
- package/src-tauri/src/commands/workspace.rs +38 -0
- package/src-tauri/src/native/mod.rs +0 -1
- package/src-tauri/src/native/system.rs +4 -47
- package/tsconfig.json +15 -1
- package/vite.config.ts +2 -1
- package/vite.config.web.ts +2 -0
- package/crates/mint-cli/src/interactive/chat_tui.rs +0 -7853
- package/crates/mint-core/src/agent/chat.rs +0 -4155
- package/crates/mint-core/src/browser/lifecycle.rs +0 -191
- package/crates/mint-core/src/browser/logging.rs +0 -20
- package/crates/mint-core/src/orchestration/tools/browser.rs +0 -31
- package/out/web/assets/CliSessionsView-CtzUJpK_.css +0 -1
- package/out/web/assets/CliSessionsView-D7hw0Mgj.js +0 -1
- package/out/web/assets/CodeReviewPage-C7bEOJfd.js +0 -4
- package/out/web/assets/CodeReviewPage-Dte9uLiL.css +0 -1
- package/out/web/assets/CommandPalette-0RrF-AOT.js +0 -1
- package/out/web/assets/ImageStudioPanel-CdxkAf_r.js +0 -1
- package/out/web/assets/LibraryPage--Qfisp6D.js +0 -2
- package/out/web/assets/LibraryPage-DAxUTAg7.css +0 -1
- package/out/web/assets/LinkedFoldersView-2nfZbDgN.js +0 -1
- package/out/web/assets/McpRegistryPicker-h9uS8_wT.js +0 -1
- package/out/web/assets/McpServersView-slfQJzNB.js +0 -1
- package/out/web/assets/MintDashboard-BSR5XpXh.js +0 -25
- package/out/web/assets/MintDashboard-CWUcCGhd.css +0 -1
- package/out/web/assets/PluginsView-l7LSm503.js +0 -1
- package/out/web/assets/ScheduledTasksView-CttmLbq1.js +0 -1
- package/out/web/assets/SettingsWindow-BCMLYvEV.js +0 -4
- package/out/web/assets/SettingsWindow-DcMVmU9u.css +0 -1
- package/out/web/assets/SkillsView-rNs1qr_U.js +0 -2
- package/out/web/assets/ToolSurfacePage-B9DzEPWN.js +0 -37
- package/out/web/assets/ToolSurfacePage-CTfgggF2.css +0 -1
- package/out/web/assets/VeoStudioPanel-DiJs_Cg2.js +0 -4
- package/out/web/assets/WorkspacePanel-CbJ1PFoZ.js +0 -1
- package/out/web/assets/WorkspaceSelector-B2xIp04D.js +0 -1
- package/out/web/assets/WorkspaceSelector-Ca8uJOsS.css +0 -1
- package/out/web/assets/abnfDiagram-VCTEODGH-CD0CjoGl.js +0 -1
- package/out/web/assets/architecture-7GRP2DOG-RKV83OeZ.js +0 -1
- package/out/web/assets/architectureDiagram-5GKGNRK7-nN_HAFct.js +0 -36
- package/out/web/assets/c4Diagram-UCG6FXSJ-DTdV8_zE.js +0 -38
- package/out/web/assets/chunk-2Q5K7J3B-Dmqrq8Tp.js +0 -1
- package/out/web/assets/chunk-75Z2AOVW-_M0z5olV.js +0 -2
- package/out/web/assets/chunk-CKBBP62Z-BpQEgeHF.js +0 -2
- package/out/web/assets/chunk-CLGD4ZFX-D54yGvGS.js +0 -1
- package/out/web/assets/chunk-CacB07dV.js +0 -1
- package/out/web/assets/chunk-DSNCTWBM-C-gvT2ru.js +0 -2
- package/out/web/assets/chunk-DU6HZSFF-CnFngIhW.js +0 -128
- package/out/web/assets/chunk-F27PBJKO-BqtWrnEO.js +0 -1
- package/out/web/assets/chunk-FOHPRMQF-BaVC1uA7.js +0 -161
- package/out/web/assets/chunk-G27WJ6UU-Ckoq5mi2.js +0 -231
- package/out/web/assets/chunk-JQ64N6SF-CF8T7GiZ.js +0 -1
- package/out/web/assets/chunk-JWPE2WC7-BwtYOHqU.js +0 -1
- package/out/web/assets/chunk-LNGE3PJU-AdBoOWw2.js +0 -34
- package/out/web/assets/chunk-OBVCFTLP-CRIkunUB.js +0 -1
- package/out/web/assets/chunk-P2QGCYS3-UFEU6BxZ.js +0 -1
- package/out/web/assets/chunk-POPQ4Y6H-CQcrNbjr.js +0 -1
- package/out/web/assets/chunk-PWAF6VOD-Cc2uVDsG.js +0 -1
- package/out/web/assets/chunk-R7TYR2AO-DiCxzdAY.js +0 -10
- package/out/web/assets/chunk-RHFEMEQ7-b7hnPmrR.js +0 -168
- package/out/web/assets/chunk-XXDRQBXY-DnJkbUaw.js +0 -1
- package/out/web/assets/chunk-Y2CYZVJY-C9o-s6OY.js +0 -1
- package/out/web/assets/classDiagram-DTDB5LWJ-RnC2mYO4.js +0 -1
- package/out/web/assets/classDiagram-v2-JRS7N3AN-RnC2mYO4.js +0 -1
- package/out/web/assets/config-CnvCChUM.js +0 -2
- package/out/web/assets/config-DM6oIVO3.css +0 -1
- package/out/web/assets/core-DsKkQ7ig.js +0 -1
- package/out/web/assets/cose-bilkent-JH36ORCC--UN4aw5-.js +0 -1
- package/out/web/assets/cynefin-OW5HDTMX-CnzQfOGp.js +0 -1
- package/out/web/assets/cynefinDiagram-5FMLGOSQ-DVtQnfpm.js +0 -62
- package/out/web/assets/cytoscape.esm-Df1UN4Y1.js +0 -321
- package/out/web/assets/dagre-3AP2YEHR-DG76_k5_.js +0 -4
- package/out/web/assets/dagre-BWadQu2F.js +0 -1
- package/out/web/assets/diagram-S7CK7UJ4-CaouUoze.js +0 -30
- package/out/web/assets/diagram-UQ7AKVKN-B4bEc26B.js +0 -41
- package/out/web/assets/diagram-VX7I27RA-7hH5IPYf.js +0 -24
- package/out/web/assets/diagram-Z3DM3KII-CCM4clo8.js +0 -24
- package/out/web/assets/dist-BoTOASLF.js +0 -1
- package/out/web/assets/dist-js-BkYNznHX.js +0 -1
- package/out/web/assets/ebnfDiagram-PWID7BFC-Da7WAM3k.js +0 -1
- package/out/web/assets/event-Cdt7Byyj.js +0 -1
- package/out/web/assets/eventmodeling-NTZA5JFV-xcfsA0XD.js +0 -1
- package/out/web/assets/flowDiagram-A5DVABFB-JdtH1673.js +0 -1
- package/out/web/assets/ganttDiagram-EL5Y4UJY-B3ClFGmL.js +0 -292
- package/out/web/assets/gitGraph-4MIJSDKK-BZ_y_cDU.js +0 -1
- package/out/web/assets/gitGraphDiagram-WWUBYQGX-drhRSYm3.js +0 -106
- package/out/web/assets/graphlib-CTR5ZhLf.js +0 -1
- package/out/web/assets/index-BZ9xgmMP.css +0 -1
- package/out/web/assets/index-Ca8cCS4h.js +0 -168
- package/out/web/assets/info-A6RAGUB7-B7I3K0F1.js +0 -1
- package/out/web/assets/infoDiagram-RXCK75RN-deX_1MPh.js +0 -2
- package/out/web/assets/journeyDiagram-EYS64GPL-CZn2kB8b.js +0 -139
- package/out/web/assets/jsx-runtime-DN4NhQUK.js +0 -1
- package/out/web/assets/katex-O3jvqgnU.js +0 -257
- package/out/web/assets/markdown-CMhYIcWB.js +0 -39
- package/out/web/assets/mermaid-parser.core-Whu2rlJC.js +0 -7
- package/out/web/assets/mermaid.core-CKyPo8VH.js +0 -11
- package/out/web/assets/modelManager-CUaGWMWu.js +0 -2
- package/out/web/assets/oauthManager-DlNhXJr6.js +0 -1
- package/out/web/assets/packet-AYTQ26CC-CEeIRKRG.js +0 -1
- package/out/web/assets/pegDiagram-XKGWAZYB-BYadI-KO.js +0 -1
- package/out/web/assets/pie-WAS4IAKB-D8uf4dh5.js +0 -1
- package/out/web/assets/pieDiagram-E7YTZNPT-CjSDy4hO.js +0 -39
- package/out/web/assets/radar-RG4KPBEZ-DZJxnokY.js +0 -1
- package/out/web/assets/railroad-74A4TZTK-DBysUiUi.js +0 -1
- package/out/web/assets/railroad-abnf-HS5TGJTU-CHWxoJYg.js +0 -1
- package/out/web/assets/railroad-ebnf-LZEXJU2U-DDv7X6bY.js +0 -1
- package/out/web/assets/railroad-peg-WCYAUIDC-DpfcYYNJ.js +0 -1
- package/out/web/assets/railroadDiagram-O6MQD6OU-CYtyv0t3.js +0 -1
- package/out/web/assets/rough.esm-DFbTUy8a.js +0 -1
- package/out/web/assets/sankeyDiagram-P5KCCOFB-Bn2x6C4Y.js +0 -40
- package/out/web/assets/sequenceDiagram-WJ2MYXX4-BvFLKtPd.js +0 -162
- package/out/web/assets/sizeCapture-X5ZJPWSS-DKeOCaN2.js +0 -1
- package/out/web/assets/src-DnfeXQPr.js +0 -1
- package/out/web/assets/stateDiagram-HBIQ2CUA-Bx0GWeaY.js +0 -1
- package/out/web/assets/stateDiagram-v2-4QOOHH4V--hol1yg_.js +0 -1
- package/out/web/assets/studio-B1mk40wD.js +0 -1
- package/out/web/assets/swimlanes-XN3QIQJK-CCma0T7L.js +0 -1
- package/out/web/assets/swimlanesDiagram-VK2B7HYN-BkohoVsU.js +0 -8
- package/out/web/assets/timeline-definition-24CTP7MA-iCRhhJ7C.js +0 -120
- package/out/web/assets/treeView-Q6P3EWNA-DZ-y08qp.js +0 -1
- package/out/web/assets/treemap-WGGIJYW6-De0CxzMx.js +0 -1
- package/out/web/assets/vennDiagram-4TSXK5OY-w_7aZ6xe.js +0 -34
- package/out/web/assets/wardley-WFR3VGLG-DT0y0xJ4.js +0 -1
- package/out/web/assets/window-BJCVtyET.js +0 -1
- package/shared-modules/libsecret/libsecret.json +0 -23
- package/shared-modules/libusb/libusb.json +0 -27
- package/shared-modules/lzo/lzo.json +0 -27
- package/src/renderer/shared/components/AgentActivityDrawer.tsx +0 -204
- package/src/renderer/shared/components/AgentActivityTable.tsx +0 -301
- package/src/renderer/shared/components/ChatMessageItem.test.tsx +0 -68
- package/src/renderer/shared/components/ChatMessageItem.tsx +0 -326
- package/src/renderer/shared/components/ChatPanel.test.tsx +0 -21
- package/src/renderer/shared/components/FormattedMessage.tsx +0 -11
- package/src/renderer/shared/components/GeminiLiveOverlay.test.tsx +0 -24
- package/src/renderer/shared/components/GlideSelect.d.ts +0 -31
- package/src/renderer/shared/components/GlideSelect.jsx +0 -266
- package/src/renderer/shared/components/InlineThoughtNote.tsx +0 -27
- package/src/renderer/shared/components/ModSessionControls.tsx +0 -8
- package/src/renderer/shared/components/ModUi.tsx +0 -26
- package/src/renderer/shared/components/ProgressActivity.tsx +0 -17
- package/src/renderer/shared/components/ReviewHistory.tsx +0 -42
- package/src/renderer/shared/components/RunSummaryDashboard.tsx +0 -143
- package/src/renderer/shared/components/SelectField.tsx +0 -38
- package/src/renderer/shared/components/SessionSources.tsx +0 -48
- package/src/renderer/shared/components/SessionSourcesPopover.tsx +0 -61
- package/src/renderer/shared/components/ToolSurfacePage.test.tsx +0 -32
- package/src/renderer/shared/components/ViewedImages.tsx +0 -36
- package/src/renderer/shared/components/WorkspaceContextPopover.tsx +0 -138
- package/src/renderer/shared/components/WorkspacePreviewActions.test.tsx +0 -44
- package/src/renderer/shared/components/ui/demo.tsx +0 -26
- package/src/renderer/shared/css/session-sources-popover.css +0 -9
- package/src/renderer/src/components/BrowserShell.tsx +0 -108
- package/src/renderer/src/components/BrowserSuggestionsPopup.tsx +0 -91
- package/src/renderer/src/components/CalculationCard.tsx +0 -3
- package/src/renderer/src/components/ImageGenCard.tsx +0 -2
- package/src/renderer/src/components/ImageSearchCard.tsx +0 -2
- package/src/renderer/src/components/MermaidCard.tsx +0 -1
- package/src/renderer/src/components/PicturesLibrary.tsx +0 -2
- package/src/renderer/src/components/Settings/AgentsTab.tsx +0 -4
- package/src/renderer/src/components/Settings/AudioTab.tsx +0 -3
- package/src/renderer/src/components/Settings/AutomationTab.tsx +0 -3
- package/src/renderer/src/components/Settings/GeneralTab.tsx +0 -3
- package/src/renderer/src/components/Settings/MemoryTab.tsx +0 -3
- package/src/renderer/src/components/Settings/PluginsTab.tsx +0 -3
- package/src/renderer/src/components/Settings/ProfileTab.tsx +0 -3
- package/src/renderer/src/components/Settings/ShortcutsTab.tsx +0 -3
- package/src/renderer/src/components/Settings/ThemeTab.tsx +0 -3
- package/src/renderer/src/components/StockCard.tsx +0 -3
- package/src/renderer/src/components/WeatherCard.tsx +0 -3
- package/src/renderer/src/components/browser-shell.css +0 -185
- package/src/renderer/src/css/pictures.css +0 -2
- package/src/renderer/src-web/components/PicturesLibrary.tsx +0 -2
- package/src/renderer/src-web/components/Settings/AgentsTab.tsx +0 -4
- package/src/renderer/src-web/components/Settings/AudioTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/AutomationTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/GeneralTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/MemoryTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/PluginsTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/ProfileTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/ShortcutsTab.tsx +0 -3
- package/src/renderer/src-web/components/Settings/ThemeTab.tsx +0 -3
- package/src/renderer/src-web/css/pictures.css +0 -2
- package/src/renderer/src-web/css/settings/base.css +0 -1266
- package/src/renderer/src-web/css/spotlight.css +0 -102
- package/src/renderer/src-web/css/widget.css +0 -213
- package/src-tauri/src/native/browser.rs +0 -252
- /package/src/renderer/shared/components/{ContextCompactionStatus.tsx → chat/ContextCompactionStatus.tsx} +0 -0
- /package/src/renderer/shared/components/{GeminiLiveOverlay.css → chat/GeminiLiveOverlay.css} +0 -0
- /package/src/renderer/shared/components/{VirtualChatHistory.tsx → chat/VirtualChatHistory.tsx} +0 -0
- /package/src/renderer/shared/components/{VoicePill.d.ts → chat/VoicePill.d.ts} +0 -0
- /package/src/renderer/shared/components/{VoicePill.test.tsx → chat/VoicePill.test.tsx} +0 -0
- /package/src/renderer/shared/components/{ScreenCaptureDialog.css → studio/ScreenCaptureDialog.css} +0 -0
- /package/src/renderer/shared/components/{ScreenCaptureDialog.tsx → studio/ScreenCaptureDialog.tsx} +0 -0
- /package/src/renderer/shared/components/{SelectField.test.tsx → ui/SelectField.test.tsx} +0 -0
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import { SpeechPlayer } from '../../speech/player'
|
|
2
|
+
import McpToolResults from '../activity/McpToolResults'
|
|
3
|
+
import ViewedImages from '../activity/ViewedImages'
|
|
3
4
|
import { CollapsiblePasteInput } from './CollapsiblePasteInput'
|
|
4
5
|
import { ContextCompactionStatus } from './ContextCompactionStatus'
|
|
5
|
-
import { activeCompactionFrom } from '
|
|
6
|
-
import { useEffect, useMemo, useRef, useState, useCallback, Fragment, type ChangeEvent, type ClipboardEvent, type DragEvent, type FormEvent, type KeyboardEvent, type RefObject } from 'react'
|
|
7
|
-
import { EMPTY_AGENT_PROGRESS, hasAgentToolActivity, thoughtsFrom, extendedThoughtsFrom, mergeFileChanges, parseFileChangesFromProgress } from '
|
|
8
|
-
import { visibleInteractionsDuringRun } from '
|
|
6
|
+
import { activeCompactionFrom } from '../../utils/contextCompaction'
|
|
7
|
+
import { useEffect, useMemo, useRef, useState, useCallback, Fragment, lazy, Suspense, useSyncExternalStore, type ChangeEvent, type ClipboardEvent, type DragEvent, type FormEvent, type KeyboardEvent, type RefObject } from 'react'
|
|
8
|
+
import { EMPTY_AGENT_PROGRESS, hasAgentToolActivity, thoughtsFrom, extendedThoughtsFrom, mergeFileChanges, parseFileChangesFromProgress } from '../../agentProgress'
|
|
9
|
+
import { visibleInteractionsDuringRun } from '../../conversation/syncView'
|
|
9
10
|
import {
|
|
10
11
|
GEMINI_MODELS,
|
|
11
12
|
OPENAI_MODELS,
|
|
@@ -16,44 +17,70 @@ import {
|
|
|
16
17
|
LOCAL_MODELS,
|
|
17
18
|
OLLAMA_MODELS,
|
|
18
19
|
GEMINI_LIVE_VOICES,
|
|
19
|
-
} from '
|
|
20
|
-
import { badge, providerLabel, fallbackNotice } from '
|
|
21
|
-
import { parseWebSearchSources } from '
|
|
22
|
-
import { useLatestCallback } from '
|
|
20
|
+
} from '../../constants/models'
|
|
21
|
+
import { badge, providerLabel, fallbackNotice } from '../../utils/providers'
|
|
22
|
+
import { parseWebSearchSources } from '../../utils/agentActivity'
|
|
23
|
+
import { useLatestCallback } from '../../utils/useLatestCallback'
|
|
23
24
|
import SlashChoicePanel from './SlashChoicePanel'
|
|
24
25
|
import SlashSuggestions, { type SlashSuggestionsHandle } from './SlashSuggestions'
|
|
25
26
|
import { ChatCodeBlock } from './ChatCodeBlock'
|
|
26
|
-
import { renderApprovalDetails, renderDiff, type ApprovalDetails } from '
|
|
27
|
+
import { renderApprovalDetails, renderDiff, type ApprovalDetails } from '../../utils/approval'
|
|
27
28
|
import { ApprovalCard } from './ApprovalCard'
|
|
28
|
-
import {
|
|
29
|
+
import { FormattedMessage, readableAssistantText, renderSpeakerIcon, renderCopyIcon } from '../../utils/markdown'
|
|
29
30
|
import { ThinkingBlock } from './ThinkingBlock'
|
|
30
31
|
import ChatMessageItem from './ChatMessageItem'
|
|
31
|
-
import
|
|
32
|
-
import {
|
|
32
|
+
import ProviderBrandIcon from '../ui/ProviderBrandIcon'
|
|
33
|
+
import { AgentActivityDrawer } from '../activity/AgentActivityDrawer'
|
|
34
|
+
import { TurnFileChanges, type RewindRequestPayload } from './TurnFileChanges'
|
|
35
|
+
import { SubagentStatusStrip } from '../activity/SubagentStatusStrip'
|
|
33
36
|
import { VirtualChatHistory, type VirtualChatHistoryHandle } from './VirtualChatHistory'
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import
|
|
37
|
-
import { numericSetting, shouldShowSessionDivider, formatSessionDividerLabel } from '../utils/ui'
|
|
37
|
+
import type { ArtifactFile } from '../../utils/artifacts'
|
|
38
|
+
import type { AgentProgress, ChatResponse, DiffHunk, FileChange, GitCheckpoint, QueuedPrompt, RuntimeStatus } from '../../types'
|
|
39
|
+
import { shouldShowSessionDivider, formatSessionDividerLabel, createTrimmedImagePreview } from '../../utils/ui'
|
|
38
40
|
import { useVoiceInput } from '@/voiceInput'
|
|
39
41
|
import VoicePill from './VoicePill'
|
|
40
|
-
import { useGeminiLiveVoice } from '
|
|
42
|
+
import { useGeminiLiveVoice } from '../../utils/useGeminiLiveVoice'
|
|
41
43
|
import GeminiLiveOverlay from './GeminiLiveOverlay'
|
|
42
|
-
import { isSupportedDocument, SUPPORTED_DOCUMENT_ACCEPT } from '
|
|
44
|
+
import { isSupportedDocument, SUPPORTED_DOCUMENT_ACCEPT } from '../../utils/documentTypes'
|
|
43
45
|
import ModelSelectorPopover from './ModelSelectorPopover'
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import { ModsPanel } from '
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import '
|
|
52
|
-
import '
|
|
46
|
+
import ChatModeSelector from './ChatModeSelector'
|
|
47
|
+
import GitBranchSelector from '../workspace/GitBranchSelector'
|
|
48
|
+
import WorkspaceSelector from '../workspace/WorkspaceSelector'
|
|
49
|
+
import ToolsPanelToggle from '../workspace/ToolsPanelToggle'
|
|
50
|
+
import { ModsPanel } from '../extensions/ModsPanel'
|
|
51
|
+
import type { ToolSurface } from '../workspace/ToolSurfacePage'
|
|
52
|
+
import { WORKSPACE_PATH_MIME, WORKSPACE_FILE_MIME, WORKSPACE_IMAGE_MIME, isImageFileName, resolveImageToDataUri, formatWorkspaceReference } from '../../utils/workspaceDrag'
|
|
53
|
+
import QueuedMessagesBanner from './QueuedMessagesBanner'
|
|
54
|
+
import '../../css/thinking-status.css'
|
|
55
|
+
import '../../css/slash-choice.css'
|
|
56
|
+
|
|
57
|
+
import { catalogPlatform, conversationPlatform, runtimePlatform } from '../../platform'
|
|
58
|
+
|
|
59
|
+
const ArtifactPreviewPanel = lazy(() => import('../workspace/ArtifactPreviewPanel').then(m => ({ default: m.ArtifactPreviewPanel })))
|
|
60
|
+
const RewindModal = lazy(() => import('./RewindModal').then(m => ({ default: m.RewindModal })))
|
|
61
|
+
const CodeReviewPage = lazy(() => import('../workspace/CodeReviewPage'))
|
|
62
|
+
|
|
63
|
+
export function shouldProbeOllamaModels(status?: RuntimeStatus | null, settingsConfig?: any): boolean {
|
|
64
|
+
return status?.activeProvider === 'ollama' || Boolean(settingsConfig?.ollamaHost || settingsConfig?.ollamaModel)
|
|
65
|
+
}
|
|
53
66
|
|
|
54
|
-
|
|
67
|
+
export function ThinkingElapsedMeta() {
|
|
68
|
+
const [elapsedSeconds, setElapsedSeconds] = useState(0)
|
|
69
|
+
useEffect(() => {
|
|
70
|
+
const startTime = Date.now()
|
|
71
|
+
const timer = setInterval(() => {
|
|
72
|
+
setElapsedSeconds(Math.round((Date.now() - startTime) / 1000))
|
|
73
|
+
}, 1000)
|
|
74
|
+
return () => clearInterval(timer)
|
|
75
|
+
}, [])
|
|
76
|
+
return (
|
|
77
|
+
<span className="thinking-status-meta">
|
|
78
|
+
{` · ${elapsedSeconds}s · Esc to cancel`}
|
|
79
|
+
</span>
|
|
80
|
+
)
|
|
81
|
+
}
|
|
55
82
|
|
|
56
|
-
const STREAM_MARKDOWN_UPDATE_MS =
|
|
83
|
+
const STREAM_MARKDOWN_UPDATE_MS = 32
|
|
57
84
|
|
|
58
85
|
function useThrottledValue<T>(value: T, intervalMs: number): T {
|
|
59
86
|
const [throttledValue, setThrottledValue] = useState(value)
|
|
@@ -83,7 +110,7 @@ function useThrottledValue<T>(value: T, intervalMs: number): T {
|
|
|
83
110
|
}
|
|
84
111
|
|
|
85
112
|
const {
|
|
86
|
-
|
|
113
|
+
speechRequest, startGeminiLiveSession, sendGeminiLiveAudioChunk, stopGeminiLiveSession,
|
|
87
114
|
listGitCheckpoints, rollbackGitCheckpoint, undoGitCheckpoint,
|
|
88
115
|
} = conversationPlatform
|
|
89
116
|
const { fetchProviderModels } = catalogPlatform
|
|
@@ -118,11 +145,14 @@ interface ChatPanelContract {
|
|
|
118
145
|
chatId: string
|
|
119
146
|
chatEnd: RefObject<HTMLDivElement | null>
|
|
120
147
|
welcomeInteraction: any
|
|
148
|
+
queuedPrompts?: QueuedPrompt[]
|
|
149
|
+
queuePaused?: boolean
|
|
121
150
|
onSubmit: (event: FormEvent<HTMLFormElement>) => void
|
|
122
151
|
onSelectImage: (event: ChangeEvent<HTMLInputElement>) => void
|
|
123
152
|
onSelectVideo: (event: ChangeEvent<HTMLInputElement>) => void
|
|
124
153
|
onSelectDocument: (event: ChangeEvent<HTMLInputElement>) => void
|
|
125
154
|
onPasteImage: (clipboardData: DataTransfer) => boolean
|
|
155
|
+
onAttachImage?: (image: { dataUri: string; previewDataUri?: string; objectUrl?: string; name: string }) => void
|
|
126
156
|
onSetMessage: (message: string) => void
|
|
127
157
|
onSendVoiceMessage: (message: string, audioDataUri?: string | null) => Promise<void>
|
|
128
158
|
onRemoveImage: (idx: number) => void
|
|
@@ -157,6 +187,16 @@ interface ChatPanelContract {
|
|
|
157
187
|
onOpenReview?: (review: Extract<ToolSurface, { kind: 'review' }>) => void
|
|
158
188
|
onSelectSlashChoice?: (value: string) => void
|
|
159
189
|
onDismissSlashChoice?: () => void
|
|
190
|
+
subscribeMessage?: (notify: () => void) => () => void
|
|
191
|
+
getMessage?: () => string
|
|
192
|
+
onRemoveQueuedPrompt?: (id: string) => void
|
|
193
|
+
onEditQueuedPrompt?: (id: string) => void
|
|
194
|
+
onClearQueuedPrompts?: () => void
|
|
195
|
+
onSteerQueuedPrompt?: (id: string) => void
|
|
196
|
+
onResumeQueue?: () => void
|
|
197
|
+
onResendFrom?: (fromId: number, newPrompt: string) => Promise<void> | void
|
|
198
|
+
onSyncHistory?: () => void
|
|
199
|
+
onReceiveApproval?: (approval: { token: string; approval: Record<string, unknown> }) => void
|
|
160
200
|
}
|
|
161
201
|
|
|
162
202
|
export type ConversationViewModel = Pick<ChatPanelContract,
|
|
@@ -168,13 +208,32 @@ export type ConversationViewModel = Pick<ChatPanelContract,
|
|
|
168
208
|
| 'conversationTitle' | 'slashChoice'
|
|
169
209
|
| 'hasOlder'
|
|
170
210
|
| 'sendingInteractionId'
|
|
211
|
+
| 'queuedPrompts'
|
|
212
|
+
| 'queuePaused'
|
|
171
213
|
>
|
|
172
|
-
export type ConversationActions = Omit<ChatPanelContract, keyof ConversationViewModel>
|
|
214
|
+
export type ConversationActions = Omit<ChatPanelContract, keyof ConversationViewModel> & {
|
|
215
|
+
subscribeMessage?: (notify: () => void) => () => void
|
|
216
|
+
getMessage?: () => string
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
const NOOP_SUBSCRIBE = () => () => {}
|
|
220
|
+
|
|
221
|
+
export function useComposerDraft(
|
|
222
|
+
fallbackMessage: string,
|
|
223
|
+
subscribe?: (notify: () => void) => () => void,
|
|
224
|
+
getMessage?: () => string,
|
|
225
|
+
): string {
|
|
226
|
+
const getSnapshot = () => (getMessage ? getMessage() : fallbackMessage)
|
|
227
|
+
return useSyncExternalStore(
|
|
228
|
+
subscribe ?? NOOP_SUBSCRIBE,
|
|
229
|
+
getSnapshot,
|
|
230
|
+
getSnapshot,
|
|
231
|
+
)
|
|
232
|
+
}
|
|
173
233
|
|
|
174
234
|
interface ChatPanelProps {
|
|
175
235
|
conversation: ConversationViewModel
|
|
176
236
|
actions: ConversationActions
|
|
177
|
-
showSessionSources?: boolean
|
|
178
237
|
tools?: { modsPanelTarget: HTMLElement | null; onOpenMods: () => void; onToggle?: () => void; open: boolean; backgroundTaskCount: number }
|
|
179
238
|
}
|
|
180
239
|
|
|
@@ -182,7 +241,6 @@ export default function ChatPanel({
|
|
|
182
241
|
conversation,
|
|
183
242
|
actions,
|
|
184
243
|
tools,
|
|
185
|
-
showSessionSources = false,
|
|
186
244
|
}: ChatPanelProps) {
|
|
187
245
|
const {
|
|
188
246
|
interactions,
|
|
@@ -199,7 +257,7 @@ export default function ChatPanel({
|
|
|
199
257
|
agentActivitySnapshots,
|
|
200
258
|
thinkingExpanded,
|
|
201
259
|
onThinkingExpandedChange: handleThinkingExpandedChange,
|
|
202
|
-
message,
|
|
260
|
+
message: initialMessage,
|
|
203
261
|
imageAttachments,
|
|
204
262
|
videoAttachments,
|
|
205
263
|
documentName,
|
|
@@ -217,6 +275,7 @@ export default function ChatPanel({
|
|
|
217
275
|
onSelectVideo,
|
|
218
276
|
onSelectDocument,
|
|
219
277
|
onPasteImage,
|
|
278
|
+
onAttachImage,
|
|
220
279
|
onSetMessage,
|
|
221
280
|
onSendVoiceMessage,
|
|
222
281
|
onRemoveImage,
|
|
@@ -247,7 +306,18 @@ export default function ChatPanel({
|
|
|
247
306
|
onOpenReview,
|
|
248
307
|
onSelectSlashChoice,
|
|
249
308
|
onDismissSlashChoice,
|
|
309
|
+
queuedPrompts = [],
|
|
310
|
+
queuePaused = false,
|
|
311
|
+
onRemoveQueuedPrompt,
|
|
312
|
+
onEditQueuedPrompt,
|
|
313
|
+
onClearQueuedPrompts,
|
|
314
|
+
onSteerQueuedPrompt,
|
|
315
|
+
onResumeQueue,
|
|
316
|
+
onResendFrom,
|
|
317
|
+
onSyncHistory,
|
|
318
|
+
onReceiveApproval,
|
|
250
319
|
} = { ...conversation, ...actions }
|
|
320
|
+
const message = useComposerDraft(initialMessage, actions.subscribeMessage, actions.getMessage)
|
|
251
321
|
const onThinkingExpandedChange = useLatestCallback(handleThinkingExpandedChange)
|
|
252
322
|
// The initiating surface already renders a live prompt/reply pair below.
|
|
253
323
|
// Hide its matching persisted turn until the local stream settles, while
|
|
@@ -306,14 +376,9 @@ export default function ChatPanel({
|
|
|
306
376
|
activeModelName = (lastThinkingProgress.data as any).model_name || null
|
|
307
377
|
}
|
|
308
378
|
const [openActivityIds, setOpenActivityIds] = useState<Record<string, boolean>>({})
|
|
309
|
-
const [openReviewIds, setOpenReviewIds] = useState<Record<string, boolean>>({})
|
|
310
|
-
const [openFileDiffs, setOpenFileDiffs] = useState<Record<string, boolean>>({})
|
|
311
|
-
const [showAllFileChanges, setShowAllFileChanges] = useState<Record<string, boolean>>({})
|
|
312
379
|
const [reviewPage, setReviewPage] = useState<{ title: string; changes: FileChange[] } | null>(null)
|
|
313
380
|
const [activeArtifact, setActiveArtifact] = useState<ArtifactFile | null>(null)
|
|
314
381
|
const [toolMenuOpen, setToolMenuOpen] = useState(false)
|
|
315
|
-
const [sessionSourcesOpen, setSessionSourcesOpen] = useState(false)
|
|
316
|
-
const [elapsedSeconds, setElapsedSeconds] = useState(0)
|
|
317
382
|
const [dynamicOllamaModels, setDynamicOllamaModels] = useState<string[]>(OLLAMA_MODELS)
|
|
318
383
|
const toggleActivity = useCallback((id: string) => {
|
|
319
384
|
setOpenActivityIds(current => ({ ...current, [id]: !(current[id] ?? (id === 'live')) }))
|
|
@@ -325,11 +390,20 @@ export default function ChatPanel({
|
|
|
325
390
|
})
|
|
326
391
|
|
|
327
392
|
const openReview = useLatestCallback((title: string, changes: FileChange[]) => {
|
|
328
|
-
if (onOpenReview)
|
|
329
|
-
|
|
393
|
+
if (onOpenReview) {
|
|
394
|
+
setReviewPage(null)
|
|
395
|
+
onOpenReview({ id: `review:${Date.now()}`, kind: 'review', title: 'Review', reviewTitle: title, changes })
|
|
396
|
+
} else {
|
|
397
|
+
setReviewPage({ title, changes })
|
|
398
|
+
}
|
|
399
|
+
})
|
|
400
|
+
|
|
401
|
+
const openAllConversationReview = useLatestCallback(() => {
|
|
402
|
+
openReview('All conversation changes', getConversationChanges())
|
|
330
403
|
})
|
|
331
404
|
|
|
332
405
|
useEffect(() => {
|
|
406
|
+
if (!shouldProbeOllamaModels(status, settingsConfig)) return
|
|
333
407
|
let cancelled = false
|
|
334
408
|
const fetchOllamaModels = async () => {
|
|
335
409
|
const host = settingsConfig?.ollamaHost || 'http://localhost:11434'
|
|
@@ -372,24 +446,8 @@ export default function ChatPanel({
|
|
|
372
446
|
return () => {
|
|
373
447
|
cancelled = true
|
|
374
448
|
}
|
|
375
|
-
}, [settingsConfig?.ollamaHost, settingsConfig?.ollamaModel])
|
|
376
|
-
|
|
377
|
-
useEffect(() => {
|
|
378
|
-
if (!sending) {
|
|
379
|
-
setElapsedSeconds(0)
|
|
380
|
-
return
|
|
381
|
-
}
|
|
382
|
-
|
|
383
|
-
const startTime = Date.now()
|
|
384
|
-
setElapsedSeconds(0)
|
|
385
|
-
|
|
386
|
-
const timer = setInterval(() => {
|
|
387
|
-
const elapsed = Math.round((Date.now() - startTime) / 1000)
|
|
388
|
-
setElapsedSeconds(elapsed)
|
|
389
|
-
}, 1000)
|
|
390
|
-
|
|
391
|
-
return () => clearInterval(timer)
|
|
392
|
-
}, [sending])
|
|
449
|
+
}, [status?.activeProvider, settingsConfig?.ollamaHost, settingsConfig?.ollamaModel])
|
|
450
|
+
const [speechError, setSpeechError] = useState('')
|
|
393
451
|
const [speakingText, setSpeakingText] = useState<string | null>(null)
|
|
394
452
|
const [copiedId, setCopiedId] = useState<string | number | null>(null)
|
|
395
453
|
|
|
@@ -637,8 +695,6 @@ export default function ChatPanel({
|
|
|
637
695
|
|
|
638
696
|
|
|
639
697
|
const toolMenuRef = useRef<HTMLDivElement | null>(null)
|
|
640
|
-
const audioRef = useRef<HTMLAudioElement | null>(null)
|
|
641
|
-
const speechRunRef = useRef(0)
|
|
642
698
|
const historyReadyRef = useRef(false)
|
|
643
699
|
const submittedDuringSessionRef = useRef(false)
|
|
644
700
|
const lastAutoSpokenIdRef = useRef<number | string | null>(null)
|
|
@@ -649,6 +705,36 @@ export default function ChatPanel({
|
|
|
649
705
|
const dragCounter = useRef(0)
|
|
650
706
|
const lastDropTimeRef = useRef(0)
|
|
651
707
|
|
|
708
|
+
const resizeInput = useCallback((element: HTMLTextAreaElement) => {
|
|
709
|
+
element.style.height = 'auto'
|
|
710
|
+
element.style.height = `${Math.min(element.scrollHeight, 120)}px`
|
|
711
|
+
}, [])
|
|
712
|
+
|
|
713
|
+
// Direct file reference insertion into chat input
|
|
714
|
+
const handleReferenceFile = useCallback((rawPath: string) => {
|
|
715
|
+
const formatted = formatWorkspaceReference(rawPath, workspacePath).trim()
|
|
716
|
+
if (!formatted) return
|
|
717
|
+
const token = `${formatted} `
|
|
718
|
+
const textarea = textareaRef.current
|
|
719
|
+
if (!textarea) {
|
|
720
|
+
onSetMessage(message.trim() ? `${message.trimEnd()} ${token}` : token)
|
|
721
|
+
return
|
|
722
|
+
}
|
|
723
|
+
const start = textarea.selectionStart ?? message.length
|
|
724
|
+
const end = textarea.selectionEnd ?? message.length
|
|
725
|
+
const before = message.slice(0, start)
|
|
726
|
+
const after = message.slice(end)
|
|
727
|
+
const spacingBefore = before && !before.endsWith(' ') && !before.endsWith('\n') ? ' ' : ''
|
|
728
|
+
const updated = `${before}${spacingBefore}${token}${after}`
|
|
729
|
+
onSetMessage(updated)
|
|
730
|
+
const nextCursor = (before + spacingBefore + token).length
|
|
731
|
+
requestAnimationFrame(() => {
|
|
732
|
+
textarea.focus()
|
|
733
|
+
textarea.setSelectionRange(nextCursor, nextCursor)
|
|
734
|
+
resizeInput(textarea)
|
|
735
|
+
})
|
|
736
|
+
}, [message, onSetMessage, workspacePath, resizeInput])
|
|
737
|
+
|
|
652
738
|
const handleDragEnter = (e: DragEvent<HTMLElement>) => {
|
|
653
739
|
e.preventDefault()
|
|
654
740
|
if (e.dataTransfer?.types?.includes('Files')) {
|
|
@@ -669,6 +755,14 @@ export default function ChatPanel({
|
|
|
669
755
|
|
|
670
756
|
const handleDragOver = (e: DragEvent<HTMLElement>) => {
|
|
671
757
|
e.preventDefault()
|
|
758
|
+
if (
|
|
759
|
+
e.dataTransfer?.types?.includes(WORKSPACE_PATH_MIME) ||
|
|
760
|
+
e.dataTransfer?.types?.includes(WORKSPACE_FILE_MIME) ||
|
|
761
|
+
e.dataTransfer?.types?.includes(WORKSPACE_IMAGE_MIME) ||
|
|
762
|
+
e.dataTransfer?.types?.includes('application/x-mint-workspace-path')
|
|
763
|
+
) {
|
|
764
|
+
e.dataTransfer.dropEffect = 'copy'
|
|
765
|
+
}
|
|
672
766
|
}
|
|
673
767
|
|
|
674
768
|
const handleDrop = (e: DragEvent<HTMLElement>) => {
|
|
@@ -677,6 +771,27 @@ export default function ChatPanel({
|
|
|
677
771
|
dragCounter.current = 0
|
|
678
772
|
setIsDragging(false)
|
|
679
773
|
|
|
774
|
+
const wsPath =
|
|
775
|
+
e.dataTransfer?.getData(WORKSPACE_IMAGE_MIME) ||
|
|
776
|
+
e.dataTransfer?.getData(WORKSPACE_PATH_MIME) ||
|
|
777
|
+
e.dataTransfer?.getData('application/x-mint-workspace-path')
|
|
778
|
+
const plainRef = e.dataTransfer?.getData('text/plain')?.trim() || ''
|
|
779
|
+
const fileRef =
|
|
780
|
+
e.dataTransfer?.getData(WORKSPACE_PATH_MIME) ||
|
|
781
|
+
e.dataTransfer?.getData('application/x-mint-workspace-path') ||
|
|
782
|
+
(plainRef.startsWith('@') ? plainRef : '')
|
|
783
|
+
if (wsPath || fileRef) {
|
|
784
|
+
void tryAttachDroppedImage(e.dataTransfer).then((attached) => {
|
|
785
|
+
if (!attached) {
|
|
786
|
+
const raw = fileRef || wsPath
|
|
787
|
+
if (raw) {
|
|
788
|
+
handleReferenceFile(raw)
|
|
789
|
+
}
|
|
790
|
+
}
|
|
791
|
+
})
|
|
792
|
+
return
|
|
793
|
+
}
|
|
794
|
+
|
|
680
795
|
const now = Date.now()
|
|
681
796
|
if (now - lastDropTimeRef.current < 250) {
|
|
682
797
|
return
|
|
@@ -718,9 +833,8 @@ export default function ChatPanel({
|
|
|
718
833
|
}
|
|
719
834
|
|
|
720
835
|
|
|
721
|
-
// The mic button
|
|
722
|
-
//
|
|
723
|
-
// same button.
|
|
836
|
+
// The mic button dictates into the composer (native capture on Desktop,
|
|
837
|
+
// browser speech recognition on Web). Gemini Live has its own button and overlay.
|
|
724
838
|
const {
|
|
725
839
|
isRecording,
|
|
726
840
|
voiceMode,
|
|
@@ -736,6 +850,7 @@ export default function ChatPanel({
|
|
|
736
850
|
scheduleVoiceListen,
|
|
737
851
|
clearRestartTimer
|
|
738
852
|
} = useVoiceInput({
|
|
853
|
+
chatId,
|
|
739
854
|
onSendVoiceMessage,
|
|
740
855
|
language: settingsConfig?.language,
|
|
741
856
|
message,
|
|
@@ -750,9 +865,31 @@ export default function ChatPanel({
|
|
|
750
865
|
chatId,
|
|
751
866
|
startSession: startGeminiLiveSession,
|
|
752
867
|
sendAudioChunk: sendGeminiLiveAudioChunk,
|
|
753
|
-
stopSession: stopGeminiLiveSession
|
|
868
|
+
stopSession: stopGeminiLiveSession,
|
|
869
|
+
onTurnSaved: () => {
|
|
870
|
+
onSyncHistory?.()
|
|
871
|
+
},
|
|
872
|
+
onToolActivity: () => {
|
|
873
|
+
onWorkspaceChanged?.()
|
|
874
|
+
},
|
|
875
|
+
onApprovalRequested: (approval) => {
|
|
876
|
+
onReceiveApproval?.(approval)
|
|
877
|
+
},
|
|
754
878
|
})
|
|
755
879
|
|
|
880
|
+
useEffect(() => {
|
|
881
|
+
const onTriggerVoice = () => {
|
|
882
|
+
if (geminiLiveEnabled) {
|
|
883
|
+
geminiLive.setVoiceMode(true)
|
|
884
|
+
} else {
|
|
885
|
+
setVoiceMode(true)
|
|
886
|
+
void startRecognition()
|
|
887
|
+
}
|
|
888
|
+
}
|
|
889
|
+
window.addEventListener('mint:trigger-voice', onTriggerVoice)
|
|
890
|
+
return () => window.removeEventListener('mint:trigger-voice', onTriggerVoice)
|
|
891
|
+
}, [geminiLiveEnabled, geminiLive, setVoiceMode, startRecognition])
|
|
892
|
+
|
|
756
893
|
const canSubmit = Boolean(message.trim() || imageAttachments.length > 0 || videoAttachments.length > 0 || documentName)
|
|
757
894
|
const sendingImageMarkers = Array.from({ length: sendingImageCount }, (_, index) => `[Image #${index + 1}]`).join(' ')
|
|
758
895
|
const sendingVideoMarkers = Array.from({ length: sendingVideoCount || 0 }, (_, index) => `[Video #${index + 1}]`).join(' ')
|
|
@@ -944,94 +1081,29 @@ export default function ChatPanel({
|
|
|
944
1081
|
submitOnEnter(event)
|
|
945
1082
|
}
|
|
946
1083
|
|
|
947
|
-
const
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
speakingRef.current = null
|
|
952
|
-
if (
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
}
|
|
962
|
-
const hasThai = /[\u0e00-\u0e7f]/.test(text)
|
|
963
|
-
const utterance = new SpeechSynthesisUtterance(text)
|
|
964
|
-
utterance.lang = hasThai ? 'th-TH' : 'en-US'
|
|
965
|
-
utterance.volume = Math.max(0, Math.min(1, numericSetting(settingsConfig?.ttsVolume, 1)))
|
|
966
|
-
utterance.rate = Math.max(0.1, Math.min(10, numericSetting(settingsConfig?.ttsSpeed, 1)))
|
|
967
|
-
utterance.pitch = Math.max(0, Math.min(2, numericSetting(settingsConfig?.ttsPitch, 1)))
|
|
968
|
-
const voice = window.speechSynthesis.getVoices().find((item) => {
|
|
969
|
-
const lang = item.lang.toLowerCase()
|
|
970
|
-
const target = hasThai ? 'th' : 'en'
|
|
971
|
-
return lang.startsWith(target) || lang.includes(target)
|
|
972
|
-
})
|
|
973
|
-
if (voice) utterance.voice = voice
|
|
974
|
-
const finishSpeech = () => {
|
|
975
|
-
setSpeakingText((current) => (current === displayText ? null : current))
|
|
976
|
-
speakingRef.current = null
|
|
977
|
-
scheduleVoiceListen(900)
|
|
978
|
-
}
|
|
979
|
-
utterance.onend = finishSpeech
|
|
980
|
-
utterance.onerror = finishSpeech
|
|
981
|
-
speakingRef.current = displayText
|
|
982
|
-
setSpeakingText(displayText)
|
|
983
|
-
window.speechSynthesis.speak(utterance)
|
|
984
|
-
}
|
|
985
|
-
const playGoogleTts = async (text: string, displayText: string, runId: number) => {
|
|
986
|
-
const chunks = await getTtsUrls(text)
|
|
987
|
-
for (const chunk of chunks) {
|
|
988
|
-
if (speechRunRef.current !== runId) return
|
|
989
|
-
await new Promise<void>((resolve, reject) => {
|
|
990
|
-
const audio = new Audio(chunk.url)
|
|
991
|
-
audio.volume = Math.max(0, Math.min(1, numericSetting(settingsConfig?.ttsVolume, 1)))
|
|
992
|
-
audio.playbackRate = Math.max(0.25, Math.min(4, numericSetting(settingsConfig?.ttsSpeed, 1)))
|
|
993
|
-
audioRef.current = audio
|
|
994
|
-
audio.onended = () => resolve()
|
|
995
|
-
audio.onpause = () => resolve()
|
|
996
|
-
audio.onerror = () => reject(new Error('Google TTS playback failed'))
|
|
997
|
-
audio.play().catch(reject)
|
|
998
|
-
})
|
|
999
|
-
}
|
|
1000
|
-
if (speechRunRef.current === runId) {
|
|
1001
|
-
setSpeakingText((current) => (current === displayText ? null : current))
|
|
1002
|
-
speakingRef.current = null
|
|
1003
|
-
scheduleVoiceListen(900)
|
|
1004
|
-
}
|
|
1005
|
-
}
|
|
1006
|
-
const speak = useLatestCallback((text: string) => {
|
|
1007
|
-
const speechText = cleanSpeechText(text)
|
|
1008
|
-
if (!speechText) return
|
|
1009
|
-
if (speakingText === text) {
|
|
1010
|
-
cancelSpeech()
|
|
1011
|
-
return
|
|
1012
|
-
}
|
|
1013
|
-
|
|
1014
|
-
cancelSpeech()
|
|
1015
|
-
const runId = speechRunRef.current
|
|
1016
|
-
speakingRef.current = text
|
|
1017
|
-
setSpeakingText(text)
|
|
1018
|
-
if (settingsConfig?.ttsProvider === 'google') {
|
|
1019
|
-
playGoogleTts(speechText, text, runId).catch((error) => {
|
|
1020
|
-
console.warn('Google TTS failed, falling back to native speech synthesis:', error)
|
|
1021
|
-
if (speechRunRef.current === runId) speakNative(speechText, text)
|
|
1022
|
-
})
|
|
1023
|
-
return
|
|
1024
|
-
}
|
|
1025
|
-
speakNative(speechText, text)
|
|
1084
|
+
const speechPlayerRef = useRef<SpeechPlayer | null>(null)
|
|
1085
|
+
const speechTextRef = useRef<string | null>(null)
|
|
1086
|
+
if (!speechPlayerRef.current) speechPlayerRef.current = new SpeechPlayer(speechRequest, state => {
|
|
1087
|
+
setSpeakingText(state === 'idle' ? null : speechTextRef.current)
|
|
1088
|
+
speakingRef.current = state === 'idle' ? null : speechTextRef.current
|
|
1089
|
+
if (state === 'idle') scheduleVoiceListen(900)
|
|
1090
|
+
}, message => setSpeechError(message))
|
|
1091
|
+
const cancelSpeech = () => { void speechPlayerRef.current?.stop() }
|
|
1092
|
+
const speak = useLatestCallback((text: string, turnId?: number, automatic = false) => {
|
|
1093
|
+
if (!automatic && speakingText === text) { cancelSpeech(); return }
|
|
1094
|
+
setSpeechError('')
|
|
1095
|
+
speechTextRef.current = text
|
|
1096
|
+
const saved = turnId ?? Number([...interactions].reverse().find(interaction => interaction.aiText === text)?.id)
|
|
1097
|
+
void speechPlayerRef.current?.play({ chatId, text, turnId: Number.isFinite(saved) && saved > 0 ? saved : undefined, automatic })
|
|
1026
1098
|
})
|
|
1099
|
+
useEffect(() => { cancelSpeech() }, [chatId, sending])
|
|
1100
|
+
useEffect(() => {
|
|
1101
|
+
historyReadyRef.current = false; submittedDuringSessionRef.current = false; lastAutoSpokenIdRef.current = null
|
|
1102
|
+
}, [chatId])
|
|
1027
1103
|
|
|
1028
|
-
const resizeInput = (element: HTMLTextAreaElement) => {
|
|
1029
|
-
element.style.height = 'auto'
|
|
1030
|
-
element.style.height = `${Math.min(element.scrollHeight, 120)}px`
|
|
1031
|
-
}
|
|
1032
1104
|
useEffect(() => {
|
|
1033
1105
|
return () => {
|
|
1034
|
-
|
|
1106
|
+
void speechPlayerRef.current?.dispose()
|
|
1035
1107
|
}
|
|
1036
1108
|
}, [])
|
|
1037
1109
|
useEffect(() => {
|
|
@@ -1061,7 +1133,7 @@ export default function ChatPanel({
|
|
|
1061
1133
|
}
|
|
1062
1134
|
|
|
1063
1135
|
lastAutoSpokenIdRef.current = latest.id
|
|
1064
|
-
speak(latest.aiText)
|
|
1136
|
+
speak(latest.aiText, Number(latest.id), true)
|
|
1065
1137
|
}, [interactions, sending, settingsConfig?.enableVoiceReply, geminiLive.voiceMode, voiceMode])
|
|
1066
1138
|
useEffect(() => {
|
|
1067
1139
|
if (!toolMenuOpen) return
|
|
@@ -1085,13 +1157,14 @@ export default function ChatPanel({
|
|
|
1085
1157
|
}, [onPasteImage])
|
|
1086
1158
|
useEffect(() => {
|
|
1087
1159
|
const handleEscapeKeyDown = (event: globalThis.KeyboardEvent) => {
|
|
1088
|
-
|
|
1160
|
+
const insideTools = event.target instanceof Element && event.target.closest('.tool-surface-page')
|
|
1161
|
+
if (event.key === 'Escape' && sending && !event.defaultPrevented && !insideTools) {
|
|
1089
1162
|
onCancelMessage()
|
|
1090
1163
|
}
|
|
1091
1164
|
}
|
|
1092
1165
|
window.addEventListener('keydown', handleEscapeKeyDown, true)
|
|
1093
1166
|
return () => window.removeEventListener('keydown', handleEscapeKeyDown, true)
|
|
1094
|
-
}, [sending, onCancelMessage
|
|
1167
|
+
}, [sending, onCancelMessage])
|
|
1095
1168
|
useEffect(() => {
|
|
1096
1169
|
if (message) return
|
|
1097
1170
|
const input = document.getElementById('chat-input') as HTMLTextAreaElement | null
|
|
@@ -1131,305 +1204,100 @@ export default function ChatPanel({
|
|
|
1131
1204
|
if (!trimmed) return
|
|
1132
1205
|
onSetMessage(message.trim() ? `${message.trimEnd()} ${trimmed} ` : `${trimmed} `)
|
|
1133
1206
|
}
|
|
1134
|
-
const handleWorkspaceDrop = (event: DragEvent<HTMLElement>) => {
|
|
1135
|
-
const reference =
|
|
1136
|
-
event.dataTransfer.getData('application/x-mint-workspace-path') ||
|
|
1137
|
-
event.dataTransfer.getData('text/plain')
|
|
1138
|
-
if (!reference.trim().startsWith('@')) return
|
|
1139
|
-
event.preventDefault()
|
|
1140
|
-
appendWorkspaceReference(reference)
|
|
1141
|
-
}
|
|
1142
|
-
const isEmptyChat = interactions.length === 0 && !sending && !pendingApproval
|
|
1143
|
-
const renderChangesList = (changes: ReturnType<typeof parseFileChangesFromProgress>, idPrefix: string) => {
|
|
1144
|
-
const showAll = Boolean(showAllFileChanges[idPrefix])
|
|
1145
|
-
const visibleChanges = showAll ? changes : changes.slice(0, 3)
|
|
1146
|
-
return (
|
|
1147
|
-
<div className="file-changes-list" style={{ display: 'flex', flexDirection: 'column', gap: '6px' }}>
|
|
1148
|
-
{visibleChanges.map((change) => {
|
|
1149
|
-
const fileKey = `${idPrefix}-${change.path}`
|
|
1150
|
-
const isDiffOpen = Boolean(openFileDiffs[fileKey])
|
|
1151
|
-
const fileName = change.path.split('/').pop() || change.path
|
|
1152
|
-
const dirPath = change.path.includes('/') ? change.path.substring(0, change.path.lastIndexOf('/')) : ''
|
|
1153
|
-
|
|
1154
|
-
return (
|
|
1155
|
-
<div key={change.path} className="file-changes-item">
|
|
1156
|
-
<div
|
|
1157
|
-
className="file-changes-item-header"
|
|
1158
|
-
onClick={() => setOpenFileDiffs((current) => ({ ...current, [fileKey]: !current[fileKey] }))}
|
|
1159
|
-
>
|
|
1160
|
-
<div style={{ display: 'flex', alignItems: 'center', gap: '8px' }}>
|
|
1161
|
-
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" style={{ color: 'var(--text-muted)' }}>
|
|
1162
|
-
<path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z" />
|
|
1163
|
-
<polyline points="14 2 14 8 20 8" />
|
|
1164
|
-
</svg>
|
|
1165
|
-
<span className={`file-changes-filename ${change.created ? 'is-new' : ''}`}>
|
|
1166
|
-
{fileName}
|
|
1167
|
-
{dirPath && <span className="file-changes-dirpath">{dirPath}</span>}
|
|
1168
|
-
{change.created && (
|
|
1169
|
-
<span className="file-changes-badge-new">
|
|
1170
|
-
[NEW FILE]
|
|
1171
|
-
</span>
|
|
1172
|
-
)}
|
|
1173
|
-
</span>
|
|
1174
|
-
</div>
|
|
1175
|
-
<div style={{ display: 'flex', alignItems: 'center', gap: '6px', fontSize: '0.76rem' }}>
|
|
1176
|
-
{change.created ? (
|
|
1177
|
-
<span className="file-changes-count-add">
|
|
1178
|
-
+{change.additions} {change.additions === 1 ? 'line' : 'lines'}
|
|
1179
|
-
</span>
|
|
1180
|
-
) : (
|
|
1181
|
-
<>
|
|
1182
|
-
{change.additions > 0 && <span className="file-changes-count-add">+{change.additions}</span>}
|
|
1183
|
-
{change.deletions > 0 && <span className="file-changes-count-del">-{change.deletions}</span>}
|
|
1184
|
-
</>
|
|
1185
|
-
)}
|
|
1186
|
-
<button
|
|
1187
|
-
type="button"
|
|
1188
|
-
className="file-changes-preview-btn"
|
|
1189
|
-
onClick={(e) => {
|
|
1190
|
-
e.stopPropagation()
|
|
1191
|
-
const fallbackContent =
|
|
1192
|
-
change.created && change.hunks.length > 0
|
|
1193
|
-
? change.hunks.map((h) => h.newText).filter(Boolean).join('\n')
|
|
1194
|
-
: undefined
|
|
1195
|
-
openArtifact({ path: change.path, content: fallbackContent })
|
|
1196
|
-
}}
|
|
1197
|
-
title="Open Live Preview Split View"
|
|
1198
|
-
>
|
|
1199
|
-
Preview
|
|
1200
|
-
</button>
|
|
1201
|
-
<span style={{ color: 'var(--text-muted)', transform: isDiffOpen ? 'rotate(90deg)' : 'none', display: 'inline-block', transition: 'transform 0.15s' }}>></span>
|
|
1202
|
-
</div>
|
|
1203
|
-
</div>
|
|
1204
|
-
|
|
1205
|
-
{isDiffOpen && (
|
|
1206
|
-
<div className="file-changes-diff-box">
|
|
1207
|
-
{change.hunks.map((hunk, hIdx) => (
|
|
1208
|
-
<div key={hIdx} className="file-changes-diff-hunk" style={{ marginBottom: hIdx < change.hunks.length - 1 ? '10px' : 0 }}>
|
|
1209
|
-
{hunk.oldText && (
|
|
1210
|
-
<div className="file-changes-diff-del">
|
|
1211
|
-
{hunk.oldText.split('\n').map((line, lIdx) => (
|
|
1212
|
-
<div key={lIdx} style={{ display: 'flex' }}>
|
|
1213
|
-
<span className="file-changes-diff-sign-del">-</span>
|
|
1214
|
-
<span>{line}</span>
|
|
1215
|
-
</div>
|
|
1216
|
-
))}
|
|
1217
|
-
</div>
|
|
1218
|
-
)}
|
|
1219
|
-
{hunk.newText && (
|
|
1220
|
-
<div className="file-changes-diff-add">
|
|
1221
|
-
{hunk.newText.split('\n').map((line, lIdx) => (
|
|
1222
|
-
<div key={lIdx} style={{ display: 'flex' }}>
|
|
1223
|
-
<span className="file-changes-diff-sign-add">+</span>
|
|
1224
|
-
<span>{line}</span>
|
|
1225
|
-
</div>
|
|
1226
|
-
))}
|
|
1227
|
-
</div>
|
|
1228
|
-
)}
|
|
1229
|
-
</div>
|
|
1230
|
-
))}
|
|
1231
|
-
</div>
|
|
1232
|
-
)}
|
|
1233
|
-
</div>
|
|
1234
|
-
)
|
|
1235
|
-
})}
|
|
1236
|
-
{changes.length > 3 && (
|
|
1237
|
-
<button
|
|
1238
|
-
type="button"
|
|
1239
|
-
className="file-changes-show-more"
|
|
1240
|
-
aria-expanded={showAll}
|
|
1241
|
-
onClick={() => setShowAllFileChanges((current) => ({ ...current, [idPrefix]: !current[idPrefix] }))}
|
|
1242
|
-
>
|
|
1243
|
-
{showAll ? 'Show fewer files' : `Show ${changes.length - 3} more ${changes.length - 3 === 1 ? 'file' : 'files'}`}
|
|
1244
|
-
<span aria-hidden="true" className={showAll ? 'is-expanded' : ''}>⌄</span>
|
|
1245
|
-
</button>
|
|
1246
|
-
)}
|
|
1247
|
-
</div>
|
|
1248
|
-
)
|
|
1249
|
-
}
|
|
1250
1207
|
|
|
1251
|
-
const
|
|
1252
|
-
|
|
1253
|
-
const progress = agentActivitySnapshots[interactionId] ?? interaction.agentActivity ?? EMPTY_AGENT_PROGRESS
|
|
1254
|
-
const changes = parseFileChangesFromProgress(progress)
|
|
1255
|
-
if (changes.length === 0) return null
|
|
1256
|
-
|
|
1257
|
-
const totalAdditions = changes.reduce((sum, c) => sum + c.additions, 0)
|
|
1258
|
-
const totalDeletions = changes.reduce((sum, c) => sum + c.deletions, 0)
|
|
1259
|
-
const createdCount = changes.filter((c) => c.created).length
|
|
1260
|
-
const modifiedCount = changes.length - createdCount
|
|
1261
|
-
const isOpen = openReviewIds[interactionId] ?? true
|
|
1262
|
-
|
|
1263
|
-
let summaryLabel = ''
|
|
1264
|
-
if (createdCount > 0 && modifiedCount === 0) {
|
|
1265
|
-
summaryLabel = `${createdCount} ${createdCount === 1 ? 'file created' : 'files created'}`
|
|
1266
|
-
} else if (createdCount > 0 && modifiedCount > 0) {
|
|
1267
|
-
summaryLabel = `${createdCount} created, ${modifiedCount} modified`
|
|
1268
|
-
} else {
|
|
1269
|
-
summaryLabel = `${changes.length} ${changes.length === 1 ? 'file changed' : 'files changed'}`
|
|
1270
|
-
}
|
|
1208
|
+
const tryAttachDroppedImage = async (dataTransfer: DataTransfer): Promise<boolean> => {
|
|
1209
|
+
if (!onAttachImage) return false
|
|
1271
1210
|
|
|
1272
|
-
const
|
|
1273
|
-
|
|
1274
|
-
|
|
1211
|
+
const rawImage = dataTransfer.getData(WORKSPACE_IMAGE_MIME)
|
|
1212
|
+
let imagePayload: { path?: string; root?: string; url?: string; name?: string } | null = null
|
|
1213
|
+
if (rawImage) {
|
|
1275
1214
|
try {
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
visible: true,
|
|
1280
|
-
message: 'No git checkpoints recorded for this session.',
|
|
1281
|
-
canUndo: false,
|
|
1282
|
-
isUndoing: false,
|
|
1283
|
-
type: 'error',
|
|
1284
|
-
})
|
|
1285
|
-
return
|
|
1286
|
-
}
|
|
1287
|
-
|
|
1288
|
-
// Targeted Step Checkpoint resolution:
|
|
1289
|
-
// Match checkpoints against files touched in this specific interaction
|
|
1290
|
-
const changePaths = new Set(changes.map((c) => c.path.trim().toLowerCase()))
|
|
1291
|
-
const matching = checkpoints.filter((cp) => {
|
|
1292
|
-
if (!cp.targetPath) return false
|
|
1293
|
-
const cpPath = cp.targetPath.trim().toLowerCase()
|
|
1294
|
-
return changePaths.has(cpPath) || Array.from(changePaths).some((p) => cpPath.endsWith(p) || p.endsWith(cpPath))
|
|
1295
|
-
})
|
|
1296
|
-
|
|
1297
|
-
let targetCp: GitCheckpoint | null = null
|
|
1298
|
-
if (matching.length > 0) {
|
|
1299
|
-
// Earliest matching checkpoint represents the state immediately before this turn's modifications
|
|
1300
|
-
targetCp = matching.reduce((earliest, curr) => (curr.step < earliest.step ? curr : earliest), matching[0])
|
|
1301
|
-
} else {
|
|
1302
|
-
// If no direct target path, try matching by timestamp
|
|
1303
|
-
const interactionTs = interaction.createdAt ? new Date(interaction.createdAt).getTime() / 1000 : 0
|
|
1304
|
-
if (interactionTs > 0) {
|
|
1305
|
-
const afterCreated = checkpoints.filter((cp) => cp.timestamp >= interactionTs - 10)
|
|
1306
|
-
if (afterCreated.length > 0) {
|
|
1307
|
-
targetCp = afterCreated[0]
|
|
1308
|
-
}
|
|
1309
|
-
}
|
|
1310
|
-
if (!targetCp) {
|
|
1311
|
-
targetCp = checkpoints[checkpoints.length - 1]
|
|
1312
|
-
}
|
|
1313
|
-
}
|
|
1314
|
-
|
|
1315
|
-
setRewindModalState({
|
|
1316
|
-
isOpen: true,
|
|
1317
|
-
interaction,
|
|
1318
|
-
changes,
|
|
1319
|
-
checkpoints,
|
|
1320
|
-
targetCheckpoint: targetCp,
|
|
1321
|
-
isLoading: false,
|
|
1322
|
-
})
|
|
1323
|
-
} catch (err: any) {
|
|
1324
|
-
setUndoToastState({
|
|
1325
|
-
visible: true,
|
|
1326
|
-
message: `Failed to load checkpoints: ${err.message || String(err)}`,
|
|
1327
|
-
canUndo: false,
|
|
1328
|
-
isUndoing: false,
|
|
1329
|
-
type: 'error',
|
|
1330
|
-
})
|
|
1215
|
+
imagePayload = JSON.parse(rawImage)
|
|
1216
|
+
} catch {
|
|
1217
|
+
// ignore
|
|
1331
1218
|
}
|
|
1332
1219
|
}
|
|
1333
1220
|
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
title="Review changed code"
|
|
1365
|
-
onClick={() => {
|
|
1366
|
-
openReview('All conversation changes', getConversationChanges())
|
|
1367
|
-
}}
|
|
1368
|
-
>
|
|
1369
|
-
Review
|
|
1370
|
-
</button>
|
|
1371
|
-
</div>
|
|
1372
|
-
</div>
|
|
1373
|
-
{isOpen && <div className="file-changes-list-container">{renderChangesList(changes, interactionId)}</div>}
|
|
1374
|
-
</div>
|
|
1375
|
-
</div>
|
|
1376
|
-
)
|
|
1377
|
-
}, [agentActivitySnapshots, getConversationChanges, openReviewIds, openFileDiffs, showAllFileChanges, workspacePath, onOpenArtifact, onOpenReview])
|
|
1378
|
-
|
|
1379
|
-
const renderActiveFileChanges = () => {
|
|
1380
|
-
const changes = composerChanges
|
|
1381
|
-
if (changes.length === 0) return null
|
|
1382
|
-
|
|
1383
|
-
const totalAdditions = changes.reduce((sum, c) => sum + c.additions, 0)
|
|
1384
|
-
const totalDeletions = changes.reduce((sum, c) => sum + c.deletions, 0)
|
|
1385
|
-
const createdCount = changes.filter((c) => c.created).length
|
|
1386
|
-
const modifiedCount = changes.length - createdCount
|
|
1387
|
-
const isOpen = openReviewIds['active-run'] ?? true
|
|
1388
|
-
|
|
1389
|
-
let summaryLabel = ''
|
|
1390
|
-
if (createdCount > 0 && modifiedCount === 0) {
|
|
1391
|
-
summaryLabel = `${createdCount} ${createdCount === 1 ? 'file created' : 'files created'}`
|
|
1392
|
-
} else if (createdCount > 0 && modifiedCount > 0) {
|
|
1393
|
-
summaryLabel = `${createdCount} created, ${modifiedCount} modified`
|
|
1394
|
-
} else {
|
|
1395
|
-
summaryLabel = `${changes.length} ${changes.length === 1 ? 'file changed' : 'files changed'}`
|
|
1221
|
+
const wsPath =
|
|
1222
|
+
imagePayload?.path ||
|
|
1223
|
+
dataTransfer.getData(WORKSPACE_PATH_MIME) ||
|
|
1224
|
+
dataTransfer.getData('application/x-mint-workspace-path')
|
|
1225
|
+
const plainText = dataTransfer.getData('text/plain')
|
|
1226
|
+
const uriList = dataTransfer.getData('text/uri-list')
|
|
1227
|
+
const candidatePath = (wsPath || plainText || uriList || '').replace(/^@/, '').trim()
|
|
1228
|
+
|
|
1229
|
+
const isImg =
|
|
1230
|
+
Boolean(imagePayload) ||
|
|
1231
|
+
isImageFileName(candidatePath) ||
|
|
1232
|
+
candidatePath.startsWith('blob:') ||
|
|
1233
|
+
candidatePath.startsWith('data:image/') ||
|
|
1234
|
+
Boolean(imagePayload?.url)
|
|
1235
|
+
if (!isImg) return false
|
|
1236
|
+
|
|
1237
|
+
const name = imagePayload?.name || candidatePath.split(/[\\/]/).pop()?.split('?')[0] || 'image.png'
|
|
1238
|
+
const root = imagePayload?.root || workspacePath || ''
|
|
1239
|
+
const url =
|
|
1240
|
+
imagePayload?.url ||
|
|
1241
|
+
(candidatePath.startsWith('http') || candidatePath.startsWith('blob:') || candidatePath.startsWith('data:image/')
|
|
1242
|
+
? candidatePath
|
|
1243
|
+
: '')
|
|
1244
|
+
|
|
1245
|
+
let dataUri = ''
|
|
1246
|
+
if (url) {
|
|
1247
|
+
dataUri = await resolveImageToDataUri(url, root, (p, r) => runtimePlatform.readWorkspaceImage(p, r))
|
|
1248
|
+
}
|
|
1249
|
+
if (!dataUri && candidatePath) {
|
|
1250
|
+
dataUri = await resolveImageToDataUri(candidatePath, root, (p, r) => runtimePlatform.readWorkspaceImage(p, r))
|
|
1396
1251
|
}
|
|
1397
1252
|
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
<span className="file-changes-summary-counts">
|
|
1407
|
-
{totalAdditions > 0 && <span className="file-changes-count-add">+{totalAdditions}</span>}
|
|
1408
|
-
{totalDeletions > 0 && <span className="file-changes-count-del">-{totalDeletions}</span>}
|
|
1409
|
-
</span>
|
|
1410
|
-
</span>
|
|
1411
|
-
</div>
|
|
1412
|
-
<button
|
|
1413
|
-
type="button"
|
|
1414
|
-
className="file-changes-review-btn"
|
|
1415
|
-
title="Review changed code"
|
|
1416
|
-
onClick={() => {
|
|
1417
|
-
openReview('All conversation changes', getConversationChanges())
|
|
1418
|
-
}}
|
|
1419
|
-
>
|
|
1420
|
-
Review
|
|
1421
|
-
</button>
|
|
1422
|
-
</div>
|
|
1253
|
+
if (dataUri) {
|
|
1254
|
+
const previewDataUri = await createTrimmedImagePreview(dataUri).catch(() => dataUri)
|
|
1255
|
+
onAttachImage({ dataUri, previewDataUri, name })
|
|
1256
|
+
textareaRef.current?.focus()
|
|
1257
|
+
return true
|
|
1258
|
+
}
|
|
1259
|
+
return false
|
|
1260
|
+
}
|
|
1423
1261
|
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1262
|
+
const handleWorkspaceDrop = (event: DragEvent<HTMLElement>) => {
|
|
1263
|
+
event.preventDefault()
|
|
1264
|
+
const wsPath =
|
|
1265
|
+
event.dataTransfer.getData(WORKSPACE_PATH_MIME) ||
|
|
1266
|
+
event.dataTransfer.getData('application/x-mint-workspace-path')
|
|
1267
|
+
const plainText = event.dataTransfer.getData('text/plain')
|
|
1268
|
+
const reference = wsPath || plainText
|
|
1269
|
+
|
|
1270
|
+
void tryAttachDroppedImage(event.dataTransfer).then((attached) => {
|
|
1271
|
+
if (attached) return
|
|
1272
|
+
if (!reference) return
|
|
1273
|
+
const trimmed = reference.trim()
|
|
1274
|
+
if (wsPath || trimmed.startsWith('@')) {
|
|
1275
|
+
handleReferenceFile(trimmed)
|
|
1276
|
+
}
|
|
1277
|
+
})
|
|
1432
1278
|
}
|
|
1279
|
+
const isEmptyChat = interactions.length === 0 && !sending && !pendingApproval
|
|
1280
|
+
|
|
1281
|
+
const handleRewindRequest = useLatestCallback((payload: RewindRequestPayload) => {
|
|
1282
|
+
setRewindModalState({
|
|
1283
|
+
isOpen: true,
|
|
1284
|
+
interaction: payload.interaction,
|
|
1285
|
+
changes: payload.changes,
|
|
1286
|
+
checkpoints: payload.checkpoints,
|
|
1287
|
+
targetCheckpoint: payload.targetCheckpoint,
|
|
1288
|
+
isLoading: false,
|
|
1289
|
+
})
|
|
1290
|
+
})
|
|
1291
|
+
|
|
1292
|
+
const handleRewindError = useLatestCallback((message: string) => {
|
|
1293
|
+
setUndoToastState({
|
|
1294
|
+
visible: true,
|
|
1295
|
+
message,
|
|
1296
|
+
canUndo: false,
|
|
1297
|
+
isUndoing: false,
|
|
1298
|
+
type: 'error',
|
|
1299
|
+
})
|
|
1300
|
+
})
|
|
1433
1301
|
|
|
1434
1302
|
const liveTurn = sending || pendingApproval ? (
|
|
1435
1303
|
<>
|
|
@@ -1437,15 +1305,26 @@ export default function ChatPanel({
|
|
|
1437
1305
|
<div style={{ display: 'flex', flexDirection: 'column', gap: '8px', marginBottom: '16px' }}>
|
|
1438
1306
|
<div className="message user-message"><div className="bubble-wrapper"><div className="message-bubble"><FormattedMessage text={[sendingMessage, sendingImageMarkers, sendingVideoMarkers].filter(Boolean).join(' ')} /></div></div></div>
|
|
1439
1307
|
{agentMode && (
|
|
1440
|
-
<
|
|
1308
|
+
<AgentActivityDrawer
|
|
1441
1309
|
progress={agentProgress}
|
|
1442
1310
|
id="live"
|
|
1443
1311
|
isOpen={openActivityIds['live'] ?? true}
|
|
1444
1312
|
onToggle={toggleActivity}
|
|
1445
1313
|
pendingApproval={!!pendingApproval}
|
|
1314
|
+
chatId={chatId}
|
|
1315
|
+
workspacePath={workspacePath}
|
|
1316
|
+
onReferenceFile={handleReferenceFile}
|
|
1317
|
+
onOpenArtifact={openArtifact}
|
|
1446
1318
|
/>
|
|
1447
1319
|
)}
|
|
1448
|
-
|
|
1320
|
+
<TurnFileChanges
|
|
1321
|
+
changes={composerChanges}
|
|
1322
|
+
isLive
|
|
1323
|
+
workspacePath={workspacePath}
|
|
1324
|
+
onReferenceFile={handleReferenceFile}
|
|
1325
|
+
onOpenArtifact={openArtifact}
|
|
1326
|
+
onOpenReview={openAllConversationReview}
|
|
1327
|
+
/>
|
|
1449
1328
|
<div className="message ai-message thinking-message">
|
|
1450
1329
|
<div className="bubble-wrapper">
|
|
1451
1330
|
{!agentMode && liveExtendedThoughts.length > 0 && (
|
|
@@ -1468,8 +1347,8 @@ export default function ChatPanel({
|
|
|
1468
1347
|
/>
|
|
1469
1348
|
)}
|
|
1470
1349
|
<div className="message-bubble">
|
|
1471
|
-
<McpToolResults progress={agentProgress} running />
|
|
1472
|
-
<ViewedImages progress={agentProgress} />
|
|
1350
|
+
<McpToolResults progress={agentProgress} running chatId={chatId} mode="artifacts-only" />
|
|
1351
|
+
<ViewedImages progress={agentProgress} chatId={chatId} onOpenArtifact={openArtifact} />
|
|
1473
1352
|
<span>
|
|
1474
1353
|
{compaction ? (
|
|
1475
1354
|
<ContextCompactionStatus key={compaction.index} />
|
|
@@ -1483,9 +1362,7 @@ export default function ChatPanel({
|
|
|
1483
1362
|
? `${activeAgentName} (${activeModelName}) is thinking...`
|
|
1484
1363
|
: 'Thinking'}
|
|
1485
1364
|
</span>
|
|
1486
|
-
<
|
|
1487
|
-
{` · ${elapsedSeconds}s · Esc to cancel`}
|
|
1488
|
-
</span>
|
|
1365
|
+
<ThinkingElapsedMeta />
|
|
1489
1366
|
</div>
|
|
1490
1367
|
)}
|
|
1491
1368
|
</span>
|
|
@@ -1493,7 +1370,7 @@ export default function ChatPanel({
|
|
|
1493
1370
|
{streamedResponse && (
|
|
1494
1371
|
<div className="message-time" style={{ display: 'flex', alignItems: 'center', gap: '8px' }}>
|
|
1495
1372
|
<span className="provider-model-chip" data-provider={(streamedResponse.provider || '').toLowerCase()} title={`${streamedResponse.provider} • ${streamedResponse.model}`}>
|
|
1496
|
-
<
|
|
1373
|
+
<ProviderBrandIcon provider={streamedResponse.provider} model={streamedResponse.model} customProviders={settingsConfig?.customProviders} size={13} />
|
|
1497
1374
|
<span className="provider-chip-name">{streamedResponse.provider}</span>
|
|
1498
1375
|
<span className="provider-chip-divider">/</span>
|
|
1499
1376
|
<span className="provider-chip-model">{streamedResponse.model}</span>
|
|
@@ -1505,15 +1382,16 @@ export default function ChatPanel({
|
|
|
1505
1382
|
type="button"
|
|
1506
1383
|
className={`msg-action-btn copy-btn ${copiedId === 'live' ? 'is-copied' : ''}`}
|
|
1507
1384
|
onClick={() => handleCopyMessage('live', throttledStreamedReply)}
|
|
1508
|
-
title={copiedId === 'live' ? '
|
|
1385
|
+
title={copiedId === 'live' ? 'Copied!' : 'Copy message'}
|
|
1509
1386
|
>
|
|
1510
1387
|
{renderCopyIcon(copiedId === 'live')}
|
|
1511
1388
|
</button>
|
|
1512
1389
|
<button
|
|
1513
1390
|
type="button"
|
|
1514
1391
|
className={`msg-action-btn tts-btn ${speakingText === throttledStreamedReply ? 'is-speaking' : ''}`}
|
|
1392
|
+
disabled={sending}
|
|
1515
1393
|
onClick={() => speak(throttledStreamedReply)}
|
|
1516
|
-
title={speakingText === throttledStreamedReply ? 'Stop reading' : 'Read aloud'}
|
|
1394
|
+
title={sending ? 'Read after the reply finishes' : speakingText === throttledStreamedReply ? 'Stop reading' : 'Read aloud'}
|
|
1517
1395
|
>
|
|
1518
1396
|
{renderSpeakerIcon(speakingText === throttledStreamedReply)}
|
|
1519
1397
|
</button>
|
|
@@ -1545,6 +1423,7 @@ export default function ChatPanel({
|
|
|
1545
1423
|
onDrop={handleDrop}
|
|
1546
1424
|
style={activeArtifact || reviewPage ? { flex: '0 0 calc(100% - var(--preview-width, 50%))', width: 'calc(100% - var(--preview-width, 50%))', minWidth: '320px', maxWidth: 'none', margin: 0, position: 'relative' } : undefined}
|
|
1547
1425
|
>
|
|
1426
|
+
{speechError && <p role="status" style={{ padding: '8px 16px', fontSize: '12px', color: 'var(--text-muted)' }}>{speechError} <button type="button" onClick={() => setSpeechError('')}>Dismiss</button></p>}
|
|
1548
1427
|
{isDragging && (
|
|
1549
1428
|
<div
|
|
1550
1429
|
className="drag-drop-overlay"
|
|
@@ -1558,16 +1437,16 @@ export default function ChatPanel({
|
|
|
1558
1437
|
left: 0,
|
|
1559
1438
|
right: 0,
|
|
1560
1439
|
bottom: 0,
|
|
1561
|
-
background: '
|
|
1440
|
+
background: 'var(--bg-backdrop)',
|
|
1562
1441
|
backdropFilter: 'blur(8px)',
|
|
1563
1442
|
border: '2px dashed var(--accent)',
|
|
1564
|
-
borderRadius: '
|
|
1443
|
+
borderRadius: 'var(--radius-xl, 18px)',
|
|
1565
1444
|
margin: '12px',
|
|
1566
1445
|
display: 'flex',
|
|
1567
1446
|
flexDirection: 'column',
|
|
1568
1447
|
alignItems: 'center',
|
|
1569
1448
|
justifyContent: 'center',
|
|
1570
|
-
color: '
|
|
1449
|
+
color: 'var(--text-primary)',
|
|
1571
1450
|
zIndex: 1000,
|
|
1572
1451
|
pointerEvents: 'auto',
|
|
1573
1452
|
}}
|
|
@@ -1651,7 +1530,6 @@ export default function ChatPanel({
|
|
|
1651
1530
|
)}
|
|
1652
1531
|
</div>
|
|
1653
1532
|
<div className="chat-header-actions">
|
|
1654
|
-
{showSessionSources && <SessionSourcesPopover chatId={chatId} liveProgress={agentProgress} open={sessionSourcesOpen} onOpenChange={setSessionSourcesOpen} />}
|
|
1655
1533
|
{tools?.onToggle && <ToolsPanelToggle open={tools.open} count={tools.backgroundTaskCount} onToggle={tools.onToggle} />}
|
|
1656
1534
|
{activeArtifact && (
|
|
1657
1535
|
<button
|
|
@@ -1685,7 +1563,7 @@ export default function ChatPanel({
|
|
|
1685
1563
|
<div className="chat-container" ref={chatContainerRef} onScroll={handleChatScroll} style={{ overflowAnchor: 'none' }}>
|
|
1686
1564
|
{hasOlder && onLoadOlder && (
|
|
1687
1565
|
<button type="button" className="load-older-messages" disabled={loadingOlder}
|
|
1688
|
-
style={{ display: 'block', margin: '0 auto 20px', padding: '7px 14px', borderRadius:
|
|
1566
|
+
style={{ display: 'block', margin: '0 auto 20px', padding: '7px 14px', borderRadius: 'var(--radius-md, 10px)',
|
|
1689
1567
|
border: '1px solid var(--border-color, #3a3a3a)', background: 'var(--surface, #252525)',
|
|
1690
1568
|
color: 'var(--text-secondary, #c0c0c0)', cursor: loadingOlder ? 'default' : 'pointer' }}
|
|
1691
1569
|
onClick={async () => {
|
|
@@ -1720,19 +1598,23 @@ export default function ChatPanel({
|
|
|
1720
1598
|
interaction={interaction}
|
|
1721
1599
|
copiedId={copiedId}
|
|
1722
1600
|
onEditMessage={handleEditMessage}
|
|
1601
|
+
onResendFrom={onResendFrom}
|
|
1723
1602
|
speakingText={speakingText}
|
|
1724
1603
|
agentActivitySnapshots={agentActivitySnapshots}
|
|
1725
|
-
thinkingExpanded={thinkingExpanded}
|
|
1726
1604
|
openActivityIds={openActivityIds}
|
|
1727
|
-
|
|
1728
|
-
openFileDiffs={openFileDiffs}
|
|
1605
|
+
thinkingExpanded={thinkingExpanded}
|
|
1729
1606
|
onThinkingExpandedChange={onThinkingExpandedChange}
|
|
1730
1607
|
handleCopyMessage={handleCopyMessage}
|
|
1731
1608
|
speak={speak}
|
|
1732
1609
|
toggleActivity={toggleActivity}
|
|
1733
|
-
|
|
1610
|
+
chatId={chatId}
|
|
1734
1611
|
workspacePath={workspacePath}
|
|
1735
|
-
|
|
1612
|
+
onReferenceFile={handleReferenceFile}
|
|
1613
|
+
customProviders={settingsConfig?.customProviders}
|
|
1614
|
+
onOpenArtifact={openArtifact}
|
|
1615
|
+
onOpenReview={openAllConversationReview}
|
|
1616
|
+
onRewindRequest={handleRewindRequest}
|
|
1617
|
+
onRewindError={handleRewindError}
|
|
1736
1618
|
/>
|
|
1737
1619
|
</Fragment>
|
|
1738
1620
|
)
|
|
@@ -1757,6 +1639,10 @@ export default function ChatPanel({
|
|
|
1757
1639
|
|
|
1758
1640
|
<div className="input-area">
|
|
1759
1641
|
<ModsPanel workspacePath={workspacePath} chatId={chatId} panelTarget={tools?.modsPanelTarget} onOpen={tools?.onOpenMods ?? (() => {})} />
|
|
1642
|
+
<SubagentStatusStrip
|
|
1643
|
+
progress={agentProgress}
|
|
1644
|
+
onOpenDetails={() => toggleActivity('live')}
|
|
1645
|
+
/>
|
|
1760
1646
|
{composerChanges.length > 0 && (
|
|
1761
1647
|
<button
|
|
1762
1648
|
type="button"
|
|
@@ -1797,24 +1683,18 @@ export default function ChatPanel({
|
|
|
1797
1683
|
{workspacePath && <GitBranchSelector workspacePath={workspacePath} disabled={sending} onBranchChanged={onWorkspaceChanged} />}
|
|
1798
1684
|
</div>
|
|
1799
1685
|
)}
|
|
1800
|
-
|
|
1801
|
-
<
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
<span className="slider round" />
|
|
1813
|
-
</span>
|
|
1814
|
-
<span className="smart-context-copy"><span className="smart-context-title">Plan mode</span></span>
|
|
1815
|
-
</label>
|
|
1816
|
-
)}
|
|
1817
|
-
</div>
|
|
1686
|
+
{queuedPrompts && queuedPrompts.length > 0 && (
|
|
1687
|
+
<QueuedMessagesBanner
|
|
1688
|
+
queuedPrompts={queuedPrompts}
|
|
1689
|
+
queuePaused={Boolean(queuePaused)}
|
|
1690
|
+
sending={sending}
|
|
1691
|
+
onRemove={onRemoveQueuedPrompt || (() => {})}
|
|
1692
|
+
onEdit={onEditQueuedPrompt || (() => {})}
|
|
1693
|
+
onClear={onClearQueuedPrompts || (() => {})}
|
|
1694
|
+
onSteer={onSteerQueuedPrompt || (() => {})}
|
|
1695
|
+
onResumeQueue={onResumeQueue}
|
|
1696
|
+
/>
|
|
1697
|
+
)}
|
|
1818
1698
|
<form
|
|
1819
1699
|
id="chat-form"
|
|
1820
1700
|
className={geminiLiveEnabled ? 'has-live-btn' : ''}
|
|
@@ -1825,7 +1705,12 @@ export default function ChatPanel({
|
|
|
1825
1705
|
onSubmit(event)
|
|
1826
1706
|
}}
|
|
1827
1707
|
onDragOver={(event) => {
|
|
1828
|
-
if (
|
|
1708
|
+
if (
|
|
1709
|
+
event.dataTransfer.types.includes(WORKSPACE_PATH_MIME) ||
|
|
1710
|
+
event.dataTransfer.types.includes(WORKSPACE_FILE_MIME) ||
|
|
1711
|
+
event.dataTransfer.types.includes(WORKSPACE_IMAGE_MIME) ||
|
|
1712
|
+
event.dataTransfer.types.includes('application/x-mint-workspace-path')
|
|
1713
|
+
) {
|
|
1829
1714
|
event.preventDefault()
|
|
1830
1715
|
event.dataTransfer.dropEffect = 'copy'
|
|
1831
1716
|
}
|
|
@@ -1881,7 +1766,7 @@ export default function ChatPanel({
|
|
|
1881
1766
|
</svg>
|
|
1882
1767
|
</span>
|
|
1883
1768
|
<span style={{ fontSize: '0.76rem', color: 'var(--text-soft)', overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '220px' }}>{documentName}</span>
|
|
1884
|
-
<button type="button" onClick={onRemoveDocument} style={{ background: 'transparent', border: 0, color: '
|
|
1769
|
+
<button type="button" onClick={onRemoveDocument} style={{ background: 'transparent', border: 0, color: 'var(--status-error)', cursor: 'pointer', display: 'inline-flex', alignItems: 'center' }}>
|
|
1885
1770
|
<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2.5" strokeLinecap="round" strokeLinejoin="round">
|
|
1886
1771
|
<line x1="18" y1="6" x2="6" y2="18"></line>
|
|
1887
1772
|
<line x1="6" y1="6" x2="18" y2="18"></line>
|
|
@@ -1930,6 +1815,18 @@ export default function ChatPanel({
|
|
|
1930
1815
|
if (historyIndex !== null) setHistoryIndex(null)
|
|
1931
1816
|
}}
|
|
1932
1817
|
onKeyDown={handleInputKeyDown}
|
|
1818
|
+
onDragOver={(event) => {
|
|
1819
|
+
if (
|
|
1820
|
+
event.dataTransfer.types.includes(WORKSPACE_PATH_MIME) ||
|
|
1821
|
+
event.dataTransfer.types.includes(WORKSPACE_FILE_MIME) ||
|
|
1822
|
+
event.dataTransfer.types.includes(WORKSPACE_IMAGE_MIME) ||
|
|
1823
|
+
event.dataTransfer.types.includes('application/x-mint-workspace-path') ||
|
|
1824
|
+
event.dataTransfer.types.includes('text/plain')
|
|
1825
|
+
) {
|
|
1826
|
+
event.preventDefault()
|
|
1827
|
+
event.dataTransfer.dropEffect = 'copy'
|
|
1828
|
+
}
|
|
1829
|
+
}}
|
|
1933
1830
|
onDrop={handleWorkspaceDrop}
|
|
1934
1831
|
placeholder="Ask anything, @ to mention, / for actions"
|
|
1935
1832
|
rows={1}
|
|
@@ -2018,22 +1915,31 @@ export default function ChatPanel({
|
|
|
2018
1915
|
<path d="M8 22h8M12 18v4M7 10h10M12 5v10" />
|
|
2019
1916
|
</svg>
|
|
2020
1917
|
</button>
|
|
2021
|
-
<
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
onSelectModelAndProvider
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
1918
|
+
<div className="chat-composer-pills">
|
|
1919
|
+
<ModelSelectorPopover
|
|
1920
|
+
activeProvider={status?.activeProvider ?? ''}
|
|
1921
|
+
activeModel={activeModel}
|
|
1922
|
+
availableProviders={status?.availableProviders ?? []}
|
|
1923
|
+
settingsConfig={settingsConfig}
|
|
1924
|
+
dynamicOllamaModels={dynamicOllamaModels}
|
|
1925
|
+
onSelect={(provider, model) => {
|
|
1926
|
+
if (onSelectModelAndProvider) {
|
|
1927
|
+
onSelectModelAndProvider(provider, model)
|
|
1928
|
+
} else {
|
|
1929
|
+
onSetProvider(provider)
|
|
1930
|
+
onSetModel(model)
|
|
1931
|
+
}
|
|
1932
|
+
}}
|
|
1933
|
+
onUpdateSettings={onUpdateSettings}
|
|
1934
|
+
/>
|
|
1935
|
+
<ChatModeSelector
|
|
1936
|
+
agentMode={agentMode}
|
|
1937
|
+
onSetAgentMode={onSetAgentMode}
|
|
1938
|
+
planMode={planMode}
|
|
1939
|
+
onSetPlanMode={onSetPlanMode}
|
|
1940
|
+
disabled={sending}
|
|
1941
|
+
/>
|
|
1942
|
+
</div>
|
|
2037
1943
|
<VoicePill
|
|
2038
1944
|
id="voice-input-btn"
|
|
2039
1945
|
className="composer-voice-pill"
|
|
@@ -2041,9 +1947,9 @@ export default function ChatPanel({
|
|
|
2041
1947
|
disabled={sending || voiceAwaitingResponse || geminiLive.voiceMode}
|
|
2042
1948
|
ariaLabel="Voice input"
|
|
2043
1949
|
title={isRecording ? 'Stop recording · Esc or slide left to cancel' : 'Tap to dictate · hold to record'}
|
|
2044
|
-
accentColor="
|
|
2045
|
-
iconColor="
|
|
2046
|
-
background="
|
|
1950
|
+
accentColor="var(--text-primary)"
|
|
1951
|
+
iconColor="var(--text-muted)"
|
|
1952
|
+
background="var(--bg-surface-soft)"
|
|
2047
1953
|
size={28}
|
|
2048
1954
|
shape="pill"
|
|
2049
1955
|
reach={8}
|
|
@@ -2089,18 +1995,34 @@ export default function ChatPanel({
|
|
|
2089
1995
|
</button>
|
|
2090
1996
|
)}
|
|
2091
1997
|
{sending ? (
|
|
2092
|
-
<
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
1998
|
+
<div style={{ display: 'inline-flex', alignItems: 'center', gap: '6px' }}>
|
|
1999
|
+
{canSubmit && (
|
|
2000
|
+
<button
|
|
2001
|
+
id="queue-btn"
|
|
2002
|
+
className="queue-btn"
|
|
2003
|
+
type="submit"
|
|
2004
|
+
title="Add to queue (Enter)"
|
|
2005
|
+
style={{ display: 'inline-flex', alignItems: 'center', justifyContent: 'center' }}
|
|
2006
|
+
>
|
|
2007
|
+
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round">
|
|
2008
|
+
<line x1="22" y1="2" x2="11" y2="13"></line>
|
|
2009
|
+
<polygon points="22 2 15 22 11 13 2 9 22 2"></polygon>
|
|
2010
|
+
</svg>
|
|
2011
|
+
</button>
|
|
2012
|
+
)}
|
|
2013
|
+
<button
|
|
2014
|
+
id="send-btn"
|
|
2015
|
+
className="stop-btn"
|
|
2016
|
+
type="button"
|
|
2017
|
+
onClick={onCancelMessage}
|
|
2018
|
+
title="Stop generating"
|
|
2019
|
+
style={{ display: 'inline-flex', alignItems: 'center', justifyContent: 'center' }}
|
|
2020
|
+
>
|
|
2021
|
+
<svg width="14" height="14" viewBox="0 0 24 24" fill="currentColor">
|
|
2022
|
+
<rect x="4" y="4" width="16" height="16" rx="2" ry="2"></rect>
|
|
2023
|
+
</svg>
|
|
2024
|
+
</button>
|
|
2025
|
+
</div>
|
|
2104
2026
|
) : (
|
|
2105
2027
|
<button id="send-btn" type="submit" disabled={!canSubmit} style={{ display: 'inline-flex', alignItems: 'center', justifyContent: 'center' }}>
|
|
2106
2028
|
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round">
|
|
@@ -2114,9 +2036,6 @@ export default function ChatPanel({
|
|
|
2114
2036
|
<p className="composer-voice-feedback" role="status">{voiceTranscript}</p>
|
|
2115
2037
|
)}
|
|
2116
2038
|
</div>
|
|
2117
|
-
<p className="input-disclaimer">
|
|
2118
|
-
Mint Agent is an AI gateway. Responses via third-party APIs. Verify critical info.
|
|
2119
|
-
</p>
|
|
2120
2039
|
{geminiLive.voiceMode && (
|
|
2121
2040
|
<GeminiLiveOverlay
|
|
2122
2041
|
status={
|
|
@@ -2140,6 +2059,8 @@ export default function ChatPanel({
|
|
|
2140
2059
|
onEndCall={() => geminiLive.setVoiceMode(false)}
|
|
2141
2060
|
voice={settingsConfig?.geminiLiveVoice || 'Puck'}
|
|
2142
2061
|
voices={GEMINI_LIVE_VOICES}
|
|
2062
|
+
pendingApproval={pendingApproval}
|
|
2063
|
+
onApproval={onApproval}
|
|
2143
2064
|
onChangeVoice={async (voiceName) => {
|
|
2144
2065
|
await onSetGeminiLiveVoice(voiceName)
|
|
2145
2066
|
geminiLive.restart()
|
|
@@ -2219,29 +2140,33 @@ export default function ChatPanel({
|
|
|
2219
2140
|
>
|
|
2220
2141
|
<div className="preview-split-resizer-grip" />
|
|
2221
2142
|
</div>
|
|
2222
|
-
{
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2143
|
+
<Suspense fallback={null}>
|
|
2144
|
+
{reviewPage ? (
|
|
2145
|
+
<CodeReviewPage
|
|
2146
|
+
title={reviewPage.title}
|
|
2147
|
+
changes={reviewPage.changes}
|
|
2148
|
+
workspacePath={workspacePath}
|
|
2149
|
+
onBack={() => setReviewPage(null)}
|
|
2150
|
+
/>
|
|
2151
|
+
) : activeArtifact ? (
|
|
2152
|
+
<ArtifactPreviewPanel artifact={activeArtifact} onClose={() => setActiveArtifact(null)} workspacePath={workspacePath} />
|
|
2153
|
+
) : null}
|
|
2154
|
+
</Suspense>
|
|
2232
2155
|
</>
|
|
2233
2156
|
)}
|
|
2234
2157
|
{rewindModalState.isOpen && (
|
|
2235
|
-
<
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2158
|
+
<Suspense fallback={null}>
|
|
2159
|
+
<RewindModal
|
|
2160
|
+
isOpen={rewindModalState.isOpen}
|
|
2161
|
+
onClose={() => setRewindModalState((prev) => ({ ...prev, isOpen: false }))}
|
|
2162
|
+
onConfirm={handleConfirmRewind}
|
|
2163
|
+
checkpoints={rewindModalState.checkpoints}
|
|
2164
|
+
targetCheckpoint={rewindModalState.targetCheckpoint}
|
|
2165
|
+
changes={rewindModalState.changes}
|
|
2166
|
+
workspacePath={workspacePath}
|
|
2167
|
+
isLoading={rewindModalState.isLoading}
|
|
2168
|
+
/>
|
|
2169
|
+
</Suspense>
|
|
2245
2170
|
)}
|
|
2246
2171
|
</div>
|
|
2247
2172
|
)
|