@agent-native/core 0.146.4 → 0.146.5
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/corpus/templates/analytics/app/components/layout/CommandPalette.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/analytics/app/pages/Settings.tsx +5 -1
- package/corpus/templates/analytics/app/routes/agent.tsx +7 -5
- package/corpus/templates/assets/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/assets/app/routes/agent.tsx +7 -5
- package/corpus/templates/assets/app/routes/settings.tsx +7 -2
- package/corpus/templates/assets/server/plugins/creative-context.ts +1 -1
- package/corpus/templates/brain/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/brain/app/lib/brain.ts +4 -2
- package/corpus/templates/brain/app/root.tsx +1 -1
- package/corpus/templates/brain/app/routes/agent.tsx +10 -2
- package/corpus/templates/calendar/app/components/layout/AppLayout.tsx +1 -1
- package/corpus/templates/calendar/app/root.tsx +1 -1
- package/corpus/templates/calendar/app/routes/_app.agent.tsx +8 -16
- package/corpus/templates/chat/app/hooks/use-navigation-state.ts +5 -2
- package/corpus/templates/chat/app/routes/agent.tsx +7 -31
- package/corpus/templates/clips/app/components/library/library-layout.tsx +1 -1
- package/corpus/templates/clips/app/root.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.agent.tsx +9 -7
- package/corpus/templates/content/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/content/app/root.tsx +1 -1
- package/corpus/templates/content/app/routes/_app.agent.tsx +9 -8
- package/corpus/templates/content/app/routes/_app.settings.tsx +7 -2
- package/corpus/templates/content/server/plugins/creative-context.ts +1 -1
- package/corpus/templates/crm/app/components/crm/RecordActions.tsx +4 -1
- package/corpus/templates/crm/app/components/layout/CrmLayout.tsx +1 -1
- package/corpus/templates/crm/app/routes/agent.tsx +10 -2
- package/corpus/templates/design/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/design/app/root.tsx +1 -1
- package/corpus/templates/design/app/routes/agent.tsx +9 -7
- package/corpus/templates/design/app/routes/settings.tsx +7 -2
- package/corpus/templates/design/server/plugins/creative-context.ts +1 -1
- package/corpus/templates/dispatch/app/root.tsx +5 -2
- package/corpus/templates/dispatch/app/routes/agent.tsx +7 -7
- package/corpus/templates/factory/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/factory/app/hooks/use-navigation-state.ts +5 -2
- package/corpus/templates/factory/app/root.tsx +1 -1
- package/corpus/templates/factory/app/routes/agent.tsx +9 -14
- package/corpus/templates/forms/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/forms/app/root.tsx +1 -1
- package/corpus/templates/forms/app/routes/_app.agent.tsx +9 -7
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +5 -3
- package/corpus/templates/macros/app/root.tsx +1 -1
- package/corpus/templates/macros/app/routes/agent.tsx +9 -6
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +8 -2
- package/corpus/templates/mail/app/components/layout/CommandPalette.tsx +1 -1
- package/corpus/templates/mail/app/routes/agent.tsx +9 -6
- package/corpus/templates/plan/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/plan/app/root.tsx +1 -1
- package/corpus/templates/plan/app/routes/agent.tsx +9 -6
- package/corpus/templates/slides/app/components/editor/ImageGenPanel.tsx +8 -12
- package/corpus/templates/slides/app/components/editor/SlideEditor.tsx +39 -2
- package/corpus/templates/slides/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/slides/app/i18n/en-US.ts +1 -0
- package/corpus/templates/slides/app/lib/create-deck-generation.ts +22 -5
- package/corpus/templates/slides/app/pages/Index.tsx +20 -5
- package/corpus/templates/slides/app/root.tsx +1 -1
- package/corpus/templates/slides/app/routes/agent.tsx +6 -9
- package/corpus/templates/slides/app/routes/settings.tsx +7 -2
- package/corpus/templates/slides/server/plugins/creative-context.ts +1 -1
- package/corpus/templates/tasks/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/tasks/app/routes/agent.tsx +10 -2
- package/dist/client/index.d.ts +1 -1
- package/dist/client/navigation/index.d.ts +1 -1
- package/dist/client/navigation/index.js +1 -1
- package/dist/client/org/OrgSwitcher.js +1 -1
- package/dist/client/settings/SettingsPanel.d.ts +8 -0
- package/dist/client/settings/SettingsPanel.js +16 -1
- package/dist/client/settings/index.d.ts +1 -1
- package/dist/collab/awareness.d.ts +2 -2
- package/dist/navigation/index.d.ts +1 -0
- package/dist/navigation/index.js +34 -0
- package/dist/notifications/routes.d.ts +3 -3
- package/dist/observability/routes.d.ts +3 -3
- package/dist/progress/routes.d.ts +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/templates/chat/app/hooks/use-navigation-state.ts +5 -2
- package/dist/templates/chat/app/routes/agent.tsx +7 -31
- package/dist/templates/default/app/routes/_index.tsx +1 -1
- package/dist/templates/default/app/routes/agent.tsx +7 -25
- package/package.json +3 -3
- package/src/templates/chat/app/hooks/use-navigation-state.ts +5 -2
- package/src/templates/chat/app/routes/agent.tsx +7 -31
- package/src/templates/default/app/routes/_index.tsx +1 -1
- package/src/templates/default/app/routes/agent.tsx +7 -25
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { buildLegacyAgentSettingsRoute } from "@agent-native/core/client/navigation";
|
|
2
|
+
import { Navigate, useLocation } from "react-router";
|
|
2
3
|
|
|
3
4
|
import { APP_TITLE } from "@/lib/app-config";
|
|
4
5
|
|
|
@@ -7,5 +8,12 @@ export function meta() {
|
|
|
7
8
|
}
|
|
8
9
|
|
|
9
10
|
export default function AgentRoute() {
|
|
10
|
-
|
|
11
|
+
const location = useLocation();
|
|
12
|
+
|
|
13
|
+
return (
|
|
14
|
+
<Navigate
|
|
15
|
+
to={buildLegacyAgentSettingsRoute(location.hash, location.search)}
|
|
16
|
+
replace
|
|
17
|
+
/>
|
|
18
|
+
);
|
|
11
19
|
}
|
package/dist/client/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ export { AgentNativeI18nProvider, LanguagePicker, getLocaleInitScript, localeDir
|
|
|
13
13
|
export { AgentNativeIcon } from "./components/icons/AgentNativeIcon.js";
|
|
14
14
|
export { FeatureFlagsEditor, evaluatedFeatureFlagValues, featureFlagValue, useFeatureFlag, useFeatureFlags, type FeatureFlagActor, type FeatureFlagMetadata, type FeatureFlagRules, type SetFeatureFlagInput, } from "./feature-flags/index.js";
|
|
15
15
|
export { withBuilderUtmTrackingParams } from "../shared/builder-link-tracking.js";
|
|
16
|
-
export { SettingsPanel, SettingsTabsPage, SecretsSection, getAgentSettingsSearchTabs, openBuilderConnectPopup, useAgentSettingsTabs, useBuilderConnectFlow, useBuilderStatus, withBuilderConnectTrackingParams, type BuilderConnectFlow, type BuilderConnectFlowOptions, type BuilderConnectStartOptions, type BuilderStatus, type AgentSettingsSearchTab, type OpenBuilderConnectPopupOptions, type SecretsSectionProps, type SettingsPanelProps, type SettingsSearchEntry, type SettingsTabItem, type SettingsTabsPageProps, } from "./settings/index.js";
|
|
16
|
+
export { SettingsPanel, SettingsTabsPage, SecretsSection, getAgentSettingsSearchTabs, openBuilderConnectPopup, useAgentSettingsTabs, type AgentSettingsTabFactory, type AgentSettingsTabFactoryContext, useBuilderConnectFlow, useBuilderStatus, withBuilderConnectTrackingParams, type BuilderConnectFlow, type BuilderConnectFlowOptions, type BuilderConnectStartOptions, type BuilderStatus, type AgentSettingsSearchTab, type OpenBuilderConnectPopupOptions, type SecretsSectionProps, type SettingsPanelProps, type SettingsSearchEntry, type SettingsTabItem, type SettingsTabsPageProps, } from "./settings/index.js";
|
|
17
17
|
export { DevDatabaseLink, type DevDatabaseLinkProps, } from "./db-admin/DevDatabaseLink.js";
|
|
18
18
|
export { DbAdminPage } from "./db-admin/DbAdminPage.js";
|
|
19
19
|
export { installRouteChunkRecovery, reloadForStaleChunk, recoverFromStaleChunkError, } from "./route-chunk-recovery.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { agentNativePath, appApiPath, appBasePath, appPath, } from "../api-path.js";
|
|
2
2
|
export { useAgentRouteState, useSemanticNavigationState, type AgentRouteLocation, type SemanticNavigationCommandEnvelope, type UseAgentRouteStateOptions, type UseAgentRouteStateResult, type UseSemanticNavigationStateOptions, type UseSemanticNavigationStateResult, } from "../route-state.js";
|
|
3
3
|
export { COMMAND_MENU_OPEN_EVENT, CommandMenu, openAgentSidebar, openAgentSettings, openCommandMenu, submitToAgent, useCommandMenuShortcut, type CommandMenuProps, type CommandMenuDoc, type CommandDocsGroupProps, type CommandGroupProps, type CommandItemProps, type CommandShortcutProps, } from "../CommandMenu.js";
|
|
4
|
-
export { buildOpenRouteLink, buildOpenRoutePath, buildResourceRoute, buildSettingsRoute, buildStandardAppRoute, buildTeamRoute, createStandardOpenPathResolver, STANDARD_APP_ROUTES, STANDARD_SETTINGS_TABS, type BuildResourceRouteOptions, type BuildStandardAppRouteOptions, type NavigationLink, type NavigationTarget, type StandardAppRouteId, type StandardOpenPathResolverOptions, type StandardOpenPathRoute, type StandardSettingsTabId, } from "../../navigation/index.js";
|
|
4
|
+
export { buildOpenRouteLink, buildOpenRoutePath, buildLegacyAgentSettingsRoute, buildResourceRoute, buildSettingsRoute, buildStandardAppRoute, buildTeamRoute, createStandardOpenPathResolver, STANDARD_APP_ROUTES, STANDARD_SETTINGS_TABS, type BuildResourceRouteOptions, type BuildStandardAppRouteOptions, type NavigationLink, type NavigationTarget, type StandardAppRouteId, type StandardOpenPathResolverOptions, type StandardOpenPathRoute, type StandardSettingsTabId, } from "../../navigation/index.js";
|
|
5
5
|
export { postNavigate, isInAgentEmbed, AGENT_NAVIGATE_MESSAGE_TYPE, type AgentNavigateMessage, } from "../embed.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { agentNativePath, appApiPath, appBasePath, appPath, } from "../api-path.js";
|
|
2
2
|
export { useAgentRouteState, useSemanticNavigationState, } from "../route-state.js";
|
|
3
3
|
export { COMMAND_MENU_OPEN_EVENT, CommandMenu, openAgentSidebar, openAgentSettings, openCommandMenu, submitToAgent, useCommandMenuShortcut, } from "../CommandMenu.js";
|
|
4
|
-
export { buildOpenRouteLink, buildOpenRoutePath, buildResourceRoute, buildSettingsRoute, buildStandardAppRoute, buildTeamRoute, createStandardOpenPathResolver, STANDARD_APP_ROUTES, STANDARD_SETTINGS_TABS, } from "../../navigation/index.js";
|
|
4
|
+
export { buildOpenRouteLink, buildOpenRoutePath, buildLegacyAgentSettingsRoute, buildResourceRoute, buildSettingsRoute, buildStandardAppRoute, buildTeamRoute, createStandardOpenPathResolver, STANDARD_APP_ROUTES, STANDARD_SETTINGS_TABS, } from "../../navigation/index.js";
|
|
5
5
|
export { postNavigate, isInAgentEmbed, AGENT_NAVIGATE_MESSAGE_TYPE, } from "../embed.js";
|
|
@@ -32,7 +32,7 @@ const SWITCHER_BUTTON_CLASS = "flex w-full items-center gap-2 rounded-md border-
|
|
|
32
32
|
const COMPACT_SWITCHER_BUTTON_CLASS = "flex items-center justify-center rounded-md border-0 bg-accent/50 p-1.5 text-muted-foreground hover:bg-accent/70 hover:text-foreground focus:outline-none focus-visible:ring-2 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-60 cursor-pointer";
|
|
33
33
|
const DEFAULT_ORGANIZATION_SETTINGS_PATH = "/settings/organization";
|
|
34
34
|
const DEFAULT_PROFILE_PATH = "/settings/account";
|
|
35
|
-
const DEFAULT_AGENT_PATH = "/agent";
|
|
35
|
+
const DEFAULT_AGENT_PATH = "/settings/agent";
|
|
36
36
|
const APP_ICON_MAP = {
|
|
37
37
|
Mail: IconMail,
|
|
38
38
|
CalendarDays: IconCalendar,
|
|
@@ -26,7 +26,15 @@ export interface AgentSettingsTabsOptions {
|
|
|
26
26
|
extensionTools?: boolean;
|
|
27
27
|
/** Optional page-level settings to show in the Agent section. */
|
|
28
28
|
agentAdditionalContent?: React.ReactNode;
|
|
29
|
+
/** Optional app-owned tabs that share the Agent settings scope. */
|
|
30
|
+
agentAdditionalTabFactories?: AgentSettingsTabFactory[];
|
|
29
31
|
}
|
|
32
|
+
export interface AgentSettingsTabFactoryContext {
|
|
33
|
+
scope: "user";
|
|
34
|
+
canManageOrg?: boolean;
|
|
35
|
+
scopeControl: React.ReactNode;
|
|
36
|
+
}
|
|
37
|
+
export type AgentSettingsTabFactory = (context: AgentSettingsTabFactoryContext) => SettingsTabItem;
|
|
30
38
|
export declare function areExtensionSettingsEnabled(options?: AgentSettingsTabsOptions): boolean;
|
|
31
39
|
export declare function SettingsPanel(props: SettingsPanelProps): React.JSX.Element;
|
|
32
40
|
export declare function ConnectionsSettingsContent({ settingsPanelProps, }: {
|
|
@@ -13,6 +13,7 @@ import { BuilderBMark } from "../builder-mark.js";
|
|
|
13
13
|
import { Popover, PopoverContent, PopoverTrigger, } from "../components/ui/popover.js";
|
|
14
14
|
import { Tooltip, TooltipContent, TooltipTrigger, } from "../components/ui/tooltip.js";
|
|
15
15
|
import { useT } from "../i18n.js";
|
|
16
|
+
import { useOrg } from "../org/hooks.js";
|
|
16
17
|
import { TeamPage } from "../org/TeamPage.js";
|
|
17
18
|
import { BuilderConnectCard } from "../setup-connections/BuilderConnectCard.js";
|
|
18
19
|
import { callAction } from "../use-action.js";
|
|
@@ -1073,8 +1074,11 @@ export function AgentSettingsContent({ className, sections = AGENT_SETTINGS_SECT
|
|
|
1073
1074
|
}
|
|
1074
1075
|
export function useAgentSettingsTabs(options = {}) {
|
|
1075
1076
|
const { isDevMode, canToggle, setDevMode } = useDevMode();
|
|
1077
|
+
const { data: org } = useOrg();
|
|
1078
|
+
const canManageOrg = !org?.orgId || org.role === "owner" || org.role === "admin";
|
|
1076
1079
|
const extensionToolsEnabled = areExtensionSettingsEnabled(options);
|
|
1077
1080
|
const agentAdditionalContent = options.agentAdditionalContent;
|
|
1081
|
+
const agentAdditionalTabFactories = options.agentAdditionalTabFactories ?? [];
|
|
1078
1082
|
const baseProps = useMemo(() => ({
|
|
1079
1083
|
isDevMode,
|
|
1080
1084
|
onToggleDevMode: () => {
|
|
@@ -1082,6 +1086,11 @@ export function useAgentSettingsTabs(options = {}) {
|
|
|
1082
1086
|
},
|
|
1083
1087
|
showDevToggle: canToggle,
|
|
1084
1088
|
}), [canToggle, isDevMode, setDevMode]);
|
|
1089
|
+
const additionalTabs = useMemo(() => agentAdditionalTabFactories.map((factory) => factory({
|
|
1090
|
+
scope: "user",
|
|
1091
|
+
canManageOrg,
|
|
1092
|
+
scopeControl: null,
|
|
1093
|
+
})), [agentAdditionalTabFactories, canManageOrg]);
|
|
1085
1094
|
return useMemo(() => {
|
|
1086
1095
|
const searchTabs = getAgentSettingsSearchTabs();
|
|
1087
1096
|
const searchTab = (id) => {
|
|
@@ -1247,6 +1256,12 @@ export function useAgentSettingsTabs(options = {}) {
|
|
|
1247
1256
|
],
|
|
1248
1257
|
content: _jsx(AgentWorkspaceContent, { activeTab: "agents", overview: null }),
|
|
1249
1258
|
},
|
|
1259
|
+
...additionalTabs,
|
|
1250
1260
|
];
|
|
1251
|
-
}, [
|
|
1261
|
+
}, [
|
|
1262
|
+
agentAdditionalContent,
|
|
1263
|
+
additionalTabs,
|
|
1264
|
+
baseProps,
|
|
1265
|
+
extensionToolsEnabled,
|
|
1266
|
+
]);
|
|
1252
1267
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { AgentSettingsContent, areExtensionSettingsEnabled, SettingsPanel, useAgentSettingsTabs, type AgentSettingsTabsOptions, type SettingsPanelProps, } from "./SettingsPanel.js";
|
|
1
|
+
export { AgentSettingsContent, areExtensionSettingsEnabled, SettingsPanel, useAgentSettingsTabs, type AgentSettingsTabFactory, type AgentSettingsTabFactoryContext, type AgentSettingsTabsOptions, type SettingsPanelProps, } from "./SettingsPanel.js";
|
|
2
2
|
export { getAgentSettingsSearchTabs, type AgentSettingsSearchTab, } from "./agent-settings-search.js";
|
|
3
3
|
export { SettingsTabsPage, type SettingsSearchEntry, type SettingsTabItem, type SettingsTabsPageProps, } from "./SettingsTabsPage.js";
|
|
4
4
|
export { AccountSettingsCard, AccountSettingsForm, type AccountSettingsCardProps, type AccountSettingsFormProps, } from "./AccountSettingsCard.js";
|
|
@@ -62,11 +62,11 @@ export declare const postAwareness: import("h3").EventHandlerWithFetch<import("h
|
|
|
62
62
|
error: string;
|
|
63
63
|
states?: undefined;
|
|
64
64
|
} | {
|
|
65
|
-
error?: undefined;
|
|
66
65
|
states: {
|
|
67
66
|
clientId: number;
|
|
68
67
|
state: string;
|
|
69
68
|
}[];
|
|
69
|
+
error?: undefined;
|
|
70
70
|
}>>;
|
|
71
71
|
/**
|
|
72
72
|
* GET /_agent-native/collab/:docId/users
|
|
@@ -77,9 +77,9 @@ export declare const getActiveUsers: import("h3").EventHandlerWithFetch<import("
|
|
|
77
77
|
error: string;
|
|
78
78
|
users?: undefined;
|
|
79
79
|
} | {
|
|
80
|
-
error?: undefined;
|
|
81
80
|
users: {
|
|
82
81
|
clientId: number;
|
|
83
82
|
lastSeen: number;
|
|
84
83
|
}[];
|
|
84
|
+
error?: undefined;
|
|
85
85
|
}>>;
|
|
@@ -38,6 +38,7 @@ export interface StandardOpenPathResolverOptions {
|
|
|
38
38
|
fallback?: StandardOpenPathRoute;
|
|
39
39
|
}
|
|
40
40
|
export declare function buildSettingsRoute(tab?: StandardSettingsTabId | string | null, basePath?: "/settings"): string;
|
|
41
|
+
export declare function buildLegacyAgentSettingsRoute(hash?: string | null, search?: string): string;
|
|
41
42
|
export declare function buildTeamRoute(options?: Pick<BuildStandardAppRouteOptions, "teamInSettings">): string;
|
|
42
43
|
export declare function buildStandardAppRoute(route: StandardAppRouteId, options?: BuildStandardAppRouteOptions): string;
|
|
43
44
|
export declare function buildResourceRoute(collection: string, resourceId: string, options?: BuildResourceRouteOptions): string;
|
package/dist/navigation/index.js
CHANGED
|
@@ -15,6 +15,21 @@ export const STANDARD_SETTINGS_TABS = {
|
|
|
15
15
|
language: "language",
|
|
16
16
|
whatsNew: "whats-new",
|
|
17
17
|
};
|
|
18
|
+
const LEGACY_AGENT_RESOURCE_TABS = new Set([
|
|
19
|
+
"files",
|
|
20
|
+
"instructions",
|
|
21
|
+
"agents",
|
|
22
|
+
"memory",
|
|
23
|
+
"skills",
|
|
24
|
+
"learnings",
|
|
25
|
+
]);
|
|
26
|
+
const LEGACY_AGENT_SETTINGS_TABS = new Set([
|
|
27
|
+
"llm",
|
|
28
|
+
"app-models",
|
|
29
|
+
"limits",
|
|
30
|
+
"voice",
|
|
31
|
+
"background",
|
|
32
|
+
]);
|
|
18
33
|
function normalizeLeadingPath(path) {
|
|
19
34
|
const trimmed = path.trim();
|
|
20
35
|
if (!trimmed || trimmed === "/")
|
|
@@ -56,6 +71,25 @@ export function buildSettingsRoute(tab, basePath = STANDARD_APP_ROUTES.settings)
|
|
|
56
71
|
.filter(Boolean);
|
|
57
72
|
return `${path}/${segments.join("/")}`;
|
|
58
73
|
}
|
|
74
|
+
export function buildLegacyAgentSettingsRoute(hash, search = "") {
|
|
75
|
+
const legacyTab = hash?.replace(/^#/, "").toLowerCase() ?? "";
|
|
76
|
+
const destination = LEGACY_AGENT_RESOURCE_TABS.has(legacyTab)
|
|
77
|
+
? buildSettingsRoute(`agent:resources:${legacyTab}`)
|
|
78
|
+
: legacyTab === "remote-agents"
|
|
79
|
+
? buildSettingsRoute("agent:agents")
|
|
80
|
+
: legacyTab === "connections"
|
|
81
|
+
? buildSettingsRoute("connections")
|
|
82
|
+
: legacyTab === "jobs"
|
|
83
|
+
? buildSettingsRoute("agent:automations")
|
|
84
|
+
: legacyTab === "library"
|
|
85
|
+
? buildSettingsRoute("library")
|
|
86
|
+
: legacyTab === "access"
|
|
87
|
+
? buildSettingsRoute("agent")
|
|
88
|
+
: LEGACY_AGENT_SETTINGS_TABS.has(legacyTab)
|
|
89
|
+
? buildSettingsRoute(`agent:${legacyTab}`)
|
|
90
|
+
: buildSettingsRoute("agent");
|
|
91
|
+
return `${destination}${search}`;
|
|
92
|
+
}
|
|
59
93
|
export function buildTeamRoute(options = {}) {
|
|
60
94
|
return options.teamInSettings
|
|
61
95
|
? buildSettingsRoute(STANDARD_SETTINGS_TABS.team)
|
|
@@ -13,13 +13,13 @@
|
|
|
13
13
|
export declare function createNotificationsHandler(): import("h3").EventHandlerWithFetch<import("h3").EventHandlerRequest, Promise<"" | import("./types.js").Notification[] | {
|
|
14
14
|
count: number;
|
|
15
15
|
updated?: undefined;
|
|
16
|
-
ok?: undefined;
|
|
17
16
|
error?: undefined;
|
|
17
|
+
ok?: undefined;
|
|
18
18
|
} | {
|
|
19
19
|
count?: undefined;
|
|
20
20
|
updated: number;
|
|
21
|
-
ok?: undefined;
|
|
22
21
|
error?: undefined;
|
|
22
|
+
ok?: undefined;
|
|
23
23
|
} | {
|
|
24
24
|
count?: undefined;
|
|
25
25
|
updated?: undefined;
|
|
@@ -28,6 +28,6 @@ export declare function createNotificationsHandler(): import("h3").EventHandlerW
|
|
|
28
28
|
} | {
|
|
29
29
|
count?: undefined;
|
|
30
30
|
updated?: undefined;
|
|
31
|
-
ok: boolean;
|
|
32
31
|
error?: undefined;
|
|
32
|
+
ok: boolean;
|
|
33
33
|
}>>;
|
|
@@ -41,16 +41,16 @@ export declare function createObservabilityHandler(): import("h3").EventHandlerW
|
|
|
41
41
|
thumbsUpRate: number;
|
|
42
42
|
avgEvalScore: number;
|
|
43
43
|
} | {
|
|
44
|
-
error?: undefined;
|
|
45
44
|
summary: import("./types.js").TraceSummary;
|
|
46
45
|
spans: import("./types.js").TraceSpan[];
|
|
47
46
|
id?: undefined;
|
|
47
|
+
error?: undefined;
|
|
48
48
|
ok?: undefined;
|
|
49
49
|
} | {
|
|
50
|
-
error?: undefined;
|
|
51
50
|
summary?: undefined;
|
|
52
51
|
spans?: undefined;
|
|
53
52
|
id: string;
|
|
53
|
+
error?: undefined;
|
|
54
54
|
ok?: undefined;
|
|
55
55
|
} | {
|
|
56
56
|
summary?: undefined;
|
|
@@ -59,9 +59,9 @@ export declare function createObservabilityHandler(): import("h3").EventHandlerW
|
|
|
59
59
|
error: any;
|
|
60
60
|
ok?: undefined;
|
|
61
61
|
} | {
|
|
62
|
-
error?: undefined;
|
|
63
62
|
summary?: undefined;
|
|
64
63
|
spans?: undefined;
|
|
65
64
|
id?: undefined;
|
|
66
65
|
ok: boolean;
|
|
66
|
+
error?: undefined;
|
|
67
67
|
}>>;
|
|
@@ -42,7 +42,10 @@ function viewForPath(pathname: string): string {
|
|
|
42
42
|
if (pathname.startsWith("/database")) return "database";
|
|
43
43
|
if (pathname.startsWith("/extensions")) return "extensions";
|
|
44
44
|
if (pathname.startsWith("/observability")) return "observability";
|
|
45
|
-
if (pathname.startsWith("/agent")
|
|
45
|
+
if (pathname.startsWith("/settings/agent") || pathname.startsWith("/agent")) {
|
|
46
|
+
return "agent";
|
|
47
|
+
}
|
|
48
|
+
if (pathname.startsWith("/settings")) return "settings";
|
|
46
49
|
if (pathname.startsWith("/team")) return "settings";
|
|
47
50
|
return "chat";
|
|
48
51
|
}
|
|
@@ -60,7 +63,7 @@ function pathForView(view?: string): string {
|
|
|
60
63
|
case "observability":
|
|
61
64
|
return "/observability";
|
|
62
65
|
case "agent":
|
|
63
|
-
return "/agent";
|
|
66
|
+
return "/settings/agent";
|
|
64
67
|
case "settings":
|
|
65
68
|
return "/settings";
|
|
66
69
|
case "team":
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useSetPageTitle } from "@agent-native/toolkit/app-shell";
|
|
1
|
+
import { buildLegacyAgentSettingsRoute } from "@agent-native/core/client/navigation";
|
|
3
2
|
import { Navigate, useLocation } from "react-router";
|
|
4
3
|
|
|
5
4
|
export function meta() {
|
|
@@ -7,34 +6,11 @@ export function meta() {
|
|
|
7
6
|
}
|
|
8
7
|
|
|
9
8
|
export default function AgentRoute() {
|
|
10
|
-
const t = useT();
|
|
11
9
|
const location = useLocation();
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"agents",
|
|
19
|
-
"memory",
|
|
20
|
-
"skills",
|
|
21
|
-
"learnings",
|
|
22
|
-
]);
|
|
23
|
-
const destination = resourceTabs.has(legacyTab)
|
|
24
|
-
? `/settings/agent/resources/${legacyTab}`
|
|
25
|
-
: legacyTab === "remote-agents"
|
|
26
|
-
? "/settings/agent/agents"
|
|
27
|
-
: legacyTab === "connections"
|
|
28
|
-
? "/settings/integrations"
|
|
29
|
-
: legacyTab === "jobs"
|
|
30
|
-
? "/settings/agent/automations"
|
|
31
|
-
: legacyTab === "access"
|
|
32
|
-
? "/settings/agent"
|
|
33
|
-
: ["llm", "app-models", "limits", "voice", "background"].includes(
|
|
34
|
-
legacyTab,
|
|
35
|
-
)
|
|
36
|
-
? `/settings/agent/${legacyTab}`
|
|
37
|
-
: "/settings/agent";
|
|
38
|
-
|
|
39
|
-
return <Navigate to={destination} replace />;
|
|
10
|
+
return (
|
|
11
|
+
<Navigate
|
|
12
|
+
to={buildLegacyAgentSettingsRoute(location.hash, location.search)}
|
|
13
|
+
replace
|
|
14
|
+
/>
|
|
15
|
+
);
|
|
40
16
|
}
|
|
@@ -76,7 +76,7 @@ export default function IndexPage() {
|
|
|
76
76
|
</p>
|
|
77
77
|
</Link>
|
|
78
78
|
<Link
|
|
79
|
-
to="/agent"
|
|
79
|
+
to="/settings/agent"
|
|
80
80
|
className="group rounded-lg border border-border/50 px-4 py-3 hover:bg-accent/50 transition-colors"
|
|
81
81
|
>
|
|
82
82
|
<p className="text-[13px] font-medium text-foreground">
|
|
@@ -1,34 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { Link } from "react-router";
|
|
1
|
+
import { buildLegacyAgentSettingsRoute } from "@agent-native/core/client/navigation";
|
|
2
|
+
import { Navigate, useLocation } from "react-router";
|
|
4
3
|
|
|
5
4
|
export function meta() {
|
|
6
5
|
return [{ title: "Agent - {{APP_TITLE}}" }];
|
|
7
6
|
}
|
|
8
7
|
|
|
9
8
|
export default function AgentPage() {
|
|
10
|
-
const
|
|
11
|
-
|
|
9
|
+
const location = useLocation();
|
|
12
10
|
return (
|
|
13
|
-
<
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
to="/settings"
|
|
18
|
-
className="text-[13px] text-muted-foreground hover:text-foreground"
|
|
19
|
-
>
|
|
20
|
-
{t("settings.title")}
|
|
21
|
-
</Link>
|
|
22
|
-
<h1 className="text-2xl font-semibold tracking-tight text-foreground">
|
|
23
|
-
{t("settings.agentTitle")}
|
|
24
|
-
</h1>
|
|
25
|
-
<p className="text-[14px] leading-relaxed text-muted-foreground">
|
|
26
|
-
{t("settings.agentDescription")}
|
|
27
|
-
</p>
|
|
28
|
-
</div>
|
|
29
|
-
|
|
30
|
-
<AgentTabsPage className="min-h-[640px] rounded-lg border border-border/50" />
|
|
31
|
-
</div>
|
|
32
|
-
</main>
|
|
11
|
+
<Navigate
|
|
12
|
+
to={buildLegacyAgentSettingsRoute(location.hash, location.search)}
|
|
13
|
+
replace
|
|
14
|
+
/>
|
|
33
15
|
);
|
|
34
16
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agent-native/core",
|
|
3
|
-
"version": "0.146.
|
|
3
|
+
"version": "0.146.5",
|
|
4
4
|
"description": "Framework for agent-native application development — where AI agents and UI share SQL state, actions, and context",
|
|
5
5
|
"homepage": "https://github.com/BuilderIO/agent-native#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -412,8 +412,8 @@
|
|
|
412
412
|
"y-protocols": "^1.0.7",
|
|
413
413
|
"yjs": "^13.6.31",
|
|
414
414
|
"zod": "^4.3.6",
|
|
415
|
-
"@agent-native/
|
|
416
|
-
"@agent-native/
|
|
415
|
+
"@agent-native/toolkit": "^0.13.5",
|
|
416
|
+
"@agent-native/recap-cli": "0.5.3"
|
|
417
417
|
},
|
|
418
418
|
"devDependencies": {
|
|
419
419
|
"@ai-sdk/anthropic": "^3.0.71",
|
|
@@ -42,7 +42,10 @@ function viewForPath(pathname: string): string {
|
|
|
42
42
|
if (pathname.startsWith("/database")) return "database";
|
|
43
43
|
if (pathname.startsWith("/extensions")) return "extensions";
|
|
44
44
|
if (pathname.startsWith("/observability")) return "observability";
|
|
45
|
-
if (pathname.startsWith("/agent")
|
|
45
|
+
if (pathname.startsWith("/settings/agent") || pathname.startsWith("/agent")) {
|
|
46
|
+
return "agent";
|
|
47
|
+
}
|
|
48
|
+
if (pathname.startsWith("/settings")) return "settings";
|
|
46
49
|
if (pathname.startsWith("/team")) return "settings";
|
|
47
50
|
return "chat";
|
|
48
51
|
}
|
|
@@ -60,7 +63,7 @@ function pathForView(view?: string): string {
|
|
|
60
63
|
case "observability":
|
|
61
64
|
return "/observability";
|
|
62
65
|
case "agent":
|
|
63
|
-
return "/agent";
|
|
66
|
+
return "/settings/agent";
|
|
64
67
|
case "settings":
|
|
65
68
|
return "/settings";
|
|
66
69
|
case "team":
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useSetPageTitle } from "@agent-native/toolkit/app-shell";
|
|
1
|
+
import { buildLegacyAgentSettingsRoute } from "@agent-native/core/client/navigation";
|
|
3
2
|
import { Navigate, useLocation } from "react-router";
|
|
4
3
|
|
|
5
4
|
export function meta() {
|
|
@@ -7,34 +6,11 @@ export function meta() {
|
|
|
7
6
|
}
|
|
8
7
|
|
|
9
8
|
export default function AgentRoute() {
|
|
10
|
-
const t = useT();
|
|
11
9
|
const location = useLocation();
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"agents",
|
|
19
|
-
"memory",
|
|
20
|
-
"skills",
|
|
21
|
-
"learnings",
|
|
22
|
-
]);
|
|
23
|
-
const destination = resourceTabs.has(legacyTab)
|
|
24
|
-
? `/settings/agent/resources/${legacyTab}`
|
|
25
|
-
: legacyTab === "remote-agents"
|
|
26
|
-
? "/settings/agent/agents"
|
|
27
|
-
: legacyTab === "connections"
|
|
28
|
-
? "/settings/integrations"
|
|
29
|
-
: legacyTab === "jobs"
|
|
30
|
-
? "/settings/agent/automations"
|
|
31
|
-
: legacyTab === "access"
|
|
32
|
-
? "/settings/agent"
|
|
33
|
-
: ["llm", "app-models", "limits", "voice", "background"].includes(
|
|
34
|
-
legacyTab,
|
|
35
|
-
)
|
|
36
|
-
? `/settings/agent/${legacyTab}`
|
|
37
|
-
: "/settings/agent";
|
|
38
|
-
|
|
39
|
-
return <Navigate to={destination} replace />;
|
|
10
|
+
return (
|
|
11
|
+
<Navigate
|
|
12
|
+
to={buildLegacyAgentSettingsRoute(location.hash, location.search)}
|
|
13
|
+
replace
|
|
14
|
+
/>
|
|
15
|
+
);
|
|
40
16
|
}
|
|
@@ -76,7 +76,7 @@ export default function IndexPage() {
|
|
|
76
76
|
</p>
|
|
77
77
|
</Link>
|
|
78
78
|
<Link
|
|
79
|
-
to="/agent"
|
|
79
|
+
to="/settings/agent"
|
|
80
80
|
className="group rounded-lg border border-border/50 px-4 py-3 hover:bg-accent/50 transition-colors"
|
|
81
81
|
>
|
|
82
82
|
<p className="text-[13px] font-medium text-foreground">
|
|
@@ -1,34 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { Link } from "react-router";
|
|
1
|
+
import { buildLegacyAgentSettingsRoute } from "@agent-native/core/client/navigation";
|
|
2
|
+
import { Navigate, useLocation } from "react-router";
|
|
4
3
|
|
|
5
4
|
export function meta() {
|
|
6
5
|
return [{ title: "Agent - {{APP_TITLE}}" }];
|
|
7
6
|
}
|
|
8
7
|
|
|
9
8
|
export default function AgentPage() {
|
|
10
|
-
const
|
|
11
|
-
|
|
9
|
+
const location = useLocation();
|
|
12
10
|
return (
|
|
13
|
-
<
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
to="/settings"
|
|
18
|
-
className="text-[13px] text-muted-foreground hover:text-foreground"
|
|
19
|
-
>
|
|
20
|
-
{t("settings.title")}
|
|
21
|
-
</Link>
|
|
22
|
-
<h1 className="text-2xl font-semibold tracking-tight text-foreground">
|
|
23
|
-
{t("settings.agentTitle")}
|
|
24
|
-
</h1>
|
|
25
|
-
<p className="text-[14px] leading-relaxed text-muted-foreground">
|
|
26
|
-
{t("settings.agentDescription")}
|
|
27
|
-
</p>
|
|
28
|
-
</div>
|
|
29
|
-
|
|
30
|
-
<AgentTabsPage className="min-h-[640px] rounded-lg border border-border/50" />
|
|
31
|
-
</div>
|
|
32
|
-
</main>
|
|
11
|
+
<Navigate
|
|
12
|
+
to={buildLegacyAgentSettingsRoute(location.hash, location.search)}
|
|
13
|
+
replace
|
|
14
|
+
/>
|
|
33
15
|
);
|
|
34
16
|
}
|