@salsita-ai/sdk 0.50.0-develop.b5d443db78 → 0.50.0-develop.b65a5a9c66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -3
- package/dist/admin/common/admin-interface.d.ts +13 -3
- package/dist/admin/common/admin-interface.js +1 -1
- package/dist/admin/ui/layout/UserProfile.d.ts +1 -1
- package/dist/admin/ui/layout/UserProfile.js +1 -1
- package/dist/admin/ui/maintenance/ImportPresets.js +1 -1
- package/dist/application/mount-application.js +1 -1
- package/dist/application/mount-configurator.js +1 -1
- package/dist/application/studio-embedding.d.ts +6 -0
- package/dist/application/studio-embedding.js +1 -0
- package/dist/application-spec/core/enhanced-json-schema.d.ts +5 -6
- package/dist/application-spec/core/enhanced-json-schema.js +1 -1
- package/dist/application-spec/core/markers/index.d.ts +1 -0
- package/dist/application-spec/core/markers/index.js +1 -1
- package/dist/application-spec/core/markers/set-in-studio-marker.d.ts +15 -0
- package/dist/application-spec/core/markers/set-in-studio-marker.js +1 -0
- package/dist/application-spec/errors/diagnostic-codes.d.ts +22 -0
- package/dist/application-spec/errors/diagnostic-codes.js +1 -1
- package/dist/application-spec/errors/diagnostic-messages.d.ts +23 -1
- package/dist/application-spec/errors/diagnostic-messages.js +1 -1
- package/dist/application-spec/generate-application/code/domain-runtime-files.d.ts +3 -3
- package/dist/application-spec/generate-application/code/domain-runtime-files.js +1 -1
- package/dist/application-spec/generate-application/code/index.d.ts +1 -0
- package/dist/application-spec/generate-application/code/standalone-app-files.d.ts +4 -15
- package/dist/application-spec/generate-application/code/standalone-app-files.js +1 -1
- package/dist/application-spec/generate-application/code/templates/admin-config.d.ts +5 -1
- package/dist/application-spec/generate-application/code/templates/admin-config.js +4 -3
- package/dist/application-spec/generate-application/code/templates/application-types.js +5 -5
- package/dist/application-spec/generate-application/code/templates/configurator-config.js +8 -6
- package/dist/application-spec/generate-application/code/templates/configurator-domain-code.d.ts +0 -1
- package/dist/application-spec/generate-application/code/templates/configurator-domain-code.js +6 -8
- package/dist/application-spec/generate-application/code/templates/configurator-frontend-code.d.ts +1 -0
- package/dist/application-spec/generate-application/code/templates/configurator-frontend-code.js +8 -6
- package/dist/application-spec/generate-application/code/templates/domain-spec/factory-types/domain-factory-types.d.ts +6 -8
- package/dist/application-spec/generate-application/code/templates/domain-spec/factory-types/domain-factory-types.js +3 -3
- package/dist/application-spec/generate-application/code/templates/domain-spec/generate-base-configurator-builder.js +2 -1
- package/dist/application-spec/generate-application/code/templates/domain-spec/generate-domain-block.d.ts +1 -1
- package/dist/application-spec/generate-application/code/templates/domain-spec/generate-domain-block.js +38 -41
- package/dist/application-spec/generate-application/code/templates/domain-spec/generate-phx-globals.d.ts +1 -1
- package/dist/application-spec/generate-application/code/templates/domain-spec/generate-phx-globals.js +19 -3
- package/dist/application-spec/generate-application/code/templates/domain-spec.js +12 -12
- package/dist/application-spec/generate-application/code/templates/domain.js +3 -3
- package/dist/application-spec/generate-application/code/templates/editor.d.ts +1 -1
- package/dist/application-spec/generate-application/code/templates/editor.js +16 -3
- package/dist/application-spec/generate-application/code/templates/frontend-config.js +7 -3
- package/dist/application-spec/generate-application/code/templates/global-definition/generate-action-types.d.ts +3 -3
- package/dist/application-spec/generate-application/code/templates/global-definition/generate-action-types.js +3 -3
- package/dist/application-spec/generate-application/code/templates/global-definition/generate-assistant-form-element-types.d.ts +10 -6
- package/dist/application-spec/generate-application/code/templates/global-definition/generate-assistant-form-element-types.js +7 -7
- package/dist/application-spec/generate-application/code/templates/global-definition/generate-phx-types.js +12 -13
- package/dist/application-spec/generate-application/code/templates/globals.js +21 -12
- package/dist/application-spec/generate-application/code/templates/html-index.d.ts +12 -1
- package/dist/application-spec/generate-application/code/templates/html-index.js +9 -10
- package/dist/application-spec/generate-application/code/templates/index.d.ts +1 -1
- package/dist/application-spec/generate-application/code/templates/sign-in-page-options.d.ts +5 -0
- package/dist/application-spec/generate-application/code/templates/sign-in-page-options.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/core/cli.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/core/sdk.js +8 -36
- package/dist/application-spec/generate-application/code/templates/skills/core/workflow.js +15 -11
- package/dist/application-spec/generate-application/code/templates/skills/features/application-states/views-and-tools.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/index.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/index.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/panel.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/panel.js +42 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/reading-and-changing.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/reading-and-changing.js +55 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/session-setup.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/assistant/session-setup.js +16 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/custom-layout/custom-layout.js +3 -3
- package/dist/application-spec/generate-application/code/templates/skills/features/custom-layout/pages.d.ts +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/custom-layout/pages.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/custom-layout/sign-in.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/custom-layout/sign-in.js +19 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/domain-controls/custom-controls.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/domain-controls/scene-controls.js +4 -2
- package/dist/application-spec/generate-application/code/templates/skills/features/domain-model/actions.js +3 -3
- package/dist/application-spec/generate-application/code/templates/skills/features/domain-model/components.js +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/features/domain-model/expressions.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/features.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/state/violations.js +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/features/variants.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/authentication.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/authentication.js +48 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/backend-data.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/backend-data.js +45 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/entry-and-environment.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/entry-and-environment.js +36 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/finalization.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/finalization.js +92 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/index.d.ts +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/index.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/publishing.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/publishing.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/session-fields.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/session-fields.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/callback.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/callback.js +26 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/documents.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/documents.js +51 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/email.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/email.js +38 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/index.d.ts +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/index.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/integrations.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/integrations.js +88 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/links-and-images.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/links-and-images.js +68 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/tasks.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/tasks/tasks.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/webhooks.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks/webhooks.js +1 -0
- package/dist/application-spec/generate-application/code/templates/skills/guide.d.ts +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/phoenix-skill-bundle.js +3 -3
- package/dist/application-spec/generate-application/code/templates/skills/phx-members-without-guide.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/asset-conversion.js +3 -3
- package/dist/application-spec/generate-application/code/templates/skills/processes/assistant-configuration.d.ts +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/assistant-configuration.js +3 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/feedback/report.js +29 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/finalization.js +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/processes/first-draft/build.js +29 -15
- package/dist/application-spec/generate-application/code/templates/skills/processes/first-draft/direction.js +17 -14
- package/dist/application-spec/generate-application/code/templates/skills/processes/first-draft/first-draft.js +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/processes/first-draft/handoff.js +3 -3
- package/dist/application-spec/generate-application/code/templates/skills/processes/index.d.ts +2 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/index.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/model-migration.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/review/appearance.js +2 -2
- package/dist/application-spec/generate-application/code/templates/skills/processes/review/code.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/review/review.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/review/visual-inspection.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/scene-realism.d.ts +2 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/scene-realism.js +29 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/product-definition.js +2 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/specification.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/ux-specification.d.ts +2 -0
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/ux-specification.js +28 -0
- package/dist/application-spec/generate-application/code/templates/skills/sdk-content.d.ts +0 -7
- package/dist/application-spec/generate-application/code/templates/skills/sdk-content.js +1 -1
- package/dist/application-spec/generate-application/code/templates/skills/sdk-subpath-imports.js +1 -1
- package/dist/application-spec/generate-application/code/templates/webhook-builders.js +8 -6
- package/dist/application-spec/generate-application/code/templates/webhook-index.js +2 -6
- package/dist/application-spec/generate-application/code/webhook-safe-files.d.ts +3 -1
- package/dist/application-spec/generate-application/code/webhook-safe-files.js +1 -1
- package/dist/application-spec/parse-application-files/access/access-handler-kinds.d.ts +18 -0
- package/dist/application-spec/parse-application-files/access/access-handler-kinds.js +1 -0
- package/dist/application-spec/parse-application-files/access/analyzed-file.d.ts +7 -0
- package/dist/application-spec/parse-application-files/access/check-access-handler-files.d.ts +20 -0
- package/dist/application-spec/parse-application-files/access/check-access-handler-files.js +1 -0
- package/dist/application-spec/parse-application-files/access/check-auth-hook-files.d.ts +17 -0
- package/dist/application-spec/parse-application-files/access/check-auth-hook-files.js +1 -0
- package/dist/application-spec/parse-application-files/access/index.d.ts +5 -0
- package/dist/application-spec/parse-application-files/access/index.js +1 -0
- package/dist/application-spec/parse-application-files/access/sign-in-control.d.ts +7 -0
- package/dist/application-spec/parse-application-files/access/sign-in-control.js +1 -0
- package/dist/application-spec/parse-application-files/categorize/categorize-files.d.ts +2 -1
- package/dist/application-spec/parse-application-files/categorize/categorize-files.js +1 -1
- package/dist/application-spec/parse-application-files/categorize/module-analysis.d.ts +30 -4
- package/dist/application-spec/parse-application-files/categorize/module-analysis.js +1 -1
- package/dist/application-spec/parse-application-files/categorize/webhook-safety.js +1 -1
- package/dist/application-spec/parse-application-files/merge/merged-app-metadata.d.ts +17 -1
- package/dist/application-spec/parse-application-files/merge/merged-app-metadata.js +1 -1
- package/dist/application-spec/parse-application-files/merge/merged-assistant.js +1 -1
- package/dist/application-spec/parse-application-files/merge/merged-spec.d.ts +7 -1
- package/dist/application-spec/parse-application-files/merge/merged-spec.js +1 -1
- package/dist/application-spec/parse-application-files/parse-application-files.js +1 -1
- package/dist/application-spec/parse-application-files/parse-common-admin-spec.js +1 -1
- package/dist/application-spec/parse-application-files/raw-spec/raw-actions.d.ts +3 -2
- package/dist/application-spec/parse-application-files/raw-spec/raw-actions.js +1 -1
- package/dist/application-spec/parse-application-files/raw-spec/raw-assistant.d.ts +67 -8
- package/dist/application-spec/parse-application-files/raw-spec/raw-assistant.js +1 -1
- package/dist/application-spec/parse-application-files/raw-spec/raw-components.js +1 -1
- package/dist/application-spec/parse-application-files/raw-spec/raw-spec-file.d.ts +12 -3
- package/dist/application-spec/parse-application-files/raw-spec/raw-spec-file.js +1 -1
- package/dist/application-spec/parse-application-files/resolve/resolve-import-modules.js +1 -1
- package/dist/application-spec/parse-application-files/spec/application/configurator-spec/configurator-spec.d.ts +6 -0
- package/dist/application-spec/parse-application-files/spec/application/configurator-spec/configurator-spec.js +1 -1
- package/dist/application-spec/parse-application-files/spec/expressions/user-expressions.js +1 -1
- package/dist/application-spec/parse-application-files/spec/model/index.d.ts +2 -1
- package/dist/application-spec/parse-application-files/spec/model/index.js +1 -1
- package/dist/application-spec/parse-application-files/spec/model/session-data-schema.d.ts +5 -2
- package/dist/application-spec/parse-application-files/spec/model/session-data-schema.js +1 -1
- package/dist/application-spec/parse-application-files/spec/model/session-fields/index.d.ts +1 -0
- package/dist/application-spec/parse-application-files/spec/model/session-fields/index.js +1 -0
- package/dist/application-spec/parse-application-files/spec/model/session-fields/session-fields.d.ts +15 -0
- package/dist/application-spec/parse-application-files/spec/model/session-fields/session-fields.js +1 -0
- package/dist/application-spec/parse-application-files/spec/relations/relations.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/actions.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/app-metadata.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-form-elements.d.ts +14 -2
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-form-elements.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-schema.d.ts +7 -10
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-schema.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-server-settings.d.ts +5 -6
- package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-server-settings.js +1 -1
- package/dist/application-spec/parse-application-files/spec/sections/assistant/index.d.ts +0 -1
- package/dist/application-spec/webhook-boundary.js +1 -1
- package/dist/client/authenticated-client.d.ts +5 -1
- package/dist/client/authenticated-client.js +1 -1
- package/dist/client/authorized-client.d.ts +4 -1
- package/dist/client/authorized-client.js +1 -1
- package/dist/client/base-client.d.ts +15 -1
- package/dist/client/base-client.js +1 -1
- package/dist/client/cli-client/cli-api-client.d.ts +17 -0
- package/dist/client/cli-client/cli-api-client.js +1 -0
- package/dist/client/cli-client/index.d.ts +2 -0
- package/dist/client/cli-client/index.js +1 -0
- package/dist/client/cli-client/unsupported-api-version-error.d.ts +11 -0
- package/dist/client/cli-client/unsupported-api-version-error.js +1 -0
- package/dist/client/contract.d.ts +53 -10
- package/dist/client/contract.js +1 -1
- package/dist/client/index.d.ts +2 -1
- package/dist/client/index.js +1 -1
- package/dist/client/local-authorized-client.d.ts +1 -0
- package/dist/client/local-authorized-client.js +1 -1
- package/dist/client/memory-authorized-client.d.ts +1 -0
- package/dist/client/memory-authorized-client.js +1 -1
- package/dist/client/phoenix-api.d.ts +8470 -2127
- package/dist/client/unauthenticated-client.d.ts +1 -0
- package/dist/client/unauthenticated-client.js +1 -1
- package/dist/configurator/ConfiguratorApp.js +1 -1
- package/dist/configurator/agent-at-work/AgentAtWorkFallback.d.ts +7 -0
- package/dist/configurator/agent-at-work/AgentAtWorkFallback.js +1 -0
- package/dist/configurator/agent-at-work/AgentAtWorkPage.d.ts +20 -0
- package/dist/configurator/agent-at-work/AgentAtWorkPage.js +1 -0
- package/dist/configurator/agent-at-work/AgentModeBadge.d.ts +11 -0
- package/dist/configurator/agent-at-work/AgentModeBadge.js +1 -0
- package/dist/configurator/agent-at-work/StudioMark.d.ts +8 -0
- package/dist/configurator/agent-at-work/StudioMark.js +1 -0
- package/dist/configurator/agent-at-work/agent-at-work-copy.d.ts +17 -0
- package/dist/configurator/agent-at-work/agent-at-work-copy.js +1 -0
- package/dist/configurator/agent-at-work/agent-at-work-styles.d.ts +23 -0
- package/dist/configurator/agent-at-work/agent-at-work-styles.js +374 -0
- package/dist/configurator/agent-at-work/index.d.ts +3 -0
- package/dist/configurator/agent-at-work/index.js +1 -0
- package/dist/configurator/application-runtime/extensions/configurator-extension-systems.d.ts +5 -4
- package/dist/configurator/application-runtime/extensions/configurator-extension-systems.js +1 -1
- package/dist/configurator/application-runtime/extensions/create-configurator-extensions.js +1 -1
- package/dist/configurator/application-runtime/extensions/selectors.d.ts +4 -2
- package/dist/configurator/application-runtime/extensions/selectors.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/action-system/action-context.d.ts +14 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action-context.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action-factory.d.ts +13 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action-system.d.ts +55 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action-system.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action.d.ts +56 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/action.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/index.d.ts +6 -0
- package/dist/configurator/application-runtime/extensions/systems/action-system/index.js +1 -0
- package/dist/{domain/domain-runtime/spec → configurator/application-runtime/extensions/systems/action-system}/prepare-action-implementations.d.ts +4 -3
- package/dist/{domain/domain-runtime/spec → configurator/application-runtime/extensions/systems/action-system}/prepare-action-implementations.js +2 -2
- package/dist/{domain/spec/modules → configurator/application-runtime/extensions/systems/action-system}/resolve-action-modules.d.ts +2 -2
- package/dist/configurator/application-runtime/extensions/systems/action-system/resolve-action-modules.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-annotation.d.ts +14 -8
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-image-view.d.ts +18 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-image-view.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-speech-player.d.ts +69 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-speech-player.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-system.d.ts +252 -22
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/composer-attachments.d.ts +63 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/composer-attachments.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/graphql-tools.d.ts +52 -36
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/graphql-tools.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/rasterize-image.d.ts +13 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/rasterize-image.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/speakable-reply.d.ts +7 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/speakable-reply.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/index.d.ts +3 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/index.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/register-webmcp-tools.d.ts +33 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/register-webmcp-tools.js +6 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/share-link.d.ts +14 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/share-link.js +2 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/to-webmcp-result.d.ts +10 -0
- package/dist/configurator/application-runtime/extensions/systems/assistant-system/webmcp/to-webmcp-result.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/camera-control-system/camera-control-system.d.ts +41 -35
- package/dist/configurator/application-runtime/extensions/systems/camera-control-system/camera-control-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/export-system/export-system.d.ts +18 -5
- package/dist/configurator/application-runtime/extensions/systems/export-system/export-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/entity-meta.d.ts +8 -1
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/entity-meta.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/graphql-system.d.ts +46 -12
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/graphql-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/is-offered-for-selection.d.ts +16 -0
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/is-offered-for-selection.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/read-offered-navigation.d.ts +26 -0
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/read-offered-navigation.js +1 -0
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/violations.d.ts +25 -8
- package/dist/configurator/application-runtime/extensions/systems/graphql-system/violations.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/export-image-capture.d.ts +15 -4
- package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/export-image-capture.js +3 -3
- package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/image-rendering-system.d.ts +15 -7
- package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/image-rendering-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/index.d.ts +8 -3
- package/dist/configurator/application-runtime/extensions/systems/index.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/layout-system/layout-system.d.ts +11 -0
- package/dist/configurator/application-runtime/extensions/systems/layout-system/layout-system.js +1 -1
- package/dist/configurator/application-runtime/extensions/systems/sketching-system/sketching-system.d.ts +5 -5
- package/dist/configurator/application-runtime/hooks/use-configurator.d.ts +3 -3
- package/dist/configurator/common/configurator-interface.d.ts +21 -9
- package/dist/configurator/common/configurator-interface.js +1 -1
- package/dist/configurator/index.d.ts +1 -0
- package/dist/configurator/index.js +1 -1
- package/dist/configurator/{ui/configurator-layout/universal → pages}/ExportingOverlay.d.ts +3 -2
- package/dist/configurator/pages/ExportingOverlay.js +1 -0
- package/dist/configurator/pages/InertRoot.d.ts +10 -0
- package/dist/configurator/pages/InertRoot.js +1 -0
- package/dist/configurator/pages/LoadedConfiguratorDetailPage.js +1 -1
- package/dist/configurator/pages/PresetCreationErrorPage.d.ts +1 -1
- package/dist/configurator/pages/PresetCreationErrorPage.js +1 -1
- package/dist/configurator/pages/error-boundaries/AgentModeErrorFallback.d.ts +8 -0
- package/dist/configurator/pages/error-boundaries/AgentModeErrorFallback.js +1 -0
- package/dist/configurator/pages/error-boundaries/DevContextFallback.d.ts +4 -2
- package/dist/configurator/pages/error-boundaries/DevContextFallback.js +1 -1
- package/dist/configurator/pages/error-boundaries/DevLoadingFallback.d.ts +6 -4
- package/dist/configurator/pages/error-boundaries/DevLoadingFallback.js +1 -1
- package/dist/configurator/pages/error-boundaries/GeneralErrorBoundary.js +1 -1
- package/dist/configurator/scene/cameras/CameraPadding.d.ts +5 -0
- package/dist/configurator/scene/cameras/CameraPadding.js +1 -1
- package/dist/configurator/scene/resources/use-phx-gltf.js +1 -1
- package/dist/configurator/scene/scene-entity/materials/LocalCreatedMaterial.js +1 -1
- package/dist/configurator/scene/scene-entity/materials/RemoteReplacedMaterial.d.ts +5 -0
- package/dist/configurator/scene/scene-entity/materials/RemoteReplacedMaterial.js +1 -1
- package/dist/configurator/scene/scene-entity/materials/use-dispose-replaced.d.ts +27 -0
- package/dist/configurator/scene/scene-entity/materials/use-dispose-replaced.js +1 -0
- package/dist/configurator/toolbar-actions/use-toolbar-actions.js +1 -1
- package/dist/configurator/ui/assistant/AssistantChips.d.ts +78 -6
- package/dist/configurator/ui/assistant/AssistantChips.js +1 -1
- package/dist/configurator/ui/assistant/AssistantComposer.d.ts +99 -1
- package/dist/configurator/ui/assistant/AssistantComposer.js +1 -1
- package/dist/configurator/ui/assistant/AssistantMarkdown.d.ts +37 -3
- package/dist/configurator/ui/assistant/AssistantMarkdown.js +1 -1
- package/dist/configurator/ui/assistant/AssistantPanel.d.ts +51 -4
- package/dist/configurator/ui/assistant/AssistantPanel.js +1 -1
- package/dist/configurator/ui/assistant/AssistantThread.d.ts +85 -2
- package/dist/configurator/ui/assistant/AssistantThread.js +1 -1
- package/dist/configurator/ui/assistant/AssistantThreadItemView.d.ts +83 -6
- package/dist/configurator/ui/assistant/AssistantThreadItemView.js +1 -1
- package/dist/configurator/ui/assistant/alert/AssistantAlert.d.ts +35 -1
- package/dist/configurator/ui/assistant/alert/AssistantAlert.js +1 -1
- package/dist/configurator/ui/assistant/alert/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/annotation/AnnotationBadge.d.ts +34 -0
- package/dist/configurator/ui/assistant/annotation/AnnotationBadge.js +1 -1
- package/dist/configurator/ui/assistant/annotation/AnnotationOverlay.d.ts +2 -3
- package/dist/configurator/ui/assistant/annotation/AnnotationViewer.js +1 -1
- package/dist/configurator/ui/assistant/annotation/MessageAnnotations.js +1 -1
- package/dist/configurator/ui/assistant/annotation/annotation-layout.d.ts +59 -5
- package/dist/configurator/ui/assistant/annotation/annotation-layout.js +1 -1
- package/dist/configurator/ui/assistant/annotation/editor/AnnotationComment.d.ts +40 -5
- package/dist/configurator/ui/assistant/annotation/editor/AnnotationComment.js +1 -1
- package/dist/configurator/ui/assistant/annotation/editor/AnnotationEditor.d.ts +6 -5
- package/dist/configurator/ui/assistant/annotation/editor/AnnotationEditor.js +1 -1
- package/dist/configurator/ui/assistant/annotation/editor/annotation-pins.d.ts +5 -0
- package/dist/configurator/ui/assistant/annotation/editor/annotation-pins.js +1 -1
- package/dist/configurator/ui/assistant/annotation/editor/index.d.ts +1 -0
- package/dist/configurator/ui/assistant/annotation/index.d.ts +3 -2
- package/dist/configurator/ui/assistant/annotation/index.js +1 -1
- package/dist/configurator/ui/assistant/assistant-failure.d.ts +9 -4
- package/dist/configurator/ui/assistant/assistant-failure.js +1 -1
- package/dist/configurator/ui/assistant/attachments/MessageImages.d.ts +49 -5
- package/dist/configurator/ui/assistant/attachments/MessageImages.js +1 -1
- package/dist/configurator/ui/assistant/attachments/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/composer/composer-frame.d.ts +7 -2
- package/dist/configurator/ui/assistant/composer/composer-frame.js +1 -1
- package/dist/configurator/ui/assistant/composer/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/composer/index.js +1 -1
- package/dist/configurator/ui/assistant/disclaimer/AssistantDisclaimerDialog.d.ts +10 -0
- package/dist/configurator/ui/assistant/disclaimer/AssistantDisclaimerDialog.js +1 -0
- package/dist/configurator/ui/assistant/disclaimer/AssistantDisclaimerLine.d.ts +10 -0
- package/dist/configurator/ui/assistant/disclaimer/AssistantDisclaimerLine.js +1 -0
- package/dist/configurator/ui/assistant/disclaimer/index.d.ts +2 -0
- package/dist/configurator/ui/assistant/disclaimer/index.js +1 -0
- package/dist/configurator/ui/assistant/drawing/AssistantDrawing.d.ts +58 -0
- package/dist/configurator/ui/assistant/drawing/AssistantDrawing.js +1 -0
- package/dist/configurator/ui/assistant/drawing/index.d.ts +2 -0
- package/dist/configurator/ui/assistant/drawing/index.js +1 -0
- package/dist/configurator/ui/assistant/drawing/parse-drawing.d.ts +18 -0
- package/dist/configurator/ui/assistant/drawing/parse-drawing.js +1 -0
- package/dist/configurator/ui/assistant/drawing/use-drawing-url.d.ts +8 -0
- package/dist/configurator/ui/assistant/drawing/use-drawing-url.js +1 -0
- package/dist/configurator/ui/assistant/entity-link/AssistantEntityLink.d.ts +35 -1
- package/dist/configurator/ui/assistant/entity-link/AssistantEntityLink.js +1 -1
- package/dist/configurator/ui/assistant/entity-link/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/form/AssistantForm.d.ts +59 -2
- package/dist/configurator/ui/assistant/form/AssistantForm.js +1 -1
- package/dist/configurator/ui/assistant/form/built-in-form-slots.d.ts +16 -0
- package/dist/configurator/ui/assistant/form/built-in-form-slots.js +1 -0
- package/dist/configurator/ui/assistant/form/form-model.d.ts +9 -0
- package/dist/configurator/ui/assistant/form/index.d.ts +2 -1
- package/dist/configurator/ui/assistant/form/parse-form-block.d.ts +6 -5
- package/dist/configurator/ui/assistant/form/parse-form-block.js +1 -1
- package/dist/configurator/ui/assistant/form/read-form-tile.d.ts +8 -0
- package/dist/configurator/ui/assistant/form/read-form-tile.js +1 -0
- package/dist/configurator/ui/assistant/form/registry/built-in-form-elements.d.ts +6 -3
- package/dist/configurator/ui/assistant/form/registry/built-in-form-elements.js +1 -1
- package/dist/configurator/ui/assistant/form/registry/create-assistant-form-element.d.ts +11 -7
- package/dist/configurator/ui/assistant/form/registry/form-registry.d.ts +1 -1
- package/dist/configurator/ui/assistant/form/registry/form-registry.js +1 -1
- package/dist/configurator/ui/assistant/form/registry/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/form/split-form-rows.d.ts +7 -0
- package/dist/configurator/ui/assistant/form/split-form-rows.js +1 -0
- package/dist/configurator/ui/assistant/form-elements/FormConfirm.d.ts +51 -0
- package/dist/configurator/ui/assistant/form-elements/FormConfirm.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormGroup.d.ts +47 -0
- package/dist/configurator/ui/assistant/form-elements/FormGroup.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormNumber.d.ts +43 -0
- package/dist/configurator/ui/assistant/form-elements/FormNumber.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormOptions.d.ts +56 -2
- package/dist/configurator/ui/assistant/form-elements/FormOptions.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormReply.d.ts +43 -0
- package/dist/configurator/ui/assistant/form-elements/FormReply.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormText.d.ts +47 -0
- package/dist/configurator/ui/assistant/form-elements/FormText.js +1 -1
- package/dist/configurator/ui/assistant/form-elements/FormTile.d.ts +72 -0
- package/dist/configurator/ui/assistant/form-elements/FormTile.js +1 -0
- package/dist/configurator/ui/assistant/form-elements/form-element-props.d.ts +27 -0
- package/dist/configurator/ui/assistant/form-elements/index.d.ts +8 -9
- package/dist/configurator/ui/assistant/form-elements/index.js +1 -1
- package/dist/configurator/ui/assistant/image-view/ImageView.d.ts +66 -0
- package/dist/configurator/ui/assistant/image-view/ImageView.js +1 -0
- package/dist/configurator/ui/assistant/image-view/index.d.ts +1 -0
- package/dist/configurator/ui/assistant/image-view/index.js +1 -0
- package/dist/configurator/ui/assistant/image-view/use-image-blob.d.ts +7 -0
- package/dist/configurator/ui/assistant/image-view/use-image-blob.js +1 -0
- package/dist/configurator/ui/assistant/index.d.ts +21 -10
- package/dist/configurator/ui/assistant/index.js +1 -1
- package/dist/configurator/ui/assistant/panel/AssistantPanelHeader.d.ts +57 -0
- package/dist/configurator/ui/assistant/panel/AssistantPanelHeader.js +1 -0
- package/dist/configurator/ui/assistant/panel/index.d.ts +1 -0
- package/dist/configurator/ui/assistant/panel/index.js +1 -0
- package/dist/configurator/ui/assistant/reference-link/AssistantReferenceLink.d.ts +43 -1
- package/dist/configurator/ui/assistant/reference-link/AssistantReferenceLink.js +1 -1
- package/dist/configurator/ui/assistant/reference-link/assistant-reference-details.d.ts +4 -1
- package/dist/configurator/ui/assistant/reference-link/assistant-reference-details.js +1 -1
- package/dist/configurator/ui/assistant/reference-link/index.d.ts +3 -2
- package/dist/configurator/ui/assistant/reference-link/index.js +1 -1
- package/dist/configurator/ui/assistant/resource-image/AssistantImage.d.ts +49 -2
- package/dist/configurator/ui/assistant/resource-image/AssistantImage.js +1 -1
- package/dist/configurator/ui/assistant/resource-image/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/resource-image/index.js +1 -1
- package/dist/configurator/ui/assistant/screenshots/ScreenshotThumbnails.d.ts +34 -0
- package/dist/configurator/ui/assistant/screenshots/ScreenshotThumbnails.js +1 -1
- package/dist/configurator/ui/assistant/screenshots/index.d.ts +1 -1
- package/dist/configurator/ui/assistant/screenshots/tool-screenshots.d.ts +2 -6
- package/dist/configurator/ui/assistant/screenshots/tool-screenshots.js +1 -1
- package/dist/configurator/ui/assistant/screenshots/use-screenshot-src.d.ts +5 -6
- package/dist/configurator/ui/assistant/screenshots/use-screenshot-src.js +1 -1
- package/dist/configurator/ui/assistant/thread-items.d.ts +17 -3
- package/dist/configurator/ui/assistant/thread-items.js +1 -1
- package/dist/configurator/ui/assistant/use-assistant-composer.d.ts +32 -7
- package/dist/configurator/ui/assistant/use-assistant-composer.js +2 -2
- package/dist/configurator/ui/assistant/use-assistant-thread.d.ts +15 -1
- package/dist/configurator/ui/assistant/use-assistant-thread.js +1 -1
- package/dist/configurator/ui/assistant/use-load-older-on-top.d.ts +3 -3
- package/dist/configurator/ui/assistant/use-load-older-on-top.js +1 -1
- package/dist/configurator/ui/assistant/{annotation/use-end-on-unmount.d.ts → use-on-unmount.d.ts} +1 -1
- package/dist/configurator/ui/assistant/use-on-unmount.js +1 -0
- package/dist/configurator/ui/assistant/voice/RecordingBar.d.ts +21 -0
- package/dist/configurator/ui/assistant/voice/RecordingBar.js +1 -0
- package/dist/configurator/ui/assistant/voice/ReplyPlayButton.d.ts +43 -0
- package/dist/configurator/ui/assistant/voice/ReplyPlayButton.js +1 -0
- package/dist/configurator/ui/assistant/voice/index.d.ts +4 -0
- package/dist/configurator/ui/assistant/voice/index.js +1 -0
- package/dist/configurator/ui/assistant/voice/use-voice-recording.d.ts +39 -0
- package/dist/configurator/ui/assistant/voice/use-voice-recording.js +1 -0
- package/dist/configurator/ui/assistant/voice/voice-capture.d.ts +22 -0
- package/dist/configurator/ui/assistant/voice/voice-capture.js +1 -0
- package/dist/configurator/ui/configurator-layout/index.d.ts +1 -1
- package/dist/configurator/ui/configurator-layout/index.js +1 -1
- package/dist/configurator/ui/configurator-layout/slots/canvas/LayoutCanvas.js +1 -1
- package/dist/configurator/ui/configurator-layout/slots/desktop-sidebar/DesktopSidebar.js +4 -4
- package/dist/configurator/ui/configurator-layout/slots/index.d.ts +2 -0
- package/dist/configurator/ui/configurator-layout/slots/index.js +1 -1
- package/dist/configurator/ui/configurator-layout/slots/view-controls/DesktopViewControls.js +1 -1
- package/dist/configurator/ui/configurator-layout/slots/view-controls/MobileViewControls.js +1 -1
- package/dist/configurator/ui/configurator-layout/slots/view-controls/NestedViewControls.d.ts +7 -0
- package/dist/configurator/ui/configurator-layout/slots/view-controls/NestedViewControls.js +1 -0
- package/dist/configurator/ui/configurator-layout/slots/view-controls/use-view-control-items.d.ts +6 -0
- package/dist/configurator/ui/configurator-layout/slots/view-controls/use-view-control-items.js +1 -0
- package/dist/configurator/ui/configurator-layout/universal/DesktopPreview.js +1 -1
- package/dist/configurator/ui/configurator-layout/universal/Layout.js +1 -1
- package/dist/configurator/ui/configurator-layout/universal/MobileLayout.js +3 -3
- package/dist/configurator/ui/configurator-layout/universal/MobilePreview.js +1 -1
- package/dist/configurator/ui/configurator-layout/universal/use-layout-scene-safe-area.js +1 -1
- package/dist/configurator/ui/configurator-layout/universal/use-preview-description.d.ts +1 -0
- package/dist/configurator/ui/configurator-layout/universal/use-preview-description.js +1 -0
- package/dist/configurator/ui/index.d.ts +1 -1
- package/dist/configurator/ui/legacy/layout/common/ViewControls.js +1 -1
- package/dist/configurator/ui/phoenix-layout-elements/AssistantToolbarButton.js +1 -1
- package/dist/docs/index.json +130 -5
- package/dist/docs/integrations/woocommerce/overview.mdx +4 -2
- package/dist/docs/layouts/nested-view-controls.mdx +223 -0
- package/dist/docs/layouts/presets/custom.mdx +1 -0
- package/dist/docs/layouts/preview/always.mdx +22 -0
- package/dist/docs/layouts/view-controls.mdx +2 -0
- package/dist/docs/other-features/domain-actions.mdx +82 -55
- package/dist/docs/other-features/violation-messages.mdx +3 -1
- package/dist/docs/phoenix/admin.mdx +25 -64
- package/dist/docs/phoenix/application-states.mdx +1 -1
- package/dist/docs/phoenix/assistant/actions.mdx +183 -0
- package/dist/docs/phoenix/assistant/changing-the-configuration.mdx +333 -0
- package/dist/docs/phoenix/assistant/instructions-and-ai-settings.mdx +221 -0
- package/dist/docs/phoenix/assistant/overview.mdx +137 -0
- package/dist/docs/phoenix/assistant/per-session-setup.mdx +166 -0
- package/dist/docs/phoenix/assistant/reading-the-configuration.mdx +349 -0
- package/dist/docs/phoenix/assistant/screenshots.mdx +135 -0
- package/dist/docs/phoenix/assistant/security-and-limits.mdx +151 -0
- package/dist/docs/phoenix/assistant/the-panel.mdx +298 -0
- package/dist/docs/phoenix/blender-rendering.mdx +3 -1
- package/dist/docs/phoenix/clerk-sign-in.mdx +9 -5
- package/dist/docs/phoenix/configurator-interface.mdx +105 -10
- package/dist/docs/phoenix/data-sources.mdx +71 -51
- package/dist/docs/phoenix/deployments.mdx +3 -3
- package/dist/docs/phoenix/finalization.mdx +2 -2
- package/dist/docs/phoenix/getting-started.mdx +1 -1
- package/dist/docs/phoenix/integration/authentication-external.mdx +5 -5
- package/dist/docs/phoenix/integration/authentication-internal.mdx +3 -3
- package/dist/docs/phoenix/integration/finalization-internal.mdx +2 -5
- package/dist/docs/phoenix/integration/integration-modes-internal.mdx +9 -0
- package/dist/docs/phoenix/layout-slots.mdx +2 -2
- package/dist/docs/phoenix/localization.mdx +2 -1
- package/dist/docs/phoenix/migrations.mdx +1 -1
- package/dist/docs/phoenix/phoenix-cli.mdx +100 -60
- package/dist/docs/phoenix/project-structure.mdx +30 -15
- package/dist/docs/phoenix/publishing.mdx +21 -28
- package/dist/docs/phoenix/sdk-builder-workflow.mdx +61 -30
- package/dist/docs/phoenix/sessions-and-access.mdx +180 -153
- package/dist/docs/phoenix/sharing.mdx +1 -1
- package/dist/docs/phoenix/theming.mdx +5 -9
- package/dist/docs/phoenix/webhook-membership.mdx +4 -1
- package/dist/docs/phoenix/webhooks.mdx +449 -296
- package/dist/docs/ux-guidelines/choosing-navigation.mdx +2 -0
- package/dist/docs/ux-guidelines/designing-the-configuration-journey.mdx +43 -0
- package/dist/docs/ux-guidelines/interaction-modes.mdx +2 -2
- package/dist/docs/ux-guidelines/overview.mdx +11 -9
- package/dist/domain/admin-domain/index.d.ts +2 -2
- package/dist/domain/application/access/access-handlers.d.ts +19 -0
- package/dist/domain/application/access/access-handlers.js +1 -0
- package/dist/domain/application/access/anonymous-handler.d.ts +16 -0
- package/dist/domain/application/access/anonymous-handler.js +1 -0
- package/dist/domain/application/access/chunk-scopes-handler.d.ts +27 -0
- package/dist/domain/application/access/chunk-scopes-handler.js +1 -0
- package/dist/domain/application/access/code-handler.d.ts +16 -0
- package/dist/domain/application/access/code-handler.js +1 -0
- package/dist/domain/application/access/index.d.ts +7 -0
- package/dist/domain/application/access/index.js +1 -0
- package/dist/domain/application/access/refresh-handler.d.ts +16 -0
- package/dist/domain/application/access/refresh-handler.js +1 -0
- package/dist/domain/application/access/signed-in-handler.d.ts +44 -0
- package/dist/domain/application/access/signed-in-handler.js +1 -0
- package/dist/domain/application/access/visitor-handler.d.ts +23 -0
- package/dist/domain/application/access/visitor-handler.js +1 -0
- package/dist/domain/application/application-config.d.ts +37 -1
- package/dist/domain/application/assistant/assistant-exposure.d.ts +22 -0
- package/dist/domain/application/assistant/assistant-exposure.js +1 -0
- package/dist/domain/application/assistant/assistant-selection.d.ts +30 -0
- package/dist/domain/application/assistant/assistant-selection.js +1 -0
- package/dist/domain/application/assistant/build-assistant-lenses.js +4 -4
- package/dist/domain/application/assistant/build-assistant-manifest.d.ts +2 -2
- package/dist/domain/application/assistant/build-assistant-manifest.js +1 -1
- package/dist/domain/application/assistant/generate-assistant-prompt.d.ts +18 -2
- package/dist/domain/application/assistant/generate-assistant-prompt.js +1 -1
- package/dist/domain/application/assistant/index.d.ts +5 -1
- package/dist/domain/application/assistant/index.js +1 -1
- package/dist/domain/application/assistant/prepare-assistant-navigation-updates.d.ts +16 -0
- package/dist/domain/application/assistant/prepare-assistant-navigation-updates.js +1 -0
- package/dist/domain/application/assistant/read-assistant-navigation.d.ts +40 -0
- package/dist/domain/application/assistant/read-assistant-navigation.js +1 -0
- package/dist/domain/application/assistant/session-setup/apply-assistant-setup.js +1 -1
- package/dist/domain/application/assistant/session-setup/assistant-setup-manifest.d.ts +30 -2
- package/dist/domain/application/assistant/session-setup/assistant-setup-manifest.js +1 -1
- package/dist/domain/application/assistant/session-setup/assistant-takes-images.d.ts +7 -0
- package/dist/domain/application/assistant/session-setup/assistant-takes-images.js +1 -0
- package/dist/domain/application/assistant/session-setup/index.d.ts +1 -0
- package/dist/domain/application/assistant/session-setup/index.js +1 -1
- package/dist/domain/application/assistant-field-options.d.ts +2 -0
- package/dist/domain/application/assistant-field-options.js +1 -1
- package/dist/domain/application/assistant-mutations.d.ts +17 -11
- package/dist/domain/application/assistant-mutations.js +1 -1
- package/dist/domain/application/assistant-recipe-groups.d.ts +4 -3
- package/dist/domain/application/assistant-recipe-groups.js +1 -1
- package/dist/domain/application/configurator-builder.d.ts +47 -37
- package/dist/domain/application/configurator-builder.js +1 -1
- package/dist/domain/application/index.d.ts +2 -1
- package/dist/domain/application/index.js +1 -1
- package/dist/domain/application/standard-properties.d.ts +1 -1
- package/dist/domain/application/standard-properties.js +1 -1
- package/dist/domain/available-system-components/available-system-components.d.ts +1 -1
- package/dist/domain/available-system-components/available-system-components.js +1 -1
- package/dist/domain/core/action/action.d.ts +0 -49
- package/dist/domain/core/action/index.d.ts +0 -1
- package/dist/domain/core/action/index.js +1 -1
- package/dist/domain/core/component/system-component-filter.d.ts +1 -0
- package/dist/domain/core/component/system-component-filter.js +1 -1
- package/dist/domain/core/component/view-state-component.d.ts +4 -3
- package/dist/domain/core/component/view-state-component.js +1 -1
- package/dist/domain/core/domain-factory.d.ts +8 -3
- package/dist/domain/core/domain-factory.js +1 -1
- package/dist/domain/core/fit-session-data.d.ts +16 -0
- package/dist/domain/core/fit-session-data.js +1 -0
- package/dist/domain/core/index.d.ts +1 -1
- package/dist/domain/core/index.js +1 -1
- package/dist/domain/core/invariant/control-violation-hints.d.ts +37 -0
- package/dist/domain/core/invariant/control-violation-hints.js +1 -0
- package/dist/domain/core/invariant/index.d.ts +1 -0
- package/dist/domain/core/invariant/index.js +1 -1
- package/dist/domain/domain-builder/domain-builder.d.ts +1 -6
- package/dist/domain/domain-builder/domain-builder.js +1 -1
- package/dist/domain/domain-context/domain-context-systems.d.ts +3 -5
- package/dist/domain/domain-context/index.d.ts +0 -1
- package/dist/domain/domain-context/index.js +1 -1
- package/dist/domain/domain-context/navigation-system/navigation-system.d.ts +2 -2
- package/dist/domain/domain-context/navigation-system/navigation-system.js +1 -1
- package/dist/domain/domain-context/transformers/when-builder.js +1 -1
- package/dist/domain/domain-runtime/domain-context/actions.d.ts +4 -0
- package/dist/domain/domain-runtime/domain-context/actions.js +1 -1
- package/dist/domain/domain-runtime/domain-context/domain-context.d.ts +9 -1
- package/dist/domain/domain-runtime/domain-context/domain-context.js +1 -1
- package/dist/domain/domain-runtime/domain-context/index.d.ts +0 -1
- package/dist/domain/domain-runtime/domain-context/selectors.d.ts +6 -4
- package/dist/domain/domain-runtime/domain-context/selectors.js +1 -1
- package/dist/domain/domain-runtime/domain-context/types.d.ts +8 -4
- package/dist/domain/domain-runtime/domain-runtime.d.ts +27 -13
- package/dist/domain/domain-runtime/domain-runtime.js +1 -1
- package/dist/domain/domain-runtime/environment/actions.d.ts +1 -0
- package/dist/domain/domain-runtime/environment/actions.js +1 -1
- package/dist/domain/domain-runtime/environment/initialize.js +1 -1
- package/dist/domain/domain-runtime/environment/selectors.d.ts +2 -0
- package/dist/domain/domain-runtime/environment/selectors.js +1 -1
- package/dist/domain/domain-runtime/environment/types.d.ts +6 -0
- package/dist/domain/domain-runtime/spec/index.d.ts +0 -1
- package/dist/domain/domain-runtime/spec/index.js +1 -1
- package/dist/domain/domain-runtime/spec/initialize.js +1 -1
- package/dist/domain/domain-runtime/spec/selectors.d.ts +2 -2
- package/dist/domain/domain-runtime/spec/types.d.ts +12 -10
- package/dist/domain/extensions/assistant/assistant-greeting.d.ts +30 -0
- package/dist/domain/extensions/assistant/assistant-greeting.js +1 -0
- package/dist/domain/extensions/assistant/index.d.ts +1 -0
- package/dist/domain/extensions/assistant/index.js +1 -0
- package/dist/domain/extensions/export-images/agent-screenshot.d.ts +5 -4
- package/dist/domain/extensions/export-images/agent-screenshot.js +1 -1
- package/dist/domain/extensions/index.d.ts +1 -1
- package/dist/domain/extensions/index.js +1 -1
- package/dist/domain/index.d.ts +1 -1
- package/dist/domain/index.js +1 -1
- package/dist/domain/mocks/create-mock-domain-runtime.d.ts +13 -6
- package/dist/domain/spec/expressions/relation-expression-params.d.ts +1 -1
- package/dist/domain/spec/modules/index.d.ts +0 -1
- package/dist/domain/spec/modules/index.js +1 -1
- package/dist/domain/spec/phx/phx-domain.d.ts +0 -1
- package/dist/domain/spec/phx/phx-domain.js +1 -1
- package/dist/domain/spec/runtime/application-spec-slice.d.ts +5 -5
- package/dist/domain/spec/runtime/application-spec-slice.js +1 -1
- package/dist/domain/spec/runtime/create-application.d.ts +5 -2
- package/dist/domain/spec/runtime/create-application.js +1 -1
- package/dist/domain/spec/runtime-spec/runtime-spec.d.ts +2 -2
- package/dist/domain/spec/sections/actions.d.ts +3 -2
- package/dist/domain/spec/sections/app-metadata.d.ts +13 -0
- package/dist/domain/spec/sections/assistant/assistant-features.d.ts +13 -0
- package/dist/domain/spec/sections/assistant/assistant-features.js +1 -0
- package/dist/domain/spec/sections/assistant/assistant-manifest.d.ts +35 -2
- package/dist/domain/spec/sections/assistant/assistant-navigation.d.ts +21 -0
- package/dist/domain/spec/sections/assistant/assistant-navigation.js +1 -0
- package/dist/domain/spec/sections/assistant/assistant-resolved-manifest.d.ts +55 -13
- package/dist/domain/spec/sections/assistant/assistant-select.d.ts +12 -0
- package/dist/domain/spec/sections/assistant/assistant-select.js +1 -0
- package/dist/domain/spec/sections/assistant/form/assistant-form-elements.d.ts +10 -26
- package/dist/domain/spec/sections/assistant/form/assistant-form-elements.js +1 -1
- package/dist/domain/spec/sections/assistant/index.d.ts +5 -2
- package/dist/domain/system-components/index.d.ts +1 -0
- package/dist/domain/system-components/index.js +1 -1
- package/dist/domain/system-components/navigation/index.d.ts +1 -0
- package/dist/domain/system-components/navigation/index.js +1 -0
- package/dist/domain/system-components/navigation/view-controls.d.ts +24 -0
- package/dist/domain/system-components/navigation/view-controls.js +1 -0
- package/dist/editor/Editor.d.ts +5 -0
- package/dist/editor/Editor.js +1 -1
- package/dist/editor/EditorMode.d.ts +2 -0
- package/dist/editor/EditorMode.js +1 -1
- package/dist/editor/agent-mode/AgentModeBridge.d.ts +10 -0
- package/dist/editor/agent-mode/AgentModeBridge.js +1 -0
- package/dist/editor/agent-mode/agent-at-work-fonts.d.ts +2 -0
- package/dist/editor/agent-mode/agent-at-work-fonts.js +1 -0
- package/dist/editor/console-reporter/BrowserConsoleReporter.js +1 -1
- package/dist/editor/console-reporter/console-capture.d.ts +20 -0
- package/dist/editor/console-reporter/console-capture.js +1 -0
- package/dist/editor/domain-editors/DomainSpecContext.js +1 -1
- package/dist/editor/domain-editors/apply-spec-update.js +1 -1
- package/dist/editor/domain-editors/use-implementation-files.d.ts +4 -3
- package/dist/editor/domain-editors/use-implementation-files.js +1 -1
- package/dist/editor/index.d.ts +1 -0
- package/dist/editor/index.js +1 -1
- package/dist/editor/variants/VariantAnswerFooter.d.ts +8 -1
- package/dist/editor/variants/VariantAnswerFooter.js +1 -1
- package/dist/editor/variants/VariantPageUnavailable.d.ts +5 -0
- package/dist/editor/variants/VariantPageUnavailable.js +1 -0
- package/dist/editor/variants/VariantPreviewHandler.js +1 -1
- package/dist/editor/variants/variant-preview-fonts.d.ts +2 -0
- package/dist/editor/variants/variant-preview-fonts.js +1 -0
- package/dist/editor/variants/variant-preview-styles.d.ts +40 -48
- package/dist/editor/variants/variant-preview-styles.js +493 -1
- package/dist/extras/clerk/index.d.ts +6 -0
- package/dist/extras/cognito/AccountAvatar.d.ts +7 -0
- package/dist/extras/cognito/AccountAvatar.js +1 -0
- package/dist/extras/cognito/AccountControl.d.ts +13 -0
- package/dist/extras/cognito/AccountControl.js +1 -0
- package/dist/extras/cognito/AdminSignInPage.d.ts +26 -0
- package/dist/extras/cognito/AdminSignInPage.js +1 -0
- package/dist/extras/cognito/CognitoSignInPage.d.ts +8 -0
- package/dist/extras/cognito/CognitoSignInPage.js +1 -0
- package/dist/extras/cognito/ConfiguratorSignInPage.d.ts +19 -0
- package/dist/extras/cognito/ConfiguratorSignInPage.js +1 -0
- package/dist/extras/cognito/SignInFailurePage.d.ts +11 -0
- package/dist/extras/cognito/SignInFailurePage.js +1 -0
- package/dist/extras/cognito/SignInGateLayout.d.ts +25 -0
- package/dist/extras/cognito/SignInGateLayout.js +1 -0
- package/dist/extras/cognito/SignInNotice.d.ts +8 -0
- package/dist/extras/cognito/SignInNotice.js +1 -0
- package/dist/extras/cognito/index.d.ts +5 -0
- package/dist/extras/cognito/index.js +1 -0
- package/dist/globals/index.d.ts +5 -0
- package/dist/i18n/locales/cs/messages.js +1 -1
- package/dist/i18n/locales/da/messages.js +1 -1
- package/dist/i18n/locales/de/messages.js +1 -1
- package/dist/i18n/locales/de-AT/messages.js +1 -1
- package/dist/i18n/locales/en/messages.js +1 -1
- package/dist/i18n/locales/en-AU/messages.js +1 -1
- package/dist/i18n/locales/en-GB/messages.js +1 -1
- package/dist/i18n/locales/es/messages.js +1 -1
- package/dist/i18n/locales/fr/messages.js +1 -1
- package/dist/i18n/locales/hu/messages.js +1 -1
- package/dist/i18n/locales/it/messages.js +1 -1
- package/dist/i18n/locales/nl/messages.js +1 -1
- package/dist/i18n/locales/pl/messages.js +1 -1
- package/dist/i18n/locales/pt/messages.js +1 -1
- package/dist/i18n/locales/ro/messages.js +1 -1
- package/dist/i18n/locales/sk/messages.js +1 -1
- package/dist/i18n/locales/tr/messages.js +1 -1
- package/dist/legacy/deployment-cli/commands/create-environment.js +1 -1
- package/dist/legacy/deployment-cli/commands/list-environments.js +1 -1
- package/dist/legacy/deployment-cli/commands/register-deployment.js +1 -1
- package/dist/legacy/domain-cli/gen/configurator-builder.js +5 -4
- package/dist/legacy/domain-cli/utils/cache.d.ts +1 -1
- package/dist/legacy/domain-cli/utils/cache.js +1 -1
- package/dist/legacy/domain-spec/__generated/domain-schema.d.ts +25 -3
- package/dist/legacy/phoenix-cli/commands/prepare-deployment-command.js +1 -1
- package/dist/legacy/phoenix-cli/commands/prepare-local-environment-command.js +1 -1
- package/dist/legacy/phoenix-cli/services/prepare-development-environment.js +1 -1
- package/dist/legacy/phoenix-cli/services/webhook-service/transport.js +1 -1
- package/dist/legacy/webhook-cli/lib/webhook-boundary.js +1 -1
- package/dist/phoenix/application-spec/application-spec-builder.d.ts +2 -2
- package/dist/phoenix/application-spec/application-spec-builder.js +1 -1
- package/dist/phoenix/application-spec/generate-application-spec-project.d.ts +2 -1
- package/dist/phoenix/application-spec/generate-application-spec-project.js +2 -2
- package/dist/phoenix/application-spec/generate-project-files.d.ts +4 -3
- package/dist/phoenix/application-spec/generate-project-files.js +1 -1
- package/dist/phoenix/application-spec/index.d.ts +2 -1
- package/dist/phoenix/application-spec/index.js +1 -1
- package/dist/phoenix/application-spec/read-spec-project.d.ts +1 -2
- package/dist/phoenix/application-spec/read-spec-project.js +1 -1
- package/dist/phoenix/application-spec/resolve-deployment-data.d.ts +10 -2
- package/dist/phoenix/application-spec/resolve-deployment-data.js +2 -2
- package/dist/phoenix/cli.js +1 -1
- package/dist/phoenix/commands/account/index.d.ts +1 -0
- package/dist/phoenix/commands/account/index.js +1 -0
- package/dist/phoenix/commands/account/whoami.d.ts +10 -0
- package/dist/phoenix/commands/account/whoami.js +4 -0
- package/dist/phoenix/commands/build.d.ts +2 -1
- package/dist/phoenix/commands/build.js +1 -1
- package/dist/phoenix/commands/clean.d.ts +2 -1
- package/dist/phoenix/commands/clean.js +1 -1
- package/dist/phoenix/commands/cleanup-environment.js +1 -1
- package/dist/phoenix/commands/deploy.d.ts +7 -2
- package/dist/phoenix/commands/deploy.js +9 -3
- package/dist/phoenix/commands/deployment-build-envs-command.js +1 -1
- package/dist/phoenix/commands/deps/deps.js +2 -2
- package/dist/phoenix/commands/dev.d.ts +2 -1
- package/dist/phoenix/commands/dev.js +4 -4
- package/dist/phoenix/commands/feedback.d.ts +2 -2
- package/dist/phoenix/commands/feedback.js +1 -1
- package/dist/phoenix/commands/finish-deployment-command.js +1 -1
- package/dist/phoenix/commands/index.d.ts +1 -0
- package/dist/phoenix/commands/index.js +1 -1
- package/dist/phoenix/commands/init-starter-spec.js +3 -4
- package/dist/phoenix/commands/init.d.ts +2 -2
- package/dist/phoenix/commands/init.js +1 -1
- package/dist/phoenix/commands/login.d.ts +6 -3
- package/dist/phoenix/commands/login.js +3 -3
- package/dist/phoenix/commands/logout.js +1 -1
- package/dist/phoenix/commands/prepare-deployment-command.js +2 -2
- package/dist/phoenix/commands/prepare-local-environment-command.js +1 -1
- package/dist/phoenix/commands/sync.d.ts +2 -1
- package/dist/phoenix/commands/sync.js +1 -1
- package/dist/phoenix/services/application-spec-project-watcher.d.ts +3 -1
- package/dist/phoenix/services/application-spec-project-watcher.js +2 -2
- package/dist/phoenix/services/cli-credentials.d.ts +26 -7
- package/dist/phoenix/services/cli-credentials.js +2 -2
- package/dist/phoenix/services/cli-server/describe-saved-logins.d.ts +5 -0
- package/dist/phoenix/services/cli-server/describe-saved-logins.js +1 -0
- package/dist/phoenix/services/cli-server/index.d.ts +2 -0
- package/dist/phoenix/services/cli-server/index.js +1 -0
- package/dist/phoenix/services/cli-server/resolve-cli-server-url.d.ts +19 -0
- package/dist/phoenix/services/cli-server/resolve-cli-server-url.js +1 -0
- package/dist/phoenix/services/dev-experience/dev-experience.d.ts +31 -0
- package/dist/phoenix/services/dev-experience/dev-experience.js +1 -0
- package/dist/phoenix/services/dev-experience/index.d.ts +3 -0
- package/dist/phoenix/services/dev-experience/index.js +1 -0
- package/dist/phoenix/services/dev-experience/read-explicit-editor-setting.d.ts +7 -0
- package/dist/phoenix/services/dev-experience/read-explicit-editor-setting.js +1 -0
- package/dist/phoenix/services/dev-experience/regenerated-page-experience.d.ts +24 -0
- package/dist/phoenix/services/dev-experience/regenerated-page-experience.js +1 -0
- package/dist/phoenix/services/development-credential.js +1 -1
- package/dist/phoenix/services/frontend-config.d.ts +2 -0
- package/dist/phoenix/services/index.d.ts +6 -3
- package/dist/phoenix/services/index.js +1 -1
- package/dist/phoenix/services/phoenix-pubsub.d.ts +4 -0
- package/dist/phoenix/services/phoenix-regions.d.ts +6 -1
- package/dist/phoenix/services/phoenix-regions.js +1 -1
- package/dist/phoenix/services/prepare-development-environment.js +2 -2
- package/dist/phoenix/services/session/phoenix-application.d.ts +2 -1
- package/dist/phoenix/services/session/phoenix-application.js +2 -2
- package/dist/phoenix/services/signed-in-development-environment.d.ts +15 -4
- package/dist/phoenix/services/signed-in-development-environment.js +1 -1
- package/dist/phoenix/services/spec-project/describe-workspace-projects.d.ts +11 -0
- package/dist/phoenix/services/spec-project/describe-workspace-projects.js +1 -0
- package/dist/phoenix/services/spec-project/index.d.ts +3 -0
- package/dist/phoenix/services/spec-project/index.js +1 -0
- package/dist/phoenix/services/spec-project/resolve-deploy-target.d.ts +47 -0
- package/dist/phoenix/services/spec-project/resolve-deploy-target.js +1 -0
- package/dist/phoenix/services/spec-project/resolve-target-project.d.ts +34 -0
- package/dist/phoenix/services/spec-project/resolve-target-project.js +2 -0
- package/dist/phoenix/services/spec-project/write-spec-project.d.ts +7 -0
- package/dist/phoenix/services/spec-project/write-spec-project.js +1 -0
- package/dist/phoenix/services/telemetry/telemetry-event.js +1 -1
- package/dist/phoenix/services/telemetry/telemetry-state.d.ts +1 -1
- package/dist/phoenix/services/telemetry/telemetry-state.js +1 -1
- package/dist/phoenix/services/variant-file-session.js +1 -1
- package/dist/phoenix/services/vite-config.d.ts +2 -1
- package/dist/phoenix/services/vite-config.js +1 -1
- package/dist/phoenix/services/webhook-service/transport.js +1 -1
- package/dist/react-sdk/application-runtime/common-services/index.d.ts +1 -0
- package/dist/react-sdk/application-runtime/common-services/index.js +1 -1
- package/dist/react-sdk/application-runtime/common-services/selectors.d.ts +2 -0
- package/dist/react-sdk/application-runtime/common-services/selectors.js +1 -1
- package/dist/react-sdk/application-runtime/common-services/webmcp/index.d.ts +3 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/index.js +1 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-host.d.ts +35 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-host.js +1 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-model-context.d.ts +44 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-model-context.js +1 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-tool-result.d.ts +24 -0
- package/dist/react-sdk/application-runtime/common-services/webmcp/webmcp-tool-result.js +1 -0
- package/dist/react-sdk/application-runtime/domain-application-context/application-runtime-extension.d.ts +7 -1
- package/dist/react-sdk/application-runtime/domain-application-context/application-runtime-extension.js +1 -1
- package/dist/react-sdk/application-runtime/domain-application-context/configuration-persist-system.d.ts +6 -0
- package/dist/react-sdk/application-runtime/domain-application-context/configuration-persist-system.js +1 -1
- package/dist/react-sdk/application-runtime/domain-application-context/domain-application-systems.d.ts +2 -2
- package/dist/react-sdk/application-runtime/domain-application-context/selectors.d.ts +1 -3
- package/dist/react-sdk/application-runtime/domain-application-context/selectors.js +1 -1
- package/dist/react-sdk/application-runtime/hooks/index.d.ts +1 -0
- package/dist/react-sdk/application-runtime/hooks/index.js +1 -1
- package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-application.d.ts +2 -0
- package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-store.js +1 -1
- package/dist/react-sdk/application-runtime/hooks/use-environment.d.ts +7 -0
- package/dist/react-sdk/application-runtime/hooks/use-environment.js +1 -1
- package/dist/react-sdk/application-runtime/hooks/use-spec.d.ts +1 -1
- package/dist/react-sdk/application-runtime/hooks/use-webmcp-host.d.ts +7 -0
- package/dist/react-sdk/application-runtime/hooks/use-webmcp-host.js +1 -0
- package/dist/react-sdk/application-runtime/host-properties/selectors.d.ts +2 -2
- package/dist/react-sdk/application-runtime/integration/integration-mode.d.ts +30 -0
- package/dist/react-sdk/application-runtime/integration/integration-mode.js +1 -1
- package/dist/react-sdk/application-runtime/mocks/create-mock-application-runtime.js +1 -1
- package/dist/react-sdk/application-runtime/responsive/actions.d.ts +6 -0
- package/dist/react-sdk/application-runtime/responsive/actions.js +1 -1
- package/dist/react-sdk/application-runtime/responsive/initialize.js +1 -1
- package/dist/react-sdk/application-runtime/responsive/selectors.js +1 -1
- package/dist/react-sdk/application-runtime/responsive/types.d.ts +9 -0
- package/dist/react-sdk/application-runtime/runtime/create-application-runtime.d.ts +48 -18
- package/dist/react-sdk/application-runtime/runtime/create-application-runtime.js +1 -1
- package/dist/react-sdk/application-runtime/session/actions.d.ts +2 -1
- package/dist/react-sdk/application-runtime/session/actions.js +1 -1
- package/dist/react-sdk/application-runtime/session/initialize.js +1 -1
- package/dist/react-sdk/application-runtime/session/selectors.d.ts +2 -0
- package/dist/react-sdk/application-runtime/session/selectors.js +1 -1
- package/dist/react-sdk/application-runtime/session/session-service.d.ts +34 -1
- package/dist/react-sdk/application-runtime/session/session-service.js +1 -1
- package/dist/react-sdk/application-runtime/session/session-token.d.ts +8 -0
- package/dist/react-sdk/application-runtime/session/session-token.js +1 -1
- package/dist/react-sdk/application-runtime/session/types.d.ts +6 -1
- package/dist/react-sdk/domain-context/common-hooks/use-domain-context.d.ts +3 -2
- package/dist/react-sdk/domain-context/common-hooks/use-state-validity.d.ts +1 -1
- package/dist/react-sdk/domain-context/common-hooks/use-state-validity.js +1 -1
- package/dist/react-sdk/domain-context/index.d.ts +3 -2
- package/dist/react-sdk/domain-context/index.js +1 -1
- package/dist/react-sdk/domain-context/system-hooks/generate-share-link-hooks.d.ts +1 -5
- package/dist/react-sdk/domain-context/system-hooks/generate-share-link-hooks.js +1 -1
- package/dist/react-sdk/domain-context/system-hooks/generate-share-link.d.ts +25 -0
- package/dist/react-sdk/domain-context/system-hooks/generate-share-link.js +1 -0
- package/dist/react-sdk/domain-context/system-hooks/navigation-hooks.d.ts +5 -3
- package/dist/react-sdk/domain-context/system-hooks/navigation-hooks.js +1 -1
- package/dist/react-sdk/preset-selection/PresetSelectionProvider.d.ts +11 -0
- package/dist/react-sdk/preset-selection/PresetSelectionProvider.js +1 -1
- package/dist/react-sdk/preset-selection/PresetWebMcpTools.d.ts +14 -0
- package/dist/react-sdk/preset-selection/PresetWebMcpTools.js +1 -0
- package/dist/react-sdk/preset-selection/index.d.ts +2 -1
- package/dist/react-sdk/preset-selection/index.js +1 -1
- package/dist/react-sdk/preset-selection/register-preset-webmcp-tools.d.ts +31 -0
- package/dist/react-sdk/preset-selection/register-preset-webmcp-tools.js +1 -0
- package/dist/react-sdk/session/AccessDeniedAdminPage.d.ts +13 -0
- package/dist/react-sdk/session/AccessDeniedAdminPage.js +1 -0
- package/dist/react-sdk/session/AccessDeniedPage.d.ts +20 -0
- package/dist/react-sdk/session/AccessDeniedPage.js +1 -0
- package/dist/react-sdk/session/ConfiguratorUnavailablePage.d.ts +5 -0
- package/dist/react-sdk/session/ConfiguratorUnavailablePage.js +1 -0
- package/dist/react-sdk/session/SessionServiceProvider.d.ts +5 -0
- package/dist/react-sdk/session/SessionServiceProvider.js +1 -1
- package/dist/react-sdk/session/index.d.ts +3 -0
- package/dist/react-sdk/session/index.js +1 -1
- package/dist/react-sdk/session/sign-in-address.d.ts +13 -0
- package/dist/react-sdk/session/sign-in-address.js +1 -0
- package/dist/react-sdk/session/studio-frame.d.ts +7 -0
- package/dist/react-sdk/session/studio-frame.js +1 -0
- package/dist/react-sdk/session/use-sign-in.d.ts +50 -0
- package/dist/react-sdk/session/use-sign-in.js +1 -0
- package/dist/ui-sdk/components/preview/Preview.d.ts +12 -4
- package/dist/ui-sdk/components/preview/Preview.js +2 -2
- package/dist/ui-sdk/components/snackbar/Snackbar.d.ts +3 -2
- package/dist/ui-sdk/components/snackbar/Snackbar.js +1 -1
- package/dist/ui-sdk/components/toolbar/desktop-toolbar/ToolbarPopper.d.ts +2 -0
- package/dist/ui-sdk/components/toolbar/desktop-toolbar/ToolbarPopper.js +1 -1
- package/dist/ui-sdk/components/view-controls/ViewControlsContext.d.ts +3 -1
- package/dist/ui-sdk/components/view-controls/ViewControlsItem.js +1 -1
- package/dist/ui-sdk/components/view-controls/ViewControlsRoot.d.ts +6 -1
- package/dist/ui-sdk/components/view-controls/ViewControlsRoot.js +1 -1
- package/dist/ui-sdk/icons/__generated/Microphone.d.ts +3 -0
- package/dist/ui-sdk/icons/__generated/Microphone.js +1 -0
- package/dist/ui-sdk/icons/__generated/MicrophoneSlash.d.ts +3 -0
- package/dist/ui-sdk/icons/__generated/MicrophoneSlash.js +1 -0
- package/dist/ui-sdk/icons/__generated/SpeakerHigh.d.ts +3 -0
- package/dist/ui-sdk/icons/__generated/SpeakerHigh.js +1 -0
- package/dist/ui-sdk/icons/__generated/SpeakerSlash.d.ts +3 -0
- package/dist/ui-sdk/icons/__generated/SpeakerSlash.js +1 -0
- package/dist/ui-sdk/icons/__generated/Stop.d.ts +3 -0
- package/dist/ui-sdk/icons/__generated/Stop.js +1 -0
- package/dist/ui-sdk/icons/__generated/index.d.ts +10 -0
- package/dist/ui-sdk/icons/__generated/index.js +1 -1
- package/dist/ui-sdk/icons/icons-registry.js +1 -1
- package/dist/ui-sdk/theme/types.d.ts +0 -4
- package/dist/webhook/builders/auth-handler-builder.d.ts +24 -1
- package/dist/webhook/builders/auth-handler-builder.js +1 -1
- package/dist/webhook/builders/common.d.ts +14 -3
- package/dist/webhook/builders/webhook-builder.d.ts +18 -0
- package/dist/webhook/builders/webhook-builder.js +1 -1
- package/package.json +11 -4
- package/schema/domain-spec.json +444 -65
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks.d.ts +0 -2
- package/dist/application-spec/generate-application/code/templates/skills/features/webhooks.js +0 -1
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/ux-guidelines.d.ts +0 -2
- package/dist/application-spec/generate-application/code/templates/skills/processes/specification/ux-guidelines.js +0 -25
- package/dist/configurator/ui/assistant/annotation/annotation-host-context.d.ts +0 -5
- package/dist/configurator/ui/assistant/annotation/annotation-host-context.js +0 -1
- package/dist/configurator/ui/assistant/annotation/use-end-on-unmount.js +0 -1
- package/dist/configurator/ui/assistant/form-elements/FormCard.d.ts +0 -9
- package/dist/configurator/ui/assistant/form-elements/FormCard.js +0 -1
- package/dist/configurator/ui/assistant/form-elements/FormSwatch.d.ts +0 -10
- package/dist/configurator/ui/assistant/form-elements/FormSwatch.js +0 -1
- package/dist/configurator/ui/assistant/theme.d.ts +0 -2
- package/dist/configurator/ui/assistant/theme.js +0 -1
- package/dist/configurator/ui/configurator-layout/universal/ExportingOverlay.js +0 -1
- package/dist/domain/core/action/action-factory.d.ts +0 -11
- package/dist/domain/domain-context/action-system/action-system.d.ts +0 -38
- package/dist/domain/domain-context/action-system/action-system.js +0 -1
- package/dist/domain/domain-context/action-system/index.d.ts +0 -1
- package/dist/domain/domain-context/action-system/index.js +0 -1
- package/dist/domain/domain-runtime/domain-context/action-context.d.ts +0 -11
- package/dist/domain/extensions/view-controls.d.ts +0 -25
- package/dist/domain/extensions/view-controls.js +0 -1
- package/dist/domain/spec/modules/resolve-action-modules.js +0 -1
- /package/dist/{domain/domain-runtime/domain-context/action-context.js → application-spec/parse-application-files/access/analyzed-file.js} +0 -0
- /package/dist/{domain/core/action → configurator/application-runtime/extensions/systems/action-system}/action-factory.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{existsSync as e,readFileSync as o}from"fs";let t=".phoenix/editor.tsx";export const resolveRegeneratedPageExperience=(i,r)=>{let{cliEditor:n,userEditor:d,environmentEditor:a}=i,l=(e,o)=>(r.logger.detail(`Page: ${e} (${o})`),e);return void 0!==n?l(n?"editor":"plain","from CLI flag"):e(t)&&o(t,"utf8").includes(" hideUi")?void 0===d?l("agent","keeps the agent-mode page phoenix dev generated"):l(d?"editor":"plain","from ENABLE_EDITOR in the environment or .env"):void 0===a?l("editor","default"):l(a?"editor":"plain","from ENABLE_EDITOR")};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const getDevelopmentCredentialHint=(e,n)=>"developmentKey"in e?`Create a development environment for project "${n}" in Studio and paste its .env block into .env.`:"Run `phoenix login
|
|
1
|
+
export const getDevelopmentCredentialHint=(e,n)=>"developmentKey"in e?`Create a development environment for project "${n}" in Studio and paste its .env block into .env.`:"Run `phoenix login` again if the sign-in was revoked, then restart phoenix dev.";export const getDevelopmentHeaders=(e,n)=>({..."developmentKey"in e?{"x-development-key":e.developmentKey}:{authorization:`Bearer ${e.apiToken}`},"x-project-slug":n.projectSlug,"x-environment-slug":n.environmentSlug});
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
interface FrontendBuildConfig {
|
|
2
2
|
readonly jsonSchemaValidator: 'ajv' | 'csp-compatible';
|
|
3
3
|
readonly gltfDecoder: 'js' | 'wasm';
|
|
4
|
+
readonly gltfDecoderWorkerLimit: number;
|
|
5
|
+
readonly exportPixelRatio: number | undefined;
|
|
4
6
|
}
|
|
5
7
|
export interface FrontendConfigModule {
|
|
6
8
|
readonly readRuntimeConfig: () => Record<string, unknown>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type { BrowserConsoleEvent, DataRequest, DataResult, EditorContextData, EditorLifecycleStatus, EditorStateData, MockTemplateUpdateEvent, SceneRequest, SceneResult, ScreenshotRequest, ScreenshotResult, SpecUpdateEvent, StateRequest, StateResult, StateSection, } from './phoenix-pubsub.js';
|
|
1
|
+
export type { BrowserConsoleEvent, DataRequest, DataResult, EditorContextData, EditorLifecycleStatus, EditorStateData, MockTemplateUpdateEvent, SceneRequest, SceneResult, ScreenshotRequest, ScreenshotResult, SpecBuildStatus, SpecUpdateEvent, StateRequest, StateResult, StateSection, } from './phoenix-pubsub.js';
|
|
2
2
|
export { PhoenixPubSub } from './phoenix-pubsub.js';
|
|
3
3
|
export { PhoenixStore } from './phoenix-store.js';
|
|
4
4
|
export { DeploymentPreparationService, readGeneratedEnvMarkers } from './deployment/index.js';
|
|
@@ -19,9 +19,12 @@ export { compileWithSwc, watchWithSwc } from './swc.js';
|
|
|
19
19
|
export { STORY_DEV_MARKER_PATH, readActiveStoryDevMarker, type StoryDevMarker } from './story-dev-marker.js';
|
|
20
20
|
export { composeDefaultBanner } from './phx-banner-plugin.js';
|
|
21
21
|
export { getViteBuildConfigs, getViteDevConfig, setViteLogSink, type ViteLogSink, type ViteLogSinkOptions, } from './vite-config.js';
|
|
22
|
-
export { getServerCredentials, removeServerCredentials, saveServerCredentials } from './cli-credentials.js';
|
|
22
|
+
export { describeCliApiCredentialSource, getCliApiCredentials, getCliApiCredentialsHint, getServerCredentials, removeServerCredentials, saveServerCredentials, } from './cli-credentials.js';
|
|
23
23
|
export { exitCli, setBeforeCliExit } from './cli-exit.js';
|
|
24
24
|
export { createSourceArchive, extractSourceArchive } from './source-archive.js';
|
|
25
25
|
export { resolveSignedInDevelopmentEnvironment } from './signed-in-development-environment.js';
|
|
26
|
+
export { describeWorkspaceProjects, resolveDeployTarget, resolveTargetProject } from './spec-project/index.js';
|
|
26
27
|
export { createTelemetryClient, resolveTelemetryCommand, type CommandTelemetryAttempt, type TelemetryAssociation, type TelemetryClient, type TelemetryCommand, } from './telemetry/index.js';
|
|
27
|
-
export { DEFAULT_PHOENIX_REGION, PHOENIX_REGIONS, PUBLIC_PHOENIX_REGIONS, getRegionServerUrl, getRegionStudioUrl, } from './phoenix-regions.js';
|
|
28
|
+
export { DEFAULT_PHOENIX_REGION, PHOENIX_REGIONS, PUBLIC_PHOENIX_REGIONS, getRegionServerUrl, getRegionStudioUrl, getServerStudioUrl, } from './phoenix-regions.js';
|
|
29
|
+
export { describeSavedLogins, resolveCliServerUrl } from './cli-server/index.js';
|
|
30
|
+
export { type CredentialRoute, type DevExperience, readExplicitEditorSetting, resolveDevExperience, resolveRegeneratedPageExperience, } from './dev-experience/index.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{PhoenixPubSub}from"./phoenix-pubsub.js";export{PhoenixStore}from"./phoenix-store.js";export{DeploymentPreparationService,readGeneratedEnvMarkers}from"./deployment/index.js";export{PhoenixApplication}from"./session/index.js";export{VariantFileSession}from"./variant-file-session.js";export{VariantPreviewService}from"./variant-preview-service.js";export{MockTemplateWatcher}from"./mock-template-watcher.js";export{ApplicationSpecProjectWatcher}from"./application-spec-project-watcher.js";export{ApplicationSpecStoryWatcher}from"./application-spec-story-watcher.js";export{LinguiWatcher}from"./lingui-watcher.js";export{bootstrapLinguiCatalogs,extractAndCompileLingui}from"../lingui/index.js";export{loadMockTemplates,parseMockTemplateYaml}from"./spec-files.js";export{LOG_STREAMS,LogBus}from"./log-bus.js";export{createBusLogger}from"./bus-logger.js";export{patchConsole}from"./console-capture.js";export{WebhookTunnelMonitor}from"./webhook-tunnel-monitor.js";export{compileWithSwc,watchWithSwc}from"./swc.js";export{STORY_DEV_MARKER_PATH,readActiveStoryDevMarker}from"./story-dev-marker.js";export{composeDefaultBanner}from"./phx-banner-plugin.js";export{getViteBuildConfigs,getViteDevConfig,setViteLogSink}from"./vite-config.js";export{getServerCredentials,removeServerCredentials,saveServerCredentials}from"./cli-credentials.js";export{exitCli,setBeforeCliExit}from"./cli-exit.js";export{createSourceArchive,extractSourceArchive}from"./source-archive.js";export{resolveSignedInDevelopmentEnvironment}from"./signed-in-development-environment.js";export{createTelemetryClient,resolveTelemetryCommand}from"./telemetry/index.js";export{DEFAULT_PHOENIX_REGION,PHOENIX_REGIONS,PUBLIC_PHOENIX_REGIONS,getRegionServerUrl,getRegionStudioUrl}from"./phoenix-regions.js";
|
|
1
|
+
export{PhoenixPubSub}from"./phoenix-pubsub.js";export{PhoenixStore}from"./phoenix-store.js";export{DeploymentPreparationService,readGeneratedEnvMarkers}from"./deployment/index.js";export{PhoenixApplication}from"./session/index.js";export{VariantFileSession}from"./variant-file-session.js";export{VariantPreviewService}from"./variant-preview-service.js";export{MockTemplateWatcher}from"./mock-template-watcher.js";export{ApplicationSpecProjectWatcher}from"./application-spec-project-watcher.js";export{ApplicationSpecStoryWatcher}from"./application-spec-story-watcher.js";export{LinguiWatcher}from"./lingui-watcher.js";export{bootstrapLinguiCatalogs,extractAndCompileLingui}from"../lingui/index.js";export{loadMockTemplates,parseMockTemplateYaml}from"./spec-files.js";export{LOG_STREAMS,LogBus}from"./log-bus.js";export{createBusLogger}from"./bus-logger.js";export{patchConsole}from"./console-capture.js";export{WebhookTunnelMonitor}from"./webhook-tunnel-monitor.js";export{compileWithSwc,watchWithSwc}from"./swc.js";export{STORY_DEV_MARKER_PATH,readActiveStoryDevMarker}from"./story-dev-marker.js";export{composeDefaultBanner}from"./phx-banner-plugin.js";export{getViteBuildConfigs,getViteDevConfig,setViteLogSink}from"./vite-config.js";export{describeCliApiCredentialSource,getCliApiCredentials,getCliApiCredentialsHint,getServerCredentials,removeServerCredentials,saveServerCredentials}from"./cli-credentials.js";export{exitCli,setBeforeCliExit}from"./cli-exit.js";export{createSourceArchive,extractSourceArchive}from"./source-archive.js";export{resolveSignedInDevelopmentEnvironment}from"./signed-in-development-environment.js";export{describeWorkspaceProjects,resolveDeployTarget,resolveTargetProject}from"./spec-project/index.js";export{createTelemetryClient,resolveTelemetryCommand}from"./telemetry/index.js";export{DEFAULT_PHOENIX_REGION,PHOENIX_REGIONS,PUBLIC_PHOENIX_REGIONS,getRegionServerUrl,getRegionStudioUrl,getServerStudioUrl}from"./phoenix-regions.js";export{describeSavedLogins,resolveCliServerUrl}from"./cli-server/index.js";export{readExplicitEditorSetting,resolveDevExperience,resolveRegeneratedPageExperience}from"./dev-experience/index.js";
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import { Subject } from 'rxjs';
|
|
2
2
|
import type { RawProjectFiles } from '#package/application-spec';
|
|
3
3
|
import type { MockTemplateDefinition } from '#package/editor';
|
|
4
|
+
/** Whether the latest rebuild of the project files succeeded; an agent-mode page shows it on its badge. */
|
|
5
|
+
export type SpecBuildStatus = 'ok' | 'failed';
|
|
4
6
|
/** Batch of project files that changed on disk. */
|
|
5
7
|
export interface SpecUpdateEvent {
|
|
6
8
|
readonly rawProjectFiles: RawProjectFiles;
|
|
7
9
|
readonly projectRoot: string;
|
|
8
10
|
readonly configurationSchemaHash?: string;
|
|
11
|
+
/** How the rebuild this event reports went; absent when the event reports no rebuild. */
|
|
12
|
+
readonly build?: SpecBuildStatus;
|
|
9
13
|
}
|
|
10
14
|
/** Updated set of mock template definitions after a file change. */
|
|
11
15
|
export interface MockTemplateUpdateEvent {
|
|
@@ -15,4 +15,9 @@ export declare const getRegionServerUrl: (region: PhoenixRegion) => string;
|
|
|
15
15
|
* Studio of one workspace in a region. The slug becomes a subdomain, so anything but a plain slug is refused: it
|
|
16
16
|
* could otherwise point the sign-in at another host.
|
|
17
17
|
*/
|
|
18
|
-
export declare const getRegionStudioUrl: (region: PhoenixRegion, workspace: string) => string;
|
|
18
|
+
export declare const getRegionStudioUrl: (region: PhoenixRegion, workspace: string | undefined) => string;
|
|
19
|
+
/**
|
|
20
|
+
* Studio that pairs with a server, for a sign-in that names the server and no Studio. Only the server of a region
|
|
21
|
+
* has a known Studio; for a local or self-hosted server the user names it.
|
|
22
|
+
*/
|
|
23
|
+
export declare const getServerStudioUrl: (serverUrl: string, workspace: string | undefined) => string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const PHOENIX_REGIONS=["eu","us","staging"];export const PUBLIC_PHOENIX_REGIONS=["eu","us"];export const DEFAULT_PHOENIX_REGION="eu";let
|
|
1
|
+
export const PHOENIX_REGIONS=["eu","us","staging"];export const PUBLIC_PHOENIX_REGIONS=["eu","us"];export const DEFAULT_PHOENIX_REGION="eu";let t={eu:{serverUrl:"https://production-eu-central-1.salsita.ai",studioDomain:"studio.eu.salsita.ai"},us:{serverUrl:"https://production-us-east-1.salsita.ai",studioDomain:"studio.salsita.ai"},staging:{serverUrl:"https://staging.salsita.app",studioDomain:"studio-staging.salsita.app"}},s=/^[a-z0-9-]+$/;export const getRegionServerUrl=s=>t[s].serverUrl;export const getRegionStudioUrl=(e,o)=>{if(void 0===o)return`https://${t[e].studioDomain}`;if(!s.test(o))throw Error(`"${o}" is not a workspace slug. A slug has only lowercase letters, digits and dashes; use the one from your Studio address.`);return`https://${o}.${t[e].studioDomain}`};export const getServerStudioUrl=(s,e)=>{let o=PHOENIX_REGIONS.find(e=>new URL(t[e].serverUrl).origin===new URL(s).origin);if(void 0===o)throw Error(`The Studio of ${s} is not known, because it is not the server of a Phoenix region. Pass --studioUrl <url> with the address of the Studio that belongs to it.`);return getRegionStudioUrl(o,e)};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{writeFile as e}from"node:fs/promises";import{
|
|
2
|
-
`),p.debug(`Environment variables written to ${
|
|
1
|
+
import{writeFile as e}from"node:fs/promises";import{createCliApiClient as i}from"#package/client";import{resolveApplicationSpecDeploymentData as t}from"../application-spec/index.js";import{formatEnvContent as r,uploadFilesWithPresignedUrls as s}from"../utils/index.js";import{getDevelopmentCredentialHint as o,getDevelopmentHeaders as a}from"./development-credential.js";export const prepareDevelopmentEnvironment=async(n,l)=>{let{logger:p}=l,{projectSlug:d,environmentSlug:m,serverUrl:c,credential:h,outFile:f,skipUpload:v,overrideSchema:u,projectVersion:g}=n;p.step("Preparing development environment"),p.info(`Preparing development environment for project "${d}", environment "${m}"`);let E=i(c);p.debug(`Using server URL: ${c}`);let P=await t({skipUpload:v,logger:p});p.info("Preparing and activating the development deployment on the server...");let{data:b,error:$}=await E.POST("/environments/development/prepare",{body:{applicationVersion:P.applicationVersion,publishedDataHash:P.publishedDataHash,useAuthHook:P.useAuthHook,useCognito:P.useCognito,accessMode:P.accessMode,sessionFields:P.sessionFields,overrideSchema:u,configurationSchema:{version:P.schemaVersion,schema:P.schema},adminConfigurationSchema:P.adminSchema?{schema:P.adminSchema,version:P.adminSchemaVersion}:void 0,chat:P.chat,embeddings:P.embeddings,...P.assistant?{assistant:!0}:{},acl:{canCreate:P.aclCanCreate},privateFiles:[...P.assets.privateFilePaths],publicFiles:[...P.assets.publicFilePaths],sdkVersion:g},headers:a(h,{projectSlug:d,environmentSlug:m})});if($)throw Error(`Failed to prepare development deployment for ${d}/${m} on ${c}: ${$.message}. ${o(h,d)}`);if(!b)throw Error("No data returned from server while preparing the development deployment.");for(let e of b.warnings??[])p.warn(e);let{environmentVariables:w,privateUploadUrls:F,publicUploadUrls:y}=b;if(v)p.debug("Skipping file upload");else{p.info("Uploading files to S3...");let e={privateFiles:[...P.assets.privateFilesFullPaths].map(e=>{let i=e.replace("assets/private/",""),t=F[i];if(!t)throw Error(`No upload URL provided for private file ${i}, the server did not return a presigned URL for this file, please verify the file exists in the assets/private directory.`);return{localPath:e,uploadUrl:t}}),publicFiles:[...P.assets.publicFilesFullPaths].map(e=>{let i=e.replace("assets/public/",""),t=y[i];if(!t)throw Error(`No upload URL provided for public file ${i}, the server did not return a presigned URL for this file, please verify the file exists in the assets/public directory.`);return{localPath:e,uploadUrl:t}})};await s(e,{logger:p})}try{await e(f,`${r({...w,PHOENIX_PROJECT_SLUG:d,PHOENIX_ENVIRONMENT_SLUG:m,PHOENIX_SERVER_URL:c,PHOENIX_DEPLOYMENT_FINGERPRINT:P.fingerprint})}
|
|
2
|
+
`),p.debug(`Environment variables written to ${f}`)}catch{throw Error(`Failed to write environment variables to file at ${f}, please verify you have write permissions to this location.`)}p.info(`Project: ${d}`),p.info(`Environment: ${m}`),p.info(`Deployment ID: ${w.DEPLOYMENT_ID}`),p.success("Development environment prepared successfully!")};
|
|
@@ -2,6 +2,7 @@ import { Subject } from 'rxjs';
|
|
|
2
2
|
import { createServer } from 'vite';
|
|
3
3
|
import { type Logger } from '../../utils/index.js';
|
|
4
4
|
import { DeploymentPreparationService } from '../deployment/index.js';
|
|
5
|
+
import type { DevExperience } from '../dev-experience/index.js';
|
|
5
6
|
import { type DevelopmentCredential } from '../development-credential.js';
|
|
6
7
|
import { LinguiWatcher } from '../lingui-watcher.js';
|
|
7
8
|
import { LogBus } from '../log-bus.js';
|
|
@@ -16,7 +17,7 @@ export interface PhoenixDevelopmentOptions {
|
|
|
16
17
|
readonly projectSlug: string;
|
|
17
18
|
readonly environmentSlug: string;
|
|
18
19
|
readonly cliUseWorkspace: boolean | undefined;
|
|
19
|
-
readonly
|
|
20
|
+
readonly devExperience: DevExperience;
|
|
20
21
|
readonly debug: boolean;
|
|
21
22
|
readonly withLingui: boolean;
|
|
22
23
|
readonly persistenceMode: string | undefined;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Subject as e}from"rxjs";import{createServer as t}from"vite";import{resolveGeneratedEnvFile as
|
|
2
|
-
${
|
|
1
|
+
import{Subject as e}from"rxjs";import{createServer as t}from"vite";import{resolveGeneratedEnvFile as r}from"@salsita-ai/common/env";import{generateProjectFiles as o,getDeploymentFingerprint as s}from"../../application-spec/index.js";import{exists as i}from"../../utils/index.js";import{buildWebhooks as n,webhookLogContext as a}from"../../webhooks/index.js";import{ApplicationSpecProjectWatcher as l}from"../application-spec-project-watcher.js";import{ApplicationSpecStoryWatcher as c}from"../application-spec-story-watcher.js";import{DeploymentPreparationService as h,readGeneratedEnvMarkers as p}from"../deployment/index.js";import{getDevelopmentCredentialHint as u}from"../development-credential.js";import{LinguiWatcher as g}from"../lingui-watcher.js";import{LogBus as m}from"../log-bus.js";import{MockTemplateWatcher as d}from"../mock-template-watcher.js";import{PhoenixPubSub as v}from"../phoenix-pubsub.js";import{PhoenixStore as w}from"../phoenix-store.js";import{VariantPreviewService as b}from"../variant-preview-service.js";import{getViteDevConfig as S}from"../vite-config.js";import{createWebhookTunnelTransport as E,readOrCreateTunnelSessionId as x,startWebhookService as f}from"../webhook-service/index.js";import{WebhookTunnelMonitor as P}from"../webhook-tunnel-monitor.js";export class PhoenixApplication{props;context;store=new w;pubsub=new v;failures$=new e;logsValue;tunnelMonitorValue;deploymentPreparationValue;variantPreviewsValue;linguiWatcherValue;projectWatcher;storyWatcher;mockTemplateWatcher;editorServer;webhookTunnel;browserConsoleSubscription;startPromise;closePromise;constructor(e,t){this.props=e,this.context=t;let r="dev"===e.mode?e.development:void 0,o=r&&(!r.persistenceMode||"server"===r.persistenceMode);this.logsValue="dev"===e.mode?new m:void 0,this.tunnelMonitorValue=o&&r.serverUrl?new P(r.serverUrl):void 0,this.deploymentPreparationValue=o&&r.serverUrl&&r.credential?new h({serverUrl:r.serverUrl,credential:r.credential,projectSlug:r.projectSlug,environmentSlug:r.environmentSlug,sdkVersion:r.sdkVersion},{store:this.store,get logger(){return t.logger}}):void 0}get logs(){return this.logsValue}get tunnelMonitor(){return this.tunnelMonitorValue}get deploymentPreparation(){return this.deploymentPreparationValue}get projectRoot(){return this.props.projectRoot}get mode(){return this.props.mode}get variantPreviews(){return this.variantPreviewsValue}get linguiWatcher(){return this.linguiWatcherValue}start(){return this.startPromise??=this.startSession(),this.startPromise}close(){return this.closePromise??=this.closeResources(this.context.logger),this.closePromise}async startSession(){try{if(this.assertStarting(),"story"===this.mode)return void await this.startEditor();let e=this.logs;if(!e)throw Error("Cannot start development: the application has no log bus.");return this.browserConsoleSubscription=this.pubsub.browserConsole$.subscribe(t=>this.context.onBrowserConsole(t,e)),await this.startDevelopment()}catch(e){throw this.closePromise||this.context.onStartupFailure(e),await this.close(),e}}async startEditor(){let e=this.props.editorPort;void 0!==e&&("dev"===this.mode&&this.context.logger.step("Starting editor WebSocket server"),this.editorServer=this.context.createEditorServer({port:e,application:this,logger:this.context.logger,debug:this.props.development?.debug??!1}),await this.editorServer.ready,this.assertStarting(),"dev"===this.mode&&this.context.logger.debug(`Editor WebSocket server started on port ${e}`),this.mockTemplateWatcher=new d({projectRoot:this.projectRoot,pubsub:this.pubsub,logger:this.context.logger}),this.mockTemplateWatcher.start(),"story"===this.mode&&(this.storyWatcher=new c({projectRoot:this.projectRoot,pubsub:this.pubsub,logger:this.context.logger}),this.storyWatcher.start()))}async startDevelopment(){let e=this.props.development,c=this.logs;if(!e||!c)throw Error("Cannot start development: session options are missing. Supply development options when constructing the application.");let{sdkVersion:h,projectSlug:m,environmentSlug:d,cliUseWorkspace:v,devExperience:w,debug:P,withLingui:j,persistenceMode:y,force:k,serverUrl:V,credential:W,skipUpload:R}=e,{store:N,pubsub:T,deploymentPreparation:I,tunnelMonitor:_}=this;process.env.NODE_ENV="development",y&&(process.env.PERSISTENCE_MODE=y);let O=!y||"server"===y;if(O&&V&&(process.env.SERVER_URL=V),this.context.logger.step("Starting development mode"),!await i("spec"))throw Object.assign(Error('Spec folder not found. Run "phoenix init" first.'),{code:"SPEC_NOT_FOUND"});if(O&&(!V||!W))throw Error("Server persistence needs a server and a credential. Run `phoenix login`, or create a development environment in Studio and paste its .env block into .env.");this.context.logger.step("Building project files");let{templateFiles:D,applicationSpec:$}=await o({sdkVersion:h,projectSlug:m,environmentSlug:d,cliUseWorkspace:v,pageExperience:w,withLingui:j,force:k},{logger:this.context.logger});if(this.assertStarting(),this.context.logger.success("Project files built successfully"),O&&V&&W){let e=r("."),t=await p(e);k||t?.PHOENIX_PROJECT_SLUG!==m||t.PHOENIX_ENVIRONMENT_SLUG!==d||t.PHOENIX_SERVER_URL!==V||t.PHOENIX_DEPLOYMENT_FINGERPRINT!==s($)?(this.context.logger.step("Preparing development deployment"),await I?.prepareAtStartup({skipUpload:R,debug:P})):this.context.logger.debug(`${e} matches the current development environment, skipping prepare`)}if(this.assertStarting(),this.context.onProjectPrepared(c),j?(this.linguiWatcherValue=new g({logger:this.context.logger}),this.linguiWatcherValue.start()):this.context.logger.warn("Continuous Lingui updates are disabled; missing catalogs were bootstrapped at startup. Pass --withLingui or set WITH_LINGUI=true to enable."),O&&(this.context.logger.step("Building webhooks"),await a.run("webhook",async()=>{await n({experimental:!0,skipNodeEnvOverride:!0,webhookEntryPoint:"./.phoenix/.swc/.phoenix/webhook.js"})})),O&&V&&W){let e=r("."),t=await p(e);if(!t?.DEPLOYMENT_ID)throw Error(`Webhook tunnel cannot start because ${e} has no DEPLOYMENT_ID. Rerun phoenix dev to prepare the development deployment.`);this.assertStarting();let o=await x();this.assertStarting();let s=await f({experimental:!0,transport:E({serverUrl:V,credential:W,projectSlug:m,environmentSlug:d}),rejectionHint:u(W,m),environmentSlug:d,deploymentId:t.DEPLOYMENT_ID,sessionId:o,onStatus:(e,r)=>{_?.setStatus(e,{deploymentId:t.DEPLOYMENT_ID,sessionId:o,message:r??null})},onRequest:e=>_?.record(e)});this.closePromise&&(await s.stop(),this.assertStarting()),this.webhookTunnel=s,_?.setStatus("waiting",{deploymentId:t.DEPLOYMENT_ID,sessionId:o}),s.stopped.catch(e=>{this.failures$.next(Error(`Webhook tunnel failed: ${e instanceof Error?e.message:String(e)}`)),this.close()}),this.context.logger.success("Webhook tunnel started")}this.assertStarting();let M=new l({pubsub:T,logger:this.context.logger,sdkVersion:h,projectSlug:m,environmentSlug:d,cliUseWorkspace:v,pageExperience:w,inlineTemplates:!1,useServer:O},{store:N,linguiWatcher:this.linguiWatcherValue,deploymentPreparation:I});this.projectWatcher=M,this.variantPreviewsValue=new b({projectRoot:this.projectRoot},{store:N,logger:this.context.logger,projectWatcher:M}),"plain"!==w&&void 0!==this.props.editorPort&&await this.startEditor();let C=await S({templateFiles:D,agentMode:"agent"===w}),L=await t(C);return this.closePromise&&(await L.close(),this.assertStarting()),this.store.viteServer$.next(L),await L.listen(),this.assertStarting(),this.context.logger.step("Starting Vite dev server"),M.start(L),L}assertStarting(){if(this.closePromise)throw Error("Cannot continue startup: the session has already closed. Start a new Phoenix application.")}async closeResources(e){"dev"===this.mode&&e.debug("Shutting down...");let t="story"===this.mode?[{name:"story source watcher",close:()=>this.storyWatcher?.close()},{name:"mock-template watcher",close:()=>this.mockTemplateWatcher?.close()},{name:"editor server",close:()=>this.editorServer?.close()}]:[{name:"lingui watcher",close:()=>this.linguiWatcherValue?.close()},{name:"project watcher",close:()=>this.projectWatcher?.close()},{name:"mock template watcher",close:()=>this.mockTemplateWatcher?.close()},{name:"editor server",close:()=>this.editorServer?.close()},{name:"variant previews",close:()=>this.variantPreviewsValue?.dispose()},{name:"vite server",close:()=>this.store.viteServer$.value?.close()},{name:"webhook tunnel",close:()=>this.webhookTunnel?.stop()}],r=[];for(let o of t)try{"dev"===this.mode&&e.debug(`Shutting down ${o.name}`),await o.close()}catch(s){let t=s instanceof Error?s.message:String(s);"story"===this.mode?e.warn(`Failed to close the story-dev ${o.name}: ${t}. The process will continue shutting down.`):r.push(`${o.name}: ${t}`)}this.browserConsoleSubscription?.unsubscribe(),this.failures$.complete(),r.length>0&&e.warn(`Cleanup warnings:
|
|
2
|
+
${r.join("\n ")}`),"dev"===this.mode&&e.debug("Shutdown complete")}}
|
|
@@ -1,17 +1,28 @@
|
|
|
1
|
+
import type { Logger } from '../utils/index.js';
|
|
1
2
|
interface SignedInDevelopmentEnvironmentProps {
|
|
2
3
|
readonly serverUrl: string;
|
|
3
|
-
readonly
|
|
4
|
+
readonly flagProject: string | undefined;
|
|
5
|
+
readonly specProject: string | undefined;
|
|
6
|
+
readonly specProjectSource: string;
|
|
7
|
+
readonly projectRoot: string;
|
|
8
|
+
readonly interactive: boolean;
|
|
9
|
+
}
|
|
10
|
+
interface SignedInDevelopmentEnvironmentContext {
|
|
11
|
+
readonly logger: Logger;
|
|
12
|
+
readonly ask: (question: string) => Promise<string>;
|
|
4
13
|
}
|
|
5
14
|
/** The development environment `phoenix dev` works in when it authenticates with the stored login. */
|
|
6
15
|
interface SignedInDevelopmentEnvironment {
|
|
7
16
|
readonly apiToken: string;
|
|
8
|
-
|
|
17
|
+
/** Name of the workspace the sign-in is bound to. A personal sign-in has none. */
|
|
18
|
+
readonly workspaceName: string | undefined;
|
|
9
19
|
readonly projectSlug: string;
|
|
10
20
|
readonly environmentSlug: string;
|
|
11
21
|
}
|
|
12
22
|
/**
|
|
13
23
|
* Asks the server for the signed-in user's development environment in a project. The server creates it on the first
|
|
14
|
-
* call, so nothing has to be set up in Studio.
|
|
24
|
+
* call, so nothing has to be set up in Studio. The project is the one --project or the spec names, or one of the
|
|
25
|
+
* projects the sign-in can reach.
|
|
15
26
|
*/
|
|
16
|
-
export declare const resolveSignedInDevelopmentEnvironment: (props: SignedInDevelopmentEnvironmentProps) => Promise<SignedInDevelopmentEnvironment>;
|
|
27
|
+
export declare const resolveSignedInDevelopmentEnvironment: (props: SignedInDevelopmentEnvironmentProps, context: SignedInDevelopmentEnvironmentContext) => Promise<SignedInDevelopmentEnvironment>;
|
|
17
28
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{createCliApiClient as e}from"#package/client";import{getServerCredentials as o}from"./cli-credentials.js";import{describeSavedLogins as n}from"./cli-server/index.js";import{resolveTargetProject as r}from"./spec-project/index.js";export const resolveSignedInDevelopmentEnvironment=async(t,i)=>{let{serverUrl:a,projectRoot:c}=t,s=await o(a);if(!s)throw Error(`phoenix dev has no development key and you are not signed in to ${a}. ${await n()??"Run `phoenix login`."} Or paste the .env block of a Studio development environment into .env.`);void 0!==process.env.PHOENIX_API_TOKEN&&i.logger.info(`phoenix dev ignores PHOENIX_API_TOKEN: it develops with the saved login on ${a}${s.customerName?` for workspace ${s.customerName}`:""}.`);let p=await r({serverUrl:a,token:s.token,flagProject:t.flagProject,specProject:t.specProject,specProjectSource:t.specProjectSource,projectRoot:c,interactive:t.interactive,credentialHint:"Run `phoenix login` again."},i),{data:m,error:l}=await e(a).POST("/environments/development/resolve",{body:{project:p},headers:{authorization:`Bearer ${s.token}`}});if(l||!m)throw Error(`The server did not provide a development environment for project "${p}"${s.customerSlug?` in workspace "${s.customerSlug}"`:""} on ${a}: ${l?.message??"no response"}`);return{apiToken:s.token,workspaceName:s.customerName,projectSlug:m.projectSlug,environmentSlug:m.environmentSlug}};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** A workspace of the session, as `/auth/me` lists it. */
|
|
2
|
+
interface SessionWorkspace {
|
|
3
|
+
readonly slug: string;
|
|
4
|
+
readonly name: string;
|
|
5
|
+
readonly projects: readonly {
|
|
6
|
+
readonly slug: string;
|
|
7
|
+
}[];
|
|
8
|
+
}
|
|
9
|
+
/** One workspace with the project slugs the credential can reach in it, as `whoami` and deploy errors list them. */
|
|
10
|
+
export declare const describeWorkspaceProjects: (workspace: SessionWorkspace) => string;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const describeWorkspaceProjects=e=>`${e.name} (${e.slug}): ${e.projects.map(e=>e.slug).join(", ")||"no project access"}`;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{describeWorkspaceProjects}from"./describe-workspace-projects.js";export{resolveDeployTarget}from"./resolve-deploy-target.js";export{resolveTargetProject}from"./resolve-target-project.js";
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
interface ResolveDeployTargetProps {
|
|
2
|
+
readonly serverUrl: string;
|
|
3
|
+
/** API token of the credential the deploy runs with. */
|
|
4
|
+
readonly token: string;
|
|
5
|
+
/** Slug of the project the deploy is about to upload to. */
|
|
6
|
+
readonly project: string;
|
|
7
|
+
/** What to do when the server refuses the token: sign in again, or replace the variable that supplies it. */
|
|
8
|
+
readonly credentialHint: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Where a deploy goes and who it acts as, checked against the server before anything is packed, so a wrong project
|
|
12
|
+
* or account shows before it reaches a live configurator.
|
|
13
|
+
*/
|
|
14
|
+
interface DeployTarget {
|
|
15
|
+
/** Workspace that owns the project. Null when the server is too old to list the workspaces of the session. */
|
|
16
|
+
readonly workspace: {
|
|
17
|
+
readonly slug: string;
|
|
18
|
+
readonly name: string;
|
|
19
|
+
} | null;
|
|
20
|
+
/**
|
|
21
|
+
* Workspaces the named slug is in when it is in several of them; the server then deploys to the one whose project the
|
|
22
|
+
* credential can manage, and `workspace` is null. Empty otherwise.
|
|
23
|
+
*/
|
|
24
|
+
readonly ambiguousWorkspaces: readonly {
|
|
25
|
+
readonly slug: string;
|
|
26
|
+
readonly name: string;
|
|
27
|
+
}[];
|
|
28
|
+
/** How the deploy names the project: its slug, or `<slug>--<workspace slug>`. */
|
|
29
|
+
readonly project: string;
|
|
30
|
+
/** The project's slug within its workspace, which Studio addresses name it by. */
|
|
31
|
+
readonly projectSlug: string;
|
|
32
|
+
/** Email of the account, or its id on a server that sends no email. */
|
|
33
|
+
readonly account: string;
|
|
34
|
+
/** API version the server reported with the session, when it sent one. */
|
|
35
|
+
readonly apiVersion: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* The previews of the project a deploy can build into, which `--env` is checked against. Null when the server does
|
|
38
|
+
* not list them, a server from before previews.
|
|
39
|
+
*/
|
|
40
|
+
readonly previews: readonly string[] | null;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Reads the session of the credential and finds the workspace of the project a deploy targets. A project the
|
|
44
|
+
* credential cannot reach stops the deploy here with the ones it can, instead of after packing and uploading.
|
|
45
|
+
*/
|
|
46
|
+
export declare const resolveDeployTarget: ({ serverUrl, token, project, credentialHint, }: ResolveDeployTargetProps) => Promise<DeployTarget>;
|
|
47
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createCliApiClient as e}from"#package/client";import{describeWorkspaceProjects as r}from"./describe-workspace-projects.js";export const resolveDeployTarget=async({serverUrl:o,token:s,project:a,credentialHint:p})=>{let{data:t,error:c,response:l}=await e(o).GET("/auth/me",{headers:{authorization:`Bearer ${s}`}});if(c||!t){let e=401===l.status?` ${p}`:"";throw Error(`Your sign-in could not be checked: ${(c?.message??"no response").replace(/\.$/,"")}.${e}`)}let i=t.email??t.userId,n=l.headers.get("x-api-version");if(void 0===t.workspaces)return{workspace:null,ambiguousWorkspaces:[],project:a,projectSlug:a,account:i,apiVersion:n,previews:null};let u=t.workspaces.flatMap(e=>e.projects.filter(r=>r.slug===a||`${r.slug}--${e.slug}`===a).map(r=>({workspace:{slug:e.slug,name:e.name},projectSlug:r.slug,previews:r.previews??null}))),[g]=u;if(void 0===g){let e=t.workspaces.map(r).join("; ");throw Error(`Project "${a}" is not one ${i} can reach on ${o}, so nothing was packed or uploaded. ${e?`Reachable projects: ${e}`:"The credential reaches no workspace"}. Pass --project <slug> or set \`project\` in spec/application.yaml to one of them, or ask a workspace administrator for access to "${a}".`)}return u.length>1?{workspace:null,ambiguousWorkspaces:u.map(e=>e.workspace),project:a,projectSlug:g.projectSlug,account:i,apiVersion:n,previews:null}:{workspace:g.workspace,ambiguousWorkspaces:[],project:a,projectSlug:g.projectSlug,account:i,apiVersion:n,previews:g.previews}};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { Logger } from '../../utils/index.js';
|
|
2
|
+
interface ResolveTargetProjectProps {
|
|
3
|
+
readonly serverUrl: string;
|
|
4
|
+
/** API token of the sign-in the command runs with. */
|
|
5
|
+
readonly token: string;
|
|
6
|
+
/** Project slug named with `--project`. It wins over the spec. */
|
|
7
|
+
readonly flagProject: string | undefined;
|
|
8
|
+
/** `project` of the application spec, when a spec file sets it, or the project `.env` names in its place. */
|
|
9
|
+
readonly specProject: string | undefined;
|
|
10
|
+
/** Where `specProject` comes from, for messages: the spec, or `PROJECT_SLUG` for `phoenix dev`. */
|
|
11
|
+
readonly specProjectSource: string;
|
|
12
|
+
/** Folder of the project whose spec may get the chosen project written into it. */
|
|
13
|
+
readonly projectRoot: string;
|
|
14
|
+
/** Whether somebody can answer a prompt: false for an agent, CI or piped input. */
|
|
15
|
+
readonly interactive: boolean;
|
|
16
|
+
/** What to do when the server refuses the token: sign in again, or replace the variable that supplies it. */
|
|
17
|
+
readonly credentialHint: string;
|
|
18
|
+
}
|
|
19
|
+
interface ResolveTargetProjectContext {
|
|
20
|
+
readonly logger: Logger;
|
|
21
|
+
/** Prints a question and resolves with the trimmed line typed as the answer. */
|
|
22
|
+
readonly ask: (question: string) => Promise<string>;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Decides which server project `phoenix dev` and `phoenix deploy` work in: the one named with `--project`, else the
|
|
26
|
+
* one the spec names, else one of the projects the sign-in can reach.
|
|
27
|
+
*
|
|
28
|
+
* With no project named, a terminal gets a select of the reachable projects; without a terminal the only reachable
|
|
29
|
+
* project is used and several stop the command with the list, since nobody can choose. A choice the spec does not
|
|
30
|
+
* hold yet is offered for saving. A spec that still says `project: default` names no project: that alias for a
|
|
31
|
+
* workspace's original project no longer exists.
|
|
32
|
+
*/
|
|
33
|
+
export declare const resolveTargetProject: (props: ResolveTargetProjectProps, context: ResolveTargetProjectContext) => Promise<string>;
|
|
34
|
+
export {};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{DEFAULT_PROJECT_ALIAS as e}from"@salsita-ai/contracts/domain";import{createCliApiClient as t}from"#package/client";import{describeWorkspaceProjects as r}from"./describe-workspace-projects.js";import{writeSpecProject as o}from"./write-spec-project.js";let a=t=>{let r=t?.trim();return r&&r!==e?r:void 0},n=async({serverUrl:e,token:r,credentialHint:o})=>{let{data:a,error:n,response:s}=await t(e).GET("/auth/me",{headers:{authorization:`Bearer ${r}`}});if(n||!a){let t=401===s.status?` ${o}`:"";throw Error(`Phoenix could not list the projects your sign-in can reach on ${e}: ${(n?.message??"no response").replace(/\.$/,"")}. The list is needed because neither --project nor the spec names a project.${t} Passing --project <slug> skips the list.`)}let i=(a.workspaces??[]).flatMap(e=>e.projects.map(t=>({slug:t.slug,name:t.name,workspaceName:e.name,workspaceSlug:e.slug})));return i.map(e=>({...e,target:i.filter(t=>t.slug===e.slug).length>1?`${e.slug}--${e.workspaceSlug}`:e.slug}))},s=async(e,{logger:t,ask:r})=>{let o=e.map((e,t)=>` ${t+1}. ${e.target} (${e.name}, workspace ${e.workspaceName})`).join("\n");for(t.info(`Neither --project nor the spec names a project. Your sign-in can reach:
|
|
2
|
+
${o}`);;){let o=await r(`Project to use [1-${e.length}]: `),a=e.find((e,t)=>o===String(t+1)||o===e.target);if(a)return a.target;t.warn(`"${o}" is not on the list. Type a number from 1 to ${e.length}, or a project slug.`)}},i=async(t,r,{logger:a,ask:n})=>{let s=`project: ${t}`;if(!r.interactive){let o=r.flagProject?.trim()?"keep passing --project":`pass --project ${t}`;a.info(r.specProject?.trim()===e?`Replace \`${e}\` in ${r.specProjectSource} with \`${t}\`, or ${o}, to target it on later runs.`:`Add \`${s}\` to spec/application.yaml, or ${o}, to target it on later runs.`);return}if(!["","y","yes"].includes((await n(`Write \`${s}\` to the spec so later runs use it? [Y/n] `)).toLowerCase()))return;let i=await o(r.projectRoot,t);a.info(void 0===i?`Phoenix could not write \`${s}\` into the spec, because \`project\` is set there in a form it cannot rewrite or spec/application.yaml is missing. Set it by hand.`:`${i} now says \`${s}\`. Commit the change.`)};export const resolveTargetProject=async(t,o)=>{let{serverUrl:c,interactive:p}=t,{logger:l}=o,g=a(t.specProject);if(t.flagProject?.trim()===e)throw Error(`--project ${e} names no project: \`${e}\` was an alias for a workspace's original project and no longer exists. Pass the project's slug; \`phoenix whoami\` lists the ones you can reach.`);let u=a(t.flagProject);if(void 0!==u)return void 0===g?await i(u,t,o):g!==u&&l.info(`Using project "${u}" from --project instead of "${g}" from ${t.specProjectSource}.`),u;if(void 0!==g)return g;t.specProject?.trim()===e&&l.warn(`The project \`${e}\` from ${t.specProjectSource} no longer names a project. Replace it with a project slug.`);let m=await n(t),[h]=m;if(void 0===h)throw Error(`Your sign-in on ${c} can reach no project, and neither --project nor the spec names one. Create a project in Studio, or ask a workspace administrator for project access, then run the command again.`);if(p){let e=await s(m,o);return await i(e,t,o),e}if(m.length>1)throw Error(`Neither --project nor the spec names a project, and your sign-in can reach ${m.length} (${[...new Set(m.map(e=>e.workspaceSlug))].map(e=>{let t=m.filter(t=>t.workspaceSlug===e);return r({slug:e,name:t[0]?.workspaceName??e,projects:t})}).join("; ")}). Pass --project <slug>, or set \`project\` in spec/application.yaml to the slug of the one to work in.`);return l.info(`Using project "${h.target}", the only project your sign-in can reach.`),await i(h.target,t,o),h.target};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Writes the project a command targets into the spec, and returns the path of the changed file within the project.
|
|
3
|
+
* A spec file that still says `project: default` gets the slug in place of that value; otherwise the slug is added
|
|
4
|
+
* to `spec/application.yaml`. Returns nothing, and writes nothing, when `project` is set in a form that cannot be
|
|
5
|
+
* rewritten safely (a block scalar, an alias, an empty value) or there is no application spec file to add it to.
|
|
6
|
+
*/
|
|
7
|
+
export declare const writeSpecProject: (projectRoot: string, projectSlug: string) => Promise<string | undefined>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{globby as t}from"globby";import{readFile as e,writeFile as r}from"node:fs/promises";import{join as i}from"node:path";import{Scalar as a,isMap as n,isScalar as o,parseDocument as l,stringify as p}from"yaml";import{DEFAULT_PROJECT_ALIAS as s}from"@salsita-ai/contracts/domain";import{SPEC_FILE_PATTERN as m}from"../../application-spec/index.js";let c="spec/application.yaml",f=(t,e)=>{let r=l(t).get("project",!0);if(!o(r)||!r.range||"string"!=typeof r.value||r.type===a.BLOCK_LITERAL||r.type===a.BLOCK_FOLDED||r.value.trim()!==s)return t;let[i,n]=r.range;return`${t.slice(0,i)}${p(e).trimEnd()}${t.slice(n)}`};export const writeSpecProject=async(a,o)=>{let s=(await t(m,{cwd:a})).sort(),u=await Promise.all(s.map(async t=>({filePath:t,text:await e(i(a,t),"utf-8")})));for(let{filePath:t,text:e}of u){let n=f(e,o);if(n!==e)return await r(i(a,t),n),t}let $=u.find(t=>t.filePath===c);if(!$||u.some(t=>l(t.text).has("project")))return;let d=((t,e)=>{let{contents:r}=l(t),i=t.includes("\r\n")?"\r\n":"\n",a=`project: ${p(e).trimEnd()}${i}`;if(null===r)return`${t}${""===t||t.endsWith("\n")?"":i}${a}`;if(!n(r)||!r.range)return t;let[o]=r.range,s=`${t.slice(0,o)}${a}${t.slice(o)}`,m=l(s);return 0===m.errors.length&&m.get("project")===e?s:t})($.text,o);if(d!==$.text)return await r(i(a,c),d),c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const createCommandEvent=(e,t)=>({eventId:t.createId(),name:"ready"===e.phase?"cli_dev_server_ready":"started"===e.phase?"cli_command_started":"cli_command_completed",occurredAt:e.occurredAt,deviceId:e.identity.installationId,..."userId"in e.identity?{userId:e.identity.userId}:{},properties:{schema_version:1,source:"cli",command:e.command,attempt_id:e.attemptId,phase:e.phase,outcome:e.outcome,...void 0===e.durationMs?{}:{duration_ms:e.durationMs},...void 0===e.failureCategory?{}:{failure_category:e.failureCategory},sdk_version:e.sdkVersion,classification:"userId"in e.identity?"general":"unknown",work_session_id:e.identity.workSessionId,..."workspaceId"in e.identity?{workspace_id:e.identity.workspaceId}:{}}});
|
|
1
|
+
export const createCommandEvent=(e,t)=>({eventId:t.createId(),name:"ready"===e.phase?"cli_dev_server_ready":"started"===e.phase?"cli_command_started":"cli_command_completed",occurredAt:e.occurredAt,deviceId:e.identity.installationId,..."userId"in e.identity?{userId:e.identity.userId}:{},properties:{schema_version:1,source:"cli",command:e.command,attempt_id:e.attemptId,phase:e.phase,outcome:e.outcome,...void 0===e.durationMs?{}:{duration_ms:e.durationMs},...void 0===e.failureCategory?{}:{failure_category:e.failureCategory},sdk_version:e.sdkVersion,classification:"userId"in e.identity?"general":"unknown",work_session_id:e.identity.workSessionId,..."workspaceId"in e.identity&&null!==e.identity.workspaceId?{workspace_id:e.identity.workspaceId}:{}}});
|
|
@@ -8,7 +8,7 @@ export interface TelemetryAssociation {
|
|
|
8
8
|
/** Stable authenticated builder user ID, mapped to Amplitude's user_id after authentication. */
|
|
9
9
|
readonly userId: string;
|
|
10
10
|
/** Internal UUID of the SDK-builder workspace the CLI authenticated against. */
|
|
11
|
-
readonly workspaceId: string;
|
|
11
|
+
readonly workspaceId: string | null;
|
|
12
12
|
}
|
|
13
13
|
export type TelemetryIdentity = AnonymousTelemetryIdentity | (AnonymousTelemetryIdentity & TelemetryAssociation);
|
|
14
14
|
interface TelemetryStateContext {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{randomUUID as t}from"node:crypto";import{chmod as e,mkdir as i,readFile as n,writeFile as a}from"node:fs/promises";import{homedir as s}from"node:os";import{dirname as r,join as o}from"node:path";import{z as d}from"zod";let l=d.object({installationId:d.string().uuid(),workSessionId:d.string().uuid(),lastActiveAt:d.string().datetime()}),c=d.union([l.extend({userId:d.string().min(5),workspaceId:d.string().uuid()}),l.strict()]),I={createId:t,now:()=>new Date};export const getTelemetryStatePath=()=>process.env.PHOENIX_TELEMETRY_FILE??o(s(),".phoenix","telemetry.json");let u=async(t,n)=>{await i(r(t),{recursive:!0,mode:448}),await a(t,`${JSON.stringify(n,null,2)}
|
|
1
|
+
import{randomUUID as t}from"node:crypto";import{chmod as e,mkdir as i,readFile as n,writeFile as a}from"node:fs/promises";import{homedir as s}from"node:os";import{dirname as r,join as o}from"node:path";import{z as d}from"zod";let l=d.object({installationId:d.string().uuid(),workSessionId:d.string().uuid(),lastActiveAt:d.string().datetime()}),c=d.union([l.extend({userId:d.string().min(5),workspaceId:d.string().uuid().nullable()}),l.strict()]),I={createId:t,now:()=>new Date};export const getTelemetryStatePath=()=>process.env.PHOENIX_TELEMETRY_FILE??o(s(),".phoenix","telemetry.json");let u=async(t,n)=>{await i(r(t),{recursive:!0,mode:448}),await a(t,`${JSON.stringify(n,null,2)}
|
|
2
2
|
`,{mode:384}),await e(t,384)},w=async t=>{let e;try{e=await n(t,"utf8")}catch(t){return t instanceof Error&&"code"in t&&"ENOENT"===t.code?{kind:"missing"}:{kind:"invalid"}}try{let t=c.safeParse(JSON.parse(e));return t.success?{kind:"valid",state:t.data}:{kind:"invalid"}}catch{return{kind:"invalid"}}};export const loadTelemetryIdentity=async(t=I)=>{let e=getTelemetryStatePath(),i=await w(e),n="valid"===i.kind?i.state:null,a=t.now(),s=null===n?null:Date.parse(n.lastActiveAt),r=null===s||a.getTime()-s>=18e5,o=null===n?{installationId:t.createId(),workSessionId:t.createId(),lastActiveAt:a.toISOString()}:{...n,workSessionId:r?t.createId():n.workSessionId,lastActiveAt:a.toISOString()};try{"invalid"!==i.kind&&await u(e,o)}catch{return{installationId:o.installationId,workSessionId:o.workSessionId}}return{installationId:o.installationId,workSessionId:o.workSessionId,..."userId"in o&&"workspaceId"in o?{userId:o.userId,workspaceId:o.workspaceId}:{}}};export const saveTelemetryAssociation=async(t,e)=>{let i=getTelemetryStatePath(),n=await w(i);"valid"===n.kind&&n.state.installationId===t.installationId&&n.state.workSessionId===t.workSessionId&&await u(i,{...n.state,...e})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{mkdir as e,readFile as t,realpath as i,rename as a,rm as r,writeFile as s}from"node:fs/promises";import{dirname as o,join as n,relative as l,resolve as p,sep as c}from"node:path";import h from"promise-queue";import{z as d}from"zod";import{RawProjectFiles as f,RuntimeReferenceStore as m,TextFile as w,buildPhoenixDefinitions as u,isTextFile as g,parseApplicationFiles as v}from"#package/application-spec";import{generateAssistantPrompt as y,getAllPhxDefinitions as b}from"#package/domain";import{readApplicationFiles as S}from"../application-spec/application-spec-file-reader.js";import{swcEvalExpressionParser as
|
|
1
|
+
import{mkdir as e,readFile as t,realpath as i,rename as a,rm as r,writeFile as s}from"node:fs/promises";import{dirname as o,join as n,relative as l,resolve as p,sep as c}from"node:path";import h from"promise-queue";import{z as d}from"zod";import{RawProjectFiles as f,RuntimeReferenceStore as m,TextFile as w,buildPhoenixDefinitions as u,isTextFile as g,parseApplicationFiles as v}from"#package/application-spec";import{generateAssistantPrompt as y,getAllPhxDefinitions as b}from"#package/domain";import{readApplicationFiles as S}from"../application-spec/application-spec-file-reader.js";import{swcEvalExpressionParser as k,swcModuleAnalyzer as F}from"../application-spec/swc-module-analyzer.js";let N=".phoenix/variant-recovery.json",M=d.array(d.object({fileName:d.string(),original:d.string().nullable(),applied:d.string().nullable(),previous:d.string().nullable().optional()})),j=e=>!e.includes("\\")&&!e.split("/").some(e=>".."===e||"."===e||""===e)&&(/^spec\/(?!admin\/).+\.yaml$/.test(e)||/^src\/(?:components|transformers|handlers|elements|_[^/]+)\/.+\.tsx?$/.test(e)),E=e=>`Left ${e} as it is: it was edited outside the variant comparison, so restoring the baseline would overwrite that edit. Review the file and remove what the option added to it`,$=async e=>{try{return await t(e,"utf8")}catch(e){if(e instanceof Error&&"code"in e&&"ENOENT"===e.code)return null;throw e}},C=async(t,i)=>{if(null===i)return void await r(t,{force:!0});await e(o(t),{recursive:!0});let n=`${t}.variant-${crypto.randomUUID()}`;try{await s(n,i),await a(n,t)}finally{await r(n,{force:!0})}},R=(e,t)=>{let i=v({rawProjectFiles:e,phxDefinitions:u(b())},{analyzer:F,evalExpressionParser:k,referenceStore:new m,logger:t});if(!i.ok)throw Error(`Cannot apply variant: ${i.errors.map(e=>`[${e.code}] ${e.message}`).join("\n")}`);let{configurator:a,admin:r,appMetadata:s,infra:o,dataSpec:n}=i.value.applicationSpec,l=i.value.categorizedFiles,p=new Set([...l.webhooks,...l.expressions,...l.actions,...l.invariants,...l.migrations,...l.adminMigrations,...l.adminExpressions,...l.adminInvariants,...l.handlers.filter(e=>"pinned"===e.webhookMembership||"named-handler"===e.webhookMembership||"webhook-only"===e.webhookMembership),...l.components.filter(e=>"pinned"===e.webhookMembership),...l.adminComponents.filter(e=>"pinned"===e.webhookMembership)].flatMap(e=>[e.file.name,...e.deps]));return JSON.stringify({webhookFiles:e.files.filter(g).filter(e=>p.has(e.name)).sort((e,t)=>e.name.localeCompare(t.name)),appMetadata:s,infra:o,dataSpec:n,model:a.latestModel,schema:a.configurationSchema,dataSchemas:a.dataSchemas,adminModel:r.latestModel,adminSchema:r.configurationSchema,assistant:a.assistant?.sdl,assistantInstructions:a.assistant?.instructions,assistantSettings:a.assistantServerSettings,assistantPrompt:a.assistant?y(a.assistant,{surface:"panel",voice:a.assistantServerSettings?.ai.voice===!0}):null},(e,t)=>t instanceof Map?[...t.entries()]:t)};export class VariantFileSession{props;queue=new h(1,1/0);applied=new Map;baseline=new Map;contract;settled=!1;constructor(e){for(let t of(this.props=e,e.rawFiles.files))g(t)&&j(t.name)&&this.baseline.set(t.name,t.content);this.contract=R(e.rawFiles,e.logger)}static async create(e){await VariantFileSession.recover(e.projectRoot,e.logger);let t=await S({projectRoot:e.projectRoot,envs:{}});return new VariantFileSession({...e,rawFiles:t})}static async recover(e,t){let i=await $(n(e,N));if(null!==i){for(let a of M.parse(JSON.parse(i))){let i=await VariantFileSession.resolveFile(e,a.fileName),r=await $(i);if(r!==a.applied&&r!==a.original&&r!==a.previous){t.warn(E(a.fileName));continue}await C(i,a.original)}await r(n(e,N),{force:!0})}}static async resolveFile(e,t){if(!j(t))throw Error(`Cannot override ${t}: variants support frontend spec and TypeScript files only. Keep server code, dependencies, environment files and assets unchanged`);let a=await i(e),r=p(a,t),s=r;for(;;)try{let e=await i(s),r=l(a,e);if(".."===r||r.startsWith(`..${c}`))throw Error(`Cannot override ${t}: its symbolic link leaves the project`);if(e!==s)throw Error(`Cannot override ${t}: it uses a symbolic link. Variant edits require regular files so restoration preserves the original file`);break}catch(e){if(!(e instanceof Error&&"code"in e&&"ENOENT"===e.code))throw e;s=o(s)}return r}getFiles(){return[...this.baseline].map(([e,t])=>({fileName:e,content:t}))}apply(e){return this.queue.add(async()=>{if(this.settled)throw Error("This variant comparison has already ended");let t=new Map;for(let i of e){if(await VariantFileSession.resolveFile(this.props.projectRoot,i.fileName),t.has(i.fileName))throw Error(`Cannot apply variant: ${i.fileName} is specified twice`);t.set(i.fileName,i.content)}if(t.size>0){let e=this.props.rawFiles.files.filter(e=>!t.has(e.name));for(let[i,a]of t)null!==a&&e.push(w(i,a));if(R(f(e),this.props.logger)!==this.contract)throw Error("Cannot apply variant: it changes the model, schemas, data or deployment settings. Variants must need no server preparation")}await this.writeTarget(t,"refuse")})}finish(e){return this.queue.add(async()=>{this.settled||(e||await this.writeTarget(new Map,"keep"),await r(n(this.props.projectRoot,N),{force:!0}),this.settled=!0)})}async writeTarget(t,i){let a=new Set([...this.applied.keys(),...t.keys()]);if(0===a.size)return;let r=new Map;for(let e of a){let t=await VariantFileSession.resolveFile(this.props.projectRoot,e),a=this.applied.has(e)?this.applied.get(e):this.baseline.get(e)??null;if(await $(t)===a){r.set(e,t);continue}if("refuse"===i)throw Error(`Cannot switch variant: ${e} was edited outside the preview, and switching would overwrite that edit. Choose the option that is shown, or close the comparison with \`phoenix variants --close\`, which keeps the edit`);this.props.logger.warn(E(e))}let s=[...r.keys()].map(e=>({fileName:e,original:this.baseline.get(e)??null,previous:this.applied.has(e)?this.applied.get(e)??null:this.baseline.get(e)??null,applied:t.has(e)?t.get(e)??null:this.baseline.get(e)??null}));await e(n(this.props.projectRoot,".phoenix"),{recursive:!0}),await C(n(this.props.projectRoot,N),JSON.stringify(s));let o=new Map(this.applied);try{for(let e of s){let t=r.get(e.fileName);void 0!==t&&await C(t,e.applied)}}catch(e){for(let[e,t]of r)await C(t,o.has(e)?o.get(e)??null:this.baseline.get(e)??null);throw await C(n(this.props.projectRoot,N),JSON.stringify([...o].map(([e,t])=>({fileName:e,original:this.baseline.get(e)??null,applied:t})))),e}for(let[e,i]of(this.applied.clear(),t))this.applied.set(e,i);this.props.onFilesChanged(s.map(e=>({fileName:e.fileName,content:e.applied})))}}
|
|
@@ -8,8 +8,9 @@ export declare const setViteLogSink: (sink: ViteLogSink, options?: ViteLogSinkOp
|
|
|
8
8
|
/**
|
|
9
9
|
* Get the inline Vite configuration for Phoenix projects
|
|
10
10
|
*/
|
|
11
|
-
export declare const getViteDevConfig: (options
|
|
11
|
+
export declare const getViteDevConfig: (options: {
|
|
12
12
|
readonly templateFiles?: readonly string[];
|
|
13
|
+
readonly agentMode: boolean;
|
|
13
14
|
}) => Promise<InlineConfig>;
|
|
14
15
|
/**
|
|
15
16
|
* Get the inline Vite configuration for Phoenix projects
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getConfig as e}from"@lingui/conf";import{lingui as i}from"@lingui/vite-plugin";import t from"@vitejs/plugin-react";import{mkdir as
|
|
1
|
+
import{getConfig as e}from"@lingui/conf";import{lingui as i}from"@lingui/vite-plugin";import t from"@vitejs/plugin-react";import{mkdir as r,readFile as n,writeFile as o}from"fs/promises";import a from"lodash-es/camelCase.js";import{createHash as l}from"node:crypto";import{readFileSync as s,rmSync as m,writeFileSync as g}from"node:fs";import{createRequire as f}from"node:module";import{dirname as p,resolve as d}from"path";import{createLogger as c}from"vite";import u from"vite-plugin-css-injected-by-js";import{LINGUI_CONFIG_PATH as h}from"../lingui/index.js";import{isUsingLocalSdk as O}from"../utils/package-info.js";import{loadFrontendConfigModule as E}from"./frontend-config.js";import{phxBannerPlugin as y}from"./phx-banner-plugin.js";import{phxCspNoncePlugin as _}from"./phx-csp-nonce-plugin.js";import{phxGlobalIsolationPlugin as b}from"./phx-global-isolation-plugin.js";import{phxLicensesPlugin as P}from"./phx-licenses-plugin.js";import{phxVariantPreviewsPlugin as S}from"./phx-variant-previews-plugin.js";let D=null;export const setViteLogSink=(e,i={})=>{D={sink:e,echo:i.echo??!1}};let x=["react","react-dom","three","@react-three/fiber","@react-three/drei","@react-three/postprocessing","its-fine","@emotion/react","@emotion/styled","@mui/material","@mui/system","@tanstack/react-query","rxjs"],T=()=>{let t=s(h),r=l("sha256").update(t).digest("hex"),n=d(`${h}.${process.pid}.${r}.json`);try{return g(n,t),{macroPlugin:[f(import.meta.url).resolve("@lingui/babel-plugin-lingui-macro"),{linguiConfig:e({configPath:n})}],catalogPlugin:i({configPath:n})}}finally{m(n,{force:!0})}},R=e=>{let i=e.DEPLOYMENT_ID;if("string"!=typeof i)throw Error("DEPLOYMENT_ID is required in runtime config");return i};export const getViteDevConfig=async e=>{var i,r;let n,o,a=O(),l=E(),s=l.readRuntimeConfig(),m=l.frontendBuildConfig,g=T(),u=Object.fromEntries((e.templateFiles??[]).map(e=>[e,`.phoenix/${e}`]));return{...D&&{customLogger:(i=D.sink,r=D.echo,n=c(),{get hasWarned(){return n.hasWarned},info:(e,t)=>{i("info",e),r&&n.info(e,t)},warn:(e,t)=>{i("warn",e),r&&n.warn(e,t)},warnOnce:(e,t)=>{i("warn",e),r&&n.warnOnce(e,t)},error:(e,t)=>{i("error",e),r&&n.error(e,t)},clearScreen:e=>{r&&n.clearScreen(e)},hasErrorLogged:e=>n.hasErrorLogged(e)}),...D.echo?{}:{clearScreen:!1}},mode:"development",optimizeDeps:{exclude:["@swc/wasm-web"],...a&&{entries:["index.html","admin.html",...e.templateFiles??[]],force:!0}},...a&&{resolve:{alias:(o=f(d(process.cwd(),"package.json")),x.flatMap(e=>{try{let i=p(o.resolve(`${e}/package.json`));return[{find:RegExp(`^${e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}(/|$)`),replacement:`${i}$1`}]}catch{return[]}}))}},plugins:[t({babel:{plugins:[g.macroPlugin]}}),g.catalogPlugin,{name:"vite:runtime-config",apply:(e,i)=>"build"===i.command||"development"===i.mode,config:e=>{let i=l.readRuntimeConfig(),t=l.frontendBuildConfig;return{...e,define:{...e.define,"phx.frontendEnv":JSON.stringify(i),"globalThis.PHX_SCHEMA_VALIDATOR":JSON.stringify(t.jsonSchemaValidator),"globalThis.PHX_GLTF_DECODER":JSON.stringify(t.gltfDecoder),"globalThis.PHX_GLTF_DECODER_WORKER_LIMIT":JSON.stringify(t.gltfDecoderWorkerLimit),"globalThis.PHX_EXPORT_PIXEL_RATIO":JSON.stringify(t.exportPixelRatio??null)}}}},b({getDeploymentId:()=>R(l.readRuntimeConfig())}),S()],define:{"process.env":{},"import.meta.env.DEV":!0,"import.meta.env.PROD":!1,"phx.frontendEnv":JSON.stringify(s),"globalThis.PHX_SCHEMA_VALIDATOR":JSON.stringify(m.jsonSchemaValidator),"globalThis.PHX_GLTF_DECODER":JSON.stringify(m.gltfDecoder),"globalThis.PHX_GLTF_DECODER_WORKER_LIMIT":JSON.stringify(m.gltfDecoderWorkerLimit),"globalThis.PHX_EXPORT_PIXEL_RATIO":JSON.stringify(m.exportPixelRatio??null)},build:{rollupOptions:{input:{index:".phoenix/index.html",admin:".phoenix/admin.html",...u}}},root:d(process.cwd(),"./.phoenix"),server:{watch:{ignored:["./**/*.{ts,tsx}","./.swc/**","../spec/**","../src/**"]},hmr:{overlay:!e.agentMode}}}};export const getViteBuildConfigs=async e=>{let i=E(),l=i.readRuntimeConfig(),s=i.frontendBuildConfig,m=T(),g=P(),f=y({sdkVersion:e.sdkVersion,banner:e.banner}),c=[{name:"salsita-configurator",entryFile:"./configurator.ts",mainScriptPath:"./configurator.ts",htmlFiles:["./index.html",...{templateFiles:e.templateFiles}.templateFiles],main:!0,format:"iife"},{name:"salsita-admin",entryFile:"./admin.ts",mainScriptPath:"./admin.ts",htmlFiles:["./admin.html"],main:!1,format:"iife"},{name:"salsita-embedded-admin",entryFile:"./embedded-admin.ts",mainScriptPath:"./embedded-admin.ts",htmlFiles:[],main:!1,format:"es"},{name:"salsita-embedded-configurator",entryFile:"./embedded-configurator.ts",mainScriptPath:"./embedded-configurator.ts",htmlFiles:[],main:!1,format:"es"}].map(c=>({plugins:[t({babel:{plugins:[m.macroPlugin]}}),m.catalogPlugin,u({useStrictCSP:!0}),_(),b({getDeploymentId:()=>R(i.readRuntimeConfig())}),{name:"vite:lib-index",writeBundle:async()=>{if(!c.htmlFiles.length)return;let i="iife"===c.format?`${c.name}.iife.js`:`${c.name}.js`;for(let t of c.htmlFiles){if(c.main&&e.enableEditor&&"./index.html"===t)continue;let a=d("./.phoenix",t),l=d("./.phoenix/dist/frontend",t);await r(p(l),{recursive:!0});let s=(await n(a,"utf-8")).replace(c.mainScriptPath,i);await o(l,s,"utf-8")}}},g,f],build:{outDir:"./dist/frontend",chunkSizeWarningLimit:4e3,lib:{entry:c.entryFile,name:a(c.name),formats:[c.format],fileName:()=>"iife"===c.format?`${c.name}.iife.js`:`${c.name}.js`},rollupOptions:{external:[],output:{assetFileNames:`${c.name}.[ext]`}},minify:!0,emptyOutDir:!1},root:d(process.cwd(),"./.phoenix"),define:{"process.env":{},"process.env.NODE_ENV":JSON.stringify("production"),"phx.frontendEnv":JSON.stringify(l),"globalThis.PHX_SCHEMA_VALIDATOR":JSON.stringify(s.jsonSchemaValidator),"globalThis.PHX_GLTF_DECODER":JSON.stringify(s.gltfDecoder),"globalThis.PHX_GLTF_DECODER_WORKER_LIMIT":JSON.stringify(s.gltfDecoderWorkerLimit),"globalThis.PHX_EXPORT_PIXEL_RATIO":JSON.stringify(s.exportPixelRatio??null)}}));return e.enableEditor?[...c,{plugins:[t({babel:{plugins:[m.macroPlugin]}}),m.catalogPlugin,u({useStrictCSP:!0}),_(),g,f],build:{outDir:"./dist/frontend",chunkSizeWarningLimit:4e3,rollupOptions:{external:[]},minify:!0,emptyOutDir:!1},root:d(process.cwd(),"./.phoenix"),define:{"process.env":{},"process.env.NODE_ENV":JSON.stringify("production"),"phx.frontendEnv":JSON.stringify(l),"globalThis.PHX_SCHEMA_VALIDATOR":JSON.stringify(s.jsonSchemaValidator),"globalThis.PHX_GLTF_DECODER":JSON.stringify(s.gltfDecoder),"globalThis.PHX_GLTF_DECODER_WORKER_LIMIT":JSON.stringify(s.gltfDecoderWorkerLimit),"globalThis.PHX_EXPORT_PIXEL_RATIO":JSON.stringify(s.exportPixelRatio??null)}}]:c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{UnsupportedApiVersionError as e,createCliApiClient as t}from"#package/client";import{getDevelopmentHeaders as s}from"../development-credential.js";let a=(e,t)=>({ok:!1,status:t.status,message:e.message}),n=async t=>{try{return await t()}catch(t){if(t instanceof e)return{ok:!1,status:t.status,message:t.message};throw t}};export const createWebhookTunnelTransport=({serverUrl:e,credential:o,projectSlug:r,environmentSlug:l})=>{let d=t(e),u=s(o,{projectSlug:r,environmentSlug:l});return{poll:({deploymentId:e,sessionId:t,signal:s})=>n(async()=>{let{data:n,error:o,response:r}=await d.POST("/deployments/{deploymentId}/webhook-tunnel/poll",{params:{path:{deploymentId:e}},body:{sessionId:t,acceptResponseEncoding:"gzip"},headers:u,signal:s});return o?a(o,r):{ok:!0,value:n?.request??null}}),respond:async({deploymentId:e,sessionId:t,requestId:s,status:o,headers:r,body:l,isBase64Encoded:p,signal:c})=>{let i={sessionId:t,requestId:s,status:o,headers:r,body:l,isBase64Encoded:p};return Buffer.byteLength(JSON.stringify(i),"utf8")>5242880?{ok:!1,status:413,message:"Webhook tunnel response exceeds the 5 MiB encoded request limit. Reduce the backend data and retry."}:n(async()=>{let{error:t,response:s}=await d.POST("/deployments/{deploymentId}/webhook-tunnel/respond",{params:{path:{deploymentId:e}},body:i,headers:u,signal:c});return t?a(t,s):{ok:!0,value:void 0}})}}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export*from"./selectors.js";export*from"./datadog-logger.js";export*from"./resource-url-service.js";export*from"./analytics/index.js";
|
|
1
|
+
export*from"./selectors.js";export*from"./datadog-logger.js";export*from"./resource-url-service.js";export*from"./analytics/index.js";export*from"./webmcp/index.js";
|
|
@@ -35,6 +35,8 @@ export declare const createCommonServicesSelectors: (context: Context) => {
|
|
|
35
35
|
getQueryClient: () => import("@tanstack/react-query").QueryClient;
|
|
36
36
|
getWebComponentOptions: () => WebComponentOptions;
|
|
37
37
|
getWebComponentApi: () => WebComponentApi;
|
|
38
|
+
/** @internal SDK plumbing for the configurator's WebMCP tools; not part of a project's API. */
|
|
39
|
+
getWebMcpHost: () => import("./index.js").WebMcpHost;
|
|
38
40
|
getSessionService: () => SessionService<Record<string, unknown>>;
|
|
39
41
|
selectRequestSessionToken: import("@salsita-ai/common/utils").Selector<CommonServicesSelectorState, (minValiditySeconds?: number) => Promise<string>>;
|
|
40
42
|
selectRequestAdminSessionToken: import("@salsita-ai/common/utils").Selector<CommonServicesSelectorState, (minValiditySeconds?: number) => Promise<string>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{match as e}from"ts-pattern";import{createSelector as t}from"@salsita-ai/common/utils";import{AuthenticatedClient as r,AuthorizedClient as s,LocalStorageAuthenticatedClientPhoenixApiClient as i,LocalStorageAuthorizedPhoenixApiClient as o,LocalStorageUnauthenticatedPhoenixApiClient as n,MemoryAuthenticatedClientPhoenixApiClient as c,MemoryAuthorizedPhoenixApiClient as l,UnauthenticatedClient as g}from"#package/client";import{createQueryClient as
|
|
1
|
+
import{match as e}from"ts-pattern";import{createSelector as t}from"@salsita-ai/common/utils";import{AuthenticatedClient as r,AuthorizedClient as s,LocalStorageAuthenticatedClientPhoenixApiClient as i,LocalStorageAuthorizedPhoenixApiClient as o,LocalStorageUnauthenticatedPhoenixApiClient as n,MemoryAuthenticatedClientPhoenixApiClient as c,MemoryAuthorizedPhoenixApiClient as l,UnauthenticatedClient as g}from"#package/client";import{createQueryClient as m}from"./initialize.js";import{ResourceUrlService as u}from"./resource-url-service.js";import{createWebMcpHost as a}from"./webmcp/index.js";let p=t=>{let{persistenceConfig:r,requestAccessToken:i,modelVersion:n,requestSessionToken:c,refreshSession:g}=t;return e(r).with({type:"server"},e=>new s(e.serverUrl,i,c,g)).with({type:"local-storage"},()=>new o(n)).with({type:"memory"},()=>new l(n)).exhaustive()},C=t=>{let{persistenceConfig:s,modelVersion:o,requestSessionToken:n,refreshSession:l}=t;return e(s).with({type:"server"},e=>new r(e.serverUrl,n,l)).with({type:"local-storage"},()=>new i(o)).with({type:"memory"},()=>new c(o)).exhaustive()};export const createCommonServicesSelectors=r=>{let{getState:s,environmentSelectors:i,specSelectors:o,accessSelectors:c,domainServicesSelectors:l,webComponentOptions:d,webComponentApi:w,getSessionService:f,routingSelectors:A}=r,h=m(l.getLogger()),y=a(),v=t.withTypes(),S=v([],()=>f().requestSessionToken),k=()=>f().refreshSession(),T=v([],()=>f().requestAdminSessionToken),q=v([o.selectBaseResourcesUrl,i.selectDeploymentId,o.selectDeploymentQueryDisabled],(e,t,r)=>new u({baseResourcesUrl:e,deploymentId:t,deploymentQueryDisabled:r})),M=v([c.selectConfiguratorAccessService,i.selectPersistenceConfig,o.selectConfiguratorModelVersion,S],(e,t,r,s)=>{let{configurationId:i,accessInfo:o}=e;return p({persistenceConfig:t,requestAccessToken:()=>A.getRoutingService().requestAccessToken(i,o.raw),modelVersion:r,requestSessionToken:s,refreshSession:k})}),P=v([c.selectAdminAccessService,i.selectPersistenceConfig,o.selectAdminModelVersion,T],(e,t,r,s)=>p({persistenceConfig:t,requestAccessToken:()=>e.accessInfo.raw,modelVersion:r,requestSessionToken:s,refreshSession:k})),U=v([i.selectPersistenceConfig,o.selectConfiguratorModelVersion,S],(e,t,r)=>C({persistenceConfig:e,modelVersion:t,requestSessionToken:r,refreshSession:k})),V=v([i.selectPersistenceConfig,o.selectAdminModelVersion,T],(e,t,r)=>C({persistenceConfig:e,modelVersion:t,requestSessionToken:r,refreshSession:k})),b=v([i.selectPersistenceConfig,o.selectConfiguratorModelVersion,S],(e,t,r)=>s=>p({persistenceConfig:e,requestAccessToken:()=>s,modelVersion:t,requestSessionToken:r,refreshSession:k})),x=v([i.selectPersistenceConfig,o.selectAdminModelVersion,T],(e,t,r)=>s=>p({persistenceConfig:e,requestAccessToken:()=>s,modelVersion:t,requestSessionToken:r,refreshSession:k})),z=v([i.selectPersistenceConfig,i.selectDeploymentId],(t,r)=>e(t).with({type:"server"},e=>new g(e.serverUrl,l.getLogger())).with({type:"local-storage"},()=>new n(r)).with({type:"memory"},()=>new n(r)).exhaustive());return{getQueryClient:()=>h,getWebComponentOptions:()=>d,getWebComponentApi:()=>w,getWebMcpHost:()=>y,getSessionService:f,selectRequestSessionToken:S,selectRequestAdminSessionToken:T,selectResourceUrlService:q,selectConfiguratorAuthorizedClient:M,selectAdminAuthorizedClient:P,selectConfiguratorAuthenticatedClient:U,selectAdminAuthenticatedClient:V,selectCreateConfiguratorAuthorizedClient:b,selectCreateAdminAuthorizedClient:x,selectUnauthenticatedClient:z,getResourceUrlService:()=>q(s()),getConfiguratorAuthorizedClient:()=>M(s()),getAdminAuthorizedClient:()=>P(s()),getConfiguratorAuthenticatedClient:()=>U(s()),getAdminAuthenticatedClient:()=>V(s()),getCreateConfiguratorAuthorizedClient:()=>b(s()),getCreateAdminAuthorizedClient:()=>x(s()),getUnauthenticatedClient:()=>z(s())}};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { type WebMcpHost, type WebMcpLoad, createWebMcpHost } from './webmcp-host.js';
|
|
2
|
+
export { type WebMcpModelContext, type WebMcpTool, type WebMcpToolAnnotations } from './webmcp-model-context.js';
|
|
3
|
+
export { type WebMcpContent, type WebMcpToolResult } from './webmcp-tool-result.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{createWebMcpHost}from"./webmcp-host.js";
|