@agent-native/core 0.141.6 → 0.141.7
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/README.md +1 -1
- package/corpus/templates/analytics/.agents/skills/dashboard-management/SKILL.md +3 -14
- package/corpus/templates/analytics/.agents/skills/data-querying/SKILL.md +11 -6
- package/corpus/templates/analytics/.agents/skills/prometheus/SKILL.md +5 -5
- package/corpus/templates/analytics/AGENTS.md +2 -2
- package/corpus/templates/analytics/actions/compose-dashboard.ts +1 -1
- package/corpus/templates/analytics/actions/migrate-first-party-analytics-to-bigquery.ts +135 -0
- package/corpus/templates/analytics/actions/navigate.ts +1 -1
- package/corpus/templates/analytics/actions/query-agent-native-analytics.ts +2 -2
- package/corpus/templates/analytics/actions/update-dashboard.ts +0 -1
- package/corpus/templates/analytics/actions/view-screen.ts +0 -20
- package/corpus/templates/analytics/app/components/layout/Header.tsx +0 -1
- package/corpus/templates/analytics/app/hooks/use-navigation-state.ts +5 -5
- package/corpus/templates/analytics/app/i18n-data.ts +2 -90
- package/corpus/templates/analytics/app/pages/Agents.tsx +0 -3
- package/corpus/templates/analytics/app/pages/Settings.tsx +22 -43
- package/corpus/templates/analytics/app/pages/settings/settings-search.ts +23 -20
- package/corpus/templates/analytics/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/analytics/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/analytics/app/routes/team.tsx +1 -1
- package/corpus/templates/analytics/changelog/2026-08-05-settings-no-longer-includes-an-unnecessary-about-section.md +6 -0
- package/corpus/templates/analytics/docs/schemas/first-party-analytics.md +1 -1
- package/corpus/templates/analytics/scripts/first-party-analytics-bigquery.sql +104 -0
- package/corpus/templates/analytics/server/lib/agent-chat-plan-mode.ts +0 -2
- package/corpus/templates/analytics/server/lib/first-party-analytics-backend.ts +1058 -0
- package/corpus/templates/analytics/server/lib/first-party-analytics-health.ts +34 -15
- package/corpus/templates/analytics/server/lib/first-party-analytics.ts +57 -4
- package/corpus/templates/analytics/server/lib/real-data-actions.ts +1 -3
- package/corpus/templates/analytics/server/plugins/agent-chat.ts +2 -4
- package/corpus/templates/assets/.agents/skills/asset-generation/SKILL.md +8 -6
- package/corpus/templates/assets/.agents/skills/library-management/SKILL.md +16 -1
- package/corpus/templates/assets/AGENTS.md +1 -0
- package/corpus/templates/assets/actions/_helpers.ts +12 -0
- package/corpus/templates/assets/actions/generate-image.ts +9 -3
- package/corpus/templates/assets/actions/import-style-from-url.ts +115 -0
- package/corpus/templates/assets/app/hooks/use-navigation-state.ts +3 -1
- package/corpus/templates/assets/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/assets/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/assets/app/routes/settings.tsx +5 -0
- package/corpus/templates/assets/app/routes/team.tsx +1 -1
- package/corpus/templates/assets/changelog/2026-08-05-brand-kits-can-import-a-website-s-hydrated-visual-language-a.md +6 -0
- package/corpus/templates/assets/changelog/2026-08-05-generated-images-now-hand-off-embeddable-previews-to-other-w.md +6 -0
- package/corpus/templates/assets/server/lib/generation.ts +58 -0
- package/corpus/templates/assets/shared/api.ts +12 -0
- package/corpus/templates/brain/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/brain/app/routes/team.tsx +1 -1
- package/corpus/templates/brain/app/routes.ts +1 -1
- package/corpus/templates/calendar/app/components/layout/AppLayout.tsx +3 -1
- package/corpus/templates/calendar/app/routes/_app.extensions._index.tsx +1 -1
- package/corpus/templates/calendar/app/routes/_app.settings.$.tsx +1 -0
- package/corpus/templates/calendar/app/routes/_app.team.tsx +1 -1
- package/corpus/templates/chat/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/chat/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/chat/app/root.tsx +1 -1
- package/corpus/templates/chat/app/routes/agent.tsx +7 -7
- package/corpus/templates/chat/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/chat/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/chat/app/routes/team.tsx +1 -1
- package/corpus/templates/clips/app/components/library/library-layout.tsx +1 -1
- package/corpus/templates/clips/app/components/player/transcript-panel.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/storage-setup-card.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.extensions._index.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.settings.$.tsx +1 -0
- package/corpus/templates/content/app/routes/_app.extensions._index.tsx +1 -1
- package/corpus/templates/content/app/routes/_app.settings.$.tsx +1 -0
- package/corpus/templates/content/app/routes/_app.team.tsx +1 -1
- package/corpus/templates/content/e2e/global-setup.ts +1 -1
- package/corpus/templates/design/.agents/skills/design-systems/SKILL.md +6 -1
- package/corpus/templates/design/actions/analyze-brand-assets.ts +7 -7
- package/corpus/templates/design/actions/import-from-url.ts +6 -5
- package/corpus/templates/design/app/pages/DesignSystemSetup.tsx +2 -2
- package/corpus/templates/design/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/design/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/design/app/routes/team.tsx +1 -1
- package/corpus/templates/design/changelog/2026-08-05-website-url-imports-now-capture-hydrated-browser-computed-de.md +6 -0
- package/corpus/templates/design/e2e/global-setup.ts +1 -1
- package/corpus/templates/dispatch/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/dispatch/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/dispatch/app/routes/team.tsx +1 -1
- package/corpus/templates/factory/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/factory/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/factory/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/factory/app/routes/team.tsx +1 -1
- package/corpus/templates/forms/app/routes/_app.extensions._index.tsx +1 -1
- package/corpus/templates/forms/app/routes/_app.settings.$.tsx +1 -0
- package/corpus/templates/forms/app/routes/_app.team.tsx +1 -1
- package/corpus/templates/forms/shared/navigation.ts +1 -1
- package/corpus/templates/macros/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/macros/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/macros/app/routes/team.tsx +1 -1
- package/corpus/templates/mail/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/mail/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/plan/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/plan/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/plan/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/plan/app/routes/team.tsx +1 -1
- package/corpus/templates/slides/.agents/skills/design-systems/SKILL.md +3 -1
- package/corpus/templates/slides/actions/analyze-brand-assets.ts +7 -7
- package/corpus/templates/slides/actions/import-from-url.ts +6 -6
- package/corpus/templates/slides/app/components/design-system/DesignSystemSetup.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/PromptDialog.tsx +3 -0
- package/corpus/templates/slides/app/components/onboarding/FirstDeckOnboardingFlow.tsx +9 -3
- package/corpus/templates/slides/app/context/DeckContext.tsx +71 -20
- package/corpus/templates/slides/app/global.css +6 -0
- package/corpus/templates/slides/app/lib/create-deck-generation.ts +9 -5
- package/corpus/templates/slides/app/pages/DeckEditor.tsx +17 -0
- package/corpus/templates/slides/app/pages/Index.tsx +16 -5
- package/corpus/templates/slides/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/slides/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/slides/app/routes/team.tsx +1 -1
- package/corpus/templates/slides/changelog/2026-08-05-failed-deck-creation-and-reference-uploads-now-recover-clean.md +6 -0
- package/corpus/templates/slides/changelog/2026-08-05-slides-recover-completed-generation-results-after-a-sync-hic.md +6 -0
- package/corpus/templates/slides/changelog/2026-08-05-website-url-imports-now-capture-hydrated-browser-computed-st.md +6 -0
- package/corpus/templates/tasks/app/components/layout/Header.tsx +3 -1
- package/corpus/templates/tasks/app/routes/extensions._index.tsx +1 -1
- package/corpus/templates/tasks/app/routes/settings.$.tsx +1 -0
- package/dist/agent/engine/ai-sdk-engine.js +49 -3
- package/dist/agent/production-agent.d.ts +1 -0
- package/dist/agent/production-agent.js +8 -0
- package/dist/agent/types.d.ts +7 -0
- package/dist/client/agent-chat-adapter.d.ts +1 -1
- package/dist/client/agent-chat-adapter.js +30 -3
- package/dist/client/agent-page/AgentWorkspaceContent.d.ts +1 -1
- package/dist/client/agent-page/AgentWorkspaceContent.js +13 -13
- package/dist/client/chat/run-recovery.js +5 -1
- package/dist/client/embed-auth.js +6 -2
- package/dist/client/error-format.js +12 -0
- package/dist/client/integrations/IntegrationsPanel.js +40 -6
- package/dist/client/org/OrgSwitcher.js +2 -2
- package/dist/client/org/TeamPage.js +92 -72
- package/dist/client/require-session.d.ts +1 -1
- package/dist/client/require-session.js +3 -3
- package/dist/client/resources/use-mcp-servers.d.ts +5 -0
- package/dist/client/resources/use-mcp-servers.js +36 -0
- package/dist/client/settings/AccountSettingsCard.js +40 -35
- package/dist/client/settings/AutomationsSection.js +1 -1
- package/dist/client/settings/DemoModeSection.d.ts +3 -1
- package/dist/client/settings/DemoModeSection.js +4 -1
- package/dist/client/settings/ExtensionsSettingsContent.js +1 -1
- package/dist/client/settings/SchedulingTimezoneField.d.ts +3 -1
- package/dist/client/settings/SchedulingTimezoneField.js +9 -5
- package/dist/client/settings/SettingsPanel.d.ts +4 -1
- package/dist/client/settings/SettingsPanel.js +21 -21
- package/dist/client/settings/SettingsTabsPage.d.ts +2 -2
- package/dist/client/settings/SettingsTabsPage.js +98 -45
- package/dist/client/settings/VoiceTranscriptionSection.js +6 -1
- package/dist/client/settings/useSettingsPanelController.js +47 -8
- package/dist/collab/struct-routes.d.ts +1 -1
- package/dist/file-upload/actions/upload-image.d.ts +1 -1
- package/dist/ingestion/website.d.ts +30 -0
- package/dist/localization/default-messages.d.ts +5 -0
- package/dist/localization/default-messages.js +5 -0
- package/dist/mcp-client/oauth-routes.js +1 -1
- package/dist/mcp-client/routes.d.ts +1 -0
- package/dist/mcp-client/routes.js +49 -0
- package/dist/navigation/index.js +16 -5
- package/dist/observability/routes.d.ts +5 -5
- package/dist/progress/routes.d.ts +1 -1
- package/dist/provider-api/actions/custom-provider-registration.d.ts +13 -13
- package/dist/provider-api/actions/provider-api.d.ts +11 -11
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/scripts/call-agent.js +11 -0
- package/dist/secrets/routes.d.ts +3 -3
- package/dist/server/auth.js +9 -7
- package/dist/server/identity-sso.js +2 -1
- package/dist/server/onboarding-html.js +57 -34
- package/dist/server/realtime-token.d.ts +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/server/workspace-provider-oauth.js +1 -1
- package/dist/setup-connections/onboarding.js +1 -1
- package/dist/shared/index.d.ts +1 -1
- package/dist/shared/index.js +1 -1
- package/dist/shared/sign-in-journey.d.ts +5 -2
- package/dist/shared/sign-in-journey.js +10 -4
- package/dist/templates/chat/app/components/layout/Layout.tsx +1 -1
- package/dist/templates/chat/app/hooks/use-navigation-state.ts +1 -1
- package/dist/templates/chat/app/root.tsx +1 -1
- package/dist/templates/chat/app/routes/agent.tsx +7 -7
- package/dist/templates/chat/app/routes/extensions._index.tsx +1 -1
- package/dist/templates/chat/app/routes/settings.$.tsx +1 -0
- package/dist/templates/chat/app/routes/team.tsx +1 -1
- package/dist/templates/workspace-core/.agents/skills/address-feedback/SKILL.md +37 -6
- package/dist/templates/workspace-core/.agents/skills/authentication/SKILL.md +4 -2
- package/docs/content/authentication.mdx +4 -5
- package/docs/content/template-analytics-developers.mdx +1 -1
- package/docs/content/template-calendar-developers.mdx +1 -1
- package/docs/content/template-chat-developers.mdx +2 -2
- package/docs/content/template-content-developers.mdx +1 -1
- package/docs/content/template-mail-developers.mdx +1 -1
- package/docs/content/template-plan-developers.mdx +1 -1
- package/docs/content/toolkit-command-navigation.mdx +6 -6
- package/docs/content/toolkit-org-team.mdx +1 -1
- package/docs/content/toolkit-settings.mdx +8 -8
- package/docs/content/toolkit-setup-connections.mdx +1 -1
- package/package.json +1 -1
- package/src/templates/chat/app/components/layout/Layout.tsx +1 -1
- package/src/templates/chat/app/hooks/use-navigation-state.ts +1 -1
- package/src/templates/chat/app/root.tsx +1 -1
- package/src/templates/chat/app/routes/agent.tsx +7 -7
- package/src/templates/chat/app/routes/extensions._index.tsx +1 -1
- package/src/templates/chat/app/routes/settings.$.tsx +1 -0
- package/src/templates/chat/app/routes/team.tsx +1 -1
- package/src/templates/workspace-core/.agents/skills/address-feedback/SKILL.md +37 -6
- package/src/templates/workspace-core/.agents/skills/authentication/SKILL.md +4 -2
- package/corpus/templates/analytics/.agents/skills/dashboard-management/references/template-catalog-and-demo.md +0 -62
- package/corpus/templates/analytics/actions/install-dashboard-template.ts +0 -369
- package/corpus/templates/analytics/actions/list-dashboard-templates.ts +0 -47
- package/corpus/templates/analytics/actions/list-native-v2-dashboard-templates.ts +0 -34
- package/corpus/templates/analytics/app/routes/catalog.tsx +0 -240
- package/src/templates/default/actions/navigate.spec.ts +0 -53
|
@@ -172,7 +172,7 @@ export function Layout({ children }: LayoutProps) {
|
|
|
172
172
|
openOnChatRunning={chatHomeHandoffActive}
|
|
173
173
|
onFullscreenRequest={openAskAgentFullscreen}
|
|
174
174
|
emptyStateText={t("chat.inspectEmptyState")}
|
|
175
|
-
agentPageHref="/settings
|
|
175
|
+
agentPageHref="/settings/agent"
|
|
176
176
|
suggestions={[
|
|
177
177
|
t("chat.inspectSuggestionCapabilities"),
|
|
178
178
|
t("chat.inspectSuggestionHello"),
|
|
@@ -21,20 +21,20 @@ export default function AgentRoute() {
|
|
|
21
21
|
"learnings",
|
|
22
22
|
]);
|
|
23
23
|
const destination = resourceTabs.has(legacyTab)
|
|
24
|
-
? `/settings
|
|
24
|
+
? `/settings/agent/resources/${legacyTab}`
|
|
25
25
|
: legacyTab === "remote-agents"
|
|
26
|
-
? "/settings
|
|
26
|
+
? "/settings/agent/agents"
|
|
27
27
|
: legacyTab === "connections"
|
|
28
|
-
? "/settings
|
|
28
|
+
? "/settings/integrations"
|
|
29
29
|
: legacyTab === "jobs"
|
|
30
|
-
? "/settings
|
|
30
|
+
? "/settings/agent/automations"
|
|
31
31
|
: legacyTab === "access"
|
|
32
|
-
? "/settings
|
|
32
|
+
? "/settings/agent"
|
|
33
33
|
: ["llm", "app-models", "limits", "voice", "background"].includes(
|
|
34
34
|
legacyTab,
|
|
35
35
|
)
|
|
36
|
-
? `/settings
|
|
37
|
-
: "/settings
|
|
36
|
+
? `/settings/agent/${legacyTab}`
|
|
37
|
+
: "/settings/agent";
|
|
38
38
|
|
|
39
39
|
return <Navigate to={destination} replace />;
|
|
40
40
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -700,7 +700,7 @@ export function LibraryLayout({ children }: LibraryLayoutProps) {
|
|
|
700
700
|
</div>
|
|
701
701
|
|
|
702
702
|
<div className="shrink-0 space-y-2 px-3 py-2">
|
|
703
|
-
<OrgSwitcher settingsPath="/settings
|
|
703
|
+
<OrgSwitcher settingsPath="/settings/organization" />
|
|
704
704
|
<DevDatabaseLink />
|
|
705
705
|
</div>
|
|
706
706
|
</>
|
|
@@ -463,7 +463,7 @@ function BuilderCreditsPausedNotice({
|
|
|
463
463
|
size="sm"
|
|
464
464
|
className="h-8 text-amber-900 hover:bg-amber-100 hover:text-amber-950 dark:text-amber-100 dark:hover:bg-amber-900/40"
|
|
465
465
|
>
|
|
466
|
-
<a href={appPath("/settings#ai-providers")}>
|
|
466
|
+
<a href={appPath("/settings/general#ai-providers")}>
|
|
467
467
|
{t("builderCredits.openAiSetup")}
|
|
468
468
|
</a>
|
|
469
469
|
</Button>
|
|
@@ -190,7 +190,7 @@ export function StorageSetupCard({
|
|
|
190
190
|
<span className="text-sm text-muted-foreground">
|
|
191
191
|
Or{" "}
|
|
192
192
|
<a
|
|
193
|
-
href={appPath("/settings#video-storage")}
|
|
193
|
+
href={appPath("/settings/general#video-storage")}
|
|
194
194
|
className="font-medium text-foreground underline underline-offset-2 hover:text-foreground/80"
|
|
195
195
|
>
|
|
196
196
|
{t("storageSetup.configureS3")}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./_app.settings._index.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./_app.settings.js";
|
|
@@ -28,7 +28,7 @@ async function globalSetup(_config: FullConfig) {
|
|
|
28
28
|
const page = await ctx.newPage();
|
|
29
29
|
let result: Record<string, unknown> = {};
|
|
30
30
|
try {
|
|
31
|
-
await page.goto(`${baseURL}/
|
|
31
|
+
await page.goto(`${baseURL}/sign-in`, {
|
|
32
32
|
waitUntil: "domcontentloaded",
|
|
33
33
|
});
|
|
34
34
|
result = await page.evaluate(
|
|
@@ -191,7 +191,12 @@ The design system setup page collects brand assets from multiple sources. When t
|
|
|
191
191
|
pnpm action import-from-url --url "https://acme.com"
|
|
192
192
|
```
|
|
193
193
|
|
|
194
|
-
|
|
194
|
+
Renders the live page in a real browser first, then returns a bounded
|
|
195
|
+
design.md-style visual system: computed semantic colors, typography, spacing,
|
|
196
|
+
radii, shadows, representative component styles, CSS variables, logo
|
|
197
|
+
references, screenshots evidence metadata, and reusable Brand Kit data. This
|
|
198
|
+
works for React/CSS-in-JS/Tailwind pages because it reads the computed cascade;
|
|
199
|
+
it reports an explicit static SSRF-safe fallback when no browser is available.
|
|
195
200
|
|
|
196
201
|
### Source: GitHub Repository
|
|
197
202
|
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { defineAction } from "@agent-native/core";
|
|
2
|
-
import {
|
|
3
|
-
normalizeBrandWebsiteUrl,
|
|
4
|
-
fetchBrandWebsiteSignals,
|
|
5
|
-
} from "@agent-native/core/brand-kit";
|
|
2
|
+
import { normalizeBrandWebsiteUrl } from "@agent-native/core/brand-kit";
|
|
6
3
|
import { resolveAccess } from "@agent-native/core/sharing";
|
|
4
|
+
import { extractRenderedDesignSystemFromUrl } from "@agent-native/creative-context/server";
|
|
7
5
|
import { z } from "zod";
|
|
8
6
|
|
|
9
7
|
import "../server/db/index.js"; // ensure registerShareableResource runs
|
|
@@ -14,8 +12,9 @@ export { normalizeBrandWebsiteUrl };
|
|
|
14
12
|
export default defineAction({
|
|
15
13
|
description:
|
|
16
14
|
"Gather brand data from various sources for agent analysis. " +
|
|
17
|
-
"If a websiteUrl is provided,
|
|
18
|
-
"
|
|
15
|
+
"If a websiteUrl is provided, renders the page in a real browser and extracts " +
|
|
16
|
+
"computed colors, typography, spacing, radii, shadows, component styles, " +
|
|
17
|
+
"CSS custom properties, logo references, and a design.md-style summary. " +
|
|
19
18
|
"If a designSystemId is provided, includes its existing data. " +
|
|
20
19
|
"Returns structured data the agent can use to build or refine a design system.",
|
|
21
20
|
schema: z.object({
|
|
@@ -61,7 +60,8 @@ export default defineAction({
|
|
|
61
60
|
|
|
62
61
|
// Fetch and analyze website if URL provided
|
|
63
62
|
if (websiteUrl) {
|
|
64
|
-
result.websiteAnalysis =
|
|
63
|
+
result.websiteAnalysis =
|
|
64
|
+
await extractRenderedDesignSystemFromUrl(websiteUrl);
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
return result;
|
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
import { defineAction } from "@agent-native/core";
|
|
2
|
-
import {
|
|
2
|
+
import { extractRenderedDesignSystemFromUrl } from "@agent-native/creative-context/server";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
|
|
5
5
|
export default defineAction({
|
|
6
6
|
description:
|
|
7
|
-
"Analyze a website URL
|
|
8
|
-
"
|
|
9
|
-
"
|
|
7
|
+
"Analyze a website URL with an SSRF-safe bounded extractor and return a design.md-style " +
|
|
8
|
+
"visual system: computed colors, typography, spacing, radii, shadows, " +
|
|
9
|
+
"component styles, CSS variables, logo references, and reusable Brand Kit data. " +
|
|
10
|
+
"Uses static SSRF-safe extraction until Chromium navigation has a connect-time SSRF guard.",
|
|
10
11
|
schema: z.object({
|
|
11
12
|
url: z.string().describe("Website URL to analyze"),
|
|
12
13
|
}),
|
|
13
14
|
readOnly: true,
|
|
14
15
|
http: { method: "GET" },
|
|
15
16
|
run: async ({ url }) => {
|
|
16
|
-
return
|
|
17
|
+
return extractRenderedDesignSystemFromUrl(url);
|
|
17
18
|
},
|
|
18
19
|
});
|
|
@@ -444,7 +444,7 @@ export default function DesignSystemSetup() {
|
|
|
444
444
|
|
|
445
445
|
if (normalizedWebsiteUrls.length > 0) {
|
|
446
446
|
parts.push(
|
|
447
|
-
`\n## Website URLs\nExtract design tokens from these websites:\n${normalizedWebsiteUrls.map((u) => `- ${u}`).join("\n")}\n\
|
|
447
|
+
`\n## Website URLs\nExtract design tokens from these websites:\n${normalizedWebsiteUrls.map((u) => `- ${u}`).join("\n")}\n\nCall \`import-from-url\` for each URL. It uses the shared layered renderer: Builder Browser when available, then local Playwright or an approved attached browser, with an explicit SSRF-safe static fallback. The result includes hydrated computed styles (including React, CSS-in-JS, Tailwind, SPA content, and loaded fonts), desktop/mobile screenshot evidence, and a bounded design.md-style summary. Use that result as the source of truth; do not replace it with a plain HTML fetch.`,
|
|
448
448
|
);
|
|
449
449
|
}
|
|
450
450
|
|
|
@@ -903,7 +903,7 @@ export default function DesignSystemSetup() {
|
|
|
903
903
|
<p className="mt-2 text-xs text-muted-foreground/80">
|
|
904
904
|
{t("designSystemSetup.privateRepoPrefix")}{" "}
|
|
905
905
|
<a
|
|
906
|
-
href="/settings#secrets:GITHUB_TOKEN"
|
|
906
|
+
href="/settings/integrations#secrets:GITHUB_TOKEN"
|
|
907
907
|
className="font-medium text-foreground/80 underline-offset-2 hover:underline"
|
|
908
908
|
>
|
|
909
909
|
GITHUB_TOKEN
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -176,7 +176,7 @@ export default async function globalSetup(config: FullConfig) {
|
|
|
176
176
|
const page = await context.newPage();
|
|
177
177
|
|
|
178
178
|
try {
|
|
179
|
-
await page.goto(`${baseURL}/
|
|
179
|
+
await page.goto(`${baseURL}/sign-in`, {
|
|
180
180
|
waitUntil: "domcontentloaded",
|
|
181
181
|
});
|
|
182
182
|
|
|
@@ -231,7 +231,7 @@ function resolvePath(
|
|
|
231
231
|
case "threads":
|
|
232
232
|
return "/thread-debug";
|
|
233
233
|
case "team":
|
|
234
|
-
return "/settings
|
|
234
|
+
return "/settings/organization";
|
|
235
235
|
case "extensions":
|
|
236
236
|
return command?.extensionId
|
|
237
237
|
? `/extensions/${encodeURIComponent(command.extensionId)}`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./_app.settings.js";
|
|
@@ -73,7 +73,7 @@ export function formsRoutePath(target: FormsNavigationTarget): string | null {
|
|
|
73
73
|
? `/response-insights?formId=${encodeURIComponent(formId)}`
|
|
74
74
|
: "/response-insights";
|
|
75
75
|
case "team":
|
|
76
|
-
return "/settings
|
|
76
|
+
return "/settings/organization";
|
|
77
77
|
case "extensions":
|
|
78
78
|
return "/extensions";
|
|
79
79
|
case "form-preview":
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default, meta } from "./settings.js";
|
|
@@ -19,7 +19,9 @@ Design systems are stored in the `design_systems` SQL table. Each has a `data` c
|
|
|
19
19
|
## Creating a Design System
|
|
20
20
|
|
|
21
21
|
1. User provides brand context (company name, website, assets, notes)
|
|
22
|
-
2. `analyze-brand-assets`
|
|
22
|
+
2. `analyze-brand-assets` renders a website in a real browser and gathers the
|
|
23
|
+
computed visual system (colors, fonts, spacing, radii, shadows, components,
|
|
24
|
+
CSS variables, logos, and design.md-style guidance)
|
|
23
25
|
3. Agent analyzes the data and calls `create-design-system` with extracted tokens
|
|
24
26
|
4. The design system is published and becomes available for deck creation
|
|
25
27
|
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { defineAction } from "@agent-native/core";
|
|
2
|
-
import {
|
|
3
|
-
normalizeBrandWebsiteUrl,
|
|
4
|
-
fetchBrandWebsiteSignals,
|
|
5
|
-
} from "@agent-native/core/brand-kit";
|
|
2
|
+
import { normalizeBrandWebsiteUrl } from "@agent-native/core/brand-kit";
|
|
6
3
|
import { resolveAccess } from "@agent-native/core/sharing";
|
|
4
|
+
import { extractRenderedDesignSystemFromUrl } from "@agent-native/creative-context/server";
|
|
7
5
|
import { z } from "zod";
|
|
8
6
|
|
|
9
7
|
import "../server/db/index.js"; // ensure registerShareableResource runs
|
|
@@ -14,8 +12,9 @@ export { normalizeBrandWebsiteUrl };
|
|
|
14
12
|
export default defineAction({
|
|
15
13
|
description:
|
|
16
14
|
"Gather brand data from various sources for agent analysis. " +
|
|
17
|
-
"If a websiteUrl is provided,
|
|
18
|
-
"
|
|
15
|
+
"If a websiteUrl is provided, renders the page in a real browser and extracts " +
|
|
16
|
+
"computed colors, typography, spacing, radii, shadows, component styles, " +
|
|
17
|
+
"CSS custom properties, logo references, and a design.md-style summary. " +
|
|
19
18
|
"If a designSystemId is provided, includes its existing data. " +
|
|
20
19
|
"Returns structured data the agent can use to build or refine a design system.",
|
|
21
20
|
schema: z.object({
|
|
@@ -61,7 +60,8 @@ export default defineAction({
|
|
|
61
60
|
|
|
62
61
|
// Fetch and analyze website if URL provided
|
|
63
62
|
if (websiteUrl) {
|
|
64
|
-
result.websiteAnalysis =
|
|
63
|
+
result.websiteAnalysis =
|
|
64
|
+
await extractRenderedDesignSystemFromUrl(websiteUrl);
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
return result;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { defineAction } from "@agent-native/core";
|
|
2
|
-
import {
|
|
2
|
+
import { extractRenderedDesignSystemFromUrl } from "@agent-native/creative-context/server";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
|
|
5
5
|
export default defineAction({
|
|
6
6
|
description:
|
|
7
|
-
"Analyze a website URL
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
7
|
+
"Analyze a website URL in a real browser and return a bounded design.md-style " +
|
|
8
|
+
"visual system: computed colors, typography, spacing, radii, shadows, " +
|
|
9
|
+
"component styles, CSS variables, logo references, and reusable Brand Kit data. " +
|
|
10
|
+
"Uses a static SSRF-safe fallback only when a browser is unavailable.",
|
|
11
11
|
schema: z.object({
|
|
12
12
|
url: z.string().describe("Website URL to analyze"),
|
|
13
13
|
}),
|
|
14
14
|
readOnly: true,
|
|
15
15
|
http: { method: "GET" },
|
|
16
16
|
run: async ({ url }) => {
|
|
17
|
-
return
|
|
17
|
+
return extractRenderedDesignSystemFromUrl(url);
|
|
18
18
|
},
|
|
19
19
|
});
|
|
@@ -479,7 +479,7 @@ export function DesignSystemSetup({
|
|
|
479
479
|
|
|
480
480
|
if (websiteUrls.length > 0) {
|
|
481
481
|
parts.push(
|
|
482
|
-
`\n## Website URLs\nAnalyze these websites for design tokens. Call \`import-from-url\` for each:\n${websiteUrls.map((u) => `- ${u}`).join("\n")}
|
|
482
|
+
`\n## Website URLs\nAnalyze these websites for design tokens. Call \`import-from-url\` for each:\n${websiteUrls.map((u) => `- ${u}`).join("\n")}\n\nThe shared action uses the layered real-browser renderer so hydrated React, CSS-in-JS, Tailwind, SPA content, loaded fonts, computed colors, component styles, CSS variables, and desktop/mobile screenshot evidence are captured consistently. It falls back explicitly to SSRF-safe static extraction only when a browser is unavailable. Use its design.md-style result as the source of truth for the deck style.`,
|
|
483
483
|
);
|
|
484
484
|
}
|
|
485
485
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { appBasePath } from "@agent-native/core/client/api-path";
|
|
2
2
|
import { PromptComposer } from "@agent-native/core/client/composer";
|
|
3
|
+
import { ensureEmbedAuthFetchInterceptor } from "@agent-native/core/client/host";
|
|
3
4
|
import { useT } from "@agent-native/core/client/i18n";
|
|
4
5
|
import { useState, useEffect, useCallback, useRef } from "react";
|
|
5
6
|
import { createPortal } from "react-dom";
|
|
@@ -22,9 +23,11 @@ export async function uploadPromptFiles(
|
|
|
22
23
|
if (files.length === 0) return [];
|
|
23
24
|
const formData = new FormData();
|
|
24
25
|
files.forEach((file) => formData.append("files", file));
|
|
26
|
+
ensureEmbedAuthFetchInterceptor();
|
|
25
27
|
const response = await fetch(`${appBasePath()}/api/uploads`, {
|
|
26
28
|
method: "POST",
|
|
27
29
|
body: formData,
|
|
30
|
+
credentials: "include",
|
|
28
31
|
});
|
|
29
32
|
if (!response.ok) {
|
|
30
33
|
let message = "Upload failed";
|
|
@@ -15,7 +15,10 @@ import {
|
|
|
15
15
|
uploadPromptFiles,
|
|
16
16
|
type UploadedFile,
|
|
17
17
|
} from "@/components/editor/PromptDialog";
|
|
18
|
-
import {
|
|
18
|
+
import {
|
|
19
|
+
describeDeckPersistenceFailure,
|
|
20
|
+
useDecks,
|
|
21
|
+
} from "@/context/DeckContext";
|
|
19
22
|
import { useAgentGenerating } from "@/hooks/use-agent-generating";
|
|
20
23
|
import { useDesignSystems } from "@/hooks/use-design-systems";
|
|
21
24
|
import { useWorkspaceDefaults } from "@/hooks/use-workspace-defaults";
|
|
@@ -141,12 +144,15 @@ export function FirstDeckOnboardingFlow({
|
|
|
141
144
|
onUnauthenticated: () => {
|
|
142
145
|
toast.error(t("home.signInTitle"));
|
|
143
146
|
},
|
|
144
|
-
onPersistenceFailure: (failedPrompt) => {
|
|
147
|
+
onPersistenceFailure: (failedPrompt, _failedFiles, failure) => {
|
|
145
148
|
setPromptInitialText(failedPrompt);
|
|
146
149
|
setPromptInitialTextKey(Date.now());
|
|
147
150
|
setStep("prompt");
|
|
148
151
|
toast.error(t("home.generationStartFailed"), {
|
|
149
|
-
description:
|
|
152
|
+
description: describeDeckPersistenceFailure(
|
|
153
|
+
failure,
|
|
154
|
+
t("home.generationStartFailedDescription"),
|
|
155
|
+
),
|
|
150
156
|
});
|
|
151
157
|
},
|
|
152
158
|
});
|