cognova 0.2.13 → 0.2.14
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/.output/nitro.json +1 -1
- package/.output/public/_nuxt/-mGU8_Hv.js +1 -0
- package/.output/public/_nuxt/0GqCtQ9S.js +1 -0
- package/.output/public/_nuxt/{DFpmIy6J.js → 1wCoXZ14.js} +1 -1
- package/.output/public/_nuxt/2J1KxdHv.js +1 -0
- package/.output/public/_nuxt/6VDUZECX.js +1 -0
- package/.output/public/_nuxt/{C7m9zGMG.js → 8WMJQbWG.js} +1 -1
- package/.output/public/_nuxt/9Rw88G6h.js +1 -0
- package/.output/public/_nuxt/{BjsKx597.js → B-yW4SD3.js} +1 -1
- package/.output/public/_nuxt/B20jNAhm.js +1 -0
- package/.output/public/_nuxt/B3OpTH_e.js +1 -0
- package/.output/public/_nuxt/B9Y3_B5G.js +1 -0
- package/.output/public/_nuxt/B9_vmatf.js +1 -0
- package/.output/public/_nuxt/B9o6sFST.js +1 -0
- package/.output/public/_nuxt/{CseYuM6E.js → BAY3_Hrq.js} +1 -1
- package/.output/public/_nuxt/{B_9zJTqe.js → BD5rPkc2.js} +3 -3
- package/.output/public/_nuxt/BGYoW3kO.js +1 -0
- package/.output/public/_nuxt/BHUy5EAj.js +1 -0
- package/.output/public/_nuxt/BLdMRpJD.js +1 -0
- package/.output/public/_nuxt/{D6tVZcRs.js → BOCn_SGf.js} +12 -12
- package/.output/public/_nuxt/BQi8LIrn.js +1 -0
- package/.output/public/_nuxt/BS1t375R.js +1 -0
- package/.output/public/_nuxt/BTGeP1bA.js +1 -0
- package/.output/public/_nuxt/{pdYvpiud.js → BVYYP4eQ.js} +5 -5
- package/.output/public/_nuxt/BWQ7zE01.js +1 -0
- package/.output/public/_nuxt/BWqJInD3.js +1 -0
- package/.output/public/_nuxt/BXdQ9ASJ.js +1 -0
- package/.output/public/_nuxt/{DQhm-UPG.js → BXxZokD_.js} +2 -2
- package/.output/public/_nuxt/BZ7DAtPi.js +1 -0
- package/.output/public/_nuxt/BZm9w7en.js +1 -0
- package/.output/public/_nuxt/B_hNqC64.js +1 -0
- package/.output/public/_nuxt/Be47YE2L.js +1 -0
- package/.output/public/_nuxt/BgIS9_ti.js +39 -0
- package/.output/public/_nuxt/BgavRUl_.js +1 -0
- package/.output/public/_nuxt/Bh0yGTzr.js +1 -0
- package/.output/public/_nuxt/BhhMUror.js +1 -0
- package/.output/public/_nuxt/Bj5e7QPz.js +1 -0
- package/.output/public/_nuxt/{9kAKMaPC.js → Bnn59-FS.js} +1 -1
- package/.output/public/_nuxt/BoCU3mWu.js +1 -0
- package/.output/public/_nuxt/Br6epbzY.js +1 -0
- package/.output/public/_nuxt/Br81Sr2R.js +1 -0
- package/.output/public/_nuxt/BrkEOLHu.js +9 -0
- package/.output/public/_nuxt/BtrNCc2S.js +1 -0
- package/.output/public/_nuxt/BxsQlbgl.js +1 -0
- package/.output/public/_nuxt/BzrhNhdT.js +1 -0
- package/.output/public/_nuxt/{B-DMcEU9.js → C-78dDNd.js} +1 -1
- package/.output/public/_nuxt/C1oaoi1p.js +1 -0
- package/.output/public/_nuxt/C2-_hcwB.js +1 -0
- package/.output/public/_nuxt/{TxMdabnL.js → C2Gh3qqr.js} +1 -1
- package/.output/public/_nuxt/C2OHaW6l.js +1 -0
- package/.output/public/_nuxt/C3szZmvA.js +1 -0
- package/.output/public/_nuxt/C3xzleKP.js +1 -0
- package/.output/public/_nuxt/C4sG6rdW.js +1 -0
- package/.output/public/_nuxt/C5Cu9Fx6.js +1 -0
- package/.output/public/_nuxt/{LRO7YHoH.js → C5gfF7J1.js} +1 -1
- package/.output/public/_nuxt/C6Eoiclo.js +1 -0
- package/.output/public/_nuxt/C7hFztZL.js +1 -0
- package/.output/public/_nuxt/CAVUAxNU.js +2 -0
- package/.output/public/_nuxt/{CiNxIhaq.js → CCeM5lW2.js} +1 -1
- package/.output/public/_nuxt/CDcQ31Eh.js +1 -0
- package/.output/public/_nuxt/CHbHVtCy.js +1 -0
- package/.output/public/_nuxt/CHnVFnBW.js +1 -0
- package/.output/public/_nuxt/CLNcmNQS.js +1 -0
- package/.output/public/_nuxt/{D7N3EZ-I.js → CPwCTHun.js} +1 -1
- package/.output/public/_nuxt/{CFmvNggn.js → CS8SdmH2.js} +1 -1
- package/.output/public/_nuxt/CTGm_mc8.js +1 -0
- package/.output/public/_nuxt/{DNcOC5zj.js → CTQFGHjS.js} +1 -1
- package/.output/public/_nuxt/{B0nzD8Sk.js → CVVtVzXC.js} +1 -1
- package/.output/public/_nuxt/CZNOaqeX.js +1 -0
- package/.output/public/_nuxt/C_A_NkeC.js +2 -0
- package/.output/public/_nuxt/{CGplHfmR.js → C_doutX-.js} +1 -1
- package/.output/public/_nuxt/{BrX-PnSK.js → CbDLhrNA.js} +2 -2
- package/.output/public/_nuxt/CePKCqSb.js +1 -0
- package/.output/public/_nuxt/Cet4T_yO.js +1 -0
- package/.output/public/_nuxt/{C6OSRpRd.js → CjJPkhbc.js} +1 -1
- package/.output/public/_nuxt/CkZT4LGq.js +1 -0
- package/.output/public/_nuxt/CkrW8sGL.js +1 -0
- package/.output/public/_nuxt/Co0UxVsx.js +1 -0
- package/.output/public/_nuxt/CqS0zXYQ.js +1 -0
- package/.output/public/_nuxt/CskGv_Km.js +1 -0
- package/.output/public/_nuxt/{DuzpliIL.js → CuvkTsqs.js} +1 -1
- package/.output/public/_nuxt/{B2wI_pYg.js → CxMuZEwX.js} +1 -1
- package/.output/public/_nuxt/{9O1MXkck.js → CxSijT71.js} +8 -8
- package/.output/public/_nuxt/Cywo6tZI.js +1 -0
- package/.output/public/_nuxt/D1reIfpX.js +1 -0
- package/.output/public/_nuxt/D1uV2uir.js +1 -0
- package/.output/public/_nuxt/{BWuL2CzO.js → D2edadpd.js} +1 -1
- package/.output/public/_nuxt/D3cEeQh7.js +1 -0
- package/.output/public/_nuxt/D41A2mE2.js +1 -0
- package/.output/public/_nuxt/D49P2RhG.js +1 -0
- package/.output/public/_nuxt/D867g6Ds.js +1 -0
- package/.output/public/_nuxt/DEFWIjWl.js +1 -0
- package/.output/public/_nuxt/DFTEBTzZ.js +1 -0
- package/.output/public/_nuxt/{-HePz7lp.js → DHRexj9X.js} +2 -2
- package/.output/public/_nuxt/DL4EpgqQ.js +1 -0
- package/.output/public/_nuxt/DLHnP6tw.js +1 -0
- package/.output/public/_nuxt/DM20WaLq.js +1 -0
- package/.output/public/_nuxt/{B8DFEjxA.js → DNAMjHbb.js} +1 -1
- package/.output/public/_nuxt/{CLkkdThv.js → DP8t9VWs.js} +24 -24
- package/.output/public/_nuxt/DTR31rjp.js +1 -0
- package/.output/public/_nuxt/{Bc8bTnkd.js → DTlSLSo1.js} +3 -3
- package/.output/public/_nuxt/{DowkFZ2V.js → DVdnhfXT.js} +1 -1
- package/.output/public/_nuxt/{DvHS7_h2.js → DZikIgHK.js} +1 -1
- package/.output/public/_nuxt/D_YGqvw_.js +1 -0
- package/.output/public/_nuxt/D_k1YwXm.js +1 -0
- package/.output/public/_nuxt/Daf2MbWG.js +7 -0
- package/.output/public/_nuxt/DcJ0GstJ.js +1 -0
- package/.output/public/_nuxt/DcYKh6QA.js +1 -0
- package/.output/public/_nuxt/DhN3_DYH.js +1 -0
- package/.output/public/_nuxt/DhSvBSt3.js +1 -0
- package/.output/public/_nuxt/DhlIWT8K.js +1 -0
- package/.output/public/_nuxt/DjsqyRqt.js +1 -0
- package/.output/public/_nuxt/DpSM97eH.js +1 -0
- package/.output/public/_nuxt/DqR9SdeU.js +1 -0
- package/.output/public/_nuxt/DqmQtg6Y.js +1 -0
- package/.output/public/_nuxt/Dsuag_iW.js +1 -0
- package/.output/public/_nuxt/Dtr_0IbE.js +1 -0
- package/.output/public/_nuxt/DwrmFEZN.js +1 -0
- package/.output/public/_nuxt/DxE8r3r4.js +1 -0
- package/.output/public/_nuxt/G_CsVlOR.js +1 -0
- package/.output/public/_nuxt/Gyw_2f6x.js +1 -0
- package/.output/public/_nuxt/HStC1ZyE.js +1 -0
- package/.output/public/_nuxt/Hh9mv0Ek.js +1 -0
- package/.output/public/_nuxt/LR0kCjbe.js +1 -0
- package/.output/public/_nuxt/MYeLvJGV.js +1 -0
- package/.output/public/_nuxt/NKs0EGrh.js +1 -0
- package/.output/public/_nuxt/PY5EGujn.js +1 -0
- package/.output/public/_nuxt/PamJNol9.js +1 -0
- package/.output/public/_nuxt/RlvwEbHv.js +1 -0
- package/.output/public/_nuxt/{BghuwIGa.js → TNpdJOlc.js} +1 -1
- package/.output/public/_nuxt/TSYrPbLR.js +1 -0
- package/.output/public/_nuxt/U-eBrbR4.js +1 -0
- package/.output/public/_nuxt/UuqXScSw.js +1 -0
- package/.output/public/_nuxt/V04-MrLN.js +1 -0
- package/.output/public/_nuxt/X0o5GcBb.js +1 -0
- package/.output/public/_nuxt/XQNzmQy9.js +1 -0
- package/.output/public/_nuxt/Y59XKprr.js +1 -0
- package/.output/public/_nuxt/YZQjZgsH.js +1 -0
- package/.output/public/_nuxt/_-TGPiLQ.js +1 -0
- package/.output/public/_nuxt/builds/latest.json +1 -1
- package/.output/public/_nuxt/builds/meta/d7188f50-b42c-4d2c-afab-066d318f0af8.json +1 -0
- package/.output/public/_nuxt/dashboard.ByJQ-Wzh.css +1 -0
- package/.output/public/_nuxt/entry.ZJxWCrU6.css +1 -0
- package/.output/public/_nuxt/{D12qPplu.js → hCeWb_38.js} +1 -1
- package/.output/public/_nuxt/{sBzyvWMJ.js → hrPTRWjM.js} +1 -1
- package/.output/public/_nuxt/jC4pIK1p.js +1 -0
- package/.output/public/_nuxt/jTT1R-Vz.js +1 -0
- package/.output/public/_nuxt/{CRRw0Thu.js → kkAMoB43.js} +1 -1
- package/.output/public/_nuxt/{h_bXa-f2.js → mzM4BGtv.js} +1 -1
- package/.output/public/_nuxt/o-s8JBm2.js +1 -0
- package/.output/public/_nuxt/pwJTkIQ4.js +1 -0
- package/.output/public/_nuxt/{BL1mkqgd.js → rIgg2Arf.js} +3 -3
- package/.output/public/_nuxt/subdxgSQ.js +1 -0
- package/.output/public/_nuxt/t8B72leH.js +1 -0
- package/.output/public/_nuxt/vCFAHwdt.js +1 -0
- package/.output/public/_nuxt/z-MP0bB7.js +1 -0
- package/.output/server/chunks/build/CodeIcon-CWD5HcV7.mjs +1 -1
- package/.output/server/chunks/build/DropdownMenu-BBrV9nXz.mjs +1 -1
- package/.output/server/chunks/build/{EditorToolbar-DIfb5arC.mjs → EditorToolbar-B9OwSI5e.mjs} +3 -3
- package/.output/server/chunks/build/{EditorToolbar-DIfb5arC.mjs.map → EditorToolbar-B9OwSI5e.mjs.map} +1 -1
- package/.output/server/chunks/build/Img-CWLmvN1t.mjs +1 -1
- package/.output/server/chunks/build/MDC-Dx0YPDhe.mjs +1 -1
- package/.output/server/chunks/build/Select-BB1oLrCD.mjs +1 -1
- package/.output/server/chunks/build/SelectMenu-DPssg6zD.mjs +1 -1
- package/.output/server/chunks/build/Table-DCwTlhCj.mjs +1 -1
- package/.output/server/chunks/build/Tooltip-TRyl6dje.mjs +1 -1
- package/.output/server/chunks/build/Tree-DUhXKd8y.mjs +1 -1
- package/.output/server/chunks/build/{_id_-DN00UDdO.mjs → _id_-CwBeklIM.mjs} +296 -430
- package/.output/server/chunks/build/_id_-CwBeklIM.mjs.map +1 -0
- package/.output/server/chunks/build/{_name_-BnS_KEfX.mjs → _name_-D7MtW4Vu.mjs} +2 -2
- package/.output/server/chunks/build/{_name_-BnS_KEfX.mjs.map → _name_-D7MtW4Vu.mjs.map} +1 -1
- package/.output/server/chunks/build/{_uuid_-DfJaumTE.mjs → _uuid_-lvG92ein.mjs} +4 -4
- package/.output/server/chunks/build/{_uuid_-DfJaumTE.mjs.map → _uuid_-lvG92ein.mjs.map} +1 -1
- package/.output/server/chunks/build/account-LDZ4TL6x.mjs +513 -0
- package/.output/server/chunks/build/account-LDZ4TL6x.mjs.map +1 -0
- package/.output/server/chunks/build/app-CGhRZPNT.mjs +252 -0
- package/.output/server/chunks/build/app-CGhRZPNT.mjs.map +1 -0
- package/.output/server/chunks/build/{chat-m4-n9vC6.mjs → chat-BphuYhvA.mjs} +18 -27
- package/.output/server/chunks/build/chat-BphuYhvA.mjs.map +1 -0
- package/.output/server/chunks/build/client.precomputed.mjs +1 -1
- package/.output/server/chunks/build/cookie-C_iulBi6.mjs +1 -1
- package/.output/server/chunks/build/{dashboard-CiVTAZuF.mjs → dashboard-nDujDyOg.mjs} +55 -16
- package/.output/server/chunks/build/{dashboard-CiVTAZuF.mjs.map → dashboard-nDujDyOg.mjs.map} +1 -1
- package/.output/server/chunks/build/{docs-ChGwOPg5.mjs → docs-Bwucwp0r.mjs} +664 -592
- package/.output/server/chunks/build/docs-Bwucwp0r.mjs.map +1 -0
- package/.output/server/chunks/build/fetch-BB7Qzkwe.mjs +1 -1
- package/.output/server/chunks/build/{hooks-D328DcO6.mjs → hooks-D6PmTth8.mjs} +19 -29
- package/.output/server/chunks/build/hooks-D6PmTth8.mjs.map +1 -0
- package/.output/server/chunks/build/{index-CAnGTRlu.mjs → index-CJkn2jiM.mjs} +2 -2
- package/.output/server/chunks/build/{index-CAnGTRlu.mjs.map → index-CJkn2jiM.mjs.map} +1 -1
- package/.output/server/chunks/build/index-CxDxc9fm.mjs +1 -1
- package/.output/server/chunks/build/index-Cz9Y6NwN.mjs +723 -0
- package/.output/server/chunks/build/index-Cz9Y6NwN.mjs.map +1 -0
- package/.output/server/chunks/build/index-hwhuKhuZ.mjs +76 -0
- package/.output/server/chunks/build/index-hwhuKhuZ.mjs.map +1 -0
- package/.output/server/chunks/build/integrations-D5JWURiJ.mjs +1499 -0
- package/.output/server/chunks/build/integrations-D5JWURiJ.mjs.map +1 -0
- package/.output/server/chunks/build/{library-Aeg7_Lsb.mjs → library-DxRdgP6X.mjs} +2 -2
- package/.output/server/chunks/build/{library-Aeg7_Lsb.mjs.map → library-DxRdgP6X.mjs.map} +1 -1
- package/.output/server/chunks/build/{login-DnnElTl2.mjs → login-BmER_VoU.mjs} +2 -2
- package/.output/server/chunks/build/{login-DnnElTl2.mjs.map → login-BmER_VoU.mjs.map} +1 -1
- package/.output/server/chunks/build/manage-secrets-BWzqc_-f.mjs +669 -0
- package/.output/server/chunks/build/manage-secrets-BWzqc_-f.mjs.map +1 -0
- package/.output/server/chunks/build/server.mjs +65 -34
- package/.output/server/chunks/build/server.mjs.map +1 -1
- package/.output/server/chunks/build/settings-neokAVE5.mjs +154 -0
- package/.output/server/chunks/build/settings-neokAVE5.mjs.map +1 -0
- package/.output/server/chunks/build/styles.mjs +2 -2
- package/.output/server/chunks/build/{tasks-DnAFqbtt.mjs → tasks-CnpIQNpS.mjs} +27 -37
- package/.output/server/chunks/build/tasks-CnpIQNpS.mjs.map +1 -0
- package/.output/server/chunks/build/{useAgents-DHEXiFSc.mjs → useAgents-nmbkB9-_.mjs} +5 -26
- package/.output/server/chunks/build/useAgents-nmbkB9-_.mjs.map +1 -0
- package/.output/server/chunks/build/{view-n2sYa4Zh.mjs → view-mb0ISqfM.mjs} +3 -3
- package/.output/server/chunks/build/{view-n2sYa4Zh.mjs.map → view-mb0ISqfM.mjs.map} +1 -1
- package/.output/server/chunks/nitro/nitro.mjs +1000 -858
- package/.output/server/chunks/nitro/nitro.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.get.mjs +17 -2
- package/.output/server/chunks/routes/api/index.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.get3.mjs +21 -3
- package/.output/server/chunks/routes/api/index.get3.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.get4.mjs +10 -9
- package/.output/server/chunks/routes/api/index.get4.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.get9.mjs +10 -8
- package/.output/server/chunks/routes/api/index.get9.mjs.map +1 -1
- package/.output/server/chunks/routes/api/memory/search.get.mjs +10 -5
- package/.output/server/chunks/routes/api/memory/search.get.mjs.map +1 -1
- package/.output/server/chunks/routes/renderer.mjs +1 -1
- package/.output/server/index.mjs +1 -1
- package/.output/server/package.json +1 -1
- package/app/components/AssistantPanel.client.vue +16 -314
- package/app/components/agents/AgentCard.vue +111 -0
- package/app/components/agents/AgentInfoCard.vue +54 -0
- package/app/components/agents/AgentRunHistory.vue +103 -0
- package/app/components/agents/AgentRunModal.vue +1 -24
- package/app/components/agents/AgentStatsCards.vue +1 -26
- package/app/components/assistant/AssistantChat.vue +156 -0
- package/app/components/assistant/AssistantTerminal.client.vue +178 -0
- package/app/components/chat/ConversationList.vue +2 -12
- package/app/components/files/FileTree.vue +23 -202
- package/app/components/files/FileTreeModals.vue +226 -0
- package/app/components/hooks/HookStatsCards.vue +1 -6
- package/app/components/hooks/ToolBreakdownTable.vue +1 -6
- package/app/components/search/DashboardSearch.vue +38 -1
- package/app/components/tasks/TaskCard.vue +2 -7
- package/app/components/tasks/TaskDetail.vue +4 -9
- package/app/composables/useSearch.ts +21 -11
- package/app/layouts/dashboard.vue +1 -1
- package/app/pages/agents/[id].vue +6 -197
- package/app/pages/agents/index.vue +9 -142
- package/app/pages/settings/account.vue +243 -0
- package/app/pages/settings/app.vue +230 -0
- package/app/pages/settings/index.vue +12 -0
- package/app/pages/settings/integrations.vue +794 -0
- package/app/pages/settings/manage-secrets.vue +295 -0
- package/app/pages/settings.vue +20 -1581
- package/dist/cli/index.js +26 -2
- package/package.json +1 -1
- package/server/api/agents/index.get.ts +20 -1
- package/server/api/conversations/index.get.ts +23 -5
- package/server/api/documents/index.get.ts +11 -9
- package/server/api/memory/search.get.ts +11 -6
- package/server/api/tasks/index.get.ts +11 -9
- package/server/drizzle/migrations/0016_full_text_search.sql +127 -0
- package/server/drizzle/migrations/meta/_journal.json +7 -0
- package/shared/types/index.ts +7 -1
- package/shared/utils/formatting.ts +105 -0
- package/.output/public/_nuxt/4ALIM-zZ.js +0 -1
- package/.output/public/_nuxt/5sUbkh_6.js +0 -16
- package/.output/public/_nuxt/6bB8Ev7a.js +0 -1
- package/.output/public/_nuxt/7rT1DCe2.js +0 -1
- package/.output/public/_nuxt/B2PqR2Vu.js +0 -1
- package/.output/public/_nuxt/B5FuOh7E.js +0 -1
- package/.output/public/_nuxt/B6om4MW2.js +0 -1
- package/.output/public/_nuxt/B7ikW4eF.js +0 -1
- package/.output/public/_nuxt/B9kWNcU7.js +0 -1
- package/.output/public/_nuxt/BAZ8sewA.js +0 -1
- package/.output/public/_nuxt/BCPwL4ma.js +0 -1
- package/.output/public/_nuxt/BCrlmHh_.js +0 -1
- package/.output/public/_nuxt/BD-AFJWW.js +0 -1
- package/.output/public/_nuxt/BGcQMReV.js +0 -1
- package/.output/public/_nuxt/BNJJSRKh.js +0 -1
- package/.output/public/_nuxt/BNeeERBt.js +0 -1
- package/.output/public/_nuxt/BSJb5amZ.js +0 -1
- package/.output/public/_nuxt/BSsaE9Db.js +0 -1
- package/.output/public/_nuxt/BVO3XpHT.js +0 -1
- package/.output/public/_nuxt/B_Lr1vlV.js +0 -1
- package/.output/public/_nuxt/Bl0qBhCG.js +0 -1
- package/.output/public/_nuxt/Bl43dkDq.js +0 -1
- package/.output/public/_nuxt/BnMTFF5R.js +0 -1
- package/.output/public/_nuxt/BtV7oNn3.js +0 -1
- package/.output/public/_nuxt/BvFYnRMR.js +0 -1
- package/.output/public/_nuxt/BvTUBUNN.js +0 -1
- package/.output/public/_nuxt/ByLsRRoQ.js +0 -1
- package/.output/public/_nuxt/C1LcEMwB.js +0 -1
- package/.output/public/_nuxt/C2IiXp9N.js +0 -2
- package/.output/public/_nuxt/C796kFT9.js +0 -1
- package/.output/public/_nuxt/C8AtdrMH.js +0 -1
- package/.output/public/_nuxt/CAWbHTgy.js +0 -1
- package/.output/public/_nuxt/CJPrV25_.js +0 -1
- package/.output/public/_nuxt/CKKEWapF.js +0 -1
- package/.output/public/_nuxt/CNjv28J2.js +0 -1
- package/.output/public/_nuxt/CT8s4rqa.js +0 -1
- package/.output/public/_nuxt/CZSOrxUy.js +0 -1
- package/.output/public/_nuxt/CaNEL9JC.js +0 -39
- package/.output/public/_nuxt/CbTLg9oX.js +0 -1
- package/.output/public/_nuxt/CfCXpVn5.js +0 -1
- package/.output/public/_nuxt/ChmNlvWR.js +0 -1
- package/.output/public/_nuxt/Ck0QYdxe.js +0 -1
- package/.output/public/_nuxt/Ckb0pu4-.js +0 -1
- package/.output/public/_nuxt/CkwPRs1D.js +0 -1
- package/.output/public/_nuxt/CmEJg8C6.js +0 -2
- package/.output/public/_nuxt/CmL_vMJD.js +0 -1
- package/.output/public/_nuxt/Cq8zPxkT.js +0 -1
- package/.output/public/_nuxt/CxRnB4NC.js +0 -1
- package/.output/public/_nuxt/D0zMyG8n.js +0 -1
- package/.output/public/_nuxt/D1XYB283.js +0 -1
- package/.output/public/_nuxt/D2NxqyzW.js +0 -1
- package/.output/public/_nuxt/D5xyrvFu.js +0 -1
- package/.output/public/_nuxt/D8iBB0Py.js +0 -1
- package/.output/public/_nuxt/D8oIH8m1.js +0 -1
- package/.output/public/_nuxt/DB2zZev7.js +0 -1
- package/.output/public/_nuxt/DBrOAqkm.js +0 -1
- package/.output/public/_nuxt/DDXDFweK.js +0 -1
- package/.output/public/_nuxt/DFZkCmLQ.js +0 -1
- package/.output/public/_nuxt/DKZmgHNU.js +0 -1
- package/.output/public/_nuxt/DR8tGJhL.js +0 -1
- package/.output/public/_nuxt/DVAEVTjy.js +0 -1
- package/.output/public/_nuxt/DVqrPkCJ.js +0 -1
- package/.output/public/_nuxt/DWZ9ieYa.js +0 -1
- package/.output/public/_nuxt/DWj6VsZv.js +0 -1
- package/.output/public/_nuxt/DXJ9PxCv.js +0 -1
- package/.output/public/_nuxt/D_ziPROx.js +0 -1
- package/.output/public/_nuxt/Da2vwoYG.js +0 -1
- package/.output/public/_nuxt/Ddz3HcBB.js +0 -1
- package/.output/public/_nuxt/DgYei0bK.js +0 -1
- package/.output/public/_nuxt/Di_3GV_R.js +0 -1
- package/.output/public/_nuxt/Djog1f_e.js +0 -1
- package/.output/public/_nuxt/Dkap2-Pj.js +0 -7
- package/.output/public/_nuxt/DlJe_sHk.js +0 -1
- package/.output/public/_nuxt/DlPOQpH_.js +0 -1
- package/.output/public/_nuxt/DmYWMtVA.js +0 -1
- package/.output/public/_nuxt/DmxKU7sH.js +0 -1
- package/.output/public/_nuxt/DsodHRrQ.js +0 -1
- package/.output/public/_nuxt/DwSY6_2U.js +0 -1
- package/.output/public/_nuxt/DypJaSm-.js +0 -1
- package/.output/public/_nuxt/DzKaXH6P.js +0 -1
- package/.output/public/_nuxt/FK-jSuOT.js +0 -1
- package/.output/public/_nuxt/Fc2JsQt4.js +0 -1
- package/.output/public/_nuxt/IYCBGuRS.js +0 -1
- package/.output/public/_nuxt/NrRzUJNY.js +0 -1
- package/.output/public/_nuxt/OeVS0Rsb.js +0 -1
- package/.output/public/_nuxt/OlF0QnKF.js +0 -1
- package/.output/public/_nuxt/QuAoqY7t.js +0 -1
- package/.output/public/_nuxt/RlXHkmOd.js +0 -9
- package/.output/public/_nuxt/WZnvL9Dh.js +0 -1
- package/.output/public/_nuxt/ZvG7a1W3.js +0 -1
- package/.output/public/_nuxt/aPNZBVrG.js +0 -1
- package/.output/public/_nuxt/builds/meta/495aca73-bfa5-456e-b96a-f02e009c72d3.json +0 -1
- package/.output/public/_nuxt/dashboard.BxCOkJwt.css +0 -1
- package/.output/public/_nuxt/entry.C_udkZt9.css +0 -1
- package/.output/public/_nuxt/evY81hM3.js +0 -1
- package/.output/public/_nuxt/i6QBzaEi.js +0 -1
- package/.output/public/_nuxt/iTVKJ1kw.js +0 -1
- package/.output/public/_nuxt/j92uR3uR.js +0 -1
- package/.output/public/_nuxt/jdUkeAj_.js +0 -1
- package/.output/public/_nuxt/jeRvcMHU.js +0 -1
- package/.output/public/_nuxt/kuv0zpKq.js +0 -1
- package/.output/public/_nuxt/l3lKQs7b.js +0 -1
- package/.output/public/_nuxt/qIgZ7OXa.js +0 -1
- package/.output/public/_nuxt/qcVwZv8e.js +0 -1
- package/.output/public/_nuxt/ru8fqqWs.js +0 -1
- package/.output/public/_nuxt/sgmhgpCS.js +0 -1
- package/.output/public/_nuxt/y2jv0da-.js +0 -1
- package/.output/public/_nuxt/yyS4-kAX.js +0 -1
- package/.output/public/_nuxt/zIoBLBHF.js +0 -1
- package/.output/public/_nuxt/zpazwPgx.js +0 -1
- package/.output/server/chunks/build/_id_-DN00UDdO.mjs.map +0 -1
- package/.output/server/chunks/build/chat-m4-n9vC6.mjs.map +0 -1
- package/.output/server/chunks/build/docs-ChGwOPg5.mjs.map +0 -1
- package/.output/server/chunks/build/hooks-D328DcO6.mjs.map +0 -1
- package/.output/server/chunks/build/index-C9PuieXh.mjs +0 -820
- package/.output/server/chunks/build/index-C9PuieXh.mjs.map +0 -1
- package/.output/server/chunks/build/settings-B2KXoGcz.mjs +0 -3232
- package/.output/server/chunks/build/settings-B2KXoGcz.mjs.map +0 -1
- package/.output/server/chunks/build/tasks-DnAFqbtt.mjs.map +0 -1
- package/.output/server/chunks/build/useAgents-DHEXiFSc.mjs.map +0 -1
|
@@ -1,9 +1,4 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import { Terminal } from '@xterm/xterm'
|
|
3
|
-
import { FitAddon } from '@xterm/addon-fit'
|
|
4
|
-
import { WebLinksAddon } from '@xterm/addon-web-links'
|
|
5
|
-
import '@xterm/xterm/css/xterm.css'
|
|
6
|
-
|
|
7
2
|
// --- Route ---
|
|
8
3
|
const route = useRoute()
|
|
9
4
|
const isChatPage = computed(() => route.path === '/chat')
|
|
@@ -11,8 +6,7 @@ const isChatPage = computed(() => route.path === '/chat')
|
|
|
11
6
|
// --- Preferences ---
|
|
12
7
|
const {
|
|
13
8
|
assistantPanelOpen,
|
|
14
|
-
assistantPanelTab
|
|
15
|
-
assistantLastConversationId
|
|
9
|
+
assistantPanelTab
|
|
16
10
|
} = usePreferences()
|
|
17
11
|
|
|
18
12
|
const isOpen = ref(assistantPanelOpen.value)
|
|
@@ -31,100 +25,23 @@ const tabItems = [
|
|
|
31
25
|
{ label: 'Terminal', icon: 'i-lucide-terminal', value: 'terminal' }
|
|
32
26
|
]
|
|
33
27
|
|
|
34
|
-
// ---
|
|
35
|
-
const {
|
|
36
|
-
connectionStatus: chatConnectionStatus,
|
|
37
|
-
sessionStatus,
|
|
38
|
-
activeConversationId,
|
|
39
|
-
messages,
|
|
40
|
-
conversations,
|
|
41
|
-
streamingText,
|
|
42
|
-
streamingToolCalls,
|
|
43
|
-
loading: chatLoading,
|
|
44
|
-
connect: connectChat,
|
|
45
|
-
sendMessage,
|
|
46
|
-
interrupt,
|
|
47
|
-
startNewConversation,
|
|
48
|
-
loadConversation,
|
|
49
|
-
loadConversations
|
|
50
|
-
} = useChat()
|
|
51
|
-
|
|
52
|
-
const messagesContainer = ref<HTMLElement | null>(null)
|
|
53
|
-
|
|
54
|
-
const conversationItems = computed(() =>
|
|
55
|
-
conversations.value.map(c => ({
|
|
56
|
-
label: c.title || `Chat ${new Date(c.startedAt).toLocaleDateString()}`,
|
|
57
|
-
value: c.id
|
|
58
|
-
}))
|
|
59
|
-
)
|
|
60
|
-
|
|
61
|
-
const selectedConversationId = ref<string | undefined>(
|
|
62
|
-
assistantLastConversationId.value ?? undefined
|
|
63
|
-
)
|
|
64
|
-
|
|
65
|
-
// Sync selection to preference cookie, only load if user picked a different conversation
|
|
66
|
-
watch(selectedConversationId, (id) => {
|
|
67
|
-
assistantLastConversationId.value = id ?? null
|
|
68
|
-
if (id && id !== activeConversationId.value)
|
|
69
|
-
loadConversation(id)
|
|
70
|
-
})
|
|
71
|
-
|
|
72
|
-
// Sync when a new conversation is created via chat:session_created
|
|
73
|
-
watch(activeConversationId, (id) => {
|
|
74
|
-
if (id) selectedConversationId.value = id
|
|
75
|
-
})
|
|
76
|
-
|
|
77
|
-
function handleSend(message: string) {
|
|
78
|
-
sendMessage(message)
|
|
79
|
-
nextTick(scrollToBottom)
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
function handleNewChat() {
|
|
83
|
-
startNewConversation()
|
|
84
|
-
selectedConversationId.value = undefined
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
function scrollToBottom() {
|
|
88
|
-
if (messagesContainer.value)
|
|
89
|
-
messagesContainer.value.scrollTop = messagesContainer.value.scrollHeight
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
watch(streamingText, () => nextTick(scrollToBottom))
|
|
93
|
-
watch(() => messages.value.length, () => nextTick(scrollToBottom))
|
|
28
|
+
// --- Status icons (from child refs) ---
|
|
29
|
+
const terminalRef = ref<{ status: string } | null>(null)
|
|
94
30
|
|
|
95
|
-
|
|
96
|
-
connectChat()
|
|
97
|
-
loadConversations()
|
|
98
|
-
if (assistantLastConversationId.value && !activeConversationId.value)
|
|
99
|
-
loadConversation(assistantLastConversationId.value)
|
|
100
|
-
}
|
|
31
|
+
const { connectionStatus: chatConnectionStatus } = useChat()
|
|
101
32
|
|
|
102
|
-
|
|
103
|
-
const terminalRef = ref<HTMLDivElement | null>(null)
|
|
104
|
-
const terminal = ref<Terminal | null>(null)
|
|
105
|
-
const fitAddon = ref<FitAddon | null>(null)
|
|
106
|
-
const terminalInitialized = ref(false)
|
|
33
|
+
const terminalStatus = computed(() => terminalRef.value?.status ?? 'disconnected')
|
|
107
34
|
|
|
108
|
-
const {
|
|
109
|
-
|
|
110
|
-
connect: connectTerminal,
|
|
111
|
-
disconnect: disconnectTerminal,
|
|
112
|
-
sendInput,
|
|
113
|
-
sendResize,
|
|
114
|
-
startPingInterval,
|
|
115
|
-
stopPingInterval
|
|
116
|
-
} = useTerminal()
|
|
117
|
-
|
|
118
|
-
const terminalStatusIcon = computed(() => {
|
|
119
|
-
switch (terminalStatus.value) {
|
|
35
|
+
const chatStatusIcon = computed(() => {
|
|
36
|
+
switch (chatConnectionStatus.value) {
|
|
120
37
|
case 'connected': return 'i-lucide-wifi'
|
|
121
38
|
case 'connecting': return 'i-lucide-loader-2'
|
|
122
39
|
default: return 'i-lucide-wifi-off'
|
|
123
40
|
}
|
|
124
41
|
})
|
|
125
42
|
|
|
126
|
-
const
|
|
127
|
-
switch (
|
|
43
|
+
const terminalStatusIcon = computed(() => {
|
|
44
|
+
switch (terminalStatus.value) {
|
|
128
45
|
case 'connected': return 'i-lucide-wifi'
|
|
129
46
|
case 'connecting': return 'i-lucide-loader-2'
|
|
130
47
|
default: return 'i-lucide-wifi-off'
|
|
@@ -138,119 +55,6 @@ function statusClasses(status: string) {
|
|
|
138
55
|
(status === 'error' || status === 'disconnected') && 'text-muted'
|
|
139
56
|
]
|
|
140
57
|
}
|
|
141
|
-
|
|
142
|
-
function initTerminal() {
|
|
143
|
-
if (!terminalRef.value || terminalInitialized.value) return
|
|
144
|
-
|
|
145
|
-
const term = new Terminal({
|
|
146
|
-
cursorBlink: true,
|
|
147
|
-
fontSize: 14,
|
|
148
|
-
fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace',
|
|
149
|
-
theme: {
|
|
150
|
-
background: '#1a1a1a',
|
|
151
|
-
foreground: '#e5e5e5',
|
|
152
|
-
cursor: '#e5e5e5',
|
|
153
|
-
cursorAccent: '#1a1a1a',
|
|
154
|
-
selectionBackground: '#3b3b3b',
|
|
155
|
-
black: '#1a1a1a',
|
|
156
|
-
red: '#ff5555',
|
|
157
|
-
green: '#50fa7b',
|
|
158
|
-
yellow: '#f1fa8c',
|
|
159
|
-
blue: '#6272a4',
|
|
160
|
-
magenta: '#ff79c6',
|
|
161
|
-
cyan: '#8be9fd',
|
|
162
|
-
white: '#e5e5e5',
|
|
163
|
-
brightBlack: '#4d4d4d',
|
|
164
|
-
brightRed: '#ff6e6e',
|
|
165
|
-
brightGreen: '#69ff94',
|
|
166
|
-
brightYellow: '#ffffa5',
|
|
167
|
-
brightBlue: '#d6acff',
|
|
168
|
-
brightMagenta: '#ff92df',
|
|
169
|
-
brightCyan: '#a4ffff',
|
|
170
|
-
brightWhite: '#ffffff'
|
|
171
|
-
}
|
|
172
|
-
})
|
|
173
|
-
|
|
174
|
-
const fit = new FitAddon()
|
|
175
|
-
fitAddon.value = fit
|
|
176
|
-
|
|
177
|
-
term.loadAddon(fit)
|
|
178
|
-
term.loadAddon(new WebLinksAddon())
|
|
179
|
-
|
|
180
|
-
term.open(terminalRef.value)
|
|
181
|
-
fit.fit()
|
|
182
|
-
|
|
183
|
-
terminal.value = term
|
|
184
|
-
terminalInitialized.value = true
|
|
185
|
-
|
|
186
|
-
term.onData((data) => {
|
|
187
|
-
sendInput(data)
|
|
188
|
-
})
|
|
189
|
-
term.onResize(({ cols, rows }) => {
|
|
190
|
-
sendResize(cols, rows)
|
|
191
|
-
})
|
|
192
|
-
|
|
193
|
-
connectTerminal(term)
|
|
194
|
-
startPingInterval()
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
function handleTerminalResize() {
|
|
198
|
-
if (fitAddon.value && terminal.value)
|
|
199
|
-
fitAddon.value.fit()
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
function handleTerminalReconnect() {
|
|
203
|
-
if (terminalStatus.value === 'connecting') return
|
|
204
|
-
if (!terminalInitialized.value) {
|
|
205
|
-
nextTick(initTerminal)
|
|
206
|
-
return
|
|
207
|
-
}
|
|
208
|
-
if (terminal.value)
|
|
209
|
-
connectTerminal(terminal.value)
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
let resizeObserver: ResizeObserver | null = null
|
|
213
|
-
|
|
214
|
-
function setupTerminal() {
|
|
215
|
-
if (!terminalInitialized.value) {
|
|
216
|
-
initTerminal()
|
|
217
|
-
if (terminalRef.value) {
|
|
218
|
-
resizeObserver = new ResizeObserver(() => handleTerminalResize())
|
|
219
|
-
resizeObserver.observe(terminalRef.value)
|
|
220
|
-
}
|
|
221
|
-
} else {
|
|
222
|
-
handleTerminalResize()
|
|
223
|
-
terminal.value?.focus()
|
|
224
|
-
}
|
|
225
|
-
}
|
|
226
|
-
|
|
227
|
-
// --- Lifecycle ---
|
|
228
|
-
watch(isOpen, (open) => {
|
|
229
|
-
if (open) {
|
|
230
|
-
if (activeTab.value === 'chat') setupChat()
|
|
231
|
-
else nextTick(setupTerminal)
|
|
232
|
-
}
|
|
233
|
-
})
|
|
234
|
-
|
|
235
|
-
watch(activeTab, (tab) => {
|
|
236
|
-
if (!isOpen.value) return
|
|
237
|
-
if (tab === 'chat') setupChat()
|
|
238
|
-
else nextTick(setupTerminal)
|
|
239
|
-
})
|
|
240
|
-
|
|
241
|
-
onMounted(() => {
|
|
242
|
-
if (isOpen.value) {
|
|
243
|
-
if (activeTab.value === 'chat') setupChat()
|
|
244
|
-
else nextTick(setupTerminal)
|
|
245
|
-
}
|
|
246
|
-
})
|
|
247
|
-
|
|
248
|
-
onUnmounted(() => {
|
|
249
|
-
stopPingInterval()
|
|
250
|
-
disconnectTerminal()
|
|
251
|
-
if (resizeObserver) resizeObserver.disconnect()
|
|
252
|
-
if (terminal.value) terminal.value.dispose()
|
|
253
|
-
})
|
|
254
58
|
</script>
|
|
255
59
|
|
|
256
60
|
<template>
|
|
@@ -307,111 +111,17 @@ onUnmounted(() => {
|
|
|
307
111
|
</div>
|
|
308
112
|
|
|
309
113
|
<!-- Chat tab -->
|
|
310
|
-
<
|
|
114
|
+
<AssistantAssistantChat
|
|
311
115
|
v-show="activeTab === 'chat'"
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
<!-- Conversation selector -->
|
|
315
|
-
<div class="flex items-center gap-2 px-3 py-2 border-b border-default">
|
|
316
|
-
<USelectMenu
|
|
317
|
-
v-model="selectedConversationId"
|
|
318
|
-
:items="conversationItems"
|
|
319
|
-
value-key="value"
|
|
320
|
-
placeholder="New conversation"
|
|
321
|
-
size="xs"
|
|
322
|
-
class="flex-1"
|
|
323
|
-
icon="i-lucide-messages-square"
|
|
324
|
-
/>
|
|
325
|
-
<UButton
|
|
326
|
-
icon="i-lucide-plus"
|
|
327
|
-
size="xs"
|
|
328
|
-
color="primary"
|
|
329
|
-
variant="soft"
|
|
330
|
-
@click="handleNewChat"
|
|
331
|
-
/>
|
|
332
|
-
</div>
|
|
333
|
-
|
|
334
|
-
<!-- Messages -->
|
|
335
|
-
<div
|
|
336
|
-
ref="messagesContainer"
|
|
337
|
-
class="relative flex-1 overflow-y-auto p-3 space-y-3"
|
|
338
|
-
>
|
|
339
|
-
<!-- Loading overlay -->
|
|
340
|
-
<div
|
|
341
|
-
v-if="chatLoading"
|
|
342
|
-
class="absolute inset-0 flex items-center justify-center bg-elevated/80 z-10"
|
|
343
|
-
>
|
|
344
|
-
<UIcon
|
|
345
|
-
name="i-lucide-loader-2"
|
|
346
|
-
class="size-6 animate-spin text-primary"
|
|
347
|
-
/>
|
|
348
|
-
</div>
|
|
349
|
-
|
|
350
|
-
<div
|
|
351
|
-
v-if="messages.length === 0 && sessionStatus !== 'streaming' && !chatLoading"
|
|
352
|
-
class="flex flex-col items-center justify-center h-full text-dimmed"
|
|
353
|
-
>
|
|
354
|
-
<UIcon
|
|
355
|
-
name="i-lucide-message-square"
|
|
356
|
-
class="size-8 mb-2"
|
|
357
|
-
/>
|
|
358
|
-
<p class="text-sm">
|
|
359
|
-
Send a message to start chatting
|
|
360
|
-
</p>
|
|
361
|
-
</div>
|
|
362
|
-
|
|
363
|
-
<ChatMessageBubble
|
|
364
|
-
v-for="msg in messages"
|
|
365
|
-
:key="msg.id"
|
|
366
|
-
:message="msg"
|
|
367
|
-
/>
|
|
368
|
-
|
|
369
|
-
<ChatStreamingMessage
|
|
370
|
-
v-if="sessionStatus === 'streaming'"
|
|
371
|
-
:text="streamingText"
|
|
372
|
-
:tool-calls="streamingToolCalls"
|
|
373
|
-
/>
|
|
374
|
-
</div>
|
|
375
|
-
|
|
376
|
-
<!-- Input -->
|
|
377
|
-
<ChatInput
|
|
378
|
-
:session-status="sessionStatus"
|
|
379
|
-
:connection-status="chatConnectionStatus"
|
|
380
|
-
@send="handleSend"
|
|
381
|
-
@interrupt="interrupt"
|
|
382
|
-
/>
|
|
383
|
-
</div>
|
|
116
|
+
:active="isOpen && activeTab === 'chat'"
|
|
117
|
+
/>
|
|
384
118
|
|
|
385
119
|
<!-- Terminal tab -->
|
|
386
|
-
<
|
|
120
|
+
<AssistantAssistantTerminal
|
|
387
121
|
v-show="activeTab === 'terminal'"
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
<div class="flex items-center gap-2 text-muted text-xs">
|
|
392
|
-
<UIcon
|
|
393
|
-
:name="terminalStatusIcon"
|
|
394
|
-
:class="['size-3.5', ...statusClasses(terminalStatus)]"
|
|
395
|
-
/>
|
|
396
|
-
<span>{{ terminalStatus === 'connected' ? 'Connected' : terminalStatus === 'connecting' ? 'Connecting...' : terminalStatus === 'error' ? 'Connection error' : 'Disconnected' }}</span>
|
|
397
|
-
</div>
|
|
398
|
-
<UButton
|
|
399
|
-
v-if="terminalStatus === 'disconnected' || terminalStatus === 'error'"
|
|
400
|
-
size="xs"
|
|
401
|
-
color="neutral"
|
|
402
|
-
variant="ghost"
|
|
403
|
-
icon="i-lucide-refresh-cw"
|
|
404
|
-
@click="handleTerminalReconnect"
|
|
405
|
-
>
|
|
406
|
-
Reconnect
|
|
407
|
-
</UButton>
|
|
408
|
-
</div>
|
|
409
|
-
|
|
410
|
-
<div
|
|
411
|
-
ref="terminalRef"
|
|
412
|
-
class="flex-1 p-1 bg-[#1a1a1a]"
|
|
413
|
-
/>
|
|
414
|
-
</div>
|
|
122
|
+
ref="terminalRef"
|
|
123
|
+
:active="isOpen && activeTab === 'terminal'"
|
|
124
|
+
/>
|
|
415
125
|
</div>
|
|
416
126
|
</Transition>
|
|
417
127
|
</div>
|
|
@@ -427,14 +137,6 @@ onUnmounted(() => {
|
|
|
427
137
|
max-height: 80vh;
|
|
428
138
|
}
|
|
429
139
|
|
|
430
|
-
.xterm {
|
|
431
|
-
height: 100%;
|
|
432
|
-
}
|
|
433
|
-
|
|
434
|
-
.xterm-viewport {
|
|
435
|
-
overflow-y: auto !important;
|
|
436
|
-
}
|
|
437
|
-
|
|
438
140
|
/* Compact prose for chat bubbles */
|
|
439
141
|
.chat-prose {
|
|
440
142
|
font-size: 0.8125rem;
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { CronAgent } from '~~/shared/types'
|
|
3
|
+
import { formatSchedule, formatRelativeTime, getStatusColor } from '~~/shared/utils/formatting'
|
|
4
|
+
|
|
5
|
+
defineProps<{
|
|
6
|
+
agent: CronAgent
|
|
7
|
+
running: boolean
|
|
8
|
+
}>()
|
|
9
|
+
|
|
10
|
+
const emit = defineEmits<{
|
|
11
|
+
toggle: [id: string]
|
|
12
|
+
run: [id: string, event: Event]
|
|
13
|
+
cancel: [id: string, event: Event]
|
|
14
|
+
edit: [agent: CronAgent, event: Event]
|
|
15
|
+
navigate: [agent: CronAgent]
|
|
16
|
+
}>()
|
|
17
|
+
</script>
|
|
18
|
+
|
|
19
|
+
<template>
|
|
20
|
+
<UCard
|
|
21
|
+
class="cursor-pointer transition-all hover:ring-2 hover:ring-primary/50"
|
|
22
|
+
@click="emit('navigate', agent)"
|
|
23
|
+
>
|
|
24
|
+
<div class="flex items-start justify-between gap-4">
|
|
25
|
+
<div class="flex-1 min-w-0">
|
|
26
|
+
<div class="flex items-center gap-2">
|
|
27
|
+
<h3 class="font-medium truncate">
|
|
28
|
+
{{ agent.name }}
|
|
29
|
+
</h3>
|
|
30
|
+
<UBadge
|
|
31
|
+
v-if="running"
|
|
32
|
+
color="info"
|
|
33
|
+
variant="subtle"
|
|
34
|
+
size="sm"
|
|
35
|
+
>
|
|
36
|
+
<UIcon
|
|
37
|
+
name="i-lucide-loader-2"
|
|
38
|
+
class="w-3 h-3 animate-spin mr-1"
|
|
39
|
+
/>
|
|
40
|
+
Running
|
|
41
|
+
</UBadge>
|
|
42
|
+
<UBadge
|
|
43
|
+
v-else-if="agent.lastStatus"
|
|
44
|
+
:color="getStatusColor(agent.lastStatus)"
|
|
45
|
+
size="sm"
|
|
46
|
+
>
|
|
47
|
+
{{ agent.lastStatus }}
|
|
48
|
+
</UBadge>
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
<p
|
|
52
|
+
v-if="agent.description"
|
|
53
|
+
class="text-sm text-muted truncate mt-1"
|
|
54
|
+
>
|
|
55
|
+
{{ agent.description }}
|
|
56
|
+
</p>
|
|
57
|
+
|
|
58
|
+
<div class="flex items-center gap-4 mt-2 text-sm text-muted">
|
|
59
|
+
<span class="flex items-center gap-1">
|
|
60
|
+
<UIcon name="i-lucide-clock" />
|
|
61
|
+
{{ formatSchedule(agent.schedule) }}
|
|
62
|
+
</span>
|
|
63
|
+
<span
|
|
64
|
+
v-if="agent.lastRunAt"
|
|
65
|
+
class="flex items-center gap-1"
|
|
66
|
+
>
|
|
67
|
+
<UIcon name="i-lucide-activity" />
|
|
68
|
+
{{ formatRelativeTime(agent.lastRunAt) }}
|
|
69
|
+
</span>
|
|
70
|
+
<span
|
|
71
|
+
v-if="agent.maxBudgetUsd"
|
|
72
|
+
class="flex items-center gap-1"
|
|
73
|
+
>
|
|
74
|
+
<UIcon name="i-lucide-dollar-sign" />
|
|
75
|
+
${{ agent.maxBudgetUsd }} limit
|
|
76
|
+
</span>
|
|
77
|
+
</div>
|
|
78
|
+
</div>
|
|
79
|
+
|
|
80
|
+
<div class="flex items-center gap-2">
|
|
81
|
+
<USwitch
|
|
82
|
+
:model-value="agent.enabled"
|
|
83
|
+
@click.stop
|
|
84
|
+
@update:model-value="emit('toggle', agent.id)"
|
|
85
|
+
/>
|
|
86
|
+
<UButton
|
|
87
|
+
v-if="running"
|
|
88
|
+
icon="i-lucide-square"
|
|
89
|
+
variant="ghost"
|
|
90
|
+
size="sm"
|
|
91
|
+
color="error"
|
|
92
|
+
@click.stop="emit('cancel', agent.id, $event)"
|
|
93
|
+
/>
|
|
94
|
+
<UButton
|
|
95
|
+
v-else
|
|
96
|
+
icon="i-lucide-play"
|
|
97
|
+
variant="ghost"
|
|
98
|
+
size="sm"
|
|
99
|
+
:disabled="!agent.enabled"
|
|
100
|
+
@click.stop="emit('run', agent.id, $event)"
|
|
101
|
+
/>
|
|
102
|
+
<UButton
|
|
103
|
+
icon="i-lucide-pencil"
|
|
104
|
+
variant="ghost"
|
|
105
|
+
size="sm"
|
|
106
|
+
@click.stop="emit('edit', agent, $event)"
|
|
107
|
+
/>
|
|
108
|
+
</div>
|
|
109
|
+
</div>
|
|
110
|
+
</UCard>
|
|
111
|
+
</template>
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { CronAgent } from '~~/shared/types'
|
|
3
|
+
import { formatSchedule, formatRelativeTime } from '~~/shared/utils/formatting'
|
|
4
|
+
|
|
5
|
+
defineProps<{
|
|
6
|
+
agent: CronAgent
|
|
7
|
+
}>()
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<template>
|
|
11
|
+
<UCard>
|
|
12
|
+
<div class="space-y-3">
|
|
13
|
+
<div v-if="agent.description">
|
|
14
|
+
<p class="text-sm text-muted uppercase mb-1">
|
|
15
|
+
Description
|
|
16
|
+
</p>
|
|
17
|
+
<p>{{ agent.description }}</p>
|
|
18
|
+
</div>
|
|
19
|
+
|
|
20
|
+
<div class="flex flex-wrap gap-6">
|
|
21
|
+
<div>
|
|
22
|
+
<p class="text-sm text-muted uppercase mb-1">
|
|
23
|
+
Schedule
|
|
24
|
+
</p>
|
|
25
|
+
<p class="flex items-center gap-2">
|
|
26
|
+
<UIcon name="i-lucide-clock" />
|
|
27
|
+
{{ formatSchedule(agent.schedule) }}
|
|
28
|
+
<span class="text-sm text-muted">({{ agent.schedule }})</span>
|
|
29
|
+
</p>
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
<div v-if="agent.maxBudgetUsd">
|
|
33
|
+
<p class="text-sm text-muted uppercase mb-1">
|
|
34
|
+
Budget Limit
|
|
35
|
+
</p>
|
|
36
|
+
<p class="flex items-center gap-2">
|
|
37
|
+
<UIcon name="i-lucide-dollar-sign" />
|
|
38
|
+
${{ agent.maxBudgetUsd }} per run
|
|
39
|
+
</p>
|
|
40
|
+
</div>
|
|
41
|
+
|
|
42
|
+
<div v-if="agent.lastRunAt">
|
|
43
|
+
<p class="text-sm text-muted uppercase mb-1">
|
|
44
|
+
Last Run
|
|
45
|
+
</p>
|
|
46
|
+
<p class="flex items-center gap-2">
|
|
47
|
+
<UIcon name="i-lucide-activity" />
|
|
48
|
+
{{ formatRelativeTime(agent.lastRunAt) }}
|
|
49
|
+
</p>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
</UCard>
|
|
54
|
+
</template>
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { CronAgentRun } from '~~/shared/types'
|
|
3
|
+
import { formatDuration, formatDateTime, getStatusColor } from '~~/shared/utils/formatting'
|
|
4
|
+
|
|
5
|
+
defineProps<{
|
|
6
|
+
runs: CronAgentRun[]
|
|
7
|
+
loading: boolean
|
|
8
|
+
}>()
|
|
9
|
+
|
|
10
|
+
const emit = defineEmits<{
|
|
11
|
+
select: [run: CronAgentRun]
|
|
12
|
+
}>()
|
|
13
|
+
|
|
14
|
+
function truncateOutput(output?: string, maxLength = 100) {
|
|
15
|
+
if (!output) return '-'
|
|
16
|
+
if (output.length <= maxLength) return output
|
|
17
|
+
return output.substring(0, maxLength) + '...'
|
|
18
|
+
}
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<template>
|
|
22
|
+
<div class="space-y-4">
|
|
23
|
+
<h2 class="text-lg font-semibold">
|
|
24
|
+
Run History
|
|
25
|
+
</h2>
|
|
26
|
+
|
|
27
|
+
<!-- Loading runs -->
|
|
28
|
+
<div
|
|
29
|
+
v-if="loading"
|
|
30
|
+
class="flex items-center justify-center h-32"
|
|
31
|
+
>
|
|
32
|
+
<UIcon
|
|
33
|
+
name="i-lucide-loader-2"
|
|
34
|
+
class="w-6 h-6 animate-spin text-neutral-400"
|
|
35
|
+
/>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
<!-- Empty state -->
|
|
39
|
+
<div
|
|
40
|
+
v-else-if="runs.length === 0"
|
|
41
|
+
class="flex flex-col items-center justify-center h-32 text-neutral-500"
|
|
42
|
+
>
|
|
43
|
+
<UIcon
|
|
44
|
+
name="i-lucide-history"
|
|
45
|
+
class="w-8 h-8 mb-2"
|
|
46
|
+
/>
|
|
47
|
+
<p>No runs yet</p>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<!-- Run list -->
|
|
51
|
+
<div
|
|
52
|
+
v-else
|
|
53
|
+
class="space-y-2"
|
|
54
|
+
>
|
|
55
|
+
<UCard
|
|
56
|
+
v-for="run in runs"
|
|
57
|
+
:key="run.id"
|
|
58
|
+
class="cursor-pointer transition-all hover:ring-2 hover:ring-primary/50"
|
|
59
|
+
@click="emit('select', run)"
|
|
60
|
+
>
|
|
61
|
+
<div class="flex items-start justify-between gap-4">
|
|
62
|
+
<div class="flex-1 min-w-0">
|
|
63
|
+
<div class="flex items-center gap-2 mb-1">
|
|
64
|
+
<UBadge
|
|
65
|
+
v-if="run.status === 'running'"
|
|
66
|
+
color="info"
|
|
67
|
+
variant="subtle"
|
|
68
|
+
size="sm"
|
|
69
|
+
>
|
|
70
|
+
<UIcon
|
|
71
|
+
name="i-lucide-loader-2"
|
|
72
|
+
class="w-3 h-3 animate-spin mr-1"
|
|
73
|
+
/>
|
|
74
|
+
Running
|
|
75
|
+
</UBadge>
|
|
76
|
+
<UBadge
|
|
77
|
+
v-else
|
|
78
|
+
:color="getStatusColor(run.status)"
|
|
79
|
+
size="sm"
|
|
80
|
+
>
|
|
81
|
+
{{ run.status }}
|
|
82
|
+
</UBadge>
|
|
83
|
+
<span class="text-sm text-muted">
|
|
84
|
+
{{ formatDateTime(run.startedAt) }}
|
|
85
|
+
</span>
|
|
86
|
+
</div>
|
|
87
|
+
|
|
88
|
+
<p class="text-sm text-muted truncate">
|
|
89
|
+
{{ run.error ? truncateOutput(run.error) : truncateOutput(run.output) }}
|
|
90
|
+
</p>
|
|
91
|
+
</div>
|
|
92
|
+
|
|
93
|
+
<div class="text-right text-sm text-muted shrink-0">
|
|
94
|
+
<p>{{ formatDuration(run.durationMs) }}</p>
|
|
95
|
+
<p v-if="run.costUsd">
|
|
96
|
+
${{ run.costUsd.toFixed(4) }}
|
|
97
|
+
</p>
|
|
98
|
+
</div>
|
|
99
|
+
</div>
|
|
100
|
+
</UCard>
|
|
101
|
+
</div>
|
|
102
|
+
</div>
|
|
103
|
+
</template>
|
|
@@ -1,35 +1,12 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import type { CronAgentRun } from '~~/shared/types'
|
|
3
|
+
import { formatDuration, formatDateTime, getStatusColor } from '~~/shared/utils/formatting'
|
|
3
4
|
|
|
4
5
|
defineProps<{
|
|
5
6
|
run: CronAgentRun | null
|
|
6
7
|
}>()
|
|
7
8
|
|
|
8
9
|
const open = defineModel<boolean>('open', { default: false })
|
|
9
|
-
|
|
10
|
-
function formatDuration(ms?: number) {
|
|
11
|
-
if (!ms) return '-'
|
|
12
|
-
if (ms < 1000) return `${ms}ms`
|
|
13
|
-
if (ms < 60000) return `${(ms / 1000).toFixed(1)}s`
|
|
14
|
-
return `${(ms / 60000).toFixed(1)}m`
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
function formatDateTime(date?: Date | string) {
|
|
18
|
-
if (!date) return '-'
|
|
19
|
-
const d = new Date(date)
|
|
20
|
-
return d.toLocaleString()
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
function getStatusColor(status?: string) {
|
|
24
|
-
switch (status) {
|
|
25
|
-
case 'success': return 'success'
|
|
26
|
-
case 'error': return 'error'
|
|
27
|
-
case 'budget_exceeded': return 'warning'
|
|
28
|
-
case 'running': return 'info'
|
|
29
|
-
case 'cancelled': return 'neutral'
|
|
30
|
-
default: return 'neutral'
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
10
|
</script>
|
|
34
11
|
|
|
35
12
|
<template>
|