@altnovatrail/widgets 0.1.2 → 0.2.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.
Files changed (110) hide show
  1. package/README.md +1 -1
  2. package/cores/vector.schema.json +82 -3
  3. package/kinds/cells/cells.handles.json +148 -3
  4. package/kinds/cells/cells.schema.json +716 -8
  5. package/kinds/cells/vectors/bishop-grid-56-d1-1.json +105 -4
  6. package/kinds/cells/vectors/counter-cases.json +123 -0
  7. package/kinds/cells/vectors/counter-div-56-d1-3.json +57 -0
  8. package/kinds/cells/vectors/counter-div-56-d2-1.json +773 -0
  9. package/kinds/cells/vectors/counter-div-56-d2-3.json +65 -0
  10. package/kinds/cells/vectors/counter-div-56-d4-1.json +57 -0
  11. package/kinds/cells/vectors/counter-div-56-d4-2.json +106 -0
  12. package/kinds/cells/vectors/cut-cases.json +163 -0
  13. package/kinds/cells/vectors/cut-gaps-56-d2-1.json +142 -0
  14. package/kinds/cells/vectors/cut-grid-56-d2-4.json +45 -0
  15. package/kinds/cells/vectors/cut-grid-56-d4-1.json +154 -0
  16. package/kinds/cells/vectors/cut-grid-56-d4-2.json +136 -0
  17. package/kinds/cells/vectors/cut-invalid.json +48 -0
  18. package/kinds/cells/vectors/domino-grid-56-d3-2.json +238 -0
  19. package/kinds/cells/vectors/domino-limit.json +60 -0
  20. package/kinds/cells/vectors/domino-par-56-d3-2.json +194 -0
  21. package/kinds/cells/vectors/domino-par-56-d4-3.json +127 -0
  22. package/kinds/cells/vectors/figure-apart.json +47 -0
  23. package/kinds/cells/vectors/fold-12x12.json +79 -0
  24. package/kinds/cells/vectors/fold-14x14.json +79 -0
  25. package/kinds/cells/vectors/fold-26x26.json +79 -0
  26. package/kinds/cells/vectors/garden-enum-56-d3-4.json +96 -6
  27. package/kinds/cells/vectors/goat-grid-56-d4-4.json +325 -5
  28. package/kinds/cells/vectors/knight-after-no-parity.json +31 -0
  29. package/kinds/cells/vectors/knight-par-56-d2-2.json +61 -6
  30. package/kinds/cells/vectors/mosaic-grid-56-d2-2.json +84 -0
  31. package/kinds/cells/vectors/nodes-gaps-56-d2-2.json +44 -0
  32. package/kinds/cells/vectors/nodes-gaps-56-d4-2.json +70 -0
  33. package/kinds/cells/vectors/number-div-56-d2-2.json +49 -0
  34. package/kinds/cells/vectors/numbers-div-56-d3-1.json +24 -0
  35. package/kinds/cells/vectors/numbers-invalid.json +56 -0
  36. package/kinds/cells/vectors/paper-26x26.json +743 -0
  37. package/kinds/cells/vectors/paper-cube-12-d2-1.json +43 -19
  38. package/kinds/cells/vectors/paper-cube-12-d5-1.json +47 -4
  39. package/kinds/cells/vectors/paper-cube-56-d4-1.json +56 -5
  40. package/kinds/cells/vectors/paper-drawn-lines.json +184 -0
  41. package/kinds/cells/vectors/paper-grid-56-d1-2.json +46 -5
  42. package/kinds/cells/vectors/paper-turn-invalid.json +4 -4
  43. package/kinds/cells/vectors/path-6x6.json +119 -0
  44. package/kinds/cells/vectors/path-beside.json +108 -0
  45. package/kinds/cells/vectors/path-enum-12-d3-5.json +187 -0
  46. package/kinds/cells/vectors/path-enum-34-d4-3.json +412 -0
  47. package/kinds/cells/vectors/path-enum-56-d3-3.json +411 -0
  48. package/kinds/cells/vectors/path-enum-56-d3-5.json +351 -0
  49. package/kinds/cells/vectors/path-invalid.json +37 -0
  50. package/kinds/cells/vectors/path-limit.json +58 -0
  51. package/kinds/cells/vectors/path-maze.json +297 -0
  52. package/kinds/cells/vectors/path-unreachable.json +76 -0
  53. package/kinds/cells/vectors/perimeter-grid-56-d2-1.json +86 -0
  54. package/kinds/cells/vectors/perimeter-grid-56-d3-1.json +102 -0
  55. package/kinds/cells/vectors/perimeter-grid-56-d3-3.json +112 -0
  56. package/kinds/cells/vectors/perimeter-grid-56-d4-3.json +289 -0
  57. package/kinds/cells/vectors/polyomino-cases.json +191 -0
  58. package/kinds/cells/vectors/polyomino-grid-56-d3-4.json +205 -0
  59. package/kinds/cells/vectors/polyomino-grid-56-d4-1.json +137 -0
  60. package/kinds/cells/vectors/polyomino-grid-56-d5-3.json +157 -0
  61. package/kinds/cells/vectors/polyomino-invalid.json +45 -0
  62. package/kinds/cells/vectors/polyomino-one-pieces.json +28 -0
  63. package/kinds/cells/vectors/route-par-56-d3-3.json +245 -0
  64. package/kinds/cells/vectors/sides-gaps-56-d3-2.json +44 -0
  65. package/kinds/cells/vectors/sieve-div-56-d3-2.json +140 -0
  66. package/kinds/cells/vectors/tear-gaps-56-d3-1.json +84 -0
  67. package/kinds/cells/vectors/tear-limit.json +56 -0
  68. package/lib/cores/enumerate.d.ts +33 -0
  69. package/lib/cores/enumerate.js +77 -0
  70. package/lib/cores/kind.d.ts +70 -5
  71. package/lib/cores/kind.js +2 -2
  72. package/lib/cores/search.d.ts +47 -10
  73. package/lib/cores/search.js +129 -37
  74. package/lib/kinds/cells/bishop.d.ts +1 -1
  75. package/lib/kinds/cells/bishop.js +1 -1
  76. package/lib/kinds/cells/counter.d.ts +26 -0
  77. package/lib/kinds/cells/counter.js +249 -0
  78. package/lib/kinds/cells/cut.d.ts +46 -0
  79. package/lib/kinds/cells/cut.js +400 -0
  80. package/lib/kinds/cells/figure.d.ts +13 -0
  81. package/lib/kinds/cells/figure.js +114 -0
  82. package/lib/kinds/cells/holes.d.ts +6 -0
  83. package/lib/kinds/cells/holes.js +57 -0
  84. package/lib/kinds/cells/index.d.ts +8 -0
  85. package/lib/kinds/cells/index.js +10 -2
  86. package/lib/kinds/cells/kind.d.ts +3 -2
  87. package/lib/kinds/cells/kind.js +23 -8
  88. package/lib/kinds/cells/knight.d.ts +1 -1
  89. package/lib/kinds/cells/number.d.ts +6 -0
  90. package/lib/kinds/cells/number.js +32 -0
  91. package/lib/kinds/cells/operation.d.ts +27 -7
  92. package/lib/kinds/cells/paper.d.ts +10 -2
  93. package/lib/kinds/cells/paper.js +109 -13
  94. package/lib/kinds/cells/path.d.ts +38 -0
  95. package/lib/kinds/cells/path.js +288 -0
  96. package/lib/kinds/cells/piece.d.ts +27 -7
  97. package/lib/kinds/cells/piece.js +202 -37
  98. package/lib/kinds/cells/polyomino.d.ts +45 -0
  99. package/lib/kinds/cells/polyomino.js +461 -0
  100. package/lib/kinds/cells/registry.js +35 -4
  101. package/lib/kinds/cells/schema.js +45 -4
  102. package/lib/kinds/cells/sheet.d.ts +20 -1
  103. package/lib/kinds/cells/sheet.js +84 -6
  104. package/lib/kinds/cells/side.d.ts +33 -0
  105. package/lib/kinds/cells/side.js +86 -0
  106. package/lib/kinds/cells/sieve.d.ts +26 -0
  107. package/lib/kinds/cells/sieve.js +208 -0
  108. package/lib/kinds/cells/step.d.ts +1 -1
  109. package/lib/kinds/cells/step.js +1 -1
  110. package/package.json +5 -1
@@ -0,0 +1,65 @@
1
+ {
2
+ "description": "The course's task div-56-d2-3: a loop of 20 stations, the train on station 1 moving on 47 times. A table of numbers from 1 in rows of 20, the counter on 1 counting on by 1: after the 47 moves it stands on 48, the 8th of its row, the station. The scene has no goal: the place is read off the table. A step back is no step of the counter's.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 3,
6
+ "cols": 20,
7
+ "numbers": {
8
+ "first": 1
9
+ }
10
+ },
11
+ "operations": {
12
+ "counter": {
13
+ "cell": "A1",
14
+ "steps": [1]
15
+ }
16
+ }
17
+ },
18
+ "seed": "0",
19
+ "start": {
20
+ "state": {
21
+ "marks": {},
22
+ "counter_at": "A1"
23
+ },
24
+ "goal": false
25
+ },
26
+ "sequences": [
27
+ [
28
+ {
29
+ "move": {
30
+ "counter": {
31
+ "to": "A2"
32
+ }
33
+ },
34
+ "state": {
35
+ "marks": {},
36
+ "counter_at": "A2"
37
+ },
38
+ "goal": false
39
+ },
40
+ {
41
+ "move": {
42
+ "counter": {
43
+ "to": "A1"
44
+ }
45
+ },
46
+ "refused": "not-its-move"
47
+ },
48
+ {
49
+ "move": {
50
+ "counter": {
51
+ "to": "A3"
52
+ }
53
+ },
54
+ "state": {
55
+ "marks": {},
56
+ "counter_at": "A3"
57
+ },
58
+ "goal": false
59
+ }
60
+ ]
61
+ ],
62
+ "proof": {
63
+ "undecided": "no-goal"
64
+ }
65
+ }
@@ -0,0 +1,57 @@
1
+ {
2
+ "description": "The course's task div-56-d4-1: nuts shared among 9 squirrels, as many left over as each one got. A table of numbers from 0 in rows of 9: counted from 0, a number's row is what each squirrel gets, and its column what is left over. The counter on 0 counts on by 10, a row down and a column on, along the diagonal where the two are equal, up to 80 on I9; the next step, to 90 on K1, leaves it. The scene has no goal: the largest number of the rule is read off the table.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 11,
6
+ "cols": 9,
7
+ "numbers": {
8
+ "first": 0
9
+ }
10
+ },
11
+ "operations": {
12
+ "counter": {
13
+ "cell": "A1",
14
+ "steps": [10]
15
+ }
16
+ }
17
+ },
18
+ "seed": "0",
19
+ "start": {
20
+ "state": {
21
+ "marks": {},
22
+ "counter_at": "A1"
23
+ },
24
+ "goal": false
25
+ },
26
+ "sequences": [
27
+ [
28
+ {
29
+ "move": {
30
+ "counter": {
31
+ "to": "B2"
32
+ }
33
+ },
34
+ "state": {
35
+ "marks": {},
36
+ "counter_at": "B2"
37
+ },
38
+ "goal": false
39
+ },
40
+ {
41
+ "move": {
42
+ "counter": {
43
+ "to": "C3"
44
+ }
45
+ },
46
+ "state": {
47
+ "marks": {},
48
+ "counter_at": "C3"
49
+ },
50
+ "goal": false
51
+ }
52
+ ]
53
+ ],
54
+ "proof": {
55
+ "undecided": "no-goal"
56
+ }
57
+ }
@@ -0,0 +1,106 @@
1
+ {
2
+ "description": "The course's task div-56-d4-2: darts of 3 and of 8 points. A table of numbers from 0 in rows of 3, the counter on 0 counting on by 3 or by 8, so each number it stands on is a total that can be scored. The goal asks the greatest number it never stands on, 13, the task's key, read where the counter stands on 14, 8 + 3 + 3: from 14 on, a whole row is reached, and threes reach every number after it. A step of 1 is refused.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 10,
6
+ "cols": 3,
7
+ "numbers": {
8
+ "first": 0
9
+ }
10
+ },
11
+ "operations": {
12
+ "counter": {
13
+ "cell": "A1",
14
+ "steps": [3, 8]
15
+ }
16
+ },
17
+ "goal": {
18
+ "counter_missed": {}
19
+ }
20
+ },
21
+ "seed": "0",
22
+ "start": {
23
+ "state": {
24
+ "marks": {},
25
+ "counter_at": "A1"
26
+ },
27
+ "goal": false
28
+ },
29
+ "sequences": [
30
+ [
31
+ {
32
+ "move": {
33
+ "counter": {
34
+ "to": "A2"
35
+ }
36
+ },
37
+ "refused": "not-its-move"
38
+ },
39
+ {
40
+ "move": {
41
+ "counter": {
42
+ "to": "C3"
43
+ }
44
+ },
45
+ "state": {
46
+ "marks": {},
47
+ "counter_at": "C3"
48
+ },
49
+ "goal": true
50
+ },
51
+ {
52
+ "move": {
53
+ "counter": {
54
+ "to": "D3"
55
+ }
56
+ },
57
+ "state": {
58
+ "marks": {},
59
+ "counter_at": "D3"
60
+ },
61
+ "goal": true
62
+ },
63
+ {
64
+ "move": {
65
+ "counter": {
66
+ "to": "E3"
67
+ }
68
+ },
69
+ "state": {
70
+ "marks": {},
71
+ "counter_at": "E3"
72
+ },
73
+ "goal": true
74
+ }
75
+ ]
76
+ ],
77
+ "proof": {
78
+ "key": 13,
79
+ "asks": "max",
80
+ "witness": {
81
+ "path": [
82
+ {
83
+ "counter": {
84
+ "to": "B1"
85
+ }
86
+ },
87
+ {
88
+ "counter": {
89
+ "to": "C1"
90
+ }
91
+ },
92
+ {
93
+ "counter": {
94
+ "to": "E3"
95
+ }
96
+ }
97
+ ]
98
+ },
99
+ "ends": [
100
+ {
101
+ "marks": {},
102
+ "counter_at": "E3"
103
+ }
104
+ ]
105
+ }
106
+ }
@@ -0,0 +1,163 @@
1
+ {
2
+ "description": "A cut's cases along single sides on a sheet of 3 by 3, C3 a hole and a wall between A1 and A2, with marks on nodes and sides: a colour, a number, or both. A side on the sheet's edge, one beside the hole, the wall and a side cut already are refused. The goal is every cell a part of its own, the fewest cuts the 9 sides between two cells that no hole or wall parts already.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 3,
6
+ "cols": 3,
7
+ "holes": ["C3"],
8
+ "walls": [["A1", "A2"]],
9
+ "node_marks": {
10
+ "v1:h1": {
11
+ "color": "red"
12
+ },
13
+ "v2:h0": {
14
+ "number": 2
15
+ }
16
+ },
17
+ "side_marks": {
18
+ "h3:1": {
19
+ "color": "blue",
20
+ "number": 3
21
+ },
22
+ "h0:2": {
23
+ "color": "green"
24
+ },
25
+ "v0:B": {
26
+ "number": 5
27
+ }
28
+ }
29
+ },
30
+ "operations": {
31
+ "cut": {}
32
+ },
33
+ "goal": {
34
+ "cells_apart": {}
35
+ }
36
+ },
37
+ "seed": "0",
38
+ "start": {
39
+ "state": {
40
+ "marks": {},
41
+ "cut": []
42
+ },
43
+ "goal": false
44
+ },
45
+ "sequences": [
46
+ [
47
+ {
48
+ "move": {
49
+ "cut": {
50
+ "side": "h3:1"
51
+ }
52
+ },
53
+ "refused": "not-between"
54
+ },
55
+ {
56
+ "move": {
57
+ "cut": {
58
+ "side": "v2:C"
59
+ }
60
+ },
61
+ "refused": "beside-hole"
62
+ },
63
+ {
64
+ "move": {
65
+ "cut": {
66
+ "side": "v1:A"
67
+ }
68
+ },
69
+ "refused": "wall"
70
+ },
71
+ {
72
+ "move": {
73
+ "cut": {
74
+ "side": "h1:1"
75
+ }
76
+ },
77
+ "state": {
78
+ "marks": {},
79
+ "cut": ["h1:1"]
80
+ },
81
+ "goal": false
82
+ },
83
+ {
84
+ "move": {
85
+ "cut": {
86
+ "side": "h1:1"
87
+ }
88
+ },
89
+ "refused": "cut"
90
+ },
91
+ {
92
+ "move": {
93
+ "cut": {
94
+ "side": "v2:B"
95
+ }
96
+ },
97
+ "state": {
98
+ "marks": {},
99
+ "cut": ["v2:B", "h1:1"]
100
+ },
101
+ "goal": false
102
+ }
103
+ ]
104
+ ],
105
+ "proof": {
106
+ "key": 9,
107
+ "witness": {
108
+ "path": [
109
+ {
110
+ "cut": {
111
+ "side": "v1:B"
112
+ }
113
+ },
114
+ {
115
+ "cut": {
116
+ "side": "v1:C"
117
+ }
118
+ },
119
+ {
120
+ "cut": {
121
+ "side": "v2:A"
122
+ }
123
+ },
124
+ {
125
+ "cut": {
126
+ "side": "v2:B"
127
+ }
128
+ },
129
+ {
130
+ "cut": {
131
+ "side": "h1:1"
132
+ }
133
+ },
134
+ {
135
+ "cut": {
136
+ "side": "h1:2"
137
+ }
138
+ },
139
+ {
140
+ "cut": {
141
+ "side": "h1:3"
142
+ }
143
+ },
144
+ {
145
+ "cut": {
146
+ "side": "h2:1"
147
+ }
148
+ },
149
+ {
150
+ "cut": {
151
+ "side": "h2:2"
152
+ }
153
+ }
154
+ ]
155
+ },
156
+ "ends": [
157
+ {
158
+ "marks": {},
159
+ "cut": ["v1:B", "v1:C", "v2:A", "v2:B", "h1:1", "h1:2", "h1:3", "h2:1", "h2:2"]
160
+ }
161
+ ]
162
+ }
163
+ }
@@ -0,0 +1,142 @@
1
+ {
2
+ "description": "The course's task gaps-56-d2-1: a cake cut straight from edge to edge 3 times along and 4 times across, laid as a sheet of 4 rows of 5 whose lines are the places of the cuts. Each cut runs along its whole line; the goal asks the most pieces, 20, the task's key, once every line is cut. The sequence cuts a line each way; a line cut already is refused.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 4,
6
+ "cols": 5
7
+ },
8
+ "operations": {
9
+ "cut": {
10
+ "along": "line"
11
+ }
12
+ },
13
+ "goal": {
14
+ "parts": {}
15
+ }
16
+ },
17
+ "seed": "0",
18
+ "start": {
19
+ "state": {
20
+ "marks": {},
21
+ "cut": []
22
+ },
23
+ "goal": true
24
+ },
25
+ "sequences": [
26
+ [
27
+ {
28
+ "move": {
29
+ "cut": {
30
+ "side": "v2:C"
31
+ }
32
+ },
33
+ "state": {
34
+ "marks": {},
35
+ "cut": ["v2:A", "v2:B", "v2:C", "v2:D"]
36
+ },
37
+ "goal": true
38
+ },
39
+ {
40
+ "move": {
41
+ "cut": {
42
+ "side": "h1:4"
43
+ }
44
+ },
45
+ "state": {
46
+ "marks": {},
47
+ "cut": ["v2:A", "v2:B", "v2:C", "v2:D", "h1:1", "h1:2", "h1:3", "h1:4", "h1:5"]
48
+ },
49
+ "goal": true
50
+ },
51
+ {
52
+ "move": {
53
+ "cut": {
54
+ "side": "v2:A"
55
+ }
56
+ },
57
+ "refused": "cut"
58
+ }
59
+ ]
60
+ ],
61
+ "proof": {
62
+ "key": 20,
63
+ "asks": "max",
64
+ "witness": {
65
+ "path": [
66
+ {
67
+ "cut": {
68
+ "side": "v1:A"
69
+ }
70
+ },
71
+ {
72
+ "cut": {
73
+ "side": "v2:A"
74
+ }
75
+ },
76
+ {
77
+ "cut": {
78
+ "side": "v3:A"
79
+ }
80
+ },
81
+ {
82
+ "cut": {
83
+ "side": "v4:A"
84
+ }
85
+ },
86
+ {
87
+ "cut": {
88
+ "side": "h1:1"
89
+ }
90
+ },
91
+ {
92
+ "cut": {
93
+ "side": "h2:1"
94
+ }
95
+ },
96
+ {
97
+ "cut": {
98
+ "side": "h3:1"
99
+ }
100
+ }
101
+ ]
102
+ },
103
+ "ends": [
104
+ {
105
+ "marks": {},
106
+ "cut": [
107
+ "v1:A",
108
+ "v1:B",
109
+ "v1:C",
110
+ "v1:D",
111
+ "v2:A",
112
+ "v2:B",
113
+ "v2:C",
114
+ "v2:D",
115
+ "v3:A",
116
+ "v3:B",
117
+ "v3:C",
118
+ "v3:D",
119
+ "v4:A",
120
+ "v4:B",
121
+ "v4:C",
122
+ "v4:D",
123
+ "h1:1",
124
+ "h1:2",
125
+ "h1:3",
126
+ "h1:4",
127
+ "h1:5",
128
+ "h2:1",
129
+ "h2:2",
130
+ "h2:3",
131
+ "h2:4",
132
+ "h2:5",
133
+ "h3:1",
134
+ "h3:2",
135
+ "h3:3",
136
+ "h3:4",
137
+ "h3:5"
138
+ ]
139
+ }
140
+ ]
141
+ }
142
+ }
@@ -0,0 +1,45 @@
1
+ {
2
+ "description": "The course's task grid-56-d2-4: a sheet of 4 by 4 cells, one cut from top to bottom down the middle and one from the left edge to it, halfway down. The cuts the statement draws are walls of the sheet, which part it as cuts do, and the sheet is only to look at. The goal asks the most parts, the sheet's own 3, the task's key. A cut is refused: the scene allows none.",
3
+ "scene": {
4
+ "sheet": {
5
+ "rows": 4,
6
+ "cols": 4,
7
+ "walls": [["A2", "A3"], ["B2", "B3"], ["C2", "C3"], ["D2", "D3"], ["B1", "C1"], ["B2", "C2"]]
8
+ },
9
+ "operations": {},
10
+ "goal": {
11
+ "parts": {}
12
+ }
13
+ },
14
+ "seed": "0",
15
+ "start": {
16
+ "state": {
17
+ "marks": {}
18
+ },
19
+ "goal": true
20
+ },
21
+ "sequences": [
22
+ [
23
+ {
24
+ "move": {
25
+ "cut": {
26
+ "side": "v1:A"
27
+ }
28
+ },
29
+ "refused": "op-not-in-scene"
30
+ }
31
+ ]
32
+ ],
33
+ "proof": {
34
+ "key": 3,
35
+ "asks": "max",
36
+ "witness": {
37
+ "path": []
38
+ },
39
+ "ends": [
40
+ {
41
+ "marks": {}
42
+ }
43
+ ]
44
+ }
45
+ }