bazilion 0.54.0 → 0.55.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/dist/cli.js +10 -5
- package/dist/cli.js.map +1 -1
- package/dist/daemon.js +356 -69
- package/dist/daemon.js.map +1 -1
- package/dist/web/client/assets/AddProviderDialog-DfFOaCjC.js +1 -0
- package/dist/web/client/assets/AgentTemplateParts-IMJmAQjN.js +1 -0
- package/dist/web/client/assets/{Button-UiegBKOK.js → Button-bTJUy9Qf.js} +1 -1
- package/dist/web/client/assets/{ConfigPage-CUbHBhzx.js → ConfigPage-CzLHZa5o.js} +1 -1
- package/dist/web/client/assets/ConfirmDialog-Cu_evkgc.js +1 -0
- package/dist/web/client/assets/ConnectionsView-D7Fmutl2.js +1 -0
- package/dist/web/client/assets/{ManagePage-BJWZd1ts.js → ManagePage-BfvlCrmz.js} +1 -1
- package/dist/web/client/assets/{SectionTabs-ViZKm3-B.js → SectionTabs-D7kPQGoh.js} +1 -1
- package/dist/web/client/assets/{Segmented-MYKKTuZO.js → Segmented-oPkAHPO1.js} +1 -1
- package/dist/web/client/assets/SkillsParts-BuTxcCam.js +1 -0
- package/dist/web/client/assets/SpawnTeamModal-B1UnOvtp.js +1 -0
- package/dist/web/client/assets/TeamForm-DbzxtRjj.js +1 -0
- package/dist/web/client/assets/TeamThread-jpsWq6vI.js +1 -0
- package/dist/web/client/assets/UnsavedChangesGuard-BfyU9v9i.js +1 -0
- package/dist/web/client/assets/_id-BCNBLF-2.js +1 -0
- package/dist/web/client/assets/_id-D8_H79U2.js +1 -0
- package/dist/web/client/assets/access-CDWe1Kwy.js +1 -0
- package/dist/web/client/assets/{agent-actions-BgE9fKHH.js → agent-actions-CUee6aJq.js} +1 -1
- package/dist/web/client/assets/agents-sE686DTf.js +1 -0
- package/dist/web/client/assets/agents-yrur1NDa.js +1 -0
- package/dist/web/client/assets/arrow-right-U66krZnr.js +1 -0
- package/dist/web/client/assets/attention-DYEHDfmx.js +1 -0
- package/dist/web/client/assets/{bot-Bb--PFVU.js → bot-BCone8es.js} +1 -1
- package/dist/web/client/assets/chevron-right-CuqJFXTe.js +1 -0
- package/dist/web/client/assets/config-BHv886pr.js +1 -0
- package/dist/web/client/assets/createLucideIcon-jxSFpY0Q.js +1 -0
- package/dist/web/client/assets/{download-C4t9l5wR.js → download-Dy88XavQ.js} +1 -1
- package/dist/web/client/assets/{file-text-DzbjpYrV.js → file-text-DPsZ8-h9.js} +1 -1
- package/dist/web/client/assets/{images-DSYgPKM7.js → images-QBh_rL8b.js} +1 -1
- package/dist/web/client/assets/index-GOthyyE-.js +14 -0
- package/dist/web/client/assets/{key-round-BpK4-E3T.js → key-round-C-I8fAG0.js} +1 -1
- package/dist/web/client/assets/{list-checks-JNXcmws9.js → list-checks-C9Q-bjEi.js} +1 -1
- package/dist/web/client/assets/{login-DcQJk5-U.js → login-Dhe15Uuc.js} +1 -1
- package/dist/web/client/assets/{manage-SRGSx8n2.js → manage-BaIU5zKy.js} +1 -1
- package/dist/web/client/assets/mcp-A_Eo7x3q.js +1 -0
- package/dist/web/client/assets/{message-square-DM2MP9vF.js → message-square-Bwf9cHOx.js} +1 -1
- package/dist/web/client/assets/{network-BJ4iPjQO.js → network-B3FA93gC.js} +1 -1
- package/dist/web/client/assets/{parts-LZxl9Gvc.js → parts-CpIfn_BH.js} +1 -1
- package/dist/web/client/assets/plus-CQPjc8uR.js +1 -0
- package/dist/web/client/assets/routes-CTg_yjbY.js +85 -0
- package/dist/web/client/assets/skills-CLjtYtkA.js +1 -0
- package/dist/web/client/assets/{square-terminal-Dmm6cV-G.js → square-terminal-DaNLwvEs.js} +1 -1
- package/dist/web/client/assets/style-mjEbxhf5.js +7 -0
- package/dist/web/client/assets/styles-DzcEC3Rd.css +2 -0
- package/dist/web/client/assets/{system-zQ0NnQML.js → system-CrTSr5_t.js} +1 -1
- package/dist/web/client/assets/teams-Bhje5n2h.js +1 -0
- package/dist/web/client/assets/teams-Cbgw0Qhv.js +1 -0
- package/dist/web/client/assets/telegram-HtUczmaA.js +1 -0
- package/dist/web/client/assets/tools-BpjFvmoX.js +1 -0
- package/dist/web/client/assets/use-resource-BnvgCpBi.js +1 -0
- package/dist/web/client/assets/{users-round-BJrym3FG.js → users-round-BElBVSnw.js} +1 -1
- package/dist/web/client/assets/welcome-D47LKWYO.js +1 -0
- package/dist/web/client/assets/{wrench-GbE1M1RJ.js → wrench-DotqSqSm.js} +1 -1
- package/dist/web/server/assets/{AddProviderDialog-Nc5mc_P6.js → AddProviderDialog-BbpuvC2a.js} +2 -2
- package/dist/web/server/assets/{AgentTemplateParts-DZK_r3nQ.js → AgentTemplateParts-Ce7snK3m.js} +1 -1
- package/dist/web/server/assets/{ConfigPage-CxzL-gTm.js → ConfigPage-qP9ejjuw.js} +1 -1
- package/dist/web/server/assets/{ConfirmDialog-4xeCXKHe.js → ConfirmDialog-Z-uYbE9B.js} +1 -1
- package/dist/web/server/assets/{ConnectionsView-B02FjNsM.js → ConnectionsView-CLIV7V5D.js} +7 -7
- package/dist/web/server/assets/{ManagePage-BfCWE8Lj.js → ManagePage-BR9FwVZM.js} +1 -1
- package/dist/web/server/assets/{Rail-3gbidhyv.js → Rail-b6EbjBB-.js} +6 -6
- package/dist/web/server/assets/{SkillsParts-D58l8voo.js → SkillsParts-DWpdydCJ.js} +1 -1
- package/dist/web/server/assets/{SpawnDialog-MJWwppgC.js → SpawnDialog-3wNx0W1R.js} +212 -9
- package/dist/web/server/assets/{SpawnTeamModal-RjzAeX_Q.js → SpawnTeamModal-C-YMvoaB.js} +1 -1
- package/dist/web/server/assets/{TeamForm-DdOgIMiV.js → TeamForm-CL45gBdt.js} +1 -1
- package/dist/web/server/assets/{TeamThread-D-PvO3fu.js → TeamThread-CVVH6kKj.js} +3 -3
- package/dist/web/server/assets/{UnsavedChangesGuard-Bb5frygQ.js → UnsavedChangesGuard-CXK75QQp.js} +1 -1
- package/dist/web/server/assets/{_id-BPjVkcNb.js → _id-2I4CSMQj.js} +6 -6
- package/dist/web/server/assets/{_id-C1_l6oSR.js → _id-8zsImuGa.js} +7 -7
- package/dist/web/server/assets/{_id-BUfy-GwH.js → _id-BpfoPuTv.js} +2 -2
- package/dist/web/server/assets/{_id-CHvYQhWt.js → _id-d2OwovYV.js} +2 -2
- package/dist/web/server/assets/_tanstack-start-manifest_v-kkY_s_uR.js +256 -0
- package/dist/web/server/assets/{access-CNfvQ3NB.js → access-CwZ27Wsl.js} +4 -4
- package/dist/web/server/assets/{access-Cm_izIIC.js → access-CyUoElTP.js} +2 -2
- package/dist/web/server/assets/{agent-actions-COnfW5AU.js → agent-actions-C07Cp5Ue.js} +1 -1
- package/dist/web/server/assets/{agents-D0hfGIMK.js → agents-CwzhpDPm.js} +5 -5
- package/dist/web/server/assets/{agents-DzpqlIuJ.js → agents-DCWEoaxY.js} +2 -2
- package/dist/web/server/assets/{agents-C7UmTjfO.js → agents-DTub-rJk.js} +2 -2
- package/dist/web/server/assets/{agents-NOkh61dV.js → agents-vuXrAv1j.js} +5 -5
- package/dist/web/server/assets/{attention-Cx9ZWPOO.js → attention-BqCnJ1hg.js} +3 -2
- package/dist/web/server/assets/{attention-CgWhXjX7.js → attention-Dki8rmGZ.js} +1 -0
- package/dist/web/server/assets/{attention-CRvxt22X.js → attention-DwGaur_w.js} +21 -8
- package/dist/web/server/assets/{config-B5CS8juO.js → config-B9dJiji_.js} +2 -2
- package/dist/web/server/assets/{config-D117117T.js → config-D3MR2VjE.js} +6 -6
- package/dist/web/server/assets/{createSsrRpc-CwTd0zrB.js → createSsrRpc-qesavJv-.js} +1 -1
- package/dist/web/server/assets/{login-va4EtvA8.js → login-CRd1yTH5.js} +1 -1
- package/dist/web/server/assets/{login-IF0Gbsuq.js → login-ZN6KV8n-.js} +2 -2
- package/dist/web/server/assets/{mcp-C96PBxpb.js → mcp-BQ15a9dG.js} +4 -4
- package/dist/web/server/assets/{mcp-Bm9U6x7N.js → mcp-CYQuYWGX.js} +2 -2
- package/dist/web/server/assets/{page-title-CwcbXMhx.js → page-title-CVY-c2Pd.js} +6 -3
- package/dist/web/server/assets/{router-8Iq19GOz.js → router-CPdWGKQ5.js} +192 -60
- package/dist/web/server/assets/{routes-Kwam6JmS.js → routes-BPloBDc8.js} +9 -6
- package/dist/web/server/assets/{routes-BLo-fWbQ.js → routes-Dw1K3TQw.js} +132 -31
- package/dist/web/server/assets/{routes-BXvYYFrN.js → routes-xDPesCQu.js} +2 -2
- package/dist/web/server/assets/{skills-BqCnA-74.js → skills-6VSpEORe.js} +2 -2
- package/dist/web/server/assets/{skills-DSezIdDc.js → skills-D0xrNc2_.js} +5 -5
- package/dist/web/server/assets/{style-C2hIPY_Y.js → style-aMybyKzc.js} +1 -1
- package/dist/web/server/assets/{system-CcLCmkIC.js → system-B5sPgdQW.js} +2 -2
- package/dist/web/server/assets/{system-E0VePdzO.js → system-CXmiWyDG.js} +3 -3
- package/dist/web/server/assets/{teams-DScFp8mK.js → teams-ClRBVSYU.js} +2 -2
- package/dist/web/server/assets/{teams-DxA-vnzY.js → teams-Dq4RCxis.js} +2 -2
- package/dist/web/server/assets/{teams-CQVV18D3.js → teams-iXiCnN2i.js} +5 -5
- package/dist/web/server/assets/{teams-CdCmBJIj.js → teams-yF3I_Zjq.js} +5 -5
- package/dist/web/server/assets/{telegram-DR7xijeS.js → telegram-D9U9c1MN.js} +2 -2
- package/dist/web/server/assets/{telegram-DJ8s_91Y.js → telegram-DwEgyR1x.js} +5 -5
- package/dist/web/server/assets/{tools-CsH9DI-4.js → tools-DflVIdDd.js} +2 -2
- package/dist/web/server/assets/{tools-V6kezUpL.js → tools-VPIKjr3y.js} +3 -3
- package/dist/web/server/assets/{use-resource-CjcJwn7F.js → use-resource-CbHGYti0.js} +1 -1
- package/dist/web/server/assets/{welcome-BpmcD-ia.js → welcome-7DrYZVs6.js} +2 -2
- package/dist/web/server/assets/{welcome-Ya8TkL4v.js → welcome-966nOyyK.js} +6 -6
- package/dist/web/server/server.js +4 -4
- package/dist/web-server.js +4 -0
- package/dist/web-server.js.map +1 -1
- package/dist/worker.js +17 -13
- package/dist/worker.js.map +1 -1
- package/package.json +4 -4
- package/dist/web/client/assets/AddProviderDialog-CkwSq3C7.js +0 -1
- package/dist/web/client/assets/AgentTemplateParts-CEn_4qVs.js +0 -1
- package/dist/web/client/assets/ConfirmDialog-VqBOFZEp.js +0 -1
- package/dist/web/client/assets/ConnectionsView-ByARMcWP.js +0 -1
- package/dist/web/client/assets/SkillsParts-UvNK5SYP.js +0 -1
- package/dist/web/client/assets/SpawnTeamModal-DG5UbJNK.js +0 -1
- package/dist/web/client/assets/TeamForm-DGlxWv4e.js +0 -1
- package/dist/web/client/assets/TeamThread-mkwODO0S.js +0 -1
- package/dist/web/client/assets/UnsavedChangesGuard-BmdwLH99.js +0 -1
- package/dist/web/client/assets/_id-CvcxNmBH.js +0 -1
- package/dist/web/client/assets/_id-UyBk7gRl.js +0 -1
- package/dist/web/client/assets/access-C8d8vaQ6.js +0 -1
- package/dist/web/client/assets/agents-CgtzqBpD.js +0 -1
- package/dist/web/client/assets/agents-D7W4BT8r.js +0 -1
- package/dist/web/client/assets/arrow-right-D0HKRb7U.js +0 -1
- package/dist/web/client/assets/attention-D9mQWoKt.js +0 -1
- package/dist/web/client/assets/chevron-right-bs0TUSl2.js +0 -1
- package/dist/web/client/assets/config-Dw6GWf38.js +0 -1
- package/dist/web/client/assets/createLucideIcon-DkniuEtD.js +0 -1
- package/dist/web/client/assets/index-YW0gXPfk.js +0 -14
- package/dist/web/client/assets/mcp-BUWu4TvS.js +0 -1
- package/dist/web/client/assets/plus-CLGNN5QX.js +0 -1
- package/dist/web/client/assets/routes-BxIIyGho.js +0 -85
- package/dist/web/client/assets/skills-C7DzIwFJ.js +0 -1
- package/dist/web/client/assets/style-CA2GAk9b.js +0 -7
- package/dist/web/client/assets/styles-C3CDSGAr.css +0 -2
- package/dist/web/client/assets/teams-BEIJHObN.js +0 -1
- package/dist/web/client/assets/teams-DlOc7Ods.js +0 -1
- package/dist/web/client/assets/telegram-DKHq5DpE.js +0 -1
- package/dist/web/client/assets/tools-BKIpLaiC.js +0 -1
- package/dist/web/client/assets/use-resource-CQaIZbpy.js +0 -1
- package/dist/web/client/assets/welcome-CyS4Hrd-.js +0 -1
- package/dist/web/server/assets/_tanstack-start-manifest_v-CR3jm1nY.js +0 -256
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as createServerFn } from "../server.js";
|
|
2
|
-
import { t as createSsrRpc } from "./createSsrRpc-
|
|
2
|
+
import { t as createSsrRpc } from "./createSsrRpc-qesavJv-.js";
|
|
3
3
|
import { createFileRoute, lazyRouteComponent } from "@tanstack/react-router";
|
|
4
4
|
//#region src/routes/agents/index.tsx
|
|
5
|
-
var $$splitComponentImporter = () => import("./agents-
|
|
5
|
+
var $$splitComponentImporter = () => import("./agents-vuXrAv1j.js");
|
|
6
6
|
var fetchAgents = createServerFn({ method: "GET" }).handler(createSsrRpc("f715bab0037380aa3db7e237e7cf1e74168c363f48a960bb1ddfa5560de3a74e"));
|
|
7
7
|
var Route = createFileRoute("/agents/")({
|
|
8
8
|
loader: () => fetchAgents(),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as createServerFn } from "../server.js";
|
|
2
|
-
import { t as createSsrRpc } from "./createSsrRpc-
|
|
2
|
+
import { t as createSsrRpc } from "./createSsrRpc-qesavJv-.js";
|
|
3
3
|
import { createFileRoute, lazyRouteComponent } from "@tanstack/react-router";
|
|
4
4
|
//#region src/routes/templates/agents/index.tsx
|
|
5
|
-
var $$splitComponentImporter = () => import("./agents-
|
|
5
|
+
var $$splitComponentImporter = () => import("./agents-CwzhpDPm.js");
|
|
6
6
|
var fetchTemplates = createServerFn({ method: "GET" }).handler(createSsrRpc("7bc7f3b145d10e7a733fbe068ce367dda04ec2f1cdb53f0d6dcba3838eb2deeb"));
|
|
7
7
|
var Route = createFileRoute("/templates/agents/")({
|
|
8
8
|
validateSearch: (search) => ({ new: search.new === 1 || search.new === "1" ? 1 : void 0 }),
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as RowMenu, D as GroupHeader, G as DialogActions, K as Button, M as SetupCard, O as ListRow, W as Dialog, _ as CardEmpty, c as SelectField, dt as
|
|
2
|
-
import { t as ConfirmDialog } from "./ConfirmDialog-
|
|
1
|
+
import { A as RowMenu, D as GroupHeader, G as DialogActions, K as Button, M as SetupCard, O as ListRow, W as Dialog, _ as CardEmpty, c as SelectField, dt as api, g as CardBody, j as SearchField, k as Notice, pt as errorMessage, q as AgentAvatar, t as SpawnDialog, w as Chip, x as CardToolbar, y as CardList } from "./SpawnDialog-3wNx0W1R.js";
|
|
2
|
+
import { t as ConfirmDialog } from "./ConfirmDialog-Z-uYbE9B.js";
|
|
3
3
|
import { t as Segmented } from "./Segmented-3ZLdqa5U.js";
|
|
4
|
-
import { i as unarchiveAgent, n as deleteAgent, t as archiveAgent } from "./agent-actions-
|
|
4
|
+
import { i as unarchiveAgent, n as deleteAgent, t as archiveAgent } from "./agent-actions-C07Cp5Ue.js";
|
|
5
5
|
import { T as templateName, c as groupAgents, n as agentCounts, r as agentModel, s as count } from "./manage-Ce6cI4eW.js";
|
|
6
|
-
import { t as Route } from "./agents-
|
|
7
|
-
import { t as ManagePage } from "./ManagePage-
|
|
6
|
+
import { t as Route } from "./agents-DCWEoaxY.js";
|
|
7
|
+
import { t as ManagePage } from "./ManagePage-BR9FwVZM.js";
|
|
8
8
|
import { useEffect, useRef, useState } from "react";
|
|
9
9
|
import { Link, useRouter } from "@tanstack/react-router";
|
|
10
10
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { n as createServerFn } from "../server.js";
|
|
2
|
-
import { t as createSsrRpc } from "./createSsrRpc-
|
|
2
|
+
import { t as createSsrRpc } from "./createSsrRpc-qesavJv-.js";
|
|
3
3
|
import { createFileRoute, lazyRouteComponent } from "@tanstack/react-router";
|
|
4
4
|
//#region src/routes/attention/index.tsx
|
|
5
|
-
var $$splitComponentImporter = () => import("./attention-
|
|
5
|
+
var $$splitComponentImporter = () => import("./attention-DwGaur_w.js");
|
|
6
6
|
/** Questions expire in minutes and commands in two: the page keeps itself current. */
|
|
7
|
+
/** "2 minutes ago" moves on even when nothing in the list changes. */
|
|
7
8
|
/** What the item's button says: where it takes you and what you do there. */
|
|
8
9
|
var loadAttention = createServerFn({ method: "GET" }).handler(createSsrRpc("883b401299422096ee31ee824f9a24b49d06bdcedce398789778c4c549a92f3a"));
|
|
9
10
|
var Route = createFileRoute("/attention/")({
|
|
@@ -5,6 +5,7 @@ import { n as daemonClient } from "./daemon-client-B_ZRIIrT.js";
|
|
|
5
5
|
var LIST_PATH = "/api/attention?state=all&limit=200";
|
|
6
6
|
var SUMMARY_PATH = "/api/attention/summary";
|
|
7
7
|
/** Questions expire in minutes and commands in two: the page keeps itself current. */
|
|
8
|
+
/** "2 minutes ago" moves on even when nothing in the list changes. */
|
|
8
9
|
/** What the item's button says: where it takes you and what you do there. */
|
|
9
10
|
var loadAttention_createServerFn_handler = createServerRpc({
|
|
10
11
|
id: "883b401299422096ee31ee824f9a24b49d06bdcedce398789778c4c549a92f3a",
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { K as Button, M as SetupCard, O as ListRow, _ as CardEmpty, dt as
|
|
2
|
-
import { t as useHydrated } from "./use-resource-
|
|
1
|
+
import { K as Button, M as SetupCard, O as ListRow, _ as CardEmpty, dt as api, g as CardBody, i as FilterSelect, k as Notice, lt as useLive, m as Banner, pt as errorMessage, w as Chip, x as CardToolbar, y as CardList } from "./SpawnDialog-3wNx0W1R.js";
|
|
2
|
+
import { t as useHydrated } from "./use-resource-CbHGYti0.js";
|
|
3
3
|
import { r as ago } from "./ModelMenu-D-hTgYOO.js";
|
|
4
4
|
import { t as Segmented } from "./Segmented-3ZLdqa5U.js";
|
|
5
5
|
import { a as attentionSource, m as severityLabel, o as attentionSummary, t as ATTENTION_KINDS } from "./manage-Ce6cI4eW.js";
|
|
6
|
-
import { i as useAttentionCount } from "./page-title-
|
|
7
|
-
import { n as PageHeader, r as PageShell } from "./createSsrRpc-
|
|
8
|
-
import { t as Route } from "./attention-
|
|
9
|
-
import { useEffect, useState } from "react";
|
|
6
|
+
import { i as useAttentionCount } from "./page-title-CVY-c2Pd.js";
|
|
7
|
+
import { n as PageHeader, r as PageShell } from "./createSsrRpc-qesavJv-.js";
|
|
8
|
+
import { t as Route } from "./attention-BqCnJ1hg.js";
|
|
9
|
+
import { useEffect, useRef, useState } from "react";
|
|
10
10
|
import { Link } from "@tanstack/react-router";
|
|
11
11
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
12
12
|
import { BellRing } from "lucide-react";
|
|
@@ -15,6 +15,8 @@ var LIST_PATH = "/api/attention?state=all&limit=200";
|
|
|
15
15
|
var SUMMARY_PATH = "/api/attention/summary";
|
|
16
16
|
/** Questions expire in minutes and commands in two: the page keeps itself current. */
|
|
17
17
|
var POLL_MS = 5e3;
|
|
18
|
+
/** "2 minutes ago" moves on even when nothing in the list changes. */
|
|
19
|
+
var CLOCK_MS = 3e4;
|
|
18
20
|
/** What the item's button says: where it takes you and what you do there. */
|
|
19
21
|
function actionLabel(item) {
|
|
20
22
|
switch (item.kind) {
|
|
@@ -39,6 +41,8 @@ function AttentionCenter() {
|
|
|
39
41
|
const [busy, setBusy] = useState(null);
|
|
40
42
|
const [notice, setNotice] = useState(null);
|
|
41
43
|
const counts = useAttentionCount();
|
|
44
|
+
const live = useLive();
|
|
45
|
+
const revision = useRef(null);
|
|
42
46
|
const hydrated = useHydrated();
|
|
43
47
|
const visible = list.items.filter((item) => (state === "all" || (state === "open" ? item.acknowledgedAt === null : item.acknowledgedAt !== null)) && (kind === "all" || item.kind === kind) && (severity === "all" || item.severity === severity));
|
|
44
48
|
const openCount = list.items.filter((item) => item.acknowledgedAt === null).length;
|
|
@@ -51,13 +55,22 @@ function AttentionCenter() {
|
|
|
51
55
|
setSummary(nextSummary);
|
|
52
56
|
setNow(Date.now());
|
|
53
57
|
}
|
|
58
|
+
useEffect(() => live.subscribe("attention", (event) => {
|
|
59
|
+
const changed = revision.current !== event.revision;
|
|
60
|
+
revision.current = event.revision;
|
|
61
|
+
if (changed) refresh().catch(() => {});
|
|
62
|
+
}), [live.subscribe]);
|
|
54
63
|
useEffect(() => {
|
|
55
|
-
|
|
64
|
+
const timer = setInterval(() => setNow(Date.now()), CLOCK_MS);
|
|
65
|
+
return () => clearInterval(timer);
|
|
66
|
+
}, []);
|
|
67
|
+
useEffect(() => {
|
|
68
|
+
if (busy !== null || live.connected) return;
|
|
56
69
|
const timer = setInterval(() => {
|
|
57
70
|
if (document.visibilityState === "visible") refresh().catch(() => {});
|
|
58
71
|
}, POLL_MS);
|
|
59
72
|
return () => clearInterval(timer);
|
|
60
|
-
}, [busy]);
|
|
73
|
+
}, [busy, live.connected]);
|
|
61
74
|
async function run(key, request) {
|
|
62
75
|
setBusy(key);
|
|
63
76
|
setNotice(null);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as createServerFn } from "../server.js";
|
|
2
|
-
import { t as createSsrRpc } from "./createSsrRpc-
|
|
2
|
+
import { t as createSsrRpc } from "./createSsrRpc-qesavJv-.js";
|
|
3
3
|
import { createFileRoute, lazyRouteComponent } from "@tanstack/react-router";
|
|
4
4
|
//#region src/routes/config/index.tsx
|
|
5
|
-
var $$splitComponentImporter = () => import("./config-
|
|
5
|
+
var $$splitComponentImporter = () => import("./config-D3MR2VjE.js");
|
|
6
6
|
var fetchModelsPage = createServerFn({ method: "GET" }).handler(createSsrRpc("71b6b12251ac92cf4ee888c1d2b6eba3beaac079f9c39eaed95fafcd15908731"));
|
|
7
7
|
var Route = createFileRoute("/config/")({
|
|
8
8
|
validateSearch: (search) => ({
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { K as Button, M as SetupCard, N as Switch, P as Waiting, W as Dialog, dt as
|
|
2
|
-
import { r as useResource } from "./use-resource-
|
|
1
|
+
import { K as Button, M as SetupCard, N as Switch, P as Waiting, W as Dialog, dt as api, h as CARD_ROW, j as SearchField, m as Banner, pt as errorMessage, w as Chip } from "./SpawnDialog-3wNx0W1R.js";
|
|
2
|
+
import { r as useResource } from "./use-resource-CbHGYti0.js";
|
|
3
3
|
import { a as credentialLine, c as matchesModel, d as providerStatus, f as usedByLine, l as modelName, o as factsLine, r as ago, u as priceLine } from "./ModelMenu-D-hTgYOO.js";
|
|
4
|
-
import { t as ConfirmDialog } from "./ConfirmDialog-
|
|
4
|
+
import { t as ConfirmDialog } from "./ConfirmDialog-Z-uYbE9B.js";
|
|
5
5
|
import { t as Segmented } from "./Segmented-3ZLdqa5U.js";
|
|
6
|
-
import { t as Route } from "./config-
|
|
7
|
-
import { t as ConfigPage } from "./ConfigPage-
|
|
8
|
-
import { c as ProviderAvatar, l as StateChip, o as FailureBox, s as ModelRow, t as AddProviderDialog } from "./AddProviderDialog-
|
|
6
|
+
import { t as Route } from "./config-B9dJiji_.js";
|
|
7
|
+
import { t as ConfigPage } from "./ConfigPage-qP9ejjuw.js";
|
|
8
|
+
import { c as ProviderAvatar, l as StateChip, o as FailureBox, s as ModelRow, t as AddProviderDialog } from "./AddProviderDialog-BbpuvC2a.js";
|
|
9
9
|
import { useId, useMemo, useState } from "react";
|
|
10
10
|
import { useRouter } from "@tanstack/react-router";
|
|
11
11
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { i as getServerFnById, r as TSS_SERVER_FUNCTION } from "../server.js";
|
|
2
2
|
import { p as cn } from "./ModelMenu-D-hTgYOO.js";
|
|
3
|
-
import { n as usePageTitle } from "./page-title-
|
|
3
|
+
import { n as usePageTitle } from "./page-title-CVY-c2Pd.js";
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/Page.tsx
|
|
6
6
|
var PAGE_SIZE_CLASS = {
|
|
@@ -98,7 +98,7 @@ function useThemeMode() {
|
|
|
98
98
|
}
|
|
99
99
|
//#endregion
|
|
100
100
|
//#region src/routes/login.tsx
|
|
101
|
-
var $$splitComponentImporter = () => import("./login-
|
|
101
|
+
var $$splitComponentImporter = () => import("./login-ZN6KV8n-.js");
|
|
102
102
|
var Route = createFileRoute("/login")({
|
|
103
103
|
validateSearch: (search) => ({ error: search.error === "token" || search.error === "origin" ? search.error : void 0 }),
|
|
104
104
|
component: lazyRouteComponent($$splitComponentImporter, "component")
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as usePageTitle } from "./page-title-
|
|
2
|
-
import { a as PawIcon, i as useThemeMode, o as BaziuLogo, r as setThemeMode, t as Route } from "./login-
|
|
1
|
+
import { n as usePageTitle } from "./page-title-CVY-c2Pd.js";
|
|
2
|
+
import { a as PawIcon, i as useThemeMode, o as BaziuLogo, r as setThemeMode, t as Route } from "./login-CRd1yTH5.js";
|
|
3
3
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
4
|
import { KeyRound, MessageSquareText, Monitor, Moon, Sun, UsersRound } from "lucide-react";
|
|
5
5
|
//#region src/components/ThemeToggle.tsx
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { K as Button, M as SetupCard, O as ListRow, P as Waiting, b as CardRow, c as SelectField, dt as
|
|
2
|
-
import { t as ConfirmDialog } from "./ConfirmDialog-
|
|
3
|
-
import { t as Route } from "./mcp-
|
|
4
|
-
import { t as ConfigPage } from "./ConfigPage-
|
|
1
|
+
import { K as Button, M as SetupCard, O as ListRow, P as Waiting, b as CardRow, c as SelectField, dt as api, f as TextField, g as CardBody, k as Notice, pt as errorMessage, s as SecretField, v as CardForm, w as Chip, y as CardList } from "./SpawnDialog-3wNx0W1R.js";
|
|
2
|
+
import { t as ConfirmDialog } from "./ConfirmDialog-Z-uYbE9B.js";
|
|
3
|
+
import { t as Route } from "./mcp-CYQuYWGX.js";
|
|
4
|
+
import { t as ConfigPage } from "./ConfigPage-qP9ejjuw.js";
|
|
5
5
|
import { useState } from "react";
|
|
6
6
|
import { useRouter } from "@tanstack/react-router";
|
|
7
7
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as createServerFn } from "../server.js";
|
|
2
|
-
import { t as createSsrRpc } from "./createSsrRpc-
|
|
2
|
+
import { t as createSsrRpc } from "./createSsrRpc-qesavJv-.js";
|
|
3
3
|
import { createFileRoute, lazyRouteComponent } from "@tanstack/react-router";
|
|
4
4
|
//#region src/routes/config/mcp.tsx
|
|
5
|
-
var $$splitComponentImporter = () => import("./mcp-
|
|
5
|
+
var $$splitComponentImporter = () => import("./mcp-BQ15a9dG.js");
|
|
6
6
|
var fetchServers = createServerFn({ method: "GET" }).handler(createSsrRpc("278849457893891c3d22806d15e11a0a42cc3630b30e9e62b74cf2d3b982ded7"));
|
|
7
7
|
var Route = createFileRoute("/config/mcp")({
|
|
8
8
|
loader: () => fetchServers(),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { dt as api, lt as useLive } from "./SpawnDialog-3wNx0W1R.js";
|
|
2
2
|
import { createContext, useCallback, useContext, useEffect, useMemo, useRef, useState } from "react";
|
|
3
3
|
import { useRouterState } from "@tanstack/react-router";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
@@ -29,6 +29,7 @@ function AttentionCountProvider({ enabled, children }) {
|
|
|
29
29
|
agentWaits: 0
|
|
30
30
|
});
|
|
31
31
|
const controller = useRef(null);
|
|
32
|
+
const live = useLive();
|
|
32
33
|
const load = useCallback(() => {
|
|
33
34
|
if (document.visibilityState === "hidden") return;
|
|
34
35
|
controller.current?.abort();
|
|
@@ -36,8 +37,9 @@ function AttentionCountProvider({ enabled, children }) {
|
|
|
36
37
|
controller.current = current;
|
|
37
38
|
api("/api/attention/summary", { signal: current.signal }).then((summary) => setCounts(attentionCounts(summary))).catch(() => {});
|
|
38
39
|
}, []);
|
|
40
|
+
useEffect(() => live.subscribe("attention", (event) => setCounts(attentionCounts(event.summary))), [live.subscribe]);
|
|
39
41
|
useEffect(() => {
|
|
40
|
-
if (!enabled) return;
|
|
42
|
+
if (!enabled || live.connected) return;
|
|
41
43
|
load();
|
|
42
44
|
const timer = setInterval(load, POLL_MS);
|
|
43
45
|
const onShow = () => {
|
|
@@ -52,7 +54,8 @@ function AttentionCountProvider({ enabled, children }) {
|
|
|
52
54
|
}, [
|
|
53
55
|
enabled,
|
|
54
56
|
load,
|
|
55
|
-
pathname
|
|
57
|
+
pathname,
|
|
58
|
+
live.connected
|
|
56
59
|
]);
|
|
57
60
|
const value = useMemo(() => ({
|
|
58
61
|
...counts,
|
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { r as readCookie } from "./cookies-HnTYjKRp.js";
|
|
2
|
-
import { $ as agentState, H as parseWorkspaceSearch, K as Button, W as Dialog$1, dt as
|
|
2
|
+
import { $ as agentState, H as parseWorkspaceSearch, K as Button, W as Dialog$1, ct as LiveProvider, dt as api, et as shortTime, lt as useLive, pt as errorMessage, q as AgentAvatar, t as SpawnDialog } from "./SpawnDialog-3wNx0W1R.js";
|
|
3
3
|
import { n as publicOriginConfig } from "./public-origin-BpDkdS5Q.js";
|
|
4
4
|
import { t as DAEMON_BASE_URL } from "./daemon-client-B_ZRIIrT.js";
|
|
5
|
-
import { i as useAttentionCount, r as AttentionCountProvider, t as PageTitleProvider } from "./page-title-
|
|
6
|
-
import { r as PageShell } from "./createSsrRpc-
|
|
7
|
-
import { a as PawIcon, i as useThemeMode, n as THEME_MODES, o as BaziuLogo, r as setThemeMode, t as Route$3 } from "./login-
|
|
8
|
-
import { i as isTyping, n as NEW_CONVERSATION_EVENT, r as SHORTCUTS, t as Route$4 } from "./routes-
|
|
9
|
-
import { i as isSetupOpen, n as PUBLIC_PATHS, r as fetchAuthState, t as Route$5 } from "./welcome-
|
|
10
|
-
import { t as Route$6 } from "./teams-
|
|
11
|
-
import { t as Route$7 } from "./skills-
|
|
12
|
-
import { t as Route$8 } from "./config-
|
|
13
|
-
import { t as Route$9 } from "./attention-
|
|
14
|
-
import { t as Route$10 } from "./agents-
|
|
15
|
-
import { t as Route$11 } from "./tools-
|
|
16
|
-
import { t as Route$12 } from "./telegram-
|
|
17
|
-
import { t as Route$13 } from "./system-
|
|
18
|
-
import { t as Route$14 } from "./mcp-
|
|
19
|
-
import { t as Route$15 } from "./access-
|
|
20
|
-
import { t as Route$16 } from "./teams-
|
|
21
|
-
import { t as Route$17 } from "./agents-
|
|
22
|
-
import { t as Route$18 } from "./_id-
|
|
23
|
-
import { t as Route$19 } from "./_id-
|
|
24
|
-
import { useEffect, useMemo, useState } from "react";
|
|
5
|
+
import { i as useAttentionCount, r as AttentionCountProvider, t as PageTitleProvider } from "./page-title-CVY-c2Pd.js";
|
|
6
|
+
import { r as PageShell } from "./createSsrRpc-qesavJv-.js";
|
|
7
|
+
import { a as PawIcon, i as useThemeMode, n as THEME_MODES, o as BaziuLogo, r as setThemeMode, t as Route$3 } from "./login-CRd1yTH5.js";
|
|
8
|
+
import { i as isTyping, n as NEW_CONVERSATION_EVENT, r as SHORTCUTS, t as Route$4 } from "./routes-BPloBDc8.js";
|
|
9
|
+
import { i as isSetupOpen, n as PUBLIC_PATHS, r as fetchAuthState, t as Route$5 } from "./welcome-7DrYZVs6.js";
|
|
10
|
+
import { t as Route$6 } from "./teams-ClRBVSYU.js";
|
|
11
|
+
import { t as Route$7 } from "./skills-6VSpEORe.js";
|
|
12
|
+
import { t as Route$8 } from "./config-B9dJiji_.js";
|
|
13
|
+
import { t as Route$9 } from "./attention-BqCnJ1hg.js";
|
|
14
|
+
import { t as Route$10 } from "./agents-DCWEoaxY.js";
|
|
15
|
+
import { t as Route$11 } from "./tools-DflVIdDd.js";
|
|
16
|
+
import { t as Route$12 } from "./telegram-D9U9c1MN.js";
|
|
17
|
+
import { t as Route$13 } from "./system-B5sPgdQW.js";
|
|
18
|
+
import { t as Route$14 } from "./mcp-CYQuYWGX.js";
|
|
19
|
+
import { t as Route$15 } from "./access-CyUoElTP.js";
|
|
20
|
+
import { t as Route$16 } from "./teams-Dq4RCxis.js";
|
|
21
|
+
import { t as Route$17 } from "./agents-DTub-rJk.js";
|
|
22
|
+
import { t as Route$18 } from "./_id-d2OwovYV.js";
|
|
23
|
+
import { t as Route$19 } from "./_id-BpfoPuTv.js";
|
|
24
|
+
import { useEffect, useMemo, useRef, useState, useSyncExternalStore } from "react";
|
|
25
25
|
import { HeadContent, Link, Outlet, Scripts, createFileRoute, createRootRoute, createRouter, redirect, useNavigate, useRouter, useRouterState } from "@tanstack/react-router";
|
|
26
26
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
27
|
-
import { BellRing, Check, Keyboard, LayoutGrid, LogOut, MessageSquarePlus, Monitor, Moon, Search, Settings2, Sun, UserPlus, UserRound } from "lucide-react";
|
|
27
|
+
import { Bell, BellOff, BellRing, Check, Keyboard, LayoutGrid, LogOut, MessageSquarePlus, Monitor, Moon, Search, Settings2, Sun, UserPlus, UserRound } from "lucide-react";
|
|
28
28
|
import { Dialog, DropdownMenu } from "radix-ui";
|
|
29
29
|
//#region src/components/RouteStates.tsx
|
|
30
30
|
/** The router's error view for every route: a loader failed. The top nav stays usable. */
|
|
@@ -93,6 +93,89 @@ function Footer() {
|
|
|
93
93
|
});
|
|
94
94
|
}
|
|
95
95
|
//#endregion
|
|
96
|
+
//#region src/lib/desktop-notifications.tsx
|
|
97
|
+
var KEY = "bz_notify";
|
|
98
|
+
var CHANGED = "bz-notify-change";
|
|
99
|
+
/** A burst (several Agents at once) shows at most this many notifications. */
|
|
100
|
+
var MAX_AT_ONCE = 3;
|
|
101
|
+
function read() {
|
|
102
|
+
if (typeof window === "undefined" || !("Notification" in window) || !window.isSecureContext) return "unsupported";
|
|
103
|
+
if (Notification.permission === "denied") return "blocked";
|
|
104
|
+
let chosen = false;
|
|
105
|
+
try {
|
|
106
|
+
chosen = window.localStorage.getItem(KEY) === "on";
|
|
107
|
+
} catch {
|
|
108
|
+
chosen = false;
|
|
109
|
+
}
|
|
110
|
+
return chosen && Notification.permission === "granted" ? "on" : "off";
|
|
111
|
+
}
|
|
112
|
+
function subscribe(onChange) {
|
|
113
|
+
window.addEventListener(CHANGED, onChange);
|
|
114
|
+
window.addEventListener("storage", onChange);
|
|
115
|
+
return () => {
|
|
116
|
+
window.removeEventListener(CHANGED, onChange);
|
|
117
|
+
window.removeEventListener("storage", onChange);
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
function store(value) {
|
|
121
|
+
try {
|
|
122
|
+
window.localStorage.setItem(KEY, value);
|
|
123
|
+
} catch {}
|
|
124
|
+
window.dispatchEvent(new Event(CHANGED));
|
|
125
|
+
}
|
|
126
|
+
/** Whether desktop notifications are on in this browser; the server renders "off". */
|
|
127
|
+
function useNotificationsState() {
|
|
128
|
+
return useSyncExternalStore(subscribe, read, () => "off");
|
|
129
|
+
}
|
|
130
|
+
/** Ask the browser's permission (it must follow a click) and turn notifications on if granted. */
|
|
131
|
+
async function turnNotificationsOn() {
|
|
132
|
+
if (read() === "unsupported") return "unsupported";
|
|
133
|
+
store((Notification.permission === "granted" ? "granted" : await Notification.requestPermission()) === "granted" ? "on" : "off");
|
|
134
|
+
return read();
|
|
135
|
+
}
|
|
136
|
+
function turnNotificationsOff() {
|
|
137
|
+
store("off");
|
|
138
|
+
}
|
|
139
|
+
/** The items that started waiting since `known`, oldest first, at most a few. */
|
|
140
|
+
function newlyWaiting(known, waiting) {
|
|
141
|
+
return waiting.filter((item) => !known.has(item.key)).toSorted((a, b) => a.occurredAt - b.occurredAt).slice(0, MAX_AT_ONCE);
|
|
142
|
+
}
|
|
143
|
+
/** Shows the notifications; rendered once, inside the live feed's provider. */
|
|
144
|
+
function DesktopNotifier() {
|
|
145
|
+
const live = useLive();
|
|
146
|
+
const router = useRouter();
|
|
147
|
+
const known = useRef(null);
|
|
148
|
+
useEffect(() => live.subscribe("attention", (event) => {
|
|
149
|
+
const fresh = known.current === null ? [] : newlyWaiting(known.current ?? /* @__PURE__ */ new Set(), event.waiting);
|
|
150
|
+
known.current = new Set(event.waiting.map((item) => item.key));
|
|
151
|
+
if (fresh.length === 0 || read() !== "on") return;
|
|
152
|
+
if (!live.isLeader() || live.anyTabFocused()) return;
|
|
153
|
+
for (const item of fresh) {
|
|
154
|
+
let notification;
|
|
155
|
+
try {
|
|
156
|
+
notification = new Notification(item.title, {
|
|
157
|
+
body: item.diagnostic,
|
|
158
|
+
tag: item.key,
|
|
159
|
+
icon: "/baziu.svg"
|
|
160
|
+
});
|
|
161
|
+
} catch {
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
164
|
+
notification.onclick = () => {
|
|
165
|
+
window.focus();
|
|
166
|
+
notification.close();
|
|
167
|
+
router.navigate({ href: item.href });
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
}), [
|
|
171
|
+
live.subscribe,
|
|
172
|
+
live.isLeader,
|
|
173
|
+
live.anyTabFocused,
|
|
174
|
+
router
|
|
175
|
+
]);
|
|
176
|
+
return null;
|
|
177
|
+
}
|
|
178
|
+
//#endregion
|
|
96
179
|
//#region src/components/JumpPalette.tsx
|
|
97
180
|
var PAGES = [
|
|
98
181
|
[
|
|
@@ -168,10 +251,13 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
168
251
|
const [recent, setRecent] = useState([]);
|
|
169
252
|
const [dark, setDark] = useState(false);
|
|
170
253
|
const [spawning, setSpawning] = useState(false);
|
|
254
|
+
const [loaded, setLoaded] = useState(false);
|
|
255
|
+
const [enterPending, setEnterPending] = useState(false);
|
|
171
256
|
useEffect(() => {
|
|
172
257
|
if (!open) return;
|
|
173
258
|
setQuery("");
|
|
174
259
|
setActive(0);
|
|
260
|
+
setEnterPending(false);
|
|
175
261
|
setDark(document.documentElement.classList.contains("dark"));
|
|
176
262
|
const controller = new AbortController();
|
|
177
263
|
const signal = controller.signal;
|
|
@@ -185,6 +271,7 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
185
271
|
setTeams(nextTeams);
|
|
186
272
|
setActivity(nextActivity.agents);
|
|
187
273
|
setProfiles(nextProfiles);
|
|
274
|
+
setLoaded(true);
|
|
188
275
|
const latest = nextActivity.agents.filter((entry) => entry.lastActivityAt !== null).toSorted((a, b) => (b.lastActivityAt ?? 0) - (a.lastActivityAt ?? 0)).slice(0, RECENT_AGENTS);
|
|
189
276
|
setRecent((await Promise.all(latest.map((entry) => api(`/api/agents/${encodeURIComponent(entry.agentId)}/conversations?limit=3`, { signal }).then((list) => list.conversations.map((conversation) => ({
|
|
190
277
|
id: conversation.id,
|
|
@@ -193,7 +280,9 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
193
280
|
updatedAt: conversation.updatedAt,
|
|
194
281
|
selected: conversation.id === list.selectedId
|
|
195
282
|
})))))).flat().toSorted((a, b) => b.updatedAt - a.updatedAt).slice(0, RECENT_CONVERSATIONS));
|
|
196
|
-
}).catch(() => {
|
|
283
|
+
}).catch(() => {
|
|
284
|
+
if (!signal.aborted) setLoaded(true);
|
|
285
|
+
});
|
|
197
286
|
return () => controller.abort();
|
|
198
287
|
}, [open]);
|
|
199
288
|
const shown = filterDestinations(useMemo(() => {
|
|
@@ -338,6 +427,15 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
338
427
|
]), query);
|
|
339
428
|
const current = Math.min(active, Math.max(shown.length - 1, 0));
|
|
340
429
|
const hereTeam = location.pathname === "/" ? parseWorkspaceSearch(location.search).team ?? agents.find((agent) => agent.id === parseWorkspaceSearch(location.search).agent)?.teamId : void 0;
|
|
430
|
+
useEffect(() => {
|
|
431
|
+
if (!open || !enterPending || !loaded) return;
|
|
432
|
+
setEnterPending(false);
|
|
433
|
+
go(shown[current]);
|
|
434
|
+
}, [
|
|
435
|
+
open,
|
|
436
|
+
enterPending,
|
|
437
|
+
loaded
|
|
438
|
+
]);
|
|
341
439
|
function go(destination) {
|
|
342
440
|
if (!destination) return;
|
|
343
441
|
onClose();
|
|
@@ -388,7 +486,8 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
388
486
|
setActive(Math.max(current - 1, 0));
|
|
389
487
|
} else if (event.key === "Enter") {
|
|
390
488
|
event.preventDefault();
|
|
391
|
-
go(shown[current]);
|
|
489
|
+
if (loaded) go(shown[current]);
|
|
490
|
+
else setEnterPending(true);
|
|
392
491
|
}
|
|
393
492
|
},
|
|
394
493
|
style: { outline: "none" },
|
|
@@ -405,13 +504,9 @@ function JumpPalette({ open, onClose, onShowShortcuts }) {
|
|
|
405
504
|
role: "listbox",
|
|
406
505
|
"aria-label": "Destinations and actions",
|
|
407
506
|
className: "overflow-y-auto p-1.5",
|
|
408
|
-
children: [shown.length === 0 && /* @__PURE__ */
|
|
507
|
+
children: [shown.length === 0 && /* @__PURE__ */ jsx("p", {
|
|
409
508
|
className: "px-3 py-6 text-center text-sm text-muted-foreground",
|
|
410
|
-
children:
|
|
411
|
-
"Nothing matches “",
|
|
412
|
-
query,
|
|
413
|
-
"”."
|
|
414
|
-
]
|
|
509
|
+
children: loaded ? `Nothing matches “${query}”.` : "Loading…"
|
|
415
510
|
}), shown.map((destination, index) => /* @__PURE__ */ jsxs("div", { children: [destination.group !== shown[index - 1]?.group && /* @__PURE__ */ jsx("div", {
|
|
416
511
|
className: `px-2.5 pb-1 pt-2 text-xs font-bold uppercase tracking-[0.08em] ${destination.group === "Waiting for you" ? "text-warning" : "text-muted-foreground"}`,
|
|
417
512
|
children: destination.group
|
|
@@ -634,9 +729,10 @@ function PlaceLink({ to, label, icon: Icon, roots }) {
|
|
|
634
729
|
})]
|
|
635
730
|
});
|
|
636
731
|
}
|
|
637
|
-
/** Theme and Log out: things about this browser
|
|
732
|
+
/** Theme, notifications and Log out: things about this browser rather than places to go. */
|
|
638
733
|
function SessionMenu() {
|
|
639
734
|
const mode = useThemeMode();
|
|
735
|
+
const notifications = useNotificationsState();
|
|
640
736
|
const [error, setError] = useState(null);
|
|
641
737
|
async function logout() {
|
|
642
738
|
setError(null);
|
|
@@ -651,8 +747,8 @@ function SessionMenu() {
|
|
|
651
747
|
asChild: true,
|
|
652
748
|
children: /* @__PURE__ */ jsx("button", {
|
|
653
749
|
type: "button",
|
|
654
|
-
"aria-label": "Theme and log out",
|
|
655
|
-
title: "Theme and log out",
|
|
750
|
+
"aria-label": "Theme, notifications and log out",
|
|
751
|
+
title: "Theme, notifications and log out",
|
|
656
752
|
className: "unstyled inline-flex h-9 w-9 items-center justify-center rounded-lg border border-transparent text-mocha transition-colors hover:border-frost hover:bg-ivory hover:text-sapphire data-[state=open]:border-sapphire-light data-[state=open]:bg-sapphire-glow data-[state=open]:text-sapphire",
|
|
657
753
|
children: /* @__PURE__ */ jsx(UserRound, {
|
|
658
754
|
className: "size-4",
|
|
@@ -695,6 +791,8 @@ function SessionMenu() {
|
|
|
695
791
|
})
|
|
696
792
|
}),
|
|
697
793
|
/* @__PURE__ */ jsx(DropdownMenu.Separator, { className: "my-1.5 h-px bg-border" }),
|
|
794
|
+
/* @__PURE__ */ jsx(NotificationsItem, { state: notifications }),
|
|
795
|
+
/* @__PURE__ */ jsx(DropdownMenu.Separator, { className: "my-1.5 h-px bg-border" }),
|
|
698
796
|
/* @__PURE__ */ jsxs(DropdownMenu.Item, {
|
|
699
797
|
onSelect: () => void logout(),
|
|
700
798
|
className: "flex cursor-pointer items-center gap-2.5 rounded-lg px-2.5 py-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground",
|
|
@@ -710,12 +808,43 @@ function SessionMenu() {
|
|
|
710
808
|
children: ["Could not log out: ", error]
|
|
711
809
|
})] });
|
|
712
810
|
}
|
|
811
|
+
/**
|
|
812
|
+
* Desktop notifications for this browser. Turning them on asks the browser's permission; a browser
|
|
813
|
+
* that blocks them, or an address where it offers none, is said so instead.
|
|
814
|
+
*/
|
|
815
|
+
function NotificationsItem({ state }) {
|
|
816
|
+
const itemClass = "flex cursor-pointer items-start gap-2.5 rounded-lg px-2.5 py-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:cursor-default data-[disabled]:opacity-70";
|
|
817
|
+
const Icon = state === "on" ? BellOff : Bell;
|
|
818
|
+
const label = state === "on" ? "Turn off desktop notifications" : state === "off" ? "Notify me on this computer" : "Desktop notifications unavailable";
|
|
819
|
+
const detail = state === "on" || state === "off" ? "When an Agent waits for you and Bazilion is in the background." : state === "blocked" ? "This browser blocks them for this site; allow them in its site settings." : "Browsers offer them on https:// addresses and on this computer only.";
|
|
820
|
+
return /* @__PURE__ */ jsxs(DropdownMenu.Item, {
|
|
821
|
+
disabled: state === "unsupported" || state === "blocked",
|
|
822
|
+
onSelect: (event) => {
|
|
823
|
+
if (state === "on") turnNotificationsOff();
|
|
824
|
+
else {
|
|
825
|
+
event.preventDefault();
|
|
826
|
+
turnNotificationsOn();
|
|
827
|
+
}
|
|
828
|
+
},
|
|
829
|
+
className: itemClass,
|
|
830
|
+
children: [/* @__PURE__ */ jsx(Icon, {
|
|
831
|
+
className: "mt-0.5 size-4 shrink-0 text-muted-foreground",
|
|
832
|
+
"aria-hidden": "true"
|
|
833
|
+
}), /* @__PURE__ */ jsxs("span", {
|
|
834
|
+
className: "flex min-w-0 flex-col gap-0.5",
|
|
835
|
+
children: [/* @__PURE__ */ jsx("span", { children: label }), /* @__PURE__ */ jsx("span", {
|
|
836
|
+
className: "text-xs text-muted-foreground",
|
|
837
|
+
children: detail
|
|
838
|
+
})]
|
|
839
|
+
})]
|
|
840
|
+
});
|
|
841
|
+
}
|
|
713
842
|
function navButtonClass(active) {
|
|
714
843
|
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"}`;
|
|
715
844
|
}
|
|
716
845
|
//#endregion
|
|
717
846
|
//#region src/styles.css?url
|
|
718
|
-
var styles_default = "/assets/styles-
|
|
847
|
+
var styles_default = "/assets/styles-DzcEC3Rd.css";
|
|
719
848
|
//#endregion
|
|
720
849
|
//#region src/routes/__root.tsx
|
|
721
850
|
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){}})();`;
|
|
@@ -789,38 +918,41 @@ function RootComponent() {
|
|
|
789
918
|
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",
|
|
790
919
|
children: "Skip to main content"
|
|
791
920
|
}),
|
|
792
|
-
/* @__PURE__ */ jsx(
|
|
921
|
+
/* @__PURE__ */ jsx(LiveProvider, {
|
|
793
922
|
enabled: !isLogin && pathname !== "/welcome",
|
|
794
|
-
children: /* @__PURE__ */
|
|
795
|
-
|
|
796
|
-
children: [/* @__PURE__ */ jsx("div", {
|
|
797
|
-
className: "
|
|
798
|
-
children: /* @__PURE__ */ jsx(
|
|
799
|
-
}), /* @__PURE__ */ jsx("main", {
|
|
800
|
-
id: "main-content",
|
|
801
|
-
tabIndex: -1,
|
|
802
|
-
className: "mx-auto min-h-0 w-full max-w-[1600px] flex-1 overflow-clip px-3 pb-3 sm:px-5 sm:pb-5",
|
|
803
|
-
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
804
|
-
})]
|
|
805
|
-
}) : /* @__PURE__ */ jsxs("div", {
|
|
806
|
-
className: "flex min-h-dvh flex-col",
|
|
807
|
-
children: [
|
|
808
|
-
/* @__PURE__ */ jsx("div", {
|
|
923
|
+
children: /* @__PURE__ */ jsxs(AttentionCountProvider, {
|
|
924
|
+
enabled: !isLogin && pathname !== "/welcome",
|
|
925
|
+
children: [/* @__PURE__ */ jsx(DesktopNotifier, {}), /* @__PURE__ */ jsx(PageTitleProvider, { children: isLogin ? /* @__PURE__ */ jsx(Outlet, {}) : isWorkspace ? /* @__PURE__ */ jsxs("div", {
|
|
926
|
+
className: "flex h-dvh flex-col",
|
|
927
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
809
928
|
className: "px-3 sm:px-5",
|
|
810
929
|
children: /* @__PURE__ */ jsx(TopBar, {})
|
|
811
|
-
}),
|
|
812
|
-
/* @__PURE__ */ jsx("main", {
|
|
930
|
+
}), /* @__PURE__ */ jsx("main", {
|
|
813
931
|
id: "main-content",
|
|
814
932
|
tabIndex: -1,
|
|
815
|
-
className: "mx-auto w-full max-w-[
|
|
933
|
+
className: "mx-auto min-h-0 w-full max-w-[1600px] flex-1 overflow-clip px-3 pb-3 sm:px-5 sm:pb-5",
|
|
816
934
|
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
817
|
-
})
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
935
|
+
})]
|
|
936
|
+
}) : /* @__PURE__ */ jsxs("div", {
|
|
937
|
+
className: "flex min-h-dvh flex-col",
|
|
938
|
+
children: [
|
|
939
|
+
/* @__PURE__ */ jsx("div", {
|
|
940
|
+
className: "px-3 sm:px-5",
|
|
941
|
+
children: /* @__PURE__ */ jsx(TopBar, {})
|
|
942
|
+
}),
|
|
943
|
+
/* @__PURE__ */ jsx("main", {
|
|
944
|
+
id: "main-content",
|
|
945
|
+
tabIndex: -1,
|
|
946
|
+
className: "mx-auto w-full max-w-[1500px] flex-1 px-4 py-9 sm:px-6 sm:py-12",
|
|
947
|
+
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
948
|
+
}),
|
|
949
|
+
/* @__PURE__ */ jsx("div", {
|
|
950
|
+
className: "px-4 sm:px-6",
|
|
951
|
+
children: /* @__PURE__ */ jsx(Footer, {})
|
|
952
|
+
})
|
|
953
|
+
]
|
|
954
|
+
}) })]
|
|
955
|
+
})
|
|
824
956
|
}),
|
|
825
957
|
/* @__PURE__ */ jsx(Scripts, {})
|
|
826
958
|
]
|