@xfey/tutti 0.1.119 → 0.1.121

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.
Files changed (113) hide show
  1. package/dist/approvals/decision-command.d.ts +2 -2
  2. package/dist/collaboration-state/clarification-snapshot.d.ts +9 -9
  3. package/dist/collaboration-state/task-compile-context.d.ts +1 -1
  4. package/dist/control-plane/workflows/openai.d.ts +3 -4
  5. package/dist/control-plane/workflows/openai.js +3 -2
  6. package/dist/providers/openai/app-server/invocation-coordinator.d.ts +1 -0
  7. package/dist/providers/openai/app-server/invocation-coordinator.js +4 -1
  8. package/dist/providers/openai/app-server/invocation-deadline.d.ts +3 -0
  9. package/dist/providers/openai/app-server/invocation-deadline.js +15 -0
  10. package/dist/providers/openai/app-server/read-only-procedure.d.ts +4 -2
  11. package/dist/providers/openai/app-server/read-only-procedure.js +16 -0
  12. package/dist/providers/openai/app-server/workspace-write-run.d.ts +4 -2
  13. package/dist/providers/openai/app-server/workspace-write-run.js +16 -0
  14. package/dist/providers/openai/chat-assistant.d.ts +3 -4
  15. package/dist/providers/openai/chat-assistant.js +2 -1
  16. package/dist/providers/openai/execution-access.d.ts +17 -0
  17. package/dist/providers/openai/execution-access.js +13 -0
  18. package/dist/providers/openai/sdk-procedure-runner.d.ts +2 -2
  19. package/dist/providers/openai/sdk-procedure-runner.js +17 -0
  20. package/dist/run-pipeline/artifact-applicability.d.ts +3 -4
  21. package/dist/run-pipeline/artifact-applicability.js +2 -1
  22. package/dist/run-pipeline/openai.d.ts +3 -4
  23. package/dist/run-pipeline/openai.js +3 -2
  24. package/dist/run-pipeline/task-run-invocation.js +6 -12
  25. package/dist/server-shell/cli/cli.js +3 -0
  26. package/dist/server-shell/cli/host-lifecycle.js +1 -0
  27. package/dist/server-shell/cli/host-server-runtime.d.ts +1 -0
  28. package/dist/server-shell/cli/host-server-runtime.js +83 -34
  29. package/dist/server-shell/cli/launch-command.js +1 -1
  30. package/dist/server-shell/cli/launch.d.ts +7 -3
  31. package/dist/server-shell/cli/launch.js +23 -4
  32. package/dist/server-shell/cli/machine-local.d.ts +9 -0
  33. package/dist/server-shell/cli/machine-local.js +60 -6
  34. package/dist/server-shell/cli/project-resolver.d.ts +2 -2
  35. package/dist/server-shell/cli/project-resolver.js +6 -3
  36. package/dist/server-shell/cli/relay-registration.js +38 -1
  37. package/dist/server-shell/http/routes/local-control.d.ts +1 -1
  38. package/dist/server-shell/http/routes/local-control.js +2 -46
  39. package/dist/server-shell/http/routes/project-api/openapi-workspace-routes.d.ts +45 -137
  40. package/dist/server-shell/http/routes/project-api/openapi.d.ts +45 -137
  41. package/dist/server-shell/http/routes/project-api/schemas.d.ts +24 -136
  42. package/dist/server-shell/http/routes/project-api/schemas.js +4 -58
  43. package/dist/server-shell/http/routes/project-api/types.d.ts +3 -0
  44. package/dist/server-shell/local-console/managed-project-routes.d.ts +9 -0
  45. package/dist/server-shell/local-console/managed-project-routes.js +120 -0
  46. package/dist/server-shell/local-console/managed-project-service.d.ts +141 -0
  47. package/dist/server-shell/local-console/managed-project-service.js +158 -0
  48. package/dist/server-shell/local-console/operation-coordinator.d.ts +1 -1
  49. package/dist/server-shell/local-console/package-update-hosts.js +2 -1
  50. package/dist/server-shell/local-console/project-service.d.ts +4 -1
  51. package/dist/server-shell/local-console/project-service.js +62 -14
  52. package/dist/server-shell/local-console/server.js +22 -2
  53. package/dist/server-shell/managed-access/execution-binding.d.ts +9 -0
  54. package/dist/server-shell/managed-access/execution-binding.js +22 -0
  55. package/dist/server-shell/managed-access/existing-project.d.ts +15 -0
  56. package/dist/server-shell/managed-access/existing-project.js +41 -0
  57. package/dist/server-shell/managed-access/legacy-records.d.ts +2 -0
  58. package/dist/server-shell/managed-access/legacy-records.js +24 -0
  59. package/dist/server-shell/managed-access/model-control-client.d.ts +65 -0
  60. package/dist/server-shell/managed-access/model-control-client.js +112 -0
  61. package/dist/server-shell/managed-access/private-store.d.ts +19 -0
  62. package/dist/server-shell/managed-access/private-store.js +275 -0
  63. package/dist/server-shell/managed-access/project-provider.d.ts +18 -0
  64. package/dist/server-shell/managed-access/project-provider.js +30 -0
  65. package/dist/server-shell/managed-access/records.d.ts +103 -0
  66. package/dist/server-shell/managed-access/records.js +74 -0
  67. package/dist/server-shell/managed-access/runners.d.ts +11 -0
  68. package/dist/server-shell/managed-access/runners.js +103 -0
  69. package/dist/server-shell/managed-access/runtime-records.d.ts +106 -0
  70. package/dist/server-shell/managed-access/runtime-records.js +65 -0
  71. package/dist/server-shell/managed-access/runtime.d.ts +48 -0
  72. package/dist/server-shell/managed-access/runtime.js +300 -0
  73. package/dist/server-shell/managed-access/state.d.ts +53 -0
  74. package/dist/server-shell/managed-access/state.js +292 -0
  75. package/dist/server-shell/managed-access/transport.d.ts +45 -0
  76. package/dist/server-shell/managed-access/transport.js +39 -0
  77. package/dist/server-shell/managed-access/workspace.d.ts +10 -0
  78. package/dist/server-shell/managed-access/workspace.js +69 -0
  79. package/dist/server-shell/smoke/e2e-client.d.ts +8 -3
  80. package/dist/server-shell/smoke/e2e-client.js +11 -11
  81. package/node_modules/@tutti/relay-client/dist/host-control.d.ts +4 -1
  82. package/node_modules/@tutti/relay-client/dist/host-control.js +26 -3
  83. package/node_modules/@tutti/relay-client/dist/index.d.ts +1 -0
  84. package/node_modules/@tutti/relay-client/dist/index.js +1 -0
  85. package/node_modules/@tutti/relay-client/dist/project-authority.d.ts +70 -0
  86. package/node_modules/@tutti/relay-client/dist/project-authority.js +139 -0
  87. package/node_modules/@tutti/shared/dist/ids/index.d.ts +7 -0
  88. package/node_modules/@tutti/shared/dist/ids/index.js +7 -0
  89. package/node_modules/@tutti/shared/dist/schemas/api/index.d.ts +1 -0
  90. package/node_modules/@tutti/shared/dist/schemas/api/index.js +1 -0
  91. package/node_modules/@tutti/shared/dist/schemas/api/managed-account.d.ts +34 -0
  92. package/node_modules/@tutti/shared/dist/schemas/api/managed-account.js +40 -0
  93. package/node_modules/@tutti/shared/dist/schemas/api/provider-config.d.ts +7 -4
  94. package/node_modules/@tutti/shared/dist/schemas/api/provider-config.js +5 -0
  95. package/node_modules/@tutti/shared/dist/schemas/api/runtime-events.d.ts +3 -0
  96. package/node_modules/@tutti/shared/dist/schemas/internal/creation-validation.d.ts +26 -0
  97. package/node_modules/@tutti/shared/dist/schemas/internal/creation-validation.js +40 -0
  98. package/node_modules/@tutti/shared/dist/schemas/internal/index.d.ts +5 -0
  99. package/node_modules/@tutti/shared/dist/schemas/internal/index.js +5 -0
  100. package/node_modules/@tutti/shared/dist/schemas/internal/managed-account.d.ts +12 -0
  101. package/node_modules/@tutti/shared/dist/schemas/internal/managed-account.js +13 -0
  102. package/node_modules/@tutti/shared/dist/schemas/internal/managed-models.d.ts +17 -0
  103. package/node_modules/@tutti/shared/dist/schemas/internal/managed-models.js +17 -0
  104. package/node_modules/@tutti/shared/dist/schemas/internal/managed-runtime.d.ts +113 -0
  105. package/node_modules/@tutti/shared/dist/schemas/internal/managed-runtime.js +84 -0
  106. package/node_modules/@tutti/shared/dist/schemas/internal/project-authority.d.ts +114 -0
  107. package/node_modules/@tutti/shared/dist/schemas/internal/project-authority.js +102 -0
  108. package/package.json +1 -1
  109. package/web/assets/{homepage-motion-scene-B6lCCHBq.js → homepage-motion-scene-WfLyzcCG.js} +1 -1
  110. package/web/assets/{index-DsYi7AhN.css → index-ATsYiBZs.css} +1 -1
  111. package/web/assets/index-o9YCtzEd.js +70 -0
  112. package/web/index.html +2 -2
  113. package/web/assets/index-DepsYMLl.js +0 -70
@@ -0,0 +1,113 @@
1
+ import { type Static } from "@sinclair/typebox";
2
+ export declare const ManagedDelegationScopeFields: {
3
+ account_ref: import("@sinclair/typebox").TString;
4
+ relay_project_ref: import("@sinclair/typebox").TString;
5
+ delegation_ref: import("@sinclair/typebox").TString;
6
+ grant_ref: import("@sinclair/typebox").TString;
7
+ installation_ref: import("@sinclair/typebox").TString;
8
+ };
9
+ export declare const ManagedRuntimeAuthoritySchema: import("@sinclair/typebox").TObject<{
10
+ funding_kind: import("@sinclair/typebox").TLiteral<"trial">;
11
+ account_ref: import("@sinclair/typebox").TString;
12
+ relay_project_ref: import("@sinclair/typebox").TString;
13
+ delegation_ref: import("@sinclair/typebox").TString;
14
+ grant_ref: import("@sinclair/typebox").TString;
15
+ installation_ref: import("@sinclair/typebox").TString;
16
+ issuer: import("@sinclair/typebox").TString;
17
+ nonce: import("@sinclair/typebox").TString;
18
+ issued_at: import("@sinclair/typebox").TInteger;
19
+ expires_at: import("@sinclair/typebox").TInteger;
20
+ version: import("@sinclair/typebox").TLiteral<3>;
21
+ audience: import("@sinclair/typebox").TLiteral<"tutti-managed-runtime">;
22
+ }>;
23
+ export type ManagedRuntimeAuthority = Static<typeof ManagedRuntimeAuthoritySchema>;
24
+ export declare const ManagedRevocationAuthoritySchema: import("@sinclair/typebox").TObject<{
25
+ account_ref: import("@sinclair/typebox").TString;
26
+ relay_project_ref: import("@sinclair/typebox").TString;
27
+ delegation_ref: import("@sinclair/typebox").TString;
28
+ grant_ref: import("@sinclair/typebox").TString;
29
+ installation_ref: import("@sinclair/typebox").TString;
30
+ issuer: import("@sinclair/typebox").TString;
31
+ nonce: import("@sinclair/typebox").TString;
32
+ issued_at: import("@sinclair/typebox").TInteger;
33
+ expires_at: import("@sinclair/typebox").TInteger;
34
+ version: import("@sinclair/typebox").TLiteral<1>;
35
+ audience: import("@sinclair/typebox").TLiteral<"tutti-managed-revocation">;
36
+ }>;
37
+ export type ManagedRevocationAuthority = Static<typeof ManagedRevocationAuthoritySchema>;
38
+ export declare const NativeRuntimeAuthorizationSchema: import("@sinclair/typebox").TObject<{
39
+ authorization: import("@sinclair/typebox").TString;
40
+ expires_at: import("@sinclair/typebox").TInteger;
41
+ control_origin: import("@sinclair/typebox").TString;
42
+ delegation_ref: import("@sinclair/typebox").TString;
43
+ }>;
44
+ export declare const ManagedRuntimeSessionRefSchema: import("@sinclair/typebox").TString;
45
+ export declare const ManagedRuntimeCredentialRefSchema: import("@sinclair/typebox").TString;
46
+ export declare const ManagedRouteRefSchema: import("@sinclair/typebox").TString;
47
+ export declare const ManagedProviderIdentitySchema: import("@sinclair/typebox").TObject<{
48
+ base_url: import("@sinclair/typebox").TString;
49
+ model: import("@sinclair/typebox").TString;
50
+ }>;
51
+ export declare const ManagedSessionResultSchema: import("@sinclair/typebox").TObject<{
52
+ session_ref: import("@sinclair/typebox").TString;
53
+ route_ref: import("@sinclair/typebox").TString;
54
+ disposition: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"created">, import("@sinclair/typebox").TLiteral<"existing">]>;
55
+ provider: import("@sinclair/typebox").TObject<{
56
+ base_url: import("@sinclair/typebox").TString;
57
+ model: import("@sinclair/typebox").TString;
58
+ }>;
59
+ }>;
60
+ export declare const ManagedCredentialProjectionSchema: import("@sinclair/typebox").TObject<{
61
+ credential_ref: import("@sinclair/typebox").TString;
62
+ session_ref: import("@sinclair/typebox").TString;
63
+ device_ref: import("@sinclair/typebox").TString;
64
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"creating">, import("@sinclair/typebox").TLiteral<"active">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoking">, import("@sinclair/typebox").TLiteral<"revoked">]>;
65
+ expires_at: import("@sinclair/typebox").TInteger;
66
+ quota_cap: import("@sinclair/typebox").TInteger;
67
+ }>;
68
+ export declare const ManagedProviderCredentialSchema: import("@sinclair/typebox").TObject<{
69
+ base_url: import("@sinclair/typebox").TString;
70
+ model: import("@sinclair/typebox").TString;
71
+ api_key: import("@sinclair/typebox").TString;
72
+ }>;
73
+ export declare const ManagedCredentialIssueResultSchema: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
74
+ disposition: import("@sinclair/typebox").TLiteral<"issued">;
75
+ credential: import("@sinclair/typebox").TObject<{
76
+ credential_ref: import("@sinclair/typebox").TString;
77
+ session_ref: import("@sinclair/typebox").TString;
78
+ device_ref: import("@sinclair/typebox").TString;
79
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"creating">, import("@sinclair/typebox").TLiteral<"active">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoking">, import("@sinclair/typebox").TLiteral<"revoked">]>;
80
+ expires_at: import("@sinclair/typebox").TInteger;
81
+ quota_cap: import("@sinclair/typebox").TInteger;
82
+ }>;
83
+ route_ref: import("@sinclair/typebox").TString;
84
+ provider: import("@sinclair/typebox").TObject<{
85
+ base_url: import("@sinclair/typebox").TString;
86
+ model: import("@sinclair/typebox").TString;
87
+ api_key: import("@sinclair/typebox").TString;
88
+ }>;
89
+ }>, import("@sinclair/typebox").TObject<{
90
+ disposition: import("@sinclair/typebox").TLiteral<"already_issued">;
91
+ credential: import("@sinclair/typebox").TObject<{
92
+ credential_ref: import("@sinclair/typebox").TString;
93
+ session_ref: import("@sinclair/typebox").TString;
94
+ device_ref: import("@sinclair/typebox").TString;
95
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"creating">, import("@sinclair/typebox").TLiteral<"active">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoking">, import("@sinclair/typebox").TLiteral<"revoked">]>;
96
+ expires_at: import("@sinclair/typebox").TInteger;
97
+ quota_cap: import("@sinclair/typebox").TInteger;
98
+ }>;
99
+ }>]>;
100
+ export declare const ManagedCredentialRevokeResultSchema: import("@sinclair/typebox").TObject<{
101
+ disposition: import("@sinclair/typebox").TLiteral<"revoked">;
102
+ credential: import("@sinclair/typebox").TObject<{
103
+ credential_ref: import("@sinclair/typebox").TString;
104
+ session_ref: import("@sinclair/typebox").TString;
105
+ device_ref: import("@sinclair/typebox").TString;
106
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"creating">, import("@sinclair/typebox").TLiteral<"active">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoking">, import("@sinclair/typebox").TLiteral<"revoked">]>;
107
+ expires_at: import("@sinclair/typebox").TInteger;
108
+ quota_cap: import("@sinclair/typebox").TInteger;
109
+ }>;
110
+ }>;
111
+ export type ManagedProviderCredential = Static<typeof ManagedProviderCredentialSchema>;
112
+ export type ManagedCredentialProjection = Static<typeof ManagedCredentialProjectionSchema>;
113
+ //# sourceMappingURL=managed-runtime.d.ts.map
@@ -0,0 +1,84 @@
1
+ import { Type } from "@sinclair/typebox";
2
+ import { ID_PREFIXES, ULID_BODY_PATTERN } from "../../ids/index.js";
3
+ import { RelayAccountRefSchema, RelayProjectRefSchema, IdempotencyKeySchema, } from "../domain/index.js";
4
+ import { HostDelegationRefSchema, HostInstallationRefSchema, ProjectModelGrantRefSchema, } from "./project-authority.js";
5
+ export const ManagedDelegationScopeFields = {
6
+ account_ref: RelayAccountRefSchema,
7
+ relay_project_ref: RelayProjectRefSchema,
8
+ delegation_ref: HostDelegationRefSchema,
9
+ grant_ref: ProjectModelGrantRefSchema,
10
+ installation_ref: HostInstallationRefSchema,
11
+ };
12
+ const CapabilityFields = {
13
+ issuer: Type.String({ minLength: 1, maxLength: 200 }),
14
+ nonce: IdempotencyKeySchema,
15
+ issued_at: Type.Integer({ minimum: 0 }),
16
+ expires_at: Type.Integer({ minimum: 0 }),
17
+ };
18
+ export const ManagedRuntimeAuthoritySchema = Type.Object({
19
+ version: Type.Literal(3),
20
+ audience: Type.Literal("tutti-managed-runtime"),
21
+ ...CapabilityFields,
22
+ ...ManagedDelegationScopeFields,
23
+ funding_kind: Type.Literal("trial"),
24
+ }, { additionalProperties: false });
25
+ // Operator/service control only; never issued to native or browser callers.
26
+ export const ManagedRevocationAuthoritySchema = Type.Object({
27
+ version: Type.Literal(1),
28
+ audience: Type.Literal("tutti-managed-revocation"),
29
+ ...CapabilityFields,
30
+ ...ManagedDelegationScopeFields,
31
+ }, { additionalProperties: false });
32
+ export const NativeRuntimeAuthorizationSchema = Type.Object({
33
+ authorization: Type.String({
34
+ pattern: "^tma3\\.[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]{86}$",
35
+ maxLength: 3500,
36
+ }),
37
+ expires_at: Type.Integer({ minimum: 0 }),
38
+ control_origin: Type.String({ minLength: 1, maxLength: 500 }),
39
+ delegation_ref: HostDelegationRefSchema,
40
+ }, { additionalProperties: false });
41
+ const managedId = (prefix) => Type.String({ pattern: `^${prefix}${ULID_BODY_PATTERN}$` });
42
+ export const ManagedRuntimeSessionRefSchema = managedId(ID_PREFIXES.managedSession);
43
+ export const ManagedRuntimeCredentialRefSchema = managedId(ID_PREFIXES.managedCredential);
44
+ export const ManagedRouteRefSchema = Type.String({ pattern: "^[a-z0-9][a-z0-9-]{1,60}$" });
45
+ export const ManagedProviderIdentitySchema = Type.Object({
46
+ base_url: Type.String({ minLength: 1, maxLength: 500 }),
47
+ model: Type.String({ pattern: "^tutti-[a-z0-9-]{1,80}$" }),
48
+ }, { additionalProperties: false });
49
+ export const ManagedSessionResultSchema = Type.Object({
50
+ session_ref: ManagedRuntimeSessionRefSchema,
51
+ route_ref: ManagedRouteRefSchema,
52
+ disposition: Type.Union([Type.Literal("created"), Type.Literal("existing")]),
53
+ provider: ManagedProviderIdentitySchema,
54
+ }, { additionalProperties: false });
55
+ export const ManagedCredentialProjectionSchema = Type.Object({
56
+ credential_ref: ManagedRuntimeCredentialRefSchema,
57
+ session_ref: ManagedRuntimeSessionRefSchema,
58
+ device_ref: managedId(ID_PREFIXES.managedDevice),
59
+ state: Type.Union([
60
+ Type.Literal("creating"),
61
+ Type.Literal("active"),
62
+ Type.Literal("expired"),
63
+ Type.Literal("revoking"),
64
+ Type.Literal("revoked"),
65
+ ]),
66
+ expires_at: Type.Integer({ minimum: 0 }),
67
+ quota_cap: Type.Integer({ minimum: 1 }),
68
+ }, { additionalProperties: false });
69
+ export const ManagedProviderCredentialSchema = Type.Object({
70
+ base_url: Type.String({ minLength: 1, maxLength: 500 }),
71
+ model: Type.String({ pattern: "^tutti-[a-z0-9-]{1,80}$" }),
72
+ api_key: Type.String({ minLength: 16, maxLength: 1024, pattern: "^[^\\s]+$" }),
73
+ }, { additionalProperties: false });
74
+ export const ManagedCredentialIssueResultSchema = Type.Union([
75
+ Type.Object({
76
+ disposition: Type.Literal("issued"),
77
+ credential: ManagedCredentialProjectionSchema,
78
+ route_ref: ManagedRouteRefSchema,
79
+ provider: ManagedProviderCredentialSchema,
80
+ }, { additionalProperties: false }),
81
+ Type.Object({ disposition: Type.Literal("already_issued"), credential: ManagedCredentialProjectionSchema }, { additionalProperties: false }),
82
+ ]);
83
+ export const ManagedCredentialRevokeResultSchema = Type.Object({ disposition: Type.Literal("revoked"), credential: ManagedCredentialProjectionSchema }, { additionalProperties: false });
84
+ //# sourceMappingURL=managed-runtime.js.map
@@ -0,0 +1,114 @@
1
+ import { type Static } from "@sinclair/typebox";
2
+ export declare const ManagedCreationRefSchema: import("@sinclair/typebox").TString;
3
+ export declare const HostInstallationRefSchema: import("@sinclair/typebox").TString;
4
+ export declare const HostDelegationRefSchema: import("@sinclair/typebox").TString;
5
+ export declare const ProjectModelGrantRefSchema: import("@sinclair/typebox").TString;
6
+ export declare const AuthoritySecretSchema: import("@sinclair/typebox").TString;
7
+ export declare const AuthoritySecretHashSchema: import("@sinclair/typebox").TString;
8
+ export declare const AuthorityTimestampSchema: import("@sinclair/typebox").TString;
9
+ export declare function isAuthorityTimestamp(value: string): boolean;
10
+ export declare const PROJECT_TRIAL_POLICY = "trial-project-v1";
11
+ export declare const PrepareProjectAuthoritySchema: import("@sinclair/typebox").TObject<{
12
+ request_ref: import("@sinclair/typebox").TString;
13
+ project_id: import("@sinclair/typebox").TString;
14
+ surface: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"standalone">, import("@sinclair/typebox").TLiteral<"feishu">]>;
15
+ existing_relay_project_ref: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
16
+ installation_ref: import("@sinclair/typebox").TString;
17
+ installation_secret_hash: import("@sinclair/typebox").TString;
18
+ handoff_token_hash: import("@sinclair/typebox").TString;
19
+ host_registration_secret_hash: import("@sinclair/typebox").TString;
20
+ trial_consent: import("@sinclair/typebox").TLiteral<"trial-project-v1">;
21
+ expires_before: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
22
+ }>;
23
+ export type PrepareProjectAuthority = Static<typeof PrepareProjectAuthoritySchema>;
24
+ export declare const ManagedProjectBootstrapSchema: import("@sinclair/typebox").TObject<{
25
+ kind: import("@sinclair/typebox").TLiteral<"managed_project_authority_v2">;
26
+ creation_ref: import("@sinclair/typebox").TString;
27
+ handoff_token: import("@sinclair/typebox").TString;
28
+ installation_ref: import("@sinclair/typebox").TString;
29
+ installation_secret: import("@sinclair/typebox").TString;
30
+ }>;
31
+ export type ManagedProjectBootstrap = Static<typeof ManagedProjectBootstrapSchema>;
32
+ export declare const HostDelegationStatusBodySchema: import("@sinclair/typebox").TObject<{
33
+ delegation_ref: import("@sinclair/typebox").TString;
34
+ installation_ref: import("@sinclair/typebox").TString;
35
+ installation_secret: import("@sinclair/typebox").TString;
36
+ relay_project_ref: import("@sinclair/typebox").TString;
37
+ project_id: import("@sinclair/typebox").TString;
38
+ host_registration_secret: import("@sinclair/typebox").TString;
39
+ }>;
40
+ export type HostDelegationStatusBody = Static<typeof HostDelegationStatusBodySchema>;
41
+ export declare const HostDelegationProjectionSchema: import("@sinclair/typebox").TObject<{
42
+ delegation_ref: import("@sinclair/typebox").TString;
43
+ grant_ref: import("@sinclair/typebox").TString;
44
+ relay_project_ref: import("@sinclair/typebox").TString;
45
+ installation_ref: import("@sinclair/typebox").TString;
46
+ funding_kind: import("@sinclair/typebox").TLiteral<"trial">;
47
+ expires_at: import("@sinclair/typebox").TNull;
48
+ state: import("@sinclair/typebox").TLiteral<"active">;
49
+ model_access: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"runtime_authority_required">, import("@sinclair/typebox").TLiteral<"not_enabled">]>;
50
+ }>;
51
+ export type HostDelegationProjection = Static<typeof HostDelegationProjectionSchema>;
52
+ export declare const ManagedCreationProjectionSchema: import("@sinclair/typebox").TObject<{
53
+ creation_ref: import("@sinclair/typebox").TString;
54
+ project_id: import("@sinclair/typebox").TString;
55
+ surface: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"standalone">, import("@sinclair/typebox").TLiteral<"feishu">]>;
56
+ installation_ref: import("@sinclair/typebox").TString;
57
+ expires_at: import("@sinclair/typebox").TString;
58
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"prepared">, import("@sinclair/typebox").TLiteral<"activated">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoked">]>;
59
+ relay_project_ref: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
60
+ }>;
61
+ export type ManagedCreationProjection = Static<typeof ManagedCreationProjectionSchema>;
62
+ export declare const NativeCreationProofSchema: import("@sinclair/typebox").TObject<{
63
+ request_ref: import("@sinclair/typebox").TString;
64
+ project_id: import("@sinclair/typebox").TString;
65
+ installation_ref: import("@sinclair/typebox").TString;
66
+ installation_secret: import("@sinclair/typebox").TString;
67
+ handoff_token: import("@sinclair/typebox").TString;
68
+ host_registration_secret: import("@sinclair/typebox").TString;
69
+ }>;
70
+ export type NativeCreationProof = Static<typeof NativeCreationProofSchema>;
71
+ export declare const NativeCreationStatusSchema: import("@sinclair/typebox").TObject<{
72
+ request_ref: import("@sinclair/typebox").TString;
73
+ account_ref: import("@sinclair/typebox").TString;
74
+ creation: import("@sinclair/typebox").TObject<{
75
+ creation_ref: import("@sinclair/typebox").TString;
76
+ project_id: import("@sinclair/typebox").TString;
77
+ surface: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"standalone">, import("@sinclair/typebox").TLiteral<"feishu">]>;
78
+ installation_ref: import("@sinclair/typebox").TString;
79
+ expires_at: import("@sinclair/typebox").TString;
80
+ state: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"prepared">, import("@sinclair/typebox").TLiteral<"activated">, import("@sinclair/typebox").TLiteral<"expired">, import("@sinclair/typebox").TLiteral<"revoked">]>;
81
+ relay_project_ref: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
82
+ }>;
83
+ authority: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
84
+ delegation_ref: import("@sinclair/typebox").TString;
85
+ grant_ref: import("@sinclair/typebox").TString;
86
+ relay_project_ref: import("@sinclair/typebox").TString;
87
+ installation_ref: import("@sinclair/typebox").TString;
88
+ funding_kind: import("@sinclair/typebox").TLiteral<"trial">;
89
+ expires_at: import("@sinclair/typebox").TNull;
90
+ state: import("@sinclair/typebox").TLiteral<"active">;
91
+ model_access: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"runtime_authority_required">, import("@sinclair/typebox").TLiteral<"not_enabled">]>;
92
+ }>>;
93
+ }>;
94
+ export type NativeCreationStatus = Static<typeof NativeCreationStatusSchema>;
95
+ export declare const isManagedProjectBootstrap: (value: unknown) => value is ManagedProjectBootstrap;
96
+ export declare const isHostDelegationProjection: (value: unknown) => value is HostDelegationProjection;
97
+ export declare const RevokeProjectAuthoritySchema: import("@sinclair/typebox").TObject<{
98
+ command_id: import("@sinclair/typebox").TString;
99
+ target: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
100
+ kind: import("@sinclair/typebox").TLiteral<"grant">;
101
+ ref: import("@sinclair/typebox").TString;
102
+ }>, import("@sinclair/typebox").TObject<{
103
+ kind: import("@sinclair/typebox").TLiteral<"delegation">;
104
+ ref: import("@sinclair/typebox").TString;
105
+ }>, import("@sinclair/typebox").TObject<{
106
+ kind: import("@sinclair/typebox").TLiteral<"installation">;
107
+ ref: import("@sinclair/typebox").TString;
108
+ }>, import("@sinclair/typebox").TObject<{
109
+ kind: import("@sinclair/typebox").TLiteral<"creation">;
110
+ ref: import("@sinclair/typebox").TString;
111
+ }>]>;
112
+ }>;
113
+ export type RevokeProjectAuthority = Static<typeof RevokeProjectAuthoritySchema>;
114
+ //# sourceMappingURL=project-authority.d.ts.map
@@ -0,0 +1,102 @@
1
+ import { Type } from "@sinclair/typebox";
2
+ import { Value } from "@sinclair/typebox/value";
3
+ import { ID_PREFIXES, ULID_BODY_PATTERN } from "../../ids/index.js";
4
+ import { IdempotencyKeySchema, ProjectIdSchema, RelayProjectRefSchema, RelayAccountRefSchema, } from "../domain/index.js";
5
+ const id = (prefix) => Type.String({ pattern: `^${prefix}${ULID_BODY_PATTERN}$` });
6
+ export const ManagedCreationRefSchema = id(ID_PREFIXES.managedCreation);
7
+ export const HostInstallationRefSchema = id(ID_PREFIXES.hostInstallation);
8
+ export const HostDelegationRefSchema = id(ID_PREFIXES.hostDelegation);
9
+ export const ProjectModelGrantRefSchema = id(ID_PREFIXES.projectModelGrant);
10
+ export const AuthoritySecretSchema = Type.String({ pattern: "^[A-Za-z0-9_-]{43}$" });
11
+ export const AuthoritySecretHashSchema = Type.String({ pattern: "^sha256:[a-f0-9]{64}$" });
12
+ export const AuthorityTimestampSchema = Type.String({
13
+ pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
14
+ });
15
+ export function isAuthorityTimestamp(value) {
16
+ const time = Date.parse(value);
17
+ return Number.isFinite(time) && new Date(time).toISOString() === value;
18
+ }
19
+ export const PROJECT_TRIAL_POLICY = "trial-project-v1";
20
+ // Preparation creates no model credential or project truth. Native secrets never go to Web.
21
+ export const PrepareProjectAuthoritySchema = Type.Object({
22
+ request_ref: IdempotencyKeySchema,
23
+ project_id: ProjectIdSchema,
24
+ surface: Type.Union([Type.Literal("standalone"), Type.Literal("feishu")]),
25
+ existing_relay_project_ref: Type.Optional(RelayProjectRefSchema),
26
+ installation_ref: HostInstallationRefSchema,
27
+ installation_secret_hash: AuthoritySecretHashSchema,
28
+ handoff_token_hash: AuthoritySecretHashSchema,
29
+ host_registration_secret_hash: AuthoritySecretHashSchema,
30
+ trial_consent: Type.Literal(PROJECT_TRIAL_POLICY),
31
+ expires_before: Type.Optional(AuthorityTimestampSchema),
32
+ }, { additionalProperties: false });
33
+ export const ManagedProjectBootstrapSchema = Type.Object({
34
+ kind: Type.Literal("managed_project_authority_v2"),
35
+ creation_ref: ManagedCreationRefSchema,
36
+ handoff_token: AuthoritySecretSchema,
37
+ installation_ref: HostInstallationRefSchema,
38
+ installation_secret: AuthoritySecretSchema,
39
+ }, { additionalProperties: false });
40
+ export const HostDelegationStatusBodySchema = Type.Object({
41
+ delegation_ref: HostDelegationRefSchema,
42
+ installation_ref: HostInstallationRefSchema,
43
+ installation_secret: AuthoritySecretSchema,
44
+ relay_project_ref: RelayProjectRefSchema,
45
+ project_id: ProjectIdSchema,
46
+ host_registration_secret: Type.String({ minLength: 32, maxLength: 256 }),
47
+ }, { additionalProperties: false });
48
+ export const HostDelegationProjectionSchema = Type.Object({
49
+ delegation_ref: HostDelegationRefSchema,
50
+ grant_ref: ProjectModelGrantRefSchema,
51
+ relay_project_ref: RelayProjectRefSchema,
52
+ installation_ref: HostInstallationRefSchema,
53
+ funding_kind: Type.Literal("trial"),
54
+ expires_at: Type.Null(),
55
+ state: Type.Literal("active"),
56
+ // not_enabled remains readable for pre-runtime private journals. Neither value
57
+ // is a health/quota promise; every invocation still needs live native authority.
58
+ model_access: Type.Union([
59
+ Type.Literal("runtime_authority_required"),
60
+ Type.Literal("not_enabled"),
61
+ ]),
62
+ }, { additionalProperties: false });
63
+ export const ManagedCreationProjectionSchema = Type.Object({
64
+ creation_ref: ManagedCreationRefSchema,
65
+ project_id: ProjectIdSchema,
66
+ surface: Type.Union([Type.Literal("standalone"), Type.Literal("feishu")]),
67
+ installation_ref: HostInstallationRefSchema,
68
+ expires_at: AuthorityTimestampSchema,
69
+ state: Type.Union([
70
+ Type.Literal("prepared"),
71
+ Type.Literal("activated"),
72
+ Type.Literal("expired"),
73
+ Type.Literal("revoked"),
74
+ ]),
75
+ relay_project_ref: Type.Optional(RelayProjectRefSchema),
76
+ }, { additionalProperties: false });
77
+ export const NativeCreationProofSchema = Type.Object({
78
+ request_ref: IdempotencyKeySchema,
79
+ project_id: ProjectIdSchema,
80
+ installation_ref: HostInstallationRefSchema,
81
+ installation_secret: AuthoritySecretSchema,
82
+ handoff_token: AuthoritySecretSchema,
83
+ host_registration_secret: Type.String({ minLength: 32, maxLength: 256 }),
84
+ }, { additionalProperties: false });
85
+ export const NativeCreationStatusSchema = Type.Object({
86
+ request_ref: IdempotencyKeySchema,
87
+ account_ref: RelayAccountRefSchema,
88
+ creation: ManagedCreationProjectionSchema,
89
+ authority: Type.Optional(HostDelegationProjectionSchema),
90
+ }, { additionalProperties: false });
91
+ export const isManagedProjectBootstrap = (value) => Value.Check(ManagedProjectBootstrapSchema, value);
92
+ export const isHostDelegationProjection = (value) => Value.Check(HostDelegationProjectionSchema, value);
93
+ export const RevokeProjectAuthoritySchema = Type.Object({
94
+ command_id: IdempotencyKeySchema,
95
+ target: Type.Union([
96
+ Type.Object({ kind: Type.Literal("grant"), ref: ProjectModelGrantRefSchema }, { additionalProperties: false }),
97
+ Type.Object({ kind: Type.Literal("delegation"), ref: HostDelegationRefSchema }, { additionalProperties: false }),
98
+ Type.Object({ kind: Type.Literal("installation"), ref: HostInstallationRefSchema }, { additionalProperties: false }),
99
+ Type.Object({ kind: Type.Literal("creation"), ref: ManagedCreationRefSchema }, { additionalProperties: false }),
100
+ ]),
101
+ }, { additionalProperties: false });
102
+ //# sourceMappingURL=project-authority.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xfey/tutti",
3
- "version": "0.1.119",
3
+ "version": "0.1.121",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -1 +1 @@
1
- import{C as e,S as t,_ as n,a as r,b as i,c as a,d as o,f as s,g as c,h as l,i as u,l as d,m as f,n as p,o as m,p as h,r as g,s as _,t as v,u as y,v as b,w as x,x as S,y as C}from"./index-DepsYMLl.js";var w=e(`mouse-pointer-2`,[[`path`,{d:`M4.037 4.688a.495.495 0 0 1 .651-.651l16 6.5a.5.5 0 0 1-.063.947l-6.124 1.58a2 2 0 0 0-1.438 1.435l-1.579 6.126a.5.5 0 0 1-.947.063z`,key:`edeuup`}]]),T=e(`send`,[[`path`,{d:`M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z`,key:`1ffxy3`}],[`path`,{d:`m21.854 2.147-10.94 10.939`,key:`12cjpa`}]]),E=x();function D(e){return{"--reveal":e}}function O(e,t,n){let r=(e,t)=>Number.parseInt(e.slice(t,t+2),16),i=i=>Math.round(r(e,i)+(r(t,i)-r(e,i))*n).toString(16).padStart(2,`0`);return`#${i(1)}${i(3)}${i(5)}`}function k(e){let t=r((e-p.runEnd)/(p.executionComplete-p.runEnd));return t+t*t-t*t*t}function A({progress:e,children:t,className:n=``}){return(0,E.jsx)(`div`,{className:`scene-reveal ${n}`,style:D(e),children:t})}function j({progress:e,author:t,avatar:n,tone:r,timestamp:i,online:a=!1,assets:o,children:s}){return(0,E.jsxs)(`article`,{className:`scene-message`,style:D(e),children:[(0,E.jsx)(`span`,{className:`scene-avatar is-${r} ${n===`tutti`?`is-tutti`:``} ${a?`is-online`:``}`,"aria-hidden":`true`,children:n===`tutti`?(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:o.tuttiAvatarSrc,alt:``}):(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:o.humanAvatars[n],alt:``})}),(0,E.jsxs)(`div`,{className:`scene-message-copy`,children:[(0,E.jsxs)(`header`,{children:[(0,E.jsx)(`strong`,{children:t}),(0,E.jsx)(`span`,{children:i})]}),(0,E.jsx)(`p`,{children:s})]})]})}function M({time:e,assets:r}){let i=e>=p.artifactLive,a=e>=p.artifactClick,o=e>=p.runEnd&&e<p.executionComplete,u=d(e,p.runEnd,19.2),f=d(e,p.artifactLive,30.92);return(0,E.jsxs)(`aside`,{className:`scene-sidebar`,children:[(0,E.jsx)(`button`,{className:`scene-brand`,type:`button`,"aria-label":`Tutti`,tabIndex:-1,children:(0,E.jsx)(`img`,{src:r.logoSrc,alt:``})}),(0,E.jsxs)(`div`,{className:`scene-nav-stack`,children:[(0,E.jsxs)(`nav`,{className:`scene-nav`,"aria-label":`Workspace pages`,children:[(0,E.jsx)(`button`,{className:a?``:`is-active`,type:`button`,"aria-label":`Chat`,tabIndex:-1,children:(0,E.jsx)(c,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Worklist`,tabIndex:-1,children:(0,E.jsx)(b,{"aria-hidden":`true`})}),(0,E.jsxs)(`button`,{className:a?`is-active`:``,type:`button`,"aria-label":`Artifacts`,tabIndex:-1,children:[(0,E.jsx)(l,{"aria-hidden":`true`}),i?(0,E.jsx)(`span`,{className:`scene-live-pill`,style:D(f),children:`Live`}):null]}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`References`,tabIndex:-1,children:(0,E.jsx)(C,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Skills`,tabIndex:-1,children:(0,E.jsx)(s,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Timeline`,tabIndex:-1,children:(0,E.jsx)(t,{"aria-hidden":`true`})})]}),o?(0,E.jsx)(`button`,{className:`scene-status-entry is-running`,style:D(u),type:`button`,"aria-label":`Task running`,tabIndex:-1,children:(0,E.jsx)(n,{"aria-hidden":`true`})}):null]}),(0,E.jsx)(`button`,{className:`scene-settings`,type:`button`,"aria-label":`Settings`,tabIndex:-1,children:(0,E.jsx)(h,{"aria-hidden":`true`})})]})}function N({time:e,assets:t}){let n=d(e,30.35,30.92);return(0,E.jsxs)(`section`,{className:`scene-panel scene-chat-panel`,children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(c,{"aria-hidden":`true`})}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`h2`,{children:`Morrow Studio`}),(0,E.jsx)(`p`,{children:`Ceramics storefront`})]}),(0,E.jsxs)(`span`,{className:`scene-members`,"aria-hidden":`true`,children:[(0,E.jsx)(`i`,{className:`is-green`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.fey,alt:``})}),(0,E.jsx)(`i`,{className:`is-blue`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.avery,alt:``})}),(0,E.jsx)(`i`,{className:`is-yellow`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.jun,alt:``})})]})]}),(0,E.jsxs)(`div`,{className:`scene-chat-stream`,children:[(0,E.jsx)(j,{progress:d(e,1.35,2.05),author:`Fey`,avatar:`fey`,tone:`green`,timestamp:`10:12`,online:!0,assets:t,children:`🏺 Let's build an online shop for our ceramics studio.`}),(0,E.jsx)(j,{progress:d(e,2.65,3.35),author:`Avery`,avatar:`avery`,tone:`blue`,timestamp:`10:13`,online:!0,assets:t,children:`✨ Keep it warm, minimal, and editorial.`}),(0,E.jsx)(j,{progress:d(e,3.95,4.65),author:`Jun`,avatar:`jun`,tone:`yellow`,timestamp:`10:14`,online:!0,assets:t,children:`🎨 Let people preview every piece in different glazes.`}),(0,E.jsx)(j,{progress:d(e,5.25,5.95),author:`Tutti`,avatar:`tutti`,tone:`green`,timestamp:`10:15`,assets:t,children:`Got it — I'll put it together. ✨`}),(0,E.jsxs)(`article`,{className:`scene-task-result`,style:D(n),children:[(0,E.jsx)(`span`,{className:`scene-task-result-rail`,"aria-hidden":`true`}),(0,E.jsx)(`span`,{className:`scene-task-result-icon`,"aria-hidden":`true`,children:(0,E.jsx)(S,{})}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`span`,{children:`Task completed`}),(0,E.jsx)(`strong`,{children:`Build ceramics storefront`}),(0,E.jsx)(`small`,{children:`Storefront`}),(0,E.jsx)(`p`,{children:`Warm editorial shopping and glaze previews are ready in Artifacts.`})]}),(0,E.jsx)(i,{className:`scene-task-result-chevron`,"aria-hidden":`true`})]})]}),(0,E.jsxs)(`div`,{className:`scene-composer`,"aria-hidden":`true`,children:[(0,E.jsx)(`span`,{children:`Write a message`}),(0,E.jsx)(T,{})]})]})}function P({progress:e,icon:t,children:n}){return(0,E.jsxs)(`div`,{className:`scene-scratchpad-row`,style:D(e),children:[(0,E.jsx)(`span`,{"aria-hidden":`true`,children:t}),(0,E.jsx)(`p`,{children:n})]})}function F({time:e}){return(0,E.jsxs)(`section`,{className:`scene-panel scene-scratchpad-panel`,style:{"--scratchpad-collapse":d(e,p.runEnd,19.18)},children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(v,{"aria-hidden":`true`})}),(0,E.jsx)(`h2`,{children:`Scratchpad`})]}),(0,E.jsxs)(`div`,{className:`scene-scratchpad-body`,children:[(0,E.jsxs)(A,{progress:d(e,8.95,10),className:`scene-scratchpad-intro`,children:[(0,E.jsx)(`h3`,{children:`Ceramics storefront`}),(0,E.jsx)(`p`,{children:`A warm, editorial storefront for a small-batch studio, centered on tactile product discovery.`})]}),(0,E.jsx)(A,{progress:d(e,9.85,10.65),className:`scene-scratchpad-label`,children:`Confirmed`}),(0,E.jsx)(P,{progress:d(e,10.4,11.25),icon:(0,E.jsx)(S,{}),children:`Product-first editorial layout with generous space`}),(0,E.jsx)(P,{progress:d(e,11.2,12.05),icon:(0,E.jsx)(S,{}),children:`Warm neutrals with quiet serif headlines`}),(0,E.jsx)(P,{progress:d(e,12,12.85),icon:(0,E.jsx)(S,{}),children:`Keep the collection small, curated, and story-led`}),(0,E.jsx)(A,{progress:d(e,12.75,13.55),className:`scene-scratchpad-label`,children:`Requested feature`}),(0,E.jsx)(P,{progress:d(e,13.3,14.2),icon:(0,E.jsx)(o,{}),children:`Preview every piece in clay, sage, and ink glazes`})]}),(0,E.jsxs)(`footer`,{className:`scene-scratchpad-footer`,style:D(d(e,15.7,16.8)),children:[(0,E.jsxs)(`span`,{className:`scene-writing-mark`,children:[(0,E.jsx)(`strong`,{children:`Updated`}),(0,E.jsx)(`span`,{children:`just now`})]}),(0,E.jsxs)(`button`,{className:`scene-run-button`,type:`button`,tabIndex:-1,children:[(0,E.jsx)(f,{"aria-hidden":`true`}),(0,E.jsx)(`span`,{children:`Run`})]})]})]})}function I(e,t){let n=Math.max(0,Math.floor((e-t)*50/5)*5);return`${Math.floor(n/60)}m${(n%60).toString().padStart(2,`0`)}s`}function L({time:e,scoreSrc:t}){let r=d(e,18.92,19.2),i=_(e),a=i.id===`complete`,o={prepare:p.runEnd,implement:p.executionPrepareEnd,validate:p.executionImplementEnd,update:p.executionValidateEnd,complete:p.executionComplete}[i.id],s=d(e,o,o+.32),c=k(e);return(0,E.jsx)(`div`,{className:`scene-execution`,style:{"--reveal":r,"--stage-reveal":s},children:(0,E.jsxs)(`article`,{className:`homepage-motion-panel homepage-motion-execution-panel homepage-motion-execution-card is-score-${a?`complete`:`running`}`,children:[(0,E.jsx)(`header`,{className:`homepage-motion-panel-header`,children:(0,E.jsxs)(`div`,{className:`homepage-motion-panel-title`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,"aria-hidden":`true`,children:(0,E.jsx)(y,{})}),(0,E.jsx)(`h3`,{children:`Tutti is working on`})]})}),(0,E.jsxs)(`div`,{className:`homepage-motion-execution-body`,children:[(0,E.jsxs)(`div`,{className:`homepage-motion-execution-step homepage-motion-execution-stage is-${a?`complete`:`running`} has-marker`,children:[(0,E.jsx)(`span`,{className:`homepage-motion-execution-marker ${a?`is-done`:`is-running`}`,"aria-hidden":`true`,children:a?(0,E.jsx)(S,{}):(0,E.jsx)(n,{})}),(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-content homepage-motion-execution-stage-copy`,children:(0,E.jsxs)(`span`,{className:`homepage-motion-execution-step-title`,children:[(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-label`,children:i.label}),a?null:(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-elapsed`,children:` (${I(e,o)})`})]})},i.id)]}),(0,E.jsx)(`div`,{className:`homepage-motion-running-score ${a?`is-complete`:``}`,role:`img`,"aria-label":`Ode to Joy score phrase`,children:(0,E.jsx)(`div`,{className:`homepage-motion-score-passage`,style:{"--score-translate-x":`${-395.3*c}px`},"aria-hidden":`true`,children:(0,E.jsx)(`img`,{src:t,alt:``,draggable:!1})})})]})]})})}function R({color:e,variant:t=`vase`,className:n=``}){let r={"--ceramic-color":e};return t===`cup`?(0,E.jsxs)(`svg`,{className:`ceramic-object is-cup ${n}`,viewBox:`0 0 260 260`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M54 64h132l-9 126c-2 26-20 42-46 42h-22c-26 0-44-16-46-42Z`}),(0,E.jsx)(`path`,{className:`ceramic-outline`,d:`M186 92h18c34 0 34 72 1 76h-27`}),(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`120`,cy:`64`,rx:`66`,ry:`13`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M78 90c5 62 4 91 20 114`})]}):t===`bowl`?(0,E.jsxs)(`svg`,{className:`ceramic-object is-bowl ${n}`,viewBox:`0 0 300 220`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`150`,cy:`55`,rx:`116`,ry:`24`}),(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M34 55c8 82 45 132 116 132S258 137 266 55c-42 25-190 25-232 0Z`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M72 82c18 45 40 70 70 82`}),(0,E.jsx)(`path`,{className:`ceramic-base`,d:`M112 185h76`})]}):(0,E.jsxs)(`svg`,{className:`ceramic-object is-vase ${n}`,viewBox:`0 0 320 420`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M116 56c7 38-17 61-36 96-31 56-28 157 5 199 33 42 117 42 150 0 33-42 36-143 5-199-19-35-43-58-36-96Z`}),(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`160`,cy:`56`,rx:`44`,ry:`12`}),(0,E.jsx)(`ellipse`,{className:`ceramic-base`,cx:`160`,cy:`365`,rx:`66`,ry:`13`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M108 153c-25 64-23 145 1 185`})]})}function z({time:e}){let t=d(e,p.artifactClick,33.25),n=d(e,34.25,34.52),r=d(e,34.88,35.15),i=d(e,35.55,35.82),a=g(e),o=O(`#d9cbb4`,`#c56f4f`,n);e>=34.88&&(o=O(`#c56f4f`,`#6f9275`,r)),e>=35.55&&(o=O(`#6f9275`,`#243a46`,i));let s=e>=35.55?`ink`:e>=34.88?`sage`:e>=34.25?`clay`:null,c={"--artifact-scroll":a};return(0,E.jsxs)(`section`,{className:`scene-panel scene-artifact-panel`,style:D(t),children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(l,{"aria-hidden":`true`})}),(0,E.jsx)(`h2`,{children:`Artifacts`}),(0,E.jsx)(`span`,{className:`scene-ready-tag`,children:`Ready`})]}),(0,E.jsx)(`div`,{className:`scene-artifact-canvas`,children:(0,E.jsxs)(`div`,{className:`artifact-page-frame`,style:c,children:[(0,E.jsxs)(`div`,{className:`artifact-page-nav`,children:[(0,E.jsx)(`strong`,{children:`Morrow`}),(0,E.jsx)(`span`,{children:`Objects · Journal · Studio`})]}),(0,E.jsxs)(`section`,{className:`artifact-hero`,children:[(0,E.jsxs)(`div`,{className:`artifact-hero-copy`,children:[(0,E.jsx)(`span`,{className:`artifact-eyebrow`,children:`Hand-finished in small batches`}),(0,E.jsx)(`h3`,{children:`Objects for slower days.`}),(0,E.jsx)(`p`,{children:`Quiet forms, warm glazes, and useful pieces made to live with.`}),(0,E.jsx)(`button`,{type:`button`,tabIndex:-1,children:`Explore the collection`})]}),(0,E.jsxs)(`div`,{className:`artifact-hero-object`,children:[(0,E.jsx)(R,{color:o}),(0,E.jsxs)(`div`,{className:`artifact-glaze-picker`,"aria-label":`Glaze preview`,children:[(0,E.jsx)(`span`,{children:`Glaze`}),(0,E.jsx)(`i`,{className:s===`clay`?`is-active is-clay`:`is-clay`}),(0,E.jsx)(`i`,{className:s===`sage`?`is-active is-sage`:`is-sage`}),(0,E.jsx)(`i`,{className:s===`ink`?`is-active is-ink`:`is-ink`})]})]})]}),(0,E.jsxs)(`section`,{className:`artifact-collection`,children:[(0,E.jsxs)(`header`,{children:[(0,E.jsx)(`span`,{children:`Selected pieces`}),(0,E.jsx)(`p`,{children:`Everyday forms shaped for the rituals around them.`})]}),(0,E.jsxs)(`div`,{className:`artifact-product-grid`,children:[(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#b9785f`,variant:`cup`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Low cup`}),(0,E.jsx)(`span`,{children:`Rust glaze`})]})]}),(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#819283`,variant:`vase`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Field vase`}),(0,E.jsx)(`span`,{children:`Sage glaze`})]})]}),(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#d5c7af`,variant:`bowl`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Gather bowl`}),(0,E.jsx)(`span`,{children:`Flax glaze`})]})]})]})]}),(0,E.jsxs)(`section`,{className:`artifact-studio`,children:[(0,E.jsx)(`span`,{children:`Made by hand · Meant for every day`}),(0,E.jsx)(`h3`,{children:`Useful things can still feel special.`}),(0,E.jsx)(`p`,{children:`We make a small number of considered objects, slowly and close to home.`}),(0,E.jsx)(`button`,{type:`button`,tabIndex:-1,children:`Visit the studio`})]}),(0,E.jsxs)(`footer`,{className:`artifact-page-footer`,children:[(0,E.jsx)(`strong`,{children:`Morrow Ceramics`}),(0,E.jsx)(`span`,{className:`artifact-built-with`,children:`Built with Tutti.`}),(0,E.jsx)(`span`,{children:`Small batch · Est. 2026`})]})]})})]})}function B(e,t,n){return e+(t-e)*n}function V(e,t,n,r,i){let a=d(e,t,n,m);return{x:B(r.x,i.x,a),y:B(r.y,i.y,a)}}function H(e,t,n){return e<t||e>n?0:Math.sin(Math.PI*((e-t)/(n-t)))}function U(e){if(e>=p.runCursorStart&&e<18.92){let t=V(e,p.runCursorStart,p.runCursorArrive,{x:86,y:76},{x:94.25,y:94.2});return{visible:!0,x:t.x,y:t.y,clickPulse:H(e,p.runClickStart,p.runEnd)}}if(e>=31&&e<33.45){let t=V(e,31,32.22,{x:50,y:58},{x:4,y:22.85});return{visible:!0,x:t.x,y:t.y,clickPulse:H(e,32.28,32.6)}}return{visible:!1,x:50,y:50,clickPulse:0}}function W({time:e,assets:t}){let n=u(e),r=U(e),i=a(e),o=d(e,.08,1.05,m);return(0,E.jsx)(`div`,{className:`motion-scene`,role:`img`,"aria-label":`Tutti workflow animation from team discussion to a generated ceramics storefront`,style:{opacity:i,visibility:i<=.001?`hidden`:`visible`},children:(0,E.jsxs)(`div`,{className:`motion-stage`,style:{opacity:o,transform:`translate(50%, 50%) scale(${n.scale}) translate(${-n.centerX*100}%, ${-n.centerY*100}%)`},children:[(0,E.jsx)(M,{time:e,assets:t}),(0,E.jsxs)(`div`,{className:`scene-workspace-layer`,children:[(0,E.jsx)(N,{time:e,assets:t}),(0,E.jsx)(F,{time:e}),(0,E.jsx)(L,{time:e,scoreSrc:t.scoreSrc})]}),(0,E.jsx)(z,{time:e}),(0,E.jsxs)(`span`,{className:`scene-cursor ${r.visible?`is-visible`:``}`,style:{left:`${r.x}%`,top:`${r.y}%`,"--click-pulse":r.clickPulse},"aria-hidden":`true`,children:[(0,E.jsx)(w,{}),(0,E.jsx)(`i`,{})]})]})})}export{W as HomepageMotionScene};
1
+ import{C as e,S as t,_ as n,a as r,b as i,c as a,d as o,f as s,g as c,h as l,i as u,l as d,m as f,n as p,o as m,p as h,r as g,s as _,t as v,u as y,v as b,w as x,x as S,y as C}from"./index-o9YCtzEd.js";var w=e(`mouse-pointer-2`,[[`path`,{d:`M4.037 4.688a.495.495 0 0 1 .651-.651l16 6.5a.5.5 0 0 1-.063.947l-6.124 1.58a2 2 0 0 0-1.438 1.435l-1.579 6.126a.5.5 0 0 1-.947.063z`,key:`edeuup`}]]),T=e(`send`,[[`path`,{d:`M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z`,key:`1ffxy3`}],[`path`,{d:`m21.854 2.147-10.94 10.939`,key:`12cjpa`}]]),E=x();function D(e){return{"--reveal":e}}function O(e,t,n){let r=(e,t)=>Number.parseInt(e.slice(t,t+2),16),i=i=>Math.round(r(e,i)+(r(t,i)-r(e,i))*n).toString(16).padStart(2,`0`);return`#${i(1)}${i(3)}${i(5)}`}function k(e){let t=r((e-p.runEnd)/(p.executionComplete-p.runEnd));return t+t*t-t*t*t}function A({progress:e,children:t,className:n=``}){return(0,E.jsx)(`div`,{className:`scene-reveal ${n}`,style:D(e),children:t})}function j({progress:e,author:t,avatar:n,tone:r,timestamp:i,online:a=!1,assets:o,children:s}){return(0,E.jsxs)(`article`,{className:`scene-message`,style:D(e),children:[(0,E.jsx)(`span`,{className:`scene-avatar is-${r} ${n===`tutti`?`is-tutti`:``} ${a?`is-online`:``}`,"aria-hidden":`true`,children:n===`tutti`?(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:o.tuttiAvatarSrc,alt:``}):(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:o.humanAvatars[n],alt:``})}),(0,E.jsxs)(`div`,{className:`scene-message-copy`,children:[(0,E.jsxs)(`header`,{children:[(0,E.jsx)(`strong`,{children:t}),(0,E.jsx)(`span`,{children:i})]}),(0,E.jsx)(`p`,{children:s})]})]})}function M({time:e,assets:r}){let i=e>=p.artifactLive,a=e>=p.artifactClick,o=e>=p.runEnd&&e<p.executionComplete,u=d(e,p.runEnd,19.2),f=d(e,p.artifactLive,30.92);return(0,E.jsxs)(`aside`,{className:`scene-sidebar`,children:[(0,E.jsx)(`button`,{className:`scene-brand`,type:`button`,"aria-label":`Tutti`,tabIndex:-1,children:(0,E.jsx)(`img`,{src:r.logoSrc,alt:``})}),(0,E.jsxs)(`div`,{className:`scene-nav-stack`,children:[(0,E.jsxs)(`nav`,{className:`scene-nav`,"aria-label":`Workspace pages`,children:[(0,E.jsx)(`button`,{className:a?``:`is-active`,type:`button`,"aria-label":`Chat`,tabIndex:-1,children:(0,E.jsx)(c,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Worklist`,tabIndex:-1,children:(0,E.jsx)(b,{"aria-hidden":`true`})}),(0,E.jsxs)(`button`,{className:a?`is-active`:``,type:`button`,"aria-label":`Artifacts`,tabIndex:-1,children:[(0,E.jsx)(l,{"aria-hidden":`true`}),i?(0,E.jsx)(`span`,{className:`scene-live-pill`,style:D(f),children:`Live`}):null]}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`References`,tabIndex:-1,children:(0,E.jsx)(C,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Skills`,tabIndex:-1,children:(0,E.jsx)(s,{"aria-hidden":`true`})}),(0,E.jsx)(`button`,{type:`button`,"aria-label":`Timeline`,tabIndex:-1,children:(0,E.jsx)(t,{"aria-hidden":`true`})})]}),o?(0,E.jsx)(`button`,{className:`scene-status-entry is-running`,style:D(u),type:`button`,"aria-label":`Task running`,tabIndex:-1,children:(0,E.jsx)(n,{"aria-hidden":`true`})}):null]}),(0,E.jsx)(`button`,{className:`scene-settings`,type:`button`,"aria-label":`Settings`,tabIndex:-1,children:(0,E.jsx)(h,{"aria-hidden":`true`})})]})}function N({time:e,assets:t}){let n=d(e,30.35,30.92);return(0,E.jsxs)(`section`,{className:`scene-panel scene-chat-panel`,children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(c,{"aria-hidden":`true`})}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`h2`,{children:`Morrow Studio`}),(0,E.jsx)(`p`,{children:`Ceramics storefront`})]}),(0,E.jsxs)(`span`,{className:`scene-members`,"aria-hidden":`true`,children:[(0,E.jsx)(`i`,{className:`is-green`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.fey,alt:``})}),(0,E.jsx)(`i`,{className:`is-blue`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.avery,alt:``})}),(0,E.jsx)(`i`,{className:`is-yellow`,children:(0,E.jsx)(`img`,{className:`scene-avatar-image`,src:t.humanAvatars.jun,alt:``})})]})]}),(0,E.jsxs)(`div`,{className:`scene-chat-stream`,children:[(0,E.jsx)(j,{progress:d(e,1.35,2.05),author:`Fey`,avatar:`fey`,tone:`green`,timestamp:`10:12`,online:!0,assets:t,children:`🏺 Let's build an online shop for our ceramics studio.`}),(0,E.jsx)(j,{progress:d(e,2.65,3.35),author:`Avery`,avatar:`avery`,tone:`blue`,timestamp:`10:13`,online:!0,assets:t,children:`✨ Keep it warm, minimal, and editorial.`}),(0,E.jsx)(j,{progress:d(e,3.95,4.65),author:`Jun`,avatar:`jun`,tone:`yellow`,timestamp:`10:14`,online:!0,assets:t,children:`🎨 Let people preview every piece in different glazes.`}),(0,E.jsx)(j,{progress:d(e,5.25,5.95),author:`Tutti`,avatar:`tutti`,tone:`green`,timestamp:`10:15`,assets:t,children:`Got it — I'll put it together. ✨`}),(0,E.jsxs)(`article`,{className:`scene-task-result`,style:D(n),children:[(0,E.jsx)(`span`,{className:`scene-task-result-rail`,"aria-hidden":`true`}),(0,E.jsx)(`span`,{className:`scene-task-result-icon`,"aria-hidden":`true`,children:(0,E.jsx)(S,{})}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`span`,{children:`Task completed`}),(0,E.jsx)(`strong`,{children:`Build ceramics storefront`}),(0,E.jsx)(`small`,{children:`Storefront`}),(0,E.jsx)(`p`,{children:`Warm editorial shopping and glaze previews are ready in Artifacts.`})]}),(0,E.jsx)(i,{className:`scene-task-result-chevron`,"aria-hidden":`true`})]})]}),(0,E.jsxs)(`div`,{className:`scene-composer`,"aria-hidden":`true`,children:[(0,E.jsx)(`span`,{children:`Write a message`}),(0,E.jsx)(T,{})]})]})}function P({progress:e,icon:t,children:n}){return(0,E.jsxs)(`div`,{className:`scene-scratchpad-row`,style:D(e),children:[(0,E.jsx)(`span`,{"aria-hidden":`true`,children:t}),(0,E.jsx)(`p`,{children:n})]})}function F({time:e}){return(0,E.jsxs)(`section`,{className:`scene-panel scene-scratchpad-panel`,style:{"--scratchpad-collapse":d(e,p.runEnd,19.18)},children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(v,{"aria-hidden":`true`})}),(0,E.jsx)(`h2`,{children:`Scratchpad`})]}),(0,E.jsxs)(`div`,{className:`scene-scratchpad-body`,children:[(0,E.jsxs)(A,{progress:d(e,8.95,10),className:`scene-scratchpad-intro`,children:[(0,E.jsx)(`h3`,{children:`Ceramics storefront`}),(0,E.jsx)(`p`,{children:`A warm, editorial storefront for a small-batch studio, centered on tactile product discovery.`})]}),(0,E.jsx)(A,{progress:d(e,9.85,10.65),className:`scene-scratchpad-label`,children:`Confirmed`}),(0,E.jsx)(P,{progress:d(e,10.4,11.25),icon:(0,E.jsx)(S,{}),children:`Product-first editorial layout with generous space`}),(0,E.jsx)(P,{progress:d(e,11.2,12.05),icon:(0,E.jsx)(S,{}),children:`Warm neutrals with quiet serif headlines`}),(0,E.jsx)(P,{progress:d(e,12,12.85),icon:(0,E.jsx)(S,{}),children:`Keep the collection small, curated, and story-led`}),(0,E.jsx)(A,{progress:d(e,12.75,13.55),className:`scene-scratchpad-label`,children:`Requested feature`}),(0,E.jsx)(P,{progress:d(e,13.3,14.2),icon:(0,E.jsx)(o,{}),children:`Preview every piece in clay, sage, and ink glazes`})]}),(0,E.jsxs)(`footer`,{className:`scene-scratchpad-footer`,style:D(d(e,15.7,16.8)),children:[(0,E.jsxs)(`span`,{className:`scene-writing-mark`,children:[(0,E.jsx)(`strong`,{children:`Updated`}),(0,E.jsx)(`span`,{children:`just now`})]}),(0,E.jsxs)(`button`,{className:`scene-run-button`,type:`button`,tabIndex:-1,children:[(0,E.jsx)(f,{"aria-hidden":`true`}),(0,E.jsx)(`span`,{children:`Run`})]})]})]})}function I(e,t){let n=Math.max(0,Math.floor((e-t)*50/5)*5);return`${Math.floor(n/60)}m${(n%60).toString().padStart(2,`0`)}s`}function L({time:e,scoreSrc:t}){let r=d(e,18.92,19.2),i=_(e),a=i.id===`complete`,o={prepare:p.runEnd,implement:p.executionPrepareEnd,validate:p.executionImplementEnd,update:p.executionValidateEnd,complete:p.executionComplete}[i.id],s=d(e,o,o+.32),c=k(e);return(0,E.jsx)(`div`,{className:`scene-execution`,style:{"--reveal":r,"--stage-reveal":s},children:(0,E.jsxs)(`article`,{className:`homepage-motion-panel homepage-motion-execution-panel homepage-motion-execution-card is-score-${a?`complete`:`running`}`,children:[(0,E.jsx)(`header`,{className:`homepage-motion-panel-header`,children:(0,E.jsxs)(`div`,{className:`homepage-motion-panel-title`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,"aria-hidden":`true`,children:(0,E.jsx)(y,{})}),(0,E.jsx)(`h3`,{children:`Tutti is working on`})]})}),(0,E.jsxs)(`div`,{className:`homepage-motion-execution-body`,children:[(0,E.jsxs)(`div`,{className:`homepage-motion-execution-step homepage-motion-execution-stage is-${a?`complete`:`running`} has-marker`,children:[(0,E.jsx)(`span`,{className:`homepage-motion-execution-marker ${a?`is-done`:`is-running`}`,"aria-hidden":`true`,children:a?(0,E.jsx)(S,{}):(0,E.jsx)(n,{})}),(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-content homepage-motion-execution-stage-copy`,children:(0,E.jsxs)(`span`,{className:`homepage-motion-execution-step-title`,children:[(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-label`,children:i.label}),a?null:(0,E.jsx)(`span`,{className:`homepage-motion-execution-step-elapsed`,children:` (${I(e,o)})`})]})},i.id)]}),(0,E.jsx)(`div`,{className:`homepage-motion-running-score ${a?`is-complete`:``}`,role:`img`,"aria-label":`Ode to Joy score phrase`,children:(0,E.jsx)(`div`,{className:`homepage-motion-score-passage`,style:{"--score-translate-x":`${-395.3*c}px`},"aria-hidden":`true`,children:(0,E.jsx)(`img`,{src:t,alt:``,draggable:!1})})})]})]})})}function R({color:e,variant:t=`vase`,className:n=``}){let r={"--ceramic-color":e};return t===`cup`?(0,E.jsxs)(`svg`,{className:`ceramic-object is-cup ${n}`,viewBox:`0 0 260 260`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M54 64h132l-9 126c-2 26-20 42-46 42h-22c-26 0-44-16-46-42Z`}),(0,E.jsx)(`path`,{className:`ceramic-outline`,d:`M186 92h18c34 0 34 72 1 76h-27`}),(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`120`,cy:`64`,rx:`66`,ry:`13`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M78 90c5 62 4 91 20 114`})]}):t===`bowl`?(0,E.jsxs)(`svg`,{className:`ceramic-object is-bowl ${n}`,viewBox:`0 0 300 220`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`150`,cy:`55`,rx:`116`,ry:`24`}),(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M34 55c8 82 45 132 116 132S258 137 266 55c-42 25-190 25-232 0Z`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M72 82c18 45 40 70 70 82`}),(0,E.jsx)(`path`,{className:`ceramic-base`,d:`M112 185h76`})]}):(0,E.jsxs)(`svg`,{className:`ceramic-object is-vase ${n}`,viewBox:`0 0 320 420`,style:r,"aria-hidden":`true`,children:[(0,E.jsx)(`path`,{className:`ceramic-main`,d:`M116 56c7 38-17 61-36 96-31 56-28 157 5 199 33 42 117 42 150 0 33-42 36-143 5-199-19-35-43-58-36-96Z`}),(0,E.jsx)(`ellipse`,{className:`ceramic-rim`,cx:`160`,cy:`56`,rx:`44`,ry:`12`}),(0,E.jsx)(`ellipse`,{className:`ceramic-base`,cx:`160`,cy:`365`,rx:`66`,ry:`13`}),(0,E.jsx)(`path`,{className:`ceramic-highlight`,d:`M108 153c-25 64-23 145 1 185`})]})}function z({time:e}){let t=d(e,p.artifactClick,33.25),n=d(e,34.25,34.52),r=d(e,34.88,35.15),i=d(e,35.55,35.82),a=g(e),o=O(`#d9cbb4`,`#c56f4f`,n);e>=34.88&&(o=O(`#c56f4f`,`#6f9275`,r)),e>=35.55&&(o=O(`#6f9275`,`#243a46`,i));let s=e>=35.55?`ink`:e>=34.88?`sage`:e>=34.25?`clay`:null,c={"--artifact-scroll":a};return(0,E.jsxs)(`section`,{className:`scene-panel scene-artifact-panel`,style:D(t),children:[(0,E.jsxs)(`header`,{className:`scene-panel-header`,children:[(0,E.jsx)(`span`,{className:`scene-icon-tile`,children:(0,E.jsx)(l,{"aria-hidden":`true`})}),(0,E.jsx)(`h2`,{children:`Artifacts`}),(0,E.jsx)(`span`,{className:`scene-ready-tag`,children:`Ready`})]}),(0,E.jsx)(`div`,{className:`scene-artifact-canvas`,children:(0,E.jsxs)(`div`,{className:`artifact-page-frame`,style:c,children:[(0,E.jsxs)(`div`,{className:`artifact-page-nav`,children:[(0,E.jsx)(`strong`,{children:`Morrow`}),(0,E.jsx)(`span`,{children:`Objects · Journal · Studio`})]}),(0,E.jsxs)(`section`,{className:`artifact-hero`,children:[(0,E.jsxs)(`div`,{className:`artifact-hero-copy`,children:[(0,E.jsx)(`span`,{className:`artifact-eyebrow`,children:`Hand-finished in small batches`}),(0,E.jsx)(`h3`,{children:`Objects for slower days.`}),(0,E.jsx)(`p`,{children:`Quiet forms, warm glazes, and useful pieces made to live with.`}),(0,E.jsx)(`button`,{type:`button`,tabIndex:-1,children:`Explore the collection`})]}),(0,E.jsxs)(`div`,{className:`artifact-hero-object`,children:[(0,E.jsx)(R,{color:o}),(0,E.jsxs)(`div`,{className:`artifact-glaze-picker`,"aria-label":`Glaze preview`,children:[(0,E.jsx)(`span`,{children:`Glaze`}),(0,E.jsx)(`i`,{className:s===`clay`?`is-active is-clay`:`is-clay`}),(0,E.jsx)(`i`,{className:s===`sage`?`is-active is-sage`:`is-sage`}),(0,E.jsx)(`i`,{className:s===`ink`?`is-active is-ink`:`is-ink`})]})]})]}),(0,E.jsxs)(`section`,{className:`artifact-collection`,children:[(0,E.jsxs)(`header`,{children:[(0,E.jsx)(`span`,{children:`Selected pieces`}),(0,E.jsx)(`p`,{children:`Everyday forms shaped for the rituals around them.`})]}),(0,E.jsxs)(`div`,{className:`artifact-product-grid`,children:[(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#b9785f`,variant:`cup`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Low cup`}),(0,E.jsx)(`span`,{children:`Rust glaze`})]})]}),(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#819283`,variant:`vase`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Field vase`}),(0,E.jsx)(`span`,{children:`Sage glaze`})]})]}),(0,E.jsxs)(`article`,{children:[(0,E.jsx)(R,{color:`#d5c7af`,variant:`bowl`}),(0,E.jsxs)(`div`,{children:[(0,E.jsx)(`strong`,{children:`Gather bowl`}),(0,E.jsx)(`span`,{children:`Flax glaze`})]})]})]})]}),(0,E.jsxs)(`section`,{className:`artifact-studio`,children:[(0,E.jsx)(`span`,{children:`Made by hand · Meant for every day`}),(0,E.jsx)(`h3`,{children:`Useful things can still feel special.`}),(0,E.jsx)(`p`,{children:`We make a small number of considered objects, slowly and close to home.`}),(0,E.jsx)(`button`,{type:`button`,tabIndex:-1,children:`Visit the studio`})]}),(0,E.jsxs)(`footer`,{className:`artifact-page-footer`,children:[(0,E.jsx)(`strong`,{children:`Morrow Ceramics`}),(0,E.jsx)(`span`,{className:`artifact-built-with`,children:`Built with Tutti.`}),(0,E.jsx)(`span`,{children:`Small batch · Est. 2026`})]})]})})]})}function B(e,t,n){return e+(t-e)*n}function V(e,t,n,r,i){let a=d(e,t,n,m);return{x:B(r.x,i.x,a),y:B(r.y,i.y,a)}}function H(e,t,n){return e<t||e>n?0:Math.sin(Math.PI*((e-t)/(n-t)))}function U(e){if(e>=p.runCursorStart&&e<18.92){let t=V(e,p.runCursorStart,p.runCursorArrive,{x:86,y:76},{x:94.25,y:94.2});return{visible:!0,x:t.x,y:t.y,clickPulse:H(e,p.runClickStart,p.runEnd)}}if(e>=31&&e<33.45){let t=V(e,31,32.22,{x:50,y:58},{x:4,y:22.85});return{visible:!0,x:t.x,y:t.y,clickPulse:H(e,32.28,32.6)}}return{visible:!1,x:50,y:50,clickPulse:0}}function W({time:e,assets:t}){let n=u(e),r=U(e),i=a(e),o=d(e,.08,1.05,m);return(0,E.jsx)(`div`,{className:`motion-scene`,role:`img`,"aria-label":`Tutti workflow animation from team discussion to a generated ceramics storefront`,style:{opacity:i,visibility:i<=.001?`hidden`:`visible`},children:(0,E.jsxs)(`div`,{className:`motion-stage`,style:{opacity:o,transform:`translate(50%, 50%) scale(${n.scale}) translate(${-n.centerX*100}%, ${-n.centerY*100}%)`},children:[(0,E.jsx)(M,{time:e,assets:t}),(0,E.jsxs)(`div`,{className:`scene-workspace-layer`,children:[(0,E.jsx)(N,{time:e,assets:t}),(0,E.jsx)(F,{time:e}),(0,E.jsx)(L,{time:e,scoreSrc:t.scoreSrc})]}),(0,E.jsx)(z,{time:e}),(0,E.jsxs)(`span`,{className:`scene-cursor ${r.visible?`is-visible`:``}`,style:{left:`${r.x}%`,top:`${r.y}%`,"--click-pulse":r.clickPulse},"aria-hidden":`true`,children:[(0,E.jsx)(w,{}),(0,E.jsx)(`i`,{})]})]})})}export{W as HomepageMotionScene};