@patterkit/core 0.8.0 → 0.9.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/dist/index.cjs +6 -1
- package/dist/index.js +6 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -568,7 +568,12 @@ function validateGameDataValues(project, scenes, issues) {
|
|
|
568
568
|
for (const block of scene.blocks ?? []) {
|
|
569
569
|
check("block", block.id, block.gameData);
|
|
570
570
|
(0, import_model.walkNodes)(block.children ?? [], (node) => {
|
|
571
|
-
if (node.type !== "snippet")
|
|
571
|
+
if (node.type !== "snippet") {
|
|
572
|
+
if (node.selector === "choice") {
|
|
573
|
+
for (const option of node.children ?? []) if (option.type === "group") check("option", option.id, option.gameData);
|
|
574
|
+
}
|
|
575
|
+
return;
|
|
576
|
+
}
|
|
572
577
|
check("snippet", node.id, node.gameData);
|
|
573
578
|
for (const beat of node.beats ?? []) check(beat.kind, beat.id, beat.gameData);
|
|
574
579
|
});
|
package/dist/index.js
CHANGED
|
@@ -530,7 +530,12 @@ function validateGameDataValues(project, scenes, issues) {
|
|
|
530
530
|
for (const block of scene.blocks ?? []) {
|
|
531
531
|
check("block", block.id, block.gameData);
|
|
532
532
|
walkNodes(block.children ?? [], (node) => {
|
|
533
|
-
if (node.type !== "snippet")
|
|
533
|
+
if (node.type !== "snippet") {
|
|
534
|
+
if (node.selector === "choice") {
|
|
535
|
+
for (const option of node.children ?? []) if (option.type === "group") check("option", option.id, option.gameData);
|
|
536
|
+
}
|
|
537
|
+
return;
|
|
538
|
+
}
|
|
534
539
|
check("snippet", node.id, node.gameData);
|
|
535
540
|
for (const beat of node.beats ?? []) check(beat.kind, beat.id, beat.gameData);
|
|
536
541
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@patterkit/core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"description": "Patter core: stable id generation, readable-handle computation, canonical (de)serialisation, and the structural validator.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -34,9 +34,9 @@
|
|
|
34
34
|
"build": "tsup src/index.ts --format esm,cjs --dts --clean"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@patterkit/model": "0.
|
|
37
|
+
"@patterkit/model": "0.16.0",
|
|
38
38
|
"@wildwinter/expr": "^0.6.0",
|
|
39
|
-
"@wildwinter/toolkit": "^0.
|
|
39
|
+
"@wildwinter/toolkit": "^0.2.0",
|
|
40
40
|
"json5": "^2.2.3"
|
|
41
41
|
}
|
|
42
42
|
}
|