@tangle-network/agent-app 0.50.31 → 0.50.33
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/VaultPane-RHLY4DR5.js +7 -0
- package/dist/agent-enrollment/application.d.ts +25 -5
- package/dist/agent-enrollment/drizzle.d.ts +63 -0
- package/dist/agent-enrollment/drizzle.js +160 -0
- package/dist/agent-enrollment/drizzle.js.map +1 -0
- package/dist/agent-enrollment/index.d.ts +1 -1
- package/dist/agent-enrollment/index.js +5 -199
- package/dist/agent-enrollment/index.js.map +1 -1
- package/dist/app-oauth/index.d.ts +101 -0
- package/dist/app-oauth/index.js +231 -0
- package/dist/app-oauth/index.js.map +1 -0
- package/dist/assistant/index.js +1 -1
- package/dist/chat-routes/index.js +4 -4
- package/dist/{chunk-LDCR7MRU.js → chunk-2PDKWV2S.js} +2 -2
- package/dist/{chunk-2ZNU55YJ.js → chunk-3IATFW4U.js} +5 -5
- package/dist/chunk-3IATFW4U.js.map +1 -0
- package/dist/chunk-C3JSO2CB.js +232 -0
- package/dist/chunk-C3JSO2CB.js.map +1 -0
- package/dist/{chunk-CNI46COH.js → chunk-CBRYWGUO.js} +2 -2
- package/dist/{chunk-CNI46COH.js.map → chunk-CBRYWGUO.js.map} +1 -1
- package/dist/{chunk-BATKJP3P.js → chunk-E4AY62T2.js} +24 -7
- package/dist/chunk-E4AY62T2.js.map +1 -0
- package/dist/{chunk-5KFRCVAO.js → chunk-IYLPQKAH.js} +2 -2
- package/dist/{chunk-5TOV7EDF.js → chunk-PF3AZD5G.js} +4 -4
- package/dist/{chunk-ACFM2GFL.js → chunk-SYIV74NB.js} +1 -1
- package/dist/design-canvas-react/index.js +4 -4
- package/dist/design-canvas-react/lazy.js +1 -1
- package/dist/hosted-agent/react/SharedLineAppNotice.d.ts +16 -0
- package/dist/hosted-agent/react/index.d.ts +1 -0
- package/dist/hosted-agent/react/index.js +46 -1
- package/dist/hosted-agent/react/index.js.map +1 -1
- package/dist/hosted-agent/react/lines.css +92 -2
- package/dist/integrations-react/callback.d.ts +6 -0
- package/dist/integrations-react/client.d.ts +34 -0
- package/dist/integrations-react/index.d.ts +6 -0
- package/dist/integrations-react/index.js +830 -0
- package/dist/integrations-react/index.js.map +1 -0
- package/dist/integrations-react/panel.d.ts +22 -0
- package/dist/integrations-react/popup.d.ts +19 -0
- package/dist/integrations-react/projection.d.ts +25 -0
- package/dist/integrations-react/use-hub-integrations.d.ts +102 -0
- package/dist/preset-cloudflare/index.js +2 -2
- package/dist/sandbox/index.js +4 -4
- package/dist/studio-react/index.js +91 -56
- package/dist/studio-react/index.js.map +1 -1
- package/dist/teams-react/index.js +3 -3
- package/dist/theme/tokens.css +3 -1
- package/dist/tools/index.js +4 -4
- package/dist/vault/index.js +1 -1
- package/dist/vault/lazy.js +1 -1
- package/dist/web-react/index.js +4 -4
- package/dist/web-react/sandbox-terminal.d.ts +2 -0
- package/dist/web-react/terminal.js +1 -1
- package/dist/work-product/index.js +2 -2
- package/dist/workspace-react/companion.d.ts +31 -0
- package/dist/workspace-react/index.d.ts +1 -1
- package/dist/workspace-react/index.js +140 -2
- package/dist/workspace-react/index.js.map +1 -1
- package/package.json +35 -5
- package/dist/VaultPane-OTUP5AEX.js +0 -7
- package/dist/chunk-2ZNU55YJ.js.map +0 -1
- package/dist/chunk-BATKJP3P.js.map +0 -1
- /package/dist/{VaultPane-OTUP5AEX.js.map → VaultPane-RHLY4DR5.js.map} +0 -0
- /package/dist/{chunk-LDCR7MRU.js.map → chunk-2PDKWV2S.js.map} +0 -0
- /package/dist/{chunk-5KFRCVAO.js.map → chunk-IYLPQKAH.js.map} +0 -0
- /package/dist/{chunk-5TOV7EDF.js.map → chunk-PF3AZD5G.js.map} +0 -0
- /package/dist/{chunk-ACFM2GFL.js.map → chunk-SYIV74NB.js.map} +0 -0
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
InviteAcceptPage
|
|
3
|
-
} from "../chunk-W7P5KV6O.js";
|
|
4
1
|
import {
|
|
5
2
|
MembersPanel
|
|
6
3
|
} from "../chunk-GRDLGQ6A.js";
|
|
@@ -8,6 +5,9 @@ import {
|
|
|
8
5
|
InvitationsPanel
|
|
9
6
|
} from "../chunk-5MI2SKQH.js";
|
|
10
7
|
import "../chunk-AULM4X7U.js";
|
|
8
|
+
import {
|
|
9
|
+
InviteAcceptPage
|
|
10
|
+
} from "../chunk-W7P5KV6O.js";
|
|
11
11
|
import "../chunk-6XIAPIW6.js";
|
|
12
12
|
export {
|
|
13
13
|
InvitationsPanel,
|
package/dist/theme/tokens.css
CHANGED
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
24
|
:root {
|
|
25
|
+
color-scheme: light;
|
|
25
26
|
/* ── The neutral ramp ────────────────────────────────────────────────────
|
|
26
27
|
ONE ladder, both themes: light reads it from the top down, dark from the
|
|
27
28
|
bottom up. A stop's name is its oklch lightness × 100, rounded to the
|
|
@@ -349,7 +350,7 @@
|
|
|
349
350
|
* Every interactive element is keyboard-visible by DEFAULT, so a component has
|
|
350
351
|
* to opt out on purpose rather than by omission. Before this rule an element
|
|
351
352
|
* that declared no focus style fell back to the browser's own ring — measured
|
|
352
|
-
* `rgb(16, 16, 16)` in BOTH themes,
|
|
353
|
+
* `rgb(16, 16, 16)` in BOTH themes, before these theme scopes set native `color-scheme`,
|
|
353
354
|
* which is 1.03:1 against the dark canvas backdrop `rgb(19, 19, 21)`. Visible in
|
|
354
355
|
* light, effectively absent in dark, on 30 of the 176 focusable elements the
|
|
355
356
|
* playground audit reaches.
|
|
@@ -396,6 +397,7 @@
|
|
|
396
397
|
|
|
397
398
|
[data-theme='dark'],
|
|
398
399
|
.dark {
|
|
400
|
+
color-scheme: dark;
|
|
399
401
|
/* The ramp is NOT redefined here — both themes read the same `--neutral-*`
|
|
400
402
|
ladder and only differ in which stop each role picks.
|
|
401
403
|
`--warning-foreground` (dark text on a solid gold chip) is theme-invariant
|
package/dist/tools/index.js
CHANGED
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
restrictTaxonomy,
|
|
10
10
|
verifyCapabilityToken,
|
|
11
11
|
verifyExpiringCapabilityToken
|
|
12
|
-
} from "../chunk-
|
|
12
|
+
} from "../chunk-PF3AZD5G.js";
|
|
13
13
|
import {
|
|
14
14
|
DEFAULT_APP_TOOL_PATHS,
|
|
15
15
|
DEFAULT_HEADER_NAMES,
|
|
@@ -29,13 +29,13 @@ import {
|
|
|
29
29
|
defineAppTool,
|
|
30
30
|
findCustomTool,
|
|
31
31
|
isAppToolName
|
|
32
|
-
} from "../chunk-
|
|
32
|
+
} from "../chunk-2PDKWV2S.js";
|
|
33
33
|
import "../chunk-UGWQLQDS.js";
|
|
34
34
|
import "../chunk-S5SRJJQG.js";
|
|
35
|
-
import "../chunk-
|
|
35
|
+
import "../chunk-IYLPQKAH.js";
|
|
36
36
|
import {
|
|
37
37
|
ToolInputError
|
|
38
|
-
} from "../chunk-
|
|
38
|
+
} from "../chunk-CBRYWGUO.js";
|
|
39
39
|
export {
|
|
40
40
|
APP_TOOL_NAMES,
|
|
41
41
|
DEFAULT_APP_TOOL_PATHS,
|
package/dist/vault/index.js
CHANGED
package/dist/vault/lazy.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/vault/lazy.tsx
|
|
2
2
|
import { lazy } from "react";
|
|
3
3
|
var VaultPaneLazy = lazy(
|
|
4
|
-
() => import("../VaultPane-
|
|
4
|
+
() => import("../VaultPane-RHLY4DR5.js").then((m) => ({ default: m.VaultPane }))
|
|
5
5
|
);
|
|
6
6
|
export {
|
|
7
7
|
VaultPaneLazy
|
package/dist/web-react/index.js
CHANGED
|
@@ -141,6 +141,10 @@ import {
|
|
|
141
141
|
import {
|
|
142
142
|
MENTION_PILL_CLASS
|
|
143
143
|
} from "../chunk-3HUFJ5LO.js";
|
|
144
|
+
import {
|
|
145
|
+
tabTerminalConnectionId,
|
|
146
|
+
useSandboxTerminalConnection
|
|
147
|
+
} from "../chunk-E4AY62T2.js";
|
|
144
148
|
import "../chunk-FBVLEGEG.js";
|
|
145
149
|
import {
|
|
146
150
|
EvidenceLineageTable,
|
|
@@ -192,10 +196,6 @@ import {
|
|
|
192
196
|
usePending,
|
|
193
197
|
usePopover
|
|
194
198
|
} from "../chunk-XF6ZRY56.js";
|
|
195
|
-
import {
|
|
196
|
-
tabTerminalConnectionId,
|
|
197
|
-
useSandboxTerminalConnection
|
|
198
|
-
} from "../chunk-BATKJP3P.js";
|
|
199
199
|
import "../chunk-SJWIZT7B.js";
|
|
200
200
|
import "../chunk-Q3ZHNN5X.js";
|
|
201
201
|
import "../chunk-FQYAJYPW.js";
|
|
@@ -46,6 +46,8 @@ export interface SandboxTerminalConnectionResponse {
|
|
|
46
46
|
*/
|
|
47
47
|
export interface UseSandboxTerminalConnectionOptions {
|
|
48
48
|
workspaceId: string;
|
|
49
|
+
/** Connect each scope by default; false requires an explicit connect after mount or scope changes. */
|
|
50
|
+
autoConnect?: boolean;
|
|
49
51
|
connectionUrl?: string | ((workspaceId: string) => string);
|
|
50
52
|
connectionId?: string;
|
|
51
53
|
fetcher?: typeof fetch;
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
} from "../chunk-GEYACSFW.js";
|
|
5
5
|
import {
|
|
6
6
|
defineAppTool
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-2PDKWV2S.js";
|
|
8
8
|
import "../chunk-UGWQLQDS.js";
|
|
9
9
|
import {
|
|
10
10
|
ToolInputError
|
|
11
|
-
} from "../chunk-
|
|
11
|
+
} from "../chunk-CBRYWGUO.js";
|
|
12
12
|
import {
|
|
13
13
|
isWorkProductStatus,
|
|
14
14
|
parseAgentCheckInput,
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
export interface AgentWorkspaceCompanionTab {
|
|
3
|
+
id: string;
|
|
4
|
+
label: string;
|
|
5
|
+
icon?: ReactNode;
|
|
6
|
+
/** Retain a visited tab through tab switches, pane closure, and viewport changes. */
|
|
7
|
+
keepMounted?: boolean;
|
|
8
|
+
renderContent: (state: {
|
|
9
|
+
active: boolean;
|
|
10
|
+
}) => ReactNode;
|
|
11
|
+
}
|
|
12
|
+
export interface AgentWorkspaceCompanionHandle {
|
|
13
|
+
openTab: (tabId: string) => boolean;
|
|
14
|
+
}
|
|
15
|
+
export interface AgentWorkspaceCompanionProps {
|
|
16
|
+
children: ReactNode;
|
|
17
|
+
tabs: readonly AgentWorkspaceCompanionTab[];
|
|
18
|
+
open?: boolean;
|
|
19
|
+
onOpenChange?: (open: boolean) => void;
|
|
20
|
+
defaultOpen?: boolean;
|
|
21
|
+
activeTabId?: string;
|
|
22
|
+
onActiveTabChange?: (tabId: string) => void;
|
|
23
|
+
defaultActiveTabId?: string;
|
|
24
|
+
/** Namespace for remembered tab selection and underlying pane dimensions. */
|
|
25
|
+
persistenceKey?: string;
|
|
26
|
+
label?: string;
|
|
27
|
+
defaultWidth?: number;
|
|
28
|
+
className?: string;
|
|
29
|
+
}
|
|
30
|
+
/** Product-owned tools beside a conversation; omitted tools have no tabs or effects. */
|
|
31
|
+
export declare const AgentWorkspaceCompanion: import("react").ForwardRefExoticComponent<AgentWorkspaceCompanionProps & import("react").RefAttributes<AgentWorkspaceCompanionHandle>>;
|
|
@@ -97,4 +97,4 @@ export interface AgentWorkspaceLayoutProps extends Omit<SidebarLayoutProps, 'act
|
|
|
97
97
|
* structure.
|
|
98
98
|
*/
|
|
99
99
|
export declare function AgentWorkspaceLayout({ children, navItems, sessions, apps, activeRoute, activeId, ...sidebarProps }: AgentWorkspaceLayoutProps): import("react").JSX.Element;
|
|
100
|
-
export {};
|
|
100
|
+
export { AgentWorkspaceCompanion, type AgentWorkspaceCompanionHandle, type AgentWorkspaceCompanionProps, type AgentWorkspaceCompanionTab } from './companion';
|
|
@@ -6,7 +6,144 @@ import {
|
|
|
6
6
|
|
|
7
7
|
// src/workspace-react/index.tsx
|
|
8
8
|
import { SidebarLayout } from "@tangle-network/sandbox-ui/dashboard";
|
|
9
|
-
|
|
9
|
+
|
|
10
|
+
// src/workspace-react/companion.tsx
|
|
11
|
+
import { forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState } from "react";
|
|
12
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger } from "@tangle-network/sandbox-ui/primitives";
|
|
13
|
+
import { WorkspaceLayout } from "@tangle-network/sandbox-ui/workspace";
|
|
14
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
15
|
+
var AgentWorkspaceCompanion = forwardRef(function AgentWorkspaceCompanion2({
|
|
16
|
+
children,
|
|
17
|
+
tabs,
|
|
18
|
+
open: controlledOpen,
|
|
19
|
+
onOpenChange,
|
|
20
|
+
defaultOpen = false,
|
|
21
|
+
activeTabId,
|
|
22
|
+
onActiveTabChange,
|
|
23
|
+
defaultActiveTabId,
|
|
24
|
+
persistenceKey,
|
|
25
|
+
label = "Workspace tools",
|
|
26
|
+
defaultWidth = 420,
|
|
27
|
+
className
|
|
28
|
+
}, ref) {
|
|
29
|
+
const [uncontrolledOpen, setOpen] = useState(defaultOpen);
|
|
30
|
+
const open = controlledOpen ?? uncontrolledOpen;
|
|
31
|
+
const [selection, setSelection] = useState({ key: persistenceKey, id: defaultActiveTabId });
|
|
32
|
+
const [visits, setVisits] = useState(() => ({ key: persistenceKey, ids: /* @__PURE__ */ new Set() }));
|
|
33
|
+
const requested = activeTabId ?? (selection.key === persistenceKey ? selection.id : defaultActiveTabId);
|
|
34
|
+
const active = tabs.find((tab) => tab.id === requested)?.id ?? tabs[0]?.id;
|
|
35
|
+
const visited = visits.key === persistenceKey ? visits.ids : /* @__PURE__ */ new Set();
|
|
36
|
+
const storageKey = persistenceKey ? `${persistenceKey}:companion-tab` : void 0;
|
|
37
|
+
const pendingRestoration = useRef(void 0);
|
|
38
|
+
const reconciledSelection = useRef(void 0);
|
|
39
|
+
const restoredKey = useRef(void 0);
|
|
40
|
+
useEffect(() => {
|
|
41
|
+
const key = JSON.stringify([persistenceKey, defaultActiveTabId]);
|
|
42
|
+
if (restoredKey.current === key || tabs.length === 0) return;
|
|
43
|
+
let id = activeTabId ?? defaultActiveTabId;
|
|
44
|
+
if (storageKey) {
|
|
45
|
+
try {
|
|
46
|
+
id = window.localStorage.getItem(storageKey) ?? id;
|
|
47
|
+
} catch {
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
const resolved = tabs.find((tab) => tab.id === id)?.id ?? tabs[0]?.id;
|
|
51
|
+
restoredKey.current = key;
|
|
52
|
+
pendingRestoration.current = { key: persistenceKey, id: resolved };
|
|
53
|
+
setSelection({ key: persistenceKey, id: resolved });
|
|
54
|
+
if (resolved && resolved !== activeTabId) {
|
|
55
|
+
reconciledSelection.current = JSON.stringify([persistenceKey, requested, resolved]);
|
|
56
|
+
onActiveTabChange?.(resolved);
|
|
57
|
+
}
|
|
58
|
+
}, [storageKey, persistenceKey, defaultActiveTabId, activeTabId, requested, tabs, onActiveTabChange]);
|
|
59
|
+
useEffect(() => {
|
|
60
|
+
const pending = pendingRestoration.current;
|
|
61
|
+
if (pending) {
|
|
62
|
+
const acknowledged = activeTabId === void 0 ? selection.key === pending.key && selection.id === pending.id : activeTabId === pending.id;
|
|
63
|
+
if (!acknowledged) return;
|
|
64
|
+
pendingRestoration.current = void 0;
|
|
65
|
+
}
|
|
66
|
+
if (!active || tabs.some((tab) => tab.id === requested)) {
|
|
67
|
+
reconciledSelection.current = void 0;
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
const key = JSON.stringify([persistenceKey, requested, active]);
|
|
71
|
+
if (reconciledSelection.current === key) return;
|
|
72
|
+
reconciledSelection.current = key;
|
|
73
|
+
setSelection({ key: persistenceKey, id: active });
|
|
74
|
+
onActiveTabChange?.(active);
|
|
75
|
+
}, [active, activeTabId, requested, selection, persistenceKey, tabs, onActiveTabChange]);
|
|
76
|
+
useEffect(() => {
|
|
77
|
+
if (!open || !active) return;
|
|
78
|
+
setVisits((previous) => {
|
|
79
|
+
const ids = previous.key === persistenceKey ? previous.ids : /* @__PURE__ */ new Set();
|
|
80
|
+
return ids.has(active) ? previous : { key: persistenceKey, ids: /* @__PURE__ */ new Set([...ids, active]) };
|
|
81
|
+
});
|
|
82
|
+
}, [open, active, persistenceKey]);
|
|
83
|
+
const selectTab = useCallback((id) => {
|
|
84
|
+
if (!tabs.some((tab) => tab.id === id)) return false;
|
|
85
|
+
setSelection({ key: persistenceKey, id });
|
|
86
|
+
onActiveTabChange?.(id);
|
|
87
|
+
if (storageKey) {
|
|
88
|
+
try {
|
|
89
|
+
window.localStorage.setItem(storageKey, id);
|
|
90
|
+
} catch {
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
return true;
|
|
94
|
+
}, [tabs, persistenceKey, storageKey, onActiveTabChange]);
|
|
95
|
+
const changeOpen = useCallback((next) => {
|
|
96
|
+
setOpen(next);
|
|
97
|
+
onOpenChange?.(next);
|
|
98
|
+
}, [onOpenChange]);
|
|
99
|
+
useImperativeHandle(ref, () => ({
|
|
100
|
+
openTab(id) {
|
|
101
|
+
if (!selectTab(id)) return false;
|
|
102
|
+
changeOpen(true);
|
|
103
|
+
return true;
|
|
104
|
+
}
|
|
105
|
+
}), [selectTab, changeOpen]);
|
|
106
|
+
if (tabs.length === 0) return /* @__PURE__ */ jsx(Fragment, { children });
|
|
107
|
+
return /* @__PURE__ */ jsx(Tabs, { value: active, onValueChange: selectTab, className: `flex h-full min-h-0 min-w-0 flex-1 flex-col ${className ?? ""}`, children: /* @__PURE__ */ jsx(
|
|
108
|
+
WorkspaceLayout,
|
|
109
|
+
{
|
|
110
|
+
className: "h-full min-h-0 min-w-0 flex-1",
|
|
111
|
+
collapsedControlsPlacement: "overlay",
|
|
112
|
+
keepRightMounted: true,
|
|
113
|
+
center: children,
|
|
114
|
+
rightOpen: open,
|
|
115
|
+
onRightOpenChange: changeOpen,
|
|
116
|
+
rightLabel: label,
|
|
117
|
+
defaultRightWidth: defaultWidth,
|
|
118
|
+
persistenceKey,
|
|
119
|
+
minRightWidth: 280,
|
|
120
|
+
rightContentClassName: "flex flex-col overflow-hidden",
|
|
121
|
+
rightHeader: /* @__PURE__ */ jsx(TabsList, { "aria-label": label, className: "h-9 max-w-full justify-start overflow-x-auto bg-transparent p-0", children: tabs.map((tab) => /* @__PURE__ */ jsxs(TabsTrigger, { value: tab.id, className: "gap-1.5 px-2.5 text-sm", children: [
|
|
122
|
+
tab.icon,
|
|
123
|
+
/* @__PURE__ */ jsx("span", { children: tab.label })
|
|
124
|
+
] }, tab.id)) }),
|
|
125
|
+
right: tabs.map((tab) => {
|
|
126
|
+
const isActive = tab.id === active;
|
|
127
|
+
const retained = tab.keepMounted && visited.has(tab.id);
|
|
128
|
+
if (!(open && isActive) && !retained) return null;
|
|
129
|
+
return /* @__PURE__ */ jsx(
|
|
130
|
+
TabsContent,
|
|
131
|
+
{
|
|
132
|
+
value: tab.id,
|
|
133
|
+
forceMount: retained ? true : void 0,
|
|
134
|
+
hidden: !open || !isActive,
|
|
135
|
+
className: "m-0 h-full min-h-0 min-w-0 flex-1 data-[state=inactive]:hidden",
|
|
136
|
+
children: tab.renderContent({ active: open && isActive })
|
|
137
|
+
},
|
|
138
|
+
tab.id
|
|
139
|
+
);
|
|
140
|
+
})
|
|
141
|
+
}
|
|
142
|
+
) }, persistenceKey);
|
|
143
|
+
});
|
|
144
|
+
|
|
145
|
+
// src/workspace-react/index.tsx
|
|
146
|
+
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
10
147
|
function routePathFromHref(href, base) {
|
|
11
148
|
const path = href.split(/[?#]/, 1)[0] ?? "";
|
|
12
149
|
const root = base.replace(/\/+$/, "");
|
|
@@ -103,7 +240,7 @@ function AgentWorkspaceLayout({
|
|
|
103
240
|
railLabels: true,
|
|
104
241
|
...sidebarProps
|
|
105
242
|
};
|
|
106
|
-
return /* @__PURE__ */
|
|
243
|
+
return /* @__PURE__ */ jsx2(
|
|
107
244
|
SidebarLayout,
|
|
108
245
|
{
|
|
109
246
|
...layoutProps,
|
|
@@ -114,6 +251,7 @@ function AgentWorkspaceLayout({
|
|
|
114
251
|
);
|
|
115
252
|
}
|
|
116
253
|
export {
|
|
254
|
+
AgentWorkspaceCompanion,
|
|
117
255
|
AgentWorkspaceLayout
|
|
118
256
|
};
|
|
119
257
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/workspace-react/index.tsx"],"sourcesContent":["import { SidebarLayout, type SidebarLayoutNavItem, type SidebarLayoutProps } from '@tangle-network/sandbox-ui/dashboard'\nimport type { ReactNode } from 'react'\n\nimport type { WorkspaceAppRecord } from '../workspace-apps'\n\nimport {\n buildSessionNavItem,\n composeSidebarSessions,\n resolveActiveNavId,\n type NavRouteDef,\n type RailPrefetch,\n type SessionRowActions,\n type SessionSummary,\n} from '../session-shell'\n\ntype WorkspaceIcon = SidebarLayoutNavItem['icon']\n\nfunction routePathFromHref(href: string, base: string): string | null {\n const path = href.split(/[?#]/, 1)[0] ?? ''\n const root = base.replace(/\\/+$/, '')\n if (path === root) return '/'\n if (!path.startsWith(`${root}/`)) return null\n return path.slice(root.length)\n}\n\n/** The session data and product-owned URLs needed by the default workspace. */\nexport interface AgentWorkspaceSessionConfig {\n /** Icon shown beside the expandable History row. */\n icon: WorkspaceIcon\n /** Id for the session row; defaults to `history`. */\n id?: string\n /** Product copy for the session row; defaults to `History`. */\n label?: string\n /** Full-history route used by the row and overflow item. */\n href: string\n /** Product-owned URL for an individual session. */\n hrefForSession: (sessionId: string) => string\n /** Server-loaded rows, ordered by the product's query. */\n sessions: SessionSummary[]\n /** Sessions created by another tab before the loader revalidates. */\n optimisticSessions?: SessionSummary[]\n /** Number of rows shown in the rail before the full-history link. */\n limit?: number\n /** Total persisted session count, used to decide whether overflow exists. */\n totalCount?: number\n /** Session currently open in the route. */\n activeSessionId?: string | null\n /** Sessions with a live turn. */\n respondingSessionIds?: ReadonlySet<string>\n /** Live unread ids from the product's event channel. */\n liveUnreadIds?: ReadonlySet<string>\n /** Ids this tab has opened since the loader ran. */\n locallyReadIds?: ReadonlySet<string>\n /** Optional product-owned rename/delete/pin actions. */\n actions?: SessionRowActions<WorkspaceIcon>\n /** Label for the overflow row. Defaults to `View all chats`. */\n overflowLabel?: string\n /** Empty state for the expanded rail row. Defaults to `No chats yet`. */\n emptyLabel?: string\n /** Fallback title for untitled sessions. */\n untitledLabel?: string\n /** Router prefetch behavior for session links. */\n prefetch?: RailPrefetch\n /** Whether History starts expanded. Defaults to `true`. */\n defaultOpen?: boolean\n}\n\n/**\n * Registered apps shown under one expandable workspace destination.\n * Products supply authorized rows and their real route; preview URLs never\n * become navigation hrefs.\n */\nexport interface AgentWorkspaceAppsConfig {\n icon: WorkspaceIcon\n items: readonly Pick<WorkspaceAppRecord, 'id' | 'name'>[]\n hrefForApp: (appId: string) => string\n prefetch?: RailPrefetch\n}\n\n/** Route data for the shared active-nav resolver. */\nexport interface AgentWorkspaceActiveRoute {\n /** Current browser pathname, including the product's workspace base. */\n pathname: string\n /** Product route root, for example `/app/ws_123`. */\n base: string\n /** Product-owned rail routes, relative to `base`. */\n routes: NavRouteDef[]\n /** Extra route prefixes that should highlight an existing row. */\n aliases?: Record<string, string>\n /** Route prefixes that intentionally highlight no row. */\n claimsNothing?: string[]\n}\n\nexport interface AgentWorkspaceLayoutProps\n extends Omit<SidebarLayoutProps, 'activeId' | 'children' | 'navItems' | 'hideBelow' | 'railLabels'> {\n children: ReactNode\n /** Product-owned destinations. Shared Apps and History rows follow them. */\n navItems: SidebarLayoutNavItem[]\n /** Omit for a workflow-only shell with no conversational session rail. */\n sessions?: AgentWorkspaceSessionConfig\n /** Authorized app destinations, in the product's persisted order. */\n apps?: AgentWorkspaceAppsConfig\n /** When supplied, active navigation is resolved by the shared route rules. */\n activeRoute?: AgentWorkspaceActiveRoute\n /** Escape hatch for routers that already resolved the active item. */\n activeId?: string\n /** Hide the fixed desktop rail below this breakpoint. Defaults to `lg`. */\n hideBelow?: SidebarLayoutProps['hideBelow']\n /** Show labels beside rail icons. Defaults to `true`. */\n railLabels?: SidebarLayoutProps['railLabels']\n}\n\n/**\n * The default agent workspace composition.\n *\n * Products own their navigation taxonomy, routes, and session storage. This\n * component owns the repeated assembly: the standard visual layout, the\n * expandable Apps and History rows, capped session composition, unread state,\n * and active route resolution. The full History route and the empty-state composer stay\n * separate because their data and domain copy belong to the product; pair this\n * with `SessionHistoryPanel` and `EntryComposer` for the complete chat-first\n * structure.\n */\nexport function AgentWorkspaceLayout({\n children,\n navItems,\n sessions,\n apps,\n activeRoute,\n activeId,\n ...sidebarProps\n}: AgentWorkspaceLayoutProps) {\n const sessionNav = sessions\n ? (() => {\n const composed = composeSidebarSessions({\n loaderSessions: sessions.sessions,\n optimisticSessions: sessions.optimisticSessions,\n limit: sessions.limit ?? 20,\n totalCount: sessions.totalCount,\n liveUnreadIds: sessions.liveUnreadIds,\n locallyReadIds: sessions.locallyReadIds,\n currentSessionId: sessions.activeSessionId,\n })\n\n return buildSessionNavItem<WorkspaceIcon>({\n id: sessions.id,\n label: sessions.label,\n icon: sessions.icon,\n href: sessions.href,\n sessions: composed.sessions,\n hrefForSession: sessions.hrefForSession,\n activeSessionId: sessions.activeSessionId,\n respondingSessionIds: sessions.respondingSessionIds,\n actions: sessions.actions,\n overflow: composed.hasMore\n ? { href: sessions.href, label: sessions.overflowLabel }\n : undefined,\n emptyLabel: sessions.emptyLabel,\n untitledLabel: sessions.untitledLabel,\n prefetch: sessions.prefetch,\n defaultOpen: sessions.defaultOpen,\n })\n })()\n : undefined\n\n const appNavItems: SidebarLayoutNavItem[] = (apps?.items ?? []).map((app) => {\n const href = apps!.hrefForApp(app.id)\n if (!href.startsWith('/') || href.startsWith('//') || /[?#\\\\]/.test(href)) {\n throw new Error('Workspace app href must be a local route path')\n }\n return {\n id: 'workspace-app:' + app.id,\n label: app.name,\n icon: apps!.icon,\n href,\n prefetch: apps!.prefetch,\n }\n })\n const appRoutes: NavRouteDef[] = activeRoute\n ? appNavItems.map((item) => {\n const path = routePathFromHref(item.href!, activeRoute.base)\n if (!path) throw new Error('Workspace app href must be under the active workspace')\n return { id: item.id, path }\n })\n : []\n\n const historyRoutePath = sessions && activeRoute\n ? routePathFromHref(sessions.href, activeRoute.base)\n : null\n\n const resolvedActiveId = activeRoute\n ? resolveActiveNavId({\n ...activeRoute,\n routes: [\n ...activeRoute.routes,\n ...appRoutes,\n ...(sessionNav && historyRoutePath\n ? [{ id: sessions?.id ?? 'history', path: historyRoutePath }]\n : []),\n ],\n })\n : activeId\n\n const activeAppId = appNavItems.some((item) => item.id === resolvedActiveId)\n ? resolvedActiveId\n : undefined\n const appGroup: SidebarLayoutNavItem | undefined = apps && appNavItems.length > 0\n ? {\n id: 'workspace-apps',\n label: 'Apps',\n icon: apps.icon,\n expandable: true,\n defaultOpen: activeAppId !== undefined,\n subItems: appNavItems.map(({ id, label, icon, href, prefetch }) => ({\n id,\n label,\n icon,\n href: href!,\n prefetch,\n })),\n subActiveIds: activeAppId ? [activeAppId] : undefined,\n }\n : undefined\n const workspaceNavItems: SidebarLayoutNavItem[] = [\n ...navItems,\n ...(appGroup ? [appGroup] : []),\n ...(sessionNav ? [sessionNav] : []),\n ]\n\n const layoutProps = {\n hideBelow: 'lg' as const,\n railLabels: true,\n ...sidebarProps,\n }\n\n return (\n <SidebarLayout\n {...layoutProps}\n navItems={workspaceNavItems}\n activeId={activeAppId ? appGroup?.id : resolvedActiveId}\n >\n {children}\n </SidebarLayout>\n )\n}\n"],"mappings":";;;;;;;AAAA,SAAS,qBAAyE;AA4O9E;AA3NJ,SAAS,kBAAkB,MAAc,MAA6B;AACpE,QAAM,OAAO,KAAK,MAAM,QAAQ,CAAC,EAAE,CAAC,KAAK;AACzC,QAAM,OAAO,KAAK,QAAQ,QAAQ,EAAE;AACpC,MAAI,SAAS,KAAM,QAAO;AAC1B,MAAI,CAAC,KAAK,WAAW,GAAG,IAAI,G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,IACZ,GAAG;AAAA,EACL;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACJ,UAAU;AAAA,MACV,UAAU,cAAc,UAAU,KAAK;AAAA,MAEtC;AAAA;AAAA,EACH;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/workspace-react/index.tsx","../../src/workspace-react/companion.tsx"],"sourcesContent":["import { SidebarLayout, type SidebarLayoutNavItem, type SidebarLayoutProps } from '@tangle-network/sandbox-ui/dashboard'\nimport type { ReactNode } from 'react'\n\nimport type { WorkspaceAppRecord } from '../workspace-apps'\n\nimport {\n buildSessionNavItem,\n composeSidebarSessions,\n resolveActiveNavId,\n type NavRouteDef,\n type RailPrefetch,\n type SessionRowActions,\n type SessionSummary,\n} from '../session-shell'\n\ntype WorkspaceIcon = SidebarLayoutNavItem['icon']\n\nfunction routePathFromHref(href: string, base: string): string | null {\n const path = href.split(/[?#]/, 1)[0] ?? ''\n const root = base.replace(/\\/+$/, '')\n if (path === root) return '/'\n if (!path.startsWith(`${root}/`)) return null\n return path.slice(root.length)\n}\n\n/** The session data and product-owned URLs needed by the default workspace. */\nexport interface AgentWorkspaceSessionConfig {\n /** Icon shown beside the expandable History row. */\n icon: WorkspaceIcon\n /** Id for the session row; defaults to `history`. */\n id?: string\n /** Product copy for the session row; defaults to `History`. */\n label?: string\n /** Full-history route used by the row and overflow item. */\n href: string\n /** Product-owned URL for an individual session. */\n hrefForSession: (sessionId: string) => string\n /** Server-loaded rows, ordered by the product's query. */\n sessions: SessionSummary[]\n /** Sessions created by another tab before the loader revalidates. */\n optimisticSessions?: SessionSummary[]\n /** Number of rows shown in the rail before the full-history link. */\n limit?: number\n /** Total persisted session count, used to decide whether overflow exists. */\n totalCount?: number\n /** Session currently open in the route. */\n activeSessionId?: string | null\n /** Sessions with a live turn. */\n respondingSessionIds?: ReadonlySet<string>\n /** Live unread ids from the product's event channel. */\n liveUnreadIds?: ReadonlySet<string>\n /** Ids this tab has opened since the loader ran. */\n locallyReadIds?: ReadonlySet<string>\n /** Optional product-owned rename/delete/pin actions. */\n actions?: SessionRowActions<WorkspaceIcon>\n /** Label for the overflow row. Defaults to `View all chats`. */\n overflowLabel?: string\n /** Empty state for the expanded rail row. Defaults to `No chats yet`. */\n emptyLabel?: string\n /** Fallback title for untitled sessions. */\n untitledLabel?: string\n /** Router prefetch behavior for session links. */\n prefetch?: RailPrefetch\n /** Whether History starts expanded. Defaults to `true`. */\n defaultOpen?: boolean\n}\n\n/**\n * Registered apps shown under one expandable workspace destination.\n * Products supply authorized rows and their real route; preview URLs never\n * become navigation hrefs.\n */\nexport interface AgentWorkspaceAppsConfig {\n icon: WorkspaceIcon\n items: readonly Pick<WorkspaceAppRecord, 'id' | 'name'>[]\n hrefForApp: (appId: string) => string\n prefetch?: RailPrefetch\n}\n\n/** Route data for the shared active-nav resolver. */\nexport interface AgentWorkspaceActiveRoute {\n /** Current browser pathname, including the product's workspace base. */\n pathname: string\n /** Product route root, for example `/app/ws_123`. */\n base: string\n /** Product-owned rail routes, relative to `base`. */\n routes: NavRouteDef[]\n /** Extra route prefixes that should highlight an existing row. */\n aliases?: Record<string, string>\n /** Route prefixes that intentionally highlight no row. */\n claimsNothing?: string[]\n}\n\nexport interface AgentWorkspaceLayoutProps\n extends Omit<SidebarLayoutProps, 'activeId' | 'children' | 'navItems' | 'hideBelow' | 'railLabels'> {\n children: ReactNode\n /** Product-owned destinations. Shared Apps and History rows follow them. */\n navItems: SidebarLayoutNavItem[]\n /** Omit for a workflow-only shell with no conversational session rail. */\n sessions?: AgentWorkspaceSessionConfig\n /** Authorized app destinations, in the product's persisted order. */\n apps?: AgentWorkspaceAppsConfig\n /** When supplied, active navigation is resolved by the shared route rules. */\n activeRoute?: AgentWorkspaceActiveRoute\n /** Escape hatch for routers that already resolved the active item. */\n activeId?: string\n /** Hide the fixed desktop rail below this breakpoint. Defaults to `lg`. */\n hideBelow?: SidebarLayoutProps['hideBelow']\n /** Show labels beside rail icons. Defaults to `true`. */\n railLabels?: SidebarLayoutProps['railLabels']\n}\n\n/**\n * The default agent workspace composition.\n *\n * Products own their navigation taxonomy, routes, and session storage. This\n * component owns the repeated assembly: the standard visual layout, the\n * expandable Apps and History rows, capped session composition, unread state,\n * and active route resolution. The full History route and the empty-state composer stay\n * separate because their data and domain copy belong to the product; pair this\n * with `SessionHistoryPanel` and `EntryComposer` for the complete chat-first\n * structure.\n */\nexport function AgentWorkspaceLayout({\n children,\n navItems,\n sessions,\n apps,\n activeRoute,\n activeId,\n ...sidebarProps\n}: AgentWorkspaceLayoutProps) {\n const sessionNav = sessions\n ? (() => {\n const composed = composeSidebarSessions({\n loaderSessions: sessions.sessions,\n optimisticSessions: sessions.optimisticSessions,\n limit: sessions.limit ?? 20,\n totalCount: sessions.totalCount,\n liveUnreadIds: sessions.liveUnreadIds,\n locallyReadIds: sessions.locallyReadIds,\n currentSessionId: sessions.activeSessionId,\n })\n\n return buildSessionNavItem<WorkspaceIcon>({\n id: sessions.id,\n label: sessions.label,\n icon: sessions.icon,\n href: sessions.href,\n sessions: composed.sessions,\n hrefForSession: sessions.hrefForSession,\n activeSessionId: sessions.activeSessionId,\n respondingSessionIds: sessions.respondingSessionIds,\n actions: sessions.actions,\n overflow: composed.hasMore\n ? { href: sessions.href, label: sessions.overflowLabel }\n : undefined,\n emptyLabel: sessions.emptyLabel,\n untitledLabel: sessions.untitledLabel,\n prefetch: sessions.prefetch,\n defaultOpen: sessions.defaultOpen,\n })\n })()\n : undefined\n\n const appNavItems: SidebarLayoutNavItem[] = (apps?.items ?? []).map((app) => {\n const href = apps!.hrefForApp(app.id)\n if (!href.startsWith('/') || href.startsWith('//') || /[?#\\\\]/.test(href)) {\n throw new Error('Workspace app href must be a local route path')\n }\n return {\n id: 'workspace-app:' + app.id,\n label: app.name,\n icon: apps!.icon,\n href,\n prefetch: apps!.prefetch,\n }\n })\n const appRoutes: NavRouteDef[] = activeRoute\n ? appNavItems.map((item) => {\n const path = routePathFromHref(item.href!, activeRoute.base)\n if (!path) throw new Error('Workspace app href must be under the active workspace')\n return { id: item.id, path }\n })\n : []\n\n const historyRoutePath = sessions && activeRoute\n ? routePathFromHref(sessions.href, activeRoute.base)\n : null\n\n const resolvedActiveId = activeRoute\n ? resolveActiveNavId({\n ...activeRoute,\n routes: [\n ...activeRoute.routes,\n ...appRoutes,\n ...(sessionNav && historyRoutePath\n ? [{ id: sessions?.id ?? 'history', path: historyRoutePath }]\n : []),\n ],\n })\n : activeId\n\n const activeAppId = appNavItems.some((item) => item.id === resolvedActiveId)\n ? resolvedActiveId\n : undefined\n const appGroup: SidebarLayoutNavItem | undefined = apps && appNavItems.length > 0\n ? {\n id: 'workspace-apps',\n label: 'Apps',\n icon: apps.icon,\n expandable: true,\n defaultOpen: activeAppId !== undefined,\n subItems: appNavItems.map(({ id, label, icon, href, prefetch }) => ({\n id,\n label,\n icon,\n href: href!,\n prefetch,\n })),\n subActiveIds: activeAppId ? [activeAppId] : undefined,\n }\n : undefined\n const workspaceNavItems: SidebarLayoutNavItem[] = [\n ...navItems,\n ...(appGroup ? [appGroup] : []),\n ...(sessionNav ? [sessionNav] : []),\n ]\n\n const layoutProps = {\n hideBelow: 'lg' as const,\n railLabels: true,\n ...sidebarProps,\n }\n\n return (\n <SidebarLayout\n {...layoutProps}\n navItems={workspaceNavItems}\n activeId={activeAppId ? appGroup?.id : resolvedActiveId}\n >\n {children}\n </SidebarLayout>\n )\n}\n\nexport { AgentWorkspaceCompanion, type AgentWorkspaceCompanionHandle, type AgentWorkspaceCompanionProps, type AgentWorkspaceCompanionTab } from './companion'\n","import { forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState, type ReactNode } from 'react'\nimport { Tabs, TabsContent, TabsList, TabsTrigger } from '@tangle-network/sandbox-ui/primitives'\nimport { WorkspaceLayout } from '@tangle-network/sandbox-ui/workspace'\n\nexport interface AgentWorkspaceCompanionTab {\n id: string\n label: string\n icon?: ReactNode\n /** Retain a visited tab through tab switches, pane closure, and viewport changes. */\n keepMounted?: boolean\n renderContent: (state: { active: boolean }) => ReactNode\n}\n\nexport interface AgentWorkspaceCompanionHandle {\n openTab: (tabId: string) => boolean\n}\n\nexport interface AgentWorkspaceCompanionProps {\n children: ReactNode\n tabs: readonly AgentWorkspaceCompanionTab[]\n open?: boolean\n onOpenChange?: (open: boolean) => void\n defaultOpen?: boolean\n activeTabId?: string\n onActiveTabChange?: (tabId: string) => void\n defaultActiveTabId?: string\n /** Namespace for remembered tab selection and underlying pane dimensions. */\n persistenceKey?: string\n label?: string\n defaultWidth?: number\n className?: string\n}\n\n/** Product-owned tools beside a conversation; omitted tools have no tabs or effects. */\nexport const AgentWorkspaceCompanion = forwardRef<AgentWorkspaceCompanionHandle, AgentWorkspaceCompanionProps>(function AgentWorkspaceCompanion({\n children,\n tabs,\n open: controlledOpen,\n onOpenChange,\n defaultOpen = false,\n activeTabId,\n onActiveTabChange,\n defaultActiveTabId,\n persistenceKey,\n label = 'Workspace tools',\n defaultWidth = 420,\n className,\n}, ref) {\n const [uncontrolledOpen, setOpen] = useState(defaultOpen)\n const open = controlledOpen ?? uncontrolledOpen\n const [selection, setSelection] = useState({ key: persistenceKey, id: defaultActiveTabId })\n const [visits, setVisits] = useState<{ key: string | undefined; ids: ReadonlySet<string> }>(() => ({ key: persistenceKey, ids: new Set() }))\n const requested = activeTabId ?? (selection.key === persistenceKey ? selection.id : defaultActiveTabId)\n const active = tabs.find((tab) => tab.id === requested)?.id ?? tabs[0]?.id\n const visited = visits.key === persistenceKey ? visits.ids : new Set<string>()\n const storageKey = persistenceKey ? `${persistenceKey}:companion-tab` : undefined\n\n const pendingRestoration = useRef<{ key: string | undefined; id: string | undefined } | undefined>(undefined)\n const reconciledSelection = useRef<string | undefined>(undefined)\n const restoredKey = useRef<string | undefined>(undefined)\n useEffect(() => {\n const key = JSON.stringify([persistenceKey, defaultActiveTabId])\n if (restoredKey.current === key || tabs.length === 0) return\n let id = activeTabId ?? defaultActiveTabId\n if (storageKey) {\n try { id = window.localStorage.getItem(storageKey) ?? id } catch { /* Browser storage is optional. */ }\n }\n const resolved = tabs.find((tab) => tab.id === id)?.id ?? tabs[0]?.id\n restoredKey.current = key\n pendingRestoration.current = { key: persistenceKey, id: resolved }\n setSelection({ key: persistenceKey, id: resolved })\n if (resolved && resolved !== activeTabId) {\n reconciledSelection.current = JSON.stringify([persistenceKey, requested, resolved])\n onActiveTabChange?.(resolved)\n }\n }, [storageKey, persistenceKey, defaultActiveTabId, activeTabId, requested, tabs, onActiveTabChange])\n\n useEffect(() => {\n // Let restored selection reach the controlled parent before reconciling stale props.\n const pending = pendingRestoration.current\n if (pending) {\n const acknowledged = activeTabId === undefined\n ? selection.key === pending.key && selection.id === pending.id\n : activeTabId === pending.id\n if (!acknowledged) return\n pendingRestoration.current = undefined\n }\n if (!active || tabs.some((tab) => tab.id === requested)) {\n reconciledSelection.current = undefined\n return\n }\n const key = JSON.stringify([persistenceKey, requested, active])\n if (reconciledSelection.current === key) return\n reconciledSelection.current = key\n setSelection({ key: persistenceKey, id: active })\n onActiveTabChange?.(active)\n }, [active, activeTabId, requested, selection, persistenceKey, tabs, onActiveTabChange])\n\n useEffect(() => {\n if (!open || !active) return\n setVisits((previous) => {\n const ids = previous.key === persistenceKey ? previous.ids : new Set<string>()\n return ids.has(active) ? previous : { key: persistenceKey, ids: new Set([...ids, active]) }\n })\n }, [open, active, persistenceKey])\n\n const selectTab = useCallback((id: string) => {\n if (!tabs.some((tab) => tab.id === id)) return false\n setSelection({ key: persistenceKey, id })\n onActiveTabChange?.(id)\n if (storageKey) {\n try { window.localStorage.setItem(storageKey, id) } catch { /* Selection still works without storage. */ }\n }\n return true\n }, [tabs, persistenceKey, storageKey, onActiveTabChange])\n const changeOpen = useCallback((next: boolean) => {\n setOpen(next)\n onOpenChange?.(next)\n }, [onOpenChange])\n\n useImperativeHandle(ref, () => ({\n openTab(id) {\n if (!selectTab(id)) return false\n changeOpen(true)\n return true\n },\n }), [selectTab, changeOpen])\n\n if (tabs.length === 0) return <>{children}</>\n\n return (\n <Tabs key={persistenceKey} value={active} onValueChange={selectTab} className={`flex h-full min-h-0 min-w-0 flex-1 flex-col ${className ?? ''}`}>\n <WorkspaceLayout\n className=\"h-full min-h-0 min-w-0 flex-1\"\n collapsedControlsPlacement=\"overlay\"\n keepRightMounted\n center={children}\n rightOpen={open}\n onRightOpenChange={changeOpen}\n rightLabel={label}\n defaultRightWidth={defaultWidth}\n persistenceKey={persistenceKey}\n minRightWidth={280}\n rightContentClassName=\"flex flex-col overflow-hidden\"\n rightHeader={(\n <TabsList aria-label={label} className=\"h-9 max-w-full justify-start overflow-x-auto bg-transparent p-0\">\n {tabs.map((tab) => (\n <TabsTrigger key={tab.id} value={tab.id} className=\"gap-1.5 px-2.5 text-sm\">\n {tab.icon}<span>{tab.label}</span>\n </TabsTrigger>\n ))}\n </TabsList>\n )}\n right={tabs.map((tab) => {\n const isActive = tab.id === active\n const retained = tab.keepMounted && visited.has(tab.id)\n if (!(open && isActive) && !retained) return null\n return (\n <TabsContent\n key={tab.id}\n value={tab.id}\n forceMount={retained ? true : undefined}\n hidden={!open || !isActive}\n className=\"m-0 h-full min-h-0 min-w-0 flex-1 data-[state=inactive]:hidden\"\n >\n {tab.renderContent({ active: open && isActive })}\n </TabsContent>\n )\n })}\n />\n </Tabs>\n )\n})\n"],"mappings":";;;;;;;AAAA,SAAS,qBAAyE;;;ACAlF,SAAS,YAAY,aAAa,WAAW,qBAAqB,QAAQ,gBAAgC;AAC1G,SAAS,MAAM,aAAa,UAAU,mBAAmB;AACzD,SAAS,uBAAuB;AA8HA,wBAmBlB,YAnBkB;AA9FzB,IAAM,0BAA0B,WAAwE,SAASA,yBAAwB;AAAA,EAC9I;AAAA,EACA;AAAA,EACA,MAAM;AAAA,EACN;AAAA,EACA,cAAc;AAAA,EACd;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,QAAQ;AAAA,EACR,eAAe;AAAA,EACf;AACF,GAAG,KAAK;AACN,QAAM,CAA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AM,KAAK;AAAA,IACX,YAAY;AAAA,IACZ,aAAa,gBAAgB;AAAA,IAC7B,UAAU,YAAY,IAAI,CAAC,EAAE,IAAI,OAAO,MAAM,MAAM,SAAS,OAAO;AAAA,MAClE;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF,EAAE;AAAA,IACF,cAAc,cAAc,CAAC,WAAW,IAAI;AAAA,EAC9C,IACA;AACJ,QAAM,oBAA4C;AAAA,IAChD,GAAG;AAAA,IACH,GAAI,WAAW,CAAC,QAAQ,IAAI,CAAC;AAAA,IAC7B,GAAI,aAAa,CAAC,UAAU,IAAI,CAAC;AAAA,EACnC;AAEA,QAAM,cAAc;AAAA,IAClB,WAAW;AAAA,IACX,YAAY;AAAA,IACZ,GAAG;AAAA,EACL;AAEA,SACE,gBAAAA;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACJ,UAAU;AAAA,MACV,UAAU,cAAc,UAAU,KAAK;AAAA,MAEtC;AAAA;AAAA,EACH;AAEJ;","names":["AgentWorkspaceCompanion","jsx"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tangle-network/agent-app",
|
|
3
|
-
"version": "0.50.
|
|
3
|
+
"version": "0.50.33",
|
|
4
4
|
"packageManager": "pnpm@11.24.0",
|
|
5
5
|
"description": "Build agent applications with typed chat, tools, sandboxes, integrations, billing, and evaluation.",
|
|
6
6
|
"keywords": [
|
|
@@ -73,6 +73,11 @@
|
|
|
73
73
|
"import": "./dist/app-auth/index.js",
|
|
74
74
|
"default": "./dist/app-auth/index.js"
|
|
75
75
|
},
|
|
76
|
+
"./app-oauth": {
|
|
77
|
+
"types": "./dist/app-oauth/index.d.ts",
|
|
78
|
+
"import": "./dist/app-oauth/index.js",
|
|
79
|
+
"default": "./dist/app-oauth/index.js"
|
|
80
|
+
},
|
|
76
81
|
"./runtime": {
|
|
77
82
|
"types": "./dist/runtime/index.d.ts",
|
|
78
83
|
"import": "./dist/runtime/index.js",
|
|
@@ -213,6 +218,11 @@
|
|
|
213
218
|
"import": "./dist/integrations/index.js",
|
|
214
219
|
"default": "./dist/integrations/index.js"
|
|
215
220
|
},
|
|
221
|
+
"./integrations-react": {
|
|
222
|
+
"types": "./dist/integrations-react/index.d.ts",
|
|
223
|
+
"import": "./dist/integrations-react/index.js",
|
|
224
|
+
"default": "./dist/integrations-react/index.js"
|
|
225
|
+
},
|
|
216
226
|
"./channels": {
|
|
217
227
|
"types": "./dist/channels/index.d.ts",
|
|
218
228
|
"import": "./dist/channels/index.js",
|
|
@@ -228,6 +238,11 @@
|
|
|
228
238
|
"import": "./dist/agent-enrollment/index.js",
|
|
229
239
|
"default": "./dist/agent-enrollment/index.js"
|
|
230
240
|
},
|
|
241
|
+
"./agent-enrollment/drizzle": {
|
|
242
|
+
"types": "./dist/agent-enrollment/drizzle.d.ts",
|
|
243
|
+
"import": "./dist/agent-enrollment/drizzle.js",
|
|
244
|
+
"default": "./dist/agent-enrollment/drizzle.js"
|
|
245
|
+
},
|
|
231
246
|
"./hosted-agent/application": {
|
|
232
247
|
"types": "./dist/hosted-agent/application.d.ts",
|
|
233
248
|
"import": "./dist/hosted-agent/application.js",
|
|
@@ -563,6 +578,7 @@
|
|
|
563
578
|
"build-storybook": "storybook build"
|
|
564
579
|
},
|
|
565
580
|
"devDependencies": {
|
|
581
|
+
"@better-auth/oauth-provider": "1.7.2",
|
|
566
582
|
"@cloudflare/workers-types": "5.20260828.1",
|
|
567
583
|
"@firecrawl/pdf-inspector-wasm": "^1.17.0",
|
|
568
584
|
"@hocuspocus/provider": "^4.6.0",
|
|
@@ -580,7 +596,7 @@
|
|
|
580
596
|
"@tangle-network/brand": "1.9.1",
|
|
581
597
|
"@tangle-network/hub-sdk": "0.22.1",
|
|
582
598
|
"@tangle-network/sandbox": "0.59.0",
|
|
583
|
-
"@tangle-network/sandbox-ui": "0.
|
|
599
|
+
"@tangle-network/sandbox-ui": "0.117.0",
|
|
584
600
|
"@tangle-network/ui": "11.12.0",
|
|
585
601
|
"@testing-library/dom": "^10.4.1",
|
|
586
602
|
"@testing-library/react": "^16.3.3",
|
|
@@ -634,9 +650,12 @@
|
|
|
634
650
|
"playwright": "^1.63.0",
|
|
635
651
|
"@ai-sdk/google": "^3.0.33",
|
|
636
652
|
"@ai-sdk/anthropic": "^3.0.49",
|
|
637
|
-
"@anthropic-ai/sdk": "^0.93.0"
|
|
653
|
+
"@anthropic-ai/sdk": "^0.93.0",
|
|
654
|
+
"@nanostores/react": "1.1.0",
|
|
655
|
+
"nanostores": "1.5.4"
|
|
638
656
|
},
|
|
639
657
|
"peerDependencies": {
|
|
658
|
+
"@better-auth/oauth-provider": ">=1.7.2",
|
|
640
659
|
"@firecrawl/pdf-inspector-wasm": ">=0.1.3",
|
|
641
660
|
"@huggingface/transformers": ">=3",
|
|
642
661
|
"@tangle-network/agent-eval": ">=0.199.0 <0.204.0",
|
|
@@ -648,7 +667,7 @@
|
|
|
648
667
|
"@tangle-network/brand": ">=1.6.0",
|
|
649
668
|
"@tangle-network/hub-sdk": ">=0.19.3 <0.21.0 || >=0.21.0 <0.22.0 || >=0.22.1 <0.23.0",
|
|
650
669
|
"@tangle-network/sandbox": ">=0.45.0 <0.48.0 || ^0.49.0 || ^0.50.0 || ^0.51.0 || ^0.52.0 || ^0.53.0 || ^0.54.0 || ^0.55.0 || >=0.58.1 <0.60.0",
|
|
651
|
-
"@tangle-network/sandbox-ui": ">=0.
|
|
670
|
+
"@tangle-network/sandbox-ui": ">=0.117.0 <0.118.0",
|
|
652
671
|
"@tangle-network/ui": ">=11.11.3 <12.0.0",
|
|
653
672
|
"@tiptap/core": ">=3.28.0 <4.0.0",
|
|
654
673
|
"@tiptap/extension-mention": ">=3.28.0 <4.0.0",
|
|
@@ -670,9 +689,14 @@
|
|
|
670
689
|
"@modelcontextprotocol/sdk": "^1.30.0",
|
|
671
690
|
"@tangle-network/browser-agent-driver": "^0.36.1",
|
|
672
691
|
"@tangle-network/tcloud": "^0.5.2 || >=0.8.1 <0.9.0",
|
|
673
|
-
"playwright": "^1.63.0"
|
|
692
|
+
"playwright": "^1.63.0",
|
|
693
|
+
"@nanostores/react": ">=0.8.4 <2.0.0",
|
|
694
|
+
"nanostores": ">=0.11.3 <2.0.0"
|
|
674
695
|
},
|
|
675
696
|
"peerDependenciesMeta": {
|
|
697
|
+
"@better-auth/oauth-provider": {
|
|
698
|
+
"optional": true
|
|
699
|
+
},
|
|
676
700
|
"@firecrawl/pdf-inspector-wasm": {
|
|
677
701
|
"optional": true
|
|
678
702
|
},
|
|
@@ -765,6 +789,12 @@
|
|
|
765
789
|
},
|
|
766
790
|
"playwright": {
|
|
767
791
|
"optional": true
|
|
792
|
+
},
|
|
793
|
+
"@nanostores/react": {
|
|
794
|
+
"optional": true
|
|
795
|
+
},
|
|
796
|
+
"nanostores": {
|
|
797
|
+
"optional": true
|
|
768
798
|
}
|
|
769
799
|
},
|
|
770
800
|
"dependencies": {
|