bazilion 0.13.0 → 0.14.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -5
- package/dist/cli.js +285 -86
- package/dist/cli.js.map +1 -1
- package/dist/daemon.js +539 -81
- package/dist/daemon.js.map +1 -1
- package/dist/web/client/assets/AgentTabs-BcmmwYJc.js +1 -0
- package/dist/web/client/assets/ConfigPage-BCLp-FUC.js +1 -0
- package/dist/web/client/assets/ConfirmDialog-BAiyYC8w.js +1 -0
- package/dist/web/client/assets/FieldRow-DsWhqiIQ.js +1 -0
- package/dist/web/client/assets/Page-NV96O47A.js +1 -0
- package/dist/web/client/assets/ProductionTeamPolicyEditor-CHBKZMpY.js +7 -0
- package/dist/web/client/assets/{ProfileCommunicationEditor-BcSf2Hao.js → ProfileCommunicationEditor-DZ8yTQvV.js} +1 -1
- package/dist/web/client/assets/SectionTabs-4kCQXuFY.js +1 -0
- package/dist/web/client/assets/TeamTabs-BfC1pfQe.js +1 -0
- package/dist/web/client/assets/{TemplatesTabs-CyDVzrOl.js → TemplatesTabs-BwsLjN0Q.js} +1 -1
- package/dist/web/client/assets/UnsavedChangesGuard-C7U9rsPw.js +1 -0
- package/dist/web/client/assets/{_id-DWTMH7Eb.js → _id-CG9YM1tY.js} +1 -1
- package/dist/web/client/assets/_id-DfzTSFBA.js +1 -0
- package/dist/web/client/assets/_id-DtHL-U-0.js +1 -0
- package/dist/web/client/assets/_id-J0kM-98d.js +1 -0
- package/dist/web/client/assets/activity-CBQGMwWo.js +1 -0
- package/dist/web/client/assets/agents-BWGBjF2Y.js +1 -0
- package/dist/web/client/assets/agents-DTY5RXgO.js +1 -0
- package/dist/web/client/assets/approvals-DwMk9S4Z.js +1 -0
- package/dist/web/client/assets/attention-7qYFtwOW.js +1 -0
- package/dist/web/client/assets/chevron-right-DK703skW.js +1 -0
- package/dist/web/client/assets/config-D59MT3Y5.js +3 -0
- package/dist/web/client/assets/{inbox-D2NypLee.js → inbox-CpKuNfOj.js} +1 -1
- package/dist/web/client/assets/index-BVfpuiby.js +52 -0
- package/dist/web/client/assets/learning-631_q6a9.js +1 -0
- package/dist/web/client/assets/login-JjfTCGIb.js +1 -0
- package/dist/web/client/assets/mcp-DHgUOUPG.js +1 -0
- package/dist/web/client/assets/members-CLCUdo-h.js +1 -0
- package/dist/web/client/assets/memory-paAiM6ix.js +1 -0
- package/dist/web/client/assets/{policy-CHM95pMU.js → policy-Fy_Wnq6p.js} +1 -1
- package/dist/web/client/assets/{preload-helper-mNuBjNXU.js → preload-helper-bztXdkDj.js} +1 -1
- package/dist/web/client/assets/routes-DciiC6QA.js +1 -0
- package/dist/web/client/assets/services-i_RmJYAO.js +1 -0
- package/dist/web/client/assets/skills-BX42OGpp.js +1 -0
- package/dist/web/client/assets/styles-B5vcgXln.css +2 -0
- package/dist/web/client/assets/{teams-Dm_huGxn.js → teams-4ySkP31k.js} +1 -1
- package/dist/web/client/assets/teams-D6nIPyC0.js +1 -0
- package/dist/web/client/assets/telegram-CphoIRWP.js +1 -0
- package/dist/web/client/assets/tokens-2j3NQudt.js +1 -0
- package/dist/web/client/assets/triggers-sDA075Nu.js +1 -0
- package/dist/web/client/assets/utils-B6KiDbIe.js +1 -0
- package/dist/web/client/assets/welcome-Do427w4M.js +1 -0
- package/dist/web/client/assets/wire-constants-B7b2CQp1.js +74 -0
- package/dist/web/client/assets/x-CbAF-3_T.js +1 -0
- package/dist/web/server/assets/{AgentTabs-aXdsiiMp.js → AgentTabs-Dq8hDM2Q.js} +9 -2
- package/dist/web/server/assets/{ChatPane-Ba5wTsVk.js → ChatPane-CgSe7tsy.js} +81 -43
- package/dist/web/server/assets/{ConfigPage-BKlh5vOU.js → ConfigPage-CiQ-gxmJ.js} +3 -2
- package/dist/web/server/assets/ConfirmDialog-C-MPYYSU.js +99 -0
- package/dist/web/server/assets/FieldRow-DCOF07kl.js +160 -0
- package/dist/web/server/assets/{Page-LENulSXY.js → Page-Bz-ydB8j.js} +4 -10
- package/dist/web/server/assets/{ProductionTeamPolicyEditor-Y4mzFFvR.js → ProductionTeamPolicyEditor-DQSdP7Yx.js} +140 -123
- package/dist/web/server/assets/{SectionTabs-BJTPr5nU.js → SectionTabs-B2Yw81XN.js} +2 -2
- package/dist/web/server/assets/{Sidebar-DsRVCszF.js → Sidebar-DKyk7oIo.js} +563 -283
- package/dist/web/server/assets/{TeamTabs-zZzbP1t_.js → TeamTabs-Co3n2exj.js} +2 -6
- package/dist/web/server/assets/{TemplatesTabs-CcRxZhJe.js → TemplatesTabs-B0fA361R.js} +1 -1
- package/dist/web/server/assets/UnsavedChangesGuard-CiStXyBI.js +40 -0
- package/dist/web/server/assets/{_id-xTD_6ApX.js → _id-BAA9KJBU.js} +1 -1
- package/dist/web/server/assets/{_id-BQ2zoMiR.js → _id-BM5m2FLT.js} +4 -4
- package/dist/web/server/assets/{_id-BENqNBfK.js → _id-BYKpT2Tu.js} +1 -2
- package/dist/web/server/assets/{_id-BreRHYV2.js → _id-BeKhPKw3.js} +350 -185
- package/dist/web/server/assets/{_id-CPIXIqyO.js → _id-BqWTB8Wl.js} +188 -86
- package/dist/web/server/assets/{_id-DkrNqqTw.js → _id-BwvCtzlD.js} +1 -1
- package/dist/web/server/assets/{_id-BZWunvy7.js → _id-DYU6uIBx.js} +0 -1
- package/dist/web/server/assets/{_id-BFELaMIN.js → _id-ndxFHx0t.js} +75 -71
- package/dist/web/server/assets/{_id-CvYqVJPU.js → _id-sNu5aXZt.js} +2 -1
- package/dist/web/server/assets/{_tanstack-start-manifest_v-COkJjXt_.js → _tanstack-start-manifest_v-DR7wyKcH.js} +113 -90
- package/dist/web/server/assets/{activity-B6N1T_5N.js → activity-BWv1goK6.js} +3 -3
- package/dist/web/server/assets/{activity-BazZNfvf.js → activity-LjpblbDL.js} +1 -1
- package/dist/web/server/assets/{agents-BpSeOA30.js → agents-BDFGrU3o.js} +1 -1
- package/dist/web/server/assets/{agents-DY630p6x.js → agents-CJk4pxKu.js} +1 -1
- package/dist/web/server/assets/{agents-wSYNPuyK.js → agents-CYw1xHoY.js} +138 -16
- package/dist/web/server/assets/{agents-DfoLnTyD.js → agents-DfNKc_Q7.js} +52 -8
- package/dist/web/server/assets/{approvals-BkUGmYU9.js → approvals-7JOoBchn.js} +1 -1
- package/dist/web/server/assets/{approvals-BYajNOdE.js → approvals-Bz123liE.js} +59 -21
- package/dist/web/server/assets/{attention-Bw_wiiqI.js → attention-B35JvhOL.js} +1 -1
- package/dist/web/server/assets/{attention-Z3bGuxOD.js → attention-C1pPWSXw.js} +3 -3
- package/dist/web/server/assets/{config-wYtIhkRm.js → config-DQ8n0AwF.js} +1 -1
- package/dist/web/server/assets/config-XSTLuRaT.js +980 -0
- package/dist/web/server/assets/{inbox-DTTfSuGU.js → inbox-RweGCV3D.js} +3 -3
- package/dist/web/server/assets/{inbox-0iiSg-Y1.js → inbox-cu3jLzNP.js} +1 -1
- package/dist/web/server/assets/{learning-DpyLNVe8.js → learning-BaKM6qaw.js} +1 -1
- package/dist/web/server/assets/{learning-fG8316uc.js → learning-CbtNlqYo.js} +76 -23
- package/dist/web/server/assets/{login-D_GDeTrB.js → login-BNj3U6ok.js} +21 -11
- package/dist/web/server/assets/{login-CrFVVUaE.js → login-Be8eP4Jp.js} +2 -2
- package/dist/web/server/assets/{mcp-BQtp2T87.js → mcp-B0goWO8Q.js} +1 -1
- package/dist/web/server/assets/mcp-CiBs8unU.js +332 -0
- package/dist/web/server/assets/members-DHYTVgwb.js +100 -0
- package/dist/web/server/assets/{members-DXu2oAS_.js → members-DiYtr-zm.js} +1 -1
- package/dist/web/server/assets/{memory-C6fX_FKI.js → memory-CkXUgf5s.js} +150 -48
- package/dist/web/server/assets/{memory-Iq2M0-Yc.js → memory-DTFEmfF3.js} +1 -1
- package/dist/web/server/assets/{policy-D7kj3Cy7.js → policy-BddK4xom.js} +1 -1
- package/dist/web/server/assets/{policy-Bg6u-rTq.js → policy-Bvvav8fh.js} +4 -4
- package/dist/web/server/assets/{router-D-6TzLRZ.js → router-M0lutIDA.js} +347 -173
- package/dist/web/server/assets/{routes-CiPfEldd.js → routes-BgHisAxH.js} +22 -5
- package/dist/web/server/assets/{routes-CNRzy79H.js → routes-COtkyZG1.js} +1 -1
- package/dist/web/server/assets/{routes-D933ngZS.js → routes-DAU2g7Uz.js} +1 -1
- package/dist/web/server/assets/services-ClyGBU7W.js +83 -0
- package/dist/web/server/assets/{services-OB4LAr2A.js → services-DgoU1udp.js} +1 -1
- package/dist/web/server/assets/{skills-Babb9jsQ.js → skills-CYih9TJw.js} +47 -6
- package/dist/web/server/assets/{skills-D5DQL8bM.js → skills-Dw3cI3si.js} +1 -1
- package/dist/web/server/assets/{start-uKQNK6if.js → start-D4Wq9iTa.js} +1 -1
- package/dist/web/server/assets/{teams-Dz6ZEMRo.js → teams-BJuoNOTB.js} +1 -1
- package/dist/web/server/assets/{teams-Bk6ZT0MD.js → teams-DF3RViAg.js} +3 -3
- package/dist/web/server/assets/{teams-DqC4wZxu.js → teams-DFnuc660.js} +1 -1
- package/dist/web/server/assets/{teams-Cc2Czynq.js → teams-TV6nbEN_.js} +101 -10
- package/dist/web/server/assets/{telegram-J4T0XhwQ.js → telegram-DbOFpTFm.js} +1 -1
- package/dist/web/server/assets/{telegram-DUbDIVGX.js → telegram-Dj4Wwhd6.js} +147 -47
- package/dist/web/server/assets/{tokens-CJM_0NDa.js → tokens-DDwtO15P.js} +88 -19
- package/dist/web/server/assets/{tokens-DO5BzNOn.js → tokens-_2hptHP6.js} +1 -1
- package/dist/web/server/assets/{triggers-BdBx-HwR.js → triggers-BvjYNmmY.js} +1 -1
- package/dist/web/server/assets/triggers-CHk9O3rU.js +367 -0
- package/dist/web/server/assets/utils-C_uf36nf.js +8 -0
- package/dist/web/server/assets/{welcome-DDB11L5j.js → welcome-B8nchXdF.js} +9 -8
- package/dist/web/server/server.js +5 -9
- package/dist/worker.js +64 -19
- package/dist/worker.js.map +1 -1
- package/package.json +3 -3
- package/dist/web/client/assets/AgentTabs-R6gSjIj3.js +0 -1
- package/dist/web/client/assets/ConfigPage-BCwfgyjD.js +0 -1
- package/dist/web/client/assets/FieldRow-avAFLgYW.js +0 -1
- package/dist/web/client/assets/Page-CwNuDhWz.js +0 -1
- package/dist/web/client/assets/ProductionTeamPolicyEditor-DdpYInwV.js +0 -7
- package/dist/web/client/assets/SectionTabs-DZzy01az.js +0 -1
- package/dist/web/client/assets/TeamTabs-Bk89JfN7.js +0 -1
- package/dist/web/client/assets/_id-CAJTTnee.js +0 -1
- package/dist/web/client/assets/_id-CN6jPaBu.js +0 -1
- package/dist/web/client/assets/_id-DGwJqqDc.js +0 -1
- package/dist/web/client/assets/activity-DK_M0-bn.js +0 -1
- package/dist/web/client/assets/agents-B-i5pASm.js +0 -1
- package/dist/web/client/assets/agents-n8U7qNxw.js +0 -1
- package/dist/web/client/assets/approvals-CmVxCy0Z.js +0 -1
- package/dist/web/client/assets/attention-F0lUQCWE.js +0 -1
- package/dist/web/client/assets/chevron-down-OndG7r1U.js +0 -1
- package/dist/web/client/assets/config-DuApZ9xS.js +0 -3
- package/dist/web/client/assets/context-C1sMnW6K.js +0 -1
- package/dist/web/client/assets/index-B3vdrEEg.js +0 -12
- package/dist/web/client/assets/learning-zYDCfVxT.js +0 -1
- package/dist/web/client/assets/login-B1Un51Zx.js +0 -1
- package/dist/web/client/assets/mcp-DSVmJBdv.js +0 -1
- package/dist/web/client/assets/members-Pl7hXJcN.js +0 -1
- package/dist/web/client/assets/memory-Co3BEaAq.js +0 -1
- package/dist/web/client/assets/plus-Dor-_wmL.js +0 -1
- package/dist/web/client/assets/routes-D29qjwG0.js +0 -1
- package/dist/web/client/assets/services-CCQ_6YWQ.js +0 -1
- package/dist/web/client/assets/skills-3xAIvzvP.js +0 -1
- package/dist/web/client/assets/styles-D6RPN7RK.css +0 -2
- package/dist/web/client/assets/teams-UGLyjHYj.js +0 -1
- package/dist/web/client/assets/telegram-3KvrJVO6.js +0 -1
- package/dist/web/client/assets/tokens-DUSFmV5_.js +0 -1
- package/dist/web/client/assets/triggers-DlQ2KF1h.js +0 -1
- package/dist/web/client/assets/welcome-DkP8qzK1.js +0 -1
- package/dist/web/client/assets/wire-constants-BhVKOCQa.js +0 -74
- package/dist/web/server/assets/FieldRow-B4eTegH9.js +0 -94
- package/dist/web/server/assets/config-DGzM28F_.js +0 -554
- package/dist/web/server/assets/context-BkDDwbby.js +0 -12
- package/dist/web/server/assets/context-DMc0KyHh.js +0 -12
- package/dist/web/server/assets/context-poimKI7w.js +0 -47
- package/dist/web/server/assets/mcp-DlgXUcAS.js +0 -261
- package/dist/web/server/assets/members-CteHKPSF.js +0 -46
- package/dist/web/server/assets/services-DJRA1A0-.js +0 -79
- package/dist/web/server/assets/triggers-B87fycBl.js +0 -216
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
import { a as getCookie, n as createServerFn } from "../server.js";
|
|
2
2
|
import { t as DAEMON_BASE_URL } from "./daemon-client-CI5NHwNC.js";
|
|
3
3
|
import { t as webOriginConfig } from "./public-origin-xV0lm0Ty.js";
|
|
4
|
-
import { i as BaziuLogo, n as ThemeToggle, r as PawIcon, t as Route$
|
|
4
|
+
import { i as BaziuLogo, n as ThemeToggle, r as PawIcon, t as Route$5 } from "./login-Be8eP4Jp.js";
|
|
5
5
|
import { t as createSsrRpc } from "./createSsrRpc-6LHNEsSK.js";
|
|
6
|
-
import { t as Route$
|
|
7
|
-
import { t as Route$
|
|
8
|
-
import { t as Route$
|
|
9
|
-
import { t as Route$
|
|
10
|
-
import { t as Route$
|
|
11
|
-
import { t as Route$
|
|
12
|
-
import { t as Route$
|
|
13
|
-
import { t as Route$
|
|
14
|
-
import { t as Route$
|
|
15
|
-
import { t as Route$
|
|
16
|
-
import { t as Route$
|
|
17
|
-
import { t as Route$
|
|
18
|
-
import { t as Route$
|
|
19
|
-
import { t as Route$
|
|
20
|
-
import { t as Route$
|
|
21
|
-
import { t as Route$
|
|
22
|
-
import { t as Route$
|
|
23
|
-
import { t as Route$
|
|
24
|
-
import { t as Route$
|
|
25
|
-
import { t as Route$
|
|
26
|
-
import { t as Route$
|
|
27
|
-
import { t as Route$
|
|
28
|
-
import { t as Route$
|
|
29
|
-
import { t as Route$
|
|
30
|
-
import { t as Route$29 } from "./_id-BENqNBfK.js";
|
|
6
|
+
import { t as Route$6 } from "./routes-DAU2g7Uz.js";
|
|
7
|
+
import { t as Route$7 } from "./teams-DFnuc660.js";
|
|
8
|
+
import { t as Route$8 } from "./skills-Dw3cI3si.js";
|
|
9
|
+
import { t as Route$9 } from "./config-DQ8n0AwF.js";
|
|
10
|
+
import { t as Route$10 } from "./attention-B35JvhOL.js";
|
|
11
|
+
import { t as Route$11 } from "./approvals-7JOoBchn.js";
|
|
12
|
+
import { t as Route$12 } from "./agents-BDFGrU3o.js";
|
|
13
|
+
import { t as Route$13 } from "./tokens-_2hptHP6.js";
|
|
14
|
+
import { t as Route$14 } from "./services-DgoU1udp.js";
|
|
15
|
+
import { t as Route$15 } from "./mcp-B0goWO8Q.js";
|
|
16
|
+
import { t as Route$16 } from "./teams-BJuoNOTB.js";
|
|
17
|
+
import { t as Route$17 } from "./agents-CJk4pxKu.js";
|
|
18
|
+
import { t as Route$18 } from "./_id-BAA9KJBU.js";
|
|
19
|
+
import { t as Route$19 } from "./_id-sNu5aXZt.js";
|
|
20
|
+
import { t as Route$20 } from "./policy-BddK4xom.js";
|
|
21
|
+
import { t as Route$21 } from "./memory-DTFEmfF3.js";
|
|
22
|
+
import { t as Route$22 } from "./members-DiYtr-zm.js";
|
|
23
|
+
import { t as Route$23 } from "./activity-LjpblbDL.js";
|
|
24
|
+
import { t as Route$24 } from "./telegram-DbOFpTFm.js";
|
|
25
|
+
import { t as Route$25 } from "./triggers-BvjYNmmY.js";
|
|
26
|
+
import { t as Route$26 } from "./learning-BaKM6qaw.js";
|
|
27
|
+
import { t as Route$27 } from "./inbox-cu3jLzNP.js";
|
|
28
|
+
import { t as Route$28 } from "./_id-BwvCtzlD.js";
|
|
29
|
+
import { t as Route$29 } from "./_id-BYKpT2Tu.js";
|
|
31
30
|
import { useEffect, useState } from "react";
|
|
32
31
|
import { HeadContent, Link, Outlet, Scripts, createFileRoute, createRootRoute, createRouter, lazyRouteComponent, redirect, useRouterState } from "@tanstack/react-router";
|
|
33
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
34
|
-
import { BellRing, Bot, LayoutTemplate, LogOut, Settings2, ShieldCheck, Sparkles, UsersRound } from "lucide-react";
|
|
32
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
33
|
+
import { BellRing, Bot, ChevronDown, LayoutTemplate, LogOut, MessageCircle, Settings2, ShieldCheck, Sparkles, UsersRound } from "lucide-react";
|
|
34
|
+
import { DropdownMenu } from "radix-ui";
|
|
35
35
|
//#region src/components/Footer.tsx
|
|
36
36
|
function Footer() {
|
|
37
37
|
return /* @__PURE__ */ jsxs("footer", {
|
|
@@ -54,112 +54,236 @@ function Footer() {
|
|
|
54
54
|
}
|
|
55
55
|
//#endregion
|
|
56
56
|
//#region src/components/TopNav.tsx
|
|
57
|
-
var
|
|
57
|
+
var PRIMARY_LINKS = [
|
|
58
58
|
{
|
|
59
|
-
to: "/
|
|
60
|
-
label: "
|
|
61
|
-
icon:
|
|
59
|
+
to: "/",
|
|
60
|
+
label: "Chat",
|
|
61
|
+
icon: MessageCircle
|
|
62
62
|
},
|
|
63
63
|
{
|
|
64
64
|
to: "/agents",
|
|
65
|
-
label: "
|
|
65
|
+
label: "Agents",
|
|
66
66
|
icon: Bot
|
|
67
67
|
},
|
|
68
68
|
{
|
|
69
69
|
to: "/teams",
|
|
70
|
-
label: "
|
|
70
|
+
label: "Teams",
|
|
71
71
|
icon: UsersRound
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
72
|
+
}
|
|
73
|
+
];
|
|
74
|
+
var OPERATIONS_LINKS = [{
|
|
75
|
+
href: "/approvals",
|
|
76
|
+
label: "Approvals",
|
|
77
|
+
description: "Decide whether one captured action may proceed.",
|
|
78
|
+
icon: ShieldCheck
|
|
79
|
+
}, {
|
|
80
|
+
href: "/attention",
|
|
81
|
+
label: "Attention",
|
|
82
|
+
description: "Inspect failures, warnings, lessons, and open signals.",
|
|
83
|
+
icon: BellRing
|
|
84
|
+
}];
|
|
85
|
+
var MANAGE_LINKS = [
|
|
78
86
|
{
|
|
79
|
-
|
|
80
|
-
label: "
|
|
81
|
-
|
|
87
|
+
href: "/templates",
|
|
88
|
+
label: "Templates",
|
|
89
|
+
description: "Reusable Agent behavior and Team rosters.",
|
|
90
|
+
icon: LayoutTemplate
|
|
82
91
|
},
|
|
83
92
|
{
|
|
84
|
-
|
|
85
|
-
label: "
|
|
93
|
+
href: "/skills",
|
|
94
|
+
label: "Skills",
|
|
95
|
+
description: "Prompt skills available to your agents.",
|
|
86
96
|
icon: Sparkles
|
|
87
97
|
},
|
|
88
98
|
{
|
|
89
|
-
|
|
90
|
-
label: "
|
|
99
|
+
href: "/config",
|
|
100
|
+
label: "Setup",
|
|
101
|
+
description: "Providers, integrations, access, and services.",
|
|
91
102
|
icon: Settings2
|
|
92
103
|
}
|
|
93
104
|
];
|
|
94
105
|
function TopNav() {
|
|
95
106
|
const pathname = useRouterState({ select: (state) => state.location.pathname });
|
|
96
|
-
const [
|
|
107
|
+
const [attention, setAttention] = useState(null);
|
|
108
|
+
const [logoutError, setLogoutError] = useState(null);
|
|
97
109
|
useEffect(() => {
|
|
98
110
|
if (pathname === "/login" || pathname === "/welcome") return;
|
|
99
|
-
|
|
111
|
+
const controller = new AbortController();
|
|
112
|
+
fetch("/api/attention/summary", { signal: controller.signal }).then((response) => response.ok ? response.json() : null).then((body) => setAttention(body)).catch((error) => {
|
|
113
|
+
if (error instanceof DOMException && error.name === "AbortError") return;
|
|
114
|
+
});
|
|
115
|
+
return () => controller.abort();
|
|
100
116
|
}, [pathname]);
|
|
101
117
|
async function logout() {
|
|
102
|
-
|
|
118
|
+
setLogoutError(null);
|
|
119
|
+
try {
|
|
120
|
+
const response = await fetch("/api/logout", { method: "POST" });
|
|
121
|
+
if (!response.ok) throw new Error(`Log out failed (${response.status})`);
|
|
122
|
+
window.location.assign("/login");
|
|
123
|
+
} catch (error) {
|
|
124
|
+
setLogoutError(error instanceof Error ? error.message : String(error));
|
|
125
|
+
}
|
|
103
126
|
}
|
|
104
127
|
return /* @__PURE__ */ jsxs("nav", {
|
|
105
128
|
"aria-label": "Primary navigation",
|
|
106
|
-
className: "mx-auto grid w-full max-w-[1500px] shrink-0 grid-cols-[minmax(0,1fr)_auto] items-center gap-x-3 gap-y-2 border-b border-frost py-3 md:flex md:gap-2 md:py-4",
|
|
129
|
+
className: "relative mx-auto grid w-full max-w-[1500px] shrink-0 grid-cols-[minmax(0,1fr)_auto] items-center gap-x-3 gap-y-2 border-b border-frost py-3 md:flex md:gap-2 md:py-4",
|
|
107
130
|
children: [
|
|
108
131
|
/* @__PURE__ */ jsxs(Link, {
|
|
109
132
|
to: "/",
|
|
110
|
-
"aria-
|
|
133
|
+
"aria-label": "Bazilion home",
|
|
111
134
|
className: "logo team flex min-w-0 items-center gap-2 rounded-lg text-charcoal transition-opacity hover:text-charcoal hover:opacity-80",
|
|
112
135
|
children: [/* @__PURE__ */ jsx(BaziuLogo, { className: "logo-paw h-8 w-8 shrink-0 transition-transform duration-300 team-hover:rotate-[-8deg] team-hover:scale-[1.08]" }), /* @__PURE__ */ jsx("span", {
|
|
113
136
|
className: "truncate font-display text-[1.35rem] tracking-[-0.02em]",
|
|
114
137
|
children: "bazilion"
|
|
115
138
|
})]
|
|
116
139
|
}),
|
|
117
|
-
/* @__PURE__ */
|
|
118
|
-
className: "col-span-2 row-start-2 flex min-w-0 items-center
|
|
119
|
-
children:
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
/* @__PURE__ */ jsx(Icon, {
|
|
130
|
-
className: "h-[1.05rem] w-[1.05rem] shrink-0",
|
|
140
|
+
/* @__PURE__ */ jsxs("div", {
|
|
141
|
+
className: "col-span-2 row-start-2 flex min-w-0 items-center gap-1 overflow-x-auto pb-0.5 md:col-auto md:row-auto md:ml-4 md:flex-1 md:overflow-visible md:pb-0",
|
|
142
|
+
children: [
|
|
143
|
+
PRIMARY_LINKS.map((link) => {
|
|
144
|
+
const active = link.to === "/" ? pathname === "/" : pathname === link.to || pathname.startsWith(`${link.to}/`);
|
|
145
|
+
const Icon = link.icon;
|
|
146
|
+
return /* @__PURE__ */ jsxs(Link, {
|
|
147
|
+
to: link.to,
|
|
148
|
+
"aria-current": active ? "page" : void 0,
|
|
149
|
+
className: navButtonClass(active),
|
|
150
|
+
children: [/* @__PURE__ */ jsx(Icon, {
|
|
151
|
+
className: "hidden size-4 shrink-0 sm:block",
|
|
131
152
|
"aria-hidden": "true"
|
|
132
|
-
}),
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
153
|
+
}), /* @__PURE__ */ jsx("span", { children: link.label })]
|
|
154
|
+
}, link.to);
|
|
155
|
+
}),
|
|
156
|
+
/* @__PURE__ */ jsx(NavMenu, {
|
|
157
|
+
label: "Operations",
|
|
158
|
+
compactLabel: "Ops",
|
|
159
|
+
icon: BellRing,
|
|
160
|
+
links: OPERATIONS_LINKS,
|
|
161
|
+
pathname,
|
|
162
|
+
badge: attention?.openTotal ?? 0,
|
|
163
|
+
itemBadges: {
|
|
164
|
+
"/approvals": attention?.byKind.communication_approval ?? 0,
|
|
165
|
+
"/attention": attention?.openTotal ?? 0
|
|
166
|
+
}
|
|
167
|
+
}),
|
|
168
|
+
/* @__PURE__ */ jsx(NavMenu, {
|
|
169
|
+
label: "Manage",
|
|
170
|
+
icon: Settings2,
|
|
171
|
+
links: MANAGE_LINKS,
|
|
172
|
+
pathname,
|
|
173
|
+
align: "end"
|
|
174
|
+
})
|
|
175
|
+
]
|
|
145
176
|
}),
|
|
146
177
|
/* @__PURE__ */ jsxs("div", {
|
|
147
178
|
className: "col-start-2 row-start-1 flex items-center gap-1 md:col-auto md:row-auto md:ml-auto",
|
|
148
179
|
children: [/* @__PURE__ */ jsx(ThemeToggle, {}), /* @__PURE__ */ jsx("button", {
|
|
149
180
|
type: "button",
|
|
150
|
-
onClick: logout,
|
|
181
|
+
onClick: () => void logout(),
|
|
151
182
|
"aria-label": "Log out",
|
|
152
183
|
title: "Log out",
|
|
153
|
-
className: "inline-flex h-9 w-9 items-center justify-center rounded-lg text-mocha hover:bg-ivory hover:text-sapphire",
|
|
184
|
+
className: "unstyled inline-flex h-9 w-9 items-center justify-center rounded-lg text-mocha hover:bg-ivory hover:text-sapphire",
|
|
154
185
|
children: /* @__PURE__ */ jsx(LogOut, {
|
|
155
186
|
className: "h-4 w-4",
|
|
156
187
|
"aria-hidden": "true"
|
|
157
188
|
})
|
|
158
189
|
})]
|
|
190
|
+
}),
|
|
191
|
+
logoutError && /* @__PURE__ */ jsx("p", {
|
|
192
|
+
role: "alert",
|
|
193
|
+
className: "col-span-2 m-0 rounded-lg bg-danger/10 px-3 py-2 text-sm text-danger md:absolute md:right-0 md:top-[calc(100%+0.35rem)] md:z-50 md:shadow-baziu-md",
|
|
194
|
+
children: logoutError
|
|
159
195
|
})
|
|
160
196
|
]
|
|
161
197
|
});
|
|
162
198
|
}
|
|
199
|
+
function NavMenu({ label, compactLabel, icon: Icon, links, pathname, badge = 0, itemBadges = {}, align = "start" }) {
|
|
200
|
+
const active = links.some((link) => pathname === link.href || pathname.startsWith(`${link.href}/`));
|
|
201
|
+
return /* @__PURE__ */ jsxs(DropdownMenu.Root, { children: [/* @__PURE__ */ jsx(DropdownMenu.Trigger, {
|
|
202
|
+
asChild: true,
|
|
203
|
+
children: /* @__PURE__ */ jsxs("button", {
|
|
204
|
+
type: "button",
|
|
205
|
+
className: navButtonClass(active),
|
|
206
|
+
"aria-label": `${label} menu`,
|
|
207
|
+
children: [
|
|
208
|
+
/* @__PURE__ */ jsx(Icon, {
|
|
209
|
+
className: "hidden size-4 shrink-0 sm:block",
|
|
210
|
+
"aria-hidden": "true"
|
|
211
|
+
}),
|
|
212
|
+
/* @__PURE__ */ jsx("span", {
|
|
213
|
+
className: compactLabel ? "sm:hidden" : void 0,
|
|
214
|
+
children: compactLabel ?? label
|
|
215
|
+
}),
|
|
216
|
+
compactLabel && /* @__PURE__ */ jsx("span", {
|
|
217
|
+
className: "hidden sm:inline",
|
|
218
|
+
children: label
|
|
219
|
+
}),
|
|
220
|
+
badge > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("span", {
|
|
221
|
+
className: "size-2 shrink-0 rounded-full bg-danger sm:hidden",
|
|
222
|
+
"aria-label": `${badge} open items`
|
|
223
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
224
|
+
className: "hidden sm:inline-flex",
|
|
225
|
+
children: /* @__PURE__ */ jsx(CountBadge, {
|
|
226
|
+
value: badge,
|
|
227
|
+
label: `${badge} open items`
|
|
228
|
+
})
|
|
229
|
+
})] }),
|
|
230
|
+
/* @__PURE__ */ jsx(ChevronDown, {
|
|
231
|
+
className: "size-3 shrink-0 text-muted-foreground",
|
|
232
|
+
"aria-hidden": "true"
|
|
233
|
+
})
|
|
234
|
+
]
|
|
235
|
+
})
|
|
236
|
+
}), /* @__PURE__ */ jsx(DropdownMenu.Portal, { children: /* @__PURE__ */ jsxs(DropdownMenu.Content, {
|
|
237
|
+
align,
|
|
238
|
+
sideOffset: 8,
|
|
239
|
+
collisionPadding: 12,
|
|
240
|
+
className: "z-50 w-[min(21rem,calc(100vw-1.5rem))] rounded-xl border border-border bg-popover p-1.5 text-popover-foreground shadow-baziu-lg outline-none data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",
|
|
241
|
+
children: [/* @__PURE__ */ jsx(DropdownMenu.Label, {
|
|
242
|
+
className: "px-2.5 pb-1 pt-1 text-xs font-semibold uppercase tracking-[0.1em] text-muted-foreground",
|
|
243
|
+
children: label
|
|
244
|
+
}), links.map((link) => {
|
|
245
|
+
const ItemIcon = link.icon;
|
|
246
|
+
const itemActive = pathname === link.href || pathname.startsWith(`${link.href}/`);
|
|
247
|
+
return /* @__PURE__ */ jsx(DropdownMenu.Item, {
|
|
248
|
+
asChild: true,
|
|
249
|
+
children: /* @__PURE__ */ jsxs("a", {
|
|
250
|
+
href: link.href,
|
|
251
|
+
"aria-current": itemActive ? "page" : void 0,
|
|
252
|
+
className: `flex cursor-pointer items-start gap-3 rounded-lg px-2.5 py-2.5 outline-none transition-colors focus:bg-accent focus:text-accent-foreground ${itemActive ? "bg-accent/70 text-accent-foreground" : "text-foreground"}`,
|
|
253
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
254
|
+
className: "mt-0.5 flex size-7 shrink-0 items-center justify-center rounded-lg bg-muted text-muted-foreground",
|
|
255
|
+
children: /* @__PURE__ */ jsx(ItemIcon, {
|
|
256
|
+
className: "size-3.5",
|
|
257
|
+
"aria-hidden": "true"
|
|
258
|
+
})
|
|
259
|
+
}), /* @__PURE__ */ jsxs("span", {
|
|
260
|
+
className: "min-w-0 flex-1",
|
|
261
|
+
children: [/* @__PURE__ */ jsxs("span", {
|
|
262
|
+
className: "flex items-center gap-2 text-sm font-semibold",
|
|
263
|
+
children: [link.label, (itemBadges[link.href] ?? 0) > 0 && /* @__PURE__ */ jsx(CountBadge, {
|
|
264
|
+
value: itemBadges[link.href] ?? 0,
|
|
265
|
+
label: `${itemBadges[link.href]} open ${link.label.toLowerCase()} items`
|
|
266
|
+
})]
|
|
267
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
268
|
+
className: "mt-0.5 block text-xs leading-5 text-muted-foreground",
|
|
269
|
+
children: link.description
|
|
270
|
+
})]
|
|
271
|
+
})]
|
|
272
|
+
})
|
|
273
|
+
}, link.href);
|
|
274
|
+
})]
|
|
275
|
+
}) })] });
|
|
276
|
+
}
|
|
277
|
+
function CountBadge({ value, label }) {
|
|
278
|
+
return /* @__PURE__ */ jsx("span", {
|
|
279
|
+
className: "inline-flex min-w-5 items-center justify-center rounded-full bg-danger px-1.5 py-0.5 text-xs font-semibold leading-4 text-primary-foreground",
|
|
280
|
+
"aria-label": label,
|
|
281
|
+
children: value > 99 ? "99+" : value
|
|
282
|
+
});
|
|
283
|
+
}
|
|
284
|
+
function navButtonClass(active) {
|
|
285
|
+
return `unstyled inline-flex h-9 shrink-0 items-center justify-center gap-1.5 rounded-lg border px-2 text-sm font-semibold transition-colors sm:px-2.5 ${active ? "border-sapphire-light bg-sapphire-glow text-sapphire shadow-baziu-sm" : "border-transparent text-mocha hover:border-frost hover:bg-ivory hover:text-sapphire"}`;
|
|
286
|
+
}
|
|
163
287
|
//#endregion
|
|
164
288
|
//#region src/lib/auth.ts
|
|
165
289
|
var fetchAuthState = createServerFn({ method: "GET" }).handler(createSsrRpc("a5d3825fc69573bb55bab6df578c750ebb0240dd394c3acee3adea02918a5dc2"));
|
|
@@ -207,12 +331,12 @@ function installCsrfFetch() {
|
|
|
207
331
|
}
|
|
208
332
|
//#endregion
|
|
209
333
|
//#region src/styles.css?url
|
|
210
|
-
var styles_default = "/assets/styles-
|
|
334
|
+
var styles_default = "/assets/styles-B5vcgXln.css";
|
|
211
335
|
//#endregion
|
|
212
336
|
//#region src/routes/__root.tsx
|
|
213
337
|
var THEME_INIT_SCRIPT = `(function(){try{var t=localStorage.getItem('baziu-theme');var sd=window.matchMedia&&window.matchMedia('(prefers-color-scheme: dark)').matches;var d=t==='dark'||((t===null||t==='system')&&sd);document.documentElement.classList.toggle('dark',d);}catch(e){}})();`;
|
|
214
338
|
installCsrfFetch();
|
|
215
|
-
var Route$
|
|
339
|
+
var Route$4 = createRootRoute({
|
|
216
340
|
beforeLoad: async ({ location }) => {
|
|
217
341
|
const path = location.pathname;
|
|
218
342
|
if (PUBLIC_PATHS.has(path)) return;
|
|
@@ -279,39 +403,51 @@ function RootComponent() {
|
|
|
279
403
|
suppressHydrationWarning: true,
|
|
280
404
|
children: [/* @__PURE__ */ jsxs("head", { children: [/* @__PURE__ */ jsx("script", { dangerouslySetInnerHTML: { __html: THEME_INIT_SCRIPT } }), /* @__PURE__ */ jsx(HeadContent, {})] }), /* @__PURE__ */ jsxs("body", {
|
|
281
405
|
"data-layout": isWorkspace ? "workspace" : "page",
|
|
282
|
-
children: [
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
className: "px-3
|
|
286
|
-
children:
|
|
287
|
-
}),
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
}) : /* @__PURE__ */ jsxs("div", {
|
|
292
|
-
className: "flex min-h-dvh flex-col",
|
|
293
|
-
children: [
|
|
294
|
-
/* @__PURE__ */ jsx("div", {
|
|
406
|
+
children: [
|
|
407
|
+
!isLogin && /* @__PURE__ */ jsx("a", {
|
|
408
|
+
href: "#main-content",
|
|
409
|
+
className: "sr-only z-[100] rounded-lg bg-primary px-4 py-2 font-semibold text-primary-foreground focus:not-sr-only focus:fixed focus:left-3 focus:top-3",
|
|
410
|
+
children: "Skip to main content"
|
|
411
|
+
}),
|
|
412
|
+
isLogin ? /* @__PURE__ */ jsx(Outlet, {}) : isWorkspace ? /* @__PURE__ */ jsxs("div", {
|
|
413
|
+
className: "flex h-dvh flex-col",
|
|
414
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
295
415
|
className: "px-3 sm:px-5",
|
|
296
416
|
children: /* @__PURE__ */ jsx(TopNav, {})
|
|
297
|
-
}),
|
|
298
|
-
|
|
299
|
-
|
|
417
|
+
}), /* @__PURE__ */ jsx("main", {
|
|
418
|
+
id: "main-content",
|
|
419
|
+
tabIndex: -1,
|
|
420
|
+
className: "mx-auto min-h-0 w-full max-w-[1600px] flex-1 overflow-hidden px-3 pb-3 sm:px-5 sm:pb-5",
|
|
300
421
|
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
301
|
-
})
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
422
|
+
})]
|
|
423
|
+
}) : /* @__PURE__ */ jsxs("div", {
|
|
424
|
+
className: "flex min-h-dvh flex-col",
|
|
425
|
+
children: [
|
|
426
|
+
/* @__PURE__ */ jsx("div", {
|
|
427
|
+
className: "px-3 sm:px-5",
|
|
428
|
+
children: /* @__PURE__ */ jsx(TopNav, {})
|
|
429
|
+
}),
|
|
430
|
+
/* @__PURE__ */ jsx("main", {
|
|
431
|
+
id: "main-content",
|
|
432
|
+
tabIndex: -1,
|
|
433
|
+
className: "mx-auto w-full max-w-[1500px] flex-1 px-4 py-9 sm:px-6 sm:py-12",
|
|
434
|
+
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
435
|
+
}),
|
|
436
|
+
/* @__PURE__ */ jsx("div", {
|
|
437
|
+
className: "px-4 sm:px-6",
|
|
438
|
+
children: /* @__PURE__ */ jsx(Footer, {})
|
|
439
|
+
})
|
|
440
|
+
]
|
|
441
|
+
}),
|
|
442
|
+
/* @__PURE__ */ jsx(Scripts, {})
|
|
443
|
+
]
|
|
308
444
|
})]
|
|
309
445
|
});
|
|
310
446
|
}
|
|
311
447
|
//#endregion
|
|
312
448
|
//#region src/routes/welcome.tsx
|
|
313
|
-
var $$splitComponentImporter = () => import("./welcome-
|
|
314
|
-
var Route$
|
|
449
|
+
var $$splitComponentImporter = () => import("./welcome-B8nchXdF.js");
|
|
450
|
+
var Route$3 = createFileRoute("/welcome")({
|
|
315
451
|
beforeLoad: async () => {
|
|
316
452
|
if ((await fetchAuthState()).setupComplete) throw redirect({ to: "/" });
|
|
317
453
|
},
|
|
@@ -319,7 +455,7 @@ var Route$2 = createFileRoute("/welcome")({
|
|
|
319
455
|
});
|
|
320
456
|
//#endregion
|
|
321
457
|
//#region src/routes/templates/index.tsx
|
|
322
|
-
var Route$
|
|
458
|
+
var Route$2 = createFileRoute("/templates/")({ beforeLoad: () => {
|
|
323
459
|
throw redirect({ to: "/templates/agents" });
|
|
324
460
|
} });
|
|
325
461
|
//#endregion
|
|
@@ -355,17 +491,35 @@ function hasDuplicateCookie(header, name) {
|
|
|
355
491
|
if (!header) return false;
|
|
356
492
|
return header.split(";").map((part) => part.trim()).map((part) => part.slice(0, part.indexOf("="))).filter((cookieName) => cookieName === name).length > 1;
|
|
357
493
|
}
|
|
358
|
-
function
|
|
494
|
+
async function readBoundedBody(body, limit) {
|
|
359
495
|
let seen = 0;
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
496
|
+
const reader = body.getReader();
|
|
497
|
+
const chunks = [];
|
|
498
|
+
try {
|
|
499
|
+
while (true) {
|
|
500
|
+
const { done, value } = await reader.read();
|
|
501
|
+
if (done) break;
|
|
502
|
+
seen += value.byteLength;
|
|
503
|
+
if (seen > limit) {
|
|
504
|
+
await reader.cancel("request body exceeds gateway limit");
|
|
505
|
+
return null;
|
|
506
|
+
}
|
|
507
|
+
chunks.push(value);
|
|
508
|
+
}
|
|
509
|
+
} finally {
|
|
510
|
+
reader.releaseLock();
|
|
511
|
+
}
|
|
512
|
+
const result = new Uint8Array(new ArrayBuffer(seen));
|
|
513
|
+
let offset = 0;
|
|
514
|
+
for (const chunk of chunks) {
|
|
515
|
+
result.set(chunk, offset);
|
|
516
|
+
offset += chunk.byteLength;
|
|
517
|
+
}
|
|
518
|
+
return result.buffer;
|
|
365
519
|
}
|
|
366
520
|
function addSecurityHeaders(headers, production) {
|
|
367
521
|
headers.set("x-content-type-options", "nosniff");
|
|
368
|
-
headers.set("referrer-policy", "
|
|
522
|
+
headers.set("referrer-policy", "same-origin");
|
|
369
523
|
headers.set("permissions-policy", "camera=(), microphone=(), geolocation=()");
|
|
370
524
|
headers.set("x-frame-options", "DENY");
|
|
371
525
|
headers.set("content-security-policy", "default-src 'self'; base-uri 'self'; connect-src 'self'; font-src 'self'; frame-ancestors 'none'; img-src 'self' data:; object-src 'none'; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'");
|
|
@@ -403,7 +557,15 @@ async function proxy(request) {
|
|
|
403
557
|
const session = getCookie(originConfig.sessionCookie);
|
|
404
558
|
const csrf = getCookie(originConfig.csrfCookie);
|
|
405
559
|
if (unsafe && (session || incoming.pathname === "/api/login")) {
|
|
406
|
-
if (request.headers.get("origin") !== expectedOrigin)
|
|
560
|
+
if (request.headers.get("origin") !== expectedOrigin) {
|
|
561
|
+
const contentType = request.headers.get("content-type") ?? "";
|
|
562
|
+
const acceptsHtml = request.headers.get("accept")?.includes("text/html") ?? false;
|
|
563
|
+
if (incoming.pathname === "/api/login" && contentType.startsWith("application/x-www-form-urlencoded") && acceptsHtml) return new Response(null, {
|
|
564
|
+
status: 303,
|
|
565
|
+
headers: { location: "/login?error=origin" }
|
|
566
|
+
});
|
|
567
|
+
return new Response("origin validation failed", { status: 403 });
|
|
568
|
+
}
|
|
407
569
|
if (session && (!csrf || request.headers.get("x-bazilion-csrf") !== csrf)) return new Response("csrf validation failed", { status: 403 });
|
|
408
570
|
}
|
|
409
571
|
const target = `${DAEMON_BASE_URL}${incoming.pathname}${incoming.search}`;
|
|
@@ -418,14 +580,18 @@ async function proxy(request) {
|
|
|
418
580
|
const init = {
|
|
419
581
|
method: request.method,
|
|
420
582
|
headers,
|
|
421
|
-
redirect: "manual"
|
|
583
|
+
redirect: "manual",
|
|
584
|
+
signal: request.signal
|
|
422
585
|
};
|
|
423
586
|
if (request.method !== "GET" && request.method !== "HEAD") {
|
|
424
587
|
const limit = (request.headers.get("content-type") ?? "").startsWith("multipart/form-data") ? MAX_UPLOAD_BODY : MAX_JSON_BODY;
|
|
425
588
|
const contentLength = Number(request.headers.get("content-length") ?? 0);
|
|
426
589
|
if (Number.isFinite(contentLength) && contentLength > limit) return new Response("request body too large", { status: 413 });
|
|
427
|
-
if (request.body)
|
|
428
|
-
|
|
590
|
+
if (request.body) {
|
|
591
|
+
const body = await readBoundedBody(request.body, limit);
|
|
592
|
+
if (!body) return new Response("request body too large", { status: 413 });
|
|
593
|
+
init.body = body;
|
|
594
|
+
}
|
|
429
595
|
}
|
|
430
596
|
const upstream = await fetch(target, init);
|
|
431
597
|
const respHeaders = new Headers();
|
|
@@ -442,7 +608,7 @@ async function proxy(request) {
|
|
|
442
608
|
headers: respHeaders
|
|
443
609
|
});
|
|
444
610
|
}
|
|
445
|
-
var Route = createFileRoute("/api/$")({ server: { handlers: {
|
|
611
|
+
var Route$1 = createFileRoute("/api/$")({ server: { handlers: {
|
|
446
612
|
GET: ({ request }) => proxy(request),
|
|
447
613
|
POST: ({ request }) => proxy(request),
|
|
448
614
|
PUT: ({ request }) => proxy(request),
|
|
@@ -450,146 +616,154 @@ var Route = createFileRoute("/api/$")({ server: { handlers: {
|
|
|
450
616
|
DELETE: ({ request }) => proxy(request)
|
|
451
617
|
} } });
|
|
452
618
|
//#endregion
|
|
619
|
+
//#region src/routes/teams/$id/context.tsx
|
|
620
|
+
var Route = createFileRoute("/teams/$id/context")({ beforeLoad: ({ params }) => {
|
|
621
|
+
throw redirect({
|
|
622
|
+
to: "/teams/$id",
|
|
623
|
+
params: { id: params.id }
|
|
624
|
+
});
|
|
625
|
+
} });
|
|
626
|
+
//#endregion
|
|
453
627
|
//#region src/routeTree.gen.ts
|
|
454
|
-
var WelcomeRoute = Route$
|
|
628
|
+
var WelcomeRoute = Route$3.update({
|
|
455
629
|
id: "/welcome",
|
|
456
630
|
path: "/welcome",
|
|
457
|
-
getParentRoute: () => Route$
|
|
631
|
+
getParentRoute: () => Route$4
|
|
458
632
|
});
|
|
459
|
-
var LoginRoute = Route$
|
|
633
|
+
var LoginRoute = Route$5.update({
|
|
460
634
|
id: "/login",
|
|
461
635
|
path: "/login",
|
|
462
|
-
getParentRoute: () => Route$
|
|
636
|
+
getParentRoute: () => Route$4
|
|
463
637
|
});
|
|
464
|
-
var IndexRoute = Route$
|
|
638
|
+
var IndexRoute = Route$6.update({
|
|
465
639
|
id: "/",
|
|
466
640
|
path: "/",
|
|
467
|
-
getParentRoute: () => Route$
|
|
641
|
+
getParentRoute: () => Route$4
|
|
468
642
|
});
|
|
469
|
-
var TemplatesIndexRoute = Route$
|
|
643
|
+
var TemplatesIndexRoute = Route$2.update({
|
|
470
644
|
id: "/templates/",
|
|
471
645
|
path: "/templates/",
|
|
472
|
-
getParentRoute: () => Route$
|
|
646
|
+
getParentRoute: () => Route$4
|
|
473
647
|
});
|
|
474
|
-
var TeamsIndexRoute = Route$
|
|
648
|
+
var TeamsIndexRoute = Route$7.update({
|
|
475
649
|
id: "/teams/",
|
|
476
650
|
path: "/teams/",
|
|
477
|
-
getParentRoute: () => Route$
|
|
651
|
+
getParentRoute: () => Route$4
|
|
478
652
|
});
|
|
479
|
-
var SkillsIndexRoute = Route$
|
|
653
|
+
var SkillsIndexRoute = Route$8.update({
|
|
480
654
|
id: "/skills/",
|
|
481
655
|
path: "/skills/",
|
|
482
|
-
getParentRoute: () => Route$
|
|
656
|
+
getParentRoute: () => Route$4
|
|
483
657
|
});
|
|
484
|
-
var ConfigIndexRoute = Route$
|
|
658
|
+
var ConfigIndexRoute = Route$9.update({
|
|
485
659
|
id: "/config/",
|
|
486
660
|
path: "/config/",
|
|
487
|
-
getParentRoute: () => Route$
|
|
661
|
+
getParentRoute: () => Route$4
|
|
488
662
|
});
|
|
489
|
-
var AttentionIndexRoute = Route$
|
|
663
|
+
var AttentionIndexRoute = Route$10.update({
|
|
490
664
|
id: "/attention/",
|
|
491
665
|
path: "/attention/",
|
|
492
|
-
getParentRoute: () => Route$
|
|
666
|
+
getParentRoute: () => Route$4
|
|
493
667
|
});
|
|
494
|
-
var ApprovalsIndexRoute = Route$
|
|
668
|
+
var ApprovalsIndexRoute = Route$11.update({
|
|
495
669
|
id: "/approvals/",
|
|
496
670
|
path: "/approvals/",
|
|
497
|
-
getParentRoute: () => Route$
|
|
671
|
+
getParentRoute: () => Route$4
|
|
498
672
|
});
|
|
499
|
-
var AgentsIndexRoute = Route$
|
|
673
|
+
var AgentsIndexRoute = Route$12.update({
|
|
500
674
|
id: "/agents/",
|
|
501
675
|
path: "/agents/",
|
|
502
|
-
getParentRoute: () => Route$
|
|
676
|
+
getParentRoute: () => Route$4
|
|
503
677
|
});
|
|
504
|
-
var ConfigTokensRoute = Route$
|
|
678
|
+
var ConfigTokensRoute = Route$13.update({
|
|
505
679
|
id: "/config/tokens",
|
|
506
680
|
path: "/config/tokens",
|
|
507
|
-
getParentRoute: () => Route$
|
|
681
|
+
getParentRoute: () => Route$4
|
|
508
682
|
});
|
|
509
|
-
var ConfigServicesRoute = Route$
|
|
683
|
+
var ConfigServicesRoute = Route$14.update({
|
|
510
684
|
id: "/config/services",
|
|
511
685
|
path: "/config/services",
|
|
512
|
-
getParentRoute: () => Route$
|
|
686
|
+
getParentRoute: () => Route$4
|
|
513
687
|
});
|
|
514
|
-
var ConfigMcpRoute = Route$
|
|
688
|
+
var ConfigMcpRoute = Route$15.update({
|
|
515
689
|
id: "/config/mcp",
|
|
516
690
|
path: "/config/mcp",
|
|
517
|
-
getParentRoute: () => Route$
|
|
691
|
+
getParentRoute: () => Route$4
|
|
518
692
|
});
|
|
519
|
-
var ApiSplatRoute = Route.update({
|
|
693
|
+
var ApiSplatRoute = Route$1.update({
|
|
520
694
|
id: "/api/$",
|
|
521
695
|
path: "/api/$",
|
|
522
|
-
getParentRoute: () => Route$
|
|
696
|
+
getParentRoute: () => Route$4
|
|
523
697
|
});
|
|
524
|
-
var TemplatesTeamsIndexRoute = Route$
|
|
698
|
+
var TemplatesTeamsIndexRoute = Route$16.update({
|
|
525
699
|
id: "/templates/teams/",
|
|
526
700
|
path: "/templates/teams/",
|
|
527
|
-
getParentRoute: () => Route$
|
|
701
|
+
getParentRoute: () => Route$4
|
|
528
702
|
});
|
|
529
|
-
var TemplatesAgentsIndexRoute = Route$
|
|
703
|
+
var TemplatesAgentsIndexRoute = Route$17.update({
|
|
530
704
|
id: "/templates/agents/",
|
|
531
705
|
path: "/templates/agents/",
|
|
532
|
-
getParentRoute: () => Route$
|
|
706
|
+
getParentRoute: () => Route$4
|
|
533
707
|
});
|
|
534
|
-
var TeamsIdIndexRoute = Route$
|
|
708
|
+
var TeamsIdIndexRoute = Route$18.update({
|
|
535
709
|
id: "/teams/$id/",
|
|
536
710
|
path: "/teams/$id/",
|
|
537
|
-
getParentRoute: () => Route$
|
|
711
|
+
getParentRoute: () => Route$4
|
|
538
712
|
});
|
|
539
|
-
var AgentsIdIndexRoute = Route$
|
|
713
|
+
var AgentsIdIndexRoute = Route$19.update({
|
|
540
714
|
id: "/agents/$id/",
|
|
541
715
|
path: "/agents/$id/",
|
|
542
|
-
getParentRoute: () => Route$
|
|
716
|
+
getParentRoute: () => Route$4
|
|
543
717
|
});
|
|
544
|
-
var TeamsIdPolicyRoute = Route$
|
|
718
|
+
var TeamsIdPolicyRoute = Route$20.update({
|
|
545
719
|
id: "/teams/$id/policy",
|
|
546
720
|
path: "/teams/$id/policy",
|
|
547
|
-
getParentRoute: () => Route$
|
|
721
|
+
getParentRoute: () => Route$4
|
|
548
722
|
});
|
|
549
|
-
var TeamsIdMemoryRoute = Route$
|
|
723
|
+
var TeamsIdMemoryRoute = Route$21.update({
|
|
550
724
|
id: "/teams/$id/memory",
|
|
551
725
|
path: "/teams/$id/memory",
|
|
552
|
-
getParentRoute: () => Route$
|
|
726
|
+
getParentRoute: () => Route$4
|
|
553
727
|
});
|
|
554
|
-
var TeamsIdMembersRoute = Route$
|
|
728
|
+
var TeamsIdMembersRoute = Route$22.update({
|
|
555
729
|
id: "/teams/$id/members",
|
|
556
730
|
path: "/teams/$id/members",
|
|
557
|
-
getParentRoute: () => Route$
|
|
731
|
+
getParentRoute: () => Route$4
|
|
558
732
|
});
|
|
559
|
-
var TeamsIdContextRoute = Route
|
|
733
|
+
var TeamsIdContextRoute = Route.update({
|
|
560
734
|
id: "/teams/$id/context",
|
|
561
735
|
path: "/teams/$id/context",
|
|
562
|
-
getParentRoute: () => Route$
|
|
736
|
+
getParentRoute: () => Route$4
|
|
563
737
|
});
|
|
564
738
|
var TeamsIdActivityRoute = Route$23.update({
|
|
565
739
|
id: "/teams/$id/activity",
|
|
566
740
|
path: "/teams/$id/activity",
|
|
567
|
-
getParentRoute: () => Route$
|
|
741
|
+
getParentRoute: () => Route$4
|
|
568
742
|
});
|
|
569
743
|
var ConfigIntegrationsTelegramRoute = Route$24.update({
|
|
570
744
|
id: "/config/integrations/telegram",
|
|
571
745
|
path: "/config/integrations/telegram",
|
|
572
|
-
getParentRoute: () => Route$
|
|
746
|
+
getParentRoute: () => Route$4
|
|
573
747
|
});
|
|
574
748
|
var AgentsIdTriggersRoute = Route$25.update({
|
|
575
749
|
id: "/agents/$id/triggers",
|
|
576
750
|
path: "/agents/$id/triggers",
|
|
577
|
-
getParentRoute: () => Route$
|
|
751
|
+
getParentRoute: () => Route$4
|
|
578
752
|
});
|
|
579
753
|
var AgentsIdLearningRoute = Route$26.update({
|
|
580
754
|
id: "/agents/$id/learning",
|
|
581
755
|
path: "/agents/$id/learning",
|
|
582
|
-
getParentRoute: () => Route$
|
|
756
|
+
getParentRoute: () => Route$4
|
|
583
757
|
});
|
|
584
758
|
var AgentsIdInboxRoute = Route$27.update({
|
|
585
759
|
id: "/agents/$id/inbox",
|
|
586
760
|
path: "/agents/$id/inbox",
|
|
587
|
-
getParentRoute: () => Route$
|
|
761
|
+
getParentRoute: () => Route$4
|
|
588
762
|
});
|
|
589
763
|
var TemplatesTeamsIdIndexRoute = Route$28.update({
|
|
590
764
|
id: "/templates/teams/$id/",
|
|
591
765
|
path: "/templates/teams/$id/",
|
|
592
|
-
getParentRoute: () => Route$
|
|
766
|
+
getParentRoute: () => Route$4
|
|
593
767
|
});
|
|
594
768
|
var rootRouteChildren = {
|
|
595
769
|
IndexRoute,
|
|
@@ -622,11 +796,11 @@ var rootRouteChildren = {
|
|
|
622
796
|
TemplatesAgentsIdIndexRoute: Route$29.update({
|
|
623
797
|
id: "/templates/agents/$id/",
|
|
624
798
|
path: "/templates/agents/$id/",
|
|
625
|
-
getParentRoute: () => Route$
|
|
799
|
+
getParentRoute: () => Route$4
|
|
626
800
|
}),
|
|
627
801
|
TemplatesTeamsIdIndexRoute
|
|
628
802
|
};
|
|
629
|
-
var routeTree = Route$
|
|
803
|
+
var routeTree = Route$4._addFileChildren(rootRouteChildren)._addFileTypes();
|
|
630
804
|
//#endregion
|
|
631
805
|
//#region src/router.tsx
|
|
632
806
|
function getRouter() {
|