@dreamboard-games/sdk 0.4.0-alpha.8 → 0.5.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +49 -11
- package/dist/authoring/index.d.ts +6 -14
- package/dist/authoring/index.js +11 -547
- package/dist/authoring/index.js.map +1 -1
- package/dist/authoring-compiler.d.ts +27 -0
- package/dist/authoring-compiler.js +11 -0
- package/dist/authoring-compiler.js.map +1 -0
- package/dist/authoring-materialize-cli.d.ts +1 -0
- package/dist/authoring-materialize-cli.js +45 -0
- package/dist/authoring-materialize-cli.js.map +1 -0
- package/dist/browser-interaction.d.ts +22 -22
- package/dist/{chunk-3BLN5POZ.js → chunk-2GQIALJL.js} +51 -15
- package/dist/chunk-2GQIALJL.js.map +1 -0
- package/dist/chunk-533O7C4L.js +7095 -0
- package/dist/chunk-533O7C4L.js.map +1 -0
- package/dist/{chunk-44N3T2A5.js → chunk-6LMESVGT.js} +9 -28
- package/dist/chunk-6LMESVGT.js.map +1 -0
- package/dist/{chunk-ZYONCTZ2.js → chunk-DQS2EG5E.js} +3 -3
- package/dist/{chunk-ZYONCTZ2.js.map → chunk-DQS2EG5E.js.map} +1 -1
- package/dist/chunk-EOEA3I64.js +1864 -0
- package/dist/chunk-EOEA3I64.js.map +1 -0
- package/dist/{chunk-B2YBS3SG.js → chunk-FL67RDID.js} +41 -13
- package/dist/chunk-FL67RDID.js.map +1 -0
- package/dist/{chunk-2TAKLJJD.js → chunk-HIH6Y4FA.js} +222 -1267
- package/dist/chunk-HIH6Y4FA.js.map +1 -0
- package/dist/chunk-HUK4234C.js +166 -0
- package/dist/chunk-HUK4234C.js.map +1 -0
- package/dist/chunk-KGV2EUNN.js +532 -0
- package/dist/chunk-KGV2EUNN.js.map +1 -0
- package/dist/{chunk-VTK4TIXC.js → chunk-KRJPRYEA.js} +49 -4
- package/dist/chunk-KRJPRYEA.js.map +1 -0
- package/dist/chunk-KWHOFBDM.js +9 -0
- package/dist/chunk-KWHOFBDM.js.map +1 -0
- package/dist/{chunk-UC2UXAC6.js → chunk-LMHCGCA6.js} +2 -2
- package/dist/{chunk-XV27IQHA.js → chunk-N33CGX2F.js} +15 -85
- package/dist/chunk-N33CGX2F.js.map +1 -0
- package/dist/chunk-TXELBVTG.js +32 -0
- package/dist/chunk-TXELBVTG.js.map +1 -0
- package/dist/{chunk-2TRZSZGD.js → chunk-VRRR6QZT.js} +9 -12
- package/dist/chunk-VRRR6QZT.js.map +1 -0
- package/dist/chunk-VWTKGIYF.js +90 -0
- package/dist/chunk-VWTKGIYF.js.map +1 -0
- package/dist/{chunk-IYX5OO2K.js → chunk-XFMSLL3P.js} +133 -61
- package/dist/chunk-XFMSLL3P.js.map +1 -0
- package/dist/{chunk-YGQTL63W.js → chunk-ZSTCUJKZ.js} +4 -4
- package/dist/chunk-ZSTCUJKZ.js.map +1 -0
- package/dist/codegen.js +1 -1
- package/dist/{components-BTwSIjXj.d.ts → components-CNAt5J1p.d.ts} +1 -1
- package/dist/definitions-bZSBaPjj.d.ts +300 -0
- package/dist/{diagnostics-1BWjRo6-.d.ts → diagnostics-DIi3ina7.d.ts} +2 -1
- package/dist/digest.d.ts +8 -0
- package/dist/{index-CFTjJIXd.d.ts → index-CR69MyWr.d.ts} +2 -2
- package/dist/{index.d-C0PKOVbh.d.ts → index.d-Bw8AOcgp.d.ts} +532 -225
- package/dist/index.js +2 -2
- package/dist/package-set.d.ts +2 -2
- package/dist/package-set.js +2 -2
- package/dist/plugin-runtime-contract.d.ts +17 -0
- package/dist/plugin-runtime-contract.js +94 -0
- package/dist/plugin-runtime-contract.js.map +1 -0
- package/dist/{protocol-nS2ojsGr.d.ts → protocol-CVaSqPgX.d.ts} +54 -47
- package/dist/reducer/advanced.d.ts +5 -4
- package/dist/reducer/advanced.js +14 -108
- package/dist/reducer/advanced.js.map +1 -1
- package/dist/reducer-contract.d.ts +1 -1
- package/dist/reducer-contract.js +6 -4
- package/dist/reducer.d.ts +20 -98
- package/dist/reducer.js +28 -6050
- package/dist/reducer.js.map +1 -1
- package/dist/reference-games/index.d.ts +6 -198
- package/dist/reference-games/index.js +18 -200
- package/dist/reference-games/index.js.map +1 -1
- package/dist/runtime/primitives.d.ts +3 -3
- package/dist/runtime/primitives.js +5 -5
- package/dist/runtime/runtime-api.d.ts +1 -1
- package/dist/runtime/workspace-contract.d.ts +343 -11
- package/dist/runtime/workspace-contract.js +12 -6
- package/dist/{runtime-Dkfm1x2r.d.ts → runtime-C7Z2acNU.d.ts} +67 -31
- package/dist/{runtime-api-C6aWo9c0.d.ts → runtime-api-CgPuEVeF.d.ts} +4 -13
- package/dist/runtime.d.ts +7 -7
- package/dist/runtime.js +15 -11
- package/dist/runtime.js.map +1 -1
- package/dist/schema.d.ts +405 -0
- package/dist/{stale-contract-artifact-error-C5AaZPJ8.d.ts → stale-contract-artifact-error-XLaweZtF.d.ts} +1 -1
- package/dist/testing-compiler.d.ts +37 -0
- package/dist/testing-compiler.js +272 -0
- package/dist/testing-compiler.js.map +1 -0
- package/dist/testing-runtime.d.ts +98 -21
- package/dist/testing-runtime.js +154 -95
- package/dist/testing-runtime.js.map +1 -1
- package/dist/testing.d.ts +197 -156
- package/dist/testing.js +660 -372
- package/dist/testing.js.map +1 -1
- package/dist/types-DN4O7kH_.d.ts +122 -0
- package/dist/{types-CTeN_QAk.d.ts → types-q1Guidm5.d.ts} +4 -5
- package/dist/types.d.ts +0 -1
- package/dist/ui/components.d.ts +3 -2
- package/dist/ui/components.js +1 -1
- package/dist/ui/plugin-styles.css +1 -1
- package/dist/{ui-contract-Ue6SywvO.d.ts → ui-contract-BC4JpysE.d.ts} +2 -6
- package/dist/ui.d.ts +4 -3
- package/dist/ui.js +2 -2
- package/dist/{views-Qx-EHBP8.d.ts → views-D2Cfzr3h.d.ts} +17 -5
- package/package.json +41 -22
- package/REFERENCE.md +0 -22884
- package/dist/chunk-2TAKLJJD.js.map +0 -1
- package/dist/chunk-2TRZSZGD.js.map +0 -1
- package/dist/chunk-3BLN5POZ.js.map +0 -1
- package/dist/chunk-3OZMHZK3.js +0 -40
- package/dist/chunk-3OZMHZK3.js.map +0 -1
- package/dist/chunk-44N3T2A5.js.map +0 -1
- package/dist/chunk-5CQIJHGF.js +0 -663
- package/dist/chunk-5CQIJHGF.js.map +0 -1
- package/dist/chunk-B2YBS3SG.js.map +0 -1
- package/dist/chunk-IYX5OO2K.js.map +0 -1
- package/dist/chunk-VTK4TIXC.js.map +0 -1
- package/dist/chunk-VTNEWMWJ.js +0 -12
- package/dist/chunk-VTNEWMWJ.js.map +0 -1
- package/dist/chunk-XV27IQHA.js.map +0 -1
- package/dist/chunk-YGQTL63W.js.map +0 -1
- package/dist/types-B_3pObUV.d.ts +0 -192
- /package/dist/{chunk-UC2UXAC6.js.map → chunk-LMHCGCA6.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/authoring/adapter.ts","../../src/authoring/manifest-conformance-cases.ts"],"sourcesContent":["import { createHash } from \"node:crypto\";\nimport type {\n GameTopologyManifest,\n JsonValue,\n} from \"@dreamboard-games/sdk-types\";\nimport {\n AUTHORITATIVE_GENERATED_FILES,\n SEED_FILES,\n SEED_FILE_PATTERNS,\n generateAuthoritativeFiles,\n generateSeedFiles,\n materializeManifestTable,\n validateManifestAuthoring,\n} from \"@dreamboard-games/workspace-codegen\";\nimport { GENERATED_AUTHORING_METADATA } from \"./generated-metadata.js\";\nimport {\n createManifestConformanceCases,\n diagnosticCodesForValidationErrors,\n} from \"./manifest-conformance-cases.js\";\nimport type {\n AuthoringValidationResultV1,\n GenerateTestArtifactsInputV1,\n GeneratedArtifactV1,\n ProjectAuthoringAdapterV1,\n} from \"./types.js\";\n\nconst PLAYER_IDS = [\"player-1\", \"player-2\"] as const;\n\nfunction stableJson(value: unknown): string {\n if (value === undefined) {\n return \"null\";\n }\n if (value === null || typeof value !== \"object\") {\n return JSON.stringify(value);\n }\n if (Array.isArray(value)) {\n return `[${value.map((item) => stableJson(item)).join(\",\")}]`;\n }\n return `{${Object.entries(value as Record<string, unknown>)\n .filter(([, entry]) => entry !== undefined)\n .sort(([left], [right]) => left.localeCompare(right))\n .map(([key, entry]) => `${JSON.stringify(key)}:${stableJson(entry)}`)\n .join(\",\")}}`;\n}\n\nexport function sha256(value: string): string {\n return createHash(\"sha256\").update(value).digest(\"hex\");\n}\n\nfunction assertManifest(manifest: unknown): GameTopologyManifest {\n if (!manifest || typeof manifest !== \"object\") {\n throw new Error(\"Expected a manifest object.\");\n }\n return manifest as GameTopologyManifest;\n}\n\nfunction normalizeArtifact(\n path: string,\n content: string,\n ownership: GeneratedArtifactV1[\"ownership\"],\n): GeneratedArtifactV1 {\n if (\n path.length === 0 ||\n path.startsWith(\"/\") ||\n path.includes(\"\\\\\") ||\n path\n .split(\"/\")\n .some((segment) => !segment || segment === \".\" || segment === \"..\")\n ) {\n throw new Error(`Generated artifact path '${path}' is not normalized.`);\n }\n return {\n path,\n ownership,\n content,\n contentSha256: sha256(content),\n };\n}\n\nfunction normalizeArtifacts(\n entries: Record<string, string>,\n ownership: GeneratedArtifactV1[\"ownership\"],\n): GeneratedArtifactV1[] {\n return Object.entries(entries)\n .map(([path, content]) => normalizeArtifact(path, content, ownership))\n .sort((left, right) => left.path.localeCompare(right.path));\n}\n\nfunction validateNoDuplicateArtifactPaths(\n artifacts: readonly GeneratedArtifactV1[],\n): void {\n const seen = new Set<string>();\n for (const artifact of artifacts) {\n if (seen.has(artifact.path)) {\n throw new Error(\n `Generated artifact path '${artifact.path}' was emitted twice.`,\n );\n }\n seen.add(artifact.path);\n if (artifact.contentSha256 !== sha256(artifact.content)) {\n throw new Error(\n `Generated artifact '${artifact.path}' has a stale hash.`,\n );\n }\n }\n}\n\nexport function validateManifest(\n manifest: unknown,\n): AuthoringValidationResultV1 {\n try {\n const gameManifest = assertManifest(manifest);\n const result = validateManifestAuthoring(gameManifest);\n const errors = [...result.errors];\n if (errors.length === 0) {\n try {\n materializeManifest(gameManifest);\n } catch (error) {\n errors.push(error instanceof Error ? error.message : String(error));\n }\n }\n return {\n valid: errors.length === 0,\n errors,\n warnings: result.warnings,\n };\n } catch (error) {\n return {\n valid: false,\n errors: [error instanceof Error ? error.message : String(error)],\n warnings: [],\n };\n }\n}\n\nexport function materializeManifest(manifest: unknown): JsonValue {\n return materializeManifestTable({\n manifest: assertManifest(manifest),\n playerIds: PLAYER_IDS,\n shuffleItems: (values) => [...values],\n }) as JsonValue;\n}\n\nexport function generateWorkspaceArtifacts(\n manifest: unknown,\n): readonly GeneratedArtifactV1[] {\n const gameManifest = assertManifest(manifest);\n const artifacts = [\n ...normalizeArtifacts(\n generateAuthoritativeFiles(gameManifest),\n \"authoritative\",\n ),\n ...normalizeArtifacts(generateSeedFiles(gameManifest), \"seed\"),\n ].sort((left, right) => left.path.localeCompare(right.path));\n validateNoDuplicateArtifactPaths(artifacts);\n return artifacts;\n}\n\nexport function generateTestArtifacts(\n input: GenerateTestArtifactsInputV1,\n): readonly GeneratedArtifactV1[] {\n const materialized = materializeManifest(input.manifest);\n return [\n normalizeArtifact(\n \"test/generated/base-state.json\",\n `${stableJson(materialized)}\\n`,\n \"derived-test\",\n ),\n ];\n}\n\nexport const GENERATED_WORKSPACE_PATHS = [\n ...AUTHORITATIVE_GENERATED_FILES,\n ...SEED_FILES,\n \"test/generated/base-state.json\",\n] as const;\n\nexport type GeneratedWorkspacePathPattern = {\n readonly prefix: string;\n readonly suffix: string;\n};\n\nexport const GENERATED_WORKSPACE_PATH_PATTERNS: readonly GeneratedWorkspacePathPattern[] =\n SEED_FILE_PATTERNS;\n\nexport const MANIFEST_CONFORMANCE_CASES = createManifestConformanceCases();\n\nexport const projectAuthoringAdapter: ProjectAuthoringAdapterV1 = {\n protocolVersion: 1,\n metadata: GENERATED_AUTHORING_METADATA,\n generatedPaths: GENERATED_WORKSPACE_PATHS,\n generatedPathPatterns: GENERATED_WORKSPACE_PATH_PATTERNS,\n manifestConformanceCases: MANIFEST_CONFORMANCE_CASES,\n validateManifest,\n materializeManifest,\n generateWorkspaceArtifacts,\n generateTestArtifacts,\n};\n\nexport { diagnosticCodesForValidationErrors, stableJson };\n","import type {\n BoardCard,\n BoardSpec,\n ComponentHomeSpec,\n GameTopologyManifest,\n PieceSeedSpec,\n PieceTypeSpec,\n ZoneSpec,\n} from \"@dreamboard-games/sdk-types\";\nimport type { AuthoringManifestConformanceCaseV1 } from \"./types.js\";\n\nfunction baseManifest(\n cardSet: GameTopologyManifest[\"cardSets\"][number],\n overrides: Partial<GameTopologyManifest> = {},\n): GameTopologyManifest {\n return {\n players: {\n minPlayers: 2,\n maxPlayers: 2,\n optimalPlayers: 2,\n },\n cardSets: [cardSet],\n zones: [],\n boardTemplates: [],\n boards: [],\n pieceTypes: [],\n pieceSeeds: [],\n dieTypes: [],\n dieSeeds: [],\n resources: [],\n setupOptions: [],\n setupProfiles: [],\n ...overrides,\n };\n}\n\nfunction manualCardSet(\n id: string,\n defaultHome: ComponentHomeSpec,\n cards: BoardCard[],\n): GameTopologyManifest[\"cardSets\"][number] {\n const cardSet = {\n id,\n name: id,\n type: \"manual\",\n cardSchema: { properties: {} },\n defaultHome,\n cards,\n };\n return cardSet as unknown as GameTopologyManifest[\"cardSets\"][number];\n}\n\nconst sharedZone: ZoneSpec = {\n id: \"shared-zone\",\n name: \"Shared Zone\",\n scope: \"shared\",\n allowedCardSetIds: [\"cards\"],\n};\n\nconst sharedBoard: BoardSpec = {\n id: \"square-board\",\n name: \"Square Board\",\n layout: \"square\",\n scope: \"shared\",\n spaces: [\n { id: \"a1\", row: 0, col: 0 },\n { id: \"a2\", row: 0, col: 1 },\n { id: \"b1\", row: 1, col: 0 },\n { id: \"b2\", row: 1, col: 1 },\n ],\n relations: [],\n containers: [\n {\n id: \"display-row\",\n name: \"Display Row\",\n host: { type: \"board\" },\n },\n ],\n edges: [],\n vertices: [],\n};\n\nconst sharedTopology: Partial<GameTopologyManifest> = {\n boards: [sharedBoard],\n pieceTypes: [\n {\n id: \"holder\",\n name: \"Holder\",\n slots: [{ id: \"pocket\" }],\n },\n ] satisfies PieceTypeSpec[],\n pieceSeeds: [{ id: \"holder-a\", typeId: \"holder\" }] satisfies PieceSeedSpec[],\n};\n\nconst fixtures = [\n {\n id: \"manual-default-detached\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"detached\" }, [\n { type: \"marker\", name: \"Marker\", count: 1, properties: {} },\n ]),\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"ed6f7ce2ff4fbe697e49134f1d59157cf146e202db29a77be50e8326585f535c\",\n },\n },\n {\n id: \"manual-default-shared-zone\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"shared-zone\" }, [\n { type: \"coin\", name: \"Coin\", count: 2, properties: {} },\n ]),\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"75028d28dbc415c81db5e2d780d55b04c4db36378a149bc02b0194d94a8cc2b9\",\n },\n },\n {\n id: \"preset-default-shared-zone\",\n manifest: baseManifest(\n {\n id: \"cards\",\n name: \"Preset Cards\",\n type: \"preset\",\n presetId: \"standard_52_deck\",\n defaultHome: { type: \"zone\", zoneId: \"shared-zone\" },\n },\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"b3471c577ed266667b16799f75aa9b7358100a94108aa46a31ad16a0291f67ca\",\n },\n },\n {\n id: \"manual-per-card-detached-override\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"shared-zone\" }, [\n {\n type: \"removed\",\n name: \"Removed\",\n count: 1,\n home: { type: \"detached\" },\n properties: {},\n },\n ]),\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"fdcb2de78fc391e11aca1f266fd8bbb348a82faa0fbbac1d8eb1defd8697a0e9\",\n },\n },\n {\n id: \"manual-per-card-shared-zone-override\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"detached\" }, [\n {\n type: \"dealt\",\n name: \"Dealt\",\n count: 1,\n home: { type: \"zone\", zoneId: \"shared-zone\" },\n properties: {},\n },\n ]),\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"b6bee1db85f16e8a12a7136c7d524591f925427c8ec04d64b07905c5bc859d7a\",\n },\n },\n {\n id: \"manual-compatible-zones-no-inference\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"detached\" }, [\n { type: \"token\", name: \"Token\", count: 1, properties: {} },\n ]),\n {\n zones: [\n sharedZone,\n {\n ...sharedZone,\n id: \"second-compatible-zone\",\n name: \"Second Compatible Zone\",\n },\n ],\n },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"2727728ba3743d2b1874b2bc573b48c88f962fdcbdcdf20c62bed551d6d955c4\",\n },\n },\n {\n id: \"manual-per-player-zone-rejected\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"hand\" }, [\n { type: \"secret\", name: \"Secret\", count: 1, properties: {} },\n ]),\n {\n zones: [\n {\n id: \"hand\",\n name: \"Hand\",\n scope: \"perPlayer\",\n allowedCardSetIds: [\"cards\"],\n },\n ],\n },\n ),\n expected: {\n valid: false,\n transportValid: true,\n diagnosticCodes: [\"CARD_HOME_PER_PLAYER_ZONE_REJECTED\"],\n },\n },\n {\n id: \"manual-space-home\",\n manifest: baseManifest(\n manualCardSet(\n \"cards\",\n { type: \"space\", boardId: \"square-board\", spaceId: \"a1\" },\n [{ type: \"space-card\", name: \"Space\", count: 1, properties: {} }],\n ),\n sharedTopology,\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"429abfb3276c67cdca59d3dc077fc73022a9716bccef2c43f6805ff5cce0f2c2\",\n },\n },\n {\n id: \"manual-container-home\",\n manifest: baseManifest(\n manualCardSet(\n \"cards\",\n {\n type: \"container\",\n boardId: \"square-board\",\n containerId: \"display-row\",\n },\n [\n {\n type: \"container-card\",\n name: \"Container\",\n count: 1,\n properties: {},\n },\n ],\n ),\n sharedTopology,\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"eff372263227b316d064a519cf282a6cc1d2d8df4ac04673b7f47ac518d7a2a3\",\n },\n },\n {\n id: \"manual-slot-home\",\n manifest: baseManifest(\n manualCardSet(\n \"cards\",\n {\n type: \"slot\",\n host: { kind: \"piece\", id: \"holder-a\" },\n slotId: \"pocket\",\n },\n [{ type: \"slot-card\", name: \"Slot\", count: 1, properties: {} }],\n ),\n sharedTopology,\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"af3111f8d861ae69b77f2f46ba3df9f2f698f3306c412efc91095544e8121ab6\",\n },\n },\n {\n id: \"manual-edge-home\",\n manifest: baseManifest(\n manualCardSet(\n \"cards\",\n {\n type: \"edge\",\n boardId: \"square-board\",\n ref: { spaces: [\"a1\", \"a2\"] },\n },\n [{ type: \"edge-card\", name: \"Edge\", count: 1, properties: {} }],\n ),\n sharedTopology,\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"f8606ea25f52d9bf801aa4fee9f558b60d7f39bcd601d57bdfccdf1ddbf4c500\",\n },\n },\n {\n id: \"manual-vertex-home\",\n manifest: baseManifest(\n manualCardSet(\n \"cards\",\n {\n type: \"vertex\",\n boardId: \"square-board\",\n ref: { spaces: [\"a1\", \"a2\", \"b1\", \"b2\"] },\n },\n [{ type: \"vertex-card\", name: \"Vertex\", count: 1, properties: {} }],\n ),\n sharedTopology,\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"e84a4920ea8b71052acd42accf11101380ab982e493ebe207113dd4d243034de\",\n },\n },\n {\n id: \"manual-invalid-target-id\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"missing-zone\" }, [\n { type: \"lost\", name: \"Lost\", count: 1, properties: {} },\n ]),\n ),\n expected: {\n valid: false,\n transportValid: true,\n diagnosticCodes: [\"AUTHORING_VALIDATION_ERROR\"],\n },\n },\n {\n id: \"manual-count-order\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"shared-zone\" }, [\n { type: \"first\", name: \"First\", count: 3, properties: {} },\n { type: \"second\", name: \"Second\", count: 2, properties: {} },\n ]),\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"2e4ced71909d4c36053317311c9ceaf3bf3adba875bff3fe9596bbea47746423\",\n },\n },\n {\n id: \"manual-generated-scenario-base\",\n manifest: baseManifest(\n manualCardSet(\"cards\", { type: \"zone\", zoneId: \"shared-zone\" }, [\n { type: \"alpha\", name: \"Alpha\", count: 2, properties: {} },\n { type: \"beta\", name: \"Beta\", count: 1, properties: {} },\n ]),\n { zones: [sharedZone] },\n ),\n expected: {\n valid: true,\n transportValid: true,\n materializedSha256:\n \"b1b65d708b503036a49434c64c6f4aab3bedd295681bd103b69c4b98fdd5e2bb\",\n },\n },\n {\n id: \"manual-default-required\",\n manifest: {\n ...baseManifest(\n manualCardSet(\"cards\", { type: \"detached\" }, [\n { type: \"card\", name: \"Card\", count: 1, properties: {} },\n ]),\n ),\n cardSets: [\n {\n id: \"cards\",\n name: \"Cards\",\n type: \"manual\",\n cardSchema: { properties: {} },\n cards: [{ type: \"card\", name: \"Card\", count: 1, properties: {} }],\n },\n ],\n } as unknown as GameTopologyManifest,\n expected: {\n valid: false,\n transportValid: false,\n diagnosticCodes: [\"MANUAL_CARD_SET_DEFAULT_HOME_REQUIRED\"],\n },\n },\n] as const satisfies readonly (Omit<\n AuthoringManifestConformanceCaseV1,\n \"manifest\"\n> & { manifest: GameTopologyManifest })[];\n\nfunction deepFreeze<T>(value: T): T {\n if (value && typeof value === \"object\" && !Object.isFrozen(value)) {\n for (const entry of Object.values(value)) {\n deepFreeze(entry);\n }\n Object.freeze(value);\n }\n return value;\n}\n\nexport function diagnosticCodesForValidationErrors(\n errors: readonly string[],\n): readonly string[] {\n return [...new Set(errors.map(diagnosticCodeForValidationError))].sort();\n}\n\nfunction diagnosticCodeForValidationError(error: string): string {\n if (\n error.includes(\".defaultHome: Manual card sets must declare defaultHome\")\n ) {\n return \"MANUAL_CARD_SET_DEFAULT_HOME_REQUIRED\";\n }\n if (error.includes(\"cannot target per-player zone\")) {\n return \"CARD_HOME_PER_PLAYER_ZONE_REJECTED\";\n }\n if (error.includes(\"cannot target per-player board\")) {\n return \"CARD_HOME_PER_PLAYER_BOARD_REJECTED\";\n }\n return \"AUTHORING_VALIDATION_ERROR\";\n}\n\nexport function createManifestConformanceCases(): readonly AuthoringManifestConformanceCaseV1[] {\n return deepFreeze(\n fixtures,\n ) as unknown as readonly AuthoringManifestConformanceCaseV1[];\n}\n"],"mappings":";;;;;;;;;;;;;;;AAAA,SAAS,kBAAkB;;;ACW3B,SAAS,aACP,SACA,YAA2C,CAAC,GACtB;AACtB,SAAO;AAAA,IACL,SAAS;AAAA,MACP,YAAY;AAAA,MACZ,YAAY;AAAA,MACZ,gBAAgB;AAAA,IAClB;AAAA,IACA,UAAU,CAAC,OAAO;AAAA,IAClB,OAAO,CAAC;AAAA,IACR,gBAAgB,CAAC;AAAA,IACjB,QAAQ,CAAC;AAAA,IACT,YAAY,CAAC;AAAA,IACb,YAAY,CAAC;AAAA,IACb,UAAU,CAAC;AAAA,IACX,UAAU,CAAC;AAAA,IACX,WAAW,CAAC;AAAA,IACZ,cAAc,CAAC;AAAA,IACf,eAAe,CAAC;AAAA,IAChB,GAAG;AAAA,EACL;AACF;AAEA,SAAS,cACP,IACA,aACA,OAC0C;AAC1C,QAAM,UAAU;AAAA,IACd;AAAA,IACA,MAAM;AAAA,IACN,MAAM;AAAA,IACN,YAAY,EAAE,YAAY,CAAC,EAAE;AAAA,IAC7B;AAAA,IACA;AAAA,EACF;AACA,SAAO;AACT;AAEA,IAAM,aAAuB;AAAA,EAC3B,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,OAAO;AAAA,EACP,mBAA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ent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
type MaterializeWorkspaceOptions = {
|
|
2
|
+
readonly manifestPath: string;
|
|
3
|
+
readonly projectRoot?: string;
|
|
4
|
+
/** Scaffolding-only. Existing build/test paths leave seed files untouched. */
|
|
5
|
+
readonly writeMissingSeeds?: boolean;
|
|
6
|
+
};
|
|
7
|
+
type MaterializedWorkspaceResult = {
|
|
8
|
+
readonly schemaVersion: 1;
|
|
9
|
+
readonly projectRoot: string;
|
|
10
|
+
readonly authoritativeFiles: number;
|
|
11
|
+
readonly seededFiles: number;
|
|
12
|
+
readonly artifacts: readonly {
|
|
13
|
+
readonly path: string;
|
|
14
|
+
readonly ownership: "authoritative";
|
|
15
|
+
readonly sha256: `sha256:${string}`;
|
|
16
|
+
}[];
|
|
17
|
+
readonly digest: `sha256:${string}`;
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* Materialize SDK-owned workspace contracts from authored manifest source.
|
|
21
|
+
* Authoritative files are always replaced. Seed files are untouched unless a
|
|
22
|
+
* scaffolding caller explicitly opts in. No test state or projection artifact
|
|
23
|
+
* is emitted.
|
|
24
|
+
*/
|
|
25
|
+
declare function materializeWorkspace(options: MaterializeWorkspaceOptions): Promise<MaterializedWorkspaceResult>;
|
|
26
|
+
|
|
27
|
+
export { type MaterializeWorkspaceOptions, type MaterializedWorkspaceResult, materializeWorkspace };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import {
|
|
2
|
+
materializeWorkspace
|
|
3
|
+
} from "./chunk-HUK4234C.js";
|
|
4
|
+
import "./chunk-KGV2EUNN.js";
|
|
5
|
+
import "./chunk-KWHOFBDM.js";
|
|
6
|
+
import "./chunk-HIH6Y4FA.js";
|
|
7
|
+
import "./chunk-PZ5AY32C.js";
|
|
8
|
+
export {
|
|
9
|
+
materializeWorkspace
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=authoring-compiler.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
materializeWorkspace
|
|
4
|
+
} from "./chunk-HUK4234C.js";
|
|
5
|
+
import "./chunk-KGV2EUNN.js";
|
|
6
|
+
import "./chunk-KWHOFBDM.js";
|
|
7
|
+
import "./chunk-HIH6Y4FA.js";
|
|
8
|
+
import "./chunk-PZ5AY32C.js";
|
|
9
|
+
|
|
10
|
+
// src/authoring-materialize-cli.ts
|
|
11
|
+
var options = parseArgs(process.argv.slice(2));
|
|
12
|
+
var result = await materializeWorkspace(options);
|
|
13
|
+
console.log(JSON.stringify(result, null, 2));
|
|
14
|
+
function parseArgs(argv) {
|
|
15
|
+
let manifestPath;
|
|
16
|
+
let projectRoot;
|
|
17
|
+
let writeMissingSeeds = false;
|
|
18
|
+
for (let index = 0; index < argv.length; index += 1) {
|
|
19
|
+
const arg = argv[index];
|
|
20
|
+
if (arg === "--manifest") {
|
|
21
|
+
manifestPath = argv[index + 1];
|
|
22
|
+
index += 1;
|
|
23
|
+
continue;
|
|
24
|
+
}
|
|
25
|
+
if (arg === "--project-root") {
|
|
26
|
+
projectRoot = argv[index + 1];
|
|
27
|
+
index += 1;
|
|
28
|
+
continue;
|
|
29
|
+
}
|
|
30
|
+
if (arg === "--write-missing-seeds") {
|
|
31
|
+
writeMissingSeeds = true;
|
|
32
|
+
continue;
|
|
33
|
+
}
|
|
34
|
+
throw new Error(`Unknown argument '${arg}'.`);
|
|
35
|
+
}
|
|
36
|
+
if (!manifestPath) {
|
|
37
|
+
throw new Error("--manifest is required.");
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
manifestPath,
|
|
41
|
+
...projectRoot === void 0 ? {} : { projectRoot },
|
|
42
|
+
...writeMissingSeeds ? { writeMissingSeeds: true } : {}
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=authoring-materialize-cli.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/authoring-materialize-cli.ts"],"sourcesContent":["#!/usr/bin/env node\nimport { materializeWorkspace } from \"./authoring/materialize-workspace.js\";\n\nconst options = parseArgs(process.argv.slice(2));\nconst result = await materializeWorkspace(options);\nconsole.log(JSON.stringify(result, null, 2));\n\nfunction parseArgs(argv: readonly string[]): {\n readonly manifestPath: string;\n readonly projectRoot?: string;\n readonly writeMissingSeeds?: boolean;\n} {\n let manifestPath: string | undefined;\n let projectRoot: string | undefined;\n let writeMissingSeeds = false;\n for (let index = 0; index < argv.length; index += 1) {\n const arg = argv[index];\n if (arg === \"--manifest\") {\n manifestPath = argv[index + 1];\n index += 1;\n continue;\n }\n if (arg === \"--project-root\") {\n projectRoot = argv[index + 1];\n index += 1;\n continue;\n }\n if (arg === \"--write-missing-seeds\") {\n writeMissingSeeds = true;\n continue;\n }\n throw new Error(`Unknown argument '${arg}'.`);\n }\n if (!manifestPath) {\n throw new Error(\"--manifest is required.\");\n }\n return {\n manifestPath,\n ...(projectRoot === undefined ? {} : { projectRoot }),\n ...(writeMissingSeeds ? { writeMissingSeeds: true } : {}),\n };\n}\n"],"mappings":";;;;;;;;;;AAGA,IAAM,UAAU,UAAU,QAAQ,KAAK,MAAM,CAAC,CAAC;AAC/C,IAAM,SAAS,MAAM,qBAAqB,OAAO;AACjD,QAAQ,IAAI,KAAK,UAAU,QAAQ,MAAM,CAAC,CAAC;AAE3C,SAAS,UAAU,MAIjB;AACA,MAAI;AACJ,MAAI;AACJ,MAAI,oBAAoB;AACxB,WAAS,QAAQ,GAAG,QAAQ,KAAK,QAAQ,SAAS,GAAG;AACnD,UAAM,MAAM,KAAK,KAAK;AACtB,QAAI,QAAQ,cAAc;AACxB,qBAAe,KAAK,QAAQ,CAAC;AAC7B,eAAS;AACT;AAAA,IACF;AACA,QAAI,QAAQ,kBAAkB;AAC5B,oBAAc,KAAK,QAAQ,CAAC;AAC5B,eAAS;AACT;AAAA,IACF;AACA,QAAI,QAAQ,yBAAyB;AACnC,0BAAoB;AACpB;AAAA,IACF;AACA,UAAM,IAAI,MAAM,qBAAqB,GAAG,IAAI;AAAA,EAC9C;AACA,MAAI,CAAC,cAAc;AACjB,UAAM,IAAI,MAAM,yBAAyB;AAAA,EAC3C;AACA,SAAO;AAAA,IACL;AAAA,IACA,GAAI,gBAAgB,SAAY,CAAC,IAAI,EAAE,YAAY;AAAA,IACnD,GAAI,oBAAoB,EAAE,mBAAmB,KAAK,IAAI,CAAC;AAAA,EACzD;AACF;","names":[]}
|
|
@@ -29,7 +29,7 @@ declare function gameplayCommitEffect(): GameplaySemanticEffect;
|
|
|
29
29
|
declare function gameplayInvokeEffect(): GameplaySemanticEffect;
|
|
30
30
|
|
|
31
31
|
declare function defineBrowserInteractionSurface<Surface extends BrowserInteractionSurface, Intent extends BrowserInteractionIntent>(definition: BrowserInteractionSurfaceDefinition<Surface, Intent>): BrowserInteractionSurfaceDefinition<Surface, Intent>;
|
|
32
|
-
declare const gameplayBrowserInteractionSurface: BrowserInteractionSurfaceDefinition<"gameplay", "arm" | "reveal" | "invoke" | "select" | "toggle" | "increment" | "decrement" | "
|
|
32
|
+
declare const gameplayBrowserInteractionSurface: BrowserInteractionSurfaceDefinition<"gameplay", "fill" | "arm" | "reveal" | "invoke" | "select" | "toggle" | "increment" | "decrement" | "submit", string>;
|
|
33
33
|
declare function createBrowserInteractionRegistry(definitions?: readonly BrowserInteractionSurfaceDefinition[]): BrowserInteractionRegistry;
|
|
34
34
|
declare const defaultBrowserInteractionRegistry: BrowserInteractionRegistry;
|
|
35
35
|
|
|
@@ -111,8 +111,8 @@ declare const gameplaySemanticEffectSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
111
111
|
declare const browserInteractionDiagnosticSchema: z.ZodObject<{
|
|
112
112
|
code: z.ZodString;
|
|
113
113
|
severity: z.ZodEnum<{
|
|
114
|
-
error: "error";
|
|
115
114
|
warning: "warning";
|
|
115
|
+
error: "error";
|
|
116
116
|
}>;
|
|
117
117
|
message: z.ZodString;
|
|
118
118
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -190,8 +190,8 @@ declare const browserInteractionActuatorSchema: z.ZodObject<{
|
|
|
190
190
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
191
191
|
code: z.ZodString;
|
|
192
192
|
severity: z.ZodEnum<{
|
|
193
|
-
error: "error";
|
|
194
193
|
warning: "warning";
|
|
194
|
+
error: "error";
|
|
195
195
|
}>;
|
|
196
196
|
message: z.ZodString;
|
|
197
197
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -225,8 +225,8 @@ declare const browserInteractionPointerTargetSchema: z.ZodObject<{
|
|
|
225
225
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
226
226
|
code: z.ZodString;
|
|
227
227
|
severity: z.ZodEnum<{
|
|
228
|
-
error: "error";
|
|
229
228
|
warning: "warning";
|
|
229
|
+
error: "error";
|
|
230
230
|
}>;
|
|
231
231
|
message: z.ZodString;
|
|
232
232
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -315,8 +315,8 @@ declare const browserGameplayInteractionSchema: z.ZodObject<{
|
|
|
315
315
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
316
316
|
code: z.ZodString;
|
|
317
317
|
severity: z.ZodEnum<{
|
|
318
|
-
error: "error";
|
|
319
318
|
warning: "warning";
|
|
319
|
+
error: "error";
|
|
320
320
|
}>;
|
|
321
321
|
message: z.ZodString;
|
|
322
322
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -350,8 +350,8 @@ declare const browserGameplayInteractionSchema: z.ZodObject<{
|
|
|
350
350
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
351
351
|
code: z.ZodString;
|
|
352
352
|
severity: z.ZodEnum<{
|
|
353
|
-
error: "error";
|
|
354
353
|
warning: "warning";
|
|
354
|
+
error: "error";
|
|
355
355
|
}>;
|
|
356
356
|
message: z.ZodString;
|
|
357
357
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -365,8 +365,8 @@ declare const browserGameplayInteractionSchema: z.ZodObject<{
|
|
|
365
365
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
366
366
|
code: z.ZodString;
|
|
367
367
|
severity: z.ZodEnum<{
|
|
368
|
-
error: "error";
|
|
369
368
|
warning: "warning";
|
|
369
|
+
error: "error";
|
|
370
370
|
}>;
|
|
371
371
|
message: z.ZodString;
|
|
372
372
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -458,8 +458,8 @@ declare const browserGameplaySurfaceSnapshotSchema: z.ZodObject<{
|
|
|
458
458
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
459
459
|
code: z.ZodString;
|
|
460
460
|
severity: z.ZodEnum<{
|
|
461
|
-
error: "error";
|
|
462
461
|
warning: "warning";
|
|
462
|
+
error: "error";
|
|
463
463
|
}>;
|
|
464
464
|
message: z.ZodString;
|
|
465
465
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -493,8 +493,8 @@ declare const browserGameplaySurfaceSnapshotSchema: z.ZodObject<{
|
|
|
493
493
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
494
494
|
code: z.ZodString;
|
|
495
495
|
severity: z.ZodEnum<{
|
|
496
|
-
error: "error";
|
|
497
496
|
warning: "warning";
|
|
497
|
+
error: "error";
|
|
498
498
|
}>;
|
|
499
499
|
message: z.ZodString;
|
|
500
500
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -508,8 +508,8 @@ declare const browserGameplaySurfaceSnapshotSchema: z.ZodObject<{
|
|
|
508
508
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
509
509
|
code: z.ZodString;
|
|
510
510
|
severity: z.ZodEnum<{
|
|
511
|
-
error: "error";
|
|
512
511
|
warning: "warning";
|
|
512
|
+
error: "error";
|
|
513
513
|
}>;
|
|
514
514
|
message: z.ZodString;
|
|
515
515
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -523,8 +523,8 @@ declare const browserGameplaySurfaceSnapshotSchema: z.ZodObject<{
|
|
|
523
523
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
524
524
|
code: z.ZodString;
|
|
525
525
|
severity: z.ZodEnum<{
|
|
526
|
-
error: "error";
|
|
527
526
|
warning: "warning";
|
|
527
|
+
error: "error";
|
|
528
528
|
}>;
|
|
529
529
|
message: z.ZodString;
|
|
530
530
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -616,8 +616,8 @@ declare const browserSemanticSurfaceSnapshotSchema: z.ZodObject<{
|
|
|
616
616
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
617
617
|
code: z.ZodString;
|
|
618
618
|
severity: z.ZodEnum<{
|
|
619
|
-
error: "error";
|
|
620
619
|
warning: "warning";
|
|
620
|
+
error: "error";
|
|
621
621
|
}>;
|
|
622
622
|
message: z.ZodString;
|
|
623
623
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -651,8 +651,8 @@ declare const browserSemanticSurfaceSnapshotSchema: z.ZodObject<{
|
|
|
651
651
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
652
652
|
code: z.ZodString;
|
|
653
653
|
severity: z.ZodEnum<{
|
|
654
|
-
error: "error";
|
|
655
654
|
warning: "warning";
|
|
655
|
+
error: "error";
|
|
656
656
|
}>;
|
|
657
657
|
message: z.ZodString;
|
|
658
658
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -666,8 +666,8 @@ declare const browserSemanticSurfaceSnapshotSchema: z.ZodObject<{
|
|
|
666
666
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
667
667
|
code: z.ZodString;
|
|
668
668
|
severity: z.ZodEnum<{
|
|
669
|
-
error: "error";
|
|
670
669
|
warning: "warning";
|
|
670
|
+
error: "error";
|
|
671
671
|
}>;
|
|
672
672
|
message: z.ZodString;
|
|
673
673
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -681,8 +681,8 @@ declare const browserSemanticSurfaceSnapshotSchema: z.ZodObject<{
|
|
|
681
681
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
682
682
|
code: z.ZodString;
|
|
683
683
|
severity: z.ZodEnum<{
|
|
684
|
-
error: "error";
|
|
685
684
|
warning: "warning";
|
|
685
|
+
error: "error";
|
|
686
686
|
}>;
|
|
687
687
|
message: z.ZodString;
|
|
688
688
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -699,8 +699,8 @@ declare const browserUnknownSurfaceSnapshotSchema: z.ZodObject<{
|
|
|
699
699
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
700
700
|
code: z.ZodString;
|
|
701
701
|
severity: z.ZodEnum<{
|
|
702
|
-
error: "error";
|
|
703
702
|
warning: "warning";
|
|
703
|
+
error: "error";
|
|
704
704
|
}>;
|
|
705
705
|
message: z.ZodString;
|
|
706
706
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -797,8 +797,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
797
797
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
798
798
|
code: z.ZodString;
|
|
799
799
|
severity: z.ZodEnum<{
|
|
800
|
-
error: "error";
|
|
801
800
|
warning: "warning";
|
|
801
|
+
error: "error";
|
|
802
802
|
}>;
|
|
803
803
|
message: z.ZodString;
|
|
804
804
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -832,8 +832,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
832
832
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
833
833
|
code: z.ZodString;
|
|
834
834
|
severity: z.ZodEnum<{
|
|
835
|
-
error: "error";
|
|
836
835
|
warning: "warning";
|
|
836
|
+
error: "error";
|
|
837
837
|
}>;
|
|
838
838
|
message: z.ZodString;
|
|
839
839
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -847,8 +847,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
847
847
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
848
848
|
code: z.ZodString;
|
|
849
849
|
severity: z.ZodEnum<{
|
|
850
|
-
error: "error";
|
|
851
850
|
warning: "warning";
|
|
851
|
+
error: "error";
|
|
852
852
|
}>;
|
|
853
853
|
message: z.ZodString;
|
|
854
854
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -862,8 +862,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
862
862
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
863
863
|
code: z.ZodString;
|
|
864
864
|
severity: z.ZodEnum<{
|
|
865
|
-
error: "error";
|
|
866
865
|
warning: "warning";
|
|
866
|
+
error: "error";
|
|
867
867
|
}>;
|
|
868
868
|
message: z.ZodString;
|
|
869
869
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -879,8 +879,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
879
879
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
880
880
|
code: z.ZodString;
|
|
881
881
|
severity: z.ZodEnum<{
|
|
882
|
-
error: "error";
|
|
883
882
|
warning: "warning";
|
|
883
|
+
error: "error";
|
|
884
884
|
}>;
|
|
885
885
|
message: z.ZodString;
|
|
886
886
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -894,8 +894,8 @@ declare const browserInteractionSnapshotSchema: z.ZodObject<{
|
|
|
894
894
|
diagnostics: z.ZodArray<z.ZodObject<{
|
|
895
895
|
code: z.ZodString;
|
|
896
896
|
severity: z.ZodEnum<{
|
|
897
|
-
error: "error";
|
|
898
897
|
warning: "warning";
|
|
898
|
+
error: "error";
|
|
899
899
|
}>;
|
|
900
900
|
message: z.ZodString;
|
|
901
901
|
surface: z.ZodOptional<z.ZodString>;
|
|
@@ -30,12 +30,13 @@ __export(zod_exports, {
|
|
|
30
30
|
GameOutcomeSchema: () => GameOutcomeSchema,
|
|
31
31
|
InitializePhaseRequestSchema: () => InitializePhaseRequestSchema,
|
|
32
32
|
InitializeRequestSchema: () => InitializeRequestSchema,
|
|
33
|
+
InitializeResultSchema: () => InitializeResultSchema,
|
|
33
34
|
JsonValueSchema: () => JsonValueSchema,
|
|
34
35
|
OutcomeResultSchema: () => OutcomeResultSchema,
|
|
35
36
|
OutcomeScoreComponentSchema: () => OutcomeScoreComponentSchema,
|
|
36
37
|
OutcomeStandingSchema: () => OutcomeStandingSchema,
|
|
37
38
|
OutcomeTieBreakSchema: () => OutcomeTieBreakSchema,
|
|
38
|
-
|
|
39
|
+
ProjectRequestSchema: () => ProjectRequestSchema,
|
|
39
40
|
ProjectionTimingMetadataSchema: () => ProjectionTimingMetadataSchema,
|
|
40
41
|
ReduceRequestSchema: () => ReduceRequestSchema,
|
|
41
42
|
ReduceResultAcceptSchema: () => ReduceResultAcceptSchema,
|
|
@@ -54,10 +55,15 @@ __export(zod_exports, {
|
|
|
54
55
|
ReducerSessionMetaSchema: () => ReducerSessionMetaSchema,
|
|
55
56
|
ReducerSessionStateSchema: () => ReducerSessionStateSchema,
|
|
56
57
|
ReducerSetupSelectionSchema: () => ReducerSetupSelectionSchema,
|
|
58
|
+
RngDrawSchema: () => RngDrawSchema,
|
|
59
|
+
RngOperationParameterSchema: () => RngOperationParameterSchema,
|
|
60
|
+
RngOperationSchema: () => RngOperationSchema,
|
|
57
61
|
RngStateSchema: () => RngStateSchema,
|
|
58
62
|
RuntimeSimultaneousCurrentSchema: () => RuntimeSimultaneousCurrentSchema,
|
|
59
63
|
RuntimeSimultaneousStateSchema: () => RuntimeSimultaneousStateSchema,
|
|
60
64
|
RuntimeSimultaneousSubmissionSchema: () => RuntimeSimultaneousSubmissionSchema,
|
|
65
|
+
SchedulerContinuationDependencySchema: () => SchedulerContinuationDependencySchema,
|
|
66
|
+
SchedulerFlowAuthorityProjectionSchema: () => SchedulerFlowAuthorityProjectionSchema,
|
|
61
67
|
SeatProjectionBundleSchema: () => SeatProjectionBundleSchema,
|
|
62
68
|
SeatProjectionSchema: () => SeatProjectionSchema,
|
|
63
69
|
SimultaneousPhaseProjectionSchema: () => SimultaneousPhaseProjectionSchema,
|
|
@@ -74,7 +80,10 @@ var JsonValueSchema = JsonValueSchemaInternal;
|
|
|
74
80
|
var ContinuationTokenSchema = z.object({ "id": z.string().min(1), "data": JsonValueSchema }).strict();
|
|
75
81
|
var ContinuationMapSchema = z.record(z.string(), ContinuationTokenSchema);
|
|
76
82
|
var ReducerSetupSelectionSchema = z.object({ "profileId": z.string().min(1), "optionValues": z.record(z.string(), z.union([z.string(), z.null()])) }).strict();
|
|
77
|
-
var
|
|
83
|
+
var RngOperationParameterSchema = z.union([z.string(), z.number().finite(), z.boolean()]);
|
|
84
|
+
var RngOperationSchema = z.object({ "kind": z.string().min(1), "parameters": z.record(z.string(), RngOperationParameterSchema) }).strict();
|
|
85
|
+
var RngDrawSchema = z.object({ "index": z.number().int().gte(0), "cursorBefore": z.number().int().gte(0), "cursorAfter": z.number().int().gte(0), "operation": RngOperationSchema }).strict();
|
|
86
|
+
var RngStateSchema = z.object({ "seed": z.union([z.number().refine(Number.isInteger, { message: "Expected integer" }), z.null()]), "cursor": z.number().int(), "trace": z.array(z.string()), "draws": z.array(RngDrawSchema).optional() }).strict();
|
|
78
87
|
var ReducerFlowStateSchema = z.object({ "currentPhase": z.string().min(1), "turn": z.number().int(), "round": z.number().int(), "activePlayers": z.array(z.string().min(1)) }).strict();
|
|
79
88
|
var RuntimeSimultaneousSubmissionSchema = z.object({ "interactionId": z.string().min(1), "params": JsonValueSchema }).strict();
|
|
80
89
|
var RuntimeSimultaneousCurrentSchema = z.object({ "phaseName": z.string().min(1), "actors": z.array(z.string().min(1)), "submissions": z.record(z.string(), RuntimeSimultaneousSubmissionSchema) }).strict();
|
|
@@ -92,12 +101,6 @@ var EffectShuffleSharedZoneSchema = z.object({ "effectId": EffectIdSchema, "type
|
|
|
92
101
|
var EffectShufflePlayerZoneSchema = z.object({ "effectId": EffectIdSchema, "type": z.literal("shufflePlayerZone"), "zoneId": z.string().min(1), "playerId": z.string().min(1) }).strict();
|
|
93
102
|
var EffectSchema = z.discriminatedUnion("type", [EffectTransitionSchema, EffectRollDieSchema, EffectShuffleSharedZoneSchema, EffectShufflePlayerZoneSchema]);
|
|
94
103
|
var ReducerInputValidationResultSchema = z.object({ "valid": z.boolean(), "errorCode": z.string().optional(), "message": z.string().optional() }).strict();
|
|
95
|
-
var InitializeRequestSchema = z.object({ "table": JsonValueSchema, "playerIds": z.array(z.string().min(1)), "rngSeed": z.union([z.number().refine(Number.isInteger, { message: "Expected integer" }), z.null()]).optional(), "setup": z.union([ReducerSetupSelectionSchema, z.null()]).optional() }).strict();
|
|
96
|
-
var InitializePhaseRequestSchema = z.object({ "state": ReducerSessionStateSchema, "to": z.string().min(1) }).strict();
|
|
97
|
-
var ValidateInputRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
98
|
-
var ReduceRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
99
|
-
var DispatchRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
100
|
-
var ReduceResultRejectSchema = z.object({ "kind": z.literal("reject"), "errorCode": z.string().min(1), "message": z.string().optional() }).strict();
|
|
101
104
|
var GameOutcomeReasonSchema = z.object({ "code": z.string().min(1), "message": z.string().min(1).optional() }).strict();
|
|
102
105
|
var OutcomeResultSchema = z.enum(["win", "draw", "loss", "eliminated"]);
|
|
103
106
|
var OutcomeScoreComponentSchema = z.object({ "id": z.string().min(1), "label": z.string().min(1), "value": z.number().finite() }).strict();
|
|
@@ -107,29 +110,61 @@ var GameOutcomeSchema = z.object({ "reason": GameOutcomeReasonSchema, "standings
|
|
|
107
110
|
var GameEventDetailSchema = z.object({ "label": z.string().min(1), "value": z.union([z.string(), z.number().finite(), z.boolean()]) }).strict();
|
|
108
111
|
var SystemActionEventSchema = z.object({ "kind": z.literal("systemAction"), "procedureId": z.string().min(1), "title": z.string().min(1), "summary": z.string().min(1).optional(), "details": z.array(GameEventDetailSchema).max(16).optional() }).strict();
|
|
109
112
|
var GameEventSchema = z.discriminatedUnion("kind", [SystemActionEventSchema]);
|
|
113
|
+
var InitializeResultSchema = z.object({ "state": ReducerSessionStateSchema, "terminal": GameOutcomeSchema.optional(), "events": z.array(GameEventSchema).optional() }).strict();
|
|
114
|
+
var InitializeRequestSchema = z.object({ "table": JsonValueSchema, "playerIds": z.array(z.string().min(1)), "rngSeed": z.union([z.number().refine(Number.isInteger, { message: "Expected integer" }), z.null()]).optional(), "setup": z.union([ReducerSetupSelectionSchema, z.null()]).optional() }).strict();
|
|
115
|
+
var InitializePhaseRequestSchema = z.object({ "state": ReducerSessionStateSchema, "to": z.string().min(1) }).strict();
|
|
116
|
+
var ValidateInputRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
117
|
+
var ReduceRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
118
|
+
var DispatchRequestSchema = z.object({ "state": ReducerSessionStateSchema, "input": GameInputSchema }).strict();
|
|
119
|
+
var ReduceResultRejectSchema = z.object({ "kind": z.literal("reject"), "errorCode": z.string().min(1), "message": z.string().optional() }).strict();
|
|
110
120
|
var ReduceResultAcceptSchema = z.object({ "kind": z.literal("accept"), "state": ReducerSessionStateSchema, "terminal": GameOutcomeSchema.optional(), "effects": z.array(EffectSchema), "continuations": ContinuationMapSchema, "events": z.array(GameEventSchema).max(32) }).strict();
|
|
111
121
|
var ReduceResultSchema = z.discriminatedUnion("kind", [ReduceResultRejectSchema, ReduceResultAcceptSchema]);
|
|
112
122
|
var DispatchTraceAcceptedClientInputSchema = z.object({ "kind": z.literal("acceptedClientInput"), "input": GameInputSchema }).strict();
|
|
113
123
|
var DispatchTraceAppliedEffectSchema = z.object({ "kind": z.literal("appliedEffect"), "effect": EffectSchema, "continuation": ContinuationTokenSchema.optional() }).strict();
|
|
114
|
-
var DispatchTraceRngConsumptionSchema = z.object({ "kind": z.literal("rngConsumption"), "operation": z.string().min(1), "traceEntry": z.string() }).strict();
|
|
124
|
+
var DispatchTraceRngConsumptionSchema = z.object({ "kind": z.literal("rngConsumption"), "version": z.literal(2), "operation": z.string().min(1), "drawIndex": z.number().int().gte(0), "traceEntry": z.string() }).strict();
|
|
115
125
|
var DispatchTraceSchema = z.discriminatedUnion("kind", [DispatchTraceAcceptedClientInputSchema, DispatchTraceAppliedEffectSchema, DispatchTraceRngConsumptionSchema]);
|
|
116
126
|
var DispatchResultRejectSchema = z.object({ "kind": z.literal("reject"), "errorCode": z.string().min(1), "message": z.string().optional() }).strict();
|
|
117
127
|
var DispatchResultAcceptSchema = z.object({ "kind": z.literal("accept"), "state": ReducerSessionStateSchema, "terminal": GameOutcomeSchema.optional(), "trace": z.array(DispatchTraceSchema), "events": z.array(GameEventSchema).max(32) }).strict();
|
|
118
128
|
var DispatchResultSchema = z.discriminatedUnion("kind", [DispatchResultRejectSchema, DispatchResultAcceptSchema]);
|
|
119
129
|
var ReducerRuntimeLogEntryAcceptedClientInputSchema = z.object({ "kind": z.literal("acceptedClientInput"), "version": z.number().int(), "input": GameInputSchema }).strict();
|
|
120
130
|
var ReducerRuntimeLogEntryAppliedEffectSchema = z.object({ "kind": z.literal("appliedEffect"), "version": z.number().int(), "effect": EffectSchema, "continuation": z.union([ContinuationTokenSchema, z.null()]) }).strict();
|
|
121
|
-
var ReducerRuntimeLogEntryRngConsumptionSchema = z.object({ "kind": z.literal("rngConsumption"), "version": z.number().int(), "operation": z.string().min(1), "traceEntry": z.string() }).strict();
|
|
131
|
+
var ReducerRuntimeLogEntryRngConsumptionSchema = z.object({ "kind": z.literal("rngConsumption"), "version": z.number().int(), "operation": z.string().min(1), "drawIndex": z.number().int().gte(0).optional(), "traceEntry": z.string() }).strict();
|
|
122
132
|
var ReducerRuntimeLogEntryStateCommitSchema = z.object({ "kind": z.literal("stateCommit"), "version": z.number().int(), "state": ReducerSessionStateSchema }).strict();
|
|
123
133
|
var ReducerRuntimeLogEntrySchema = z.discriminatedUnion("kind", [ReducerRuntimeLogEntryAcceptedClientInputSchema, ReducerRuntimeLogEntryAppliedEffectSchema, ReducerRuntimeLogEntryRngConsumptionSchema, ReducerRuntimeLogEntryStateCommitSchema]);
|
|
124
134
|
var SeatProjectionSchema = z.object({ "view": JsonValueSchema.optional(), "availableInteractionRefs": JsonValueSchema.optional(), "zones": JsonValueSchema.optional() }).strict();
|
|
125
135
|
var SimultaneousPhaseProjectionSchema = z.object({ "phaseName": z.string().min(1), "interactionId": z.string().min(1), "actorIds": z.array(z.string().min(1)), "sealedPlayerIds": z.array(z.string().min(1)), "pendingPlayerIds": z.array(z.string().min(1)) }).strict();
|
|
136
|
+
var SchedulerContinuationDependencySchema = z.object({ "waiterPlayerId": z.string().min(1), "blockerPlayerIds": z.array(z.string().min(1)) }).strict();
|
|
137
|
+
var SchedulerFlowAuthorityProjectionSchema = z.object({ "version": z.literal(1), "activePlayerIds": z.array(z.string().min(1)), "pendingPlayerIds": z.array(z.string().min(1)), "continuationDependencies": z.array(SchedulerContinuationDependencySchema) }).strict();
|
|
126
138
|
var ProjectionTimingMetadataSchema = z.object({ "resolveAvailableInteractionsMs": z.number().finite().gte(0), "resolveViewMs": z.number().finite().gte(0), "resolveZoneHandlesMs": z.number().finite().gte(0), "descriptorHashMs": z.number().finite().gte(0) }).strict();
|
|
127
|
-
var SeatProjectionBundleSchema = z.object({ "currentStage": z.union([z.string().min(1), z.null()]).optional(), "stageSeats": z.array(z.string().min(1)).optional(), "simultaneousPhase": z.union([SimultaneousPhaseProjectionSchema, z.null()]).optional(), "sharedView": JsonValueSchema.optional(), "interactionsByRef": JsonValueSchema.optional(), "seats": z.record(z.string(), SeatProjectionSchema), "timing": ProjectionTimingMetadataSchema.optional() }).strict();
|
|
128
|
-
var
|
|
139
|
+
var SeatProjectionBundleSchema = z.object({ "currentStage": z.union([z.string().min(1), z.null()]).optional(), "stageSeats": z.array(z.string().min(1)).optional(), "simultaneousPhase": z.union([SimultaneousPhaseProjectionSchema, z.null()]).optional(), "schedulerFlow": SchedulerFlowAuthorityProjectionSchema.optional(), "sharedView": JsonValueSchema.optional(), "interactionsByRef": JsonValueSchema.optional(), "seats": z.record(z.string(), SeatProjectionSchema), "timing": ProjectionTimingMetadataSchema.optional() }).strict();
|
|
140
|
+
var ProjectRequestSchema = z.object({ "state": ReducerSessionStateSchema, "playerIds": z.array(z.string().min(1)) }).strict();
|
|
129
141
|
var BoardStaticProjectionSchema = z.object({ "view": JsonValueSchema, "hash": z.string().min(1), "manifestVersion": z.string() }).strict();
|
|
130
142
|
|
|
131
143
|
// ../reducer-contract/generated/version.ts
|
|
132
|
-
var REDUCER_CONTRACT_VERSION = "0.
|
|
144
|
+
var REDUCER_CONTRACT_VERSION = "0.5.0";
|
|
145
|
+
|
|
146
|
+
// ../reducer-contract/src/bundle.ts
|
|
147
|
+
function assertReducerBundleContract(value, source) {
|
|
148
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
149
|
+
throw new Error(`Reducer bundle ${source} did not export an object.`);
|
|
150
|
+
}
|
|
151
|
+
const bundle = value;
|
|
152
|
+
if (bundle.reducerContractVersion !== REDUCER_CONTRACT_VERSION) {
|
|
153
|
+
throw new Error(
|
|
154
|
+
`Reducer bundle ${source} requires exact contract ${REDUCER_CONTRACT_VERSION}; received ${String(bundle.reducerContractVersion ?? "missing")}.`
|
|
155
|
+
);
|
|
156
|
+
}
|
|
157
|
+
for (const method of [
|
|
158
|
+
"initialize",
|
|
159
|
+
"dispatch",
|
|
160
|
+
"boardStatic",
|
|
161
|
+
"project"
|
|
162
|
+
]) {
|
|
163
|
+
if (typeof bundle[method] !== "function") {
|
|
164
|
+
throw new Error(`Reducer bundle ${source} is missing ${method}().`);
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
133
168
|
|
|
134
169
|
// ../reducer-contract/generated/builders.ts
|
|
135
170
|
var builders_exports = {};
|
|
@@ -178,6 +213,7 @@ function materializeAccept(pending) {
|
|
|
178
213
|
export {
|
|
179
214
|
zod_exports,
|
|
180
215
|
builders_exports,
|
|
181
|
-
REDUCER_CONTRACT_VERSION
|
|
216
|
+
REDUCER_CONTRACT_VERSION,
|
|
217
|
+
assertReducerBundleContract
|
|
182
218
|
};
|
|
183
|
-
//# sourceMappingURL=chunk-
|
|
219
|
+
//# sourceMappingURL=chunk-2GQIALJL.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../reducer-contract/generated/zod.ts","../../reducer-contract/generated/version.ts","../../reducer-contract/src/bundle.ts","../../reducer-contract/generated/builders.ts"],"sourcesContent":["// @generated by packages/reducer-contract/scripts/generate.ts\n// DO NOT EDIT BY HAND. Edit schema/reducer-runtime.schema.json and rerun `pnpm generate`.\n\n/* eslint-disable */\nimport type * as Wire from \"./wire\";\nimport { z } from \"zod\";\n\nexport const ReducerContractVersionSchema = z.string().regex(new RegExp(\"^[0-9]+\\\\.[0-9]+\\\\.[0-9]+$\"));\n\nexport const EffectIdSchema = z.string().min(1);\n\nlet JsonValueSchemaInternal: z.ZodType<Wire.JsonValue>;\nJsonValueSchemaInternal = z.lazy(() => z.union([z.record(z.string(), JsonValueSchemaInternal), z.array(JsonValueSchemaInternal), z.string(), z.number(), z.boolean(), z.null()]));\nexport const JsonValueSchema = JsonValueSchemaInternal;\n\nexport const ContinuationTokenSchema = z.object({ \"id\": z.string().min(1), \"data\": JsonValueSchema }).strict();\n\nexport const ContinuationMapSchema = z.record(z.string(), ContinuationTokenSchema);\n\nexport const ReducerSetupSelectionSchema = z.object({ \"profileId\": z.string().min(1), \"optionValues\": z.record(z.string(), z.union([z.string(), z.null()])) }).strict();\n\nexport const RngOperationParameterSchema = z.union([z.string(), z.number().finite(), z.boolean()]);\n\nexport const RngOperationSchema = z.object({ \"kind\": z.string().min(1), \"parameters\": z.record(z.string(), RngOperationParameterSchema) }).strict();\n\nexport const RngDrawSchema = z.object({ \"index\": z.number().int().gte(0), \"cursorBefore\": z.number().int().gte(0), \"cursorAfter\": z.number().int().gte(0), \"operation\": RngOperationSchema }).strict();\n\nexport const RngStateSchema = z.object({ \"seed\": z.union([z.number().refine(Number.isInteger, { message: \"Expected integer\" }), z.null()]), \"cursor\": z.number().int(), \"trace\": z.array(z.string()), \"draws\": z.array(RngDrawSchema).optional() }).strict();\n\nexport const ReducerFlowStateSchema = z.object({ \"currentPhase\": z.string().min(1), \"turn\": z.number().int(), \"round\": z.number().int(), \"activePlayers\": z.array(z.string().min(1)) }).strict();\n\nexport const RuntimeSimultaneousSubmissionSchema = z.object({ \"interactionId\": z.string().min(1), \"params\": JsonValueSchema }).strict();\n\nexport const RuntimeSimultaneousCurrentSchema = z.object({ \"phaseName\": z.string().min(1), \"actors\": z.array(z.string().min(1)), \"submissions\": z.record(z.string(), RuntimeSimultaneousSubmissionSchema) }).strict();\n\nexport const RuntimeSimultaneousStateSchema = z.object({ \"current\": z.union([RuntimeSimultaneousCurrentSchema, z.null()]) }).strict();\n\nexport const TransitionRecordSchema = z.object({ \"from\": z.string().min(1), \"to\": z.string().min(1) }).strict();\n\nexport const ReducerRuntimeStateSchema = z.object({ \"rng\": RngStateSchema, \"setup\": z.union([ReducerSetupSelectionSchema, z.null()]), \"simultaneous\": RuntimeSimultaneousStateSchema, \"lastTransition\": z.union([TransitionRecordSchema, z.null()]) }).strict();\n\nexport const ReducerDomainStateSchema = z.object({ \"table\": JsonValueSchema, \"publicState\": JsonValueSchema, \"privateState\": z.record(z.string(), JsonValueSchema), \"hiddenState\": JsonValueSchema, \"flow\": ReducerFlowStateSchema, \"phase\": JsonValueSchema }).strict();\n\nexport const ReducerSessionMetaSchema = z.object({ \"contractFingerprint\": z.string().regex(new RegExp(\"^cfp[0-9]+:[a-f0-9]{16}$\")) }).strict();\n\nexport const ReducerSessionStateSchema = z.object({ \"meta\": ReducerSessionMetaSchema.optional(), \"domain\": ReducerDomainStateSchema, \"runtime\": ReducerRuntimeStateSchema }).strict();\n\nexport const GameInputInteractionSchema = z.object({ \"kind\": z.literal(\"interaction\"), \"playerId\": z.string().min(1), \"interactionId\": z.string().min(1), \"params\": JsonValueSchema }).strict();\n\nexport const GameInputSchema = z.discriminatedUnion(\"kind\", [GameInputInteractionSchema]);\n\nexport const EffectTransitionSchema = z.object({ \"effectId\": EffectIdSchema, \"type\": z.literal(\"transition\"), \"to\": z.string().min(1) }).strict();\n\nexport const EffectRollDieSchema = z.object({ \"effectId\": EffectIdSchema, \"type\": z.literal(\"rollDie\"), \"dieId\": z.string().min(1) }).strict();\n\nexport const EffectShuffleSharedZoneSchema = z.object({ \"effectId\": EffectIdSchema, \"type\": z.literal(\"shuffleSharedZone\"), \"zoneId\": z.string().min(1) }).strict();\n\nexport const EffectShufflePlayerZoneSchema = z.object({ \"effectId\": EffectIdSchema, \"type\": z.literal(\"shufflePlayerZone\"), \"zoneId\": z.string().min(1), \"playerId\": z.string().min(1) }).strict();\n\nexport const EffectSchema = z.discriminatedUnion(\"type\", [EffectTransitionSchema, EffectRollDieSchema, EffectShuffleSharedZoneSchema, EffectShufflePlayerZoneSchema]);\n\nexport const ReducerInputValidationResultSchema = z.object({ \"valid\": z.boolean(), \"errorCode\": z.string().optional(), \"message\": z.string().optional() }).strict();\n\nexport const GameOutcomeReasonSchema = z.object({ \"code\": z.string().min(1), \"message\": z.string().min(1).optional() }).strict();\n\nexport const OutcomeResultSchema = z.enum([\"win\", \"draw\", \"loss\", \"eliminated\"]);\n\nexport const OutcomeScoreComponentSchema = z.object({ \"id\": z.string().min(1), \"label\": z.string().min(1), \"value\": z.number().finite() }).strict();\n\nexport const OutcomeTieBreakSchema = z.object({ \"id\": z.string().min(1), \"label\": z.string().min(1), \"value\": z.union([z.number().finite(), z.string()]) }).strict();\n\nexport const OutcomeStandingSchema = z.object({ \"playerId\": z.string().min(1), \"rank\": z.number().int().gte(1), \"result\": OutcomeResultSchema, \"score\": z.number().finite().optional(), \"scoreBreakdown\": z.array(OutcomeScoreComponentSchema).optional(), \"tieBreaks\": z.array(OutcomeTieBreakSchema).optional() }).strict();\n\nexport const GameOutcomeSchema = z.object({ \"reason\": GameOutcomeReasonSchema, \"standings\": z.array(OutcomeStandingSchema).min(1) }).strict();\n\nexport const GameEventDetailSchema = z.object({ \"label\": z.string().min(1), \"value\": z.union([z.string(), z.number().finite(), z.boolean()]) }).strict();\n\nexport const SystemActionEventSchema = z.object({ \"kind\": z.literal(\"systemAction\"), \"procedureId\": z.string().min(1), \"title\": z.string().min(1), \"summary\": z.string().min(1).optional(), \"details\": z.array(GameEventDetailSchema).max(16).optional() }).strict();\n\nexport const GameEventSchema = z.discriminatedUnion(\"kind\", [SystemActionEventSchema]);\n\nexport const InitializeResultSchema = z.object({ \"state\": ReducerSessionStateSchema, \"terminal\": GameOutcomeSchema.optional(), \"events\": z.array(GameEventSchema).optional() }).strict();\n\nexport const InitializeRequestSchema = z.object({ \"table\": JsonValueSchema, \"playerIds\": z.array(z.string().min(1)), \"rngSeed\": z.union([z.number().refine(Number.isInteger, { message: \"Expected integer\" }), z.null()]).optional(), \"setup\": z.union([ReducerSetupSelectionSchema, z.null()]).optional() }).strict();\n\nexport const InitializePhaseRequestSchema = z.object({ \"state\": ReducerSessionStateSchema, \"to\": z.string().min(1) }).strict();\n\nexport const ValidateInputRequestSchema = z.object({ \"state\": ReducerSessionStateSchema, \"input\": GameInputSchema }).strict();\n\nexport const ReduceRequestSchema = z.object({ \"state\": ReducerSessionStateSchema, \"input\": GameInputSchema }).strict();\n\nexport const DispatchRequestSchema = z.object({ \"state\": ReducerSessionStateSchema, \"input\": GameInputSchema }).strict();\n\nexport const ReduceResultRejectSchema = z.object({ \"kind\": z.literal(\"reject\"), \"errorCode\": z.string().min(1), \"message\": z.string().optional() }).strict();\n\nexport const ReduceResultAcceptSchema = z.object({ \"kind\": z.literal(\"accept\"), \"state\": ReducerSessionStateSchema, \"terminal\": GameOutcomeSchema.optional(), \"effects\": z.array(EffectSchema), \"continuations\": ContinuationMapSchema, \"events\": z.array(GameEventSchema).max(32) }).strict();\n\nexport const ReduceResultSchema = z.discriminatedUnion(\"kind\", [ReduceResultRejectSchema, ReduceResultAcceptSchema]);\n\nexport const DispatchTraceAcceptedClientInputSchema = z.object({ \"kind\": z.literal(\"acceptedClientInput\"), \"input\": GameInputSchema }).strict();\n\nexport const DispatchTraceAppliedEffectSchema = z.object({ \"kind\": z.literal(\"appliedEffect\"), \"effect\": EffectSchema, \"continuation\": ContinuationTokenSchema.optional() }).strict();\n\nexport const DispatchTraceRngConsumptionSchema = z.object({ \"kind\": z.literal(\"rngConsumption\"), \"version\": z.literal(2), \"operation\": z.string().min(1), \"drawIndex\": z.number().int().gte(0), \"traceEntry\": z.string() }).strict();\n\nexport const DispatchTraceSchema = z.discriminatedUnion(\"kind\", [DispatchTraceAcceptedClientInputSchema, DispatchTraceAppliedEffectSchema, DispatchTraceRngConsumptionSchema]);\n\nexport const DispatchResultRejectSchema = z.object({ \"kind\": z.literal(\"reject\"), \"errorCode\": z.string().min(1), \"message\": z.string().optional() }).strict();\n\nexport const DispatchResultAcceptSchema = z.object({ \"kind\": z.literal(\"accept\"), \"state\": ReducerSessionStateSchema, \"terminal\": GameOutcomeSchema.optional(), \"trace\": z.array(DispatchTraceSchema), \"events\": z.array(GameEventSchema).max(32) }).strict();\n\nexport const DispatchResultSchema = z.discriminatedUnion(\"kind\", [DispatchResultRejectSchema, DispatchResultAcceptSchema]);\n\nexport const ReducerRuntimeLogEntryAcceptedClientInputSchema = z.object({ \"kind\": z.literal(\"acceptedClientInput\"), \"version\": z.number().int(), \"input\": GameInputSchema }).strict();\n\nexport const ReducerRuntimeLogEntryAppliedEffectSchema = z.object({ \"kind\": z.literal(\"appliedEffect\"), \"version\": z.number().int(), \"effect\": EffectSchema, \"continuation\": z.union([ContinuationTokenSchema, z.null()]) }).strict();\n\nexport const ReducerRuntimeLogEntryRngConsumptionSchema = z.object({ \"kind\": z.literal(\"rngConsumption\"), \"version\": z.number().int(), \"operation\": z.string().min(1), \"drawIndex\": z.number().int().gte(0).optional(), \"traceEntry\": z.string() }).strict();\n\nexport const ReducerRuntimeLogEntryStateCommitSchema = z.object({ \"kind\": z.literal(\"stateCommit\"), \"version\": z.number().int(), \"state\": ReducerSessionStateSchema }).strict();\n\nexport const ReducerRuntimeLogEntrySchema = z.discriminatedUnion(\"kind\", [ReducerRuntimeLogEntryAcceptedClientInputSchema, ReducerRuntimeLogEntryAppliedEffectSchema, ReducerRuntimeLogEntryRngConsumptionSchema, ReducerRuntimeLogEntryStateCommitSchema]);\n\nexport const SeatProjectionSchema = z.object({ \"view\": JsonValueSchema.optional(), \"availableInteractionRefs\": JsonValueSchema.optional(), \"zones\": JsonValueSchema.optional() }).strict();\n\nexport const SimultaneousPhaseProjectionSchema = z.object({ \"phaseName\": z.string().min(1), \"interactionId\": z.string().min(1), \"actorIds\": z.array(z.string().min(1)), \"sealedPlayerIds\": z.array(z.string().min(1)), \"pendingPlayerIds\": z.array(z.string().min(1)) }).strict();\n\nexport const SchedulerContinuationDependencySchema = z.object({ \"waiterPlayerId\": z.string().min(1), \"blockerPlayerIds\": z.array(z.string().min(1)) }).strict();\n\nexport const SchedulerFlowAuthorityProjectionSchema = z.object({ \"version\": z.literal(1), \"activePlayerIds\": z.array(z.string().min(1)), \"pendingPlayerIds\": z.array(z.string().min(1)), \"continuationDependencies\": z.array(SchedulerContinuationDependencySchema) }).strict();\n\nexport const ProjectionTimingMetadataSchema = z.object({ \"resolveAvailableInteractionsMs\": z.number().finite().gte(0), \"resolveViewMs\": z.number().finite().gte(0), \"resolveZoneHandlesMs\": z.number().finite().gte(0), \"descriptorHashMs\": z.number().finite().gte(0) }).strict();\n\nexport const SeatProjectionBundleSchema = z.object({ \"currentStage\": z.union([z.string().min(1), z.null()]).optional(), \"stageSeats\": z.array(z.string().min(1)).optional(), \"simultaneousPhase\": z.union([SimultaneousPhaseProjectionSchema, z.null()]).optional(), \"schedulerFlow\": SchedulerFlowAuthorityProjectionSchema.optional(), \"sharedView\": JsonValueSchema.optional(), \"interactionsByRef\": JsonValueSchema.optional(), \"seats\": z.record(z.string(), SeatProjectionSchema), \"timing\": ProjectionTimingMetadataSchema.optional() }).strict();\n\nexport const ProjectRequestSchema = z.object({ \"state\": ReducerSessionStateSchema, \"playerIds\": z.array(z.string().min(1)) }).strict();\n\nexport const BoardStaticProjectionSchema = z.object({ \"view\": JsonValueSchema, \"hash\": z.string().min(1), \"manifestVersion\": z.string() }).strict();\n","// @generated by packages/reducer-contract/scripts/generate.ts\n// DO NOT EDIT BY HAND. Edit schema/reducer-runtime.schema.json and rerun `pnpm generate`.\n\n/**\n * The wire-protocol version this package implements. Bumped in lockstep with\n * any breaking change to schema/reducer-runtime.schema.json. At bundle load\n * time hosts require bundles to carry this exact version.\n */\nexport const REDUCER_CONTRACT_VERSION = \"0.5.0\" as const;\n","// @generated by packages/reducer-contract/scripts/generate.ts\n// DO NOT EDIT BY HAND. Edit schema/reducer-runtime.operations.json and rerun `pnpm generate`.\n\n/* eslint-disable */\nimport type * as Wire from \"../generated/wire\";\nimport { REDUCER_CONTRACT_VERSION } from \"../generated/version\";\n\nexport type MaybePromise<T> = T | Promise<T>;\n\n/**\n * Canonical erased reducer boundary for `createReducerBundle(...)`.\n *\n * The callable method list is generated from\n * `schema/reducer-runtime.operations.json`; payload DTOs come from\n * `schema/reducer-runtime.schema.json`.\n *\n * This interface models the host/guest surface only. The concrete\n * authored bundle stays strongly typed in `@dreamboard-games/sdk/reducer`, but every\n * cross-runtime caller should agree on this shape.\n */\nexport interface ReducerBundleContract {\n readonly reducerContractVersion: Wire.ReducerContractVersion;\n initialize(\n input: Wire.InitializeRequest,\n ): MaybePromise<Wire.InitializeResult>;\n dispatch(input: Wire.DispatchRequest): MaybePromise<Wire.DispatchResult>;\n boardStatic(): Wire.BoardStaticProjection | null;\n project(input: Wire.ProjectRequest): Wire.SeatProjectionBundle;\n}\n\n/**\n * Validates an imported module value at the reducer host/guest boundary.\n *\n * The required callable members are generated from the same operation\n * authority as `ReducerBundleContract`, so runtime admission cannot drift\n * from the published TypeScript interface.\n * The contract version must match exactly.\n */\nexport function assertReducerBundleContract(\n value: unknown,\n source: string,\n): asserts value is ReducerBundleContract {\n if (!value || typeof value !== \"object\" || Array.isArray(value)) {\n throw new Error(`Reducer bundle ${source} did not export an object.`);\n }\n\n const bundle = value as Record<string, unknown>;\n if (bundle.reducerContractVersion !== REDUCER_CONTRACT_VERSION) {\n throw new Error(\n `Reducer bundle ${source} requires exact contract ${REDUCER_CONTRACT_VERSION}; received ${String(bundle.reducerContractVersion ?? \"missing\")}.`,\n );\n }\n\n for (const method of [\n \"initialize\",\n \"dispatch\",\n \"boardStatic\",\n \"project\",\n ] as const) {\n if (typeof bundle[method] !== \"function\") {\n throw new Error(`Reducer bundle ${source} is missing ${method}().`);\n }\n }\n}\n","// @generated by packages/reducer-contract/scripts/generate.ts\n// DO NOT EDIT BY HAND. Edit schema/reducer-runtime.schema.json and rerun `pnpm generate`.\n\n/* eslint-disable */\nimport type * as Wire from \"./wire\";\n\n/**\n * Typed effect constructors. Authors MUST go through these; hand-constructing\n * Wire.Effect objects is banned by convention because it's how wire drift\n * re-enters the codebase.\n *\n * The `effectId` is minted by the runtime (see createEffectIdMinter below),\n * not by the author. Each builder returns a `PendingEffect` that carries\n * the optional continuation; the reducer bundle's accept materializer splits\n * pending effects into the wire's `effects[]` + `continuations` map.\n */\n\nexport type PendingEffect = Wire.Effect & {\n readonly __continuation?: Wire.ContinuationToken;\n};\n\nexport type EffectIdMinter = () => Wire.EffectId;\n\n/**\n * Produces sequential, deterministic effect ids scoped to a single accept\n * payload: \"ef0\", \"ef1\", ... . Uniqueness only needs to be local to the\n * payload because the host consumes and discards them per dispatch.\n */\nexport function createEffectIdMinter(): EffectIdMinter {\n let i = 0;\n return () => `ef${i++}` as Wire.EffectId;\n}\n\nexport type EffectBuilders = {\n transition(args: { to: string }, continuation?: Wire.ContinuationToken): PendingEffect;\n rollDie(args: { dieId: string }, continuation?: Wire.ContinuationToken): PendingEffect;\n shuffleSharedZone(args: { zoneId: string }, continuation?: Wire.ContinuationToken): PendingEffect;\n shufflePlayerZone(args: { zoneId: string; playerId: string }, continuation?: Wire.ContinuationToken): PendingEffect;\n};\n\nexport function createEffectBuilders(mint: EffectIdMinter): EffectBuilders {\n return {\n transition(args, continuation) {\n const effect = { effectId: mint(), type: \"transition\" as const, to: args.to };\n return continuation === undefined\n ? (effect as PendingEffect)\n : Object.assign(effect, { __continuation: continuation });\n },\n rollDie(args, continuation) {\n const effect = { effectId: mint(), type: \"rollDie\" as const, dieId: args.dieId };\n return continuation === undefined\n ? (effect as PendingEffect)\n : Object.assign(effect, { __continuation: continuation });\n },\n shuffleSharedZone(args, continuation) {\n const effect = { effectId: mint(), type: \"shuffleSharedZone\" as const, zoneId: args.zoneId };\n return continuation === undefined\n ? (effect as PendingEffect)\n : Object.assign(effect, { __continuation: continuation });\n },\n shufflePlayerZone(args, continuation) {\n const effect = { effectId: mint(), type: \"shufflePlayerZone\" as const, zoneId: args.zoneId, playerId: args.playerId };\n return continuation === undefined\n ? (effect as PendingEffect)\n : Object.assign(effect, { __continuation: continuation });\n },\n };\n}\n\n/**\n * Takes a list of PendingEffects and splits them into the canonical wire\n * shape: `effects[]` (stripped of `__continuation`) + `continuations` map\n * keyed by effectId. Use at the boundary where reduce/dispatch results leave\n * author code and enter the wire.\n */\nexport function materializeAccept(pending: ReadonlyArray<PendingEffect>): {\n effects: Wire.Effect[];\n continuations: Wire.ContinuationMap;\n} {\n const effects: Wire.Effect[] = [];\n const continuations: Wire.ContinuationMap = {};\n for (const pe of pending) {\n const { __continuation, ...effect } = pe as PendingEffect & { __continuation?: Wire.ContinuationToken };\n effects.push(effect as Wire.Effect);\n if (__continuation !== undefined) {\n continuations[(effect as Wire.Effect).effectId] = __continuation;\n }\n }\n return { effects, continuations };\n}\n"],"mappings":";;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA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