@agent-native/core 0.169.0 → 0.170.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/agent-native.eject.json +4 -1
- package/bin/agent-native.js +23 -5
- package/corpus/README.md +1 -1
- package/corpus/templates/analytics/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/analytics/actions/bigquery-table-info.ts +3 -2
- package/corpus/templates/analytics/actions/query-agent-native-analytics.ts +1 -1
- package/corpus/templates/analytics/actions/search-bigquery-schema.ts +130 -4
- package/corpus/templates/analytics/agent-native.config.ts +1 -0
- package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +36 -23
- package/corpus/templates/analytics/app/i18n-data.ts +28 -0
- package/corpus/templates/analytics/app/lib/dashboard-visibility.ts +41 -0
- package/corpus/templates/analytics/app/pages/Agents.tsx +25 -1
- package/corpus/templates/analytics/app/pages/DashboardOverview.tsx +34 -9
- package/corpus/templates/analytics/app/routes/$.tsx +10 -0
- package/corpus/templates/analytics/app/routes.ts +3 -1
- package/corpus/templates/analytics/changelog/2026-08-21-dashboard-filters-keep-other-users-dashboards-out-of-mine.md +6 -0
- package/corpus/templates/analytics/changelog/2026-08-22-fixed-the-agent-native-templates-first-party-dashboard-panel.md +6 -0
- package/corpus/templates/analytics/changelog/2026-08-22-org-admin-panels-no-longer-report-a-database-error-as-a-per.md +9 -0
- package/corpus/templates/analytics/changelog/2026-08-22-slack-requests-report-invalid-inputs.md +6 -0
- package/corpus/templates/analytics/changelog/2026-08-22-unknown-analytics-links-now-return-a-real-not-found-status.md +6 -0
- package/corpus/templates/analytics/docs/schemas/first-party-analytics.md +2 -1
- package/corpus/templates/analytics/docs/schemas/tracked-events.md +2 -0
- package/corpus/templates/analytics/scripts/emit-netlify-dashboard-report-cron.ts +29 -7
- package/corpus/templates/analytics/server/handlers/slack.ts +59 -5
- package/corpus/templates/analytics/server/lib/db-admin-connections.ts +11 -6
- package/corpus/templates/analytics/server/lib/first-party-analytics.ts +132 -2
- package/corpus/templates/analytics/server/lib/real-data-actions.ts +14 -3
- package/corpus/templates/analytics/server/lib/slack.ts +4 -2
- package/corpus/templates/analytics/server/plugins/agent-chat.ts +33 -3
- package/corpus/templates/analytics/vitest.config.ts +6 -1
- package/corpus/templates/assets/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/assets/app/routes/library.tsx +5 -3
- package/corpus/templates/assets/app/routes.ts +3 -1
- package/corpus/templates/assets/changelog/2026-08-22-library-page-loads-again-instead-of-crashing-on-open.md +6 -0
- package/corpus/templates/assets/vitest.config.ts +6 -1
- package/corpus/templates/brain/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/brain/app/components/ui/pointer-lock.ts +1 -0
- package/corpus/templates/brain/app/routes/sources.tsx +8 -3
- package/corpus/templates/brain/changelog/2026-08-22-tuning-or-adding-a-source-no-longer-leaves-the-sources-page.md +6 -0
- package/corpus/templates/brain/server/lib/brain.ts +27 -2
- package/corpus/templates/brain/vitest.config.ts +1 -0
- package/corpus/templates/calendar/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/calendar/actions/list-booking-links.ts +83 -4
- package/corpus/templates/calendar/actions/update-booking-link.ts +4 -3
- package/corpus/templates/calendar/app/components/calendar/EventDetailPanel.tsx +11 -3
- package/corpus/templates/calendar/app/components/calendar/EventDetailPopover.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/GoogleConnectBanner.tsx +103 -44
- package/corpus/templates/calendar/app/components/calendar/OutOfOfficeEvent.tsx +28 -24
- package/corpus/templates/calendar/app/components/layout/AppLayout.tsx +9 -2
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +47 -58
- package/corpus/templates/calendar/app/hooks/use-booking-links.ts +5 -1
- package/corpus/templates/calendar/app/lib/event-layout.ts +52 -26
- package/corpus/templates/calendar/app/pages/BookingLinksPage.tsx +126 -98
- package/corpus/templates/calendar/app/pages/CalendarView.tsx +1 -0
- package/corpus/templates/calendar/app/pages/Settings.tsx +88 -81
- package/corpus/templates/calendar/app/routes.ts +3 -1
- package/corpus/templates/calendar/changelog/2026-08-22-booking-link-visibility-respects-shared-access.md +6 -0
- package/corpus/templates/calendar/changelog/2026-08-22-clicking-an-out-of-office-event-s-marker-no-longer-creates-a.md +6 -0
- package/corpus/templates/calendar/changelog/2026-08-22-event-detail-views-now-show-your-calendar-timezone.md +6 -0
- package/corpus/templates/calendar/changelog/2026-08-22-google-calendar-can-now-connect-with-the-shared-google-oauth.md +6 -0
- package/corpus/templates/calendar/changelog/2026-08-22-overlapping-events-now-show-each-others-boundaries.md +6 -0
- package/corpus/templates/calendar/changelog/2026-08-22-public-booking-pages-now-offer-time-slots-from-the-host-s-we.md +6 -0
- package/corpus/templates/calendar/server/handlers/bookings.ts +5 -7
- package/corpus/templates/calendar/server/handlers/google-auth.ts +10 -2
- package/corpus/templates/calendar/server/lib/google-calendar.ts +139 -14
- package/corpus/templates/calendar/server/onboarding.ts +85 -0
- package/corpus/templates/calendar/server/plugins/agent-chat.ts +2 -0
- package/corpus/templates/calendar/shared/api.ts +9 -1
- package/corpus/templates/chat/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/chat/app/routes.ts +3 -1
- package/corpus/templates/chat/vitest.config.ts +8 -0
- package/corpus/templates/clips/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/clips/actions/get-meeting.ts +9 -4
- package/corpus/templates/clips/actions/list-recordings.ts +16 -3
- package/corpus/templates/clips/actions/search-meetings.ts +1 -0
- package/corpus/templates/clips/actions/stop-meeting-recording.ts +87 -6
- package/corpus/templates/clips/actions/view-screen.ts +8 -1
- package/corpus/templates/clips/app/components/library/search-bar.tsx +1 -1
- package/corpus/templates/clips/app/components/meetings/meeting-history-row.tsx +32 -1
- package/corpus/templates/clips/app/components/player/delete-recording-menu.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/recorder-engine.ts +29 -1
- package/corpus/templates/clips/app/i18n/en-US.ts +5 -0
- package/corpus/templates/clips/app/routes/_app.meetings.$meetingId.tsx +33 -4
- package/corpus/templates/clips/app/routes/_app.meetings._index.tsx +1 -0
- package/corpus/templates/clips/app/routes/access-request.approve.tsx +16 -9
- package/corpus/templates/clips/app/routes/embed.$shareId.tsx +17 -7
- package/corpus/templates/clips/app/routes/share.$shareId.tsx +17 -7
- package/corpus/templates/clips/changelog/2026-08-21-camera-bubble-black-circle.md +6 -0
- package/corpus/templates/clips/changelog/2026-08-22-screen-recordings-respect-the-microphone-toggle.md +6 -0
- package/corpus/templates/clips/changelog/2026-08-22-the-recordings-library-no-longer-fails-right-after-server-start.md +6 -0
- package/corpus/templates/clips/changelog/2026-08-23-the-agent-can-see-your-library-right-after-server-start.md +6 -0
- package/corpus/templates/clips/chrome-extension/src/background.ts +1 -2
- package/corpus/templates/clips/chrome-extension/src/native-transcription.ts +39 -7
- package/corpus/templates/clips/chrome-extension/src/offscreen.ts +21 -25
- package/corpus/templates/clips/desktop/src/app.tsx +53 -24
- package/corpus/templates/clips/desktop/src/lib/bubble-playback.ts +68 -0
- package/corpus/templates/clips/desktop/src/lib/recorder.ts +3 -0
- package/corpus/templates/clips/desktop/src/lib/transcription-capture.ts +72 -14
- package/corpus/templates/clips/desktop/src/lib/updater.ts +8 -3
- package/corpus/templates/clips/desktop/src/overlays/bubble.tsx +162 -20
- package/corpus/templates/clips/desktop/src-tauri/src/clips/mod.rs +43 -6
- package/corpus/templates/clips/desktop/src-tauri/src/native_screen/custom_capture.rs +150 -13
- package/corpus/templates/clips/desktop/src-tauri/src/tray.rs +12 -0
- package/corpus/templates/clips/server/lib/calendar-event-meetings.ts +28 -3
- package/corpus/templates/clips/server/lib/emails.ts +17 -33
- package/corpus/templates/content/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/content/app/components/editor/VisualEditor.tsx +140 -15
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +12 -14
- package/corpus/templates/content/app/components/ui/pointer-lock.ts +1 -0
- package/corpus/templates/content/app/hooks/use-content-database.ts +18 -2
- package/corpus/templates/content/app/hooks/use-local-storage.ts +38 -22
- package/corpus/templates/content/app/i18n-data.ts +25 -0
- package/corpus/templates/content/app/routes.ts +3 -1
- package/corpus/templates/content/changelog/2026-08-22-code-blocks-inserted-from-the-slash-menu-no-longer-get-stuck.md +6 -0
- package/corpus/templates/content/changelog/2026-08-22-the-sidebar-page-tree-no-longer-flashes-empty-after-creating-a-page.md +6 -0
- package/corpus/templates/content/docs/solutions/2026-08-21-content-mermaid-rendering-shape.md +233 -0
- package/corpus/templates/content/server/plugins/agent-chat.ts +9 -2
- package/corpus/templates/content/vitest.config.ts +7 -1
- package/corpus/templates/crm/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/design/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/design/.generated/bridge/editor-chrome.generated.ts +1386 -92
- package/corpus/templates/design/actions/generate-design.ts +98 -47
- package/corpus/templates/design/actions/get-design-system.ts +6 -1
- package/corpus/templates/design/actions/refresh-design-system-with-builder.ts +146 -0
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +70 -26
- package/corpus/templates/design/app/components/design/EditPanel.tsx +15 -47
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +284 -136
- package/corpus/templates/design/app/components/design/bridge/editor-chrome.bridge.ts +2060 -144
- package/corpus/templates/design/app/components/design/editor/DesignBottomToolbar.tsx +6 -2
- package/corpus/templates/design/app/components/design/editor/DesignWorkspaceRail.tsx +4 -4
- package/corpus/templates/design/app/components/design/keyboard-shortcuts.ts +10 -8
- package/corpus/templates/design/app/components/design/multi-screen/alt-hover-measurement.ts +19 -2
- package/corpus/templates/design/app/components/design/multi-screen/types.ts +9 -2
- package/corpus/templates/design/app/components/layout/Header.tsx +15 -0
- package/corpus/templates/design/app/components/layout/Layout.tsx +7 -2
- package/corpus/templates/design/app/hooks/useDesignHotkeys.ts +13 -8
- package/corpus/templates/design/app/i18n-data.ts +11 -10
- package/corpus/templates/design/app/i18n-keyboard-shortcuts.ts +12 -0
- package/corpus/templates/design/app/lib/design-system-data.ts +68 -0
- package/corpus/templates/design/app/pages/DesignEditor.tsx +99 -57
- package/corpus/templates/design/app/pages/DesignSystemSetup.tsx +39 -8
- package/corpus/templates/design/app/pages/DesignSystems.tsx +137 -43
- package/corpus/templates/design/app/pages/Index.tsx +3 -1
- package/corpus/templates/design/app/pages/Templates.tsx +0 -10
- package/corpus/templates/design/app/pages/design-editor/code-layer-state.ts +10 -0
- package/corpus/templates/design/app/pages/design-editor/collab-sync.ts +50 -0
- package/corpus/templates/design/app/pages/design-editor/commands/apply-design-editor-command.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/apply-file-content-update.ts +10 -8
- package/corpus/templates/design/app/pages/design-editor/commands/apply-local-content-update.ts +6 -6
- package/corpus/templates/design/app/pages/design-editor/commands/apply-pending-visual-styles-with-agent.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/commit-visual-styles.ts +18 -7
- package/corpus/templates/design/app/pages/design-editor/commands/escape-hotkey.ts +4 -90
- package/corpus/templates/design/app/pages/design-editor/commands/layer-marquee-selection-change.ts +2 -1
- package/corpus/templates/design/app/pages/design-editor/commands/layer-selection-change.ts +4 -3
- package/corpus/templates/design/app/pages/design-editor/commands/screen-element-select.ts +12 -2
- package/corpus/templates/design/app/pages/design-editor/commands/screen-visual-style-change.ts +9 -2
- package/corpus/templates/design/app/pages/design-editor/commands/send-runtime-layer-move-semantic-handoff.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/send-runtime-layer-semantic-handoff.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/send-runtime-layer-state-semantic-handoff.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/start-sidebar-resize.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/editor-state.ts +11 -1
- package/corpus/templates/design/app/pages/design-editor/effects/adopt-db-file-content.ts +11 -19
- package/corpus/templates/design/app/pages/design-editor/effects/observe-collab-text.ts +6 -6
- package/corpus/templates/design/app/pages/design-editor/effects/publish-agent-selection-context.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/effects/seed-collab-content.ts +12 -15
- package/corpus/templates/design/app/pages/design-editor/preview-navigation.ts +25 -0
- package/corpus/templates/design/app/pages/design-editor/selection-state.ts +5 -59
- package/corpus/templates/design/app/pages/design-editor/tool-state.ts +8 -0
- package/corpus/templates/design/app/pages/design-editor/types.ts +3 -3
- package/corpus/templates/design/app/routes.ts +3 -1
- package/corpus/templates/design/changelog/2026-08-20-canvas-edits-patch-the-frame-instead-of-rebuilding-it.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-builder-design-system-imports-reconcile-after-indexing.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-draw-mode-needs-shift-y.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-eyedropper-shortcut.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-figma-style-alignment-guides-and-snapping.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-group-transforms-keep-the-selection.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-inspector-fields-keep-focus-on-enter.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-pen-alt-keeps-the-incoming-handle.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-pen-on-the-board-creates-one-vector.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-scale-a-multi-selection-from-the-group-handles.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-scale-resizes-text-with-the-object.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-selecting-another-object-keeps-the-scale-tool-armed.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-the-shape-tool-remembers-the-shape-you-picked.md +6 -0
- package/corpus/templates/design/changelog/2026-08-21-vectors-drawn-in-a-frame-land-where-you-drew-them.md +6 -0
- package/corpus/templates/design/changelog/2026-08-22-multi-screen-generation-no-longer-loses-a-saved-screens-layo.md +6 -0
- package/corpus/templates/design/changelog/2026-08-22-rename-and-search-fields-are-labeled-for-screen-readers.md +6 -0
- package/corpus/templates/design/package.json +2 -0
- package/corpus/templates/design/server/lib/builder-design-system-proxy.ts +311 -0
- package/corpus/templates/design/shared/canvas-math.ts +612 -206
- package/corpus/templates/design/shared/pen-path.ts +37 -0
- package/corpus/templates/design/vitest.config.ts +7 -1
- package/corpus/templates/dispatch/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/dispatch/actions/list-workspace-connections.ts +34 -3
- package/corpus/templates/dispatch/app/routes/integrations.tsx +55 -21
- package/corpus/templates/dispatch/app/routes.ts +3 -1
- package/corpus/templates/factory/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/factory/.env.example +2 -7
- package/corpus/templates/factory/AGENTS.md +3 -0
- package/corpus/templates/factory/README.md +5 -3
- package/corpus/templates/factory/actions/create-factory.ts +16 -3
- package/corpus/templates/factory/actions/get-slack-feedback-context.ts +2 -0
- package/corpus/templates/factory/actions/get-triage-item.ts +2 -0
- package/corpus/templates/factory/actions/list-factory-audit.ts +116 -36
- package/corpus/templates/factory/actions/list-factory-automations.ts +2 -1
- package/corpus/templates/factory/actions/list-triage-items.ts +22 -19
- package/corpus/templates/factory/actions/run-factory-automation.ts +7 -3
- package/corpus/templates/factory/actions/save-factory-automation.ts +5 -2
- package/corpus/templates/factory/actions/save-triage-config.ts +2 -8
- package/corpus/templates/factory/actions/start-builder-for-item.ts +21 -0
- package/corpus/templates/factory/app/components/factory/FactoryAuditView.tsx +229 -297
- package/corpus/templates/factory/app/components/factory/FactorySettingsView.tsx +397 -247
- package/corpus/templates/factory/app/components/factory/FactorySourceSettingsGroup.tsx +33 -0
- package/corpus/templates/factory/app/components/factory/NewFactoryForm.tsx +202 -162
- package/corpus/templates/factory/app/i18n/en-US.ts +32 -4
- package/corpus/templates/factory/app/routes/factory.tsx +84 -11
- package/corpus/templates/factory/app/routes.ts +3 -1
- package/corpus/templates/factory/changelog/2026-08-21-activity-runs-use-automation-display-names.md +6 -0
- package/corpus/templates/factory/changelog/2026-08-21-create-and-settings-source-cards.md +6 -0
- package/corpus/templates/factory/changelog/2026-08-21-keep-automations-visible-while-running.md +6 -0
- package/corpus/templates/factory/changelog/2026-08-21-nested-factory-automations-can-poll.md +6 -0
- package/corpus/templates/factory/changelog/2026-08-21-settings-sticky-unsaved-bar.md +6 -0
- package/corpus/templates/factory/server/connectors/credentials.ts +10 -5
- package/corpus/templates/factory/server/lib/factory-audit-report.ts +412 -0
- package/corpus/templates/factory/server/lib/factory-config-reconcile.ts +321 -0
- package/corpus/templates/factory/server/lib/factory-scope.ts +25 -2
- package/corpus/templates/factory/server/lib/require-factory-automation.ts +13 -4
- package/corpus/templates/factory/server/plugins/factory-migrations.ts +148 -4
- package/corpus/templates/factory/server/plugins/factory-scheduler-job.ts +4 -6
- package/corpus/templates/factory/vitest.config.ts +17 -2
- package/corpus/templates/forms/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/forms/app/routes/_app.settings.tsx +4 -1
- package/corpus/templates/forms/changelog/2026-08-22-the-extensions-link-now-opens-the-extensions-tab-instead-o.md +6 -0
- package/corpus/templates/forms/server/lib/public-form-ssr.ts +11 -1
- package/corpus/templates/forms/vitest.config.ts +1 -0
- package/corpus/templates/macros/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/macros/app/routes.ts +3 -1
- package/corpus/templates/macros/vitest.config.ts +6 -1
- package/corpus/templates/mail/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/mail/actions/manage-gmail-filters.ts +10 -2
- package/corpus/templates/mail/app/components/GoogleConnectBanner.tsx +100 -37
- package/corpus/templates/mail/app/components/email/IntegrationsSidebar.tsx +14 -2
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +66 -36
- package/corpus/templates/mail/app/hooks/use-emails.ts +13 -3
- package/corpus/templates/mail/app/hooks/use-google-auth.ts +2 -0
- package/corpus/templates/mail/app/lib/google-oauth-setup.ts +17 -0
- package/corpus/templates/mail/app/pages/InboxPage.tsx +69 -9
- package/corpus/templates/mail/app/routes/$.tsx +9 -0
- package/corpus/templates/mail/app/routes/$view.$threadId.tsx +23 -1
- package/corpus/templates/mail/app/routes/$view.tsx +47 -1
- package/corpus/templates/mail/app/routes.ts +3 -1
- package/corpus/templates/mail/changelog/2026-08-22-gmail-can-now-connect-with-the-shared-google-oauth.md +6 -0
- package/corpus/templates/mail/changelog/2026-08-22-gmail-filters-now-shows-the-real-error.md +6 -0
- package/corpus/templates/mail/changelog/2026-08-22-unknown-mail-urls-now-show-the-404-page.md +6 -0
- package/corpus/templates/mail/server/handlers/google-auth.ts +11 -2
- package/corpus/templates/mail/server/lib/google-auth.ts +92 -12
- package/corpus/templates/mail/server/onboarding.ts +66 -18
- package/corpus/templates/mail/vitest.config.ts +6 -1
- package/corpus/templates/plan/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/plan/app/routes/settings.tsx +4 -1
- package/corpus/templates/plan/app/routes.ts +3 -1
- package/corpus/templates/plan/changelog/2026-08-22-the-extensions-link-now-opens-the-extensions-tab-instead-o.md +6 -0
- package/corpus/templates/plan/netlify.toml +1 -1
- package/corpus/templates/slides/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/slides/actions/patch-deck.ts +79 -10
- package/corpus/templates/slides/actions/update-slide.ts +11 -1
- package/corpus/templates/slides/app/components/deck/SlideRenderer.tsx +14 -4
- package/corpus/templates/slides/app/components/editor/ExportMenu.tsx +10 -52
- package/corpus/templates/slides/app/components/editor/GoogleDocImportHint.tsx +8 -53
- package/corpus/templates/slides/app/components/editor/GoogleDriveConnectionCta.tsx +9 -75
- package/corpus/templates/slides/app/components/editor/GoogleSlidesReferenceImport.tsx +8 -60
- package/corpus/templates/slides/app/components/editor/SlideContextToolbar.tsx +10 -2
- package/corpus/templates/slides/app/components/editor/SlideEditor.tsx +19 -7
- package/corpus/templates/slides/app/lib/sanitize-slide-html.ts +49 -36
- package/corpus/templates/slides/app/routes/access-request.approve.tsx +16 -9
- package/corpus/templates/slides/app/routes.ts +3 -1
- package/corpus/templates/slides/changelog/2026-08-22-already-uploaded-chat-images-are-no-longer-dropped.md +6 -0
- package/corpus/templates/slides/changelog/2026-08-22-google-drive-and-slides-can-now-connect-with-the-shared-google-oauth.md +6 -0
- package/corpus/templates/slides/changelog/2026-08-22-multi-slide-repairs-now-report-slides-that-still-overflow.md +6 -0
- package/corpus/templates/slides/changelog/2026-08-22-update-slide-now-reports-which-batched-edit-was-skipped.md +6 -0
- package/corpus/templates/slides/server/handlers/google-docs-auth.ts +52 -1
- package/corpus/templates/slides/server/lib/chat-attachments.ts +29 -3
- package/corpus/templates/slides/server/lib/google-docs-oauth.ts +66 -16
- package/corpus/templates/slides/server/lib/slide-content-patch.ts +13 -2
- package/corpus/templates/slides/server/plugins/agent-chat.ts +5 -2
- package/corpus/templates/slides/tsconfig.json +5 -0
- package/corpus/templates/slides/vitest.config.ts +6 -1
- package/corpus/templates/tasks/.agents/skills/secrets/SKILL.md +11 -4
- package/corpus/templates/tasks/app/routes/settings.tsx +4 -1
- package/corpus/templates/tasks/app/routes.ts +3 -1
- package/corpus/templates/tasks/changelog/2026-08-22-the-extensions-link-now-opens-the-extensions-tab-instead-o.md +6 -0
- package/corpus/templates/tasks/vitest.config.ts +7 -1
- package/dist/action.d.ts +91 -0
- package/dist/action.js +50 -0
- package/dist/agent/abort-reasons.d.ts +38 -0
- package/dist/agent/abort-reasons.js +49 -0
- package/dist/agent/engine/ai-sdk-engine.js +8 -5
- package/dist/agent/engine/anthropic-engine.js +7 -5
- package/dist/agent/engine/credential-errors.d.ts +1 -1
- package/dist/agent/engine/credential-errors.js +2 -2
- package/dist/agent/engine/first-event-timeout.d.ts +42 -17
- package/dist/agent/engine/first-event-timeout.js +67 -25
- package/dist/agent/production-agent.d.ts +23 -0
- package/dist/agent/production-agent.js +107 -102
- package/dist/agent/run-loop-with-resume.d.ts +2 -28
- package/dist/agent/run-loop-with-resume.js +25 -40
- package/dist/agent/run-manager.js +5 -4
- package/dist/agent/run-store.d.ts +55 -0
- package/dist/agent/run-store.js +124 -1
- package/dist/agent/tool-search.js +2 -1
- package/dist/agent/types.d.ts +9 -4
- package/dist/app-config/configuration-error.d.ts +11 -0
- package/dist/app-config/configuration-error.js +14 -0
- package/dist/app-config/index.d.ts +1 -0
- package/dist/app-config/index.js +1 -0
- package/dist/app-config/integrations.d.ts +1 -0
- package/dist/app-config/integrations.js +10 -0
- package/dist/app-config/plugins.d.ts +34 -0
- package/dist/app-config/plugins.js +39 -0
- package/dist/app-config/run-lifecycle-invariants.d.ts +18 -9
- package/dist/app-config/run-lifecycle-invariants.js +18 -25
- package/dist/app-config/schema.d.ts +16 -0
- package/dist/app-config/schema.js +2 -0
- package/dist/chat-threads/schema-migrations.js +20 -0
- package/dist/chat-threads/store.js +21 -4
- package/dist/cli/native-dependencies.d.ts +4 -0
- package/dist/cli/native-dependencies.js +15 -0
- package/dist/client/AssistantChat.js +47 -15
- package/dist/client/ConnectBuilderCard.d.ts +3 -1
- package/dist/client/ConnectBuilderCard.js +6 -3
- package/dist/client/EnvironmentBadge.d.ts +1 -1
- package/dist/client/EnvironmentBadge.js +40 -5
- package/dist/client/MultiTabAssistantChat.d.ts +1 -1
- package/dist/client/MultiTabAssistantChat.js +35 -14
- package/dist/client/agent-chat/index.d.ts +1 -1
- package/dist/client/agent-chat/index.js +1 -1
- package/dist/client/agent-page/use-jobs.d.ts +2 -1
- package/dist/client/agent-page/use-jobs.js +3 -5
- package/dist/client/agent-sidebar-state.js +3 -1
- package/dist/client/blocks/library/code-tabs.js +5 -0
- package/dist/client/blocks/library/code.js +1 -0
- package/dist/client/chat/message-components.d.ts +7 -0
- package/dist/client/chat/message-components.js +1 -1
- package/dist/client/chat/run-recovery.js +5 -2
- package/dist/client/chat/tool-call-display.js +9 -3
- package/dist/client/chat-first/apps-rail.js +2 -2
- package/dist/client/chat-model-groups.d.ts +12 -0
- package/dist/client/chat-model-groups.js +3 -2
- package/dist/client/error-format.js +12 -0
- package/dist/client/integrations/GoogleProductLogo.d.ts +5 -0
- package/dist/client/integrations/GoogleProductLogo.js +45 -0
- package/dist/client/integrations/index.d.ts +2 -0
- package/dist/client/integrations/index.js +2 -0
- package/dist/client/integrations/workspace-provider-oauth.d.ts +8 -0
- package/dist/client/integrations/workspace-provider-oauth.js +13 -0
- package/dist/client/navigation/index.d.ts +1 -0
- package/dist/client/navigation/index.js +1 -0
- package/dist/client/resources/mcp-integration-catalog.js +0 -29
- package/dist/client/route-state.js +6 -0
- package/dist/client/settings/SettingsTabsPage.js +10 -6
- package/dist/client/sharing/ShareButton.js +11 -2
- package/dist/client/use-chat-models.d.ts +6 -0
- package/dist/client/use-chat-models.js +10 -0
- package/dist/client/use-db-sync.js +27 -9
- package/dist/client/workspace-app-navigation.d.ts +10 -0
- package/dist/client/workspace-app-navigation.js +38 -0
- package/dist/collab/struct-routes.d.ts +1 -1
- package/dist/connections/catalog.d.ts +111 -9
- package/dist/connections/catalog.js +86 -30
- package/dist/db/create-get-db.js +18 -0
- package/dist/db/ddl-guard.d.ts +0 -4
- package/dist/db/ddl-guard.js +46 -0
- package/dist/deploy/build.d.ts +32 -0
- package/dist/deploy/build.js +241 -16
- package/dist/deploy/function-bundle.d.ts +45 -0
- package/dist/deploy/function-bundle.js +337 -0
- package/dist/deploy/workspace-deploy.js +19 -1
- package/dist/eject/workspace-connections.js +4 -0
- package/dist/email-catalog/registry.d.ts +4 -0
- package/dist/email-catalog/registry.js +79 -14
- package/dist/extensions/content-patch.js +14 -2
- package/dist/file-upload/actions/upload-image.d.ts +1 -1
- package/dist/integrations/plugin.d.ts +10 -0
- package/dist/integrations/plugin.js +40 -6
- package/dist/jobs/actions/run-automation-now.d.ts +2 -1
- package/dist/jobs/actions/run-automation-now.js +11 -5
- package/dist/jobs/frontmatter.js +53 -2
- package/dist/jobs/run-now.d.ts +11 -1
- package/dist/jobs/run-now.js +42 -7
- package/dist/jobs/scheduler.d.ts +1 -0
- package/dist/jobs/scheduler.js +2 -1
- package/dist/localization/core-messages/ar-SA.js +4 -1
- package/dist/localization/core-messages/de-DE.js +4 -1
- package/dist/localization/core-messages/en-US.d.ts +4 -1
- package/dist/localization/core-messages/en-US.js +4 -1
- package/dist/localization/core-messages/es-ES.js +4 -1
- package/dist/localization/core-messages/fr-FR.js +4 -1
- package/dist/localization/core-messages/hi-IN.js +4 -1
- package/dist/localization/core-messages/ja-JP.js +4 -1
- package/dist/localization/core-messages/ko-KR.js +4 -1
- package/dist/localization/core-messages/pt-BR.js +4 -1
- package/dist/localization/core-messages/zh-CN.js +4 -1
- package/dist/localization/core-messages/zh-TW.js +4 -1
- package/dist/localization/core-messages.d.ts +4 -1
- package/dist/localization/default-messages.d.ts +2 -5
- package/dist/localization/default-messages.js +2 -5
- package/dist/mcp/build-server.d.ts +9 -0
- package/dist/mcp/build-server.js +37 -8
- package/dist/mcp-client/oauth-client.d.ts +7 -0
- package/dist/mcp-client/oauth-client.js +12 -1
- package/dist/notifications/routes.d.ts +1 -1
- package/dist/oauth-tokens/index.d.ts +1 -1
- package/dist/oauth-tokens/index.js +1 -1
- package/dist/oauth-tokens/lifecycle.d.ts +11 -0
- package/dist/oauth-tokens/lifecycle.js +17 -0
- package/dist/oauth-tokens/store.js +7 -0
- package/dist/observability/posthog-ai.d.ts +15 -1
- package/dist/observability/posthog-ai.js +24 -12
- package/dist/observability/traces.js +158 -28
- package/dist/onboarding/app-profile.js +2 -2
- package/dist/onboarding/plugin.js +10 -2
- package/dist/onboarding/types.d.ts +2 -0
- package/dist/provider-api/actions/custom-provider-registration.d.ts +12 -12
- package/dist/provider-api/actions/provider-api.d.ts +11 -11
- package/dist/provider-api/corpus-jobs.d.ts +2 -2
- package/dist/provider-api/index.js +2 -0
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/resources/store.js +13 -4
- package/dist/scripts/agent-engines/list-agent-engines.js +29 -3
- package/dist/scripts/db/check-scoping.js +9 -6
- package/dist/secrets/register-framework-secrets.js +1 -1
- package/dist/secrets/routes.d.ts +6 -6
- package/dist/server/action-discovery.js +5 -0
- package/dist/server/agent-chat/action-filters-a2a.d.ts +27 -3
- package/dist/server/agent-chat/action-filters-a2a.js +48 -9
- package/dist/server/agent-chat-plugin.js +36 -9
- package/dist/server/agent-discovery.js +43 -20
- package/dist/server/auth.js +18 -16
- package/dist/server/beta-opt-out-html.js +45 -4
- package/dist/server/better-auth-instance.d.ts +2 -1
- package/dist/server/better-auth-instance.js +23 -7
- package/dist/server/builder-browser.d.ts +4 -0
- package/dist/server/builder-browser.js +23 -1
- package/dist/server/builder-design-systems.d.ts +4 -1
- package/dist/server/builder-design-systems.js +87 -6
- package/dist/server/builder-oauth.d.ts +1 -7
- package/dist/server/builder-oauth.js +80 -163
- package/dist/server/core-routes-plugin.d.ts +29 -0
- package/dist/server/core-routes-plugin.js +113 -21
- package/dist/server/default-plugins.d.ts +18 -0
- package/dist/server/default-plugins.js +22 -0
- package/dist/server/edge.d.ts +1 -0
- package/dist/server/edge.js +1 -0
- package/dist/server/framework-request-handler.js +31 -3
- package/dist/server/google-oauth.d.ts +3 -0
- package/dist/server/google-oauth.js +3 -0
- package/dist/server/index.d.ts +4 -4
- package/dist/server/index.js +3 -3
- package/dist/server/onboarding-html.js +37 -3
- package/dist/server/workspace-provider-oauth.d.ts +6 -1
- package/dist/server/workspace-provider-oauth.js +72 -20
- package/dist/shared/agent-sidebar-url.d.ts +1 -0
- package/dist/shared/agent-sidebar-url.js +1 -0
- package/dist/shared/environment-lanes.d.ts +2 -0
- package/dist/shared/environment-lanes.js +3 -1
- package/dist/shared/index.d.ts +3 -1
- package/dist/shared/index.js +3 -1
- package/dist/shared/surface-visibility.d.ts +31 -0
- package/dist/shared/surface-visibility.js +57 -0
- package/dist/templates/chat/.agents/skills/secrets/SKILL.md +11 -4
- package/dist/templates/chat/app/routes.ts +3 -1
- package/dist/templates/chat/vitest.config.ts +8 -0
- package/dist/templates/default/.agents/skills/secrets/SKILL.md +11 -4
- package/dist/templates/default/app/routes.ts +3 -1
- package/dist/templates/headless/.agents/skills/secrets/SKILL.md +11 -4
- package/dist/templates/workspace-core/.agents/skills/secrets/SKILL.md +11 -4
- package/dist/tracking/registry.d.ts +11 -0
- package/dist/tracking/registry.js +5 -2
- package/dist/triggers/actions.js +10 -3
- package/dist/usage/store.js +23 -3
- package/dist/user-profile/actions/get-auth-methods.js +18 -5
- package/dist/vite/client.js +24 -5
- package/docs/content/actions-access-control.mdx +43 -4
- package/docs/content/actions-defining.mdx +16 -0
- package/docs/content/template-clips-capture-everywhere.mdx +29 -30
- package/docs/content/template-clips-developers.mdx +4 -4
- package/docs/content/template-clips.mdx +3 -1
- package/package.json +3 -3
- package/src/eject/workspace-connections.ts +4 -0
- package/src/templates/chat/.agents/skills/secrets/SKILL.md +11 -4
- package/src/templates/chat/app/routes.ts +3 -1
- package/src/templates/chat/vitest.config.ts +8 -0
- package/src/templates/default/.agents/skills/secrets/SKILL.md +11 -4
- package/src/templates/default/app/routes.ts +3 -1
- package/src/templates/headless/.agents/skills/secrets/SKILL.md +11 -4
- package/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +11 -4
- /package/corpus/templates/dispatch/app/routes/{apps.$appId.tsx → apps.$appId.$.tsx} +0 -0
|
@@ -748,6 +748,7 @@ import {
|
|
|
748
748
|
PngCaptureError,
|
|
749
749
|
type PngCaptureScope,
|
|
750
750
|
} from "./design-editor/png-export-render";
|
|
751
|
+
import { openPreviewUrl } from "./design-editor/preview-navigation";
|
|
751
752
|
import {
|
|
752
753
|
computeInteractZoomToFit,
|
|
753
754
|
DEFAULT_INTERACT_DEVICE_PRESET,
|
|
@@ -786,6 +787,7 @@ import { postShaderFillPreviewClearToPreviewIframes } from "./design-editor/text
|
|
|
786
787
|
import {
|
|
787
788
|
getDesignBottomToolbarMode,
|
|
788
789
|
getSingleScreenCreationTool,
|
|
790
|
+
resolveToolAfterSelection,
|
|
789
791
|
shouldAutoEnableDrawOverlay,
|
|
790
792
|
} from "./design-editor/tool-state";
|
|
791
793
|
import {
|
|
@@ -955,6 +957,9 @@ function DesignEditor() {
|
|
|
955
957
|
// Editor state
|
|
956
958
|
const [mode, setMode] = useState<EditorMode>("edit");
|
|
957
959
|
const [activeTool, setActiveTool] = useState<DesignTool>("move");
|
|
960
|
+
// Drawing drops activeTool back to move (Figma parity), so the shape group
|
|
961
|
+
// button cannot read its own identity off it.
|
|
962
|
+
const [shapeTool, setShapeTool] = useState<ShapeTool>("rect");
|
|
958
963
|
// The frame tool draws a top-level SCREEN or a plain FRAME container. Made
|
|
959
964
|
// explicit because deciding it from where the drag started is unguessable.
|
|
960
965
|
const [frameToolDraws, setFrameToolDraws] = useState<"screen" | "frame">(
|
|
@@ -1359,7 +1364,7 @@ function DesignEditor() {
|
|
|
1359
1364
|
} | null>(null);
|
|
1360
1365
|
const reviewFocusNonceRef = useRef(0);
|
|
1361
1366
|
const [activeLeftPanel, setActiveLeftPanel] =
|
|
1362
|
-
useState<DesignLeftPanel>("file");
|
|
1367
|
+
useState<DesignLeftPanel | null>("file");
|
|
1363
1368
|
const [activeCodeFile, setActiveCodeFile] =
|
|
1364
1369
|
useState<CodeWorkbenchActiveFile | null>(null);
|
|
1365
1370
|
const initialSearchCommandAppliedForIdRef = useRef<string | null>(null);
|
|
@@ -6091,9 +6096,9 @@ function DesignEditor() {
|
|
|
6091
6096
|
latestActiveContentRef.current = activeContent;
|
|
6092
6097
|
}, [activeContent]);
|
|
6093
6098
|
useEffect(() => {
|
|
6094
|
-
if (!initialGenerationChromeLimited
|
|
6099
|
+
if (!initialGenerationChromeLimited) return;
|
|
6095
6100
|
setActiveLeftPanel("agent");
|
|
6096
|
-
}, [
|
|
6101
|
+
}, [initialGenerationChromeLimited]);
|
|
6097
6102
|
const fileContentById = useMemo(() => {
|
|
6098
6103
|
const map = new Map<string, string>();
|
|
6099
6104
|
for (const file of files) {
|
|
@@ -8109,13 +8114,18 @@ function DesignEditor() {
|
|
|
8109
8114
|
* engine handles persistence identically to in-screen elements.
|
|
8110
8115
|
*/
|
|
8111
8116
|
const handleBoardDrawPrimitive = useCallback(
|
|
8112
|
-
(
|
|
8117
|
+
(
|
|
8118
|
+
primitive: CanvasPrimitiveInsert,
|
|
8119
|
+
options?: { nextTool?: "move" | "pen" },
|
|
8120
|
+
) => {
|
|
8113
8121
|
if (!boardFileId || !canEditDesign) return false;
|
|
8114
8122
|
const result = handleCreatePrimitive(boardFileId, primitive);
|
|
8115
8123
|
if (!result) return false;
|
|
8116
8124
|
const nodeId = typeof result === "string" ? result : primitive.nodeId;
|
|
8117
8125
|
if (nodeId) {
|
|
8118
|
-
|
|
8126
|
+
// Without the caller's tool intent a board pen commit lands on Move,
|
|
8127
|
+
// which disarms the Pen mid-path — a screen insert keeps it.
|
|
8128
|
+
handlePrimitiveCreated(boardFileId, nodeId, options);
|
|
8119
8129
|
}
|
|
8120
8130
|
|
|
8121
8131
|
return result;
|
|
@@ -8368,6 +8378,7 @@ function DesignEditor() {
|
|
|
8368
8378
|
blurActiveDesignEditableTarget();
|
|
8369
8379
|
flushSync(() => {
|
|
8370
8380
|
setActiveTool(tool);
|
|
8381
|
+
setShapeTool(tool);
|
|
8371
8382
|
if (viewModeRef.current === "single" && activeFile) {
|
|
8372
8383
|
setMode("edit");
|
|
8373
8384
|
setDrawMode(false);
|
|
@@ -9009,7 +9020,7 @@ function DesignEditor() {
|
|
|
9009
9020
|
handleBreakpointBarSelect(undefined);
|
|
9010
9021
|
}
|
|
9011
9022
|
}
|
|
9012
|
-
setActiveTool(
|
|
9023
|
+
setActiveTool(resolveToolAfterSelection);
|
|
9013
9024
|
setMode("edit");
|
|
9014
9025
|
},
|
|
9015
9026
|
[clearPendingOverviewLayerSelectionTimer, handleBreakpointBarSelect],
|
|
@@ -9390,6 +9401,7 @@ function DesignEditor() {
|
|
|
9390
9401
|
elementInfo?: ElementInfo;
|
|
9391
9402
|
/** Pre-gesture values, for the pending-edit revert stack. */
|
|
9392
9403
|
originalStyles?: Record<string, string>;
|
|
9404
|
+
preserveSelection?: boolean;
|
|
9393
9405
|
} = {},
|
|
9394
9406
|
) =>
|
|
9395
9407
|
runCommitVisualStyles(
|
|
@@ -9888,7 +9900,10 @@ function DesignEditor() {
|
|
|
9888
9900
|
selector: string,
|
|
9889
9901
|
styles: Record<string, string>,
|
|
9890
9902
|
elementInfo?: ElementInfo,
|
|
9891
|
-
metadata?: {
|
|
9903
|
+
metadata?: {
|
|
9904
|
+
originalStyles?: Record<string, string>;
|
|
9905
|
+
preserveSelection?: boolean;
|
|
9906
|
+
},
|
|
9892
9907
|
) => {
|
|
9893
9908
|
if (!activeFile?.id) return;
|
|
9894
9909
|
// The gesture already moved the live DOM, so this never needs the
|
|
@@ -9900,6 +9915,7 @@ function DesignEditor() {
|
|
|
9900
9915
|
runtimeApplied: true,
|
|
9901
9916
|
elementInfo,
|
|
9902
9917
|
originalStyles: metadata?.originalStyles,
|
|
9918
|
+
preserveSelection: metadata?.preserveSelection,
|
|
9903
9919
|
});
|
|
9904
9920
|
},
|
|
9905
9921
|
[activeFile?.id, commitVisualStyles],
|
|
@@ -10047,7 +10063,10 @@ function DesignEditor() {
|
|
|
10047
10063
|
selector: string,
|
|
10048
10064
|
styles: Record<string, string>,
|
|
10049
10065
|
elementInfo?: ElementInfo,
|
|
10050
|
-
metadata?: {
|
|
10066
|
+
metadata?: {
|
|
10067
|
+
originalStyles?: Record<string, string>;
|
|
10068
|
+
preserveSelection?: boolean;
|
|
10069
|
+
},
|
|
10051
10070
|
) =>
|
|
10052
10071
|
runScreenVisualStyleChange(
|
|
10053
10072
|
{
|
|
@@ -13178,7 +13197,6 @@ function DesignEditor() {
|
|
|
13178
13197
|
activeBreakpointWidthStateRef,
|
|
13179
13198
|
activeTool,
|
|
13180
13199
|
cancelActiveEditorDrag,
|
|
13181
|
-
codeLayerOwnerByNodeIdRef,
|
|
13182
13200
|
drawMode,
|
|
13183
13201
|
enterOverviewFromZoom,
|
|
13184
13202
|
focusedAnnotationSending,
|
|
@@ -13191,11 +13209,8 @@ function DesignEditor() {
|
|
|
13191
13209
|
overviewAnnotationSending,
|
|
13192
13210
|
pinMode,
|
|
13193
13211
|
selectedElement,
|
|
13194
|
-
selectedLayerIdsState,
|
|
13195
|
-
setActiveFileId,
|
|
13196
13212
|
setActiveTool,
|
|
13197
13213
|
setDrawMode,
|
|
13198
|
-
setExpandedLayerIds,
|
|
13199
13214
|
setHoveredElement,
|
|
13200
13215
|
setMode,
|
|
13201
13216
|
setOverviewClearSelectionRequest,
|
|
@@ -13220,7 +13235,6 @@ function DesignEditor() {
|
|
|
13220
13235
|
overviewAnnotationSending,
|
|
13221
13236
|
pinMode,
|
|
13222
13237
|
selectedElement,
|
|
13223
|
-
selectedLayerIdsState,
|
|
13224
13238
|
viewMode,
|
|
13225
13239
|
],
|
|
13226
13240
|
);
|
|
@@ -13477,12 +13491,8 @@ function DesignEditor() {
|
|
|
13477
13491
|
owner.node.parentId,
|
|
13478
13492
|
);
|
|
13479
13493
|
if (!parentOwner || parentOwner.fileId !== owner.fileId) return;
|
|
13480
|
-
//
|
|
13481
|
-
//
|
|
13482
|
-
// collapsed <html>/<body> shell node, which the layers panel never shows
|
|
13483
|
-
// as selectable. Without this guard, Shift+Enter/"\\" on a top-level
|
|
13484
|
-
// layer would select <body> instead of no-op'ing like the comment above
|
|
13485
|
-
// already documents.
|
|
13494
|
+
// The flat ownership map still resolves a top-level layer's parentId to
|
|
13495
|
+
// the collapsed <html>/<body> shell node the layers panel never shows.
|
|
13486
13496
|
if (!hasSelectableCodeLayerParent({ parentNode: parentOwner.node })) {
|
|
13487
13497
|
return;
|
|
13488
13498
|
}
|
|
@@ -13524,7 +13534,7 @@ function DesignEditor() {
|
|
|
13524
13534
|
setOverviewSelectAllRequest((request) => request + 1);
|
|
13525
13535
|
}, [activeFile, getFreshActiveContent, overviewScreens]);
|
|
13526
13536
|
|
|
13527
|
-
//
|
|
13537
|
+
// Shared by the canvas context-menu Rename item — the single
|
|
13528
13538
|
// currently-selected layer id eligible for the layers-panel inline rename,
|
|
13529
13539
|
// or null when zero or more-than-one layers are selected (screen/file rows
|
|
13530
13540
|
// are excluded; renaming those is a separate flow). `__`-prefixed and file
|
|
@@ -13620,14 +13630,9 @@ function DesignEditor() {
|
|
|
13620
13630
|
handleDeleteOverviewSelection(selectedLayerIdsState);
|
|
13621
13631
|
}
|
|
13622
13632
|
: undefined,
|
|
13623
|
-
//
|
|
13624
|
-
//
|
|
13625
|
-
//
|
|
13626
|
-
// focus is clearly on a specific layer. Route to the layer's real inline
|
|
13627
|
-
// rename editor (LayersPanel ref's beginRename) when exactly one
|
|
13628
|
-
// selectable (non-file-row) layer is selected; only fall back to
|
|
13629
|
-
// renaming the design title when nothing (or more than one layer) is
|
|
13630
|
-
// selected.
|
|
13633
|
+
// The context-menu Rename item routes to the layer's real inline rename
|
|
13634
|
+
// editor (LayersPanel ref's beginRename) when exactly one selectable
|
|
13635
|
+
// (non-file-row) layer is selected.
|
|
13631
13636
|
onRename: () => {
|
|
13632
13637
|
if (!canEditDesign) return;
|
|
13633
13638
|
const layerId = getSingleSelectedRenamableLayerId();
|
|
@@ -15628,6 +15633,20 @@ function DesignEditor() {
|
|
|
15628
15633
|
selectedLayerTargetsRef.current = selectedLayerTargets;
|
|
15629
15634
|
}, [selectedLayerTargets]);
|
|
15630
15635
|
|
|
15636
|
+
/** The overview canvas keeps a layer's owning screen in `selectedScreenIds`
|
|
15637
|
+
* (z-order and "topmost screen" read it), so without this the screen's own
|
|
15638
|
+
* full-bleed SelectionBox stays mounted over the element and its drag
|
|
15639
|
+
* surface swallows the gesture — the frame moves instead of the layer. */
|
|
15640
|
+
const selectedElementScreenId = useMemo(() => {
|
|
15641
|
+
const first = selectedLayerTargets[0];
|
|
15642
|
+
if (!first) return null;
|
|
15643
|
+
return selectedLayerTargets.every(
|
|
15644
|
+
(target) => target.fileId === first.fileId,
|
|
15645
|
+
)
|
|
15646
|
+
? first.fileId
|
|
15647
|
+
: null;
|
|
15648
|
+
}, [selectedLayerTargets]);
|
|
15649
|
+
|
|
15631
15650
|
const selectedLayerSelectorGroupsByScreen = useMemo(() => {
|
|
15632
15651
|
const groupsByScreen: Record<string, string[][]> = {};
|
|
15633
15652
|
selectedLayerTargets.forEach((target) => {
|
|
@@ -16017,19 +16036,24 @@ function DesignEditor() {
|
|
|
16017
16036
|
|
|
16018
16037
|
// ── Preview, publish waitlist, gradient, interaction states ────────────────
|
|
16019
16038
|
const handleOpenDesignPreview = useCallback(() => {
|
|
16020
|
-
|
|
16021
|
-
|
|
16022
|
-
|
|
16039
|
+
let previewUrl = activeScreenPreviewUrl;
|
|
16040
|
+
let blobUrl: string | null = null;
|
|
16041
|
+
if (!previewUrl) {
|
|
16042
|
+
if (!activeContent.trim()) return;
|
|
16043
|
+
blobUrl = URL.createObjectURL(
|
|
16044
|
+
new Blob([fullPreviewHtml(activeContent)], { type: "text/html" }),
|
|
16045
|
+
);
|
|
16046
|
+
previewUrl = blobUrl;
|
|
16023
16047
|
}
|
|
16024
16048
|
|
|
16025
|
-
|
|
16026
|
-
|
|
16027
|
-
|
|
16028
|
-
|
|
16029
|
-
new Blob([fullPreviewHtml(activeContent)], { type: "text/html" }),
|
|
16049
|
+
openPreviewUrl(
|
|
16050
|
+
previewUrl,
|
|
16051
|
+
(url, target) => window.open(url, target),
|
|
16052
|
+
(url) => window.location.assign(url),
|
|
16030
16053
|
);
|
|
16031
|
-
|
|
16032
|
-
|
|
16054
|
+
if (blobUrl) {
|
|
16055
|
+
window.setTimeout(() => URL.revokeObjectURL(blobUrl!), 60_000);
|
|
16056
|
+
}
|
|
16033
16057
|
}, [activeContent, activeScreenPreviewUrl]);
|
|
16034
16058
|
|
|
16035
16059
|
const handleJoinPublishWaitlist = useCallback(async () => {
|
|
@@ -17868,7 +17892,7 @@ function DesignEditor() {
|
|
|
17868
17892
|
}),
|
|
17869
17893
|
);
|
|
17870
17894
|
setActiveFileId(pickedId);
|
|
17871
|
-
setActiveTool(
|
|
17895
|
+
setActiveTool(resolveToolAfterSelection);
|
|
17872
17896
|
setMode("edit");
|
|
17873
17897
|
if (activeBreakpointWidthStateRef.current !== undefined) {
|
|
17874
17898
|
handleBreakpointBarSelect(undefined);
|
|
@@ -19006,10 +19030,13 @@ function DesignEditor() {
|
|
|
19006
19030
|
onRequestTweaks: handleRequestTweaks,
|
|
19007
19031
|
onStyleChange: handleStyleChange,
|
|
19008
19032
|
onStylesChange: handleStylesChange,
|
|
19009
|
-
motionKeyframeState
|
|
19010
|
-
|
|
19011
|
-
? handleToggleMotionKeyframe
|
|
19033
|
+
motionKeyframeState: SHOW_DESIGN_SECONDARY_LEFT_PANELS
|
|
19034
|
+
? motionKeyframeState
|
|
19012
19035
|
: undefined,
|
|
19036
|
+
onToggleMotionKeyframe:
|
|
19037
|
+
SHOW_DESIGN_SECONDARY_LEFT_PANELS && canEditDesign
|
|
19038
|
+
? handleToggleMotionKeyframe
|
|
19039
|
+
: undefined,
|
|
19013
19040
|
breakpointContext,
|
|
19014
19041
|
onExport: handleInspectorExport,
|
|
19015
19042
|
onRenderExportPreview: handleRenderExportPreview,
|
|
@@ -19082,15 +19109,23 @@ function DesignEditor() {
|
|
|
19082
19109
|
: undefined
|
|
19083
19110
|
}
|
|
19084
19111
|
motionOpen={motionDockOpen}
|
|
19085
|
-
motionDisabled={!activeFile}
|
|
19112
|
+
motionDisabled={!activeFile || initialGenerationChromeLimited}
|
|
19086
19113
|
projectMenu={hostEmbeddedEditor ? null : projectMenu}
|
|
19087
19114
|
onMotionToggle={() => setMotionDockOpenAnimated(!motionDockOpen)}
|
|
19088
|
-
onPanelChange={
|
|
19115
|
+
onPanelChange={(panel) => {
|
|
19116
|
+
if (panel === null && initialGenerationChromeLimited) return;
|
|
19117
|
+
setActiveLeftPanel(panel);
|
|
19118
|
+
}}
|
|
19089
19119
|
/>
|
|
19090
19120
|
<div
|
|
19091
19121
|
ref={leftSidebarContentRef}
|
|
19092
|
-
|
|
19093
|
-
|
|
19122
|
+
aria-hidden={activeLeftPanel === null}
|
|
19123
|
+
className={cn(
|
|
19124
|
+
"flex min-h-0 max-w-[calc(100dvw-57px)] shrink-0 flex-col overflow-hidden border-r border-[var(--design-editor-panel-divider-color)] bg-[var(--design-editor-panel-bg)] transition-[width] duration-150 ease-out md:max-w-none",
|
|
19125
|
+
activeLeftPanel === null &&
|
|
19126
|
+
"pointer-events-none invisible border-r-0",
|
|
19127
|
+
)}
|
|
19128
|
+
style={{ width: activeLeftPanel ? leftContentWidth : 0 }}
|
|
19094
19129
|
>
|
|
19095
19130
|
<div
|
|
19096
19131
|
className={cn(
|
|
@@ -19324,13 +19359,15 @@ function DesignEditor() {
|
|
|
19324
19359
|
</>
|
|
19325
19360
|
) : null}
|
|
19326
19361
|
</div>
|
|
19327
|
-
|
|
19328
|
-
|
|
19329
|
-
|
|
19330
|
-
|
|
19331
|
-
|
|
19332
|
-
|
|
19333
|
-
|
|
19362
|
+
{activeLeftPanel ? (
|
|
19363
|
+
<div
|
|
19364
|
+
role="separator"
|
|
19365
|
+
aria-orientation="vertical"
|
|
19366
|
+
aria-label={t("layersPanel.title")}
|
|
19367
|
+
className="absolute right-[-2px] top-0 z-[80] h-full w-1 cursor-col-resize bg-transparent transition-colors hover:bg-[var(--design-editor-selection-color)]"
|
|
19368
|
+
onPointerDown={(event) => startSidebarResize("left", event)}
|
|
19369
|
+
/>
|
|
19370
|
+
) : null}
|
|
19334
19371
|
</div>
|
|
19335
19372
|
) : null}
|
|
19336
19373
|
|
|
@@ -19349,6 +19386,7 @@ function DesignEditor() {
|
|
|
19349
19386
|
pinMode={pinMode}
|
|
19350
19387
|
drawMode={drawMode}
|
|
19351
19388
|
activeTool={activeTool}
|
|
19389
|
+
shapeTool={shapeTool}
|
|
19352
19390
|
isOverview={viewMode === "overview"}
|
|
19353
19391
|
hasActiveFile={Boolean(activeFile)}
|
|
19354
19392
|
onMove={handleMoveTool}
|
|
@@ -19458,9 +19496,8 @@ function DesignEditor() {
|
|
|
19458
19496
|
(selectedScreenIds.length > 0 && files.length > 1)),
|
|
19459
19497
|
)}
|
|
19460
19498
|
canReorder={canEditDesign && Boolean(selectedElement)}
|
|
19461
|
-
//
|
|
19462
|
-
//
|
|
19463
|
-
// flow lives elsewhere (the title control), not this menu.
|
|
19499
|
+
// Rename is only offered for a single selectable layer target;
|
|
19500
|
+
// design-title rename lives in the title control, not this menu.
|
|
19464
19501
|
canRename={
|
|
19465
19502
|
canEditDesign && Boolean(getSingleSelectedRenamableLayerId())
|
|
19466
19503
|
}
|
|
@@ -19813,6 +19850,7 @@ function DesignEditor() {
|
|
|
19813
19850
|
cameraCommand={cameraCommand}
|
|
19814
19851
|
activeId={activeFileId}
|
|
19815
19852
|
selectedScreenIds={overviewSelectedScreenIds}
|
|
19853
|
+
selectedElementScreenId={selectedElementScreenId}
|
|
19816
19854
|
hiddenScreenIds={hiddenLayerIds}
|
|
19817
19855
|
lockedScreenIds={lockedLayerIds}
|
|
19818
19856
|
fullViewScreenIds={fullViewScreenIds}
|
|
@@ -20467,7 +20505,11 @@ function DesignEditor() {
|
|
|
20467
20505
|
closing. Canvas remains visible above.
|
|
20468
20506
|
Preview-only scrubbing fires a motion-preview postMessage to the
|
|
20469
20507
|
canvas iframe; track/duration edits autosave through apply-motion-edit. */}
|
|
20470
|
-
{!hostOwnsChrome &&
|
|
20508
|
+
{!hostOwnsChrome &&
|
|
20509
|
+
SHOW_DESIGN_SECONDARY_LEFT_PANELS &&
|
|
20510
|
+
!initialGenerationChromeLimited &&
|
|
20511
|
+
activeFile &&
|
|
20512
|
+
motionDockMounted ? (
|
|
20471
20513
|
<MotionDock
|
|
20472
20514
|
tracks={motionTracks}
|
|
20473
20515
|
durationMs={motionDurationMs}
|
|
@@ -61,6 +61,8 @@ type OtherSource =
|
|
|
61
61
|
| "existing"
|
|
62
62
|
| "notes";
|
|
63
63
|
|
|
64
|
+
type BuilderIndexInputSource = "figma" | "github" | "design-md";
|
|
65
|
+
|
|
64
66
|
interface BuilderIndexResult {
|
|
65
67
|
ok: boolean;
|
|
66
68
|
source: "builder";
|
|
@@ -151,6 +153,8 @@ export default function DesignSystemSetup() {
|
|
|
151
153
|
const [builderIndexing, setBuilderIndexing] = useState(false);
|
|
152
154
|
const [builderIndexResult, setBuilderIndexResult] =
|
|
153
155
|
useState<BuilderIndexResult | null>(null);
|
|
156
|
+
const [builderIndexInputSource, setBuilderIndexInputSource] =
|
|
157
|
+
useState<BuilderIndexInputSource | null>(null);
|
|
154
158
|
const [builderIndexError, setBuilderIndexError] = useState<string | null>(
|
|
155
159
|
null,
|
|
156
160
|
);
|
|
@@ -222,6 +226,7 @@ export default function DesignSystemSetup() {
|
|
|
222
226
|
}
|
|
223
227
|
setBuilderIndexError(null);
|
|
224
228
|
setBuilderIndexResult(null);
|
|
229
|
+
setBuilderIndexInputSource("figma");
|
|
225
230
|
stopDecodePolling();
|
|
226
231
|
setDecodeStatus(null);
|
|
227
232
|
setBuilderIndexing(true);
|
|
@@ -550,7 +555,7 @@ export default function DesignSystemSetup() {
|
|
|
550
555
|
if (isGithubOnlySource) {
|
|
551
556
|
setValidationError(null);
|
|
552
557
|
try {
|
|
553
|
-
await indexSystemMutation.mutateAsync({
|
|
558
|
+
const result = await indexSystemMutation.mutateAsync({
|
|
554
559
|
projectName: companyInfo.trim() || undefined,
|
|
555
560
|
description:
|
|
556
561
|
[notes.trim(), customInstructions.trim()]
|
|
@@ -562,8 +567,9 @@ export default function DesignSystemSetup() {
|
|
|
562
567
|
...(link.include?.length ? { include: link.include } : {}),
|
|
563
568
|
})),
|
|
564
569
|
});
|
|
570
|
+
setBuilderIndexInputSource("github");
|
|
571
|
+
setBuilderIndexResult(result);
|
|
565
572
|
toast.success(t("designSystemSetup.githubIndexStarted"));
|
|
566
|
-
navigate("/design-systems");
|
|
567
573
|
} catch (error) {
|
|
568
574
|
setValidationError(
|
|
569
575
|
error instanceof Error
|
|
@@ -603,7 +609,7 @@ export default function DesignSystemSetup() {
|
|
|
603
609
|
if (isDesignMdOnlySource) {
|
|
604
610
|
setValidationError(null);
|
|
605
611
|
try {
|
|
606
|
-
await indexSystemMutation.mutateAsync({
|
|
612
|
+
const result = await indexSystemMutation.mutateAsync({
|
|
607
613
|
projectName: companyInfo.trim() || undefined,
|
|
608
614
|
description:
|
|
609
615
|
[notes.trim(), customInstructions.trim()]
|
|
@@ -611,8 +617,9 @@ export default function DesignSystemSetup() {
|
|
|
611
617
|
.join("\n\n") || undefined,
|
|
612
618
|
designMd: readableDesignMdFiles[0]?.textContent,
|
|
613
619
|
});
|
|
620
|
+
setBuilderIndexInputSource("design-md");
|
|
621
|
+
setBuilderIndexResult(result);
|
|
614
622
|
toast.success(t("designSystemSetup.designMdIndexStarted"));
|
|
615
|
-
navigate("/design-systems");
|
|
616
623
|
} catch (error) {
|
|
617
624
|
setValidationError(
|
|
618
625
|
error instanceof Error
|
|
@@ -861,6 +868,23 @@ export default function DesignSystemSetup() {
|
|
|
861
868
|
</div>
|
|
862
869
|
)}
|
|
863
870
|
|
|
871
|
+
{builderIndexResult && builderIndexInputSource !== "figma" ? (
|
|
872
|
+
<div className="mb-6">
|
|
873
|
+
<BuilderIndexPreview
|
|
874
|
+
result={builderIndexResult}
|
|
875
|
+
decodeStatus={null}
|
|
876
|
+
source={builderIndexInputSource ?? "design-md"}
|
|
877
|
+
displayTitle={companyInfo.trim()}
|
|
878
|
+
onReset={() => {
|
|
879
|
+
setDecodeStatus(null);
|
|
880
|
+
setBuilderIndexResult(null);
|
|
881
|
+
setBuilderIndexInputSource(null);
|
|
882
|
+
setBuilderIndexError(null);
|
|
883
|
+
}}
|
|
884
|
+
/>
|
|
885
|
+
</div>
|
|
886
|
+
) : null}
|
|
887
|
+
|
|
864
888
|
<div className="space-y-5">
|
|
865
889
|
<section className="rounded-lg border border-border bg-card p-4">
|
|
866
890
|
<div className="mb-3">
|
|
@@ -990,6 +1014,7 @@ export default function DesignSystemSetup() {
|
|
|
990
1014
|
stopDecodePolling();
|
|
991
1015
|
setDecodeStatus(null);
|
|
992
1016
|
setBuilderIndexResult(null);
|
|
1017
|
+
setBuilderIndexInputSource(null);
|
|
993
1018
|
setBuilderIndexError(null);
|
|
994
1019
|
}}
|
|
995
1020
|
/>
|
|
@@ -1596,32 +1621,38 @@ function FileList({
|
|
|
1596
1621
|
function BuilderIndexPreview({
|
|
1597
1622
|
result,
|
|
1598
1623
|
decodeStatus,
|
|
1624
|
+
source = "figma",
|
|
1599
1625
|
displayTitle,
|
|
1600
1626
|
onReset,
|
|
1601
1627
|
}: {
|
|
1602
1628
|
result: BuilderIndexResult;
|
|
1603
1629
|
decodeStatus: DecodeJobStatus | null;
|
|
1630
|
+
source?: BuilderIndexInputSource;
|
|
1604
1631
|
displayTitle?: string;
|
|
1605
1632
|
onReset: () => void;
|
|
1606
1633
|
}) {
|
|
1607
1634
|
const t = useT();
|
|
1608
1635
|
const decodeError =
|
|
1609
1636
|
decodeStatus?.status === "error" ? decodeStatus.error : null;
|
|
1637
|
+
const SourceIcon =
|
|
1638
|
+
source === "figma"
|
|
1639
|
+
? IconBrandFigma
|
|
1640
|
+
: source === "github"
|
|
1641
|
+
? IconBrandGithub
|
|
1642
|
+
: IconFileDescription;
|
|
1610
1643
|
|
|
1611
1644
|
return (
|
|
1612
1645
|
<div className="space-y-4 rounded-xl border border-border bg-card p-4">
|
|
1613
1646
|
<div className="flex items-start gap-3">
|
|
1614
1647
|
<div className="flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-[#609FF8]/10">
|
|
1615
|
-
<
|
|
1648
|
+
<SourceIcon className="h-5 w-5 text-[var(--design-editor-accent-color)]" />
|
|
1616
1649
|
</div>
|
|
1617
1650
|
<div className="min-w-0 flex-1">
|
|
1618
1651
|
<h3 className="text-sm font-semibold text-foreground">
|
|
1619
1652
|
{displayTitle || result.suggestedTitle}
|
|
1620
1653
|
</h3>
|
|
1621
1654
|
<p className="mt-1 text-xs leading-relaxed text-muted-foreground">
|
|
1622
|
-
{
|
|
1623
|
-
"Builder is indexing this Figma file into a reusable design system." /* i18n-ignore Builder indexing status */
|
|
1624
|
-
}
|
|
1655
|
+
{t("designSystemSetup.figmaParsingDescription")}
|
|
1625
1656
|
</p>
|
|
1626
1657
|
</div>
|
|
1627
1658
|
</div>
|