veryfront 0.1.1237 → 0.1.1239
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/esm/cli/auth/login.d.ts +24 -2
- package/esm/cli/auth/login.d.ts.map +1 -1
- package/esm/cli/auth/login.js +444 -35
- package/esm/cli/commands/build/error-handler.d.ts.map +1 -1
- package/esm/cli/commands/build/error-handler.js +41 -3
- package/esm/cli/commands/build/handler.d.ts.map +1 -1
- package/esm/cli/commands/build/handler.js +1 -1
- package/esm/cli/commands/dev/command.d.ts.map +1 -1
- package/esm/cli/commands/dev/command.js +14 -1
- package/esm/cli/commands/dev/inference-status.d.ts +6 -0
- package/esm/cli/commands/dev/inference-status.d.ts.map +1 -1
- package/esm/cli/commands/dev/inference-status.js +14 -2
- package/esm/cli/commands/generate/command.d.ts.map +1 -1
- package/esm/cli/commands/generate/command.js +61 -0
- package/esm/cli/commands/init/init-command.d.ts.map +1 -1
- package/esm/cli/commands/init/init-command.js +23 -31
- package/esm/cli/commands/install/registry.d.ts.map +1 -1
- package/esm/cli/commands/install/registry.js +6 -9
- package/esm/cli/commands/login/command-help.d.ts.map +1 -1
- package/esm/cli/commands/login/command-help.js +3 -1
- package/esm/cli/commands/pull/command.d.ts +1 -0
- package/esm/cli/commands/pull/command.d.ts.map +1 -1
- package/esm/cli/commands/pull/command.js +49 -6
- package/esm/cli/commands/push/command-help.d.ts.map +1 -1
- package/esm/cli/commands/push/command-help.js +7 -0
- package/esm/cli/commands/push/command.d.ts +23 -12
- package/esm/cli/commands/push/command.d.ts.map +1 -1
- package/esm/cli/commands/push/command.js +461 -44
- package/esm/cli/commands/push/plan.d.ts +35 -0
- package/esm/cli/commands/push/plan.d.ts.map +1 -0
- package/esm/cli/commands/push/plan.js +96 -0
- package/esm/cli/commands/schedule/handler.d.ts +21 -2
- package/esm/cli/commands/schedule/handler.d.ts.map +1 -1
- package/esm/cli/commands/schedule/handler.js +74 -27
- package/esm/cli/commands/schema/command-help.js +1 -1
- package/esm/cli/commands/up/command.js +1 -1
- package/esm/cli/commands/webhook/handler.d.ts.map +1 -1
- package/esm/cli/commands/webhook/handler.js +3 -1
- package/esm/cli/router.d.ts.map +1 -1
- package/esm/cli/router.js +27 -5
- package/esm/cli/shared/args.d.ts +15 -1
- package/esm/cli/shared/args.d.ts.map +1 -1
- package/esm/cli/shared/args.js +56 -3
- package/esm/cli/shared/config.d.ts +11 -2
- package/esm/cli/shared/config.d.ts.map +1 -1
- package/esm/cli/shared/config.js +72 -27
- package/esm/cli/shared/project-creation.js +1 -1
- package/esm/cli/sync/state.d.ts +20 -0
- package/esm/cli/sync/state.d.ts.map +1 -0
- package/esm/cli/sync/state.js +193 -0
- package/esm/deno.js +2 -2
- package/esm/extensions/ext-llm-anthropic/src/anthropic-request-builder.d.ts.map +1 -1
- package/esm/extensions/ext-llm-anthropic/src/anthropic-request-builder.js +852 -21
- package/esm/extensions/ext-observability-sentry/src/policy.d.ts +2 -0
- package/esm/extensions/ext-observability-sentry/src/policy.d.ts.map +1 -1
- package/esm/extensions/ext-observability-sentry/src/policy.js +214 -3
- package/esm/src/agent/conversation/delegation-policy.d.ts +2 -0
- package/esm/src/agent/conversation/delegation-policy.d.ts.map +1 -1
- package/esm/src/agent/conversation/delegation-policy.js +13 -3
- package/esm/src/agent/conversation/hosted-terminal.d.ts.map +1 -1
- package/esm/src/agent/conversation/hosted-terminal.js +6 -2
- package/esm/src/agent/conversation/run-chunk-mirror.d.ts.map +1 -1
- package/esm/src/agent/conversation/run-chunk-mirror.js +14 -2
- package/esm/src/agent/factory.d.ts.map +1 -1
- package/esm/src/agent/factory.js +22 -11
- package/esm/src/agent/hosted/chat-runtime-tool-assembly.d.ts +2 -0
- package/esm/src/agent/hosted/chat-runtime-tool-assembly.d.ts.map +1 -1
- package/esm/src/agent/hosted/chat-runtime-tool-assembly.js +6 -1
- package/esm/src/agent/hosted/child-fork-execution-runner.d.ts +2 -1
- package/esm/src/agent/hosted/child-fork-execution-runner.d.ts.map +1 -1
- package/esm/src/agent/hosted/child-fork-execution-runner.js +6 -3
- package/esm/src/agent/hosted/child-fork-step-message-preparation.d.ts +12 -3
- package/esm/src/agent/hosted/child-fork-step-message-preparation.d.ts.map +1 -1
- package/esm/src/agent/hosted/child-fork-step-message-preparation.js +16 -3
- package/esm/src/agent/hosted/cloud-agent-chat-execution.d.ts +1 -1
- package/esm/src/agent/hosted/cloud-agent-chat-execution.d.ts.map +1 -1
- package/esm/src/agent/hosted/cloud-agent-chat-execution.js +3 -3
- package/esm/src/agent/hosted/cloud-agent-child-tools.d.ts +11 -0
- package/esm/src/agent/hosted/cloud-agent-child-tools.d.ts.map +1 -1
- package/esm/src/agent/hosted/cloud-agent-child-tools.js +2 -3
- package/esm/src/agent/hosted/cloud-agent-config.d.ts +1 -0
- package/esm/src/agent/hosted/cloud-agent-config.d.ts.map +1 -1
- package/esm/src/agent/hosted/cloud-runtime-system-messages.d.ts +16 -1
- package/esm/src/agent/hosted/cloud-runtime-system-messages.d.ts.map +1 -1
- package/esm/src/agent/hosted/cloud-runtime-system-messages.js +13 -3
- package/esm/src/agent/hosted/default-chat-runtime.d.ts +2 -1
- package/esm/src/agent/hosted/default-chat-runtime.d.ts.map +1 -1
- package/esm/src/agent/hosted/default-chat-runtime.js +18 -7
- package/esm/src/agent/hosted/default-invoke-agent-tool.d.ts +2 -1
- package/esm/src/agent/hosted/default-invoke-agent-tool.d.ts.map +1 -1
- package/esm/src/agent/hosted/default-invoke-agent-tool.js +11 -3
- package/esm/src/agent/hosted/default-project-steering-refresh.d.ts +2 -1
- package/esm/src/agent/hosted/default-project-steering-refresh.d.ts.map +1 -1
- package/esm/src/agent/hosted/default-project-steering-refresh.js +4 -1
- package/esm/src/agent/hosted/runtime-state-resolver.d.ts +6 -4
- package/esm/src/agent/hosted/runtime-state-resolver.d.ts.map +1 -1
- package/esm/src/agent/hosted/runtime-state-resolver.js +8 -11
- package/esm/src/agent/index.d.ts +3 -3
- package/esm/src/agent/index.d.ts.map +1 -1
- package/esm/src/agent/project/agent-runtime.d.ts.map +1 -1
- package/esm/src/agent/project/agent-runtime.js +6 -3
- package/esm/src/agent/runtime/agent-definition.d.ts +68 -66
- package/esm/src/agent/runtime/agent-definition.d.ts.map +1 -1
- package/esm/src/agent/runtime/agent-definition.js +15 -2
- package/esm/src/agent/runtime/agent-invocation-contract.d.ts +2 -0
- package/esm/src/agent/runtime/agent-invocation-contract.d.ts.map +1 -1
- package/esm/src/agent/runtime/agent-markdown-adapter.js +1 -1
- package/esm/src/agent/runtime/agent-runtime-step.d.ts +11 -5
- package/esm/src/agent/runtime/agent-runtime-step.d.ts.map +1 -1
- package/esm/src/agent/runtime/agent-runtime-step.js +23 -6
- package/esm/src/agent/runtime/call-context.d.ts +42 -11
- package/esm/src/agent/runtime/call-context.d.ts.map +1 -1
- package/esm/src/agent/runtime/call-context.js +480 -42
- package/esm/src/agent/runtime/chat-stream-handler.d.ts +18 -0
- package/esm/src/agent/runtime/chat-stream-handler.d.ts.map +1 -1
- package/esm/src/agent/runtime/chat-stream-handler.js +38 -18
- package/esm/src/agent/runtime/effective-agent-system.d.ts +13 -4
- package/esm/src/agent/runtime/effective-agent-system.d.ts.map +1 -1
- package/esm/src/agent/runtime/effective-agent-system.js +29 -0
- package/esm/src/agent/runtime/index.d.ts +1 -0
- package/esm/src/agent/runtime/index.d.ts.map +1 -1
- package/esm/src/agent/runtime/index.js +638 -53
- package/esm/src/agent/runtime/load-skill-tool.d.ts +33 -3
- package/esm/src/agent/runtime/load-skill-tool.d.ts.map +1 -1
- package/esm/src/agent/runtime/load-skill-tool.js +152 -21
- package/esm/src/agent/runtime/model-resolution.d.ts +3 -0
- package/esm/src/agent/runtime/model-resolution.d.ts.map +1 -1
- package/esm/src/agent/runtime/model-resolution.js +14 -0
- package/esm/src/agent/runtime/model-transport.d.ts +1 -0
- package/esm/src/agent/runtime/model-transport.d.ts.map +1 -1
- package/esm/src/agent/runtime/model-transport.js +5 -2
- package/esm/src/agent/runtime/run-runtime-context.d.ts +4 -0
- package/esm/src/agent/runtime/run-runtime-context.d.ts.map +1 -1
- package/esm/src/agent/runtime/run-runtime-context.js +9 -3
- package/esm/src/agent/runtime/runtime-tool-config.d.ts +1 -0
- package/esm/src/agent/runtime/runtime-tool-config.d.ts.map +1 -1
- package/esm/src/agent/runtime/skill-prompt.d.ts +3 -0
- package/esm/src/agent/runtime/skill-prompt.d.ts.map +1 -1
- package/esm/src/agent/runtime/skill-prompt.js +113 -25
- package/esm/src/agent/runtime/streamed-assistant-message.d.ts +22 -2
- package/esm/src/agent/runtime/streamed-assistant-message.d.ts.map +1 -1
- package/esm/src/agent/runtime/streamed-assistant-message.js +26 -5
- package/esm/src/agent/runtime/tool-inventory.d.ts.map +1 -1
- package/esm/src/agent/runtime/tool-inventory.js +13 -9
- package/esm/src/agent/runtime/tool-result-continuation.d.ts +4 -2
- package/esm/src/agent/runtime/tool-result-continuation.d.ts.map +1 -1
- package/esm/src/agent/runtime/tool-result-continuation.js +24 -20
- package/esm/src/agent/schemas/agent.schema.d.ts +2 -2
- package/esm/src/agent/service/runtime.js +1 -1
- package/esm/src/agent/streaming/fork-runtime-stream.d.ts +5 -4
- package/esm/src/agent/streaming/fork-runtime-stream.d.ts.map +1 -1
- package/esm/src/agent/types.d.ts +14 -1
- package/esm/src/agent/types.d.ts.map +1 -1
- package/esm/src/chat/chat-ui-message-helpers.d.ts.map +1 -1
- package/esm/src/chat/chat-ui-message-helpers.js +75 -16
- package/esm/src/config/loader.d.ts.map +1 -1
- package/esm/src/config/loader.js +37 -1
- package/esm/src/errors/catalog/build-errors.d.ts.map +1 -1
- package/esm/src/errors/catalog/build-errors.js +14 -0
- package/esm/src/errors/error-registry/build.d.ts +2 -0
- package/esm/src/errors/error-registry/build.d.ts.map +1 -1
- package/esm/src/errors/error-registry/build.js +8 -0
- package/esm/src/errors/error-registry/deploy.d.ts +4 -0
- package/esm/src/errors/error-registry/deploy.d.ts.map +1 -1
- package/esm/src/errors/error-registry/deploy.js +16 -0
- package/esm/src/errors/error-registry.d.ts +3 -0
- package/esm/src/errors/error-registry.d.ts.map +1 -1
- package/esm/src/errors/index.d.ts +2 -1
- package/esm/src/errors/index.d.ts.map +1 -1
- package/esm/src/errors/index.js +4 -3
- package/esm/src/errors/tenant-classification.d.ts +25 -0
- package/esm/src/errors/tenant-classification.d.ts.map +1 -0
- package/esm/src/errors/tenant-classification.js +61 -0
- package/esm/src/extensions/builtin-extensions.d.ts +10 -15
- package/esm/src/extensions/builtin-extensions.d.ts.map +1 -1
- package/esm/src/extensions/builtin-extensions.js +32 -26
- package/esm/src/extensions/deferred-extension.d.ts +4 -4
- package/esm/src/extensions/deferred-extension.js +4 -4
- package/esm/src/extensions/index.d.ts +1 -0
- package/esm/src/extensions/index.d.ts.map +1 -1
- package/esm/src/extensions/index.js +1 -0
- package/esm/src/html/hydration-script-builder/hydration-runtime.generated.js +1 -1
- package/esm/src/integrations/_data.d.ts.map +1 -1
- package/esm/src/integrations/_data.js +6 -0
- package/esm/src/integrations/schema.d.ts +8 -0
- package/esm/src/integrations/schema.d.ts.map +1 -1
- package/esm/src/integrations/schema.js +3 -0
- package/esm/src/integrations/types.d.ts +2 -0
- package/esm/src/integrations/types.d.ts.map +1 -1
- package/esm/src/internal-agents/run-stream.d.ts.map +1 -1
- package/esm/src/internal-agents/run-stream.js +35 -20
- package/esm/src/internal-agents/run-system-prompt.d.ts +7 -2
- package/esm/src/internal-agents/run-system-prompt.d.ts.map +1 -1
- package/esm/src/internal-agents/run-system-prompt.js +19 -13
- package/esm/src/internal-agents/schema.d.ts +2 -0
- package/esm/src/internal-agents/schema.d.ts.map +1 -1
- package/esm/src/modules/react-loader/ssr-module-loader/loader.d.ts.map +1 -1
- package/esm/src/modules/react-loader/ssr-module-loader/loader.js +2 -18
- package/esm/src/modules/react-loader/ssr-module-loader/ssr-dependency-validator.d.ts +11 -0
- package/esm/src/modules/react-loader/ssr-module-loader/ssr-dependency-validator.d.ts.map +1 -1
- package/esm/src/modules/react-loader/ssr-module-loader/ssr-dependency-validator.js +53 -6
- package/esm/src/observability/application-error-contract.d.ts +4 -0
- package/esm/src/observability/application-error-contract.d.ts.map +1 -1
- package/esm/src/observability/application-errors.d.ts.map +1 -1
- package/esm/src/observability/application-errors.js +64 -3
- package/esm/src/platform/adapters/runtime/deno/http-server.d.ts.map +1 -1
- package/esm/src/platform/adapters/runtime/deno/http-server.js +2 -10
- package/esm/src/platform/adapters/runtime/shared/request-peer.d.ts +14 -0
- package/esm/src/platform/adapters/runtime/shared/request-peer.d.ts.map +1 -1
- package/esm/src/platform/adapters/runtime/shared/request-peer.js +82 -0
- package/esm/src/platform/compat/http/pinned-fetch.d.ts +1 -1
- package/esm/src/provider/runtime-loader/provider-http.d.ts +5 -1
- package/esm/src/provider/runtime-loader/provider-http.d.ts.map +1 -1
- package/esm/src/provider/runtime-loader/provider-http.js +55 -17
- package/esm/src/provider/shared/index.d.ts +1 -0
- package/esm/src/provider/shared/index.d.ts.map +1 -1
- package/esm/src/provider/shared/index.js +2 -0
- package/esm/src/provider/types.d.ts +1 -0
- package/esm/src/provider/types.d.ts.map +1 -1
- package/esm/src/react/components/ui/adapter/builtin/combobox.d.ts +3 -0
- package/esm/src/react/components/ui/adapter/builtin/combobox.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/builtin/combobox.js +204 -0
- package/esm/src/react/components/ui/adapter/builtin/dialog.d.ts +3 -0
- package/esm/src/react/components/ui/adapter/builtin/dialog.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/builtin/dialog.js +20 -0
- package/esm/src/react/components/ui/adapter/builtin/drawer.d.ts +3 -0
- package/esm/src/react/components/ui/adapter/builtin/drawer.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/builtin/drawer.js +21 -0
- package/esm/src/react/components/ui/adapter/builtin/index.d.ts.map +1 -1
- package/esm/src/react/components/ui/adapter/builtin/index.js +10 -0
- package/esm/src/react/components/ui/adapter/builtin/popover.d.ts +3 -0
- package/esm/src/react/components/ui/adapter/builtin/popover.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/builtin/popover.js +28 -0
- package/esm/src/react/components/ui/adapter/builtin/tabs.d.ts +3 -0
- package/esm/src/react/components/ui/adapter/builtin/tabs.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/builtin/tabs.js +73 -0
- package/esm/src/react/components/ui/adapter/context.d.ts.map +1 -1
- package/esm/src/react/components/ui/adapter/context.js +10 -0
- package/esm/src/react/components/ui/adapter/contract.d.ts +212 -0
- package/esm/src/react/components/ui/adapter/contract.d.ts.map +1 -1
- package/esm/src/react/components/ui/adapter/token-scope.d.ts +24 -0
- package/esm/src/react/components/ui/adapter/token-scope.d.ts.map +1 -0
- package/esm/src/react/components/ui/adapter/token-scope.js +26 -0
- package/esm/src/react/components/ui/alert-dialog.d.ts +101 -0
- package/esm/src/react/components/ui/alert-dialog.d.ts.map +1 -0
- package/esm/src/react/components/ui/alert-dialog.js +181 -0
- package/esm/src/react/components/ui/aspect-ratio.d.ts +18 -0
- package/esm/src/react/components/ui/aspect-ratio.d.ts.map +1 -0
- package/esm/src/react/components/ui/aspect-ratio.js +13 -0
- package/esm/src/react/components/ui/autocomplete.d.ts +67 -0
- package/esm/src/react/components/ui/autocomplete.d.ts.map +1 -0
- package/esm/src/react/components/ui/autocomplete.js +59 -0
- package/esm/src/react/components/ui/breadcrumb.d.ts +86 -0
- package/esm/src/react/components/ui/breadcrumb.d.ts.map +1 -0
- package/esm/src/react/components/ui/breadcrumb.js +67 -0
- package/esm/src/react/components/ui/calendar.d.ts +40 -0
- package/esm/src/react/components/ui/calendar.d.ts.map +1 -0
- package/esm/src/react/components/ui/calendar.js +170 -0
- package/esm/src/react/components/ui/combobox.d.ts +74 -0
- package/esm/src/react/components/ui/combobox.d.ts.map +1 -0
- package/esm/src/react/components/ui/combobox.js +100 -0
- package/esm/src/react/components/ui/context-menu.d.ts +116 -0
- package/esm/src/react/components/ui/context-menu.d.ts.map +1 -0
- package/esm/src/react/components/ui/context-menu.js +168 -0
- package/esm/src/react/components/ui/date-picker.d.ts +69 -0
- package/esm/src/react/components/ui/date-picker.d.ts.map +1 -0
- package/esm/src/react/components/ui/date-picker.js +96 -0
- package/esm/src/react/components/ui/dialog.d.ts +41 -11
- package/esm/src/react/components/ui/dialog.d.ts.map +1 -1
- package/esm/src/react/components/ui/dialog.js +47 -28
- package/esm/src/react/components/ui/drawer.d.ts +31 -8
- package/esm/src/react/components/ui/drawer.d.ts.map +1 -1
- package/esm/src/react/components/ui/drawer.js +33 -22
- package/esm/src/react/components/ui/dropdown-menu.d.ts.map +1 -1
- package/esm/src/react/components/ui/dropdown-menu.js +7 -75
- package/esm/src/react/components/ui/field.d.ts +70 -0
- package/esm/src/react/components/ui/field.d.ts.map +1 -0
- package/esm/src/react/components/ui/field.js +161 -0
- package/esm/src/react/components/ui/file-type.d.ts +9 -8
- package/esm/src/react/components/ui/file-type.d.ts.map +1 -1
- package/esm/src/react/components/ui/file-type.js +8 -8
- package/esm/src/react/components/ui/hover-card.d.ts +82 -0
- package/esm/src/react/components/ui/hover-card.d.ts.map +1 -0
- package/esm/src/react/components/ui/hover-card.js +140 -0
- package/esm/src/react/components/ui/index.d.ts +23 -2
- package/esm/src/react/components/ui/index.d.ts.map +1 -1
- package/esm/src/react/components/ui/index.js +21 -0
- package/esm/src/react/components/ui/input-otp.d.ts +37 -0
- package/esm/src/react/components/ui/input-otp.d.ts.map +1 -0
- package/esm/src/react/components/ui/input-otp.js +42 -0
- package/esm/src/react/components/ui/menu-keyboard.d.ts +8 -0
- package/esm/src/react/components/ui/menu-keyboard.d.ts.map +1 -0
- package/esm/src/react/components/ui/menu-keyboard.js +76 -0
- package/esm/src/react/components/ui/menubar.d.ts +98 -0
- package/esm/src/react/components/ui/menubar.d.ts.map +1 -0
- package/esm/src/react/components/ui/menubar.js +173 -0
- package/esm/src/react/components/ui/meter.d.ts +45 -0
- package/esm/src/react/components/ui/meter.d.ts.map +1 -0
- package/esm/src/react/components/ui/meter.js +59 -0
- package/esm/src/react/components/ui/modal-surface.d.ts +7 -1
- package/esm/src/react/components/ui/modal-surface.d.ts.map +1 -1
- package/esm/src/react/components/ui/modal-surface.js +23 -6
- package/esm/src/react/components/ui/navigation-menu.d.ts +101 -0
- package/esm/src/react/components/ui/navigation-menu.d.ts.map +1 -0
- package/esm/src/react/components/ui/navigation-menu.js +195 -0
- package/esm/src/react/components/ui/number-field.d.ts +46 -0
- package/esm/src/react/components/ui/number-field.d.ts.map +1 -0
- package/esm/src/react/components/ui/number-field.js +121 -0
- package/esm/src/react/components/ui/pagination.d.ts +77 -0
- package/esm/src/react/components/ui/pagination.d.ts.map +1 -0
- package/esm/src/react/components/ui/pagination.js +62 -0
- package/esm/src/react/components/ui/popover.d.ts +42 -13
- package/esm/src/react/components/ui/popover.d.ts.map +1 -1
- package/esm/src/react/components/ui/popover.js +25 -12
- package/esm/src/react/components/ui/scroll-area.d.ts +38 -0
- package/esm/src/react/components/ui/scroll-area.d.ts.map +1 -0
- package/esm/src/react/components/ui/scroll-area.js +35 -0
- package/esm/src/react/components/ui/separator.d.ts +20 -0
- package/esm/src/react/components/ui/separator.d.ts.map +1 -0
- package/esm/src/react/components/ui/separator.js +13 -0
- package/esm/src/react/components/ui/slider.d.ts +44 -0
- package/esm/src/react/components/ui/slider.d.ts.map +1 -0
- package/esm/src/react/components/ui/slider.js +46 -0
- package/esm/src/react/components/ui/status.d.ts +6 -5
- package/esm/src/react/components/ui/status.d.ts.map +1 -1
- package/esm/src/react/components/ui/status.js +4 -4
- package/esm/src/react/components/ui/tabs.d.ts +32 -9
- package/esm/src/react/components/ui/tabs.d.ts.map +1 -1
- package/esm/src/react/components/ui/tabs.js +46 -22
- package/esm/src/react/components/ui/toggle.d.ts +26 -0
- package/esm/src/react/components/ui/toggle.d.ts.map +1 -0
- package/esm/src/react/components/ui/toggle.js +29 -0
- package/esm/src/react/components/ui/use-isomorphic-layout-effect.d.ts +2 -1
- package/esm/src/react/components/ui/use-isomorphic-layout-effect.d.ts.map +1 -1
- package/esm/src/react/components/ui/use-isomorphic-layout-effect.js +6 -3
- package/esm/src/rendering/chunk-optimizer/source-imports.d.ts.map +1 -1
- package/esm/src/rendering/chunk-optimizer/source-imports.js +4 -114
- package/esm/src/rendering/orchestrator/css-candidate-manifest.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/css-candidate-manifest.js +30 -1
- package/esm/src/rendering/orchestrator/module-loader/build-failure.d.ts +10 -0
- package/esm/src/rendering/orchestrator/module-loader/build-failure.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/module-loader/build-failure.js +50 -3
- package/esm/src/rendering/orchestrator/module-loader/dependency-resolver.d.ts +2 -0
- package/esm/src/rendering/orchestrator/module-loader/dependency-resolver.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/module-loader/dependency-resolver.js +21 -6
- package/esm/src/rendering/orchestrator/module-loader/index.d.ts +2 -1
- package/esm/src/rendering/orchestrator/module-loader/index.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/module-loader/index.js +190 -7
- package/esm/src/rendering/orchestrator/module-loader/module-persistence.d.ts +4 -0
- package/esm/src/rendering/orchestrator/module-loader/module-persistence.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/module-loader/module-persistence.js +374 -7
- package/esm/src/rendering/orchestrator/pipeline.d.ts.map +1 -1
- package/esm/src/rendering/orchestrator/pipeline.js +12 -1
- package/esm/src/runs/runs-client.d.ts +2 -4
- package/esm/src/runs/runs-client.d.ts.map +1 -1
- package/esm/src/runs/schemas.d.ts +18 -8
- package/esm/src/runs/schemas.d.ts.map +1 -1
- package/esm/src/runs/schemas.js +26 -0
- package/esm/src/runtime/model-call-context.d.ts +6 -1
- package/esm/src/runtime/model-call-context.d.ts.map +1 -1
- package/esm/src/runtime/runtime-bridge.d.ts.map +1 -1
- package/esm/src/runtime/runtime-bridge.js +133 -15
- package/esm/src/schedule/factory.d.ts +8 -2
- package/esm/src/schedule/factory.d.ts.map +1 -1
- package/esm/src/schedule/factory.js +0 -8
- package/esm/src/schedule/index.d.ts +10 -1
- package/esm/src/schedule/index.d.ts.map +1 -1
- package/esm/src/schedule/index.js +9 -0
- package/esm/src/schedule/types.d.ts +30 -11
- package/esm/src/schedule/types.d.ts.map +1 -1
- package/esm/src/schedule/validation.d.ts +17 -0
- package/esm/src/schedule/validation.d.ts.map +1 -1
- package/esm/src/schedule/validation.js +93 -5
- package/esm/src/security/sandbox/worker-pool.d.ts.map +1 -1
- package/esm/src/security/sandbox/worker-pool.js +6 -1
- package/esm/src/server/bootstrap.d.ts.map +1 -1
- package/esm/src/server/bootstrap.js +6 -0
- package/esm/src/server/dev-server/index.d.ts +1 -1
- package/esm/src/server/dev-server/index.d.ts.map +1 -1
- package/esm/src/server/dev-server/server.d.ts +7 -3
- package/esm/src/server/dev-server/server.d.ts.map +1 -1
- package/esm/src/server/dev-server/server.js +12 -3
- package/esm/src/server/dev-server/types.d.ts +7 -1
- package/esm/src/server/dev-server/types.d.ts.map +1 -1
- package/esm/src/server/dev-server.d.ts +1 -1
- package/esm/src/server/dev-server.d.ts.map +1 -1
- package/esm/src/server/handlers/dev/framework-candidates.generated.d.ts.map +1 -1
- package/esm/src/server/handlers/dev/framework-candidates.generated.js +2509 -34
- package/esm/src/server/handlers/dev/projects/index.d.ts.map +1 -1
- package/esm/src/server/handlers/dev/projects/index.js +3 -0
- package/esm/src/server/handlers/request/agent-stream.handler.d.ts.map +1 -1
- package/esm/src/server/handlers/request/agent-stream.handler.js +29 -24
- package/esm/src/server/index.d.ts +3 -3
- package/esm/src/server/index.d.ts.map +1 -1
- package/esm/src/server/index.js +10 -5
- package/esm/src/server/node-handler.d.ts.map +1 -1
- package/esm/src/server/node-handler.js +4 -1
- package/esm/src/server/production-server.d.ts.map +1 -1
- package/esm/src/server/production-server.js +2 -1
- package/esm/src/server/project-env/cache.d.ts +17 -0
- package/esm/src/server/project-env/cache.d.ts.map +1 -1
- package/esm/src/server/project-env/cache.js +78 -2
- package/esm/src/server/project-env/fetcher.d.ts.map +1 -1
- package/esm/src/server/project-env/fetcher.js +24 -14
- package/esm/src/server/project-env/index.d.ts +1 -1
- package/esm/src/server/project-env/index.d.ts.map +1 -1
- package/esm/src/server/project-env/index.js +1 -1
- package/esm/src/server/project-env/internal-authorization.d.ts +7 -0
- package/esm/src/server/project-env/internal-authorization.d.ts.map +1 -0
- package/esm/src/server/project-env/internal-authorization.js +32 -0
- package/esm/src/server/runtime-handler/index.d.ts.map +1 -1
- package/esm/src/server/runtime-handler/index.js +1 -1
- package/esm/src/server/runtime-handler/projects-handler.d.ts +1 -1
- package/esm/src/server/runtime-handler/projects-handler.d.ts.map +1 -1
- package/esm/src/server/runtime-handler/projects-handler.js +4 -2
- package/esm/src/transforms/esm/http-bundler.d.ts.map +1 -1
- package/esm/src/transforms/esm/http-bundler.js +6 -5
- package/esm/src/transforms/esm/http-cache-helpers.d.ts +11 -0
- package/esm/src/transforms/esm/http-cache-helpers.d.ts.map +1 -1
- package/esm/src/transforms/esm/http-cache-helpers.js +35 -0
- package/esm/src/transforms/esm/http-cache.d.ts.map +1 -1
- package/esm/src/transforms/esm/http-cache.js +16 -10
- package/esm/src/transforms/esm/specifier-resolver.d.ts.map +1 -1
- package/esm/src/transforms/esm/specifier-resolver.js +87 -7
- package/esm/src/transforms/import-rewriter/strategies/alias-strategy.d.ts +2 -0
- package/esm/src/transforms/import-rewriter/strategies/alias-strategy.d.ts.map +1 -1
- package/esm/src/transforms/import-rewriter/strategies/alias-strategy.js +11 -6
- package/esm/src/transforms/md/compiler/md-compiler.d.ts.map +1 -1
- package/esm/src/transforms/md/compiler/md-compiler.js +12 -5
- package/esm/src/transforms/mdx/compiler/frontmatter-extractor.d.ts +2 -0
- package/esm/src/transforms/mdx/compiler/frontmatter-extractor.d.ts.map +1 -1
- package/esm/src/transforms/mdx/compiler/frontmatter-extractor.js +33 -1
- package/esm/src/transforms/mdx/compiler/mdx-compiler.d.ts.map +1 -1
- package/esm/src/transforms/mdx/compiler/mdx-compiler.js +46 -7
- package/esm/src/transforms/mdx/esm-module-loader/cache/index.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/cache/index.js +8 -2
- package/esm/src/transforms/mdx/esm-module-loader/cache-format.d.ts +1 -0
- package/esm/src/transforms/mdx/esm-module-loader/cache-format.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/cache-format.js +3 -0
- package/esm/src/transforms/mdx/esm-module-loader/loader-helpers.d.ts +4 -0
- package/esm/src/transforms/mdx/esm-module-loader/loader-helpers.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/loader-helpers.js +44 -8
- package/esm/src/transforms/mdx/esm-module-loader/missing-module.d.ts +2 -0
- package/esm/src/transforms/mdx/esm-module-loader/missing-module.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/missing-module.js +4 -0
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/http-fallback.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/http-fallback.js +5 -1
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/http-fetcher.d.ts +2 -0
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/http-fetcher.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/http-fetcher.js +50 -11
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/nested-imports.d.ts +24 -12
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/nested-imports.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/module-fetcher/nested-imports.js +201 -18
- package/esm/src/transforms/mdx/esm-module-loader/types.d.ts +5 -0
- package/esm/src/transforms/mdx/esm-module-loader/types.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/utils/source-spans.d.ts +22 -2
- package/esm/src/transforms/mdx/esm-module-loader/utils/source-spans.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/utils/source-spans.js +2080 -129
- package/esm/src/transforms/mdx/esm-module-loader/utils/stub-module.d.ts +11 -1
- package/esm/src/transforms/mdx/esm-module-loader/utils/stub-module.d.ts.map +1 -1
- package/esm/src/transforms/mdx/esm-module-loader/utils/stub-module.js +32 -15
- package/esm/src/transforms/pipeline/stages/compile.d.ts.map +1 -1
- package/esm/src/transforms/pipeline/stages/compile.js +44 -0
- package/esm/src/transforms/shared/specifier-suffix.d.ts +25 -0
- package/esm/src/transforms/shared/specifier-suffix.d.ts.map +1 -0
- package/esm/src/transforms/shared/specifier-suffix.js +43 -0
- package/esm/src/trigger/index.d.ts +2 -2
- package/esm/src/trigger/index.d.ts.map +1 -1
- package/esm/src/trigger/index.js +1 -1
- package/esm/src/trigger/local-runner.d.ts +2 -2
- package/esm/src/trigger/local-runner.d.ts.map +1 -1
- package/esm/src/trigger/local-runner.js +11 -4
- package/esm/src/trigger/target.d.ts +97 -5
- package/esm/src/trigger/target.d.ts.map +1 -1
- package/esm/src/trigger/target.js +175 -5
- package/esm/src/utils/version-constant.d.ts +1 -1
- package/esm/src/utils/version-constant.js +1 -1
- package/esm/src/webhook/types.d.ts +21 -6
- package/esm/src/webhook/types.d.ts.map +1 -1
- package/esm/src/webhook/validation.d.ts.map +1 -1
- package/esm/src/webhook/validation.js +27 -39
- package/esm/templates/index.d.ts +1 -1
- package/esm/templates/index.d.ts.map +1 -1
- package/esm/templates/loader.d.ts +6 -6
- package/esm/templates/loader.d.ts.map +1 -1
- package/esm/templates/loader.js +34 -18
- package/esm/templates/manifest.generated.d.ts +3 -0
- package/esm/templates/manifest.generated.d.ts.map +1 -0
- package/esm/templates/manifest.generated.js +2 -0
- package/package.json +8 -8
- package/esm/templates/manifest.d.ts +0 -664
- package/esm/templates/manifest.d.ts.map +0 -1
- package/esm/templates/manifest.js +0 -662
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Tabs
|
|
2
|
+
* Tabs - ported from Veryfront Studio `components/Tabs/Tabs.tsx`, with the
|
|
3
3
|
* `motion/react` spring-slide forked out: the active pill is a static
|
|
4
4
|
* background (no dependency, no layout animation), only the `transition-colors`
|
|
5
5
|
* CSS that Studio already ships. Semantic classes remapped to veryfront's
|
|
6
|
-
* `[var(--token)]` vocabulary.
|
|
6
|
+
* `[var(--token)]` vocabulary.
|
|
7
|
+
*
|
|
8
|
+
* The selection MECHANICS (`role="tablist"` / `role="tab"`, `aria-selected`,
|
|
9
|
+
* select-on-click) come from the active adapter's `tabs` slot
|
|
10
|
+
* (`useAdapter().tabs`) - with no provider that is the zero-dependency builtin,
|
|
11
|
+
* so behaviour and markup are unchanged. This skin owns only the API shape, the
|
|
12
|
+
* `size` variant, and the visual look (including the active pill), which it
|
|
13
|
+
* drives from the controlled `value` prop.
|
|
7
14
|
*
|
|
8
15
|
* Flat, prefixed exports (`Tabs` + `TabsItem`) to match the other `ui/`
|
|
9
16
|
* primitives (`SelectItem`, `DialogTrigger`, …). Note: `cn` is clsx-only (no
|
|
@@ -11,8 +18,23 @@
|
|
|
11
18
|
* suffix (e.g. `px-8!`).
|
|
12
19
|
*
|
|
13
20
|
* Two sizes:
|
|
14
|
-
* - `default`
|
|
15
|
-
* - `sm`
|
|
21
|
+
* - `default` - filled track (`--input-bg`), 34/38px, accent pill.
|
|
22
|
+
* - `sm` - flat, outlined, 32px, for panel headers.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```tsx
|
|
26
|
+
* import { Tabs, TabsItem } from "veryfront/ui";
|
|
27
|
+
*
|
|
28
|
+
* function Example() {
|
|
29
|
+
* const [tab, setTab] = React.useState("overview");
|
|
30
|
+
* return (
|
|
31
|
+
* <Tabs value={tab} onValueChange={setTab}>
|
|
32
|
+
* <TabsItem value="overview">Overview</TabsItem>
|
|
33
|
+
* <TabsItem value="activity">Activity</TabsItem>
|
|
34
|
+
* </Tabs>
|
|
35
|
+
* );
|
|
36
|
+
* }
|
|
37
|
+
* ```
|
|
16
38
|
*
|
|
17
39
|
* @module react/components/ui/tabs
|
|
18
40
|
*/
|
|
@@ -25,7 +47,7 @@ export interface TabsProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "o
|
|
|
25
47
|
size?: TabsSize;
|
|
26
48
|
children: React.ReactNode;
|
|
27
49
|
}
|
|
28
|
-
/** Tablist container
|
|
50
|
+
/** Tablist container - delegates selection to the adapter, owns the size + look. */
|
|
29
51
|
export declare const Tabs: any;
|
|
30
52
|
/** Props accepted by `<TabsItem>`. */
|
|
31
53
|
export interface TabsItemProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "value"> {
|
|
@@ -34,10 +56,11 @@ export interface TabsItemProps extends Omit<React.ButtonHTMLAttributes<HTMLButto
|
|
|
34
56
|
children: React.ReactNode;
|
|
35
57
|
}
|
|
36
58
|
/**
|
|
37
|
-
* Individual tab
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
59
|
+
* Individual tab - renders as a button, or an anchor when `href` is set. The
|
|
60
|
+
* adapter's `tabs.Tab` supplies the `role="tab"` / `aria-selected` / `data-state`
|
|
61
|
+
* mechanics and composes selection onto the caller's `onClick` (caller's runs
|
|
62
|
+
* first, then the tab activates); this skin renders the visual pill and forwards
|
|
63
|
+
* native props/ref.
|
|
41
64
|
*/
|
|
42
65
|
export declare const TabsItem: any;
|
|
43
66
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tabs.d.ts","sourceRoot":"","sources":["../../../../../src/src/react/components/ui/tabs.tsx"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"tabs.d.ts","sourceRoot":"","sources":["../../../../../src/src/react/components/ui/tabs.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,KAAK,QAAQ,GAAG,SAAS,GAAG,IAAI,CAAC;AAWjC,0DAA0D;AAC1D,MAAM,WAAW,SAAU,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC;IACvF,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,IAAI,CAAC,EAAE,QAAQ,CAAC;IAChB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,oFAAoF;AACpF,eAAO,MAAM,IAAI,KAwBf,CAAC;AAGH,sCAAsC;AACtC,MAAM,WAAW,aACf,SAAQ,IAAI,CAAC,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,OAAO,CAAC;IACpE,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,QAAQ,KAyCpB,CAAC"}
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Tabs
|
|
2
|
+
* Tabs - ported from Veryfront Studio `components/Tabs/Tabs.tsx`, with the
|
|
3
3
|
* `motion/react` spring-slide forked out: the active pill is a static
|
|
4
4
|
* background (no dependency, no layout animation), only the `transition-colors`
|
|
5
5
|
* CSS that Studio already ships. Semantic classes remapped to veryfront's
|
|
6
|
-
* `[var(--token)]` vocabulary.
|
|
6
|
+
* `[var(--token)]` vocabulary.
|
|
7
|
+
*
|
|
8
|
+
* The selection MECHANICS (`role="tablist"` / `role="tab"`, `aria-selected`,
|
|
9
|
+
* select-on-click) come from the active adapter's `tabs` slot
|
|
10
|
+
* (`useAdapter().tabs`) - with no provider that is the zero-dependency builtin,
|
|
11
|
+
* so behaviour and markup are unchanged. This skin owns only the API shape, the
|
|
12
|
+
* `size` variant, and the visual look (including the active pill), which it
|
|
13
|
+
* drives from the controlled `value` prop.
|
|
7
14
|
*
|
|
8
15
|
* Flat, prefixed exports (`Tabs` + `TabsItem`) to match the other `ui/`
|
|
9
16
|
* primitives (`SelectItem`, `DialogTrigger`, …). Note: `cn` is clsx-only (no
|
|
@@ -11,40 +18,57 @@
|
|
|
11
18
|
* suffix (e.g. `px-8!`).
|
|
12
19
|
*
|
|
13
20
|
* Two sizes:
|
|
14
|
-
* - `default`
|
|
15
|
-
* - `sm`
|
|
21
|
+
* - `default` - filled track (`--input-bg`), 34/38px, accent pill.
|
|
22
|
+
* - `sm` - flat, outlined, 32px, for panel headers.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```tsx
|
|
26
|
+
* import { Tabs, TabsItem } from "veryfront/ui";
|
|
27
|
+
*
|
|
28
|
+
* function Example() {
|
|
29
|
+
* const [tab, setTab] = React.useState("overview");
|
|
30
|
+
* return (
|
|
31
|
+
* <Tabs value={tab} onValueChange={setTab}>
|
|
32
|
+
* <TabsItem value="overview">Overview</TabsItem>
|
|
33
|
+
* <TabsItem value="activity">Activity</TabsItem>
|
|
34
|
+
* </Tabs>
|
|
35
|
+
* );
|
|
36
|
+
* }
|
|
37
|
+
* ```
|
|
16
38
|
*
|
|
17
39
|
* @module react/components/ui/tabs
|
|
18
40
|
*/
|
|
19
41
|
import * as React from "react";
|
|
20
42
|
import { createStrictContext } from "../create-strict-context.js";
|
|
21
43
|
import { cx as cn } from "./cva.js";
|
|
22
|
-
|
|
23
|
-
|
|
44
|
+
import { useAdapter } from "./adapter/context.js";
|
|
45
|
+
const [TabsSkinContext, useTabsSkin] = createStrictContext("TabsItem", "Tabs");
|
|
46
|
+
/** Tablist container - delegates selection to the adapter, owns the size + look. */
|
|
24
47
|
export const Tabs = React.forwardRef(function Tabs({ value, onValueChange, size = "default", className, children, ...props }, ref) {
|
|
25
|
-
|
|
26
|
-
|
|
48
|
+
const { tabs } = useAdapter();
|
|
49
|
+
return (React.createElement(TabsSkinContext.Provider, { value: { value, size } },
|
|
50
|
+
React.createElement(tabs.Root, { ref: ref, value: value, onValueChange: onValueChange, ...props, className: cn("inline-flex w-fit items-center rounded-full", size === "sm"
|
|
27
51
|
? "h-[32px] gap-0 border border-[var(--edge)] bg-transparent p-0.5"
|
|
28
52
|
: "h-[34px] gap-2 bg-[var(--input-bg)] p-1 md:h-[38px]", className) }, children)));
|
|
29
53
|
});
|
|
30
54
|
Tabs.displayName = "Tabs";
|
|
31
55
|
/**
|
|
32
|
-
* Individual tab
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
56
|
+
* Individual tab - renders as a button, or an anchor when `href` is set. The
|
|
57
|
+
* adapter's `tabs.Tab` supplies the `role="tab"` / `aria-selected` / `data-state`
|
|
58
|
+
* mechanics and composes selection onto the caller's `onClick` (caller's runs
|
|
59
|
+
* first, then the tab activates); this skin renders the visual pill and forwards
|
|
60
|
+
* native props/ref.
|
|
36
61
|
*/
|
|
37
62
|
export const TabsItem = React.forwardRef(function TabsItem({ value, href, children, className, onClick, ...props }, ref) {
|
|
38
|
-
const
|
|
39
|
-
const
|
|
63
|
+
const { tabs } = useAdapter();
|
|
64
|
+
const { value: selected, size } = useTabsSkin();
|
|
65
|
+
const isActive = selected === value;
|
|
40
66
|
const Comp = (href ? "a" : "button");
|
|
41
|
-
return (React.createElement(
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
: "
|
|
47
|
-
isActive && (React.createElement("div", { className: cn("absolute inset-0 rounded-full bg-[var(--accent)]", ctx.size === "default" && "dark:bg-[var(--foreground)]") })),
|
|
48
|
-
React.createElement("span", { className: "relative z-10" }, children)));
|
|
67
|
+
return (React.createElement(tabs.Tab, { value: value, asChild: true, ref: ref, onClick: onClick },
|
|
68
|
+
React.createElement(Comp, { ...(href ? { href } : { type: "button" }), ...props, className: cn("relative inline-flex items-center h-full rounded-full font-normal transition-colors cursor-pointer focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--edge-medium)]", size === "sm" ? "px-3 text-sm" : "px-5 md:px-6 text-sm md:text-base", isActive
|
|
69
|
+
? cn("text-[var(--foreground)]", size === "default" && "dark:text-[var(--background)]")
|
|
70
|
+
: "text-[var(--foreground)] opacity-50 hover:opacity-100", className) },
|
|
71
|
+
isActive && (React.createElement("div", { className: cn("absolute inset-0 rounded-full bg-[var(--accent)]", size === "default" && "dark:bg-[var(--foreground)]") })),
|
|
72
|
+
React.createElement("span", { className: "relative z-10" }, children))));
|
|
49
73
|
});
|
|
50
74
|
TabsItem.displayName = "TabsItem";
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Toggle - a two-state pressed button (on / off). Behavioural but self-contained
|
|
3
|
+
* (a single `aria-pressed` button, no floating engine needed): controlled via
|
|
4
|
+
* `pressed`/`onPressedChange` or uncontrolled via `defaultPressed`. State is
|
|
5
|
+
* exposed as `data-state="on" | "off"` for styling; `asChild` grafts the toggle
|
|
6
|
+
* behaviour onto your own element. Skinned entirely with veryfront theme tokens.
|
|
7
|
+
*
|
|
8
|
+
* @module react/components/ui/toggle
|
|
9
|
+
*/
|
|
10
|
+
import * as React from "react";
|
|
11
|
+
/** Props accepted by `<Toggle>`. */
|
|
12
|
+
export interface ToggleProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "onChange"> {
|
|
13
|
+
/** Controlled pressed state. Pair with `onPressedChange`. */
|
|
14
|
+
pressed?: boolean;
|
|
15
|
+
/** Initial pressed state when uncontrolled. @default false */
|
|
16
|
+
defaultPressed?: boolean;
|
|
17
|
+
/** Fires with the next pressed state on user activation. */
|
|
18
|
+
onPressedChange?: (pressed: boolean) => void;
|
|
19
|
+
/** Render as a Slot, merging the toggle behaviour onto the child element. */
|
|
20
|
+
asChild?: boolean;
|
|
21
|
+
/** React 19: ref is a regular prop. */
|
|
22
|
+
ref?: React.Ref<HTMLButtonElement>;
|
|
23
|
+
}
|
|
24
|
+
/** Render a pressed toggle button. */
|
|
25
|
+
export declare function Toggle({ pressed, defaultPressed, onPressedChange, asChild, disabled, className, onClick, ref, ...props }: ToggleProps): React.ReactElement;
|
|
26
|
+
//# sourceMappingURL=toggle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle.d.ts","sourceRoot":"","sources":["../../../../../src/src/react/components/ui/toggle.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,oCAAoC;AACpC,MAAM,WAAW,WACf,SAAQ,IAAI,CAAC,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,UAAU,CAAC;IACvE,6DAA6D;IAC7D,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,8DAA8D;IAC9D,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,4DAA4D;IAC5D,eAAe,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IAC7C,6EAA6E;IAC7E,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,uCAAuC;IACvC,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;CACpC;AAED,sCAAsC;AACtC,wBAAgB,MAAM,CAAC,EACrB,OAAO,EACP,cAAsB,EACtB,eAAe,EACf,OAAe,EACf,QAAQ,EACR,SAAS,EACT,OAAO,EACP,GAAG,EACH,GAAG,KAAK,EACT,EAAE,WAAW,GAAG,KAAK,CAAC,YAAY,CAsClC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Toggle - a two-state pressed button (on / off). Behavioural but self-contained
|
|
3
|
+
* (a single `aria-pressed` button, no floating engine needed): controlled via
|
|
4
|
+
* `pressed`/`onPressedChange` or uncontrolled via `defaultPressed`. State is
|
|
5
|
+
* exposed as `data-state="on" | "off"` for styling; `asChild` grafts the toggle
|
|
6
|
+
* behaviour onto your own element. Skinned entirely with veryfront theme tokens.
|
|
7
|
+
*
|
|
8
|
+
* @module react/components/ui/toggle
|
|
9
|
+
*/
|
|
10
|
+
import * as React from "react";
|
|
11
|
+
import { cx as cn } from "./cva.js";
|
|
12
|
+
import { Slot } from "./slot.js";
|
|
13
|
+
/** Render a pressed toggle button. */
|
|
14
|
+
export function Toggle({ pressed, defaultPressed = false, onPressedChange, asChild = false, disabled, className, onClick, ref, ...props }) {
|
|
15
|
+
const isControlled = pressed !== undefined;
|
|
16
|
+
const [internal, setInternal] = React.useState(defaultPressed);
|
|
17
|
+
const isOn = isControlled ? pressed : internal;
|
|
18
|
+
const handleClick = (event) => {
|
|
19
|
+
onClick?.(event);
|
|
20
|
+
if (event.defaultPrevented)
|
|
21
|
+
return;
|
|
22
|
+
const next = !isOn;
|
|
23
|
+
if (!isControlled)
|
|
24
|
+
setInternal(next);
|
|
25
|
+
onPressedChange?.(next);
|
|
26
|
+
};
|
|
27
|
+
const Comp = asChild ? Slot : "button";
|
|
28
|
+
return (React.createElement(Comp, { ref: ref, type: asChild ? undefined : "button", "aria-pressed": isOn, "data-state": isOn ? "on" : "off", "data-disabled": disabled ? "" : undefined, disabled: disabled, onClick: handleClick, className: cn("inline-flex items-center justify-center gap-1.5 whitespace-nowrap rounded-md", "h-[38px] min-w-[38px] px-3 text-base font-normal", "transition-[background-color,color] duration-150 ease-in", "text-[var(--foreground)] hover:bg-[var(--accent)]", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--edge-medium)] focus-visible:ring-offset-2 focus-visible:ring-offset-[var(--background)]", "data-[state=on]:bg-[var(--secondary)] data-[state=on]:text-[var(--foreground)]", "disabled:pointer-events-none disabled:opacity-50", "[&_svg]:size-4 [&_svg]:shrink-0", className), ...props }));
|
|
29
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import * as React from "react";
|
|
1
2
|
/**
|
|
2
3
|
* Use a layout effect in browsers without emitting React's server-rendering
|
|
3
4
|
* warning when a primitive is rendered on the server.
|
|
4
5
|
*/
|
|
5
|
-
export declare const useIsomorphicLayoutEffect:
|
|
6
|
+
export declare const useIsomorphicLayoutEffect: typeof React.useLayoutEffect;
|
|
6
7
|
//# sourceMappingURL=use-isomorphic-layout-effect.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-isomorphic-layout-effect.d.ts","sourceRoot":"","sources":["../../../../../src/src/react/components/ui/use-isomorphic-layout-effect.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"use-isomorphic-layout-effect.d.ts","sourceRoot":"","sources":["../../../../../src/src/react/components/ui/use-isomorphic-layout-effect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,OAAO,KAAK,CAAC,eAKpD,CAAC"}
|
|
@@ -3,6 +3,9 @@ import * as React from "react";
|
|
|
3
3
|
* Use a layout effect in browsers without emitting React's server-rendering
|
|
4
4
|
* warning when a primitive is rendered on the server.
|
|
5
5
|
*/
|
|
6
|
-
export const useIsomorphicLayoutEffect =
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
export const useIsomorphicLayoutEffect = (effect, deps) => {
|
|
7
|
+
const useEffectHook = typeof globalThis.document === "undefined"
|
|
8
|
+
? React.useEffect
|
|
9
|
+
: React.useLayoutEffect;
|
|
10
|
+
return useEffectHook(effect, deps);
|
|
11
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"source-imports.d.ts","sourceRoot":"","sources":["../../../../src/src/rendering/chunk-optimizer/source-imports.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAKjE,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;
|
|
1
|
+
{"version":3,"file":"source-imports.d.ts","sourceRoot":"","sources":["../../../../src/src/rendering/chunk-optimizer/source-imports.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAKjE,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;AA8PD,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,YAAY,CAwBhE;AAED,OAAO,EAAE,cAAc,EAAE,CAAC"}
|
|
@@ -179,123 +179,13 @@ function maskMarkdownRegions(source) {
|
|
|
179
179
|
}
|
|
180
180
|
return maskHtmlComments(parts.join(""));
|
|
181
181
|
}
|
|
182
|
-
function readHexDigit(char) {
|
|
183
|
-
if (char === undefined)
|
|
184
|
-
return -1;
|
|
185
|
-
const code = char.charCodeAt(0);
|
|
186
|
-
if (code >= 0x30 && code <= 0x39)
|
|
187
|
-
return code - 0x30;
|
|
188
|
-
if (code >= 0x41 && code <= 0x46)
|
|
189
|
-
return code - 0x41 + 10;
|
|
190
|
-
if (code >= 0x61 && code <= 0x66)
|
|
191
|
-
return code - 0x61 + 10;
|
|
192
|
-
return -1;
|
|
193
|
-
}
|
|
194
|
-
function readFixedHex(value, start, length) {
|
|
195
|
-
let parsed = 0;
|
|
196
|
-
for (let index = 0; index < length; index++) {
|
|
197
|
-
const digit = readHexDigit(value[start + index]);
|
|
198
|
-
if (digit === -1) {
|
|
199
|
-
throw new SyntaxError("Invalid escaped module specifier");
|
|
200
|
-
}
|
|
201
|
-
parsed = parsed * 16 + digit;
|
|
202
|
-
}
|
|
203
|
-
return { value: parsed, end: start + length };
|
|
204
|
-
}
|
|
205
|
-
function decodeModuleSpecifier(value) {
|
|
206
|
-
if (!value.includes("\\"))
|
|
207
|
-
return value;
|
|
208
|
-
let decoded = "";
|
|
209
|
-
let cursor = 0;
|
|
210
|
-
while (cursor < value.length) {
|
|
211
|
-
const char = value[cursor++];
|
|
212
|
-
if (char !== "\\") {
|
|
213
|
-
if (char === "\n" || char === "\r") {
|
|
214
|
-
throw new SyntaxError("Module specifiers cannot contain line terminators");
|
|
215
|
-
}
|
|
216
|
-
decoded += char;
|
|
217
|
-
continue;
|
|
218
|
-
}
|
|
219
|
-
if (cursor >= value.length) {
|
|
220
|
-
throw new SyntaxError("Invalid escaped module specifier");
|
|
221
|
-
}
|
|
222
|
-
const escaped = value[cursor++];
|
|
223
|
-
const simple = {
|
|
224
|
-
b: "\b",
|
|
225
|
-
f: "\f",
|
|
226
|
-
n: "\n",
|
|
227
|
-
r: "\r",
|
|
228
|
-
t: "\t",
|
|
229
|
-
v: "\v",
|
|
230
|
-
"\\": "\\",
|
|
231
|
-
"'": "'",
|
|
232
|
-
'"': '"',
|
|
233
|
-
};
|
|
234
|
-
if (Object.hasOwn(simple, escaped)) {
|
|
235
|
-
decoded += simple[escaped];
|
|
236
|
-
continue;
|
|
237
|
-
}
|
|
238
|
-
if (escaped === "\n")
|
|
239
|
-
continue;
|
|
240
|
-
if (escaped === "\r") {
|
|
241
|
-
if (value[cursor] === "\n")
|
|
242
|
-
cursor++;
|
|
243
|
-
continue;
|
|
244
|
-
}
|
|
245
|
-
if (escaped === "0") {
|
|
246
|
-
if (/[0-9]/.test(value[cursor] ?? "")) {
|
|
247
|
-
throw new SyntaxError("Legacy octal escapes are not valid in module specifiers");
|
|
248
|
-
}
|
|
249
|
-
decoded += "\0";
|
|
250
|
-
continue;
|
|
251
|
-
}
|
|
252
|
-
if (escaped === "x") {
|
|
253
|
-
const parsed = readFixedHex(value, cursor, 2);
|
|
254
|
-
decoded += String.fromCharCode(parsed.value);
|
|
255
|
-
cursor = parsed.end;
|
|
256
|
-
continue;
|
|
257
|
-
}
|
|
258
|
-
if (escaped === "u") {
|
|
259
|
-
if (value[cursor] === "{") {
|
|
260
|
-
const closing = value.indexOf("}", cursor + 1);
|
|
261
|
-
if (closing === -1 || closing === cursor + 1) {
|
|
262
|
-
throw new SyntaxError("Invalid Unicode escape in module specifier");
|
|
263
|
-
}
|
|
264
|
-
let codePoint = 0;
|
|
265
|
-
for (let index = cursor + 1; index < closing; index++) {
|
|
266
|
-
const digit = readHexDigit(value[index]);
|
|
267
|
-
if (digit === -1) {
|
|
268
|
-
throw new SyntaxError("Invalid Unicode escape in module specifier");
|
|
269
|
-
}
|
|
270
|
-
codePoint = codePoint * 16 + digit;
|
|
271
|
-
if (codePoint > 0x10ffff) {
|
|
272
|
-
throw new SyntaxError("Module specifier Unicode escape is out of range");
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
decoded += String.fromCodePoint(codePoint);
|
|
276
|
-
cursor = closing + 1;
|
|
277
|
-
continue;
|
|
278
|
-
}
|
|
279
|
-
const parsed = readFixedHex(value, cursor, 4);
|
|
280
|
-
decoded += String.fromCharCode(parsed.value);
|
|
281
|
-
cursor = parsed.end;
|
|
282
|
-
continue;
|
|
283
|
-
}
|
|
284
|
-
if (escaped >= "1" && escaped <= "9") {
|
|
285
|
-
throw new SyntaxError("Legacy numeric escapes are not valid in module specifiers");
|
|
286
|
-
}
|
|
287
|
-
decoded += escaped;
|
|
288
|
-
}
|
|
289
|
-
return decoded;
|
|
290
|
-
}
|
|
291
182
|
function validateImportSpecifier(value) {
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
hasControlCharacter(decoded)) {
|
|
183
|
+
if (value.length === 0 ||
|
|
184
|
+
value.length > MAX_IMPORT_SPECIFIER_CHARS ||
|
|
185
|
+
hasControlCharacter(value)) {
|
|
296
186
|
throw new TypeError(`Chunk analysis import specifiers must contain between 1 and ${MAX_IMPORT_SPECIFIER_CHARS} characters without control characters`);
|
|
297
187
|
}
|
|
298
|
-
return
|
|
188
|
+
return value;
|
|
299
189
|
}
|
|
300
190
|
/**
|
|
301
191
|
* Run a span scanner one match past the per-page bound and fail closed there.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"css-candidate-manifest.d.ts","sourceRoot":"","sources":["../../../../src/src/rendering/orchestrator/css-candidate-manifest.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,iBAAiB,EACvB,MAAM,kDAAkD,CAAC;AAK1D,UAAU,cAAc;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAQD,UAAU,qBAAqB;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,iBAAiB,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,KAAK,EAAE,cAAc,EAAE,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED,UAAU,uBAAuB;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,iBAAiB,CAAC;IACjC,KAAK,EAAE,cAAc,EAAE,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;CAC1B;AAqBD,wBAAgB,8BAA8B,IAAI;IAChD,SAAS,EAAE;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/B,eAAe,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAC;CAC1D,CAUA;
|
|
1
|
+
{"version":3,"file":"css-candidate-manifest.d.ts","sourceRoot":"","sources":["../../../../src/src/rendering/orchestrator/css-candidate-manifest.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,iBAAiB,EACvB,MAAM,kDAAkD,CAAC;AAK1D,UAAU,cAAc;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAQD,UAAU,qBAAqB;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,iBAAiB,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,KAAK,EAAE,cAAc,EAAE,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED,UAAU,uBAAuB;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,iBAAiB,CAAC;IACjC,KAAK,EAAE,cAAc,EAAE,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;CAC1B;AAqBD,wBAAgB,8BAA8B,IAAI;IAChD,SAAS,EAAE;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/B,eAAe,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAC;CAC1D,CAUA;AA2ID;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,qBAAqB,GAAG,GAAG,CAAC,MAAM,CAAC,CAoD9E;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,uBAAuB,GAAG,GAAG,CAAC,MAAM,CAAC,CAGlF;AAED;;GAEG;AACH,wBAAgB,mCAAmC,CAAC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAc/E"}
|
|
@@ -40,6 +40,19 @@ function toRelativeProjectPath(path, projectDir) {
|
|
|
40
40
|
}
|
|
41
41
|
return normalized.replace(/^\/+/, "");
|
|
42
42
|
}
|
|
43
|
+
function toDiagnosticProjectPath(path, projectDir) {
|
|
44
|
+
const normalized = normalizePath(path);
|
|
45
|
+
const normalizedProjectDir = normalizePath(projectDir).replace(/\/+$/, "");
|
|
46
|
+
if (normalized === normalizedProjectDir)
|
|
47
|
+
return ".";
|
|
48
|
+
if (normalized.startsWith(`${normalizedProjectDir}/`)) {
|
|
49
|
+
return normalized.slice(normalizedProjectDir.length + 1);
|
|
50
|
+
}
|
|
51
|
+
if (/^(?:[A-Za-z]:)?\//.test(normalized)) {
|
|
52
|
+
return `[outside-project]/${normalized.split("/").pop() ?? "unknown"}`;
|
|
53
|
+
}
|
|
54
|
+
return normalized.replace(/^\/+/, "");
|
|
55
|
+
}
|
|
43
56
|
function buildManifestCacheKey(projectScope, projectVersion, styleProfileHash) {
|
|
44
57
|
return `${projectScope}:${projectVersion}:${styleProfileHash ?? "default"}`;
|
|
45
58
|
}
|
|
@@ -71,7 +84,23 @@ function buildCandidateManifest(files, projectDir) {
|
|
|
71
84
|
continue;
|
|
72
85
|
if (!SOURCE_EXTENSIONS.some((ext) => file.path.endsWith(ext)))
|
|
73
86
|
continue;
|
|
74
|
-
|
|
87
|
+
// A file the tokenizer refuses to admit (over the byte or candidate-count
|
|
88
|
+
// cap) must degrade to "contributes no candidates", not abort the manifest:
|
|
89
|
+
// an escaping throw here propagates to the SSR boundary and, because it
|
|
90
|
+
// happens before manifestCache.set, is rebuilt and re-thrown on every
|
|
91
|
+
// request to the project (VERYFRONT-SERVER-F).
|
|
92
|
+
let extracted;
|
|
93
|
+
try {
|
|
94
|
+
extracted = extractCandidates(file.content);
|
|
95
|
+
}
|
|
96
|
+
catch (error) {
|
|
97
|
+
logger.warn("Skipping file rejected by candidate extraction", {
|
|
98
|
+
path: toDiagnosticProjectPath(file.path, projectDir),
|
|
99
|
+
error: error instanceof Error ? error.message : String(error),
|
|
100
|
+
});
|
|
101
|
+
continue;
|
|
102
|
+
}
|
|
103
|
+
const candidates = new Set(extracted);
|
|
75
104
|
const relativePath = toRelativeProjectPath(file.path, projectDir);
|
|
76
105
|
const absolutePath = normalizePath(file.path);
|
|
77
106
|
fileCandidates.set(relativePath, candidates);
|
|
@@ -15,6 +15,16 @@
|
|
|
15
15
|
*/
|
|
16
16
|
/** Tag `error` as a build failure and return it. */
|
|
17
17
|
export declare function markBuildFailure(error: unknown): unknown;
|
|
18
|
+
/**
|
|
19
|
+
* Tag `error` as a build failure the tenant's own source caused, and return it.
|
|
20
|
+
*
|
|
21
|
+
* For seams that know the provenance from control flow rather than from a
|
|
22
|
+
* registry slug — an import specifier that still does not resolve after a full
|
|
23
|
+
* rebuild, for instance, is a path the project authored.
|
|
24
|
+
*/
|
|
25
|
+
export declare function markTenantBuildFailure(error: unknown): unknown;
|
|
18
26
|
/** True when `error` was raised while compiling or resolving project source. */
|
|
19
27
|
export declare function isBuildFailure(error: unknown): boolean;
|
|
28
|
+
/** True only for a build failure explicitly classified as tenant source. */
|
|
29
|
+
export declare function isTenantBuildFailure(error: unknown): boolean;
|
|
20
30
|
//# sourceMappingURL=build-failure.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build-failure.d.ts","sourceRoot":"","sources":["../../../../../src/src/rendering/orchestrator/module-loader/build-failure.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;
|
|
1
|
+
{"version":3,"file":"build-failure.d.ts","sourceRoot":"","sources":["../../../../../src/src/rendering/orchestrator/module-loader/build-failure.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAiCH,oDAAoD;AACpD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAMxD;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAM9D;AAED,gFAAgF;AAChF,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAEtD;AAED,4EAA4E;AAC5E,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAE5D"}
|
|
@@ -13,14 +13,61 @@
|
|
|
13
13
|
* Only the loader is in a position to know which happened, so it tags the
|
|
14
14
|
* error at the point of failure instead of leaving later layers to infer it.
|
|
15
15
|
*/
|
|
16
|
+
import { isTenantSourceBuildError } from "../../../errors/tenant-classification.js";
|
|
17
|
+
const ObjectDefineProperty = Object.defineProperty;
|
|
18
|
+
const ObjectPrototypeHasOwnProperty = Object.prototype.hasOwnProperty;
|
|
19
|
+
const ReflectApply = Reflect.apply;
|
|
20
|
+
const ReflectGetOwnPropertyDescriptor = Reflect.getOwnPropertyDescriptor;
|
|
16
21
|
const BUILD_FAILURE = Symbol.for("veryfront.module-loader.build-failure");
|
|
22
|
+
const TENANT_BUILD_FAILURE = Symbol.for("veryfront.module-loader.tenant-build-failure");
|
|
23
|
+
/**
|
|
24
|
+
* Modules are strict mode, so a plain assignment onto a frozen error throws.
|
|
25
|
+
* These taggers run inside `catch` blocks, where a throw would replace the
|
|
26
|
+
* original error with a `TypeError` and lose the failure entirely.
|
|
27
|
+
*/
|
|
28
|
+
function defineTag(error, tag) {
|
|
29
|
+
try {
|
|
30
|
+
ObjectDefineProperty(error, tag, { value: true, configurable: true });
|
|
31
|
+
}
|
|
32
|
+
catch {
|
|
33
|
+
// Sealed or non-configurable: the error stays untagged, which degrades to
|
|
34
|
+
// the pre-classification behavior rather than destroying the error.
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
function hasOwnTrueTag(error, tag) {
|
|
38
|
+
const descriptor = ReflectGetOwnPropertyDescriptor(error, tag);
|
|
39
|
+
return descriptor !== undefined &&
|
|
40
|
+
ReflectApply(ObjectPrototypeHasOwnProperty, descriptor, ["value"]) === true &&
|
|
41
|
+
descriptor.value === true;
|
|
42
|
+
}
|
|
17
43
|
/** Tag `error` as a build failure and return it. */
|
|
18
44
|
export function markBuildFailure(error) {
|
|
19
|
-
if (error instanceof Error)
|
|
20
|
-
error
|
|
45
|
+
if (error instanceof Error) {
|
|
46
|
+
defineTag(error, BUILD_FAILURE);
|
|
47
|
+
if (isTenantSourceBuildError(error))
|
|
48
|
+
defineTag(error, TENANT_BUILD_FAILURE);
|
|
49
|
+
}
|
|
50
|
+
return error;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Tag `error` as a build failure the tenant's own source caused, and return it.
|
|
54
|
+
*
|
|
55
|
+
* For seams that know the provenance from control flow rather than from a
|
|
56
|
+
* registry slug — an import specifier that still does not resolve after a full
|
|
57
|
+
* rebuild, for instance, is a path the project authored.
|
|
58
|
+
*/
|
|
59
|
+
export function markTenantBuildFailure(error) {
|
|
60
|
+
if (error instanceof Error) {
|
|
61
|
+
defineTag(error, BUILD_FAILURE);
|
|
62
|
+
defineTag(error, TENANT_BUILD_FAILURE);
|
|
63
|
+
}
|
|
21
64
|
return error;
|
|
22
65
|
}
|
|
23
66
|
/** True when `error` was raised while compiling or resolving project source. */
|
|
24
67
|
export function isBuildFailure(error) {
|
|
25
|
-
return error instanceof Error && error
|
|
68
|
+
return error instanceof Error && hasOwnTrueTag(error, BUILD_FAILURE);
|
|
69
|
+
}
|
|
70
|
+
/** True only for a build failure explicitly classified as tenant source. */
|
|
71
|
+
export function isTenantBuildFailure(error) {
|
|
72
|
+
return error instanceof Error && hasOwnTrueTag(error, TENANT_BUILD_FAILURE);
|
|
26
73
|
}
|
|
@@ -10,6 +10,8 @@ export type ResolvedModuleDependency = {
|
|
|
10
10
|
isLocalLib: boolean;
|
|
11
11
|
/** True when discovered inside `import("…")` rather than a static import. */
|
|
12
12
|
isDynamic: boolean;
|
|
13
|
+
/** True when discovered in a bare `import "…"` statement. */
|
|
14
|
+
isSideEffect?: boolean;
|
|
13
15
|
};
|
|
14
16
|
/** Resolved dependency after its source module has been transformed to a temp file. */
|
|
15
17
|
export type TransformedModuleDependency = ResolvedModuleDependency & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dependency-resolver.d.ts","sourceRoot":"","sources":["../../../../../src/src/rendering/orchestrator/module-loader/dependency-resolver.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;
|
|
1
|
+
{"version":3,"file":"dependency-resolver.d.ts","sourceRoot":"","sources":["../../../../../src/src/rendering/orchestrator/module-loader/dependency-resolver.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AAsDzE,sEAAsE;AACtE,MAAM,MAAM,wBAAwB,GAAG;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,UAAU,EAAE,OAAO,CAAC;IACpB,6EAA6E;IAC7E,SAAS,EAAE,OAAO,CAAC;IACnB,6DAA6D;IAC7D,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF,uFAAuF;AACvF,MAAM,MAAM,2BAA2B,GAAG,wBAAwB,GAAG;IACnE,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,sEAAsE;AACtE,MAAM,WAAW,8BAA8B;IAC7C,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,cAAc,CAAC;CACzB;AAyID,yEAAyE;AACzE,wBAAsB,yBAAyB,CAC7C,KAAK,EAAE,8BAA8B,GACpC,OAAO,CAAC,wBAAwB,EAAE,CAAC,CAuBrC;AAED,2EAA2E;AAC3E,wBAAgB,gCAAgC,CAC9C,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,2BAA2B,EAAE,GAC7C,MAAM,CAiBR"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { dirname, join, normalize, toFileUrl } from "../../../platform/compat/path/index.js";
|
|
2
2
|
import { parallelMap, rendererLogger } from "../../../utils/index.js";
|
|
3
|
-
import { findDynamicImportSpans, findStaticImportFromSpans, replaceSourceSpans, } from "../../../transforms/mdx/esm-module-loader/utils/source-spans.js";
|
|
3
|
+
import { findDynamicImportSpans, findStaticImportFromSpans, findStaticSideEffectImportSpans, replaceSourceSpans, } from "../../../transforms/mdx/esm-module-loader/utils/source-spans.js";
|
|
4
4
|
import { findSourceFile } from "../file-resolver/index.js";
|
|
5
5
|
const logger = rendererLogger.component("module-loader");
|
|
6
6
|
const MAX_IMPORTS_PER_KIND = 500;
|
|
@@ -22,16 +22,26 @@ function collectBoundedSpans(scan, kind) {
|
|
|
22
22
|
const matchAlias = (specifier) => specifier.startsWith("@/") ? specifier : null;
|
|
23
23
|
const matchRelative = (specifier) => specifier.match(/^(\.\.?\/[^?]+)(?:\?.*)?$/)?.[1];
|
|
24
24
|
function collectAliasImports(fileContent) {
|
|
25
|
-
const toAlias = (isDynamic) => ({ original, path, start, end }) => ({ full: original, path, start, end, isDynamic });
|
|
25
|
+
const toAlias = (isDynamic, isSideEffect = false) => ({ original, path, start, end }) => ({ full: original, path, start, end, isDynamic, isSideEffect });
|
|
26
26
|
return [
|
|
27
27
|
...collectBoundedSpans((maxMatches) => findStaticImportFromSpans(fileContent, matchAlias, maxMatches), "static alias").map(toAlias(false)),
|
|
28
|
+
...collectBoundedSpans((maxMatches) => findStaticSideEffectImportSpans(fileContent, matchAlias, maxMatches), "side-effect alias").map(toAlias(false, true)),
|
|
28
29
|
...collectBoundedSpans((maxMatches) => findDynamicImportSpans(fileContent, matchAlias, maxMatches), "dynamic alias").map(toAlias(true)),
|
|
29
30
|
];
|
|
30
31
|
}
|
|
31
32
|
function collectRelativeImports(fileContent, fileDir) {
|
|
32
|
-
const toRelative = (isDynamic) => ({ original, path, start, end }) => ({
|
|
33
|
+
const toRelative = (isDynamic, isSideEffect = false) => ({ original, path, start, end }) => ({
|
|
34
|
+
full: original,
|
|
35
|
+
path,
|
|
36
|
+
fromDir: fileDir,
|
|
37
|
+
start,
|
|
38
|
+
end,
|
|
39
|
+
isDynamic,
|
|
40
|
+
isSideEffect,
|
|
41
|
+
});
|
|
33
42
|
return [
|
|
34
43
|
...collectBoundedSpans((maxMatches) => findStaticImportFromSpans(fileContent, matchRelative, maxMatches), "static relative").map(toRelative(false)),
|
|
44
|
+
...collectBoundedSpans((maxMatches) => findStaticSideEffectImportSpans(fileContent, matchRelative, maxMatches), "side-effect relative").map(toRelative(false, true)),
|
|
35
45
|
...collectBoundedSpans((maxMatches) => findDynamicImportSpans(fileContent, matchRelative, maxMatches), "dynamic relative").map(toRelative(true)),
|
|
36
46
|
]
|
|
37
47
|
// Ignore already-transformed file:// imports.
|
|
@@ -85,6 +95,7 @@ async function resolveRelativeImport(imp, adapter) {
|
|
|
85
95
|
depFilePath,
|
|
86
96
|
isLocalLib: false,
|
|
87
97
|
isDynamic: imp.isDynamic,
|
|
98
|
+
isSideEffect: imp.isSideEffect,
|
|
88
99
|
};
|
|
89
100
|
}
|
|
90
101
|
/** Resolves @/ alias and relative local imports from a source module. */
|
|
@@ -111,9 +122,13 @@ export function rewriteResolvedDependencyImports(fileContent, transformedDeps) {
|
|
|
111
122
|
start: dep.start,
|
|
112
123
|
end: dep.end,
|
|
113
124
|
expected: dep.full,
|
|
114
|
-
// A dynamic span covers only the quoted specifier
|
|
115
|
-
//
|
|
116
|
-
replacement: dep.
|
|
125
|
+
// A dynamic span covers only the quoted specifier, a side-effect span
|
|
126
|
+
// covers the bare import, and a static binding span covers `from "…"`.
|
|
127
|
+
replacement: dep.isSideEffect
|
|
128
|
+
? `import "${moduleUrl}"`
|
|
129
|
+
: dep.isDynamic
|
|
130
|
+
? `"${moduleUrl}"`
|
|
131
|
+
: `from "${moduleUrl}"`,
|
|
117
132
|
};
|
|
118
133
|
});
|
|
119
134
|
return replaceSourceSpans(fileContent, replacements);
|