@agent-native/core 0.124.2 → 0.124.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/corpus/README.md +2 -2
- package/corpus/core/CHANGELOG.md +16 -0
- package/corpus/core/docs/content/cloneable-saas.mdx +9 -9
- package/corpus/core/docs/content/creating-templates.mdx +2 -2
- package/corpus/core/docs/content/deployment.mdx +23 -0
- package/corpus/core/docs/content/faq.mdx +4 -4
- package/corpus/core/docs/content/key-concepts.mdx +1 -1
- package/corpus/core/docs/content/multi-app-workspace.mdx +1 -1
- package/corpus/core/docs/content/syncing-template-changes.mdx +1 -1
- package/corpus/core/docs/content/template-analytics-developers.mdx +2 -2
- package/corpus/core/docs/content/template-analytics.mdx +2 -2
- package/corpus/core/docs/content/template-assets-developers.mdx +3 -3
- package/corpus/core/docs/content/template-assets.mdx +2 -2
- package/corpus/core/docs/content/template-brain-developers.mdx +2 -2
- package/corpus/core/docs/content/template-brain.mdx +1 -1
- package/corpus/core/docs/content/template-calendar-developers.mdx +1 -1
- package/corpus/core/docs/content/template-calendar.mdx +1 -1
- package/corpus/core/docs/content/template-chat.mdx +1 -1
- package/corpus/core/docs/content/template-clips-developers.mdx +4 -4
- package/corpus/core/docs/content/template-clips.mdx +2 -2
- package/corpus/core/docs/content/template-content-developers.mdx +2 -2
- package/corpus/core/docs/content/template-content.mdx +1 -1
- package/corpus/core/docs/content/template-design-brand-and-figma.mdx +1 -1
- package/corpus/core/docs/content/template-design-developers.mdx +2 -2
- package/corpus/core/docs/content/template-design.mdx +2 -2
- package/corpus/core/docs/content/template-dispatch-developers.mdx +5 -5
- package/corpus/core/docs/content/template-forms-developers.mdx +1 -1
- package/corpus/core/docs/content/template-forms.mdx +1 -1
- package/corpus/core/docs/content/template-mail-developers.mdx +2 -2
- package/corpus/core/docs/content/template-mail.mdx +2 -2
- package/corpus/core/docs/content/template-plan-developers.mdx +3 -3
- package/corpus/core/docs/content/template-plan.mdx +3 -3
- package/corpus/core/docs/content/template-slides-developers.mdx +4 -4
- package/corpus/core/docs/content/template-slides.mdx +1 -1
- package/corpus/core/docs/content/what-is-agent-native.mdx +5 -5
- package/corpus/core/package.json +1 -1
- package/corpus/core/src/a2a/auth-policy.ts +1 -1
- package/corpus/core/src/agent/production-agent.ts +14 -1
- package/corpus/core/src/agent/run-manager.ts +6 -13
- package/corpus/core/src/cli/index.ts +11 -1
- package/corpus/core/src/client/route-chunk-recovery.ts +18 -7
- package/corpus/core/src/db/client.ts +7 -6
- package/corpus/core/src/db/migrations.ts +2 -1
- package/corpus/core/src/deploy/build.ts +290 -4
- package/corpus/core/src/deploy/nitro-preset.ts +50 -0
- package/corpus/core/src/integrations/pending-tasks-retry-job.ts +2 -1
- package/corpus/core/src/scripts/call-agent.ts +4 -2
- package/corpus/core/src/server/agent-discovery.ts +1 -0
- package/corpus/core/src/server/agent-run-context.ts +13 -3
- package/corpus/core/src/server/request-context.ts +2 -0
- package/corpus/core/src/shared/cloudflare-globals.d.ts +2 -1
- package/corpus/core/src/shared/runtime.ts +2 -0
- package/corpus/core/src/shared/streaming-text-smoothing.ts +15 -14
- package/corpus/core/src/templates/default/.agents/skills/secrets/SKILL.md +29 -0
- package/corpus/core/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/en-US.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/zh-CN.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/zh-TW.ts +6 -6
- package/corpus/core/src/templates/headless/.agents/skills/secrets/SKILL.md +29 -0
- package/corpus/core/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +29 -0
- package/corpus/core/src/vite/client.ts +20 -1
- package/corpus/templates/analytics/actions/restore-dashboard-revision.ts +9 -2
- package/corpus/templates/analytics/app/components/dashboard/DashboardHistoryPanel.tsx +3 -0
- package/corpus/templates/analytics/app/components/dashboard/DashboardPanelSkeleton.tsx +1 -1
- package/corpus/templates/analytics/app/global.css +10 -9
- package/corpus/templates/analytics/app/hooks/use-chart-tooltip-portal.ts +59 -18
- package/corpus/templates/analytics/app/hooks/use-dashboard-revisions.ts +14 -2
- package/corpus/templates/analytics/app/i18n-data.ts +102 -0
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/index.tsx +232 -2
- package/corpus/templates/analytics/changelog/2026-07-27-chart-tooltips-stay-beside-the-cursor-when-they-extend-beyon.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-27-chat-no-longer-claims-a-data-source-is-disconnected-when-it-.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-27-dashboard-changes-can-be-undone-with-cmd-z-and-actions-menu.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-27-dashboard-redo-with-cmd-shift-z-and-actions-menu.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-27-dashboard-skeletons-are-subtler-and-smoother.md +6 -0
- package/corpus/templates/analytics/server/lib/dashboards-store.ts +61 -20
- package/corpus/templates/analytics/server/lib/real-data-actions.ts +1 -0
- package/corpus/templates/analytics/server/plugins/agent-chat.ts +7 -3
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +7 -32
- package/corpus/templates/calendar/changelog/2026-07-27-calendar-s-sidebar-now-uses-a-cleaner-layout-with-fewer-util.md +6 -0
- package/corpus/templates/content/app/components/editor/database/sidebar.tsx +14 -6
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +32 -37
- package/corpus/templates/content/changelog/2026-07-27-content-sidebar-page-lists-now-load-with-quiet-skeletons-and.md +6 -0
- package/corpus/templates/design/.agents/skills/design-generation/SKILL.md +34 -11
- package/corpus/templates/design/.agents/skills/responsive-breakpoints/SKILL.md +8 -0
- package/corpus/templates/design/actions/generate-design.ts +259 -36
- package/corpus/templates/design/actions/generate-screens.ts +51 -14
- package/corpus/templates/design/actions/present-design-variants.ts +6 -3
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +8 -0
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +158 -9
- package/corpus/templates/design/app/components/design/design-canvas/content-size-report.ts +124 -0
- package/corpus/templates/design/app/components/design/multi-screen/frame-geometry.ts +61 -9
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +16 -18
- package/corpus/templates/design/changelog/2026-07-24-ai-designs-now-default-to-a-full-size-desktop-mobile-pair-fr.md +6 -0
- package/corpus/templates/design/changelog/2026-07-24-design-frames-now-fill-the-viewport-height-and-grow-to-fit-t.md +6 -0
- package/corpus/templates/design/changelog/2026-07-24-generating-an-additional-screen-now-places-it-beside-the-exi.md +6 -0
- package/corpus/templates/design/changelog/2026-07-27-collapsed-sidebar-keeps-the-agent-native-logo.md +6 -0
- package/corpus/templates/dispatch/AGENTS.md +7 -2
- package/corpus/templates/dispatch/actions/view-screen.ts +3 -2
- package/corpus/templates/dispatch/changelog/2026-07-17-curated-template-remixes.md +1 -1
- package/corpus/templates/dispatch/changelog/2026-07-27-creating-an-app-from-a-curated-template-now-uses-clearer-mor.md +6 -0
- package/corpus/templates/dispatch/changelog/2026-07-27-thread-debug-accepts-request-run-ids.md +6 -0
- package/corpus/templates/slides/actions/create-design-system.ts +10 -2
- package/corpus/templates/slides/actions/import-file.ts +173 -1
- package/corpus/templates/slides/actions/list-slide-comments.ts +16 -1
- package/corpus/templates/slides/actions/update-design-system.ts +13 -2
- package/corpus/templates/slides/app/components/editor/AssetLibraryPanel.tsx +35 -12
- package/corpus/templates/slides/app/components/editor/EditorToolbar.tsx +36 -0
- package/corpus/templates/slides/app/i18n/en-US.ts +3 -0
- package/corpus/templates/slides/app/lib/dynamic-import.ts +63 -0
- package/corpus/templates/slides/app/lib/export-pdf-client.ts +3 -2
- package/corpus/templates/slides/app/lib/export-pptx-client.ts +5 -2
- package/corpus/templates/slides/app/pages/DesignSystems.tsx +9 -1
- package/corpus/templates/slides/server/db/schema.ts +11 -0
- package/corpus/templates/slides/server/handlers/assets.ts +64 -19
- package/corpus/templates/slides/server/handlers/import/html-converter.ts +38 -0
- package/corpus/templates/slides/server/plugins/db.ts +20 -0
- package/corpus/templates/slides/shared/design-system-validation.ts +62 -0
- package/dist/a2a/auth-policy.js +1 -1
- package/dist/a2a/auth-policy.js.map +1 -1
- package/dist/agent/production-agent.d.ts +1 -0
- package/dist/agent/production-agent.d.ts.map +1 -1
- package/dist/agent/production-agent.js +12 -1
- package/dist/agent/production-agent.js.map +1 -1
- package/dist/agent/run-manager.d.ts +2 -0
- package/dist/agent/run-manager.d.ts.map +1 -1
- package/dist/agent/run-manager.js +4 -10
- package/dist/agent/run-manager.js.map +1 -1
- package/dist/cli/index.js +8 -1
- package/dist/cli/index.js.map +1 -1
- package/dist/client/route-chunk-recovery.d.ts.map +1 -1
- package/dist/client/route-chunk-recovery.js +16 -7
- package/dist/client/route-chunk-recovery.js.map +1 -1
- package/dist/db/client.d.ts.map +1 -1
- package/dist/db/client.js +4 -2
- package/dist/db/client.js.map +1 -1
- package/dist/db/migrations.d.ts.map +1 -1
- package/dist/db/migrations.js +2 -1
- package/dist/db/migrations.js.map +1 -1
- package/dist/deploy/build.d.ts +25 -0
- package/dist/deploy/build.d.ts.map +1 -1
- package/dist/deploy/build.js +227 -4
- package/dist/deploy/build.js.map +1 -1
- package/dist/deploy/nitro-preset.d.ts +8 -0
- package/dist/deploy/nitro-preset.d.ts.map +1 -0
- package/dist/deploy/nitro-preset.js +36 -0
- package/dist/deploy/nitro-preset.js.map +1 -0
- package/dist/integrations/pending-tasks-retry-job.d.ts.map +1 -1
- package/dist/integrations/pending-tasks-retry-job.js +2 -1
- package/dist/integrations/pending-tasks-retry-job.js.map +1 -1
- 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/provider-api/actions/custom-provider-registration.d.ts +11 -11
- package/dist/provider-api/actions/provider-api.d.ts +11 -11
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/scripts/call-agent.d.ts.map +1 -1
- package/dist/scripts/call-agent.js +4 -2
- package/dist/scripts/call-agent.js.map +1 -1
- package/dist/server/agent-discovery.d.ts.map +1 -1
- package/dist/server/agent-discovery.js +1 -0
- package/dist/server/agent-discovery.js.map +1 -1
- package/dist/server/agent-run-context.d.ts.map +1 -1
- package/dist/server/agent-run-context.js +10 -3
- package/dist/server/agent-run-context.js.map +1 -1
- package/dist/server/request-context.d.ts +2 -0
- package/dist/server/request-context.d.ts.map +1 -1
- package/dist/server/request-context.js.map +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/shared/runtime.d.ts.map +1 -1
- package/dist/shared/runtime.js +2 -0
- package/dist/shared/runtime.js.map +1 -1
- package/dist/shared/streaming-text-smoothing.d.ts.map +1 -1
- package/dist/shared/streaming-text-smoothing.js +15 -8
- package/dist/shared/streaming-text-smoothing.js.map +1 -1
- package/dist/templates/default/.agents/skills/secrets/SKILL.md +29 -0
- package/dist/templates/default/app/i18n/ar-SA.ts +6 -6
- package/dist/templates/default/app/i18n/de-DE.ts +6 -6
- package/dist/templates/default/app/i18n/en-US.ts +6 -6
- package/dist/templates/default/app/i18n/es-ES.ts +6 -6
- package/dist/templates/default/app/i18n/fr-FR.ts +6 -6
- package/dist/templates/default/app/i18n/hi-IN.ts +6 -6
- package/dist/templates/default/app/i18n/ja-JP.ts +6 -6
- package/dist/templates/default/app/i18n/ko-KR.ts +6 -6
- package/dist/templates/default/app/i18n/pt-BR.ts +6 -6
- package/dist/templates/default/app/i18n/zh-CN.ts +6 -6
- package/dist/templates/default/app/i18n/zh-TW.ts +6 -6
- package/dist/templates/headless/.agents/skills/secrets/SKILL.md +29 -0
- package/dist/templates/workspace-core/.agents/skills/secrets/SKILL.md +29 -0
- package/dist/vite/client.d.ts +1 -1
- package/dist/vite/client.d.ts.map +1 -1
- package/dist/vite/client.js +16 -0
- package/dist/vite/client.js.map +1 -1
- package/docs/content/cloneable-saas.mdx +9 -9
- package/docs/content/creating-templates.mdx +2 -2
- package/docs/content/deployment.mdx +23 -0
- package/docs/content/faq.mdx +4 -4
- package/docs/content/key-concepts.mdx +1 -1
- package/docs/content/multi-app-workspace.mdx +1 -1
- package/docs/content/syncing-template-changes.mdx +1 -1
- package/docs/content/template-analytics-developers.mdx +2 -2
- package/docs/content/template-analytics.mdx +2 -2
- package/docs/content/template-assets-developers.mdx +3 -3
- package/docs/content/template-assets.mdx +2 -2
- package/docs/content/template-brain-developers.mdx +2 -2
- package/docs/content/template-brain.mdx +1 -1
- package/docs/content/template-calendar-developers.mdx +1 -1
- package/docs/content/template-calendar.mdx +1 -1
- package/docs/content/template-chat.mdx +1 -1
- package/docs/content/template-clips-developers.mdx +4 -4
- package/docs/content/template-clips.mdx +2 -2
- package/docs/content/template-content-developers.mdx +2 -2
- package/docs/content/template-content.mdx +1 -1
- package/docs/content/template-design-brand-and-figma.mdx +1 -1
- package/docs/content/template-design-developers.mdx +2 -2
- package/docs/content/template-design.mdx +2 -2
- package/docs/content/template-dispatch-developers.mdx +5 -5
- package/docs/content/template-forms-developers.mdx +1 -1
- package/docs/content/template-forms.mdx +1 -1
- package/docs/content/template-mail-developers.mdx +2 -2
- package/docs/content/template-mail.mdx +2 -2
- package/docs/content/template-plan-developers.mdx +3 -3
- package/docs/content/template-plan.mdx +3 -3
- package/docs/content/template-slides-developers.mdx +4 -4
- package/docs/content/template-slides.mdx +1 -1
- package/docs/content/what-is-agent-native.mdx +5 -5
- package/package.json +1 -1
- package/src/a2a/auth-policy.ts +1 -1
- package/src/agent/production-agent.ts +14 -1
- package/src/agent/run-manager.ts +6 -13
- package/src/cli/index.ts +11 -1
- package/src/client/route-chunk-recovery.ts +18 -7
- package/src/db/client.ts +7 -6
- package/src/db/migrations.ts +2 -1
- package/src/deploy/build.ts +290 -4
- package/src/deploy/nitro-preset.ts +50 -0
- package/src/integrations/pending-tasks-retry-job.ts +2 -1
- package/src/scripts/call-agent.ts +4 -2
- package/src/server/agent-discovery.ts +1 -0
- package/src/server/agent-run-context.ts +13 -3
- package/src/server/request-context.ts +2 -0
- package/src/shared/cloudflare-globals.d.ts +2 -1
- package/src/shared/runtime.ts +2 -0
- package/src/shared/streaming-text-smoothing.ts +15 -14
- package/src/templates/default/.agents/skills/secrets/SKILL.md +29 -0
- package/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/src/templates/default/app/i18n/en-US.ts +6 -6
- package/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/src/templates/default/app/i18n/zh-CN.ts +6 -6
- package/src/templates/default/app/i18n/zh-TW.ts +6 -6
- package/src/templates/headless/.agents/skills/secrets/SKILL.md +29 -0
- package/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +29 -0
- package/src/vite/client.ts +20 -1
- /package/corpus/templates/slides/server/routes/api/assets/{[filename].delete.ts → [id].delete.ts} +0 -0
|
@@ -12,7 +12,6 @@ import {
|
|
|
12
12
|
IconDatabase,
|
|
13
13
|
IconDots,
|
|
14
14
|
IconFileText,
|
|
15
|
-
IconLoader2,
|
|
16
15
|
IconPlus,
|
|
17
16
|
IconStar,
|
|
18
17
|
IconTrash,
|
|
@@ -44,6 +43,7 @@ import {
|
|
|
44
43
|
DropdownMenuTrigger,
|
|
45
44
|
} from "@/components/ui/dropdown-menu";
|
|
46
45
|
import { ScrollArea } from "@/components/ui/scroll-area";
|
|
46
|
+
import { Skeleton } from "@/components/ui/skeleton";
|
|
47
47
|
import {
|
|
48
48
|
Tooltip,
|
|
49
49
|
TooltipContent,
|
|
@@ -261,7 +261,6 @@ export function DatabaseSidebarView({
|
|
|
261
261
|
hierarchyItems,
|
|
262
262
|
hierarchyUniverseItems,
|
|
263
263
|
scroll = true,
|
|
264
|
-
loadingLabel,
|
|
265
264
|
noMatchesLabel,
|
|
266
265
|
clearLabel,
|
|
267
266
|
navigationLabel,
|
|
@@ -286,7 +285,6 @@ export function DatabaseSidebarView({
|
|
|
286
285
|
hierarchyItems?: ContentDatabaseItem[];
|
|
287
286
|
hierarchyUniverseItems?: ContentDatabaseItem[];
|
|
288
287
|
scroll?: boolean;
|
|
289
|
-
loadingLabel: string;
|
|
290
288
|
noMatchesLabel: string;
|
|
291
289
|
clearLabel: string;
|
|
292
290
|
navigationLabel: string;
|
|
@@ -367,9 +365,19 @@ export function DatabaseSidebarView({
|
|
|
367
365
|
|
|
368
366
|
if (isLoading) {
|
|
369
367
|
return (
|
|
370
|
-
<div className="
|
|
371
|
-
|
|
372
|
-
|
|
368
|
+
<div aria-hidden="true" className="grid gap-1 p-1">
|
|
369
|
+
{[70, 55, 85, 60, 45].map((width, index) => (
|
|
370
|
+
<div
|
|
371
|
+
key={`sidebar-skeleton-${index}`}
|
|
372
|
+
className="flex h-7 items-center gap-1.5 rounded px-1.5"
|
|
373
|
+
>
|
|
374
|
+
<Skeleton className="size-3.5 shrink-0 rounded-sm bg-sidebar-foreground/12 dark:bg-sidebar-foreground/10" />
|
|
375
|
+
<Skeleton
|
|
376
|
+
className="h-3 rounded bg-sidebar-foreground/12 dark:bg-sidebar-foreground/10"
|
|
377
|
+
style={{ width: `${width}%` }}
|
|
378
|
+
/>
|
|
379
|
+
</div>
|
|
380
|
+
))}
|
|
373
381
|
</div>
|
|
374
382
|
);
|
|
375
383
|
}
|
|
@@ -63,7 +63,6 @@ import { toast } from "sonner";
|
|
|
63
63
|
|
|
64
64
|
import { ContentFilesSidebarView } from "@/components/editor/database/sidebar";
|
|
65
65
|
import { QueryErrorState } from "@/components/QueryErrorState";
|
|
66
|
-
import { ThemeToggle } from "@/components/ThemeToggle";
|
|
67
66
|
import {
|
|
68
67
|
AlertDialog,
|
|
69
68
|
AlertDialogAction,
|
|
@@ -83,6 +82,7 @@ import {
|
|
|
83
82
|
DropdownMenuTrigger,
|
|
84
83
|
} from "@/components/ui/dropdown-menu";
|
|
85
84
|
import { ScrollArea } from "@/components/ui/scroll-area";
|
|
85
|
+
import { Skeleton } from "@/components/ui/skeleton";
|
|
86
86
|
import {
|
|
87
87
|
Tooltip,
|
|
88
88
|
TooltipContent,
|
|
@@ -133,7 +133,6 @@ import {
|
|
|
133
133
|
DocumentTreeItem,
|
|
134
134
|
FavoriteDocumentItem,
|
|
135
135
|
} from "./DocumentTreeItem";
|
|
136
|
-
import { NotionButton } from "./NotionButton";
|
|
137
136
|
import {
|
|
138
137
|
contentSpaceAvailability,
|
|
139
138
|
contentSpaceForStoredSelection,
|
|
@@ -288,7 +287,7 @@ function WorkspaceFilesSection({
|
|
|
288
287
|
const failed = filesDatabase.isError || filesPersonalView.isError;
|
|
289
288
|
|
|
290
289
|
return (
|
|
291
|
-
<div className="ms-3
|
|
290
|
+
<div className="ms-3 pb-1 ps-1">
|
|
292
291
|
{failed ? (
|
|
293
292
|
<QueryErrorState
|
|
294
293
|
compact
|
|
@@ -329,7 +328,6 @@ function WorkspaceFilesSection({
|
|
|
329
328
|
onDeleteItem={onDeleteItem}
|
|
330
329
|
onToggleFavorite={onToggleFavorite}
|
|
331
330
|
labels={{
|
|
332
|
-
loadingLabel: t("sidebar.loadingFiles"),
|
|
333
331
|
noMatchesLabel: t("database.noRowsMatchThisView"),
|
|
334
332
|
clearLabel: t("database.clearSearchAndFilters"),
|
|
335
333
|
navigationLabel: `${space.name} ${t("sidebar.files")}`,
|
|
@@ -1407,12 +1405,12 @@ export function DocumentSidebar({
|
|
|
1407
1405
|
};
|
|
1408
1406
|
|
|
1409
1407
|
const renderTreeSkeleton = () => (
|
|
1410
|
-
<div className="
|
|
1408
|
+
<div aria-hidden="true" className="grid gap-1 px-3 py-1">
|
|
1411
1409
|
{[70, 55, 85, 60, 45].map((w, i) => (
|
|
1412
1410
|
<div key={i} className="flex items-center gap-2 px-1 py-1.5">
|
|
1413
|
-
<
|
|
1414
|
-
<
|
|
1415
|
-
className="h-3
|
|
1411
|
+
<Skeleton className="size-3.5 shrink-0 rounded-sm bg-sidebar-foreground/12 dark:bg-sidebar-foreground/10" />
|
|
1412
|
+
<Skeleton
|
|
1413
|
+
className="h-3 rounded bg-sidebar-foreground/12 dark:bg-sidebar-foreground/10"
|
|
1416
1414
|
style={{ width: `${w}%` }}
|
|
1417
1415
|
/>
|
|
1418
1416
|
</div>
|
|
@@ -1611,7 +1609,6 @@ export function DocumentSidebar({
|
|
|
1611
1609
|
}}
|
|
1612
1610
|
scroll={false}
|
|
1613
1611
|
labels={{
|
|
1614
|
-
loadingLabel: t("sidebar.loadingFiles"),
|
|
1615
1612
|
noMatchesLabel: t("database.noRowsMatchThisView"),
|
|
1616
1613
|
clearLabel: t("database.clearSearchAndFilters"),
|
|
1617
1614
|
navigationLabel: "Content navigation",
|
|
@@ -1637,9 +1634,7 @@ export function DocumentSidebar({
|
|
|
1637
1634
|
</div>
|
|
1638
1635
|
</div>
|
|
1639
1636
|
) : contentSpaceState === "loading" ? (
|
|
1640
|
-
|
|
1641
|
-
{t("sidebar.loadingFiles")}
|
|
1642
|
-
</div>
|
|
1637
|
+
renderTreeSkeleton()
|
|
1643
1638
|
) : (
|
|
1644
1639
|
<QueryErrorState
|
|
1645
1640
|
compact
|
|
@@ -1656,7 +1651,7 @@ export function DocumentSidebar({
|
|
|
1656
1651
|
const collapsed = collapsedSections.trash;
|
|
1657
1652
|
|
|
1658
1653
|
return (
|
|
1659
|
-
<div className="mt-3
|
|
1654
|
+
<div className="mt-3 pt-2">
|
|
1660
1655
|
<div className="px-2">
|
|
1661
1656
|
<button
|
|
1662
1657
|
type="button"
|
|
@@ -2025,26 +2020,30 @@ export function DocumentSidebar({
|
|
|
2025
2020
|
</Link>
|
|
2026
2021
|
</div>
|
|
2027
2022
|
{!collapsedSections.favorites &&
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2023
|
+
(isLoading
|
|
2024
|
+
? renderTreeSkeleton()
|
|
2025
|
+
: favorites.map((doc) => (
|
|
2026
|
+
<FavoriteDocumentItem
|
|
2027
|
+
key={doc.id}
|
|
2028
|
+
document={doc}
|
|
2029
|
+
active={doc.id === activeDocumentId}
|
|
2030
|
+
sidebarWidth={favoriteRowWidth}
|
|
2031
|
+
onSelect={() => {
|
|
2032
|
+
handleOpenFavorite(doc);
|
|
2033
|
+
onNavigate?.();
|
|
2034
|
+
}}
|
|
2035
|
+
onCreateChildPage={() =>
|
|
2036
|
+
void handleCreatePage(doc.id)
|
|
2037
|
+
}
|
|
2038
|
+
onCreateChildDatabase={() =>
|
|
2039
|
+
void handleCreateDatabase(doc.id)
|
|
2040
|
+
}
|
|
2041
|
+
onRemoveFavorite={() =>
|
|
2042
|
+
handleToggleFavorite(doc.id, false)
|
|
2043
|
+
}
|
|
2044
|
+
onDelete={() => void handleDelete(doc.id)}
|
|
2045
|
+
/>
|
|
2046
|
+
)))}
|
|
2048
2047
|
</div>
|
|
2049
2048
|
)}
|
|
2050
2049
|
|
|
@@ -2080,10 +2079,6 @@ export function DocumentSidebar({
|
|
|
2080
2079
|
{/* Footer */}
|
|
2081
2080
|
<div className="shrink-0 space-y-2 px-3 py-2">
|
|
2082
2081
|
{isCodeMode ? <DevDatabaseLink /> : null}
|
|
2083
|
-
<div className="flex justify-end gap-0.5">
|
|
2084
|
-
<NotionButton />
|
|
2085
|
-
<ThemeToggle />
|
|
2086
|
-
</div>
|
|
2087
2082
|
<SidebarFooterActions
|
|
2088
2083
|
feedback={feedbackButton}
|
|
2089
2084
|
translate={translateButton}
|
|
@@ -249,7 +249,12 @@ Favor choice-first questions (2-5 concrete options, `allowOther: true`, and a
|
|
|
249
249
|
combining multiple answers — stacking multi-select questions multiplies
|
|
250
250
|
follow-up ambiguity instead of resolving it.
|
|
251
251
|
|
|
252
|
-
**Carry the form-factor answer through to generation — do not just ask and discard it.**
|
|
252
|
+
**Carry the form-factor answer through to generation — do not just ask and discard it.** Map the answer to the design's device SET, not to separate per-device screen files. Device widths of the SAME page are breakpoint frames of one document (see the `responsive-breakpoints` skill), never a `mobile.html` + `desktop.html` pair. Pass the answer through `generate-design`'s `devices` param — `("mobile"|"tablet"|"desktop")[]`, default `["desktop","mobile"]`:
|
|
253
|
+
|
|
254
|
+
- If the prompt/answer names specific devices, generate EXACTLY those, deduped ("mobile" only → one mobile frame; "mobile, tablet, desktop" → all three).
|
|
255
|
+
- If nothing about form factor is specified — or the answer is "Both / responsive" or "Decide for me" — default to `["desktop","mobile"]`: a Desktop base + a Mobile frame only. Never auto-add a tablet, a redundant desktop, or a stray duplicate frame.
|
|
256
|
+
|
|
257
|
+
The WIDEST requested device is the base/primary frame; narrower devices become breakpoint frames (never at the primary width). Device frame sizes: mobile 390×844, tablet 768×1024, desktop 1440×900. `present-design-variants` still takes explicit `width`/`height` per variant to size its exploration screens (see Phase 2).
|
|
253
258
|
|
|
254
259
|
### Phase 2 — Generate side-by-side variations (2-5, three by default)
|
|
255
260
|
|
|
@@ -264,16 +269,16 @@ screen name.
|
|
|
264
269
|
"designId": "<the design id>",
|
|
265
270
|
"prompt": "Pick a direction",
|
|
266
271
|
"variants": [
|
|
267
|
-
{ "id": "a", "label": "Editorial Serif", "width": 1440, "height":
|
|
268
|
-
{ "id": "b", "label": "Bold Brutalist", "width": 1440, "height":
|
|
269
|
-
{ "id": "c", "label": "Soft & Spacious", "width": 1440, "height":
|
|
272
|
+
{ "id": "a", "label": "Editorial Serif", "width": 1440, "height": 900, "content": "<!DOCTYPE html>...full self-contained HTML..." },
|
|
273
|
+
{ "id": "b", "label": "Bold Brutalist", "width": 1440, "height": 900, "content": "<!DOCTYPE html>..." },
|
|
274
|
+
{ "id": "c", "label": "Soft & Spacious", "width": 1440, "height": 900, "content": "<!DOCTYPE html>..." }
|
|
270
275
|
]
|
|
271
276
|
}
|
|
272
277
|
```
|
|
273
278
|
|
|
274
279
|
Each `content` is a complete, self-contained document (Alpine.js + Tailwind via CDN, full `<head>`, CSS variables in `:root`). Variations should be **stylistically/structurally distinct** — different typography schools, layout grammars, color moods — never just color swaps. Label them with concrete style names ("Editorial Serif", not "Variant A").
|
|
275
280
|
|
|
276
|
-
Pass `width`/`height` on every variant to match the form-factor answer (mobile ≈ 390×844, tablet ≈ 768×1024, desktop ≈ 1440×
|
|
281
|
+
Pass `width`/`height` on every variant to match the form-factor answer (mobile ≈ 390×844, tablet ≈ 768×1024, desktop ≈ 1440×900) — the example above is desktop-sized. When `content` is omitted, `present-design-variants` infers a size from the prompt/label/description text and the width/height you pass still wins when given.
|
|
277
282
|
|
|
278
283
|
Wait for the user's pick before refining. Once they choose, keep the selected
|
|
279
284
|
screen, delete the unchosen variant screens with `delete-file`, and continue
|
|
@@ -299,10 +304,11 @@ pnpm action generate-design \
|
|
|
299
304
|
--prompt "Description of the design" \
|
|
300
305
|
--files '[{"filename":"index.html","content":"<full HTML>","fileType":"html"}]' \
|
|
301
306
|
--tweaks '[{"id":"accent","label":"Accent","type":"color-swatch","options":[...],"defaultValue":"#0EA5E9","cssVar":"--color-accent"}]' \
|
|
302
|
-
--
|
|
307
|
+
--devices '["desktop","mobile"]' \
|
|
308
|
+
--canvasFrames '[{"filename":"index.html","x":0,"y":0,"width":1440,"height":900}]'
|
|
303
309
|
```
|
|
304
310
|
|
|
305
|
-
|
|
311
|
+
Pass the `devices` param (`("mobile"|"tablet"|"desktop")[]`, default `["desktop","mobile"]`) so a new design renders the right device frames: the widest device becomes the primary `canvasFrames` placement and each narrower device is added as a breakpoint frame of the SAME document — not an extra file. Default to Desktop + Mobile when the form factor is unspecified; never auto-add a tablet or a redundant desktop. When you also pass `canvasFrames` explicitly, size the primary to the widest device (mobile ≈ 390×844, tablet ≈ 768×1024, desktop ≈ 1440×900) — a screen saved without a placement falls back to a generic default that won't match the intended device. For genuinely distinct screens generated together (Home / Dashboard / Checkout — NOT per-device copies of one page), call `generate-screens` first; it returns the matching `canvasFrame` to forward to each `generate-design` call.
|
|
306
312
|
|
|
307
313
|
#### Non-web sizes — ad units, print one-pagers, social sizes
|
|
308
314
|
|
|
@@ -411,7 +417,11 @@ Every `index.html` must include:
|
|
|
411
417
|
}
|
|
412
418
|
|
|
413
419
|
/* Base styles */
|
|
414
|
-
body {
|
|
420
|
+
body {
|
|
421
|
+
font-family: var(--font-body);
|
|
422
|
+
min-height: 100vh;
|
|
423
|
+
min-height: 100dvh; /* fill the frame — see Full-height frames below */
|
|
424
|
+
}
|
|
415
425
|
h1, h2, h3, h4, h5, h6 {
|
|
416
426
|
font-family: var(--font-heading);
|
|
417
427
|
text-wrap: balance;
|
|
@@ -430,14 +440,24 @@ Every `index.html` must include:
|
|
|
430
440
|
</style>
|
|
431
441
|
</head>
|
|
432
442
|
<body class="bg-[var(--color-primary)] text-[var(--color-text)]">
|
|
433
|
-
<!--
|
|
434
|
-
<div x-data="{ /* component state */ }">
|
|
443
|
+
<!-- Root wrapper fills the device viewport: prefer min-h-screen over inline height:100vh -->
|
|
444
|
+
<div x-data="{ /* component state */ }" class="min-h-screen">
|
|
435
445
|
<!-- Content -->
|
|
436
446
|
</div>
|
|
437
447
|
</body>
|
|
438
448
|
</html>
|
|
439
449
|
```
|
|
440
450
|
|
|
451
|
+
**Full-height frames.** Overview frames now default to at least the device
|
|
452
|
+
viewport height and grow to fit their own content at their own width
|
|
453
|
+
(Framer-style), so a short page must still fill its frame instead of leaving a
|
|
454
|
+
stubby box. The mandatory `body` rule above sets `min-height: 100dvh` (with a
|
|
455
|
+
`100vh` fallback) for exactly this. Put full-height intent on the top-level
|
|
456
|
+
wrapper with Tailwind's `min-h-screen` rather than raw inline `height: 100vh` —
|
|
457
|
+
the editor keeps device-anchored full-height utilities pinned to the device
|
|
458
|
+
viewport, so a full-height hero fills the frame without triggering runaway
|
|
459
|
+
growth.
|
|
460
|
+
|
|
441
461
|
### Alpine.js Patterns
|
|
442
462
|
|
|
443
463
|
**State management** — use `x-data` on the highest-level container:
|
|
@@ -661,7 +681,10 @@ Fontshare `<link>`/`@import` and confirm it renders.
|
|
|
661
681
|
|
|
662
682
|
A prototype with more than one screen is **multiple files** in the same design
|
|
663
683
|
(e.g. `index.html`, `dashboard.html`, `checkout.html`). The editor shows them
|
|
664
|
-
all in the artboard/overview and as screen tabs.
|
|
684
|
+
all in the artboard/overview and as screen tabs. This is only for genuinely
|
|
685
|
+
distinct screens — the mobile and desktop views of the *same* page are
|
|
686
|
+
breakpoint frames of ONE document (the `devices` param + the
|
|
687
|
+
`responsive-breakpoints` model), never a second file.
|
|
665
688
|
|
|
666
689
|
The preview renders each file in a sandboxed `srcdoc` iframe. A real
|
|
667
690
|
`<a href="/pricing">` or `<a href="page.html">` resolves against the *app* URL
|
|
@@ -27,6 +27,14 @@ scopes to `≤ 809px`). `breakpointUpperBoundPx` in
|
|
|
27
27
|
|
|
28
28
|
## Managing breakpoints
|
|
29
29
|
|
|
30
|
+
A newly generated design's frame set comes from `generate-design`'s `devices`
|
|
31
|
+
param (`("mobile"|"tablet"|"desktop")[]`, default `["desktop","mobile"]`). The
|
|
32
|
+
cascade is **desktop-base**: the widest requested device is the primary/base
|
|
33
|
+
frame and each narrower device is a breakpoint frame. The default injected set
|
|
34
|
+
is therefore a Desktop base plus a single Mobile (390) breakpoint frame — the
|
|
35
|
+
narrower frame(s) only, never a frame at the primary desktop width and never an
|
|
36
|
+
auto-added tablet.
|
|
37
|
+
|
|
30
38
|
- `add-breakpoint` — adds a device-width frame to `designs.data.breakpointSet`
|
|
31
39
|
(Framer defaults: Desktop 1200 / Tablet 810 / Phone 390, or custom 320-3840).
|
|
32
40
|
Duplicate widths are ignored.
|