@agent-native/core-corpus 0.214.0 → 0.217.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/corpus/README.md +1 -1
- package/corpus/templates/analytics/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/analytics/.agents/skills/session-replay/SKILL.md +61 -1
- package/corpus/templates/analytics/AGENTS.md +1 -1
- package/corpus/templates/analytics/CHANGELOG.md +2 -0
- package/corpus/templates/analytics/actions/get-session-replay-summary.ts +9 -65
- package/corpus/templates/analytics/actions/list-event-catalog.ts +1 -1
- package/corpus/templates/analytics/actions/list-session-outputs.ts +40 -0
- package/corpus/templates/analytics/actions/list-session-recordings.ts +17 -4
- package/corpus/templates/analytics/actions/view-screen.ts +29 -3
- package/corpus/templates/analytics/app/i18n/en-US.ts +27 -0
- package/corpus/templates/analytics/app/pages/sessions/EventCatalogPage.tsx +18 -1
- package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +3 -1
- package/corpus/templates/analytics/app/pages/sessions/SessionOutputs.tsx +197 -0
- package/corpus/templates/analytics/app/pages/sessions/SessionsTriagePage.tsx +114 -4
- package/corpus/templates/analytics/changelog/2026-10-15-sessions-can-find-people-who-made-a-slides-deck-but-didn-t-p.md +6 -0
- package/corpus/templates/analytics/changelog/2026-10-16-the-activation-funnel-counts-visitors-who-decline-analytics-.md +6 -0
- package/corpus/templates/analytics/changelog/2026-10-21-session-replay-quotas-count-the-compressed-size-analytics-st.md +6 -0
- package/corpus/templates/analytics/server/db/schema.ts +67 -0
- package/corpus/templates/analytics/server/lib/canonical-first-party-dashboard-repair.ts +9 -0
- package/corpus/templates/analytics/server/lib/first-party-analytics.ts +28 -22
- package/corpus/templates/analytics/server/lib/first-party-metric-catalog.ts +36 -1
- package/corpus/templates/analytics/server/lib/output-outcomes.ts +712 -0
- package/corpus/templates/analytics/server/lib/replay-origins.ts +33 -0
- package/corpus/templates/analytics/server/lib/session-event-index.ts +20 -0
- package/corpus/templates/analytics/server/lib/session-performance.ts +6 -40
- package/corpus/templates/analytics/server/lib/session-recording-associations.ts +30 -1
- package/corpus/templates/analytics/server/lib/session-replay-triage.ts +99 -0
- package/corpus/templates/analytics/server/lib/session-replay.ts +85 -40
- package/corpus/templates/analytics/server/lib/sessions-triage-lab.ts +8 -2
- package/corpus/templates/analytics/server/plugins/db.ts +46 -0
- package/corpus/templates/analytics/shared/output-use.ts +205 -0
- package/corpus/templates/analytics/shared/session-events.ts +6 -0
- package/corpus/templates/assets/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/brain/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/calendar/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/calendar/CHANGELOG.md +6 -0
- package/corpus/templates/calendar/actions/create-event.ts +2 -4
- package/corpus/templates/calendar/actions/update-event.ts +35 -6
- package/corpus/templates/calendar/changelog/2026-10-21-solo-events-avoid-notification-approval.md +6 -0
- package/corpus/templates/chat/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/clips/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/community/qr/package.json +1 -1
- package/corpus/templates/content/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/content/.agents/skills/content-product-development/references/verification.md +36 -0
- package/corpus/templates/content/.agents/skills/document-editing/SKILL.md +10 -0
- package/corpus/templates/content/.agents/skills/document-editing/references/databases.md +17 -3
- package/corpus/templates/content/.agents/skills/notion-integration/SKILL.md +4 -2
- package/corpus/templates/content/CHANGELOG.md +54 -0
- package/corpus/templates/content/acceptance/_writers.ts +604 -0
- package/corpus/templates/content/acceptance/generate-action-registry.ts +10 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/create-document.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/duplicate-page.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/edit-document-find-and-replace-without-a-revision.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/edit-document-find-and-replace.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/edit-document-initializecontent.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/import-content.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/local-files-import-content-source-existing-page.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/local-files-import-content-source-new-page.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/local-files-sync-local-folder-source-changed-file.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/local-files-sync-local-folder-source-new-file.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/restore-document-version.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/set-document-property-primary-blocks-field.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/set-image-alt-text.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/undo-content-import.json +75 -0
- package/corpus/templates/content/acceptance/golden/gate-off-stored-bytes/update-document-browser-full-rewrite.json +75 -0
- package/corpus/templates/content/acceptance/known-loss.ts +69 -0
- package/corpus/templates/content/acceptance/round-trip-corpus.ts +1397 -0
- package/corpus/templates/content/actions/_blocks-field-identity.ts +35 -1
- package/corpus/templates/content/actions/_browser-document-save-attempt.ts +23 -1
- package/corpus/templates/content/actions/_builder-cms-blob-custody.ts +467 -0
- package/corpus/templates/content/actions/_builder-cms-execution-lease.ts +17 -0
- package/corpus/templates/content/actions/_builder-cms-intent-lookup.ts +5 -0
- package/corpus/templates/content/actions/_builder-cms-read-client.ts +881 -21
- package/corpus/templates/content/actions/_builder-cms-write-adapter.ts +28 -2
- package/corpus/templates/content/actions/_builder-cms-write-client.ts +109 -11
- package/corpus/templates/content/actions/_builder-docs-client.ts +1 -0
- package/corpus/templates/content/actions/_builder-private-blob.test-fixture.ts +90 -0
- package/corpus/templates/content/actions/_builder-source-execution-guard.ts +48 -0
- package/corpus/templates/content/actions/_content-database-lifecycle.ts +11 -11
- package/corpus/templates/content/actions/_content-database-personal-view.ts +2 -0
- package/corpus/templates/content/actions/_content-favorites.ts +37 -0
- package/corpus/templates/content/actions/_content-save-outcomes.ts +5 -0
- package/corpus/templates/content/actions/_database-membership-lock.ts +39 -8
- package/corpus/templates/content/actions/_database-navigation.ts +19 -21
- package/corpus/templates/content/actions/_database-row-batch.ts +41 -18
- package/corpus/templates/content/actions/_database-row-mutation.ts +17 -28
- package/corpus/templates/content/actions/_database-source-utils.ts +308 -9
- package/corpus/templates/content/actions/_database-utils.ts +96 -7
- package/corpus/templates/content/actions/_database-view-setup.ts +37 -2
- package/corpus/templates/content/actions/_delete-content-space.ts +8 -1
- package/corpus/templates/content/actions/_document-edit-mutation.ts +33 -32
- package/corpus/templates/content/actions/_document-flush.ts +593 -171
- package/corpus/templates/content/actions/_document-save-locks.ts +54 -0
- package/corpus/templates/content/actions/_document-save-row.ts +133 -0
- package/corpus/templates/content/actions/_github-source-freshness.ts +30 -4
- package/corpus/templates/content/actions/_github-source.ts +18 -8
- package/corpus/templates/content/actions/_move-page-to-space.ts +189 -25
- package/corpus/templates/content/actions/_nfm-syntax.ts +2 -0
- package/corpus/templates/content/actions/_row-lock-order.ts +115 -0
- package/corpus/templates/content/actions/add-content-database-source-field-property.ts +23 -6
- package/corpus/templates/content/actions/cancel-prepared-builder-source-update.ts +110 -26
- package/corpus/templates/content/actions/change-content-database-source-role.ts +51 -7
- package/corpus/templates/content/actions/create-content-database.ts +11 -0
- package/corpus/templates/content/actions/create-document.ts +13 -1
- package/corpus/templates/content/actions/delete-content-database.ts +17 -14
- package/corpus/templates/content/actions/delete-document-property.ts +5 -0
- package/corpus/templates/content/actions/delete-document.ts +311 -100
- package/corpus/templates/content/actions/disconnect-content-database-source.ts +68 -2
- package/corpus/templates/content/actions/disconnect-local-folder-source.ts +33 -2
- package/corpus/templates/content/actions/edit-document.ts +18 -5
- package/corpus/templates/content/actions/execute-builder-source-execution.ts +900 -140
- package/corpus/templates/content/actions/export-document.ts +3 -0
- package/corpus/templates/content/actions/get-blocks-field-word-count.ts +22 -5
- package/corpus/templates/content/actions/get-document.ts +2 -0
- package/corpus/templates/content/actions/import-content-source.ts +170 -54
- package/corpus/templates/content/actions/move-document.ts +191 -73
- package/corpus/templates/content/actions/permanently-delete-document.ts +6 -0
- package/corpus/templates/content/actions/prepare-builder-source-execution.ts +155 -13
- package/corpus/templates/content/actions/prepare-builder-source-review.ts +299 -73
- package/corpus/templates/content/actions/pull-document.ts +8 -2
- package/corpus/templates/content/actions/remove-database-items.ts +23 -4
- package/corpus/templates/content/actions/restore-content-database.ts +76 -55
- package/corpus/templates/content/actions/restore-document-version.ts +19 -35
- package/corpus/templates/content/actions/restore-document.ts +65 -53
- package/corpus/templates/content/actions/rollback-created-slash-document.ts +11 -16
- package/corpus/templates/content/actions/set-document-property.ts +15 -1
- package/corpus/templates/content/actions/set-live-body-switch.ts +45 -0
- package/corpus/templates/content/actions/share-local-file-document.ts +18 -14
- package/corpus/templates/content/actions/suggest-document-edit.ts +2 -3
- package/corpus/templates/content/actions/sync-local-folder-source.ts +35 -1
- package/corpus/templates/content/actions/undo-content-import.ts +16 -12
- package/corpus/templates/content/actions/update-content-database-view.ts +2 -0
- package/corpus/templates/content/actions/update-document.ts +158 -34
- package/corpus/templates/content/actions/validate-builder-source-execution.ts +135 -26
- package/corpus/templates/content/app/components/editor/BubbleToolbar.tsx +1 -6
- package/corpus/templates/content/app/components/editor/CommentsSidebar.tsx +49 -3
- package/corpus/templates/content/app/components/editor/ContentImportDialog.tsx +2 -0
- package/corpus/templates/content/app/components/editor/DocumentBlockFields.tsx +53 -11
- package/corpus/templates/content/app/components/editor/DocumentEditor.tsx +608 -353
- package/corpus/templates/content/app/components/editor/StaticDocumentBody.tsx +765 -0
- package/corpus/templates/content/app/components/editor/VisualEditor.tsx +233 -80
- package/corpus/templates/content/app/components/editor/blockFieldSaveController.ts +32 -3
- package/corpus/templates/content/app/components/editor/blockFieldSaveRegistry.ts +88 -23
- package/corpus/templates/content/app/components/editor/comment-anchors.ts +19 -0
- package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +228 -71
- package/corpus/templates/content/app/components/editor/database/GitHubSourceStatusLine.tsx +27 -2
- package/corpus/templates/content/app/components/editor/database/ListItemLayout.tsx +32 -8
- package/corpus/templates/content/app/components/editor/database/ListItemRow.tsx +27 -2
- package/corpus/templates/content/app/components/editor/database-sources/BuilderSourceReviewDialog.tsx +1 -0
- package/corpus/templates/content/app/components/editor/document-flush-participant.ts +253 -0
- package/corpus/templates/content/app/components/editor/editor-transaction-meta.ts +28 -0
- package/corpus/templates/content/app/components/editor/extensions/AudioBlock.tsx +2 -1
- package/corpus/templates/content/app/components/editor/extensions/ImageBlock.tsx +27 -6
- package/corpus/templates/content/app/components/editor/extensions/LocalMdxComponentNode.tsx +0 -1
- package/corpus/templates/content/app/components/editor/extensions/NotionExtensions.tsx +4 -4
- package/corpus/templates/content/app/components/editor/extensions/SuggestionHighlight.ts +24 -2
- package/corpus/templates/content/app/components/editor/extensions/VideoBlock.tsx +25 -6
- package/corpus/templates/content/app/components/editor/pending-document-persistence.ts +59 -1
- package/corpus/templates/content/app/components/editor/stored-body-images.ts +27 -0
- package/corpus/templates/content/app/components/editor/suggestions/presentation-rebase.ts +17 -0
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +11 -4
- package/corpus/templates/content/app/components/trash/TrashBrowser.tsx +4 -1
- package/corpus/templates/content/app/global.css +21 -0
- package/corpus/templates/content/app/hooks/use-content-database.ts +40 -2
- package/corpus/templates/content/app/hooks/use-content-trash.ts +8 -0
- package/corpus/templates/content/app/hooks/use-documents.ts +14 -0
- package/corpus/templates/content/app/i18n-data.ts +1 -0
- package/corpus/templates/content/app/import-messages.ts +25 -0
- package/corpus/templates/content/app/trash-messages.ts +16 -0
- package/corpus/templates/content/changelog/2026-10-16-a-page-open-in-a-tab-that-shows-it-s-in-the-trash-reopens-wi.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-a-page-restored-from-trash-returns-to-its-place-in-its-colle.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-agent-written-markdown-keeps-nested-lists-indented-with-spac.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-opening-a-page-you-can-edit-no-longer-rebuilds-its-editor-on.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-pages-moved-or-imported-at-the-same-time-can-no-longer-end-u.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-re-importing-a-markdown-export-of-a-page-no-longer-reports-t.md +6 -0
- package/corpus/templates/content/changelog/2026-10-16-saving-a-page-or-restoring-one-of-its-versions-no-longer-fai.md +6 -0
- package/corpus/templates/content/changelog/2026-10-17-agents-reading-a-page-you-have-open-no-longer-wait-or-fail-w.md +6 -0
- package/corpus/templates/content/changelog/2026-10-17-builder-content-avoids-retrying-a-write-when-builder-accepte.md +6 -0
- package/corpus/templates/content/changelog/2026-10-18-link-a-new-collection-to-a-github-folder-from-its-sources.md +1 -1
- package/corpus/templates/content/changelog/2026-10-19-fresh-document-reads-require-confirmation-from-every-open-ed.md +6 -0
- package/corpus/templates/content/changelog/2026-10-20-builder-content-sync-keeps-read-and-write-status-accurate-wh.md +6 -0
- package/corpus/templates/content/changelog/2026-10-20-html-table-cells-preserve-a-trailing-backslash-when-opening-.md +6 -0
- package/corpus/templates/content/changelog/2026-10-20-preserve-empty-paragraph-colors-and-refuse-unsupported-inlin.md +6 -0
- package/corpus/templates/content/changelog/2026-10-20-the-advanced-filter-and-each-filter-group-inside-it-have-the.md +6 -0
- package/corpus/templates/content/changelog/2026-10-21-blocks-fields-keep-unconfirmed-saves-visible-and-agent-reads.md +6 -0
- package/corpus/templates/content/changelog/2026-10-21-list-rows-can-show-each-pages-first-lines.md +6 -0
- package/corpus/templates/content/changelog/2026-10-21-preserve-compact-table-row-groups-and-report-invalid-block-colors.md +6 -0
- package/corpus/templates/content/changelog/2026-10-21-suggested-edits-show-an-agent-s-whole-reason-open-a-group-to.md +6 -0
- package/corpus/templates/content/changelog/2026-10-21-suggestions-keep-refusing-unmatched-emphasis-in-stored-markd.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-a-collection-linked-to-a-big-github-folder-fills-faster-and-p.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-accept-remaining-and-reject-remaining-show-the-result-for-ev.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-accepting-a-group-of-suggested-edits-saves-faster-and-adds-o.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-agents-read-saved-page-text-after-failed-icon-change.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-changes-made-from-a-menu-or-popover-such-as-an-image-s-alt-t.md +6 -0
- package/corpus/templates/content/changelog/2026-10-22-text-an-agent-writes-inside-a-callout-column-or-synced-block.md +6 -0
- package/corpus/templates/content/docs/product/capabilities/content.source.adapters.md +29 -0
- package/corpus/templates/content/e2e/auth-files.ts +28 -0
- package/corpus/templates/content/e2e/convergence-summary.ts +84 -29
- package/corpus/templates/content/e2e/gate-arm.ts +15 -0
- package/corpus/templates/content/e2e/global-setup.ts +43 -75
- package/corpus/templates/content/e2e/global-teardown.ts +34 -0
- package/corpus/templates/content/e2e/helpers.ts +598 -92
- package/corpus/templates/content/e2e/live-body-gate.ts +188 -0
- package/corpus/templates/content/e2e/playwright.config.ts +12 -3
- package/corpus/templates/content/e2e/server-identity.ts +47 -0
- package/corpus/templates/content/e2e/stored-form/collab-blocks.ts +123 -0
- package/corpus/templates/content/package.json +1 -1
- package/corpus/templates/content/parity/matrix.md +42 -42
- package/corpus/templates/content/parity/matrix.ts +3 -1
- package/corpus/templates/content/scripts/_stored-form-census-kinds.ts +30 -2
- package/corpus/templates/content/scripts/historical-icon-apply.ts +9 -1
- package/corpus/templates/content/scripts/trace-startup.mjs +460 -133
- package/corpus/templates/content/server/db/exec.ts +58 -0
- package/corpus/templates/content/server/db/schema.ts +21 -0
- package/corpus/templates/content/server/lib/content-trash-purge.ts +222 -144
- package/corpus/templates/content/server/lib/document-metadata-updated-at.ts +43 -1
- package/corpus/templates/content/server/lib/document-revision.ts +23 -0
- package/corpus/templates/content/server/lib/live-body-writer.ts +311 -0
- package/corpus/templates/content/server/lib/notion-sync.ts +63 -29
- package/corpus/templates/content/server/lib/notion.ts +5 -5
- package/corpus/templates/content/server/lib/suggested-edits.ts +357 -230
- package/corpus/templates/content/server/live-copy/binding.ts +31 -0
- package/corpus/templates/content/server/live-copy/bounded-task.d.ts +6 -0
- package/corpus/templates/content/server/live-copy/exec-db.ts +1 -0
- package/corpus/templates/content/server/live-copy/holds.ts +59 -0
- package/corpus/templates/content/server/live-copy/persist.ts +656 -0
- package/corpus/templates/content/server/live-copy/switch.ts +136 -0
- package/corpus/templates/content/server/live-copy/task-names.ts +4 -0
- package/corpus/templates/content/server/live-copy/tasks.ts +183 -0
- package/corpus/templates/content/server/live-copy/write-cause.ts +85 -0
- package/corpus/templates/content/server/live-copy/write.ts +85 -0
- package/corpus/templates/content/server/plugins/builder-private-payload-cleanup.ts +22 -0
- package/corpus/templates/content/server/plugins/collab.ts +3 -0
- package/corpus/templates/content/server/plugins/db.ts +33 -0
- package/corpus/templates/content/server/routes/api/documents/[id]/move.patch.ts +50 -168
- package/corpus/templates/content/shared/api.ts +32 -1
- package/corpus/templates/content/shared/blocks-fields-manifest.ts +106 -0
- package/corpus/templates/content/shared/database-item-layout.ts +54 -22
- package/corpus/templates/content/shared/database-query.ts +192 -30
- package/corpus/templates/content/shared/document-export.ts +12 -14
- package/corpus/templates/content/shared/document-flush-protocol.ts +88 -0
- package/corpus/templates/content/shared/document-intent-merge.ts +16 -9
- package/corpus/templates/content/shared/editor-save-state.ts +97 -0
- package/corpus/templates/content/shared/feature-flags.ts +10 -0
- package/corpus/templates/content/shared/import/markdown.ts +91 -7
- package/corpus/templates/content/shared/import/types.ts +2 -0
- package/corpus/templates/content/shared/inline-math.ts +6 -4
- package/corpus/templates/content/shared/nfm-fidelity.ts +247 -0
- package/corpus/templates/content/shared/nfm.ts +1933 -340
- package/corpus/templates/content/shared/og-description.ts +258 -36
- package/corpus/templates/content/shared/suggestion-diff.ts +13 -0
- package/corpus/templates/content/shared/suggestion-formatting.ts +143 -20
- package/corpus/templates/content/shared/suggestion-text.ts +39 -0
- package/corpus/templates/content/vitest.config.ts +10 -0
- package/corpus/templates/crm/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/design/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/design/.agents/skills/design-templates/SKILL.md +5 -1
- package/corpus/templates/design/.agents/skills/native-effects/SKILL.md +9 -2
- package/corpus/templates/design/.generated/bridge/shader-fill-preview.generated.ts +3 -249
- package/corpus/templates/design/.generated/bridge/shader-runtime.generated.ts +30 -92
- package/corpus/templates/design/AGENTS.md +1 -3
- package/corpus/templates/design/CHANGELOG.md +34 -0
- package/corpus/templates/design/CODE_NATIVE_DESIGN_STUDIO_IMPLEMENTATION_PLAN.md +1 -6
- package/corpus/templates/design/DESIGN-STUDIO-PLAN.md +5 -7
- package/corpus/templates/design/actions/_native-local-export-server.ts +44 -31
- package/corpus/templates/design/actions/_native-render-contexts.ts +76 -21
- package/corpus/templates/design/actions/claim-native-local-export.ts +5 -0
- package/corpus/templates/design/actions/finish-native-local-export.ts +13 -2
- package/corpus/templates/design/actions/get-getting-started.ts +53 -0
- package/corpus/templates/design/actions/get-native-shader-approvals.ts +35 -0
- package/corpus/templates/design/actions/get-shader.ts +134 -219
- package/corpus/templates/design/actions/list-design-extensions.ts +3 -58
- package/corpus/templates/design/actions/request-native-local-export.ts +32 -6
- package/corpus/templates/design/actions/run-design-extension-action.ts +0 -29
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +141 -108
- package/corpus/templates/design/app/components/design/DesignExtensionsPanel.tsx +0 -218
- package/corpus/templates/design/app/components/design/DesignThumbnail.tsx +59 -3
- package/corpus/templates/design/app/components/design/EditPanel.tsx +35 -47
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +242 -62
- package/corpus/templates/design/app/components/design/NativePreviewErrorBoundary.tsx +53 -0
- package/corpus/templates/design/app/components/design/bridge/codegen.ts +18 -3
- package/corpus/templates/design/app/components/design/bridge/native-composition-clock.ts +5 -4
- package/corpus/templates/design/app/components/design/bridge/native-dom.ts +37 -0
- package/corpus/templates/design/app/components/design/bridge/native-intrinsic-image.ts +2 -1
- package/corpus/templates/design/app/components/design/bridge/native-mesh-grid.ts +90 -0
- package/corpus/templates/design/app/components/design/bridge/native-opaque-public-asset.ts +363 -0
- package/corpus/templates/design/app/components/design/bridge/native-opaque-worker-lease.ts +179 -0
- package/corpus/templates/design/app/components/design/bridge/native-preview-geometry.ts +132 -7
- package/corpus/templates/design/app/components/design/bridge/native-preview-policy.ts +4 -0
- package/corpus/templates/design/app/components/design/bridge/native-preview-viewport-transport.ts +378 -0
- package/corpus/templates/design/app/components/design/bridge/native-scene-body-transform.ts +62 -0
- package/corpus/templates/design/app/components/design/bridge/native-scene-presentation-element.ts +10 -0
- package/corpus/templates/design/app/components/design/bridge/native-shader-runtime.bridge.ts +778 -246
- package/corpus/templates/design/app/components/design/bridge/native-source-provider.ts +512 -320
- package/corpus/templates/design/app/components/design/bridge/native-stateful-resource.ts +2 -2
- package/corpus/templates/design/app/components/design/bridge/native-stateless-compute.ts +5 -2
- package/corpus/templates/design/app/components/design/bridge/native-svg-source.ts +11 -1
- package/corpus/templates/design/app/components/design/bridge/native-worker-broker.ts +6 -0
- package/corpus/templates/design/app/components/design/bridge/native-worker-entry.ts +761 -303
- package/corpus/templates/design/app/components/design/bridge/native-worker-fill.ts +16 -6
- package/corpus/templates/design/app/components/design/bridge/native-worker-gpu.ts +854 -91
- package/corpus/templates/design/app/components/design/bridge/native-worker-host.ts +15 -1
- package/corpus/templates/design/app/components/design/bridge/native-worker-input-assets.ts +200 -0
- package/corpus/templates/design/app/components/design/bridge/native-worker-protocol.ts +40 -1
- package/corpus/templates/design/app/components/design/bridge/native-worker-scene-host.ts +540 -161
- package/corpus/templates/design/app/components/design/bridge/native-worker-source-snapshot.ts +21 -0
- package/corpus/templates/design/app/components/design/bridge/shader-fill-preview.bridge.ts +5 -371
- package/corpus/templates/design/app/components/design/bridge/shader-runtime.bridge.ts +45 -150
- package/corpus/templates/design/app/components/design/design-canvas/interact-document.ts +5 -9
- package/corpus/templates/design/app/components/design/design-canvas/native-preview-surface.ts +150 -0
- package/corpus/templates/design/app/components/design/design-canvas/native-public-asset-preview.ts +409 -0
- package/corpus/templates/design/app/components/design/design-canvas/native-public-worker-preview.ts +1086 -0
- package/corpus/templates/design/app/components/design/design-canvas/private-replay-screenshot-preview.ts +2 -2
- package/corpus/templates/design/app/components/design/design-canvas/text-content-change-result.ts +46 -12
- package/corpus/templates/design/app/components/design/edit-panel/effects-properties.tsx +15 -26
- package/corpus/templates/design/app/components/design/edit-panel/fill-properties.tsx +74 -67
- package/corpus/templates/design/app/components/design/edit-panel/panel-primitives.tsx +7 -19
- package/corpus/templates/design/app/components/design/inspector/DesignColorPicker.tsx +39 -30
- package/corpus/templates/design/app/components/design/inspector/GradientEditor.tsx +4 -0
- package/corpus/templates/design/app/components/design/inspector/NativeShaderColorControls.tsx +3 -7
- package/corpus/templates/design/app/components/design/inspector/NativeShaderPaintControls.tsx +12 -5
- package/corpus/templates/design/app/components/design/inspector/NativeShaderPanel.tsx +705 -190
- package/corpus/templates/design/app/components/design/inspector/fill-field-reading.ts +1 -2
- package/corpus/templates/design/app/components/design/inspector/index.ts +0 -6
- package/corpus/templates/design/app/components/design/inspector/native-catalog-display.ts +26 -5
- package/corpus/templates/design/app/components/design/inspector/native-shader-catalog-fixture.ts +42 -0
- package/corpus/templates/design/app/components/design/inspector/native-shader-catalog-preview.ts +51 -33
- package/corpus/templates/design/app/components/design/inspector/native-shader-paint.ts +1 -0
- package/corpus/templates/design/app/components/design/inspector/native-shader-property-draft.ts +89 -23
- package/corpus/templates/design/app/components/design/inspector/saved-glsl-shader.tsx +243 -0
- package/corpus/templates/design/app/components/design/multi-screen/board-surface-html.ts +54 -5
- package/corpus/templates/design/app/components/design/shader-source-coordination.ts +66 -0
- package/corpus/templates/design/app/components/design/use-native-shader-approvals.ts +36 -8
- package/corpus/templates/design/app/components/home/DesignHomeLibrary.tsx +15 -8
- package/corpus/templates/design/app/components/layout/GettingStarted.tsx +50 -0
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +3 -0
- package/corpus/templates/design/app/components/templates/DesignTemplateGrid.tsx +163 -0
- package/corpus/templates/design/app/components/templates/DesignTemplateLibrary.tsx +65 -78
- package/corpus/templates/design/app/components/templates/TemplatePreview.tsx +66 -5
- package/corpus/templates/design/app/global.css +6 -0
- package/corpus/templates/design/app/i18n/en-US.ts +95 -2
- package/corpus/templates/design/app/lib/canvas-load-outcome.ts +147 -0
- package/corpus/templates/design/app/lib/canvas-outcome-tracking.ts +531 -0
- package/corpus/templates/design/app/lib/canvas-style-kind.ts +50 -0
- package/corpus/templates/design/app/pages/Index.tsx +10 -3
- package/corpus/templates/design/app/pages/Present.tsx +36 -1
- package/corpus/templates/design/app/pages/design-editor/commands/apply-file-content-update.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/apply-local-content-update.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/commit-visual-styles.ts +88 -32
- package/corpus/templates/design/app/pages/design-editor/commands/cross-screen-element-drop.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/layer-move-to-screen.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/paste-selection.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/paste-svg-layer.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/prepare-content-history-replay.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/redo.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/render-png-blob.ts +84 -41
- package/corpus/templates/design/app/pages/design-editor/commands/save-file-content.ts +38 -3
- package/corpus/templates/design/app/pages/design-editor/commands/shader-source-edit.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/commands/undo.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/design-editor-view.tsx +0 -2
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-content-and-components.ts +4 -33
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-core.ts +9 -0
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-export-and-handoff.ts +2 -2
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-files-and-saving.ts +2 -0
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-history.ts +0 -11
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-layer-models.ts +2 -55
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-screen-rendering.tsx +0 -3
- package/corpus/templates/design/app/pages/design-editor/domains/use-editor-selection-and-styles.ts +0 -24
- package/corpus/templates/design/app/pages/design-editor/text-edit-utils.ts +0 -16
- package/corpus/templates/design/app/pages/design-editor/use-native-local-export-requests.ts +70 -11
- package/corpus/templates/design/app/pages/design-editor/view/single-screen-canvas.tsx +0 -2
- package/corpus/templates/design/changelog/2026-10-20-folded-mesh-adds-an-animated-sculpted-fill-with-editable-col.md +6 -0
- package/corpus/templates/design/changelog/2026-10-20-read-only-design-views-render-native-shader-previews-in-nest.md +6 -0
- package/corpus/templates/design/changelog/2026-10-20-selected-screens-with-shader-effects-can-be-exported-togethe.md +6 -0
- package/corpus/templates/design/changelog/2026-10-20-shader-previews-reuse-validated-scene-data-while-panning-inc.md +6 -0
- package/corpus/templates/design/changelog/2026-10-20-shader-previews-stay-aligned-while-you-zoom.md +6 -0
- package/corpus/templates/design/changelog/2026-10-20-signed-out-sessions-no-longer-watch-for-private-png-export-r.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-a-getting-started-checklist-at-the-bottom-of-the-sidebar-tra.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-effect-thumbnails-show-richer-previews.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-native-effects-render-across-previews.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-native-shader-previews-use-less-gpu-memory-when-many-mesh-ef.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-opening-design-no-longer-shows-png-export-errors-when-no-exp.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-pulsing-border-controls-grouped.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-pulsing-border-follows-element-outlines.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-remove-obsolete-shader-fills.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-shader-previews-recover-from-temporary-gpu-and-image-failure.md +6 -0
- package/corpus/templates/design/changelog/2026-10-21-templates-now-open-a-read-only-preview-from-the-card-and-the.md +6 -0
- package/corpus/templates/design/changelog/2026-10-22-collapsed-shader-layers-no-longer-interrupt-other-shaders-on.md +6 -0
- package/corpus/templates/design/changelog/2026-10-22-shader-fills-and-effects-render-correctly-on-canvas-elements.md +6 -0
- package/corpus/templates/design/changelog/2026-10-22-shader-fills-keep-rendering-when-other-screen-content-cannot.md +6 -0
- package/corpus/templates/design/package.json +0 -1
- package/corpus/templates/design/playwright.config.ts +1 -1
- package/corpus/templates/design/scripts/design-export-validation/export-baseline.json +24 -0
- package/corpus/templates/design/scripts/runtime-budget-zoom.ts +9 -21
- package/corpus/templates/design/scripts/runtime-budget.ts +10 -24
- package/corpus/templates/design/server/lib/getting-started.ts +267 -0
- package/corpus/templates/design/server/plugins/agent-chat.ts +0 -2
- package/corpus/templates/design/server/plugins/getting-started.ts +5 -0
- package/corpus/templates/design/shared/design-template-presets/analytics-dashboard.ts +127 -0
- package/corpus/templates/design/shared/design-template-presets/design-studio.ts +98 -0
- package/corpus/templates/design/shared/design-template-presets/messaging-app.ts +101 -0
- package/corpus/templates/design/shared/design-template-presets/project-tasks.ts +120 -0
- package/corpus/templates/design/shared/design-template-presets.ts +8 -0
- package/corpus/templates/design/shared/effect-graph.ts +46 -1
- package/corpus/templates/design/shared/generation-output-receipt.ts +0 -1
- package/corpus/templates/design/shared/native-effect-animation-capability.ts +6 -0
- package/corpus/templates/design/shared/native-effect-folded-mesh-v1.ts +268 -0
- package/corpus/templates/design/shared/native-effect-folded-mesh-v2.ts +310 -0
- package/corpus/templates/design/shared/native-effect-folded-mesh.ts +489 -0
- package/corpus/templates/design/shared/native-effect-gallery-additions.ts +2 -2
- package/corpus/templates/design/shared/native-effect-paint.ts +8 -0
- package/corpus/templates/design/shared/native-effect-parameter-constraints.ts +8 -1
- package/corpus/templates/design/shared/native-effect-presets.ts +18 -1
- package/corpus/templates/design/shared/native-effect-property-presentation.ts +81 -0
- package/corpus/templates/design/shared/native-effect-pulsing-border-v3.ts +281 -0
- package/corpus/templates/design/shared/native-effect-pulsing-border-v4.ts +284 -0
- package/corpus/templates/design/shared/native-effect-pulsing-border.ts +300 -0
- package/corpus/templates/design/shared/native-effect-trust.ts +6 -0
- package/corpus/templates/design/shared/native-effect-wgsl.ts +12 -0
- package/corpus/templates/design/shared/native-effects.ts +528 -15
- package/corpus/templates/design/shared/native-input-resources.ts +36 -0
- package/corpus/templates/design/shared/native-local-export.ts +14 -0
- package/corpus/templates/design/shared/native-parameter-animation.ts +1 -0
- package/corpus/templates/design/shared/native-pointer-input.ts +9 -11
- package/corpus/templates/design/shared/shader-fills.ts +0 -513
- package/corpus/templates/design/vitest.setup.ts +7 -1
- package/corpus/templates/dispatch/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/dispatch/.agents/skills/turn-into-app/SKILL.md +20 -18
- package/corpus/templates/factory/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/factory/.agents/skills/review-latest-feedback/SKILL.md +36 -80
- package/corpus/templates/factory/.agents/skills/review-latest-feedback/references/channel-inventory.md +54 -16
- package/corpus/templates/factory/.agents/skills/review-latest-feedback/references/slack-reaction-replies.md +50 -73
- package/corpus/templates/factory/.agents/skills/turn-into-app/SKILL.md +20 -18
- package/corpus/templates/forms/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/forms/server/plugins/agent-chat.ts +1 -1
- package/corpus/templates/mail/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/plan/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/slides/.agents/skills/actions/references/action-fields.md +1 -1
- package/corpus/templates/slides/CHANGELOG.md +6 -0
- package/corpus/templates/slides/actions/delete-deck.ts +7 -0
- package/corpus/templates/slides/changelog/2026-10-21-connected-deck-deletion-requires-approval.md +6 -0
- package/corpus/templates/slides/scripts/edit-fidelity/client-action.ts +61 -0
- package/corpus/templates/slides/scripts/edit-fidelity/run.ts +10 -0
- package/corpus/templates/slides-2/.agents/skills/actions/SKILL.md +199 -0
- package/corpus/templates/slides-2/.agents/skills/actions/references/action-fields.md +145 -0
- package/corpus/templates/slides-2/.agents/skills/actions/references/examples.md +96 -0
- package/corpus/templates/slides-2/.agents/skills/actions/references/provider-apis.md +95 -0
- package/corpus/templates/slides-2/.agents/skills/adding-a-feature/SKILL.md +235 -0
- package/corpus/templates/slides-2/.agents/skills/agent-native-docs/SKILL.md +161 -0
- package/corpus/templates/slides-2/.agents/skills/agent-native-toolkit/SKILL.md +314 -0
- package/corpus/templates/slides-2/.agents/skills/analytics-data-for-decks/SKILL.md +44 -0
- package/corpus/templates/slides-2/.agents/skills/apply-slide-comments/SKILL.md +63 -0
- package/corpus/templates/slides-2/.agents/skills/client-side-routing/SKILL.md +87 -0
- package/corpus/templates/slides-2/.agents/skills/context-awareness/SKILL.md +282 -0
- package/corpus/templates/slides-2/.agents/skills/create-deck/SKILL.md +263 -0
- package/corpus/templates/slides-2/.agents/skills/create-deck/references/reference-inputs.md +72 -0
- package/corpus/templates/slides-2/.agents/skills/create-deck/references/slide-templates.md +93 -0
- package/corpus/templates/slides-2/.agents/skills/create-deck/references/source-material.md +16 -0
- package/corpus/templates/slides-2/.agents/skills/creative-context/SKILL.md +134 -0
- package/corpus/templates/slides-2/.agents/skills/customizing-agent-native/SKILL.md +219 -0
- package/corpus/templates/slides-2/.agents/skills/deck-management/SKILL.md +182 -0
- package/corpus/templates/slides-2/.agents/skills/delegate-to-agent/SKILL.md +62 -0
- package/corpus/templates/slides-2/.agents/skills/design-systems/SKILL.md +233 -0
- package/corpus/templates/slides-2/.agents/skills/external-agents/SKILL.md +549 -0
- package/corpus/templates/slides-2/.agents/skills/external-agents/references/mcp-apps-embedding.md +169 -0
- package/corpus/templates/slides-2/.agents/skills/frontend-design/SKILL.md +102 -0
- package/corpus/templates/slides-2/.agents/skills/frontend-design/references/visual-direction.md +102 -0
- package/corpus/templates/slides-2/.agents/skills/image-generation-via-a2a/SKILL.md +134 -0
- package/corpus/templates/slides-2/.agents/skills/performance/SKILL.md +79 -0
- package/corpus/templates/slides-2/.agents/skills/portability/SKILL.md +108 -0
- package/corpus/templates/slides-2/.agents/skills/real-time-sync/SKILL.md +146 -0
- package/corpus/templates/slides-2/.agents/skills/reliable-mutations/SKILL.md +72 -0
- package/corpus/templates/slides-2/.agents/skills/secrets/SKILL.md +82 -0
- package/corpus/templates/slides-2/.agents/skills/security/SKILL.md +80 -0
- package/corpus/templates/slides-2/.agents/skills/self-modifying-code/SKILL.md +123 -0
- package/corpus/templates/slides-2/.agents/skills/shadcn-ui/SKILL.md +71 -0
- package/corpus/templates/slides-2/.agents/skills/sharing/SKILL.md +286 -0
- package/corpus/templates/slides-2/.agents/skills/slide-design/SKILL.md +144 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/SKILL.md +284 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/references/animations.md +33 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/references/freeform-objects.md +22 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/references/restyling.md +69 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/references/transitions.md +26 -0
- package/corpus/templates/slides-2/.agents/skills/slide-editing/references/video.md +45 -0
- package/corpus/templates/slides-2/.agents/skills/slide-images/SKILL.md +136 -0
- package/corpus/templates/slides-2/.agents/skills/storing-data/SKILL.md +234 -0
- package/corpus/templates/slides-2/.agents/skills/turn-into-skill/SKILL.md +112 -0
- package/corpus/templates/slides-2/.agents/skills/turn-into-skill/agents/openai.yaml +4 -0
- package/corpus/templates/slides-2/.agents/skills/workspace-conventions/SKILL.md +103 -0
- package/corpus/templates/slides-2/.builder/rules/deploy-app.mdc +22 -0
- package/corpus/templates/slides-2/.builder/rules/organize-ui.mdc +9 -0
- package/corpus/templates/slides-2/.dockerignore +61 -0
- package/corpus/templates/slides-2/.env.example +23 -0
- package/corpus/templates/slides-2/.ignore +3 -0
- package/corpus/templates/slides-2/.mcp.json +8 -0
- package/corpus/templates/slides-2/.oxfmtrc.json +8 -0
- package/corpus/templates/slides-2/AGENTS.md +66 -0
- package/corpus/templates/slides-2/CHANGELOG.md +76 -0
- package/corpus/templates/slides-2/DEVELOPING.md +157 -0
- package/corpus/templates/slides-2/README.md +58 -0
- package/corpus/templates/slides-2/THIRD_PARTY_NOTICES.md +33 -0
- package/corpus/templates/slides-2/_gitignore +38 -0
- package/corpus/templates/slides-2/actions/_agent-presence.ts +29 -0
- package/corpus/templates/slides-2/actions/_app-url.ts +37 -0
- package/corpus/templates/slides-2/actions/_deck-app-scope.ts +30 -0
- package/corpus/templates/slides-2/actions/_deck-tracking.ts +260 -0
- package/corpus/templates/slides-2/actions/_deck-write.ts +206 -0
- package/corpus/templates/slides-2/actions/_imported-slide-source.ts +162 -0
- package/corpus/templates/slides-2/actions/_inline-image-storage.ts +1013 -0
- package/corpus/templates/slides-2/actions/_linked-design-system.ts +83 -0
- package/corpus/templates/slides-2/actions/_presenter-notes.ts +83 -0
- package/corpus/templates/slides-2/actions/_render-artifacts.ts +111 -0
- package/corpus/templates/slides-2/actions/_slide-source.ts +344 -0
- package/corpus/templates/slides-2/actions/_tab-state.ts +51 -0
- package/corpus/templates/slides-2/actions/_test-brandfetch.ts +31 -0
- package/corpus/templates/slides-2/actions/_uploaded-files.ts +114 -0
- package/corpus/templates/slides-2/actions/add-deck.ts +123 -0
- package/corpus/templates/slides-2/actions/add-slide-comment.ts +267 -0
- package/corpus/templates/slides-2/actions/add-slide.ts +888 -0
- package/corpus/templates/slides-2/actions/analyze-brand-assets.ts +66 -0
- package/corpus/templates/slides-2/actions/apply-design-system.ts +111 -0
- package/corpus/templates/slides-2/actions/approve-deck-access-request.ts +287 -0
- package/corpus/templates/slides-2/actions/audit-contrast.ts +143 -0
- package/corpus/templates/slides-2/actions/check-image-gen.ts +17 -0
- package/corpus/templates/slides-2/actions/clone-context-slide.ts +340 -0
- package/corpus/templates/slides-2/actions/clone-creative-context-deck.ts +143 -0
- package/corpus/templates/slides-2/actions/control-deck-history.ts +186 -0
- package/corpus/templates/slides-2/actions/control-presenter.ts +117 -0
- package/corpus/templates/slides-2/actions/control-slide-editor.ts +267 -0
- package/corpus/templates/slides-2/actions/create-deck-from-template.ts +274 -0
- package/corpus/templates/slides-2/actions/create-deck.ts +1243 -0
- package/corpus/templates/slides-2/actions/create-design-system.ts +131 -0
- package/corpus/templates/slides-2/actions/create-share-link.ts +127 -0
- package/corpus/templates/slides-2/actions/db-health.ts +22 -0
- package/corpus/templates/slides-2/actions/delete-asset.ts +154 -0
- package/corpus/templates/slides-2/actions/delete-deck.ts +427 -0
- package/corpus/templates/slides-2/actions/delete-design-system.ts +167 -0
- package/corpus/templates/slides-2/actions/delete-slide-comment.ts +143 -0
- package/corpus/templates/slides-2/actions/delete-staged-dataset.ts +30 -0
- package/corpus/templates/slides-2/actions/duplicate-deck.ts +299 -0
- package/corpus/templates/slides-2/actions/export-google-slides.ts +41 -0
- package/corpus/templates/slides-2/actions/export-html.ts +770 -0
- package/corpus/templates/slides-2/actions/export-pptx.ts +2203 -0
- package/corpus/templates/slides-2/actions/extract-pdf.ts +49 -0
- package/corpus/templates/slides-2/actions/generate-image-api.ts +671 -0
- package/corpus/templates/slides-2/actions/generate-image.ts +492 -0
- package/corpus/templates/slides-2/actions/get-agent-access-deck.ts +52 -0
- package/corpus/templates/slides-2/actions/get-deck-access-status.ts +130 -0
- package/corpus/templates/slides-2/actions/get-deck-design-tokens.ts +62 -0
- package/corpus/templates/slides-2/actions/get-deck-reference-context.ts +232 -0
- package/corpus/templates/slides-2/actions/get-deck-template.ts +38 -0
- package/corpus/templates/slides-2/actions/get-deck-version.ts +85 -0
- package/corpus/templates/slides-2/actions/get-deck.ts +562 -0
- package/corpus/templates/slides-2/actions/get-design-system-decode-job-status.ts +57 -0
- package/corpus/templates/slides-2/actions/get-design-system-tier-limit.ts +12 -0
- package/corpus/templates/slides-2/actions/get-design-system.ts +453 -0
- package/corpus/templates/slides-2/actions/get-google-docs-status.ts +106 -0
- package/corpus/templates/slides-2/actions/get-google-picker-token.ts +84 -0
- package/corpus/templates/slides-2/actions/get-home-suggestions.ts +52 -0
- package/corpus/templates/slides-2/actions/get-layout-overflows.ts +192 -0
- package/corpus/templates/slides-2/actions/get-slide-render.ts +125 -0
- package/corpus/templates/slides-2/actions/get-slide-source.ts +115 -0
- package/corpus/templates/slides-2/actions/get-slide-theme-preview.ts +64 -0
- package/corpus/templates/slides-2/actions/get-slide-theme.ts +44 -0
- package/corpus/templates/slides-2/actions/get-slides-2-upload-storage-status.ts +17 -0
- package/corpus/templates/slides-2/actions/get-slides-notification-prefs.ts +37 -0
- package/corpus/templates/slides-2/actions/get-workspace-defaults.ts +51 -0
- package/corpus/templates/slides-2/actions/image-gen-status.ts +35 -0
- package/corpus/templates/slides-2/actions/import-code.ts +26 -0
- package/corpus/templates/slides-2/actions/import-design-project.ts +49 -0
- package/corpus/templates/slides-2/actions/import-document.ts +125 -0
- package/corpus/templates/slides-2/actions/import-docx.ts +57 -0
- package/corpus/templates/slides-2/actions/import-file.ts +1273 -0
- package/corpus/templates/slides-2/actions/import-from-url.ts +25 -0
- package/corpus/templates/slides-2/actions/import-google-doc.ts +208 -0
- package/corpus/templates/slides-2/actions/import-google-font.ts +110 -0
- package/corpus/templates/slides-2/actions/import-google-slides-reference.ts +667 -0
- package/corpus/templates/slides-2/actions/import-pptx.ts +564 -0
- package/corpus/templates/slides-2/actions/import-svgl-logo.ts +115 -0
- package/corpus/templates/slides-2/actions/index-design-system-with-builder.ts +181 -0
- package/corpus/templates/slides-2/actions/index-uploaded-design-system-files.ts +77 -0
- package/corpus/templates/slides-2/actions/list-assets.ts +286 -0
- package/corpus/templates/slides-2/actions/list-deck-templates.ts +83 -0
- package/corpus/templates/slides-2/actions/list-deck-versions.ts +185 -0
- package/corpus/templates/slides-2/actions/list-decks.ts +591 -0
- package/corpus/templates/slides-2/actions/list-design-systems.ts +180 -0
- package/corpus/templates/slides-2/actions/list-slide-comments.ts +128 -0
- package/corpus/templates/slides-2/actions/list-slide-themes.ts +17 -0
- package/corpus/templates/slides-2/actions/list-staged-datasets.ts +14 -0
- package/corpus/templates/slides-2/actions/logo-config.ts +13 -0
- package/corpus/templates/slides-2/actions/navigate.ts +158 -0
- package/corpus/templates/slides-2/actions/patch-deck.ts +2378 -0
- package/corpus/templates/slides-2/actions/provider-api-catalog.ts +25 -0
- package/corpus/templates/slides-2/actions/provider-api-docs.ts +83 -0
- package/corpus/templates/slides-2/actions/provider-api-request.ts +222 -0
- package/corpus/templates/slides-2/actions/query-staged-dataset.ts +83 -0
- package/corpus/templates/slides-2/actions/read-composer-source.ts +108 -0
- package/corpus/templates/slides-2/actions/request-deck-access.ts +803 -0
- package/corpus/templates/slides-2/actions/restore-deck-version.ts +203 -0
- package/corpus/templates/slides-2/actions/run.ts +2 -0
- package/corpus/templates/slides-2/actions/save-deck.ts +313 -0
- package/corpus/templates/slides-2/actions/search-google-fonts.ts +61 -0
- package/corpus/templates/slides-2/actions/search-images.ts +30 -0
- package/corpus/templates/slides-2/actions/search-logos.ts +23 -0
- package/corpus/templates/slides-2/actions/search-svgl-logos.ts +42 -0
- package/corpus/templates/slides-2/actions/set-default-design-system.ts +88 -0
- package/corpus/templates/slides-2/actions/set-workspace-defaults.ts +61 -0
- package/corpus/templates/slides-2/actions/start-design-system-upload.ts +80 -0
- package/corpus/templates/slides-2/actions/sync-design-system-with-builder.ts +84 -0
- package/corpus/templates/slides-2/actions/toggle-slide-comment-reaction.ts +150 -0
- package/corpus/templates/slides-2/actions/transform-slide-objects.ts +1528 -0
- package/corpus/templates/slides-2/actions/update-asset.ts +499 -0
- package/corpus/templates/slides-2/actions/update-deck-aspect-ratio.ts +95 -0
- package/corpus/templates/slides-2/actions/update-deck-design-tokens.ts +175 -0
- package/corpus/templates/slides-2/actions/update-design-system.ts +95 -0
- package/corpus/templates/slides-2/actions/update-slide-comment.ts +213 -0
- package/corpus/templates/slides-2/actions/update-slide-source.ts +353 -0
- package/corpus/templates/slides-2/actions/update-slide.ts +850 -0
- package/corpus/templates/slides-2/actions/update-slides-notification-prefs.ts +55 -0
- package/corpus/templates/slides-2/actions/view-screen.ts +1098 -0
- package/corpus/templates/slides-2/agent-native.app-skill.json +165 -0
- package/corpus/templates/slides-2/agent-native.config.ts +20 -0
- package/corpus/templates/slides-2/agent-native.json +18 -0
- package/corpus/templates/slides-2/app/components/ThemeToggle.tsx +47 -0
- package/corpus/templates/slides-2/app/components/comments/SlideCommentPins.tsx +781 -0
- package/corpus/templates/slides-2/app/components/comments/SlideCommentsPanel.tsx +1075 -0
- package/corpus/templates/slides-2/app/components/deck/DeckCard.tsx +304 -0
- package/corpus/templates/slides-2/app/components/deck/DeckFilterMenu.tsx +83 -0
- package/corpus/templates/slides-2/app/components/deck/ExcalidrawSlide.tsx +183 -0
- package/corpus/templates/slides-2/app/components/deck/MermaidRenderer.tsx +126 -0
- package/corpus/templates/slides-2/app/components/deck/SlideRenderer.tsx +1553 -0
- package/corpus/templates/slides-2/app/components/design-system/DesignSystemCard.tsx +235 -0
- package/corpus/templates/slides-2/app/components/design-system/DesignSystemSetup.tsx +2021 -0
- package/corpus/templates/slides-2/app/components/design-system/builder-design-system-upload.ts +200 -0
- package/corpus/templates/slides-2/app/components/design-system/builder-index-response.ts +104 -0
- package/corpus/templates/slides-2/app/components/editor/AddSlidePopover.tsx +461 -0
- package/corpus/templates/slides-2/app/components/editor/AiEditingMarker.tsx +24 -0
- package/corpus/templates/slides-2/app/components/editor/AlignmentGuides.tsx +82 -0
- package/corpus/templates/slides-2/app/components/editor/AnimationsPanel.tsx +698 -0
- package/corpus/templates/slides-2/app/components/editor/AppMenu.tsx +356 -0
- package/corpus/templates/slides-2/app/components/editor/AssetLibraryPanel.tsx +508 -0
- package/corpus/templates/slides-2/app/components/editor/BlockBubbleMenu.tsx +548 -0
- package/corpus/templates/slides-2/app/components/editor/DeckAccessDeniedPage.tsx +173 -0
- package/corpus/templates/slides-2/app/components/editor/DeckEditorSkeleton.tsx +35 -0
- package/corpus/templates/slides-2/app/components/editor/DeferredPopoverFallback.tsx +148 -0
- package/corpus/templates/slides-2/app/components/editor/EditorActionCluster.tsx +217 -0
- package/corpus/templates/slides-2/app/components/editor/EditorSidebar.tsx +1047 -0
- package/corpus/templates/slides-2/app/components/editor/EditorToolbar.tsx +1285 -0
- package/corpus/templates/slides-2/app/components/editor/ExportMenu.tsx +579 -0
- package/corpus/templates/slides-2/app/components/editor/GeneratingOverlay.tsx +21 -0
- package/corpus/templates/slides-2/app/components/editor/GeneratingSlidePreview.tsx +73 -0
- package/corpus/templates/slides-2/app/components/editor/GoogleDocImportHint.tsx +378 -0
- package/corpus/templates/slides-2/app/components/editor/GoogleDriveConnectionCta.tsx +154 -0
- package/corpus/templates/slides-2/app/components/editor/GoogleSlidesReferenceImport.tsx +299 -0
- package/corpus/templates/slides-2/app/components/editor/HistoryPanel.tsx +354 -0
- package/corpus/templates/slides-2/app/components/editor/HomeQuickStartDialog.tsx +202 -0
- package/corpus/templates/slides-2/app/components/editor/ImageCropOverlay.tsx +820 -0
- package/corpus/templates/slides-2/app/components/editor/ImageDropPromptPopover.tsx +280 -0
- package/corpus/templates/slides-2/app/components/editor/ImageGenPanel.tsx +244 -0
- package/corpus/templates/slides-2/app/components/editor/ImageOverlay.tsx +280 -0
- package/corpus/templates/slides-2/app/components/editor/ImageSearchPanel.tsx +183 -0
- package/corpus/templates/slides-2/app/components/editor/ImportDeckButton.tsx +247 -0
- package/corpus/templates/slides-2/app/components/editor/LogoSearchPanel.tsx +366 -0
- package/corpus/templates/slides-2/app/components/editor/MermaidToExcalidrawPanel.tsx +99 -0
- package/corpus/templates/slides-2/app/components/editor/MissingDeckAccessPane.tsx +219 -0
- package/corpus/templates/slides-2/app/components/editor/NewDeckReferenceStep.tsx +812 -0
- package/corpus/templates/slides-2/app/components/editor/PromptDialog.tsx +963 -0
- package/corpus/templates/slides-2/app/components/editor/QuestionFlow.tsx +119 -0
- package/corpus/templates/slides-2/app/components/editor/RequestDeckAccessDialog.tsx +101 -0
- package/corpus/templates/slides-2/app/components/editor/ShareDialog.tsx +126 -0
- package/corpus/templates/slides-2/app/components/editor/SlideContextToolbar.tsx +1471 -0
- package/corpus/templates/slides-2/app/components/editor/SlideEditor.tsx +11183 -0
- package/corpus/templates/slides-2/app/components/editor/SlideOverflowWarning.tsx +82 -0
- package/corpus/templates/slides-2/app/components/editor/SlideScrollStack.tsx +307 -0
- package/corpus/templates/slides-2/app/components/editor/SlideSlashCommandMenu.tsx +692 -0
- package/corpus/templates/slides-2/app/components/editor/SlideThumbnailContextMenu.tsx +52 -0
- package/corpus/templates/slides-2/app/components/editor/SlideTransitionControl.tsx +184 -0
- package/corpus/templates/slides-2/app/components/editor/SlidesComposerContext.tsx +789 -0
- package/corpus/templates/slides-2/app/components/editor/SlidesComposerContextProvider.tsx +74 -0
- package/corpus/templates/slides-2/app/components/editor/SlidesLayersPanel.tsx +377 -0
- package/corpus/templates/slides-2/app/components/editor/SpeakerNotesPanel.tsx +119 -0
- package/corpus/templates/slides-2/app/components/editor/TweaksPanel.tsx +77 -0
- package/corpus/templates/slides-2/app/components/editor/UploadStorageGate.tsx +37 -0
- package/corpus/templates/slides-2/app/components/editor/bullet-editing.ts +880 -0
- package/corpus/templates/slides-2/app/components/editor/canvas-interactions/index.ts +12 -0
- package/corpus/templates/slides-2/app/components/editor/canvas-interactions/slides-canvas-adapter.ts +119 -0
- package/corpus/templates/slides-2/app/components/editor/commit-active-edit.ts +14 -0
- package/corpus/templates/slides-2/app/components/editor/editor-command-model.ts +35 -0
- package/corpus/templates/slides-2/app/components/editor/fit-text-object.ts +31 -0
- package/corpus/templates/slides-2/app/components/editor/in-place-text-session.browser-cases.json +983 -0
- package/corpus/templates/slides-2/app/components/editor/in-place-text-session.browser-host.ts +747 -0
- package/corpus/templates/slides-2/app/components/editor/in-place-text-session.ts +6891 -0
- package/corpus/templates/slides-2/app/components/editor/inline-edit-session.ts +26 -0
- package/corpus/templates/slides-2/app/components/editor/list-editing.ts +501 -0
- package/corpus/templates/slides-2/app/components/editor/rich-text-selection.ts +975 -0
- package/corpus/templates/slides-2/app/components/editor/rte-test-utils.ts +265 -0
- package/corpus/templates/slides-2/app/components/editor/selection-overlay-measurement.ts +191 -0
- package/corpus/templates/slides-2/app/components/editor/slide-escape-arbiter.ts +34 -0
- package/corpus/templates/slides-2/app/components/editor/slide-object-interactions.ts +6362 -0
- package/corpus/templates/slides-2/app/components/editor/slide-object-transform.browser-host.ts +19 -0
- package/corpus/templates/slides-2/app/components/editor/slide-pointer-target.ts +432 -0
- package/corpus/templates/slides-2/app/components/editor/slide-presence.ts +13 -0
- package/corpus/templates/slides-2/app/components/editor/slide-style.ts +243 -0
- package/corpus/templates/slides-2/app/components/editor/slide-text-targets.ts +540 -0
- package/corpus/templates/slides-2/app/components/editor/style-clipboard.ts +102 -0
- package/corpus/templates/slides-2/app/components/editor/use-prompt-import.ts +159 -0
- package/corpus/templates/slides-2/app/components/home/SlidesHomeLibrary.tsx +79 -0
- package/corpus/templates/slides-2/app/components/layout/AgentWorkIndicator.tsx +193 -0
- package/corpus/templates/slides-2/app/components/layout/Header.tsx +110 -0
- package/corpus/templates/slides-2/app/components/layout/Layout.tsx +492 -0
- package/corpus/templates/slides-2/app/components/layout/Sidebar.tsx +109 -0
- package/corpus/templates/slides-2/app/components/layout/layout-route-policy.ts +28 -0
- package/corpus/templates/slides-2/app/components/presentation/PresentationView.tsx +1116 -0
- package/corpus/templates/slides-2/app/components/presentation/PresenterView.tsx +526 -0
- package/corpus/templates/slides-2/app/components/presentation/SlideTransitionStage.tsx +297 -0
- package/corpus/templates/slides-2/app/components/presentation/present-channel.ts +31 -0
- package/corpus/templates/slides-2/app/components/presentation/slide-build-steps.ts +231 -0
- package/corpus/templates/slides-2/app/components/presentation/slide-navigation.ts +273 -0
- package/corpus/templates/slides-2/app/components/presentation/slide-transition-motion.ts +258 -0
- package/corpus/templates/slides-2/app/components/presentation/voice-navigation.ts +61 -0
- package/corpus/templates/slides-2/app/components/settings/notification-settings.tsx +93 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2AssetBrowser.tsx +726 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2CommandMenu.tsx +453 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2Comments.tsx +571 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2DesignTokens.tsx +345 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2Editor.tsx +4804 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2ExportMenu.tsx +671 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2FontBrowser.tsx +342 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2ImageCropControls.tsx +487 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2Inspector.tsx +950 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/Slides2SvglLogoSearchDialog.tsx +332 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/cross-slide-edit-history.ts +151 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/design-token-presets.ts +140 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/editor-action-errors.ts +47 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/editor-export-errors.ts +60 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/geometry.ts +275 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/image-crop-style.ts +82 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/inline-text-editor.tsx +631 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/keyboard-shortcuts.ts +104 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/object-insertion.ts +13 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/preview-patches.ts +54 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/sandbox-render-errors.ts +23 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/source-structure.ts +634 -0
- package/corpus/templates/slides-2/app/components/slides-2-editor/types.ts +85 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2BlackoutOverlay.tsx +13 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2ControlBar.tsx +285 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2HelpDialog.tsx +72 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2JumpInput.tsx +38 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2LaserPointer.tsx +67 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2Overview.tsx +161 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2Player.tsx +839 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/Slides2ProgressBar.tsx +23 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/keyboard.ts +36 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/presenter-channel.ts +131 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/use-presenter-action-bridge.ts +296 -0
- package/corpus/templates/slides-2/app/components/slides-2-presenter/useSlides2TouchSwipe.ts +80 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/SandboxedSlide.tsx +724 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/SlideContentRenderer.tsx +137 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/Slides2Canvas.tsx +99 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/constants.ts +4 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/protocol.ts +1400 -0
- package/corpus/templates/slides-2/app/components/slides-2-runtime/transition-frame.ts +439 -0
- package/corpus/templates/slides-2/app/components/templates/DeckTemplateLibrary.tsx +314 -0
- package/corpus/templates/slides-2/app/components/templates/DeckTemplatePreview.tsx +60 -0
- package/corpus/templates/slides-2/app/components/templates/DeckTemplateStage.tsx +45 -0
- package/corpus/templates/slides-2/app/components/ui/alert-dialog.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/avatar.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/button-group.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/button.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/card.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/command.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/context-menu.tsx +32 -0
- package/corpus/templates/slides-2/app/components/ui/dialog.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/dropdown-menu.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/filter-trigger.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/input.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/label.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/popover.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/progress.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/scroll-area.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/select.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/separator.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/sheet.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/skeleton.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/slider.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/spinner.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/switch.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/tabs.tsx +59 -0
- package/corpus/templates/slides-2/app/components/ui/textarea.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/toggle-group.tsx +1 -0
- package/corpus/templates/slides-2/app/components/ui/toolkit-provider.tsx +17 -0
- package/corpus/templates/slides-2/app/components/ui/tooltip.tsx +1 -0
- package/corpus/templates/slides-2/app/components/visual-editor/CanvasCommentPins.tsx +46 -0
- package/corpus/templates/slides-2/app/components/visual-editor/DrawOverlay.tsx +27 -0
- package/corpus/templates/slides-2/app/components/visual-editor/MultiSelectChip.tsx +97 -0
- package/corpus/templates/slides-2/app/components/visual-editor/SaveStatusIndicator.tsx +273 -0
- package/corpus/templates/slides-2/app/components/visual-editor/index.ts +4 -0
- package/corpus/templates/slides-2/app/context/DeckContext.tsx +7486 -0
- package/corpus/templates/slides-2/app/design-system.ts +3 -0
- package/corpus/templates/slides-2/app/entry.client.tsx +10 -0
- package/corpus/templates/slides-2/app/entry.server.tsx +10 -0
- package/corpus/templates/slides-2/app/global.css +1626 -0
- package/corpus/templates/slides-2/app/hooks/use-agent-generating.ts +517 -0
- package/corpus/templates/slides-2/app/hooks/use-compact-editor-layout.ts +26 -0
- package/corpus/templates/slides-2/app/hooks/use-contrast-audit-bridge.ts +49 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-access-reload.ts +70 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-access.ts +50 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-design-system.ts +146 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-history-action-bridge.ts +266 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-presence.ts +89 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-role.ts +46 -0
- package/corpus/templates/slides-2/app/hooks/use-deck-versions.ts +43 -0
- package/corpus/templates/slides-2/app/hooks/use-design-system-workflows.ts +11 -0
- package/corpus/templates/slides-2/app/hooks/use-design-systems.ts +31 -0
- package/corpus/templates/slides-2/app/hooks/use-generating-slide-preview.ts +115 -0
- package/corpus/templates/slides-2/app/hooks/use-navigation-state.ts +229 -0
- package/corpus/templates/slides-2/app/hooks/use-new-deck-generation-signal.ts +46 -0
- package/corpus/templates/slides-2/app/hooks/use-new-deck-generation.ts +710 -0
- package/corpus/templates/slides-2/app/hooks/use-sidebar-collapsed.ts +95 -0
- package/corpus/templates/slides-2/app/hooks/use-slide-comments.ts +202 -0
- package/corpus/templates/slides-2/app/hooks/use-slide-file-storage-status.ts +55 -0
- package/corpus/templates/slides-2/app/hooks/use-undo-selection.ts +66 -0
- package/corpus/templates/slides-2/app/hooks/use-workspace-defaults.ts +31 -0
- package/corpus/templates/slides-2/app/i18n/en-US.ts +1507 -0
- package/corpus/templates/slides-2/app/i18n/index.ts +19 -0
- package/corpus/templates/slides-2/app/lib/agent-visible-message.ts +21 -0
- package/corpus/templates/slides-2/app/lib/aspect-ratios.ts +7 -0
- package/corpus/templates/slides-2/app/lib/asset-error-copy.ts +59 -0
- package/corpus/templates/slides-2/app/lib/canvas-zoom.ts +47 -0
- package/corpus/templates/slides-2/app/lib/composer-context.ts +152 -0
- package/corpus/templates/slides-2/app/lib/composer-draft.ts +34 -0
- package/corpus/templates/slides-2/app/lib/contrast-audit.ts +390 -0
- package/corpus/templates/slides-2/app/lib/contrast-resolve.ts +240 -0
- package/corpus/templates/slides-2/app/lib/create-deck-generation.ts +938 -0
- package/corpus/templates/slides-2/app/lib/deck-access-lost.ts +4 -0
- package/corpus/templates/slides-2/app/lib/deck-backup.ts +186 -0
- package/corpus/templates/slides-2/app/lib/deck-editor-loading.ts +91 -0
- package/corpus/templates/slides-2/app/lib/deck-export-file-client.ts +77 -0
- package/corpus/templates/slides-2/app/lib/deck-filter.ts +52 -0
- package/corpus/templates/slides-2/app/lib/deck-list-loading.ts +16 -0
- package/corpus/templates/slides-2/app/lib/deck-preview-frame.ts +15 -0
- package/corpus/templates/slides-2/app/lib/deck-share-links.ts +9 -0
- package/corpus/templates/slides-2/app/lib/deck-sorting.ts +19 -0
- package/corpus/templates/slides-2/app/lib/deferred-editor-surfaces.ts +24 -0
- package/corpus/templates/slides-2/app/lib/design-system-selection.ts +11 -0
- package/corpus/templates/slides-2/app/lib/design-systems.ts +231 -0
- package/corpus/templates/slides-2/app/lib/dynamic-import.ts +50 -0
- package/corpus/templates/slides-2/app/lib/editor-agent-handoff.ts +92 -0
- package/corpus/templates/slides-2/app/lib/editor-shortcuts.ts +153 -0
- package/corpus/templates/slides-2/app/lib/export-google-slides-client.ts +168 -0
- package/corpus/templates/slides-2/app/lib/export-pdf-client.ts +684 -0
- package/corpus/templates/slides-2/app/lib/export-pptx-client.ts +2420 -0
- package/corpus/templates/slides-2/app/lib/generation-lifecycle.ts +24 -0
- package/corpus/templates/slides-2/app/lib/generation-state.ts +247 -0
- package/corpus/templates/slides-2/app/lib/google-docs-client.ts +110 -0
- package/corpus/templates/slides-2/app/lib/google-slides-export-availability-client.ts +53 -0
- package/corpus/templates/slides-2/app/lib/google-slides-reference-source.ts +18 -0
- package/corpus/templates/slides-2/app/lib/image-download.ts +85 -0
- package/corpus/templates/slides-2/app/lib/image-drop-to-agent.ts +210 -0
- package/corpus/templates/slides-2/app/lib/import-uploaded-deck.ts +132 -0
- package/corpus/templates/slides-2/app/lib/inline-edit-remote.ts +55 -0
- package/corpus/templates/slides-2/app/lib/localize-slides-changelog.ts +47 -0
- package/corpus/templates/slides-2/app/lib/mermaid-blocks.ts +18 -0
- package/corpus/templates/slides-2/app/lib/new-deck-reference-selection.ts +174 -0
- package/corpus/templates/slides-2/app/lib/normalize-slide-padding.ts +74 -0
- package/corpus/templates/slides-2/app/lib/pending-deck-changes.ts +33 -0
- package/corpus/templates/slides-2/app/lib/portaled-layer.ts +7 -0
- package/corpus/templates/slides-2/app/lib/pptx-google-slides.ts +204 -0
- package/corpus/templates/slides-2/app/lib/prompt-attachment-adapter.ts +37 -0
- package/corpus/templates/slides-2/app/lib/prompt-file-uploads.ts +557 -0
- package/corpus/templates/slides-2/app/lib/recent-references.ts +106 -0
- package/corpus/templates/slides-2/app/lib/reference-document-hydration.ts +406 -0
- package/corpus/templates/slides-2/app/lib/register-chat-renderers.tsx +645 -0
- package/corpus/templates/slides-2/app/lib/reveal-after-delete.ts +55 -0
- package/corpus/templates/slides-2/app/lib/sanitize-slide-html.ts +752 -0
- package/corpus/templates/slides-2/app/lib/slide-agent-context.ts +148 -0
- package/corpus/templates/slides-2/app/lib/slide-animation-elements.ts +900 -0
- package/corpus/templates/slides-2/app/lib/slide-clipboard.ts +534 -0
- package/corpus/templates/slides-2/app/lib/slide-comment-anchor.ts +286 -0
- package/corpus/templates/slides-2/app/lib/slide-content-merge.ts +295 -0
- package/corpus/templates/slides-2/app/lib/slide-image-replacement.ts +1919 -0
- package/corpus/templates/slides-2/app/lib/slide-live-remote.ts +215 -0
- package/corpus/templates/slides-2/app/lib/slide-scroll.ts +56 -0
- package/corpus/templates/slides-2/app/lib/slide-source-map.ts +1099 -0
- package/corpus/templates/slides-2/app/lib/slide-video.ts +390 -0
- package/corpus/templates/slides-2/app/lib/slides-relay-tracking.ts +114 -0
- package/corpus/templates/slides-2/app/lib/streaming-slide-html.ts +77 -0
- package/corpus/templates/slides-2/app/lib/tab-id.ts +3 -0
- package/corpus/templates/slides-2/app/lib/template-navigation.ts +15 -0
- package/corpus/templates/slides-2/app/lib/text-tool-shortcut.ts +75 -0
- package/corpus/templates/slides-2/app/lib/undo-reveal.ts +332 -0
- package/corpus/templates/slides-2/app/lib/upload-response.ts +107 -0
- package/corpus/templates/slides-2/app/lib/utils.ts +38 -0
- package/corpus/templates/slides-2/app/lib/validate-native-slide-html.ts +177 -0
- package/corpus/templates/slides-2/app/lib/video-upload.ts +354 -0
- package/corpus/templates/slides-2/app/pages/DeckEditor.tsx +6158 -0
- package/corpus/templates/slides-2/app/pages/DesignSystems.tsx +363 -0
- package/corpus/templates/slides-2/app/pages/Index.tsx +3254 -0
- package/corpus/templates/slides-2/app/pages/NotFound.tsx +33 -0
- package/corpus/templates/slides-2/app/pages/Presentation.tsx +120 -0
- package/corpus/templates/slides-2/app/pages/SharedPresentation.tsx +174 -0
- package/corpus/templates/slides-2/app/pages/SlideThemeDetail.tsx +227 -0
- package/corpus/templates/slides-2/app/pages/SlideThemes.tsx +155 -0
- package/corpus/templates/slides-2/app/pages/Slides2EditorPage.tsx +1618 -0
- package/corpus/templates/slides-2/app/pages/Slides2PresenterConsolePage.tsx +937 -0
- package/corpus/templates/slides-2/app/pages/Slides2PresenterPage.tsx +979 -0
- package/corpus/templates/slides-2/app/pages/Templates.tsx +32 -0
- package/corpus/templates/slides-2/app/root.tsx +391 -0
- package/corpus/templates/slides-2/app/routes/$.tsx +10 -0
- package/corpus/templates/slides-2/app/routes/_index.tsx +1 -0
- package/corpus/templates/slides-2/app/routes/access-request.approve.tsx +276 -0
- package/corpus/templates/slides-2/app/routes/agent.tsx +19 -0
- package/corpus/templates/slides-2/app/routes/chat.$threadId.tsx +1 -0
- package/corpus/templates/slides-2/app/routes/chat.tsx +190 -0
- package/corpus/templates/slides-2/app/routes/deck.$id.tsx +10 -0
- package/corpus/templates/slides-2/app/routes/deck.$id_.present.tsx +10 -0
- package/corpus/templates/slides-2/app/routes/design-systems.tsx +10 -0
- package/corpus/templates/slides-2/app/routes/extensions.$id.$slug.tsx +2 -0
- package/corpus/templates/slides-2/app/routes/extensions.$id.tsx +5 -0
- package/corpus/templates/slides-2/app/routes/extensions._index.tsx +5 -0
- package/corpus/templates/slides-2/app/routes/extensions.tsx +5 -0
- package/corpus/templates/slides-2/app/routes/home-layout.tsx +31 -0
- package/corpus/templates/slides-2/app/routes/home.tsx +22 -0
- package/corpus/templates/slides-2/app/routes/p.$id.tsx +195 -0
- package/corpus/templates/slides-2/app/routes/settings.$.tsx +1 -0
- package/corpus/templates/slides-2/app/routes/settings.tsx +131 -0
- package/corpus/templates/slides-2/app/routes/share.$token.tsx +137 -0
- package/corpus/templates/slides-2/app/routes/slide.tsx +209 -0
- package/corpus/templates/slides-2/app/routes/team.tsx +11 -0
- package/corpus/templates/slides-2/app/routes/templates.tsx +1 -0
- package/corpus/templates/slides-2/app/routes/themes.$id.tsx +1 -0
- package/corpus/templates/slides-2/app/routes/themes.tsx +1 -0
- package/corpus/templates/slides-2/app/routes.ts +24 -0
- package/corpus/templates/slides-2/app/vite-env.d.ts +24 -0
- package/corpus/templates/slides-2/changelog/2026-10-17-find-and-switch-decks-from-the-presenter-console.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-17-meet-slides-2-create-and-refine-editable-slide-decks-with-an.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-17-pptx-image-export.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-17-visual-editor.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-apply-an-accessible-design-system-to-an-existing-deck-before.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-choose-a-template-or-start-a-new-presentation-from-the-slide.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-generate-decks-from-a-prompt-then-edit-slide-elements-direct.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-generate-presentation-decks-from-a-prompt-and-edit-every-sli.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-new-presentation-drafts-save-before-generation-starts-so-you.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-18-the-assistant-can-undo-redo-and-save-pending-edits-in-the-vi.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-agents-can-insert-duplicate-and-delete-canvas-objects-in-sou.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-browse-slide-themes.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-clicking-a-slide-preview-in-overview-selects-that-slide.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-create-decks-from-a-prompt-and-edit-slides-directly-on-the-c.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-creating-and-editing-decks-now-starts-with-the-tools-most-re.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-deleting-decks-revokes-public-links.md +7 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-escape-cancels-an-in-progress-slide-drag-without-losing-earl.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-import-failures-now-show-clear-localized-descriptions-instea.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-presenter-controls-stay-responsive-when-moving-over-the-slid.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-presenter-notes-stay-private-from-viewers-and-commenters.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-preview-generated-slides-in-chat.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-remote-image-previews-accept-supported-raster-formats.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-search-the-svgl-catalog-and-add-svg-logos-to-a-deck-or-the-g.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-slide-generation-explains-when-react-effect-hooks-cannot-run.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-the-editor-highlights-hovered-objects-and-keeps-image-replac.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-19-the-slide-editor-uses-the-shared-agent-native-controls.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-deck-editing-controls-match-the-workspace.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-google-slides-imports-now-report-missing-image-data-instead-.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-imports-and-previews-handle-large-content-safely.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-public-deck-pages-can-export-source-backed-slides-to-pdf.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-saved-slide-images-stay-available.md +6 -0
- package/corpus/templates/slides-2/changelog/2026-10-20-scope-global-media-picks-to-assets-the-current-deck-can-reso.md +6 -0
- package/corpus/templates/slides-2/components.json +20 -0
- package/corpus/templates/slides-2/drizzle.config.ts +3 -0
- package/corpus/templates/slides-2/learnings.defaults.md +5 -0
- package/corpus/templates/slides-2/netlify.toml +24 -0
- package/corpus/templates/slides-2/package.json +147 -0
- package/corpus/templates/slides-2/public/agent-native-icon-dark.svg +10 -0
- package/corpus/templates/slides-2/public/agent-native-icon-light.svg +10 -0
- package/corpus/templates/slides-2/public/agent-native-logo-dark.svg +21 -0
- package/corpus/templates/slides-2/public/agent-native-logo-light.svg +21 -0
- package/corpus/templates/slides-2/public/assets/builder-logo-white.svg +15 -0
- package/corpus/templates/slides-2/public/assets/generated/preview.html +61 -0
- package/corpus/templates/slides-2/public/assets/intuit-logo-white.svg +6 -0
- package/corpus/templates/slides-2/public/assets/walmart-logo-white.svg +6 -0
- package/corpus/templates/slides-2/public/chatgpt-plugin-icon.svg +7 -0
- package/corpus/templates/slides-2/public/favicon.svg +1 -0
- package/corpus/templates/slides-2/public/icon-180.svg +1 -0
- package/corpus/templates/slides-2/public/icon-192.svg +1 -0
- package/corpus/templates/slides-2/public/icon-512.svg +1 -0
- package/corpus/templates/slides-2/public/manifest.json +20 -0
- package/corpus/templates/slides-2/public/placeholder.svg +1 -0
- package/corpus/templates/slides-2/public/robots.txt +14 -0
- package/corpus/templates/slides-2/public/visual-edit-structure-proof.html +99 -0
- package/corpus/templates/slides-2/react-router.config.ts +7 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/README.md +499 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/authoring-fuzz.ts +9517 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/baseline.json +16427 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/dev-server-url.ts +10 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/lib/in-page.ts +1975 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/lib/metrics.ts +1401 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/retry-infra.ts +7 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/run-options.ts +21 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/run-outcomes.ts +127 -0
- package/corpus/templates/slides-2/scripts/edit-fidelity/run.ts +8451 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/README.md +116 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/compare-layout-lib.ts +241 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/compare-layout.ts +30 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/diff.ts +222 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/export.ts +765 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/fixtures/agent-dark-deck.json +48 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/generate-calibration.ts +765 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/google-export.ts +137 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/google-layout.ts +82 -0
- package/corpus/templates/slides-2/scripts/export-fidelity/resolve-pkg.ts +29 -0
- package/corpus/templates/slides-2/scripts/migrate-production.ts +22 -0
- package/corpus/templates/slides-2/server/db/index.ts +73 -0
- package/corpus/templates/slides-2/server/db/schema.ts +189 -0
- package/corpus/templates/slides-2/server/handlers/assets-url.ts +13 -0
- package/corpus/templates/slides-2/server/handlers/assets.ts +3217 -0
- package/corpus/templates/slides-2/server/handlers/decks.ts +185 -0
- package/corpus/templates/slides-2/server/handlers/demo.ts +9 -0
- package/corpus/templates/slides-2/server/handlers/design-systems.ts +219 -0
- package/corpus/templates/slides-2/server/handlers/google-docs-auth.ts +165 -0
- package/corpus/templates/slides-2/server/handlers/image-gen.ts +153 -0
- package/corpus/templates/slides-2/server/handlers/image-providers/gemini.ts +209 -0
- package/corpus/templates/slides-2/server/handlers/image-providers/index.ts +61 -0
- package/corpus/templates/slides-2/server/handlers/image-providers/openai.ts +288 -0
- package/corpus/templates/slides-2/server/handlers/image-providers/types.ts +35 -0
- package/corpus/templates/slides-2/server/handlers/import/docx-parser.ts +31 -0
- package/corpus/templates/slides-2/server/handlers/import/html-converter.ts +1534 -0
- package/corpus/templates/slides-2/server/handlers/import/pdf-fidelity-parser.ts +1039 -0
- package/corpus/templates/slides-2/server/handlers/import/pdf-sidecar-reader.ts +81 -0
- package/corpus/templates/slides-2/server/handlers/import/pdf-style-digest.ts +187 -0
- package/corpus/templates/slides-2/server/handlers/import/pptx-assets.ts +155 -0
- package/corpus/templates/slides-2/server/handlers/import/pptx-parser.ts +57 -0
- package/corpus/templates/slides-2/server/handlers/request-auth-context.ts +108 -0
- package/corpus/templates/slides-2/server/handlers/share.ts +52 -0
- package/corpus/templates/slides-2/server/handlers/uploads-chunked.ts +1066 -0
- package/corpus/templates/slides-2/server/handlers/uploads.ts +457 -0
- package/corpus/templates/slides-2/server/lib/access-request-email.ts +66 -0
- package/corpus/templates/slides-2/server/lib/assets-image-delegation.ts +331 -0
- package/corpus/templates/slides-2/server/lib/bounded-multipart.ts +49 -0
- package/corpus/templates/slides-2/server/lib/builder-design-system-proxy.ts +122 -0
- package/corpus/templates/slides-2/server/lib/chat-attachments.ts +425 -0
- package/corpus/templates/slides-2/server/lib/chatgpt-directory-tools.ts +246 -0
- package/corpus/templates/slides-2/server/lib/chunked-upload-session.ts +195 -0
- package/corpus/templates/slides-2/server/lib/comment-notifications.ts +184 -0
- package/corpus/templates/slides-2/server/lib/deck-access-requests.ts +102 -0
- package/corpus/templates/slides-2/server/lib/deck-asset-scope.ts +150 -0
- package/corpus/templates/slides-2/server/lib/deck-export-tracking.ts +119 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-case-study.ts +154 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-company.ts +160 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-pitch.ts +151 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-quarterly.ts +264 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-shared.ts +35 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-update.ts +188 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/a-workshop.ts +196 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-keynote.ts +131 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-lesson.ts +209 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-manifesto.ts +149 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-portfolio.ts +144 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-research.ts +221 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-roadmap.ts +264 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/b-shared.ts +44 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/group-a.ts +16 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/group-b.ts +16 -0
- package/corpus/templates/slides-2/server/lib/deck-templates/legacy.ts +567 -0
- package/corpus/templates/slides-2/server/lib/deck-templates.ts +60 -0
- package/corpus/templates/slides-2/server/lib/deck-versions.ts +233 -0
- package/corpus/templates/slides-2/server/lib/design-system-workflows.ts +22 -0
- package/corpus/templates/slides-2/server/lib/emails.ts +84 -0
- package/corpus/templates/slides-2/server/lib/env-config.ts +15 -0
- package/corpus/templates/slides-2/server/lib/fetch-remote-image.ts +245 -0
- package/corpus/templates/slides-2/server/lib/generation-completion.ts +278 -0
- package/corpus/templates/slides-2/server/lib/google-docs-access.ts +51 -0
- package/corpus/templates/slides-2/server/lib/google-docs-error.ts +54 -0
- package/corpus/templates/slides-2/server/lib/google-docs-oauth.ts +422 -0
- package/corpus/templates/slides-2/server/lib/google-fonts.ts +509 -0
- package/corpus/templates/slides-2/server/lib/google-oauth-preflight.ts +119 -0
- package/corpus/templates/slides-2/server/lib/google-slides-export-availability.ts +55 -0
- package/corpus/templates/slides-2/server/lib/image-proxy-response.ts +16 -0
- package/corpus/templates/slides-2/server/lib/image-proxy-url.ts +155 -0
- package/corpus/templates/slides-2/server/lib/import-asset-storage.ts +214 -0
- package/corpus/templates/slides-2/server/lib/imported-asset-batch.ts +218 -0
- package/corpus/templates/slides-2/server/lib/legacy-slide-source.ts +692 -0
- package/corpus/templates/slides-2/server/lib/media-search-providers.ts +216 -0
- package/corpus/templates/slides-2/server/lib/native-creative-context.ts +295 -0
- package/corpus/templates/slides-2/server/lib/pdf-parse-setup.ts +115 -0
- package/corpus/templates/slides-2/server/lib/provider-api.ts +57 -0
- package/corpus/templates/slides-2/server/lib/request-wait-until.ts +30 -0
- package/corpus/templates/slides-2/server/lib/shared-deck.ts +29 -0
- package/corpus/templates/slides-2/server/lib/slide-asset-references.ts +309 -0
- package/corpus/templates/slides-2/server/lib/slide-content-patch.ts +1004 -0
- package/corpus/templates/slides-2/server/lib/slide-hygiene.ts +731 -0
- package/corpus/templates/slides-2/server/lib/slide-image-insertion.ts +136 -0
- package/corpus/templates/slides-2/server/lib/slide-reveal-issues.ts +41 -0
- package/corpus/templates/slides-2/server/lib/slide-source-editing/babel-walk.ts +117 -0
- package/corpus/templates/slides-2/server/lib/slide-source-editing/batch-edit.ts +152 -0
- package/corpus/templates/slides-2/server/lib/slide-source-editing/edit-ops.ts +1478 -0
- package/corpus/templates/slides-2/server/lib/slide-source-editing/image-target.ts +128 -0
- package/corpus/templates/slides-2/server/lib/slide-source-editing/text-diff.ts +23 -0
- package/corpus/templates/slides-2/server/lib/slide-source-limits.ts +9 -0
- package/corpus/templates/slides-2/server/lib/slide-source.ts +1786 -0
- package/corpus/templates/slides-2/server/lib/slide-theme-demo-sources.ts +2106 -0
- package/corpus/templates/slides-2/server/lib/slide-themes.ts +2174 -0
- package/corpus/templates/slides-2/server/lib/slide-worker-runtime.ts +1995 -0
- package/corpus/templates/slides-2/server/lib/slides-tracking.ts +73 -0
- package/corpus/templates/slides-2/server/lib/source-import.ts +213 -0
- package/corpus/templates/slides-2/server/lib/svgl.ts +364 -0
- package/corpus/templates/slides-2/server/lib/tenant-files.ts +179 -0
- package/corpus/templates/slides-2/server/lib/upload-storage-status.ts +9 -0
- package/corpus/templates/slides-2/server/lib/uploaded-asset-cleanup-outbox.ts +521 -0
- package/corpus/templates/slides-2/server/lib/uploaded-asset-object-lifecycle.ts +404 -0
- package/corpus/templates/slides-2/server/lib/uploaded-fonts.ts +696 -0
- package/corpus/templates/slides-2/server/lib/uploaded-reference-storage.ts +77 -0
- package/corpus/templates/slides-2/server/lib/validate-slide-animations.ts +341 -0
- package/corpus/templates/slides-2/server/middleware/auth.ts +6 -0
- package/corpus/templates/slides-2/server/plugins/_dev-upload-stub.ts +6 -0
- package/corpus/templates/slides-2/server/plugins/agent-chat.ts +402 -0
- package/corpus/templates/slides-2/server/plugins/auth.ts +31 -0
- package/corpus/templates/slides-2/server/plugins/collab.ts +30 -0
- package/corpus/templates/slides-2/server/plugins/config.ts +6 -0
- package/corpus/templates/slides-2/server/plugins/core-routes.ts +30 -0
- package/corpus/templates/slides-2/server/plugins/creative-context.ts +187 -0
- package/corpus/templates/slides-2/server/plugins/db.ts +462 -0
- package/corpus/templates/slides-2/server/plugins/feature-flags.ts +5 -0
- package/corpus/templates/slides-2/server/plugins/labs.ts +8 -0
- package/corpus/templates/slides-2/server/plugins/orphaned-asset-cleanup.ts +17 -0
- package/corpus/templates/slides-2/server/plugins/otel.ts +6 -0
- package/corpus/templates/slides-2/server/plugins/transactional-emails.ts +5 -0
- package/corpus/templates/slides-2/server/register-secrets.ts +209 -0
- package/corpus/templates/slides-2/server/routes/[...page].get.ts +5 -0
- package/corpus/templates/slides-2/server/routes/[...page].head.ts +1 -0
- package/corpus/templates/slides-2/server/routes/[base]/_agent-native/google-docs/auth-url.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/[base]/_agent-native/google-docs/callback.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/_agent-native/google-docs/auth-url.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/_agent-native/google-docs/callback.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/assets/upload-video.post.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/assets/upload.post.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/assets/video-uploads.delete.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/deck-agent-context.json.get.ts +105 -0
- package/corpus/templates/slides-2/server/routes/api/decks/events.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/demo.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/exports/[filename].get.ts +221 -0
- package/corpus/templates/slides-2/server/routes/api/exports/google-slides.post.ts +240 -0
- package/corpus/templates/slides-2/server/routes/api/exports/html.post.ts +67 -0
- package/corpus/templates/slides-2/server/routes/api/exports/pptx.post.ts +100 -0
- package/corpus/templates/slides-2/server/routes/api/gen-preview/[...].get.ts +24 -0
- package/corpus/templates/slides-2/server/routes/api/generated/[...].get.ts +24 -0
- package/corpus/templates/slides-2/server/routes/api/image-proxy.get.ts +518 -0
- package/corpus/templates/slides-2/server/routes/api/import-assets/[token].get.ts +70 -0
- package/corpus/templates/slides-2/server/routes/api/preview-images.get.ts +20 -0
- package/corpus/templates/slides-2/server/routes/api/share/[token].get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads-chunked/[sessionId]/chunk.post.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads-chunked/[sessionId]/status.get.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads-chunked/[sessionId].delete.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads-chunked/start.post.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads.delete.ts +1 -0
- package/corpus/templates/slides-2/server/routes/api/uploads.post.ts +1 -0
- package/corpus/templates/slides-2/server/workspace-defaults.ts +196 -0
- package/corpus/templates/slides-2/shared/action-ui.ts +147 -0
- package/corpus/templates/slides-2/shared/agent-readable.ts +2 -0
- package/corpus/templates/slides-2/shared/api.ts +406 -0
- package/corpus/templates/slides-2/shared/app-state-tabs.ts +30 -0
- package/corpus/templates/slides-2/shared/app-storage.ts +9 -0
- package/corpus/templates/slides-2/shared/aspect-ratios.ts +49 -0
- package/corpus/templates/slides-2/shared/blank-slide.ts +179 -0
- package/corpus/templates/slides-2/shared/client-compatibility.ts +2 -0
- package/corpus/templates/slides-2/shared/contrast-audit.ts +255 -0
- package/corpus/templates/slides-2/shared/deck-access.ts +26 -0
- package/corpus/templates/slides-2/shared/deck-app-scope.ts +14 -0
- package/corpus/templates/slides-2/shared/deck-content.ts +37 -0
- package/corpus/templates/slides-2/shared/deck-history-control.ts +79 -0
- package/corpus/templates/slides-2/shared/deck-scope.ts +5 -0
- package/corpus/templates/slides-2/shared/deck-title.ts +199 -0
- package/corpus/templates/slides-2/shared/deck-write.ts +61 -0
- package/corpus/templates/slides-2/shared/design-flags.ts +7 -0
- package/corpus/templates/slides-2/shared/design-system-validation.ts +88 -0
- package/corpus/templates/slides-2/shared/editor-control.ts +120 -0
- package/corpus/templates/slides-2/shared/generation-timing.ts +19 -0
- package/corpus/templates/slides-2/shared/google-docs.ts +69 -0
- package/corpus/templates/slides-2/shared/labs.ts +10 -0
- package/corpus/templates/slides-2/shared/overview-navigation.ts +34 -0
- package/corpus/templates/slides-2/shared/ownership.ts +6 -0
- package/corpus/templates/slides-2/shared/pdf-sidecar.ts +130 -0
- package/corpus/templates/slides-2/shared/presenter-control.ts +111 -0
- package/corpus/templates/slides-2/shared/representative-slide.ts +89 -0
- package/corpus/templates/slides-2/shared/slide-background.ts +30 -0
- package/corpus/templates/slides-2/shared/slide-comment-anchor.ts +117 -0
- package/corpus/templates/slides-2/shared/slide-comment-reactions.ts +47 -0
- package/corpus/templates/slides-2/shared/slide-design-tokens.ts +92 -0
- package/corpus/templates/slides-2/shared/slide-fit.ts +78 -0
- package/corpus/templates/slides-2/shared/slide-ids.ts +133 -0
- package/corpus/templates/slides-2/shared/slide-number.ts +124 -0
- package/corpus/templates/slides-2/shared/slide-object-structure.ts +790 -0
- package/corpus/templates/slides-2/shared/slide-text-range-selection.ts +50 -0
- package/corpus/templates/slides-2/shared/slide-transitions.ts +70 -0
- package/corpus/templates/slides-2/shared/slides-2-transition.ts +194 -0
- package/corpus/templates/slides-2/shared/slides-user-prefs.ts +22 -0
- package/corpus/templates/slides-2/shared/source-import-errors.ts +12 -0
- package/corpus/templates/slides-2/shared/source-runtime-export.ts +76 -0
- package/corpus/templates/slides-2/shared/upload-types.ts +41 -0
- package/corpus/templates/slides-2/ssr-entry.ts +11 -0
- package/corpus/templates/slides-2/tsconfig.json +27 -0
- package/corpus/templates/slides-2/vite.config.ts +77 -0
- package/corpus/templates/slides-2/vitest.config.ts +28 -0
- package/corpus/templates/tasks/.agents/skills/actions/references/action-fields.md +1 -1
- package/package.json +1 -1
- package/corpus/templates/design/.agents/skills/shader-fills/SKILL.md +0 -182
- package/corpus/templates/design/actions/apply-shader-fill.ts +0 -450
- package/corpus/templates/design/actions/apply-shader.ts +0 -257
- package/corpus/templates/design/actions/preview-shader-fill.ts +0 -157
- package/corpus/templates/design/app/components/design/inspector/GlslShaderPanel.tsx +0 -1144
- package/corpus/templates/design/app/components/design/inspector/SHADER_INTEGRATION.md +0 -450
- package/corpus/templates/design/app/components/design/inspector/ShaderControls.stories.tsx +0 -71
- package/corpus/templates/design/app/components/design/inspector/ShaderControls.tsx +0 -555
- package/corpus/templates/design/app/components/design/inspector/ShaderEffectRow.tsx +0 -105
- package/corpus/templates/design/app/components/design/inspector/ShaderFillsPanel.tsx +0 -433
- package/corpus/templates/design/app/components/design/inspector/color-picker-shader-pane.tsx +0 -648
- package/corpus/templates/design/shared/shader-fill.ts +0 -174
- package/corpus/templates/design/shared/shader-presets.ts +0 -1523
|
@@ -3,7 +3,12 @@ import type {
|
|
|
3
3
|
EffectDefinition,
|
|
4
4
|
EffectInstance,
|
|
5
5
|
} from "../../../../shared/native-effects";
|
|
6
|
+
import {
|
|
7
|
+
nativeWorkerInputAssetId,
|
|
8
|
+
planNativeInputResources,
|
|
9
|
+
} from "../../../../shared/native-input-resources";
|
|
6
10
|
import { readNativeAuthoredPaint } from "./native-authored-paint";
|
|
11
|
+
import { isNativeHtmlElement, isNativeSvgRoot } from "./native-dom";
|
|
7
12
|
import {
|
|
8
13
|
planNativeChainedEffectExtent,
|
|
9
14
|
planNativeFillPresentationExtent,
|
|
@@ -14,11 +19,18 @@ import {
|
|
|
14
19
|
supportsNativeOutput2D,
|
|
15
20
|
} from "./native-effect-output-geometry";
|
|
16
21
|
import { filterNativeExportSelection } from "./native-export-selection";
|
|
22
|
+
import { fitNativeRasterDensity } from "./native-preview-geometry";
|
|
17
23
|
import { beginNativeRegionExport } from "./native-region-export";
|
|
24
|
+
import {
|
|
25
|
+
attachNativeScenePresentationCanvas,
|
|
26
|
+
supportsNativeSceneBodyTransform,
|
|
27
|
+
} from "./native-scene-body-transform";
|
|
28
|
+
import { isNativeScenePresentationElement } from "./native-scene-presentation-element";
|
|
18
29
|
import {
|
|
19
30
|
createNativeSceneProvider,
|
|
20
31
|
cloneNativeTextFlow,
|
|
21
32
|
NativeSourceError,
|
|
33
|
+
NativeSourceCapabilityError,
|
|
22
34
|
nativeTargetOverflowInsets,
|
|
23
35
|
nativeTextFlowUsesDocumentFont,
|
|
24
36
|
paintNativeTextFlow,
|
|
@@ -27,13 +39,24 @@ import {
|
|
|
27
39
|
type NativeSourceRecord,
|
|
28
40
|
} from "./native-source-provider";
|
|
29
41
|
import { NativeWorkerHost, NativeWorkerHostError } from "./native-worker-host";
|
|
42
|
+
import { NativeWorkerInputAssets } from "./native-worker-input-assets";
|
|
30
43
|
import type {
|
|
31
44
|
NativeWorkerEffectTarget,
|
|
32
45
|
NativeWorkerScene,
|
|
33
46
|
NativeWorkerSourceRecord,
|
|
34
47
|
} from "./native-worker-protocol";
|
|
48
|
+
import {
|
|
49
|
+
NATIVE_WORKER_MAX_DIMENSION,
|
|
50
|
+
NATIVE_WORKER_MAX_PIXELS,
|
|
51
|
+
} from "./native-worker-protocol";
|
|
35
52
|
import { NativeWorkerSourceSnapshot } from "./native-worker-source-snapshot";
|
|
36
53
|
|
|
54
|
+
export class NativeWorkerSceneSourceError extends NativeSourceError {
|
|
55
|
+
constructor(readonly captureFailure: NativeSourceCapabilityError) {
|
|
56
|
+
super("worker-scene-source-unsupported", captureFailure.message);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
37
60
|
export type NativeWorkerSceneEntry = {
|
|
38
61
|
instance: EffectInstance;
|
|
39
62
|
definition: EffectDefinition;
|
|
@@ -41,6 +64,80 @@ export type NativeWorkerSceneEntry = {
|
|
|
41
64
|
target: HTMLElement | SVGSVGElement;
|
|
42
65
|
};
|
|
43
66
|
|
|
67
|
+
export function planNativeWorkerSceneGeometry(input: {
|
|
68
|
+
viewport: { x: number; y: number; width: number; height: number };
|
|
69
|
+
pixelRatio: number;
|
|
70
|
+
}): {
|
|
71
|
+
viewport: { x: number; y: number; width: number; height: number };
|
|
72
|
+
pixelRatio: number;
|
|
73
|
+
width: number;
|
|
74
|
+
height: number;
|
|
75
|
+
} {
|
|
76
|
+
const { viewport, pixelRatio: requestedRatio } = input;
|
|
77
|
+
if (
|
|
78
|
+
![
|
|
79
|
+
viewport.x,
|
|
80
|
+
viewport.y,
|
|
81
|
+
viewport.width,
|
|
82
|
+
viewport.height,
|
|
83
|
+
requestedRatio,
|
|
84
|
+
].every(Number.isFinite) ||
|
|
85
|
+
viewport.width <= 0 ||
|
|
86
|
+
viewport.height <= 0 ||
|
|
87
|
+
requestedRatio <= 0
|
|
88
|
+
)
|
|
89
|
+
throw new NativeSourceError(
|
|
90
|
+
"worker-viewport-geometry-invalid",
|
|
91
|
+
"The native worker viewport has invalid geometry.",
|
|
92
|
+
);
|
|
93
|
+
const pixelRatio = fitNativeRasterDensity({
|
|
94
|
+
width: viewport.width,
|
|
95
|
+
height: viewport.height,
|
|
96
|
+
density: requestedRatio,
|
|
97
|
+
maxDimension: NATIVE_WORKER_MAX_DIMENSION,
|
|
98
|
+
maxPixels: NATIVE_WORKER_MAX_PIXELS,
|
|
99
|
+
});
|
|
100
|
+
const width = Math.ceil(viewport.width * pixelRatio);
|
|
101
|
+
const height = Math.ceil(viewport.height * pixelRatio);
|
|
102
|
+
if (
|
|
103
|
+
!Number.isSafeInteger(width) ||
|
|
104
|
+
!Number.isSafeInteger(height) ||
|
|
105
|
+
width < 1 ||
|
|
106
|
+
height < 1 ||
|
|
107
|
+
width > NATIVE_WORKER_MAX_DIMENSION ||
|
|
108
|
+
height > NATIVE_WORKER_MAX_DIMENSION ||
|
|
109
|
+
width * height > NATIVE_WORKER_MAX_PIXELS
|
|
110
|
+
)
|
|
111
|
+
throw new NativeSourceError(
|
|
112
|
+
"worker-viewport-budget-exceeded",
|
|
113
|
+
"The requested native worker viewport exceeds its full-resolution budget.",
|
|
114
|
+
);
|
|
115
|
+
return { viewport, pixelRatio, width, height };
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export function nativeWorkerDefinitions(
|
|
119
|
+
entries: readonly NativeWorkerSceneEntry[],
|
|
120
|
+
): EffectDefinition[] {
|
|
121
|
+
const definitions = new Map<
|
|
122
|
+
string,
|
|
123
|
+
{ definition: EffectDefinition; hash: string }
|
|
124
|
+
>();
|
|
125
|
+
for (const entry of entries) {
|
|
126
|
+
const key = JSON.stringify([entry.definition.id, entry.definition.version]);
|
|
127
|
+
const existing = definitions.get(key);
|
|
128
|
+
if (existing && existing.hash !== entry.definitionHash)
|
|
129
|
+
throw new NativeSourceError(
|
|
130
|
+
"worker-definition-conflict",
|
|
131
|
+
`Native effect ${entry.definition.id} version ${entry.definition.version} has conflicting definitions.`,
|
|
132
|
+
);
|
|
133
|
+
definitions.set(key, {
|
|
134
|
+
definition: entry.definition,
|
|
135
|
+
hash: entry.definitionHash,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
return [...definitions.values()].map(({ definition }) => definition);
|
|
139
|
+
}
|
|
140
|
+
|
|
44
141
|
type TargetState = {
|
|
45
142
|
entry: NativeWorkerSceneEntry;
|
|
46
143
|
marker: HTMLCanvasElement;
|
|
@@ -57,6 +154,18 @@ type Publication = {
|
|
|
57
154
|
targetEpochs: Map<string, { source: number; authored: number }>;
|
|
58
155
|
rootRecords: readonly NativeSourceRecord[];
|
|
59
156
|
payloads: Map<string, { payload: string; definitionHash: string }>;
|
|
157
|
+
authoredPayloads: Map<string, { payload: string; definitionHash: string }>;
|
|
158
|
+
clockIdentity?: { origin: number | null; sourcePlaying: boolean };
|
|
159
|
+
};
|
|
160
|
+
|
|
161
|
+
type CameraCandidate = {
|
|
162
|
+
committed: { scene: NativeWorkerScene; publication: Publication };
|
|
163
|
+
viewport: NativeWorkerScene["viewport"];
|
|
164
|
+
width: number;
|
|
165
|
+
height: number;
|
|
166
|
+
pixelRatio: number;
|
|
167
|
+
clock: NativeWorkerScene["clock"];
|
|
168
|
+
clockIdentity: NonNullable<Publication["clockIdentity"]>;
|
|
60
169
|
};
|
|
61
170
|
|
|
62
171
|
const OMIT_SCENE_CHILD =
|
|
@@ -83,21 +192,68 @@ export function nativeWorkerOutputRecords(
|
|
|
83
192
|
});
|
|
84
193
|
}
|
|
85
194
|
|
|
195
|
+
type NativeWorkerOutputTarget = Pick<
|
|
196
|
+
NativeWorkerEffectTarget,
|
|
197
|
+
"sourceRecords" | "fillLocalSourceRecords" | "fillPhases"
|
|
198
|
+
>;
|
|
199
|
+
|
|
200
|
+
export function nativeWorkerOutputSceneRecords(
|
|
201
|
+
targets: NativeWorkerOutputTarget[],
|
|
202
|
+
records: readonly NativeWorkerSourceRecord[],
|
|
203
|
+
sizes: ReadonlyMap<string, { width: number; height: number }>,
|
|
204
|
+
): NativeWorkerSourceRecord[] {
|
|
205
|
+
for (const target of targets) {
|
|
206
|
+
target.sourceRecords = nativeWorkerOutputRecords(
|
|
207
|
+
target.sourceRecords,
|
|
208
|
+
sizes,
|
|
209
|
+
);
|
|
210
|
+
if (target.fillLocalSourceRecords)
|
|
211
|
+
target.fillLocalSourceRecords = nativeWorkerOutputRecords(
|
|
212
|
+
target.fillLocalSourceRecords,
|
|
213
|
+
sizes,
|
|
214
|
+
);
|
|
215
|
+
if (target.fillPhases)
|
|
216
|
+
for (const key of Object.keys(target.fillPhases) as Array<
|
|
217
|
+
keyof NonNullable<NativeWorkerEffectTarget["fillPhases"]>
|
|
218
|
+
>)
|
|
219
|
+
target.fillPhases[key] = nativeWorkerOutputRecords(
|
|
220
|
+
target.fillPhases[key],
|
|
221
|
+
sizes,
|
|
222
|
+
);
|
|
223
|
+
}
|
|
224
|
+
return nativeWorkerOutputRecords(records, sizes);
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
function nativeWorkerTargetDrawable(
|
|
228
|
+
rect: Pick<DOMRect, "x" | "y" | "width" | "height">,
|
|
229
|
+
): boolean {
|
|
230
|
+
if (
|
|
231
|
+
![rect.x, rect.y, rect.width, rect.height].every(Number.isFinite) ||
|
|
232
|
+
rect.width < 0 ||
|
|
233
|
+
rect.height < 0
|
|
234
|
+
)
|
|
235
|
+
throw new NativeSourceError(
|
|
236
|
+
"worker-target-geometry-invalid",
|
|
237
|
+
"A native effect target has unavailable or oversized geometry.",
|
|
238
|
+
);
|
|
239
|
+
return rect.width > 0 && rect.height > 0;
|
|
240
|
+
}
|
|
241
|
+
|
|
86
242
|
function nativeWorkerTargetGeometry(
|
|
87
|
-
|
|
243
|
+
rect: DOMRect,
|
|
88
244
|
pixelRatio: number,
|
|
89
245
|
cssWidth: number,
|
|
90
246
|
cssHeight: number,
|
|
91
247
|
): { width: number; height: number; rect: NativeWorkerEffectTarget["rect"] } {
|
|
92
|
-
const rect = target.getBoundingClientRect();
|
|
93
248
|
const width = Math.max(1, Math.ceil(cssWidth * pixelRatio));
|
|
94
249
|
const height = Math.max(1, Math.ceil(cssHeight * pixelRatio));
|
|
95
250
|
if (
|
|
96
251
|
![rect.x, rect.y, rect.width, rect.height].every(Number.isFinite) ||
|
|
97
252
|
rect.width <= 0 ||
|
|
98
253
|
rect.height <= 0 ||
|
|
99
|
-
width >
|
|
100
|
-
height >
|
|
254
|
+
width > NATIVE_WORKER_MAX_DIMENSION ||
|
|
255
|
+
height > NATIVE_WORKER_MAX_DIMENSION ||
|
|
256
|
+
width * height > NATIVE_WORKER_MAX_PIXELS
|
|
101
257
|
)
|
|
102
258
|
throw new NativeSourceError(
|
|
103
259
|
"worker-target-geometry-invalid",
|
|
@@ -120,6 +276,7 @@ export class NativeWorkerSceneHost {
|
|
|
120
276
|
{ signature: string; canvas: HTMLCanvasElement }
|
|
121
277
|
>();
|
|
122
278
|
private readonly assetRevisions = new Map<string, number>();
|
|
279
|
+
private readonly inputAssets = new NativeWorkerInputAssets();
|
|
123
280
|
private readonly pendingAssetRevisions = new Map<
|
|
124
281
|
number,
|
|
125
282
|
Map<string, number>
|
|
@@ -155,16 +312,17 @@ export class NativeWorkerSceneHost {
|
|
|
155
312
|
private cameraInFlightGeneration: number | null = null;
|
|
156
313
|
private cameraUpdatePending = false;
|
|
157
314
|
private cameraPublishTimer: ReturnType<typeof setTimeout> | null = null;
|
|
158
|
-
private clock: () =>
|
|
315
|
+
private clock: () => NativeWorkerScene["clock"];
|
|
159
316
|
|
|
160
317
|
constructor(
|
|
161
318
|
workerSource: string,
|
|
162
319
|
sceneId: string,
|
|
163
|
-
clock: () =>
|
|
320
|
+
clock: () => NativeWorkerScene["clock"],
|
|
164
321
|
private readonly onCommitted: (
|
|
165
322
|
publication: Publication,
|
|
166
323
|
message: {
|
|
167
324
|
timeSeconds: number;
|
|
325
|
+
contentChanged: boolean;
|
|
168
326
|
committedInstances: readonly {
|
|
169
327
|
instanceId: string;
|
|
170
328
|
definitionHash: string;
|
|
@@ -189,6 +347,13 @@ export class NativeWorkerSceneHost {
|
|
|
189
347
|
viewport: { x: number; y: number; width: number; height: number };
|
|
190
348
|
pixelRatio: number;
|
|
191
349
|
},
|
|
350
|
+
private readonly sceneCadence: () => {
|
|
351
|
+
frameRateTarget: 60 | 120;
|
|
352
|
+
compact: boolean;
|
|
353
|
+
},
|
|
354
|
+
private readonly getClockOrigin?: () => number,
|
|
355
|
+
private readonly hasPresentationToRetire?: () => boolean,
|
|
356
|
+
private readonly beforeCommit?: () => void,
|
|
192
357
|
) {
|
|
193
358
|
const body = document.body;
|
|
194
359
|
if (!body)
|
|
@@ -203,7 +368,11 @@ export class NativeWorkerSceneHost {
|
|
|
203
368
|
this.canvas.setAttribute("aria-hidden", "true");
|
|
204
369
|
this.canvas.style.cssText =
|
|
205
370
|
"position:fixed;left:0;top:0;pointer-events:none;visibility:hidden;z-index:0;max-width:none;max-height:none;";
|
|
206
|
-
|
|
371
|
+
attachNativeScenePresentationCanvas(
|
|
372
|
+
this.canvas,
|
|
373
|
+
body,
|
|
374
|
+
getComputedStyle(body),
|
|
375
|
+
);
|
|
207
376
|
const provider = createNativeSceneProvider(
|
|
208
377
|
document.documentElement,
|
|
209
378
|
"layer",
|
|
@@ -306,26 +475,36 @@ export class NativeWorkerSceneHost {
|
|
|
306
475
|
this.targets.delete(id);
|
|
307
476
|
}
|
|
308
477
|
this.entries = [...entries];
|
|
309
|
-
for (const target of this.markedTargets) {
|
|
310
|
-
target.removeAttribute("data-an-native-fill-instance");
|
|
311
|
-
target.removeAttribute("data-an-native-layer-instance");
|
|
312
|
-
}
|
|
313
|
-
this.markedTargets.clear();
|
|
314
478
|
for (const entry of entries) {
|
|
315
479
|
const existing = this.targets.get(entry.instance.id);
|
|
316
480
|
if (existing) existing.entry = entry;
|
|
317
481
|
else this.targets.set(entry.instance.id, this.createTarget(entry));
|
|
318
482
|
}
|
|
483
|
+
this.restoreEntryMarkersAndVisibility();
|
|
484
|
+
this.requestUpdate();
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
private restoreEntryMarkersAndVisibility(): void {
|
|
488
|
+
for (const target of this.markedTargets) {
|
|
489
|
+
target.removeAttribute("data-an-native-fill-instance");
|
|
490
|
+
target.removeAttribute("data-an-native-layer-instance");
|
|
491
|
+
}
|
|
492
|
+
this.markedTargets.clear();
|
|
319
493
|
const topFill = new Map<Element, string>();
|
|
320
494
|
const topLayer = new Map<Element, string>();
|
|
321
|
-
for (const entry of entries) {
|
|
495
|
+
for (const entry of this.entries) {
|
|
322
496
|
if (entry.instance.placement === "fill")
|
|
323
497
|
topFill.set(entry.target, entry.instance.id);
|
|
324
498
|
if (entry.instance.placement === "layer")
|
|
325
499
|
topLayer.set(entry.target, entry.instance.id);
|
|
326
500
|
}
|
|
327
|
-
for (const entry of entries) {
|
|
328
|
-
const state = this.targets.get(entry.instance.id)
|
|
501
|
+
for (const entry of this.entries) {
|
|
502
|
+
const state = this.targets.get(entry.instance.id);
|
|
503
|
+
if (!state)
|
|
504
|
+
throw new NativeWorkerHostError(
|
|
505
|
+
"worker-instance-state-missing",
|
|
506
|
+
"A native worker instance is unavailable.",
|
|
507
|
+
);
|
|
329
508
|
this.markedTargets.add(entry.target);
|
|
330
509
|
if (topFill.get(entry.target) === entry.instance.id)
|
|
331
510
|
entry.target.setAttribute(
|
|
@@ -345,7 +524,6 @@ export class NativeWorkerSceneHost {
|
|
|
345
524
|
? "visible"
|
|
346
525
|
: "hidden";
|
|
347
526
|
}
|
|
348
|
-
this.requestUpdate();
|
|
349
527
|
}
|
|
350
528
|
|
|
351
529
|
setEntriesAndWait(
|
|
@@ -414,8 +592,8 @@ export class NativeWorkerSceneHost {
|
|
|
414
592
|
private snapshotClock(
|
|
415
593
|
viewport: { x: number; y: number; width: number; height: number },
|
|
416
594
|
exportCapture: boolean,
|
|
595
|
+
clock = this.clock(),
|
|
417
596
|
): NativeWorkerScene["clock"] {
|
|
418
|
-
const clock = this.clock();
|
|
419
597
|
if (
|
|
420
598
|
exportCapture ||
|
|
421
599
|
!clock.playing ||
|
|
@@ -456,19 +634,28 @@ export class NativeWorkerSceneHost {
|
|
|
456
634
|
return readableMarkers ? { ...clock, playing: false } : clock;
|
|
457
635
|
}
|
|
458
636
|
|
|
637
|
+
private clockIdentity(
|
|
638
|
+
sourceClock: NativeWorkerScene["clock"],
|
|
639
|
+
): NonNullable<Publication["clockIdentity"]> {
|
|
640
|
+
if (!this.getClockOrigin)
|
|
641
|
+
return { origin: null, sourcePlaying: sourceClock.playing };
|
|
642
|
+
const origin = this.getClockOrigin();
|
|
643
|
+
if (!Number.isFinite(origin))
|
|
644
|
+
throw new NativeSourceError(
|
|
645
|
+
"worker-clock-origin-unreadable",
|
|
646
|
+
"The native worker playback origin is unreadable.",
|
|
647
|
+
);
|
|
648
|
+
return { origin, sourcePlaying: sourceClock.playing };
|
|
649
|
+
}
|
|
650
|
+
|
|
459
651
|
retainsPreviewViewport(
|
|
460
652
|
viewport: { x: number; y: number; width: number; height: number },
|
|
461
653
|
pixelRatio: number,
|
|
462
654
|
): boolean {
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
!committed ||
|
|
468
|
-
this.lastScene?.generation !== committed.scene.generation
|
|
469
|
-
)
|
|
470
|
-
return false;
|
|
471
|
-
const retained = committed.scene.viewport;
|
|
655
|
+
if (this.dirty || this.updating) return false;
|
|
656
|
+
const known = this.committedScene();
|
|
657
|
+
if (!known) return false;
|
|
658
|
+
const retained = known.scene.viewport;
|
|
472
659
|
if (
|
|
473
660
|
![viewport.x, viewport.y, viewport.width, viewport.height].every(
|
|
474
661
|
Number.isFinite,
|
|
@@ -481,6 +668,13 @@ export class NativeWorkerSceneHost {
|
|
|
481
668
|
viewport.y + viewport.height > retained.y + retained.height + 0.001
|
|
482
669
|
)
|
|
483
670
|
return false;
|
|
671
|
+
const planned = planNativeWorkerSceneGeometry({
|
|
672
|
+
viewport: retained,
|
|
673
|
+
pixelRatio,
|
|
674
|
+
});
|
|
675
|
+
const committed = this.currentCameraSource(planned.pixelRatio);
|
|
676
|
+
if (!committed || this.lastScene?.generation !== committed.scene.generation)
|
|
677
|
+
return false;
|
|
484
678
|
if (
|
|
485
679
|
this.snapshotClock(viewport, false).playing !==
|
|
486
680
|
committed.scene.clock.playing
|
|
@@ -493,6 +687,7 @@ export class NativeWorkerSceneHost {
|
|
|
493
687
|
pixelRatio: number,
|
|
494
688
|
): ReturnType<NativeWorkerSceneHost["committedScene"]> {
|
|
495
689
|
const committed = this.committedScene();
|
|
690
|
+
const cadence = this.sceneCadence();
|
|
496
691
|
if (
|
|
497
692
|
!this.visible ||
|
|
498
693
|
this.disposed ||
|
|
@@ -507,11 +702,15 @@ export class NativeWorkerSceneHost {
|
|
|
507
702
|
!Number.isFinite(pixelRatio) ||
|
|
508
703
|
pixelRatio <= 0 ||
|
|
509
704
|
Math.abs(pixelRatio - committed.scene.pixelRatio) > 0.000001 ||
|
|
510
|
-
|
|
705
|
+
(committed.scene.frameRateTarget ?? 60) !== cadence.frameRateTarget ||
|
|
706
|
+
(committed.scene.compact ?? false) !== cadence.compact ||
|
|
707
|
+
this.entries.length !== committed.publication.authoredPayloads.size
|
|
511
708
|
)
|
|
512
709
|
return null;
|
|
513
710
|
for (const entry of this.entries) {
|
|
514
|
-
const expected = committed.publication.
|
|
711
|
+
const expected = committed.publication.authoredPayloads.get(
|
|
712
|
+
entry.instance.id,
|
|
713
|
+
);
|
|
515
714
|
const epoch = committed.publication.targetEpochs.get(entry.instance.id);
|
|
516
715
|
const state = this.targets.get(entry.instance.id);
|
|
517
716
|
const target = committed.scene.targets.find(
|
|
@@ -525,11 +724,15 @@ export class NativeWorkerSceneHost {
|
|
|
525
724
|
!state ||
|
|
526
725
|
state.entry.target !== entry.target ||
|
|
527
726
|
state.provider.sourceEpoch?.() !== epoch.source ||
|
|
528
|
-
state.provider.authoredSourceEpoch?.() !== epoch.authored
|
|
529
|
-
!target
|
|
727
|
+
state.provider.authoredSourceEpoch?.() !== epoch.authored
|
|
530
728
|
)
|
|
531
729
|
return null;
|
|
532
730
|
const rect = entry.target.getBoundingClientRect();
|
|
731
|
+
if (!nativeWorkerTargetDrawable(rect)) {
|
|
732
|
+
if (target) return null;
|
|
733
|
+
continue;
|
|
734
|
+
}
|
|
735
|
+
if (!target) return null;
|
|
533
736
|
if (
|
|
534
737
|
Math.abs(rect.x - target.rect.x) > 0.001 ||
|
|
535
738
|
Math.abs(rect.y - target.rect.y) > 0.001 ||
|
|
@@ -541,12 +744,12 @@ export class NativeWorkerSceneHost {
|
|
|
541
744
|
return committed;
|
|
542
745
|
}
|
|
543
746
|
|
|
544
|
-
private
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
const
|
|
548
|
-
const committed = this.currentCameraSource(pixelRatio);
|
|
747
|
+
private cameraCandidate(): CameraCandidate | null {
|
|
748
|
+
const geometry = planNativeWorkerSceneGeometry(this.sceneGeometry());
|
|
749
|
+
const { viewport } = geometry;
|
|
750
|
+
const committed = this.currentCameraSource(geometry.pixelRatio);
|
|
549
751
|
if (!committed) return null;
|
|
752
|
+
const pixelRatio = committed.scene.pixelRatio;
|
|
550
753
|
const width = Math.ceil(viewport.width * pixelRatio);
|
|
551
754
|
const height = Math.ceil(viewport.height * pixelRatio);
|
|
552
755
|
if (
|
|
@@ -557,10 +760,52 @@ export class NativeWorkerSceneHost {
|
|
|
557
760
|
viewport.height <= 0 ||
|
|
558
761
|
width < 1 ||
|
|
559
762
|
height < 1 ||
|
|
560
|
-
width >
|
|
561
|
-
height >
|
|
763
|
+
width > NATIVE_WORKER_MAX_DIMENSION ||
|
|
764
|
+
height > NATIVE_WORKER_MAX_DIMENSION ||
|
|
765
|
+
width * height > NATIVE_WORKER_MAX_PIXELS
|
|
562
766
|
)
|
|
563
767
|
return null;
|
|
768
|
+
const sourceClock = this.clock();
|
|
769
|
+
return {
|
|
770
|
+
committed,
|
|
771
|
+
viewport,
|
|
772
|
+
width,
|
|
773
|
+
height,
|
|
774
|
+
pixelRatio,
|
|
775
|
+
clock: this.snapshotClock(viewport, false, sourceClock),
|
|
776
|
+
clockIdentity: this.clockIdentity(sourceClock),
|
|
777
|
+
};
|
|
778
|
+
}
|
|
779
|
+
|
|
780
|
+
private sameCamera(
|
|
781
|
+
candidate: CameraCandidate,
|
|
782
|
+
scene: NativeWorkerScene,
|
|
783
|
+
publication: Publication,
|
|
784
|
+
): boolean {
|
|
785
|
+
const { viewport, clock, clockIdentity } = candidate;
|
|
786
|
+
const previousIdentity = publication.clockIdentity;
|
|
787
|
+
return (
|
|
788
|
+
scene.viewport.x === viewport.x &&
|
|
789
|
+
scene.viewport.y === viewport.y &&
|
|
790
|
+
scene.viewport.width === viewport.width &&
|
|
791
|
+
scene.viewport.height === viewport.height &&
|
|
792
|
+
scene.width === candidate.width &&
|
|
793
|
+
scene.height === candidate.height &&
|
|
794
|
+
scene.pixelRatio === candidate.pixelRatio &&
|
|
795
|
+
scene.clock.playing === clock.playing &&
|
|
796
|
+
scene.clock.speed === clock.speed &&
|
|
797
|
+
previousIdentity?.sourcePlaying === clockIdentity.sourcePlaying &&
|
|
798
|
+
(clockIdentity.sourcePlaying
|
|
799
|
+
? clockIdentity.origin !== null &&
|
|
800
|
+
clockIdentity.origin === previousIdentity?.origin
|
|
801
|
+
: scene.clock.timeSeconds === clock.timeSeconds)
|
|
802
|
+
);
|
|
803
|
+
}
|
|
804
|
+
|
|
805
|
+
private reprojectSnapshot(
|
|
806
|
+
candidate: CameraCandidate,
|
|
807
|
+
): Awaited<ReturnType<NativeWorkerSceneHost["captureSnapshot"]>> {
|
|
808
|
+
const { committed, viewport, width, height, pixelRatio, clock } = candidate;
|
|
564
809
|
const generation = ++this.generation;
|
|
565
810
|
return {
|
|
566
811
|
scene: {
|
|
@@ -569,11 +814,16 @@ export class NativeWorkerSceneHost {
|
|
|
569
814
|
viewport,
|
|
570
815
|
width,
|
|
571
816
|
height,
|
|
572
|
-
|
|
817
|
+
pixelRatio,
|
|
818
|
+
clock,
|
|
573
819
|
},
|
|
574
820
|
assets: [],
|
|
575
821
|
revisions: new Map(this.assetRevisions),
|
|
576
|
-
publication: {
|
|
822
|
+
publication: {
|
|
823
|
+
...committed.publication,
|
|
824
|
+
generation,
|
|
825
|
+
clockIdentity: candidate.clockIdentity,
|
|
826
|
+
},
|
|
577
827
|
};
|
|
578
828
|
}
|
|
579
829
|
|
|
@@ -600,12 +850,13 @@ export class NativeWorkerSceneHost {
|
|
|
600
850
|
}
|
|
601
851
|
|
|
602
852
|
private async updateLoop(): Promise<void> {
|
|
603
|
-
if (this.disposed || this.updating) return;
|
|
853
|
+
if (this.disposed || this.holdingLastFrame || this.updating) return;
|
|
604
854
|
this.updating = true;
|
|
605
855
|
try {
|
|
606
856
|
while (
|
|
607
857
|
this.dirty &&
|
|
608
858
|
!this.disposed &&
|
|
859
|
+
!this.holdingLastFrame &&
|
|
609
860
|
!this.capturingExport &&
|
|
610
861
|
this.visible
|
|
611
862
|
) {
|
|
@@ -613,6 +864,7 @@ export class NativeWorkerSceneHost {
|
|
|
613
864
|
try {
|
|
614
865
|
await this.sendSnapshot();
|
|
615
866
|
} catch (error) {
|
|
867
|
+
if (this.disposed || this.holdingLastFrame) return;
|
|
616
868
|
this.assetRevisions.clear();
|
|
617
869
|
this.onFailure(
|
|
618
870
|
error instanceof Error ? error : new Error(String(error)),
|
|
@@ -650,8 +902,7 @@ export class NativeWorkerSceneHost {
|
|
|
650
902
|
node.nodeType === Node.TEXT_NODE && !!node.textContent?.trim(),
|
|
651
903
|
) ||
|
|
652
904
|
[...body.children].some(
|
|
653
|
-
(child) =>
|
|
654
|
-
!(child instanceof HTMLElement || child instanceof SVGSVGElement),
|
|
905
|
+
(child) => !isNativeScenePresentationElement(child),
|
|
655
906
|
)
|
|
656
907
|
)
|
|
657
908
|
throw new NativeSourceError(
|
|
@@ -674,19 +925,18 @@ export class NativeWorkerSceneHost {
|
|
|
674
925
|
"scene-background-unsupported",
|
|
675
926
|
"The native worker scene has an unsupported root background.",
|
|
676
927
|
);
|
|
677
|
-
if (
|
|
678
|
-
bodyStyle.transform !== "none" ||
|
|
679
|
-
bodyStyle.translate !== "none" ||
|
|
680
|
-
bodyStyle.rotate !== "none" ||
|
|
681
|
-
bodyStyle.scale !== "none" ||
|
|
682
|
-
bodyStyle.opacity !== "1"
|
|
683
|
-
)
|
|
928
|
+
if (!supportsNativeSceneBodyTransform(bodyStyle))
|
|
684
929
|
throw new NativeSourceError(
|
|
685
930
|
"scene-presentation-transform-unsupported",
|
|
686
931
|
"The native worker scene cannot project a transformed or translucent body.",
|
|
687
932
|
);
|
|
933
|
+
attachNativeScenePresentationCanvas(this.canvas, body, bodyStyle);
|
|
934
|
+
const requestedGeometry = this.sceneGeometry();
|
|
935
|
+
const plannedGeometry = options
|
|
936
|
+
? requestedGeometry
|
|
937
|
+
: planNativeWorkerSceneGeometry(requestedGeometry);
|
|
688
938
|
const { viewport: previewViewport, pixelRatio: requestedPixelRatio } =
|
|
689
|
-
|
|
939
|
+
plannedGeometry;
|
|
690
940
|
const viewport = options?.cropRect ?? previewViewport;
|
|
691
941
|
const pixelRatio = options?.pixelRatio ?? requestedPixelRatio;
|
|
692
942
|
const width = Math.ceil(viewport.width * pixelRatio);
|
|
@@ -696,9 +946,9 @@ export class NativeWorkerSceneHost {
|
|
|
696
946
|
pixelRatio <= 0 ||
|
|
697
947
|
width < 1 ||
|
|
698
948
|
height < 1 ||
|
|
699
|
-
width >
|
|
700
|
-
height >
|
|
701
|
-
width * height >
|
|
949
|
+
width > NATIVE_WORKER_MAX_DIMENSION ||
|
|
950
|
+
height > NATIVE_WORKER_MAX_DIMENSION ||
|
|
951
|
+
width * height > NATIVE_WORKER_MAX_PIXELS
|
|
702
952
|
)
|
|
703
953
|
throw new NativeSourceError(
|
|
704
954
|
"worker-viewport-budget-exceeded",
|
|
@@ -724,7 +974,16 @@ export class NativeWorkerSceneHost {
|
|
|
724
974
|
>();
|
|
725
975
|
const extents = new Map<string, NativeEffectExtentPlan>();
|
|
726
976
|
const previousByTarget = new Map<Element, string>();
|
|
727
|
-
|
|
977
|
+
const targetRects = new Map<HTMLElement | SVGSVGElement, DOMRect>();
|
|
978
|
+
const drawableEntries = this.entries.filter((entry) => {
|
|
979
|
+
let rect = targetRects.get(entry.target);
|
|
980
|
+
if (!rect) {
|
|
981
|
+
rect = entry.target.getBoundingClientRect();
|
|
982
|
+
targetRects.set(entry.target, rect);
|
|
983
|
+
}
|
|
984
|
+
return nativeWorkerTargetDrawable(rect);
|
|
985
|
+
});
|
|
986
|
+
for (const entry of drawableEntries) {
|
|
728
987
|
const state = this.targets.get(entry.instance.id);
|
|
729
988
|
if (!state || state.entry.target !== entry.target)
|
|
730
989
|
throw new NativeSourceError(
|
|
@@ -732,14 +991,14 @@ export class NativeWorkerSceneHost {
|
|
|
732
991
|
"A native worker target changed during scene capture.",
|
|
733
992
|
);
|
|
734
993
|
const layout = this.layout(entry.target);
|
|
735
|
-
const visible = entry.target
|
|
994
|
+
const visible = targetRects.get(entry.target)!;
|
|
736
995
|
const displayScale = Math.max(
|
|
737
996
|
visible.width / layout.width,
|
|
738
997
|
visible.height / layout.height,
|
|
739
998
|
);
|
|
740
999
|
const targetPixelRatio = pixelRatio * displayScale;
|
|
741
1000
|
const geometry = nativeWorkerTargetGeometry(
|
|
742
|
-
|
|
1001
|
+
visible,
|
|
743
1002
|
targetPixelRatio,
|
|
744
1003
|
layout.width,
|
|
745
1004
|
layout.height,
|
|
@@ -759,8 +1018,8 @@ export class NativeWorkerSceneHost {
|
|
|
759
1018
|
cssWidth: layout.width,
|
|
760
1019
|
cssHeight: layout.height,
|
|
761
1020
|
pixelRatio: targetPixelRatio,
|
|
762
|
-
maxDimension:
|
|
763
|
-
maxPixels:
|
|
1021
|
+
maxDimension: NATIVE_WORKER_MAX_DIMENSION,
|
|
1022
|
+
maxPixels: NATIVE_WORKER_MAX_PIXELS,
|
|
764
1023
|
previous,
|
|
765
1024
|
});
|
|
766
1025
|
if (!planned.ok)
|
|
@@ -849,12 +1108,12 @@ export class NativeWorkerSceneHost {
|
|
|
849
1108
|
`${options ? `export:${generation}:` : ""}${entry.instance.id}:provider:${state.captureScope}:epoch:${targetSourceEpoch}`,
|
|
850
1109
|
receiver,
|
|
851
1110
|
needsGeometry,
|
|
852
|
-
needsInterior && entry.target
|
|
1111
|
+
needsInterior && isNativeSvgRoot(entry.target),
|
|
853
1112
|
);
|
|
854
1113
|
let cornerRadii: NativeWorkerEffectTarget["cornerRadii"];
|
|
855
1114
|
if (
|
|
856
1115
|
entry.instance.clip === "bounds" &&
|
|
857
|
-
entry.target
|
|
1116
|
+
isNativeHtmlElement(entry.target)
|
|
858
1117
|
) {
|
|
859
1118
|
const radius = resolveNativeClipRadii({
|
|
860
1119
|
width: outputExtent.sourceWidth,
|
|
@@ -954,6 +1213,39 @@ export class NativeWorkerSceneHost {
|
|
|
954
1213
|
"worker-target-epoch-stale",
|
|
955
1214
|
"The native effect target changed during capture.",
|
|
956
1215
|
);
|
|
1216
|
+
const inputPlan = planNativeInputResources(
|
|
1217
|
+
entry.definition,
|
|
1218
|
+
entry.instance,
|
|
1219
|
+
);
|
|
1220
|
+
if (!inputPlan.ok)
|
|
1221
|
+
throw new NativeSourceError(inputPlan.code, inputPlan.detail);
|
|
1222
|
+
const inputAssetIds: Record<string, string> = {};
|
|
1223
|
+
for (const [resource, input] of inputPlan.inputs) {
|
|
1224
|
+
if (input.kind !== "asset") continue;
|
|
1225
|
+
const sampleEncoding = input.sampleEncoding ?? "srgb-color";
|
|
1226
|
+
if (
|
|
1227
|
+
(sampleEncoding !== "srgb-color" &&
|
|
1228
|
+
sampleEncoding !== "linear-data") ||
|
|
1229
|
+
input.preprocess !== undefined ||
|
|
1230
|
+
input.mipmap !== undefined
|
|
1231
|
+
)
|
|
1232
|
+
throw new NativeSourceError(
|
|
1233
|
+
"worker-input-processing-unsupported",
|
|
1234
|
+
`The worker cannot process input ${resource}.`,
|
|
1235
|
+
);
|
|
1236
|
+
const assetId = nativeWorkerInputAssetId(input);
|
|
1237
|
+
if (!assetId)
|
|
1238
|
+
throw new NativeSourceError(
|
|
1239
|
+
"worker-input-asset-unsupported",
|
|
1240
|
+
`The worker cannot identify input ${resource}.`,
|
|
1241
|
+
);
|
|
1242
|
+
inputAssetIds[resource] = await snapshot.inputBitmap(
|
|
1243
|
+
assetId,
|
|
1244
|
+
1,
|
|
1245
|
+
() => this.inputAssets.bitmap(input.url, sampleEncoding),
|
|
1246
|
+
sampleEncoding,
|
|
1247
|
+
);
|
|
1248
|
+
}
|
|
957
1249
|
targetSnapshots.push({
|
|
958
1250
|
instanceId: entry.instance.id,
|
|
959
1251
|
definitionHash: entry.definitionHash,
|
|
@@ -964,18 +1256,19 @@ export class NativeWorkerSceneHost {
|
|
|
964
1256
|
pixelRatio: targetPixelRatio,
|
|
965
1257
|
sourceRecords,
|
|
966
1258
|
...coverage,
|
|
1259
|
+
...(Object.keys(inputAssetIds).length ? { inputAssetIds } : {}),
|
|
967
1260
|
...(cornerRadii ? { cornerRadii } : {}),
|
|
968
1261
|
...(textMaskAssetId ? { textMaskAssetId } : {}),
|
|
969
1262
|
...(fillPhases ? { fillPhases } : {}),
|
|
970
1263
|
});
|
|
971
1264
|
}
|
|
972
|
-
for (const entry of
|
|
1265
|
+
for (const entry of drawableEntries) {
|
|
973
1266
|
if (entry.instance.placement !== "backdrop") continue;
|
|
974
|
-
const owners =
|
|
1267
|
+
const owners = drawableEntries.filter(
|
|
975
1268
|
(candidate, index) =>
|
|
976
1269
|
(candidate.instance.placement === "layer" ||
|
|
977
1270
|
(candidate.instance.placement === "fill" &&
|
|
978
|
-
|
|
1271
|
+
drawableEntries.every(
|
|
979
1272
|
(other, otherIndex) =>
|
|
980
1273
|
otherIndex <= index ||
|
|
981
1274
|
other.instance.placement !== "fill" ||
|
|
@@ -1013,7 +1306,7 @@ export class NativeWorkerSceneHost {
|
|
|
1013
1306
|
);
|
|
1014
1307
|
if (nearest) child.groupLocalOwnerId = nearest.instance.id;
|
|
1015
1308
|
if (!nearest || nearest.instance.placement !== "fill") continue;
|
|
1016
|
-
if (!(nearest.target
|
|
1309
|
+
if (!isNativeHtmlElement(nearest.target))
|
|
1017
1310
|
throw new NativeSourceError(
|
|
1018
1311
|
"source-inline-svg",
|
|
1019
1312
|
"An SVG Fill cannot contain a nested HTML Backdrop.",
|
|
@@ -1094,30 +1387,17 @@ export class NativeWorkerSceneHost {
|
|
|
1094
1387
|
records,
|
|
1095
1388
|
);
|
|
1096
1389
|
}
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
if (target.fillPhases)
|
|
1109
|
-
for (const key of Object.keys(target.fillPhases) as Array<
|
|
1110
|
-
keyof NonNullable<NativeWorkerEffectTarget["fillPhases"]>
|
|
1111
|
-
>)
|
|
1112
|
-
target.fillPhases[key] = nativeWorkerOutputRecords(
|
|
1113
|
-
target.fillPhases[key],
|
|
1114
|
-
nativeOutputSizes,
|
|
1115
|
-
);
|
|
1116
|
-
}
|
|
1117
|
-
const rawRootRecords = await this.provider.readScene(
|
|
1118
|
-
undefined,
|
|
1119
|
-
"scene-presentation",
|
|
1120
|
-
);
|
|
1390
|
+
let rawRootRecords: NativeSourceRecord[];
|
|
1391
|
+
try {
|
|
1392
|
+
rawRootRecords = await this.provider.readScene(
|
|
1393
|
+
undefined,
|
|
1394
|
+
"scene-presentation",
|
|
1395
|
+
);
|
|
1396
|
+
} catch (error) {
|
|
1397
|
+
if (!options && error instanceof NativeSourceCapabilityError)
|
|
1398
|
+
throw new NativeWorkerSceneSourceError(error);
|
|
1399
|
+
throw error;
|
|
1400
|
+
}
|
|
1121
1401
|
if (
|
|
1122
1402
|
this.provider.needsContinuousFrames() ||
|
|
1123
1403
|
(await this.provider.replaySafety(
|
|
@@ -1160,9 +1440,11 @@ export class NativeWorkerSceneHost {
|
|
|
1160
1440
|
: `root:epoch:${sourceEpoch}`,
|
|
1161
1441
|
rawRootRecords,
|
|
1162
1442
|
);
|
|
1163
|
-
const normalizedRootRecords =
|
|
1164
|
-
|
|
1165
|
-
|
|
1443
|
+
const normalizedRootRecords = nativeWorkerOutputSceneRecords(
|
|
1444
|
+
targetSnapshots,
|
|
1445
|
+
allRootRecords,
|
|
1446
|
+
nativeOutputSizes,
|
|
1447
|
+
);
|
|
1166
1448
|
const selected = options?.selectedRoots
|
|
1167
1449
|
? new Set(finalRootRecords)
|
|
1168
1450
|
: null;
|
|
@@ -1172,6 +1454,8 @@ export class NativeWorkerSceneHost {
|
|
|
1172
1454
|
)
|
|
1173
1455
|
: normalizedRootRecords;
|
|
1174
1456
|
const { assets, requiredAssets, revisions } = snapshot.finish();
|
|
1457
|
+
const sourceClock = this.clock();
|
|
1458
|
+
const cadence = this.sceneCadence();
|
|
1175
1459
|
const scene: NativeWorkerScene = {
|
|
1176
1460
|
sceneId: this.worker.sceneId,
|
|
1177
1461
|
generation,
|
|
@@ -1182,10 +1466,12 @@ export class NativeWorkerSceneHost {
|
|
|
1182
1466
|
height,
|
|
1183
1467
|
pixelRatio,
|
|
1184
1468
|
colorSpace: "srgb",
|
|
1185
|
-
|
|
1469
|
+
frameRateTarget: cadence.frameRateTarget,
|
|
1470
|
+
compact: cadence.compact,
|
|
1471
|
+
clock: this.snapshotClock(viewport, !!options, sourceClock),
|
|
1186
1472
|
requiredAssets,
|
|
1187
|
-
definitions:
|
|
1188
|
-
instances:
|
|
1473
|
+
definitions: nativeWorkerDefinitions(drawableEntries),
|
|
1474
|
+
instances: drawableEntries.map((entry) => entry.instance),
|
|
1189
1475
|
targets: targetSnapshots,
|
|
1190
1476
|
records,
|
|
1191
1477
|
...(selected ? { backdropRecords: normalizedRootRecords } : {}),
|
|
@@ -1206,6 +1492,7 @@ export class NativeWorkerSceneHost {
|
|
|
1206
1492
|
generation,
|
|
1207
1493
|
sourceEpoch: sourceEpoch!,
|
|
1208
1494
|
authoredEpoch: authoredEpoch!,
|
|
1495
|
+
clockIdentity: this.clockIdentity(sourceClock),
|
|
1209
1496
|
rootWidth,
|
|
1210
1497
|
rootHeight,
|
|
1211
1498
|
targetEpochs: new Map(
|
|
@@ -1229,6 +1516,15 @@ export class NativeWorkerSceneHost {
|
|
|
1229
1516
|
),
|
|
1230
1517
|
rootRecords: rawRootRecords,
|
|
1231
1518
|
payloads: new Map(
|
|
1519
|
+
drawableEntries.map((entry) => [
|
|
1520
|
+
entry.instance.id,
|
|
1521
|
+
{
|
|
1522
|
+
payload: JSON.stringify(entry.instance),
|
|
1523
|
+
definitionHash: entry.definitionHash,
|
|
1524
|
+
},
|
|
1525
|
+
]),
|
|
1526
|
+
),
|
|
1527
|
+
authoredPayloads: new Map(
|
|
1232
1528
|
this.entries.map((entry) => [
|
|
1233
1529
|
entry.instance.id,
|
|
1234
1530
|
{
|
|
@@ -1247,15 +1543,34 @@ export class NativeWorkerSceneHost {
|
|
|
1247
1543
|
}
|
|
1248
1544
|
|
|
1249
1545
|
private async sendSnapshot(): Promise<void> {
|
|
1546
|
+
const camera = this.cameraCandidate();
|
|
1250
1547
|
if (this.cameraInFlightGeneration !== null) {
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1548
|
+
if (camera) {
|
|
1549
|
+
const pendingScene = this.scenes.get(this.cameraInFlightGeneration);
|
|
1550
|
+
const pendingPublication = this.staged.get(
|
|
1551
|
+
this.cameraInFlightGeneration,
|
|
1552
|
+
);
|
|
1553
|
+
this.cameraUpdatePending = !(
|
|
1554
|
+
this.publicationWaiters.size === 0 &&
|
|
1555
|
+
pendingScene &&
|
|
1556
|
+
pendingPublication &&
|
|
1557
|
+
this.sameCamera(camera, pendingScene, pendingPublication)
|
|
1558
|
+
);
|
|
1254
1559
|
return;
|
|
1255
1560
|
}
|
|
1256
1561
|
this.clearCameraSubmission();
|
|
1257
1562
|
}
|
|
1258
|
-
|
|
1563
|
+
if (
|
|
1564
|
+
camera &&
|
|
1565
|
+
this.publicationWaiters.size === 0 &&
|
|
1566
|
+
this.sameCamera(
|
|
1567
|
+
camera,
|
|
1568
|
+
camera.committed.scene,
|
|
1569
|
+
camera.committed.publication,
|
|
1570
|
+
)
|
|
1571
|
+
)
|
|
1572
|
+
return;
|
|
1573
|
+
const cameraSnapshot = camera ? this.reprojectSnapshot(camera) : null;
|
|
1259
1574
|
const { scene, assets, revisions, publication } =
|
|
1260
1575
|
cameraSnapshot ?? (await this.captureSnapshot());
|
|
1261
1576
|
const generation = scene.generation;
|
|
@@ -1359,7 +1674,7 @@ export class NativeWorkerSceneHost {
|
|
|
1359
1674
|
generation: number,
|
|
1360
1675
|
isExport: boolean,
|
|
1361
1676
|
): Promise<string> {
|
|
1362
|
-
if (!(entry.target
|
|
1677
|
+
if (!isNativeHtmlElement(entry.target))
|
|
1363
1678
|
throw new NativeSourceError(
|
|
1364
1679
|
"source-inline-svg",
|
|
1365
1680
|
"An SVG Fill uses vector coverage rather than a text mask.",
|
|
@@ -1467,60 +1782,77 @@ export class NativeWorkerSceneHost {
|
|
|
1467
1782
|
this.requestUpdate();
|
|
1468
1783
|
return;
|
|
1469
1784
|
}
|
|
1470
|
-
const
|
|
1785
|
+
const replacedPresentation = this.hasPresentationToRetire?.() === true;
|
|
1786
|
+
const cameraOnly =
|
|
1787
|
+
!replacedPresentation && this.canReuseCommittedPresentation(publication);
|
|
1471
1788
|
const paintedChildren = new Set<Element>();
|
|
1472
|
-
for (const record of publication.rootRecords) {
|
|
1473
|
-
const root = scenePaintRoot(record.node, body);
|
|
1474
|
-
if (root && root !== this.canvas && !root.matches(OMIT_SCENE_CHILD))
|
|
1475
|
-
paintedChildren.add(root);
|
|
1476
|
-
}
|
|
1477
1789
|
const authoredOpacities = new Map<Element, string>();
|
|
1478
|
-
|
|
1479
|
-
const
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1790
|
+
if (!cameraOnly) {
|
|
1791
|
+
const body = document.body;
|
|
1792
|
+
for (const record of publication.rootRecords) {
|
|
1793
|
+
const root = scenePaintRoot(record.node, body);
|
|
1794
|
+
if (root && root !== this.canvas && !root.matches(OMIT_SCENE_CHILD))
|
|
1795
|
+
paintedChildren.add(root);
|
|
1796
|
+
}
|
|
1797
|
+
for (const child of paintedChildren) {
|
|
1798
|
+
const opacity =
|
|
1799
|
+
child.getAttribute("data-an-native-authored-opacity") ??
|
|
1800
|
+
getComputedStyle(child).opacity;
|
|
1801
|
+
const value = Number(opacity);
|
|
1802
|
+
if (
|
|
1803
|
+
!opacity.trim() ||
|
|
1804
|
+
!Number.isFinite(value) ||
|
|
1805
|
+
value < 0 ||
|
|
1806
|
+
value > 1
|
|
1807
|
+
) {
|
|
1808
|
+
this.onFailure(
|
|
1809
|
+
new NativeSourceError(
|
|
1810
|
+
"worker-scene-opacity-unreadable",
|
|
1811
|
+
"The native worker scene has unreadable authored opacity.",
|
|
1812
|
+
),
|
|
1813
|
+
);
|
|
1814
|
+
return;
|
|
1815
|
+
}
|
|
1816
|
+
authoredOpacities.set(child, opacity);
|
|
1496
1817
|
}
|
|
1497
|
-
authoredOpacities.set(child, opacity);
|
|
1498
|
-
}
|
|
1499
|
-
for (const old of this.suppressed) {
|
|
1500
|
-
if (paintedChildren.has(old)) continue;
|
|
1501
|
-
old.removeAttribute("data-an-native-scene-suppressed");
|
|
1502
|
-
old.removeAttribute("data-an-native-authored-opacity");
|
|
1503
|
-
this.suppressed.delete(old);
|
|
1504
1818
|
}
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
);
|
|
1819
|
+
this.beforeCommit?.();
|
|
1820
|
+
if (replacedPresentation) this.restoreEntryMarkersAndVisibility();
|
|
1821
|
+
if (!cameraOnly) {
|
|
1822
|
+
for (const old of this.suppressed) {
|
|
1823
|
+
if (paintedChildren.has(old)) continue;
|
|
1824
|
+
old.removeAttribute("data-an-native-scene-suppressed");
|
|
1825
|
+
old.removeAttribute("data-an-native-authored-opacity");
|
|
1826
|
+
this.suppressed.delete(old);
|
|
1827
|
+
}
|
|
1828
|
+
for (const child of paintedChildren) {
|
|
1829
|
+
if (!child.hasAttribute("data-an-native-authored-opacity")) {
|
|
1830
|
+
child.setAttribute(
|
|
1831
|
+
"data-an-native-authored-opacity",
|
|
1832
|
+
authoredOpacities.get(child)!,
|
|
1833
|
+
);
|
|
1834
|
+
}
|
|
1835
|
+
child.setAttribute("data-an-native-scene-suppressed", "");
|
|
1836
|
+
this.suppressed.add(child);
|
|
1511
1837
|
}
|
|
1512
|
-
child.setAttribute("data-an-native-scene-suppressed", "");
|
|
1513
|
-
this.suppressed.add(child);
|
|
1514
1838
|
}
|
|
1515
1839
|
const presentedScene = this.scenes.get(publication.generation);
|
|
1516
1840
|
if (presentedScene) {
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1841
|
+
const { style } = this.canvas;
|
|
1842
|
+
const { viewport } = presentedScene;
|
|
1843
|
+
const left = `${viewport.x}px`;
|
|
1844
|
+
const top = `${viewport.y}px`;
|
|
1845
|
+
const width = `${viewport.width}px`;
|
|
1846
|
+
const height = `${viewport.height}px`;
|
|
1847
|
+
if (style.left !== left) style.left = left;
|
|
1848
|
+
if (style.top !== top) style.top = top;
|
|
1849
|
+
if (style.width !== width) style.width = width;
|
|
1850
|
+
if (style.height !== height) style.height = height;
|
|
1851
|
+
}
|
|
1852
|
+
if (!cameraOnly) {
|
|
1853
|
+
this.canvas.style.visibility = "visible";
|
|
1854
|
+
document.documentElement.setAttribute("data-an-native-scene-managed", "");
|
|
1521
1855
|
}
|
|
1522
|
-
this.canvas.style.visibility = "visible";
|
|
1523
|
-
document.documentElement.setAttribute("data-an-native-scene-managed", "");
|
|
1524
1856
|
this.committed = publication;
|
|
1525
1857
|
this.committedSceneSnapshot =
|
|
1526
1858
|
this.scenes.get(publication.generation) ?? null;
|
|
@@ -1529,23 +1861,25 @@ export class NativeWorkerSceneHost {
|
|
|
1529
1861
|
this.cameraUpdatePending;
|
|
1530
1862
|
if (this.cameraInFlightGeneration === publication.generation)
|
|
1531
1863
|
this.clearCameraSubmission();
|
|
1532
|
-
|
|
1533
|
-
entry.
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1864
|
+
if (!cameraOnly)
|
|
1865
|
+
for (const entry of this.entries) {
|
|
1866
|
+
entry.target.setAttribute("data-an-native-status", "ready");
|
|
1867
|
+
entry.target.setAttribute("data-an-native-backend", "webgpu-worker");
|
|
1868
|
+
entry.target.removeAttribute("data-an-native-error");
|
|
1869
|
+
entry.target.removeAttribute("data-an-native-error-message");
|
|
1870
|
+
}
|
|
1538
1871
|
for (const generation of this.staged.keys())
|
|
1539
1872
|
if (generation <= publication.generation) this.staged.delete(generation);
|
|
1540
1873
|
for (const generation of this.scenes.keys())
|
|
1541
1874
|
if (generation < publication.generation) this.scenes.delete(generation);
|
|
1542
1875
|
this.onCommitted(publication, {
|
|
1543
1876
|
timeSeconds: message.timeSeconds,
|
|
1877
|
+
contentChanged: !cameraOnly,
|
|
1544
1878
|
committedInstances: message.committedInstances,
|
|
1545
1879
|
});
|
|
1546
1880
|
if (drainCamera) this.requestUpdate();
|
|
1547
1881
|
for (const waiter of this.publicationWaiters) {
|
|
1548
|
-
const expected = publication.
|
|
1882
|
+
const expected = publication.authoredPayloads.get(waiter.instanceId);
|
|
1549
1883
|
const committedScene = this.committedSceneSnapshot;
|
|
1550
1884
|
if (
|
|
1551
1885
|
publication.generation < waiter.minimumGeneration ||
|
|
@@ -1562,6 +1896,42 @@ export class NativeWorkerSceneHost {
|
|
|
1562
1896
|
}
|
|
1563
1897
|
}
|
|
1564
1898
|
|
|
1899
|
+
private canReuseCommittedPresentation(publication: Publication): boolean {
|
|
1900
|
+
const committed = this.committed;
|
|
1901
|
+
if (
|
|
1902
|
+
!committed ||
|
|
1903
|
+
committed.sourceEpoch !== publication.sourceEpoch ||
|
|
1904
|
+
committed.authoredEpoch !== publication.authoredEpoch ||
|
|
1905
|
+
committed.rootWidth !== publication.rootWidth ||
|
|
1906
|
+
committed.rootHeight !== publication.rootHeight ||
|
|
1907
|
+
committed.targetEpochs !== publication.targetEpochs ||
|
|
1908
|
+
committed.rootRecords !== publication.rootRecords ||
|
|
1909
|
+
committed.payloads !== publication.payloads ||
|
|
1910
|
+
committed.authoredPayloads !== publication.authoredPayloads ||
|
|
1911
|
+
this.canvas.style.visibility !== "visible" ||
|
|
1912
|
+
!document.documentElement.hasAttribute("data-an-native-scene-managed")
|
|
1913
|
+
)
|
|
1914
|
+
return false;
|
|
1915
|
+
for (const entry of this.entries) {
|
|
1916
|
+
if (
|
|
1917
|
+
entry.target.getAttribute("data-an-native-status") !== "ready" ||
|
|
1918
|
+
entry.target.getAttribute("data-an-native-backend") !==
|
|
1919
|
+
"webgpu-worker" ||
|
|
1920
|
+
entry.target.hasAttribute("data-an-native-error") ||
|
|
1921
|
+
entry.target.hasAttribute("data-an-native-error-message")
|
|
1922
|
+
)
|
|
1923
|
+
return false;
|
|
1924
|
+
}
|
|
1925
|
+
for (const child of this.suppressed)
|
|
1926
|
+
if (
|
|
1927
|
+
!child.isConnected ||
|
|
1928
|
+
!child.hasAttribute("data-an-native-scene-suppressed") ||
|
|
1929
|
+
!child.hasAttribute("data-an-native-authored-opacity")
|
|
1930
|
+
)
|
|
1931
|
+
return false;
|
|
1932
|
+
return true;
|
|
1933
|
+
}
|
|
1934
|
+
|
|
1565
1935
|
committedScene(): {
|
|
1566
1936
|
scene: NativeWorkerScene;
|
|
1567
1937
|
publication: Publication;
|
|
@@ -1581,6 +1951,7 @@ export class NativeWorkerSceneHost {
|
|
|
1581
1951
|
window.removeEventListener("scroll", this.requestUpdate, true);
|
|
1582
1952
|
window.removeEventListener("resize", this.requestUpdate);
|
|
1583
1953
|
this.worker.dispose();
|
|
1954
|
+
this.inputAssets.dispose();
|
|
1584
1955
|
this.provider.dispose();
|
|
1585
1956
|
for (const state of this.targets.values()) {
|
|
1586
1957
|
state.provider.dispose();
|
|
@@ -1683,25 +2054,32 @@ export class NativeWorkerSceneHost {
|
|
|
1683
2054
|
scene.authoredEpoch === hiddenAuthoredEpoch &&
|
|
1684
2055
|
this.provider.sourceEpoch?.() === scene.sourceEpoch &&
|
|
1685
2056
|
this.provider.authoredSourceEpoch?.() === hiddenAuthoredEpoch &&
|
|
1686
|
-
|
|
1687
|
-
|
|
2057
|
+
this.entries.length === hiddenPayloads.length &&
|
|
2058
|
+
captured.publication.authoredPayloads.size === hiddenPayloads.length &&
|
|
1688
2059
|
!hiddenPayloads.some((expected, index) => {
|
|
1689
2060
|
const entry = this.entries[index];
|
|
1690
|
-
const target = scene.targets
|
|
1691
|
-
|
|
2061
|
+
const target = scene.targets.find(
|
|
2062
|
+
(item) => item.instanceId === expected.id,
|
|
2063
|
+
);
|
|
2064
|
+
const instance = scene.instances.find(
|
|
2065
|
+
(item) => item.id === expected.id,
|
|
2066
|
+
);
|
|
2067
|
+
const payload = captured.publication.authoredPayloads.get(
|
|
2068
|
+
expected.id,
|
|
2069
|
+
);
|
|
1692
2070
|
const provider = this.targets.get(expected.id)?.provider;
|
|
1693
2071
|
const capturedEpoch = captured.publication.targetEpochs.get(
|
|
1694
2072
|
expected.id,
|
|
1695
2073
|
);
|
|
1696
2074
|
return (
|
|
1697
2075
|
!entry ||
|
|
1698
|
-
!
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
target
|
|
1702
|
-
JSON.stringify(instance) !== expected.payload ||
|
|
2076
|
+
!payload ||
|
|
2077
|
+
payload.payload !== expected.payload ||
|
|
2078
|
+
payload.definitionHash !== expected.definitionHash ||
|
|
2079
|
+
!!target !== !!instance ||
|
|
2080
|
+
(instance && JSON.stringify(instance) !== expected.payload) ||
|
|
1703
2081
|
JSON.stringify(entry.instance) !== expected.payload ||
|
|
1704
|
-
target.definitionHash !== expected.definitionHash ||
|
|
2082
|
+
(target && target.definitionHash !== expected.definitionHash) ||
|
|
1705
2083
|
entry.definitionHash !== expected.definitionHash ||
|
|
1706
2084
|
!capturedEpoch ||
|
|
1707
2085
|
provider?.sourceEpoch?.() !== capturedEpoch.source ||
|
|
@@ -1789,6 +2167,7 @@ export class NativeWorkerSceneHost {
|
|
|
1789
2167
|
window.removeEventListener("scroll", this.requestUpdate, true);
|
|
1790
2168
|
window.removeEventListener("resize", this.requestUpdate);
|
|
1791
2169
|
this.worker.dispose();
|
|
2170
|
+
this.inputAssets.dispose();
|
|
1792
2171
|
this.provider.dispose();
|
|
1793
2172
|
for (const state of this.targets.values()) {
|
|
1794
2173
|
state.provider.dispose();
|