@elaraai/e3-ui 1.0.98 → 1.0.99

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 (381) hide show
  1. package/README.md +0 -2
  2. package/dist/src/allocation/adapters.d.ts +1 -1
  3. package/dist/src/allocation/adapters.js +1 -1
  4. package/dist/src/allocation/index.d.ts +46 -90
  5. package/dist/src/allocation/index.d.ts.map +1 -1
  6. package/dist/src/allocation/index.js +5 -5
  7. package/dist/src/allocation/index.js.map +1 -1
  8. package/dist/src/bind/data-indexed.d.ts +273 -51
  9. package/dist/src/bind/data-indexed.d.ts.map +1 -1
  10. package/dist/src/bind/data-indexed.js +233 -56
  11. package/dist/src/bind/data-indexed.js.map +1 -1
  12. package/dist/src/bind/data.d.ts +48 -9
  13. package/dist/src/bind/data.d.ts.map +1 -1
  14. package/dist/src/bind/data.js +48 -3
  15. package/dist/src/bind/data.js.map +1 -1
  16. package/dist/src/bind/record.d.ts +61 -24
  17. package/dist/src/bind/record.d.ts.map +1 -1
  18. package/dist/src/bind/record.js +17 -57
  19. package/dist/src/bind/record.js.map +1 -1
  20. package/dist/src/calendar/index.d.ts +55 -95
  21. package/dist/src/calendar/index.d.ts.map +1 -1
  22. package/dist/src/calendar/index.js +10 -6
  23. package/dist/src/calendar/index.js.map +1 -1
  24. package/dist/src/flowchart/index.d.ts +35 -31
  25. package/dist/src/flowchart/index.d.ts.map +1 -1
  26. package/dist/src/flowchart/index.js +35 -31
  27. package/dist/src/flowchart/index.js.map +1 -1
  28. package/dist/src/flowchart/library.d.ts +108 -84
  29. package/dist/src/flowchart/library.d.ts.map +1 -1
  30. package/dist/src/flowchart/library.js +108 -84
  31. package/dist/src/flowchart/library.js.map +1 -1
  32. package/dist/src/flowchart/payload.d.ts +39 -107
  33. package/dist/src/flowchart/payload.d.ts.map +1 -1
  34. package/dist/src/flowchart/payload.js +3 -3
  35. package/dist/src/flowchart/payload.js.map +1 -1
  36. package/dist/src/flowchart/values.d.ts +35 -31
  37. package/dist/src/flowchart/values.d.ts.map +1 -1
  38. package/dist/src/flowchart/values.js +35 -31
  39. package/dist/src/flowchart/values.js.map +1 -1
  40. package/dist/src/flowchart/window.d.ts +0 -12
  41. package/dist/src/flowchart/window.d.ts.map +1 -1
  42. package/dist/src/flowchart/window.js +3 -2
  43. package/dist/src/flowchart/window.js.map +1 -1
  44. package/dist/src/index.d.ts +2 -2
  45. package/dist/src/index.d.ts.map +1 -1
  46. package/dist/src/index.js +1 -1
  47. package/dist/src/index.js.map +1 -1
  48. package/dist/src/internal.d.ts +7 -3
  49. package/dist/src/internal.d.ts.map +1 -1
  50. package/dist/src/internal.js +12 -3
  51. package/dist/src/internal.js.map +1 -1
  52. package/dist/src/plan/assemble.d.ts +8 -0
  53. package/dist/src/plan/assemble.d.ts.map +1 -1
  54. package/dist/src/plan/assemble.js +1 -1
  55. package/dist/src/plan/assemble.js.map +1 -1
  56. package/dist/src/plan/builders.d.ts +1518 -2
  57. package/dist/src/plan/builders.d.ts.map +1 -1
  58. package/dist/src/plan/builders.js +248 -114
  59. package/dist/src/plan/builders.js.map +1 -1
  60. package/dist/src/plan/event-rows.d.ts +9 -14
  61. package/dist/src/plan/event-rows.d.ts.map +1 -1
  62. package/dist/src/plan/event-rows.js +6 -46
  63. package/dist/src/plan/event-rows.js.map +1 -1
  64. package/dist/src/plan/factories.d.ts +72 -4
  65. package/dist/src/plan/factories.d.ts.map +1 -1
  66. package/dist/src/plan/factories.js +147 -1
  67. package/dist/src/plan/factories.js.map +1 -1
  68. package/dist/src/plan/index.d.ts +147 -125
  69. package/dist/src/plan/index.d.ts.map +1 -1
  70. package/dist/src/plan/index.js +135 -122
  71. package/dist/src/plan/index.js.map +1 -1
  72. package/dist/src/plan/ir.d.ts +1105 -44
  73. package/dist/src/plan/ir.d.ts.map +1 -1
  74. package/dist/src/plan/ir.js +5 -0
  75. package/dist/src/plan/ir.js.map +1 -1
  76. package/dist/src/plan/library.d.ts +65 -42
  77. package/dist/src/plan/library.d.ts.map +1 -1
  78. package/dist/src/plan/library.js +65 -42
  79. package/dist/src/plan/library.js.map +1 -1
  80. package/dist/src/plan/nested-checks.d.ts +146 -0
  81. package/dist/src/plan/nested-checks.d.ts.map +1 -0
  82. package/dist/src/plan/nested-checks.js +468 -0
  83. package/dist/src/plan/nested-checks.js.map +1 -0
  84. package/dist/src/plan/nested-patch.d.ts +35 -0
  85. package/dist/src/plan/nested-patch.d.ts.map +1 -0
  86. package/dist/src/plan/nested-patch.js +143 -0
  87. package/dist/src/plan/nested-patch.js.map +1 -0
  88. package/dist/src/plan/nested-read.d.ts +3250 -0
  89. package/dist/src/plan/nested-read.d.ts.map +1 -0
  90. package/dist/src/plan/nested-read.js +163 -0
  91. package/dist/src/plan/nested-read.js.map +1 -0
  92. package/dist/src/plan/nested.d.ts +280 -0
  93. package/dist/src/plan/nested.d.ts.map +1 -0
  94. package/dist/src/plan/nested.js +6 -0
  95. package/dist/src/plan/nested.js.map +1 -0
  96. package/dist/src/plan/ordered-source.d.ts +1030 -1
  97. package/dist/src/plan/ordered-source.d.ts.map +1 -1
  98. package/dist/src/plan/ordered-source.js +48 -6
  99. package/dist/src/plan/ordered-source.js.map +1 -1
  100. package/dist/src/plan/over.d.ts +111 -75
  101. package/dist/src/plan/over.d.ts.map +1 -1
  102. package/dist/src/plan/over.js +111 -75
  103. package/dist/src/plan/over.js.map +1 -1
  104. package/dist/src/plan/pick.d.ts +15 -3
  105. package/dist/src/plan/pick.d.ts.map +1 -1
  106. package/dist/src/plan/pick.js +75 -36
  107. package/dist/src/plan/pick.js.map +1 -1
  108. package/dist/src/plan/plan.d.ts +2719 -558
  109. package/dist/src/plan/plan.d.ts.map +1 -1
  110. package/dist/src/plan/plan.js +14 -2
  111. package/dist/src/plan/plan.js.map +1 -1
  112. package/dist/src/plan/reads.d.ts +421 -0
  113. package/dist/src/plan/reads.d.ts.map +1 -0
  114. package/dist/src/plan/reads.js +143 -0
  115. package/dist/src/plan/reads.js.map +1 -0
  116. package/dist/src/plan/refs.d.ts +111 -75
  117. package/dist/src/plan/refs.d.ts.map +1 -1
  118. package/dist/src/plan/refs.js +111 -75
  119. package/dist/src/plan/refs.js.map +1 -1
  120. package/dist/src/plan/root.d.ts +10 -5
  121. package/dist/src/plan/root.d.ts.map +1 -1
  122. package/dist/src/plan/root.js +76 -13
  123. package/dist/src/plan/root.js.map +1 -1
  124. package/dist/src/plan/series.d.ts +5140 -4331
  125. package/dist/src/plan/series.d.ts.map +1 -1
  126. package/dist/src/plan/series.js +1026 -264
  127. package/dist/src/plan/series.js.map +1 -1
  128. package/dist/src/plan/shade.d.ts +981 -0
  129. package/dist/src/plan/shade.d.ts.map +1 -0
  130. package/dist/src/plan/shade.js +60 -0
  131. package/dist/src/plan/shade.js.map +1 -0
  132. package/dist/src/plan/types.d.ts +178 -18
  133. package/dist/src/plan/types.d.ts.map +1 -1
  134. package/dist/src/plan/types.js +69 -19
  135. package/dist/src/plan/types.js.map +1 -1
  136. package/dist/src/query/builder.d.ts +3 -3
  137. package/dist/src/query/builder.d.ts.map +1 -1
  138. package/dist/src/query/builder.js +1 -1
  139. package/dist/src/query/library.d.ts +3 -3
  140. package/dist/src/query/library.d.ts.map +1 -1
  141. package/dist/src/query/library.js +1 -1
  142. package/dist/src/query/queries.d.ts +2 -2
  143. package/dist/src/query/queries.js +1 -1
  144. package/dist/src/query/saved.d.ts +8 -4
  145. package/dist/src/query/saved.d.ts.map +1 -1
  146. package/dist/src/query/saved.js +8 -4
  147. package/dist/src/query/saved.js.map +1 -1
  148. package/dist/src/query/types.d.ts +8 -3
  149. package/dist/src/query/types.d.ts.map +1 -1
  150. package/dist/src/query/types.js +8 -3
  151. package/dist/src/query/types.js.map +1 -1
  152. package/dist/src/roster/index.d.ts +47 -91
  153. package/dist/src/roster/index.d.ts.map +1 -1
  154. package/dist/src/roster/index.js +6 -6
  155. package/dist/src/roster/index.js.map +1 -1
  156. package/dist/src/roster/targets.d.ts +8 -4
  157. package/dist/src/roster/targets.d.ts.map +1 -1
  158. package/dist/src/roster/targets.js +9 -5
  159. package/dist/src/roster/targets.js.map +1 -1
  160. package/dist/src/schedule/cell-checks.js +3 -3
  161. package/dist/src/schedule/cell-checks.js.map +1 -1
  162. package/dist/src/schedule/days.d.ts +1 -1
  163. package/dist/src/schedule/days.js +1 -1
  164. package/dist/src/schedule/events.d.ts +10 -6
  165. package/dist/src/schedule/events.d.ts.map +1 -1
  166. package/dist/src/schedule/events.js +252 -228
  167. package/dist/src/schedule/events.js.map +1 -1
  168. package/dist/src/schedule/patch.d.ts +1 -1
  169. package/dist/src/schedule/patch.js +1 -1
  170. package/dist/src/schedule/periods.d.ts +8 -4
  171. package/dist/src/schedule/periods.d.ts.map +1 -1
  172. package/dist/src/schedule/periods.js +1 -1
  173. package/dist/src/schedule/periods.js.map +1 -1
  174. package/dist/src/schedule/record-window.d.ts +38 -58
  175. package/dist/src/schedule/record-window.d.ts.map +1 -1
  176. package/dist/src/schedule/record-window.js +15 -16
  177. package/dist/src/schedule/record-window.js.map +1 -1
  178. package/dist/src/schedule/resources.d.ts +1 -1
  179. package/dist/src/schedule/session.d.ts +1 -1
  180. package/dist/src/schedule/session.js +1 -1
  181. package/dist/src/schedule/types.d.ts +29 -1
  182. package/dist/src/schedule/types.d.ts.map +1 -1
  183. package/dist/src/schedule/types.js +16 -1
  184. package/dist/src/schedule/types.js.map +1 -1
  185. package/dist/src/schematic/index.d.ts +19 -9
  186. package/dist/src/schematic/index.d.ts.map +1 -1
  187. package/dist/src/schematic/index.js +19 -9
  188. package/dist/src/schematic/index.js.map +1 -1
  189. package/dist/src/schematic/kinds.d.ts +4 -4
  190. package/dist/src/schematic/kinds.js +9 -9
  191. package/dist/src/schematic/kinds.js.map +1 -1
  192. package/dist/src/schematic/payload.d.ts +38 -88
  193. package/dist/src/schematic/payload.d.ts.map +1 -1
  194. package/dist/src/schematic/payload.js +4 -4
  195. package/dist/src/schematic/payload.js.map +1 -1
  196. package/dist/src/schematic/window.d.ts +8 -7
  197. package/dist/src/schematic/window.d.ts.map +1 -1
  198. package/dist/src/schematic/window.js +22 -19
  199. package/dist/src/schematic/window.js.map +1 -1
  200. package/dist/src/sheet/bridge.d.ts +19 -0
  201. package/dist/src/sheet/bridge.d.ts.map +1 -1
  202. package/dist/src/sheet/bridge.js +28 -21
  203. package/dist/src/sheet/bridge.js.map +1 -1
  204. package/dist/src/sheet/index.d.ts +66 -46
  205. package/dist/src/sheet/index.d.ts.map +1 -1
  206. package/dist/src/sheet/index.js +66 -46
  207. package/dist/src/sheet/index.js.map +1 -1
  208. package/dist/src/sheet/library.d.ts +13 -8
  209. package/dist/src/sheet/library.d.ts.map +1 -1
  210. package/dist/src/sheet/library.js +13 -8
  211. package/dist/src/sheet/library.js.map +1 -1
  212. package/dist/src/sheet/record.d.ts +1 -1
  213. package/dist/src/sheet/record.js +2 -2
  214. package/dist/src/sheet/record.js.map +1 -1
  215. package/dist/src/sheet/registers.d.ts +152 -128
  216. package/dist/src/sheet/registers.d.ts.map +1 -1
  217. package/dist/src/sheet/registers.js +152 -128
  218. package/dist/src/sheet/registers.js.map +1 -1
  219. package/dist/src/sheet/root.d.ts +4 -1
  220. package/dist/src/sheet/root.d.ts.map +1 -1
  221. package/dist/src/sheet/root.js +15 -3
  222. package/dist/src/sheet/root.js.map +1 -1
  223. package/dist/src/sheet/sheet.d.ts +39 -113
  224. package/dist/src/sheet/sheet.d.ts.map +1 -1
  225. package/dist/src/sheet/sheet.js +7 -5
  226. package/dist/src/sheet/sheet.js.map +1 -1
  227. package/dist/src/sheet/sub-rows.d.ts +106 -76
  228. package/dist/src/sheet/sub-rows.d.ts.map +1 -1
  229. package/dist/src/sheet/sub-rows.js +106 -76
  230. package/dist/src/sheet/sub-rows.js.map +1 -1
  231. package/dist/src/sheet/types.d.ts +19 -62
  232. package/dist/src/sheet/types.d.ts.map +1 -1
  233. package/dist/src/studio/builder.d.ts +3 -153
  234. package/dist/src/studio/builder.d.ts.map +1 -1
  235. package/dist/src/studio/builder.js +1 -1
  236. package/dist/src/studio/canvas.d.ts +5 -4
  237. package/dist/src/studio/canvas.d.ts.map +1 -1
  238. package/dist/src/studio/canvas.js +8 -7
  239. package/dist/src/studio/canvas.js.map +1 -1
  240. package/dist/src/studio/component.d.ts +30 -20
  241. package/dist/src/studio/component.d.ts.map +1 -1
  242. package/dist/src/studio/component.js +26 -61
  243. package/dist/src/studio/component.js.map +1 -1
  244. package/dist/src/studio/index.d.ts +2 -2
  245. package/dist/src/studio/index.d.ts.map +1 -1
  246. package/dist/src/studio/index.js +1 -1
  247. package/dist/src/studio/index.js.map +1 -1
  248. package/dist/src/studio/inspector.d.ts +10 -39
  249. package/dist/src/studio/inspector.d.ts.map +1 -1
  250. package/dist/src/studio/inspector.js +11 -31
  251. package/dist/src/studio/inspector.js.map +1 -1
  252. package/dist/src/studio/library.d.ts +3 -169
  253. package/dist/src/studio/library.d.ts.map +1 -1
  254. package/dist/src/studio/library.js +1 -1
  255. package/dist/src/studio/page.d.ts +0 -8
  256. package/dist/src/studio/page.d.ts.map +1 -1
  257. package/dist/src/studio/pages.d.ts +17 -591
  258. package/dist/src/studio/pages.d.ts.map +1 -1
  259. package/dist/src/studio/pages.js +17 -44
  260. package/dist/src/studio/pages.js.map +1 -1
  261. package/dist/src/studio/palette.d.ts +2 -7
  262. package/dist/src/studio/palette.d.ts.map +1 -1
  263. package/dist/src/studio/palette.js +4 -5
  264. package/dist/src/studio/palette.js.map +1 -1
  265. package/dist/src/studio/publish.d.ts +8 -18
  266. package/dist/src/studio/publish.d.ts.map +1 -1
  267. package/dist/src/studio/publish.js +10 -36
  268. package/dist/src/studio/publish.js.map +1 -1
  269. package/dist/src/utils/derive.d.ts +12 -12
  270. package/dist/src/utils/derive.d.ts.map +1 -1
  271. package/dist/src/utils/derive.js +5 -2
  272. package/dist/src/utils/derive.js.map +1 -1
  273. package/dist/src/utils/ordered-source.d.ts.map +1 -1
  274. package/dist/src/utils/ordered-source.js +14 -5
  275. package/dist/src/utils/ordered-source.js.map +1 -1
  276. package/dist/test/allocation/allocation.examples.d.ts +1900 -1598
  277. package/dist/test/allocation/allocation.examples.d.ts.map +1 -1
  278. package/dist/test/allocation/allocation.examples.js +179 -89
  279. package/dist/test/allocation/allocation.examples.js.map +1 -1
  280. package/dist/test/allocation/optimise.examples.d.ts.map +1 -1
  281. package/dist/test/allocation/optimise.examples.js +7 -7
  282. package/dist/test/allocation/optimise.examples.js.map +1 -1
  283. package/dist/test/bind/data/data.examples.d.ts +1057 -903
  284. package/dist/test/bind/data/data.examples.d.ts.map +1 -1
  285. package/dist/test/bind/data/data.examples.js +260 -204
  286. package/dist/test/bind/data/data.examples.js.map +1 -1
  287. package/dist/test/bind/record/record.examples.d.ts +457 -426
  288. package/dist/test/bind/record/record.examples.d.ts.map +1 -1
  289. package/dist/test/bind/record/record.examples.js +41 -21
  290. package/dist/test/bind/record/record.examples.js.map +1 -1
  291. package/dist/test/calendar/calendar-records.examples.d.ts +162 -170
  292. package/dist/test/calendar/calendar-records.examples.d.ts.map +1 -1
  293. package/dist/test/calendar/calendar-records.examples.js +20 -12
  294. package/dist/test/calendar/calendar-records.examples.js.map +1 -1
  295. package/dist/test/calendar/calendar-windows.examples.d.ts.map +1 -1
  296. package/dist/test/calendar/calendar-windows.examples.js +12 -12
  297. package/dist/test/calendar/calendar-windows.examples.js.map +1 -1
  298. package/dist/test/calendar/calendar.examples.d.ts +1172 -901
  299. package/dist/test/calendar/calendar.examples.d.ts.map +1 -1
  300. package/dist/test/calendar/calendar.examples.js +211 -124
  301. package/dist/test/calendar/calendar.examples.js.map +1 -1
  302. package/dist/test/calendar/optimise.examples.js +2 -2
  303. package/dist/test/calendar/optimise.examples.js.map +1 -1
  304. package/dist/test/examples-package.d.ts +6 -9
  305. package/dist/test/examples-package.d.ts.map +1 -1
  306. package/dist/test/examples-package.js +11 -32
  307. package/dist/test/examples-package.js.map +1 -1
  308. package/dist/test/flowchart/flowchart.examples.d.ts +3841 -2820
  309. package/dist/test/flowchart/flowchart.examples.d.ts.map +1 -1
  310. package/dist/test/flowchart/flowchart.examples.js +211 -121
  311. package/dist/test/flowchart/flowchart.examples.js.map +1 -1
  312. package/dist/test/plan/optimise.examples.js +2 -2
  313. package/dist/test/plan/optimise.examples.js.map +1 -1
  314. package/dist/test/plan/plan-events.examples.d.ts +4055 -3263
  315. package/dist/test/plan/plan-events.examples.d.ts.map +1 -1
  316. package/dist/test/plan/plan-events.examples.js +492 -319
  317. package/dist/test/plan/plan-events.examples.js.map +1 -1
  318. package/dist/test/plan/plan-nested.examples.d.ts +1829 -0
  319. package/dist/test/plan/plan-nested.examples.d.ts.map +1 -0
  320. package/dist/test/plan/plan-nested.examples.js +321 -0
  321. package/dist/test/plan/plan-nested.examples.js.map +1 -0
  322. package/dist/test/plan/plan-records.examples.d.ts +328 -362
  323. package/dist/test/plan/plan-records.examples.d.ts.map +1 -1
  324. package/dist/test/plan/plan-records.examples.js +81 -57
  325. package/dist/test/plan/plan-records.examples.js.map +1 -1
  326. package/dist/test/plan/plan-windows.examples.d.ts +1756 -1398
  327. package/dist/test/plan/plan-windows.examples.d.ts.map +1 -1
  328. package/dist/test/plan/plan-windows.examples.js +161 -128
  329. package/dist/test/plan/plan-windows.examples.js.map +1 -1
  330. package/dist/test/plan/plan.examples.d.ts +2238 -5712
  331. package/dist/test/plan/plan.examples.d.ts.map +1 -1
  332. package/dist/test/plan/plan.examples.js +839 -968
  333. package/dist/test/plan/plan.examples.js.map +1 -1
  334. package/dist/test/query/query.examples.d.ts +5221 -3005
  335. package/dist/test/query/query.examples.d.ts.map +1 -1
  336. package/dist/test/query/query.examples.js +169 -118
  337. package/dist/test/query/query.examples.js.map +1 -1
  338. package/dist/test/roster/optimise.examples.d.ts.map +1 -1
  339. package/dist/test/roster/optimise.examples.js +7 -7
  340. package/dist/test/roster/optimise.examples.js.map +1 -1
  341. package/dist/test/roster/roster-records.examples.d.ts +364 -392
  342. package/dist/test/roster/roster-records.examples.d.ts.map +1 -1
  343. package/dist/test/roster/roster-records.examples.js +40 -26
  344. package/dist/test/roster/roster-records.examples.js.map +1 -1
  345. package/dist/test/roster/roster.examples.d.ts +4605 -4308
  346. package/dist/test/roster/roster.examples.d.ts.map +1 -1
  347. package/dist/test/roster/roster.examples.js +212 -113
  348. package/dist/test/roster/roster.examples.js.map +1 -1
  349. package/dist/test/schedule/schedule.examples.d.ts +2646 -2471
  350. package/dist/test/schedule/schedule.examples.d.ts.map +1 -1
  351. package/dist/test/schedule/schedule.examples.js +144 -88
  352. package/dist/test/schedule/schedule.examples.js.map +1 -1
  353. package/dist/test/schematic/schematic-records.examples.d.ts +286 -276
  354. package/dist/test/schematic/schematic-records.examples.d.ts.map +1 -1
  355. package/dist/test/schematic/schematic-records.examples.js +52 -38
  356. package/dist/test/schematic/schematic-records.examples.js.map +1 -1
  357. package/dist/test/schematic/schematic.examples.d.ts +1842 -1491
  358. package/dist/test/schematic/schematic.examples.d.ts.map +1 -1
  359. package/dist/test/schematic/schematic.examples.js +240 -134
  360. package/dist/test/schematic/schematic.examples.js.map +1 -1
  361. package/dist/test/sheet/optimise.examples.d.ts +102 -95
  362. package/dist/test/sheet/optimise.examples.d.ts.map +1 -1
  363. package/dist/test/sheet/optimise.examples.js +7 -3
  364. package/dist/test/sheet/optimise.examples.js.map +1 -1
  365. package/dist/test/sheet/sheet-records.examples.d.ts +175 -214
  366. package/dist/test/sheet/sheet-records.examples.d.ts.map +1 -1
  367. package/dist/test/sheet/sheet-records.examples.js +29 -17
  368. package/dist/test/sheet/sheet-records.examples.js.map +1 -1
  369. package/dist/test/sheet/sheet.examples.d.ts +3642 -3353
  370. package/dist/test/sheet/sheet.examples.d.ts.map +1 -1
  371. package/dist/test/sheet/sheet.examples.js +389 -282
  372. package/dist/test/sheet/sheet.examples.js.map +1 -1
  373. package/dist/test/studio/component.examples.js +2 -2
  374. package/dist/test/studio/component.examples.js.map +1 -1
  375. package/dist/test/studio/page.examples.js +6 -6
  376. package/dist/test/studio/page.examples.js.map +1 -1
  377. package/dist/test/studio/studio.examples.d.ts +2329 -873
  378. package/dist/test/studio/studio.examples.d.ts.map +1 -1
  379. package/dist/test/studio/studio.examples.js +155 -107
  380. package/dist/test/studio/studio.examples.js.map +1 -1
  381. package/package.json +15 -11
@@ -43,8 +43,8 @@ export const OpsRow = StructType({
43
43
  load: FloatType,
44
44
  state: EventStateType,
45
45
  });
46
- /** One hall's presses (or the delivery vans), keyed by id. */
47
- export const OpsHall = DictType(StringType, OpsRow);
46
+ /** One hall — its presses (or the delivery vans), a Dict keyed by id, which its series step down into by field. */
47
+ export const OpsHall = StructType({ presses: DictType(StringType, OpsRow) });
48
48
  /**
49
49
  * The seeded ops schedule — an `e3.input`'s default IS the dataset's initial
50
50
  * value, so this is what a freshly-deployed workspace (and the offline
@@ -60,80 +60,80 @@ export const OpsHall = DictType(StringType, OpsRow);
60
60
  * estimated ahead of it.
61
61
  */
62
62
  export const opsInput = e3.input('ops', DictType(StringType, OpsHall), variant('value', new Map([
63
- ["Hall 1", new Map([
64
- ["H1-P01", { ticket: "J-4603", startWeek: 25n, weeks: 3n, sheets: 96.0, load: 78.0, state: ACTUAL }],
65
- ["H1-P02", { ticket: "J-4612", startWeek: 26n, weeks: 2n, sheets: 64.0, load: 71.0, state: ACTUAL }],
66
- ["H1-P03", { ticket: "J-4642", startWeek: 28n, weeks: 3n, sheets: 112.0, load: 88.0, state: RUNNING }],
67
- ["H1-P04", { ticket: "J-4624", startWeek: 27n, weeks: 4n, sheets: 104.0, load: 84.0, state: RUNNING }],
68
- ["H1-P05", { ticket: "J-4657", startWeek: 31n, weeks: 3n, sheets: 88.0, load: 66.0, state: CONFIRMED }],
69
- ["H1-P06", { ticket: "J-4669", startWeek: 32n, weeks: 2n, sheets: 72.0, load: 59.0, state: CONFIRMED }],
70
- ["H1-P07", { ticket: "J-4693", startWeek: 33n, weeks: 4n, sheets: 120.0, load: 92.0, state: PROPOSED }],
71
- ["H1-P08", { ticket: "J-4708", startWeek: 35n, weeks: 3n, sheets: 96.0, load: 74.0, state: PROPOSED }],
72
- ["H1-P09", { ticket: "J-4726", startWeek: 36n, weeks: 3n, sheets: 80.0, load: 63.0, state: ESTIMATED }],
73
- ["H1-P10", { ticket: "J-4741", startWeek: 37n, weeks: 2n, sheets: 56.0, load: 48.0, state: ESTIMATED }],
74
- ])],
75
- ["Hall 2", new Map([
76
- ["H2-P01", { ticket: "J-4906", startWeek: 25n, weeks: 4n, sheets: 118.0, load: 91.0, state: ACTUAL }],
77
- ["H2-P02", { ticket: "J-4921", startWeek: 27n, weeks: 2n, sheets: 52.0, load: 55.0, state: ACTUAL }],
78
- ["H2-P03", { ticket: "J-4933", startWeek: 29n, weeks: 3n, sheets: 92.0, load: 80.0, state: RUNNING }],
79
- ["H2-P04", { ticket: "J-4948", startWeek: 30n, weeks: 2n, sheets: 68.0, load: 61.0, state: CONFIRMED }],
80
- ["H2-P05", { ticket: "J-4960", startWeek: 31n, weeks: 4n, sheets: 128.0, load: 96.0, state: CONFIRMED }],
81
- ["H2-P06", { ticket: "J-4975", startWeek: 33n, weeks: 3n, sheets: 84.0, load: 69.0, state: PROPOSED }],
82
- ["H2-P07", { ticket: "J-4987", startWeek: 34n, weeks: 2n, sheets: 60.0, load: 52.0, state: PROPOSED }],
83
- ["H2-P08", { ticket: "J-5002", startWeek: 35n, weeks: 4n, sheets: 112.0, load: 87.0, state: PROPOSED }],
84
- ["H2-P09", { ticket: "J-5014", startWeek: 37n, weeks: 3n, sheets: 76.0, load: 64.0, state: ESTIMATED }],
85
- ["H2-P10", { ticket: "J-5029", startWeek: 38n, weeks: 2n, sheets: 48.0, load: 44.0, state: ESTIMATED }],
86
- ])],
87
- ["Hall 3", new Map([
88
- ["H3-P01", { ticket: "J-5203", startWeek: 24n, weeks: 3n, sheets: 88.0, load: 73.0, state: ACTUAL }],
89
- ["H3-P02", { ticket: "J-5215", startWeek: 26n, weeks: 4n, sheets: 124.0, load: 94.0, state: ACTUAL }],
90
- ["H3-P03", { ticket: "J-5230", startWeek: 29n, weeks: 2n, sheets: 56.0, load: 51.0, state: RUNNING }],
91
- ["H3-P04", { ticket: "J-5242", startWeek: 30n, weeks: 3n, sheets: 100.0, load: 82.0, state: RUNNING }],
92
- ["H3-P05", { ticket: "J-5257", startWeek: 32n, weeks: 2n, sheets: 72.0, load: 62.0, state: CONFIRMED }],
93
- ["H3-P06", { ticket: "J-5272", startWeek: 33n, weeks: 4n, sheets: 116.0, load: 90.0, state: CONFIRMED }],
94
- ["H3-P07", { ticket: "J-5284", startWeek: 35n, weeks: 3n, sheets: 92.0, load: 76.0, state: PROPOSED }],
95
- ["H3-P08", { ticket: "J-5299", startWeek: 36n, weeks: 2n, sheets: 64.0, load: 57.0, state: PROPOSED }],
96
- ["H3-P09", { ticket: "J-5311", startWeek: 37n, weeks: 4n, sheets: 108.0, load: 85.0, state: ESTIMATED }],
97
- ["H3-P10", { ticket: "J-5323", startWeek: 39n, weeks: 2n, sheets: 44.0, load: 41.0, state: ESTIMATED }],
98
- ])],
99
- ["Hall 4", new Map([
100
- ["H4-P01", { ticket: "J-5506", startWeek: 25n, weeks: 2n, sheets: 60.0, load: 54.0, state: ACTUAL }],
101
- ["H4-P02", { ticket: "J-5518", startWeek: 27n, weeks: 3n, sheets: 96.0, load: 79.0, state: ACTUAL }],
102
- ["H4-P03", { ticket: "J-5533", startWeek: 28n, weeks: 4n, sheets: 132.0, load: 98.0, state: RUNNING }],
103
- ["H4-P04", { ticket: "J-5545", startWeek: 31n, weeks: 2n, sheets: 68.0, load: 60.0, state: CONFIRMED }],
104
- ["H4-P05", { ticket: "J-5560", startWeek: 32n, weeks: 3n, sheets: 104.0, load: 83.0, state: CONFIRMED }],
105
- ["H4-P06", { ticket: "J-5572", startWeek: 34n, weeks: 2n, sheets: 76.0, load: 67.0, state: PROPOSED }],
106
- ["H4-P07", { ticket: "J-5587", startWeek: 35n, weeks: 4n, sheets: 120.0, load: 93.0, state: PROPOSED }],
107
- ["H4-P08", { ticket: "J-5599", startWeek: 37n, weeks: 3n, sheets: 84.0, load: 70.0, state: ESTIMATED }],
108
- ["H4-P09", { ticket: "J-5614", startWeek: 38n, weeks: 2n, sheets: 52.0, load: 47.0, state: ESTIMATED }],
109
- ["H4-P10", { ticket: "J-5626", startWeek: 39n, weeks: 3n, sheets: 88.0, load: 72.0, state: ESTIMATED }],
110
- ])],
111
- ["Hall 5", new Map([
112
- ["H5-P01", { ticket: "J-5803", startWeek: 24n, weeks: 4n, sheets: 110.0, load: 86.0, state: ACTUAL }],
113
- ["H5-P02", { ticket: "J-5815", startWeek: 26n, weeks: 2n, sheets: 58.0, load: 53.0, state: ACTUAL }],
114
- ["H5-P03", { ticket: "J-5827", startWeek: 28n, weeks: 3n, sheets: 94.0, load: 77.0, state: RUNNING }],
115
- ["H5-P04", { ticket: "J-5839", startWeek: 30n, weeks: 4n, sheets: 126.0, load: 95.0, state: RUNNING }],
116
- ["H5-P05", { ticket: "J-5854", startWeek: 32n, weeks: 2n, sheets: 70.0, load: 61.0, state: CONFIRMED }],
117
- ["H5-P06", { ticket: "J-5866", startWeek: 33n, weeks: 3n, sheets: 98.0, load: 81.0, state: CONFIRMED }],
118
- ["H5-P07", { ticket: "J-5881", startWeek: 35n, weeks: 2n, sheets: 66.0, load: 58.0, state: PROPOSED }],
119
- ["H5-P08", { ticket: "J-5893", startWeek: 36n, weeks: 4n, sheets: 114.0, load: 89.0, state: PROPOSED }],
120
- ["H5-P09", { ticket: "J-5908", startWeek: 38n, weeks: 3n, sheets: 82.0, load: 68.0, state: ESTIMATED }],
121
- ["H5-P10", { ticket: "J-5920", startWeek: 39n, weeks: 2n, sheets: 50.0, load: 45.0, state: ESTIMATED }],
122
- ])],
63
+ ["Hall 1", { presses: new Map([
64
+ ["H1-P01", { ticket: "J-4603", startWeek: 25n, weeks: 3n, sheets: 96.0, load: 78.0, state: ACTUAL }],
65
+ ["H1-P02", { ticket: "J-4612", startWeek: 26n, weeks: 2n, sheets: 64.0, load: 71.0, state: ACTUAL }],
66
+ ["H1-P03", { ticket: "J-4642", startWeek: 28n, weeks: 3n, sheets: 112.0, load: 88.0, state: RUNNING }],
67
+ ["H1-P04", { ticket: "J-4624", startWeek: 27n, weeks: 4n, sheets: 104.0, load: 84.0, state: RUNNING }],
68
+ ["H1-P05", { ticket: "J-4657", startWeek: 31n, weeks: 3n, sheets: 88.0, load: 66.0, state: CONFIRMED }],
69
+ ["H1-P06", { ticket: "J-4669", startWeek: 32n, weeks: 2n, sheets: 72.0, load: 59.0, state: CONFIRMED }],
70
+ ["H1-P07", { ticket: "J-4693", startWeek: 33n, weeks: 4n, sheets: 120.0, load: 92.0, state: PROPOSED }],
71
+ ["H1-P08", { ticket: "J-4708", startWeek: 35n, weeks: 3n, sheets: 96.0, load: 74.0, state: PROPOSED }],
72
+ ["H1-P09", { ticket: "J-4726", startWeek: 36n, weeks: 3n, sheets: 80.0, load: 63.0, state: ESTIMATED }],
73
+ ["H1-P10", { ticket: "J-4741", startWeek: 37n, weeks: 2n, sheets: 56.0, load: 48.0, state: ESTIMATED }],
74
+ ]) }],
75
+ ["Hall 2", { presses: new Map([
76
+ ["H2-P01", { ticket: "J-4906", startWeek: 25n, weeks: 4n, sheets: 118.0, load: 91.0, state: ACTUAL }],
77
+ ["H2-P02", { ticket: "J-4921", startWeek: 27n, weeks: 2n, sheets: 52.0, load: 55.0, state: ACTUAL }],
78
+ ["H2-P03", { ticket: "J-4933", startWeek: 29n, weeks: 3n, sheets: 92.0, load: 80.0, state: RUNNING }],
79
+ ["H2-P04", { ticket: "J-4948", startWeek: 30n, weeks: 2n, sheets: 68.0, load: 61.0, state: CONFIRMED }],
80
+ ["H2-P05", { ticket: "J-4960", startWeek: 31n, weeks: 4n, sheets: 128.0, load: 96.0, state: CONFIRMED }],
81
+ ["H2-P06", { ticket: "J-4975", startWeek: 33n, weeks: 3n, sheets: 84.0, load: 69.0, state: PROPOSED }],
82
+ ["H2-P07", { ticket: "J-4987", startWeek: 34n, weeks: 2n, sheets: 60.0, load: 52.0, state: PROPOSED }],
83
+ ["H2-P08", { ticket: "J-5002", startWeek: 35n, weeks: 4n, sheets: 112.0, load: 87.0, state: PROPOSED }],
84
+ ["H2-P09", { ticket: "J-5014", startWeek: 37n, weeks: 3n, sheets: 76.0, load: 64.0, state: ESTIMATED }],
85
+ ["H2-P10", { ticket: "J-5029", startWeek: 38n, weeks: 2n, sheets: 48.0, load: 44.0, state: ESTIMATED }],
86
+ ]) }],
87
+ ["Hall 3", { presses: new Map([
88
+ ["H3-P01", { ticket: "J-5203", startWeek: 24n, weeks: 3n, sheets: 88.0, load: 73.0, state: ACTUAL }],
89
+ ["H3-P02", { ticket: "J-5215", startWeek: 26n, weeks: 4n, sheets: 124.0, load: 94.0, state: ACTUAL }],
90
+ ["H3-P03", { ticket: "J-5230", startWeek: 29n, weeks: 2n, sheets: 56.0, load: 51.0, state: RUNNING }],
91
+ ["H3-P04", { ticket: "J-5242", startWeek: 30n, weeks: 3n, sheets: 100.0, load: 82.0, state: RUNNING }],
92
+ ["H3-P05", { ticket: "J-5257", startWeek: 32n, weeks: 2n, sheets: 72.0, load: 62.0, state: CONFIRMED }],
93
+ ["H3-P06", { ticket: "J-5272", startWeek: 33n, weeks: 4n, sheets: 116.0, load: 90.0, state: CONFIRMED }],
94
+ ["H3-P07", { ticket: "J-5284", startWeek: 35n, weeks: 3n, sheets: 92.0, load: 76.0, state: PROPOSED }],
95
+ ["H3-P08", { ticket: "J-5299", startWeek: 36n, weeks: 2n, sheets: 64.0, load: 57.0, state: PROPOSED }],
96
+ ["H3-P09", { ticket: "J-5311", startWeek: 37n, weeks: 4n, sheets: 108.0, load: 85.0, state: ESTIMATED }],
97
+ ["H3-P10", { ticket: "J-5323", startWeek: 39n, weeks: 2n, sheets: 44.0, load: 41.0, state: ESTIMATED }],
98
+ ]) }],
99
+ ["Hall 4", { presses: new Map([
100
+ ["H4-P01", { ticket: "J-5506", startWeek: 25n, weeks: 2n, sheets: 60.0, load: 54.0, state: ACTUAL }],
101
+ ["H4-P02", { ticket: "J-5518", startWeek: 27n, weeks: 3n, sheets: 96.0, load: 79.0, state: ACTUAL }],
102
+ ["H4-P03", { ticket: "J-5533", startWeek: 28n, weeks: 4n, sheets: 132.0, load: 98.0, state: RUNNING }],
103
+ ["H4-P04", { ticket: "J-5545", startWeek: 31n, weeks: 2n, sheets: 68.0, load: 60.0, state: CONFIRMED }],
104
+ ["H4-P05", { ticket: "J-5560", startWeek: 32n, weeks: 3n, sheets: 104.0, load: 83.0, state: CONFIRMED }],
105
+ ["H4-P06", { ticket: "J-5572", startWeek: 34n, weeks: 2n, sheets: 76.0, load: 67.0, state: PROPOSED }],
106
+ ["H4-P07", { ticket: "J-5587", startWeek: 35n, weeks: 4n, sheets: 120.0, load: 93.0, state: PROPOSED }],
107
+ ["H4-P08", { ticket: "J-5599", startWeek: 37n, weeks: 3n, sheets: 84.0, load: 70.0, state: ESTIMATED }],
108
+ ["H4-P09", { ticket: "J-5614", startWeek: 38n, weeks: 2n, sheets: 52.0, load: 47.0, state: ESTIMATED }],
109
+ ["H4-P10", { ticket: "J-5626", startWeek: 39n, weeks: 3n, sheets: 88.0, load: 72.0, state: ESTIMATED }],
110
+ ]) }],
111
+ ["Hall 5", { presses: new Map([
112
+ ["H5-P01", { ticket: "J-5803", startWeek: 24n, weeks: 4n, sheets: 110.0, load: 86.0, state: ACTUAL }],
113
+ ["H5-P02", { ticket: "J-5815", startWeek: 26n, weeks: 2n, sheets: 58.0, load: 53.0, state: ACTUAL }],
114
+ ["H5-P03", { ticket: "J-5827", startWeek: 28n, weeks: 3n, sheets: 94.0, load: 77.0, state: RUNNING }],
115
+ ["H5-P04", { ticket: "J-5839", startWeek: 30n, weeks: 4n, sheets: 126.0, load: 95.0, state: RUNNING }],
116
+ ["H5-P05", { ticket: "J-5854", startWeek: 32n, weeks: 2n, sheets: 70.0, load: 61.0, state: CONFIRMED }],
117
+ ["H5-P06", { ticket: "J-5866", startWeek: 33n, weeks: 3n, sheets: 98.0, load: 81.0, state: CONFIRMED }],
118
+ ["H5-P07", { ticket: "J-5881", startWeek: 35n, weeks: 2n, sheets: 66.0, load: 58.0, state: PROPOSED }],
119
+ ["H5-P08", { ticket: "J-5893", startWeek: 36n, weeks: 4n, sheets: 114.0, load: 89.0, state: PROPOSED }],
120
+ ["H5-P09", { ticket: "J-5908", startWeek: 38n, weeks: 3n, sheets: 82.0, load: 68.0, state: ESTIMATED }],
121
+ ["H5-P10", { ticket: "J-5920", startWeek: 39n, weeks: 2n, sheets: 50.0, load: 45.0, state: ESTIMATED }],
122
+ ]) }],
123
123
  // The delivery vans — the same flat row, read as weekly load strips
124
124
  // rather than run bars (see the `vans` series below).
125
- ["Vans", new Map([
126
- ["V-01", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 46.0, state: CONFIRMED }],
127
- ["V-02", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 58.0, state: CONFIRMED }],
128
- ["V-03", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 67.0, state: CONFIRMED }],
129
- ["V-04", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 74.0, state: CONFIRMED }],
130
- ["V-05", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 81.0, state: CONFIRMED }],
131
- ["V-06", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 88.0, state: CONFIRMED }],
132
- ["V-07", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 93.0, state: CONFIRMED }],
133
- ["V-08", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 97.0, state: CONFIRMED }],
134
- ["V-09", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 64.0, state: CONFIRMED }],
135
- ["V-10", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 52.0, state: CONFIRMED }],
136
- ])],
125
+ ["Vans", { presses: new Map([
126
+ ["V-01", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 46.0, state: CONFIRMED }],
127
+ ["V-02", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 58.0, state: CONFIRMED }],
128
+ ["V-03", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 67.0, state: CONFIRMED }],
129
+ ["V-04", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 74.0, state: CONFIRMED }],
130
+ ["V-05", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 81.0, state: CONFIRMED }],
131
+ ["V-06", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 88.0, state: CONFIRMED }],
132
+ ["V-07", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 93.0, state: CONFIRMED }],
133
+ ["V-08", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 97.0, state: CONFIRMED }],
134
+ ["V-09", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 64.0, state: CONFIRMED }],
135
+ ["V-10", { ticket: "—", startWeek: 27n, weeks: 12n, sheets: 0.0, load: 52.0, state: CONFIRMED }],
136
+ ]) }],
137
137
  ])));
138
138
  /**
139
139
  * A maintenance work order — the row of the `work_orders` record, keyed by
@@ -156,37 +156,38 @@ export const WorkQueueKey = StructType({ status: StringType, due: DateTimeType }
156
156
  * workspace holds, and deploy builds its index over it. The ids run in the
157
157
  * order the orders were raised, which is nothing like the order they are due.
158
158
  */
159
- export const workOrders = e3.record('work_orders', DictType(StringType, WorkOrderRow), new Map([
160
- ["WO-1001", { site: "North", title: "Replace kiln 2 burner", crew: "Mech A", status: "planned", due: new Date("2026-10-19T00:00:00Z") }],
161
- ["WO-1002", { site: "North", title: "Calibrate belt scale 4", crew: "Inst", status: "late", due: new Date("2026-09-15T00:00:00Z") }],
162
- ["WO-1003", { site: "South", title: "Reline crusher jaw", crew: "Mech B", status: "open", due: new Date("2026-09-25T00:00:00Z") }],
163
- ["WO-1004", { site: "South", title: "Grease stacker bearings", crew: "Mech B", status: "open", due: new Date("2026-09-24T00:00:00Z") }],
164
- ["WO-1005", { site: "Port", title: "Inspect shiploader boom", crew: "Struct", status: "late", due: new Date("2026-09-18T00:00:00Z") }],
165
- ["WO-1006", { site: "North", title: "Swap conveyor 7 idlers", crew: "Mech A", status: "open", due: new Date("2026-09-29T00:00:00Z") }],
166
- ["WO-1007", { site: "Port", title: "Test dust suppression pumps", crew: "Elec", status: "planned", due: new Date("2026-10-06T00:00:00Z") }],
167
- ["WO-1008", { site: "South", title: "Replace screen deck panels", crew: "Mech B", status: "late", due: new Date("2026-09-11T00:00:00Z") }],
168
- ["WO-1009", { site: "North", title: "Thermal scan MCC room", crew: "Elec", status: "open", due: new Date("2026-09-26T00:00:00Z") }],
169
- ["WO-1010", { site: "Port", title: "Rebuild reclaimer gearbox", crew: "Mech A", status: "planned", due: new Date("2026-10-26T00:00:00Z") }],
170
- ["WO-1011", { site: "South", title: "Align apron feeder", crew: "Mech B", status: "open", due: new Date("2026-10-01T00:00:00Z") }],
171
- ["WO-1012", { site: "North", title: "Service compressor 2", crew: "Mech A", status: "late", due: new Date("2026-09-21T00:00:00Z") }],
172
- ["WO-1013", { site: "Port", title: "Weld chute liner", crew: "Struct", status: "open", due: new Date("2026-09-30T00:00:00Z") }],
173
- ["WO-1014", { site: "South", title: "Replace pump 3 impeller", crew: "Mech B", status: "planned", due: new Date("2026-10-09T00:00:00Z") }],
174
- ["WO-1015", { site: "North", title: "Relamp stockpile towers", crew: "Elec", status: "planned", due: new Date("2026-10-13T00:00:00Z") }],
175
- ["WO-1016", { site: "Port", title: "Tension berth 2 belt", crew: "Mech A", status: "open", due: new Date("2026-09-24T00:00:00Z") }],
176
- ["WO-1017", { site: "South", title: "Inspect tailings line", crew: "Struct", status: "late", due: new Date("2026-09-22T00:00:00Z") }],
177
- ["WO-1018", { site: "North", title: "Change kiln 1 seals", crew: "Mech A", status: "planned", due: new Date("2026-11-02T00:00:00Z") }],
178
- ]));
179
- /**
180
- * The dispatch queue — every work order under `{status, due}`, carrying its
181
- * title so the queue renders from index pages alone and never reads an
182
- * order's row.
183
- */
184
- export const workQueue = e3.recordIndex('by_status', workOrders, {
185
- key: East.function([StringType, WorkOrderRow], WorkQueueKey, ($, _id, order) => ({ status: order.status, due: order.due })),
186
- value: East.function([StringType, WorkOrderRow], StringType, ($, _id, order) => order.title),
159
+ export const workOrders = e3.record('work_orders', DictType(StringType, WorkOrderRow), {
160
+ initial: new Map([
161
+ ["WO-1001", { site: "North", title: "Replace kiln 2 burner", crew: "Mech A", status: "planned", due: new Date("2026-10-19T00:00:00Z") }],
162
+ ["WO-1002", { site: "North", title: "Calibrate belt scale 4", crew: "Inst", status: "late", due: new Date("2026-09-15T00:00:00Z") }],
163
+ ["WO-1003", { site: "South", title: "Reline crusher jaw", crew: "Mech B", status: "open", due: new Date("2026-09-25T00:00:00Z") }],
164
+ ["WO-1004", { site: "South", title: "Grease stacker bearings", crew: "Mech B", status: "open", due: new Date("2026-09-24T00:00:00Z") }],
165
+ ["WO-1005", { site: "Port", title: "Inspect shiploader boom", crew: "Struct", status: "late", due: new Date("2026-09-18T00:00:00Z") }],
166
+ ["WO-1006", { site: "North", title: "Swap conveyor 7 idlers", crew: "Mech A", status: "open", due: new Date("2026-09-29T00:00:00Z") }],
167
+ ["WO-1007", { site: "Port", title: "Test dust suppression pumps", crew: "Elec", status: "planned", due: new Date("2026-10-06T00:00:00Z") }],
168
+ ["WO-1008", { site: "South", title: "Replace screen deck panels", crew: "Mech B", status: "late", due: new Date("2026-09-11T00:00:00Z") }],
169
+ ["WO-1009", { site: "North", title: "Thermal scan MCC room", crew: "Elec", status: "open", due: new Date("2026-09-26T00:00:00Z") }],
170
+ ["WO-1010", { site: "Port", title: "Rebuild reclaimer gearbox", crew: "Mech A", status: "planned", due: new Date("2026-10-26T00:00:00Z") }],
171
+ ["WO-1011", { site: "South", title: "Align apron feeder", crew: "Mech B", status: "open", due: new Date("2026-10-01T00:00:00Z") }],
172
+ ["WO-1012", { site: "North", title: "Service compressor 2", crew: "Mech A", status: "late", due: new Date("2026-09-21T00:00:00Z") }],
173
+ ["WO-1013", { site: "Port", title: "Weld chute liner", crew: "Struct", status: "open", due: new Date("2026-09-30T00:00:00Z") }],
174
+ ["WO-1014", { site: "South", title: "Replace pump 3 impeller", crew: "Mech B", status: "planned", due: new Date("2026-10-09T00:00:00Z") }],
175
+ ["WO-1015", { site: "North", title: "Relamp stockpile towers", crew: "Elec", status: "planned", due: new Date("2026-10-13T00:00:00Z") }],
176
+ ["WO-1016", { site: "Port", title: "Tension berth 2 belt", crew: "Mech A", status: "open", due: new Date("2026-09-24T00:00:00Z") }],
177
+ ["WO-1017", { site: "South", title: "Inspect tailings line", crew: "Struct", status: "late", due: new Date("2026-09-22T00:00:00Z") }],
178
+ ["WO-1018", { site: "North", title: "Change kiln 1 seals", crew: "Mech A", status: "planned", due: new Date("2026-11-02T00:00:00Z") }],
179
+ ]),
180
+ indexes: (index) => ({
181
+ // The dispatch queue — every work order under `{status, due}`, carrying its
182
+ // title so the queue renders from index pages alone and never reads an
183
+ // order's row.
184
+ by_status: index.key(East.function([StringType, WorkOrderRow], WorkQueueKey, ($, _id, order) => ({ status: order.status, due: order.due })), { value: East.function([StringType, WorkOrderRow], StringType, ($, _id, order) => order.title) }),
185
+ }),
186
+ mutations: (mutation) => ({
187
+ // The work orders' patch door: another session's change to an order commits through it, and moves the queue with it.
188
+ patch: mutation.patch(),
189
+ }),
187
190
  });
188
- /** The work orders' patch door: another session's change to an order commits through it, and moves the queue with it. */
189
- export const workOrdersPatch = e3.mutation.patch(workOrders);
190
191
  export const dataBindFloat = example({
191
192
  keywords: ["Data", "bind", "Reactive", "Float", "dataset", "read"],
192
193
  description: "Bind to a Float dataset and display its current value",
@@ -290,7 +291,7 @@ export const dataBindPagedPlan = example({
290
291
  label: (_h, hall) => hall,
291
292
  runs: _l => [],
292
293
  rollup: "union",
293
- children: Plan.children((l) => l, [
294
+ children: Plan.children("presses", [
294
295
  // Presses — each flat row becomes TWO bars: a one-week
295
296
  // make-ready ahead of the job, then the run itself, with its
296
297
  // label and quantity built from the job ticket and sheets
@@ -326,7 +327,7 @@ export const dataBindPagedPlan = example({
326
327
  match: (_h, hall) => hall.equal("Vans"),
327
328
  label: (_h, hall) => hall,
328
329
  collapsed: true, summaryAggregate: "mean",
329
- children: Plan.children((l) => l, [
330
+ children: Plan.children("presses", [
330
331
  Plan.series.heat(OpsRow, {
331
332
  key: "van-load", title: "Van load",
332
333
  label: (_r, k) => k, id: true,
@@ -374,14 +375,14 @@ export const dataBindPagedRevision = example({
374
375
  });
375
376
  export const dataBindPagedIndex = example({
376
377
  keywords: [
377
- "Data", "bindPaged", "index", "recordIndex", "record", "secondary index", "queue", "ordered",
378
+ "Data", "bindPaged", "index", "indexes", "record", "secondary index", "queue", "ordered",
378
379
  "window", "covering", "projection", "ik", "key", "value", "row", "join", "Table", "paged", "by_status",
379
380
  ],
380
- description: "Read a record THROUGH one of its indexes — `Data.bindPaged(workOrders, { index: workQueue })` serves the INDEX's pages in the index's own order, so the dispatch queue arrives late-first and by due date within each status, whatever the work orders' ids are. Each row is `{ ik, key, value, row }`: the index key, the order's id, and the title the index covers — so the Table renders from index pages alone and reads no order's row (`join: true` would fill `row` from the record too)",
381
+ description: "Read a record THROUGH one of its indexes — `Data.bindPaged(workOrders, { index: \"by_status\" })` serves the INDEX's pages in the index's own order, so the dispatch queue arrives late-first and by due date within each status, whatever the work orders' ids are. Each row is `{ ik, key, value, row }`: the index key, the order's id, and the title the index covers — so the Table renders from index pages alone and reads no order's row (`join: true` would fill `row` from the record too)",
381
382
  fn: East.function([], UIComponentType, (_$) => (_jsx(Reactive, { children: $ => {
382
- // Pass the index DECLARATION, not its name: the window's type —
383
- // its key and what it covers — comes from it.
384
- const queue = $.let(Data.bindPaged(workOrders, { index: workQueue }));
383
+ // Name one of the record's indexes: the window's type — its key
384
+ // and what it covers — comes from the index's declaration.
385
+ const queue = $.let(Data.bindPaged(workOrders, { index: "by_status" }));
385
386
  return _jsx(Table, { data: queue, columns: {
386
387
  ik: { header: "Due", value: (ik) => East.str `${ik.status} · ${ik.due.printFormatted("ddd D MMM")}` },
387
388
  value: { header: "Work order" },
@@ -614,7 +615,7 @@ export const countsSaid = East.function([DictType(StringType, IntegerType)], UIC
614
615
  export const previewCountsView = ui('preview_counts_view', [previewCountsInput], countsSaid);
615
616
  /** A ui task over the work orders, their queue read a window at a time beside the commits of their record, which is never read whole. */
616
617
  export const previewOrdersView = ui('preview_orders_view', [], East.function([], UIComponentType, (_$) => (_jsx(Reactive, { children: $ => {
617
- const orders = $.let(Data.bindPaged(workOrders, { index: workQueue }));
618
+ const orders = $.let(Data.bindPaged(workOrders, { index: "by_status" }));
618
619
  const record = $.let(Record.bind(workOrders, []));
619
620
  const commits = $.let(record.history().match({
620
621
  some: (_$2, history) => history.size(),
@@ -631,14 +632,20 @@ export const previewOrdersView = ui('preview_orders_view', [], East.function([],
631
632
  /** A person and the skills they hold: a Set field, which an index lists once under each skill. */
632
633
  export const IndexedPerson = StructType({ name: StringType, skills: SetType(StringType) });
633
634
  /** People by key: Ada and Amy share skill `b`, and Abe holds none, so the skills index lists him nowhere. */
634
- export const indexedPeople = e3.record('indexed_people', DictType(StringType, IndexedPerson), new Map([
635
- ["p1", { name: "Ada", skills: new Set(["a", "b"]) }],
636
- ["p2", { name: "Abe", skills: new Set() }],
637
- ["p3", { name: "Amy", skills: new Set(["b"]) }],
638
- ]));
639
- export const indexedPeoplePatch = e3.mutation.patch(indexedPeople);
640
- export const peopleByName = e3.recordIndex('by_name', indexedPeople, { on: ["name"] });
641
- export const peopleBySkill = e3.recordIndex('by_skill', indexedPeople, { on: ["skills"] });
635
+ export const indexedPeople = e3.record('indexed_people', DictType(StringType, IndexedPerson), {
636
+ initial: new Map([
637
+ ["p1", { name: "Ada", skills: new Set(["a", "b"]) }],
638
+ ["p2", { name: "Abe", skills: new Set() }],
639
+ ["p3", { name: "Amy", skills: new Set(["b"]) }],
640
+ ]),
641
+ indexes: (index) => ({
642
+ by_name: index.on(["name"]),
643
+ by_skill: index.on(["skills"]),
644
+ }),
645
+ mutations: (mutation) => ({
646
+ patch: mutation.patch(),
647
+ }),
648
+ });
642
649
  /** An event of a status over a span of time: no end is an instant, and no start the backlog. */
643
650
  export const IntervalEvent = StructType({ status: StringType, start: OptionType(DateTimeType), end: OptionType(DateTimeType) });
644
651
  /**
@@ -647,22 +654,28 @@ export const IntervalEvent = StructType({ status: StringType, start: OptionType(
647
654
  * it ends, an instant at each of its bounds, one cancelled and one in the
648
655
  * backlog — what an overlap with `[2 Oct, 3 Oct)` takes and what it leaves.
649
656
  */
650
- export const indexedIntervals = e3.record('indexed_intervals', DictType(StringType, IntervalEvent), new Map([
651
- ["backlog", { status: "Ready", start: none, end: none }],
652
- ["carry", { status: "Ready", start: some(new Date("2026-10-01T22:00:00Z")), end: some(new Date("2026-10-02T06:00:00Z")) }],
653
- ["span", { status: "Ready", start: some(new Date("2025-01-01T00:00:00Z")), end: some(new Date("2027-01-01T00:00:00Z")) }],
654
- ["inside", { status: "Ready", start: some(new Date("2026-10-02T10:00:00Z")), end: some(new Date("2026-10-02T11:00:00Z")) }],
655
- ["ends-at-from", { status: "Ready", start: some(new Date("2026-10-01T12:00:00Z")), end: some(new Date("2026-10-02T00:00:00Z")) }],
656
- ["starts-at-to", { status: "Ready", start: some(new Date("2026-10-03T00:00:00Z")), end: some(new Date("2026-10-03T01:00:00Z")) }],
657
- ["instant-at-from", { status: "Ready", start: some(new Date("2026-10-02T00:00:00Z")), end: none }],
658
- ["instant-at-to", { status: "Ready", start: some(new Date("2026-10-03T00:00:00Z")), end: none }],
659
- ["cancelled", { status: "Cancelled", start: some(new Date("2026-01-01T00:00:00Z")), end: some(new Date("2027-01-01T00:00:00Z")) }],
660
- ]));
661
- export const indexedIntervalsPatch = e3.mutation.patch(indexedIntervals);
662
- // The start alone is listed first: a declared overlap must never be read as a start range because its index came first.
663
- export const intervalsByStart = e3.recordIndex('by_start', indexedIntervals, { on: ["start"] });
664
- export const intervalsByStatusTime = e3.recordIndex.interval('by_status_time', indexedIntervals, { on: ["status"], from: "start", to: "end" });
665
- export const intervalsByTime = e3.recordIndex.interval('by_time', indexedIntervals, { from: "start", to: "end" });
657
+ export const indexedIntervals = e3.record('indexed_intervals', DictType(StringType, IntervalEvent), {
658
+ initial: new Map([
659
+ ["backlog", { status: "Ready", start: none, end: none }],
660
+ ["carry", { status: "Ready", start: some(new Date("2026-10-01T22:00:00Z")), end: some(new Date("2026-10-02T06:00:00Z")) }],
661
+ ["span", { status: "Ready", start: some(new Date("2025-01-01T00:00:00Z")), end: some(new Date("2027-01-01T00:00:00Z")) }],
662
+ ["inside", { status: "Ready", start: some(new Date("2026-10-02T10:00:00Z")), end: some(new Date("2026-10-02T11:00:00Z")) }],
663
+ ["ends-at-from", { status: "Ready", start: some(new Date("2026-10-01T12:00:00Z")), end: some(new Date("2026-10-02T00:00:00Z")) }],
664
+ ["starts-at-to", { status: "Ready", start: some(new Date("2026-10-03T00:00:00Z")), end: some(new Date("2026-10-03T01:00:00Z")) }],
665
+ ["instant-at-from", { status: "Ready", start: some(new Date("2026-10-02T00:00:00Z")), end: none }],
666
+ ["instant-at-to", { status: "Ready", start: some(new Date("2026-10-03T00:00:00Z")), end: none }],
667
+ ["cancelled", { status: "Cancelled", start: some(new Date("2026-01-01T00:00:00Z")), end: some(new Date("2027-01-01T00:00:00Z")) }],
668
+ ]),
669
+ indexes: (index) => ({
670
+ // The start alone is listed first: a declared overlap must never be read as a start range because its index came first.
671
+ by_start: index.on(["start"]),
672
+ by_status_time: index.interval({ on: ["status"], from: "start", to: "end" }),
673
+ by_time: index.interval({ from: "start", to: "end" }),
674
+ }),
675
+ mutations: (mutation) => ({
676
+ patch: mutation.patch(),
677
+ }),
678
+ });
666
679
  /** A rack on a data centre floor, in metres: its hall, where it stands — by its centre — if anywhere yet, and its footprint. */
667
680
  export const IndexedRack = StructType({ hall: StringType, x: OptionType(FloatType), y: OptionType(FloatType), w: FloatType, h: FloatType });
668
681
  /**
@@ -670,19 +683,60 @@ export const IndexedRack = StructType({ hall: StringType, x: OptionType(FloatTyp
670
683
  * aisle, one in hall B far down the floor, and one in hall A not yet placed —
671
684
  * what a window over the row takes, what its margin takes, and what it leaves.
672
685
  */
673
- export const indexedRacks = e3.record('indexed_racks', DictType(StringType, IndexedRack), new Map([
674
- ["r1", { hall: "A", x: some(1.0), y: some(1.0), w: 0.6, h: 1.2 }],
675
- ["r2", { hall: "A", x: some(2.0), y: some(1.0), w: 0.6, h: 1.2 }],
676
- ["r3", { hall: "A", x: some(3.0), y: some(1.0), w: 0.6, h: 1.2 }],
677
- ["r4", { hall: "B", x: some(2.0), y: some(3.5), w: 0.6, h: 1.2 }],
678
- ["far", { hall: "B", x: some(40.0), y: some(40.0), w: 0.6, h: 1.2 }],
679
- ["unplaced", { hall: "A", x: none, y: none, w: 0.6, h: 1.2 }],
680
- ]));
681
- export const indexedRacksPatch = e3.mutation.patch(indexedRacks);
682
- // The window whatever the rail chooses, and beside it a choice of halls and the window in one read; both carry their rows.
683
- export const racksByArea = e3.recordIndex.area('racks_by_area', indexedRacks, { x: "x", y: "y", width: "w", height: "h", at: "centre", cell: 0.01 });
684
- export const racksByHallArea = e3.recordIndex.area('racks_by_hall_area', indexedRacks, { on: ["hall"], x: "x", y: "y", width: "w", height: "h", at: "centre", cell: 0.01 });
685
- export const racksByHall = e3.recordIndex('racks_by_hall', indexedRacks, { on: ["hall"] });
686
+ export const indexedRacks = e3.record('indexed_racks', DictType(StringType, IndexedRack), {
687
+ initial: new Map([
688
+ ["r1", { hall: "A", x: some(1.0), y: some(1.0), w: 0.6, h: 1.2 }],
689
+ ["r2", { hall: "A", x: some(2.0), y: some(1.0), w: 0.6, h: 1.2 }],
690
+ ["r3", { hall: "A", x: some(3.0), y: some(1.0), w: 0.6, h: 1.2 }],
691
+ ["r4", { hall: "B", x: some(2.0), y: some(3.5), w: 0.6, h: 1.2 }],
692
+ ["far", { hall: "B", x: some(40.0), y: some(40.0), w: 0.6, h: 1.2 }],
693
+ ["unplaced", { hall: "A", x: none, y: none, w: 0.6, h: 1.2 }],
694
+ ]),
695
+ indexes: (index) => ({
696
+ // The window whatever the rail chooses, and beside it a choice of halls and the window in one read; both carry their rows.
697
+ racks_by_area: index.area({ x: "x", y: "y", width: "w", height: "h", at: "centre", cell: 0.01 }),
698
+ racks_by_hall_area: index.area({ on: ["hall"], x: "x", y: "y", width: "w", height: "h", at: "centre", cell: 0.01 }),
699
+ racks_by_hall: index.on(["hall"]),
700
+ }),
701
+ mutations: (mutation) => ({
702
+ patch: mutation.patch(),
703
+ }),
704
+ });
705
+ /**
706
+ * A rack whose fields are named as e3's own parts of a generated key once were
707
+ * (#1432): `area`, `__area`, `tile` and `__tile`. No name is reserved — e3's
708
+ * parts are its index's kind's — so each is a field of the rail like any
709
+ * other, and an area index may be led by them.
710
+ */
711
+ export const NamedRack = StructType({
712
+ area: StringType, __area: StringType, tile: StringType, __tile: StringType, x: OptionType(FloatType), y: OptionType(FloatType),
713
+ });
714
+ /**
715
+ * Five racks: two in area A1 by B — one inside the window over the floor's
716
+ * corner, one far down it — one by C and one in A2 inside it, and one in A1 by
717
+ * B not yet placed.
718
+ */
719
+ export const namedRacks = e3.record('named_racks', DictType(StringType, NamedRack), {
720
+ initial: new Map([
721
+ ["n1", { area: "A1", __area: "B", tile: "T1", __tile: "U1", x: some(1.0), y: some(1.0) }],
722
+ ["n2", { area: "A1", __area: "B", tile: "T2", __tile: "U1", x: some(100.0), y: some(100.0) }],
723
+ ["n3", { area: "A1", __area: "C", tile: "T1", __tile: "U2", x: some(1.5), y: some(1.5) }],
724
+ ["n4", { area: "A2", __area: "B", tile: "T1", __tile: "U2", x: some(2.0), y: some(2.0) }],
725
+ ["unplaced", { area: "A1", __area: "B", tile: "T2", __tile: "U1", x: none, y: none }],
726
+ ]),
727
+ indexes: (index) => ({
728
+ // Each field leads a plain index; the window is read whatever the rail chooses, or beside a choice of `area` and `__area`.
729
+ named_by_area: index.on(["area"]),
730
+ named_by_under_area: index.on(["__area"]),
731
+ named_by_tile: index.on(["tile"]),
732
+ named_by_under_tile: index.on(["__tile"]),
733
+ named_by_place: index.area({ x: "x", y: "y", cell: 1 }),
734
+ named_by_area_place: index.area({ on: ["area", "__area"], x: "x", y: "y", cell: 1 }),
735
+ }),
736
+ mutations: (mutation) => ({
737
+ patch: mutation.patch(),
738
+ }),
739
+ });
686
740
  /** A rack's load: what its card's figure and its dot draw. */
687
741
  export const IndexedRackLoad = StructType({ kw: FloatType, alarm: StringType });
688
742
  /**
@@ -692,14 +746,18 @@ export const IndexedRackLoad = StructType({ kw: FloatType, alarm: StringType });
692
746
  * racks read their details by, through the runs the area index files them in
693
747
  * (#1393).
694
748
  */
695
- export const indexedRackLoads = e3.record('indexed_rack_loads', DictType(StringType, IndexedRackLoad), new Map([
696
- ["far", { kw: 1.0, alarm: "ok" }],
697
- ["gone", { kw: 2.0, alarm: "ok" }],
698
- ["r1", { kw: 4.2, alarm: "ok" }],
699
- ["r2", { kw: 9.9, alarm: "warm" }],
700
- ["r4", { kw: 11.1, alarm: "hot" }],
701
- ]));
702
- export const indexedRackLoadsPatch = e3.mutation.patch(indexedRackLoads);
749
+ export const indexedRackLoads = e3.record('indexed_rack_loads', DictType(StringType, IndexedRackLoad), {
750
+ initial: new Map([
751
+ ["far", { kw: 1.0, alarm: "ok" }],
752
+ ["gone", { kw: 2.0, alarm: "ok" }],
753
+ ["r1", { kw: 4.2, alarm: "ok" }],
754
+ ["r2", { kw: 9.9, alarm: "warm" }],
755
+ ["r4", { kw: 11.1, alarm: "hot" }],
756
+ ]),
757
+ mutations: (mutation) => ({
758
+ patch: mutation.patch(),
759
+ }),
760
+ });
703
761
  /** A print job: the press it runs on, if any yet, its state, and when it runs, if it is scheduled. */
704
762
  export const IndexedJob = StructType({ press: OptionType(StringType), state: StringType, start: OptionType(DateTimeType), end: OptionType(DateTimeType) });
705
763
  /**
@@ -709,57 +767,55 @@ export const IndexedJob = StructType({ press: OptionType(StringType), state: Str
709
767
  * one in the backlog — what a cell of some presses in a week holds, and what a
710
768
  * month's totals count (#1039).
711
769
  */
712
- export const indexedJobs = e3.record('indexed_jobs', DictType(StringType, IndexedJob), new Map([
713
- ["carry", { press: some("P-1"), state: "running", start: some(new Date("2026-10-02T20:00:00Z")), end: some(new Date("2026-10-05T04:00:00Z")) }],
714
- ["across", { press: some("P-1"), state: "planned", start: some(new Date("2026-10-11T18:00:00Z")), end: some(new Date("2026-10-12T06:00:00Z")) }],
715
- ["month", { press: some("P-2"), state: "planned", start: some(new Date("2026-10-01T00:00:00Z")), end: some(new Date("2026-11-01T00:00:00Z")) }],
716
- ["inside", { press: some("P-2"), state: "running", start: some(new Date("2026-10-06T08:00:00Z")), end: some(new Date("2026-10-06T16:00:00Z")) }],
717
- ["late", { press: some("P-3"), state: "late", start: some(new Date("2026-10-07T09:00:00Z")), end: some(new Date("2026-10-07T12:00:00Z")) }],
718
- ["instant", { press: some("P-3"), state: "late", start: some(new Date("2026-10-05T00:00:00Z")), end: none }],
719
- ["unpressed", { press: none, state: "planned", start: some(new Date("2026-10-06T00:00:00Z")), end: some(new Date("2026-10-06T02:00:00Z")) }],
720
- ["backlog", { press: some("P-1"), state: "planned", start: none, end: none }],
721
- ]));
722
- export const indexedJobsPatch = e3.mutation.patch(indexedJobs);
723
- // The jobs a window overlaps, by state or not; their cells, some presses in a week, by state or not; and their totals,
724
- // a press in a month.
725
- export const jobsByTime = e3.recordIndex.interval('jobs_by_time', indexedJobs, { from: "start", to: "end" });
726
- export const jobsByStateTime = e3.recordIndex.interval('jobs_by_state_time', indexedJobs, { on: ["state"], from: "start", to: "end" });
727
- export const jobsByPressWeek = e3.recordIndex.series('jobs_by_press_week', indexedJobs, { key: "press", from: "start", to: "end", tile: "week" });
728
- export const jobsByStatePressWeek = e3.recordIndex.series('jobs_by_state_press_week', indexedJobs, { on: ["state"], key: "press", from: "start", to: "end", tile: "week" });
729
- export const jobsByPressMonth = e3.recordIndex.summary('jobs_by_press_month', indexedJobs, { key: "press", from: "start", to: "end", tile: "month" });
770
+ export const indexedJobs = e3.record('indexed_jobs', DictType(StringType, IndexedJob), {
771
+ initial: new Map([
772
+ ["carry", { press: some("P-1"), state: "running", start: some(new Date("2026-10-02T20:00:00Z")), end: some(new Date("2026-10-05T04:00:00Z")) }],
773
+ ["across", { press: some("P-1"), state: "planned", start: some(new Date("2026-10-11T18:00:00Z")), end: some(new Date("2026-10-12T06:00:00Z")) }],
774
+ ["month", { press: some("P-2"), state: "planned", start: some(new Date("2026-10-01T00:00:00Z")), end: some(new Date("2026-11-01T00:00:00Z")) }],
775
+ ["inside", { press: some("P-2"), state: "running", start: some(new Date("2026-10-06T08:00:00Z")), end: some(new Date("2026-10-06T16:00:00Z")) }],
776
+ ["late", { press: some("P-3"), state: "late", start: some(new Date("2026-10-07T09:00:00Z")), end: some(new Date("2026-10-07T12:00:00Z")) }],
777
+ ["instant", { press: some("P-3"), state: "late", start: some(new Date("2026-10-05T00:00:00Z")), end: none }],
778
+ ["unpressed", { press: none, state: "planned", start: some(new Date("2026-10-06T00:00:00Z")), end: some(new Date("2026-10-06T02:00:00Z")) }],
779
+ ["backlog", { press: some("P-1"), state: "planned", start: none, end: none }],
780
+ ]),
781
+ indexes: (index) => ({
782
+ // The jobs a window overlaps, by state or not; their cells, some presses in a week, by state or not; and their totals,
783
+ // a press in a month.
784
+ jobs_by_time: index.interval({ from: "start", to: "end" }),
785
+ jobs_by_state_time: index.interval({ on: ["state"], from: "start", to: "end" }),
786
+ jobs_by_press_week: index.series({ key: "press", from: "start", to: "end", tile: "week" }),
787
+ jobs_by_state_press_week: index.series({ on: ["state"], key: "press", from: "start", to: "end", tile: "week" }),
788
+ jobs_by_press_month: index.summary({ key: "press", from: "start", to: "end", tile: "month" }),
789
+ }),
790
+ mutations: (mutation) => ({
791
+ patch: mutation.patch(),
792
+ }),
793
+ });
730
794
  /** A step of a flow: its lane, and who owns it, if anyone. */
731
795
  export const ComputedStep = StructType({ lane: StringType, owner: OptionType(StringType) });
732
796
  /** A flow: what it is, and its steps. */
733
797
  export const ComputedFlow = StructType({ description: StringType, states: ArrayType(ComputedStep) });
734
798
  /** Flows whose indexes are computed from their steps: `a` has two steps in one lane, `c` a step no one owns, and `d` none at all. */
735
- export const computedFlows = e3.record('computed_flows', DictType(StringType, ComputedFlow), new Map([
736
- ["a", { description: "Inbound", states: [{ lane: "load", owner: some("team-a") }, { lane: "load", owner: some("team-a") }, { lane: "review", owner: none }] }],
737
- ["b", { description: "Inbound", states: [{ lane: "load", owner: some("team-b") }] }],
738
- ["c", { description: "Returns", states: [{ lane: "review", owner: none }] }],
739
- ["d", { description: "Empty", states: [] }],
740
- ]));
741
- export const computedFlowsPatch = e3.mutation.patch(computedFlows);
742
- export const computedByDescription = e3.recordIndex('description', computedFlows, { on: ["description"] });
743
- export const computedByStateCount = e3.recordIndex('state_count', computedFlows, {
744
- key: East.function([StringType, ComputedFlow], StructType({ stateCount: IntegerType }), (_$, _id, flow) => ({ stateCount: flow.states.size() })),
745
- });
746
- export const computedByDescriptionCount = e3.recordIndex('description_count', computedFlows, {
747
- key: East.function([StringType, ComputedFlow], StructType({ description: StringType, stateCount: IntegerType }), (_$, _id, flow) => ({ description: flow.description, stateCount: flow.states.size() })),
748
- });
749
- export const computedByLane = e3.recordIndex('lane', computedFlows, {
750
- keys: East.function([StringType, ComputedFlow], SetType(StructType({ lane: StringType })), (_$, _id, flow) => flow.states.toSet((_$2, state) => ({ lane: state.lane }))),
751
- });
752
- export const computedByOwner = e3.recordIndex('owner', computedFlows, {
753
- keys: East.function([StringType, ComputedFlow], SetType(StructType({ owner: OptionType(StringType) })), (_$, _id, flow) => flow.states.toSet((_$2, state) => ({ owner: state.owner }))),
754
- });
755
- // Scalar computed keys, each a field by its index's name.
756
- export const computedByLabel = e3.recordIndex('label', computedFlows, {
757
- key: East.function([StringType, ComputedFlow], StringType, (_$, _id, flow) => flow.description),
758
- });
759
- export const computedBySize = e3.recordIndex('size', computedFlows, {
760
- key: East.function([StringType, ComputedFlow], IntegerType, (_$, _id, flow) => flow.states.size()),
761
- });
762
- export const computedByDecisionOwner = e3.recordIndex('decisionOwner', computedFlows, {
763
- keys: East.function([StringType, ComputedFlow], SetType(OptionType(StringType)), (_$, _id, flow) => flow.states.toSet((_$2, state) => state.owner)),
799
+ export const computedFlows = e3.record('computed_flows', DictType(StringType, ComputedFlow), {
800
+ initial: new Map([
801
+ ["a", { description: "Inbound", states: [{ lane: "load", owner: some("team-a") }, { lane: "load", owner: some("team-a") }, { lane: "review", owner: none }] }],
802
+ ["b", { description: "Inbound", states: [{ lane: "load", owner: some("team-b") }] }],
803
+ ["c", { description: "Returns", states: [{ lane: "review", owner: none }] }],
804
+ ["d", { description: "Empty", states: [] }],
805
+ ]),
806
+ indexes: (index) => ({
807
+ description: index.on(["description"]),
808
+ state_count: index.key(East.function([StringType, ComputedFlow], StructType({ stateCount: IntegerType }), (_$, _id, flow) => ({ stateCount: flow.states.size() }))),
809
+ description_count: index.key(East.function([StringType, ComputedFlow], StructType({ description: StringType, stateCount: IntegerType }), (_$, _id, flow) => ({ description: flow.description, stateCount: flow.states.size() }))),
810
+ lane: index.keys(East.function([StringType, ComputedFlow], SetType(StructType({ lane: StringType })), (_$, _id, flow) => flow.states.toSet((_$2, state) => ({ lane: state.lane })))),
811
+ owner: index.keys(East.function([StringType, ComputedFlow], SetType(StructType({ owner: OptionType(StringType) })), (_$, _id, flow) => flow.states.toSet((_$2, state) => ({ owner: state.owner })))),
812
+ // Scalar computed keys, each a field by its index's name.
813
+ label: index.key(East.function([StringType, ComputedFlow], StringType, (_$, _id, flow) => flow.description)),
814
+ size: index.key(East.function([StringType, ComputedFlow], IntegerType, (_$, _id, flow) => flow.states.size())),
815
+ decisionOwner: index.keys(East.function([StringType, ComputedFlow], SetType(OptionType(StringType)), (_$, _id, flow) => flow.states.toSet((_$2, state) => state.owner))),
816
+ }),
817
+ mutations: (mutation) => ({
818
+ patch: mutation.patch(),
819
+ }),
764
820
  });
765
821
  //# sourceMappingURL=data.examples.js.map