@bitbybit-dev/base 1.3.2 → 1.4.0-rc.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 (77) hide show
  1. package/README.md +1 -1
  2. package/lib/api/GlobalCDNProvider.js +1 -1
  3. package/lib/api/index.d.ts +2 -0
  4. package/lib/api/index.js +2 -0
  5. package/lib/api/inputs/base-inputs.d.ts +10 -4
  6. package/lib/api/inputs/color-inputs.d.ts +24 -23
  7. package/lib/api/inputs/color-inputs.js +1 -0
  8. package/lib/api/inputs/dates-inputs.d.ts +16 -16
  9. package/lib/api/inputs/frame-inputs.d.ts +515 -0
  10. package/lib/api/inputs/frame-inputs.js +617 -0
  11. package/lib/api/inputs/index.d.ts +1 -0
  12. package/lib/api/inputs/index.js +1 -0
  13. package/lib/api/inputs/io-inputs.d.ts +3 -3
  14. package/lib/api/inputs/io-inputs.js +1 -1
  15. package/lib/api/inputs/lists-inputs.d.ts +23 -23
  16. package/lib/api/inputs/logic-inputs.d.ts +11 -11
  17. package/lib/api/inputs/math-inputs.d.ts +49 -49
  18. package/lib/api/inputs/math-inputs.js +4 -4
  19. package/lib/api/inputs/mesh-inputs.d.ts +3 -3
  20. package/lib/api/inputs/mesh-inputs.js +3 -3
  21. package/lib/api/inputs/point-inputs.d.ts +39 -38
  22. package/lib/api/inputs/point-inputs.js +6 -5
  23. package/lib/api/inputs/polyline-inputs.d.ts +5 -4
  24. package/lib/api/inputs/polyline-inputs.js +3 -3
  25. package/lib/api/inputs/text-inputs.d.ts +34 -33
  26. package/lib/api/inputs/text-inputs.js +15 -12
  27. package/lib/api/inputs/transforms-inputs.d.ts +16 -16
  28. package/lib/api/inputs/vector-inputs.d.ts +26 -25
  29. package/lib/api/inputs/vector-inputs.js +2 -1
  30. package/lib/api/kernel-calls/call-by-path.d.ts +12 -0
  31. package/lib/api/kernel-calls/call-by-path.js +36 -0
  32. package/lib/api/kernel-calls/constraints.d.ts +53 -0
  33. package/lib/api/kernel-calls/constraints.js +21 -0
  34. package/lib/api/kernel-calls/describe-failure.d.ts +32 -0
  35. package/lib/api/kernel-calls/describe-failure.js +164 -0
  36. package/lib/api/kernel-calls/errors.d.ts +55 -0
  37. package/lib/api/kernel-calls/errors.js +42 -0
  38. package/lib/api/kernel-calls/failure-message.d.ts +18 -0
  39. package/lib/api/kernel-calls/failure-message.js +36 -0
  40. package/lib/api/kernel-calls/index.d.ts +10 -0
  41. package/lib/api/kernel-calls/index.js +10 -0
  42. package/lib/api/kernel-calls/input-rules.d.ts +67 -0
  43. package/lib/api/kernel-calls/input-rules.js +135 -0
  44. package/lib/api/kernel-calls/input-validation.d.ts +130 -0
  45. package/lib/api/kernel-calls/input-validation.js +221 -0
  46. package/lib/api/kernel-calls/rehydrate.d.ts +16 -0
  47. package/lib/api/kernel-calls/rehydrate.js +38 -0
  48. package/lib/api/kernel-calls/resolve-dto.d.ts +59 -0
  49. package/lib/api/kernel-calls/resolve-dto.js +61 -0
  50. package/lib/api/kernel-calls/with-defaults.d.ts +16 -0
  51. package/lib/api/kernel-calls/with-defaults.js +53 -0
  52. package/lib/api/resolved-inputs/index.d.ts +304 -0
  53. package/lib/api/resolved-inputs/index.js +1 -0
  54. package/lib/api/services/color.js +43 -26
  55. package/lib/api/services/dates.js +53 -33
  56. package/lib/api/services/frame.d.ts +670 -0
  57. package/lib/api/services/frame.js +1040 -0
  58. package/lib/api/services/helpers/dxf/dxf-generator.d.ts +2 -3
  59. package/lib/api/services/helpers/dxf/dxf-generator.js +27 -37
  60. package/lib/api/services/helpers/dxf/dxf.js +10 -4
  61. package/lib/api/services/helpers/frame-axes.d.ts +36 -0
  62. package/lib/api/services/helpers/frame-axes.js +57 -0
  63. package/lib/api/services/helpers/matrices.d.ts +17 -0
  64. package/lib/api/services/helpers/matrices.js +51 -0
  65. package/lib/api/services/index.d.ts +1 -0
  66. package/lib/api/services/index.js +1 -0
  67. package/lib/api/services/line.js +15 -12
  68. package/lib/api/services/lists.js +174 -136
  69. package/lib/api/services/logic.js +44 -34
  70. package/lib/api/services/math.js +127 -82
  71. package/lib/api/services/mesh.js +20 -13
  72. package/lib/api/services/point.js +62 -46
  73. package/lib/api/services/polyline.js +22 -18
  74. package/lib/api/services/text.js +81 -46
  75. package/lib/api/services/transforms.js +38 -25
  76. package/lib/api/services/vector.js +37 -22
  77. package/package.json +1 -1
@@ -23,7 +23,7 @@ export declare namespace Text {
23
23
  * The text the method works on; it is not changed, a new text is returned.
24
24
  * @default Hello World
25
25
  */
26
- text: string;
26
+ text?: string | undefined;
27
27
  }
28
28
  /**
29
29
  * A text and a separator for `text.split`.
@@ -34,12 +34,12 @@ export declare namespace Text {
34
34
  * The text to cut into pieces.
35
35
  * @default a,b,c
36
36
  */
37
- text: string;
37
+ text?: string | undefined;
38
38
  /**
39
39
  * The text that marks a cut; it is dropped from the pieces.
40
40
  * @default ,
41
41
  */
42
- separator: string;
42
+ separator?: string | undefined;
43
43
  }
44
44
  /**
45
45
  * A text, what to look for in it and what to put in its place, for `text.replaceAll`.
@@ -50,17 +50,17 @@ export declare namespace Text {
50
50
  * The text to make the replacements in.
51
51
  * @default a-c
52
52
  */
53
- text: string;
53
+ text?: string | undefined;
54
54
  /**
55
55
  * The text to look for; every occurrence is replaced.
56
56
  * @default -
57
57
  */
58
- search: string;
58
+ search?: string | undefined;
59
59
  /**
60
60
  * The text that takes the place of each occurrence.
61
61
  * @default b
62
62
  */
63
- replaceWith: string;
63
+ replaceWith?: string | undefined;
64
64
  }
65
65
  /**
66
66
  * Texts and a separator for `text.join`, which writes them one after another.
@@ -76,7 +76,7 @@ export declare namespace Text {
76
76
  * The text placed between neighbors; an empty text joins them directly.
77
77
  * @default ,
78
78
  */
79
- separator: string;
79
+ separator?: string | undefined;
80
80
  }
81
81
  /**
82
82
  * Any value for `text.toString`, which turns it into text the way JavaScript prints it.
@@ -110,12 +110,12 @@ export declare namespace Text {
110
110
  * The text with placeholders such as `{0}` and `{1}`.
111
111
  * @default Hello {0}
112
112
  */
113
- text: string;
113
+ text?: string | undefined;
114
114
  /**
115
115
  * The values, in placeholder order: the first fills `{0}`, the second `{1}`.
116
116
  * @default ["World"]
117
117
  */
118
- values: string[];
118
+ values?: string[] | undefined;
119
119
  }
120
120
  /**
121
121
  * A text and something to look for in it, for `text.includes`, `text.startsWith`,
@@ -127,12 +127,12 @@ export declare namespace Text {
127
127
  * The text to look in.
128
128
  * @default hello world
129
129
  */
130
- text: string;
130
+ text?: string | undefined;
131
131
  /**
132
132
  * The text to look for, matched exactly, including case.
133
133
  * @default world
134
134
  */
135
- search: string;
135
+ search?: string | undefined;
136
136
  }
137
137
  /**
138
138
  * A text and a range of positions for `text.substring` and `text.slice`.
@@ -143,7 +143,7 @@ export declare namespace Text {
143
143
  * The text to take characters from.
144
144
  * @default hello world
145
145
  */
146
- text: string;
146
+ text?: string | undefined;
147
147
  /**
148
148
  * Position of the first character to take, counting from 0.
149
149
  * @default 0
@@ -151,11 +151,12 @@ export declare namespace Text {
151
151
  * @maximum Infinity
152
152
  * @step 1
153
153
  */
154
- start: number;
154
+ start?: number | undefined;
155
155
  /**
156
156
  * Position just after the last character to take; leave it out to take everything to the
157
157
  * end.
158
- * @default 5
158
+ * @default undefined
159
+ * @optional true
159
160
  * @minimum 0
160
161
  * @maximum Infinity
161
162
  * @step 1
@@ -171,7 +172,7 @@ export declare namespace Text {
171
172
  * The text to read a character from.
172
173
  * @default hello
173
174
  */
174
- text: string;
175
+ text?: string | undefined;
175
176
  /**
176
177
  * Position of the character, counting from 0.
177
178
  * @default 0
@@ -179,7 +180,7 @@ export declare namespace Text {
179
180
  * @maximum Infinity
180
181
  * @step 1
181
182
  */
182
- index: number;
183
+ index?: number | undefined;
183
184
  }
184
185
  /**
185
186
  * A text, a length and a filler for `text.padStart` and `text.padEnd`.
@@ -190,7 +191,7 @@ export declare namespace Text {
190
191
  * The text to lengthen.
191
192
  * @default x
192
193
  */
193
- text: string;
194
+ text?: string | undefined;
194
195
  /**
195
196
  * The length to reach; a text already that long stays as it is.
196
197
  * @default 3
@@ -198,12 +199,12 @@ export declare namespace Text {
198
199
  * @maximum Infinity
199
200
  * @step 1
200
201
  */
201
- length: number;
202
+ length?: number | undefined;
202
203
  /**
203
204
  * The filler repeated until the length is reached; the last repeat is cut short if needed.
204
205
  * @default a
205
206
  */
206
- padString: string;
207
+ padString?: string | undefined;
207
208
  }
208
209
  /**
209
210
  * A text and a count for `text.repeat`.
@@ -214,7 +215,7 @@ export declare namespace Text {
214
215
  * The text that is written out again and again.
215
216
  * @default ha
216
217
  */
217
- text: string;
218
+ text?: string | undefined;
218
219
  /**
219
220
  * How many times the text appears in the result.
220
221
  * @default 3
@@ -222,7 +223,7 @@ export declare namespace Text {
222
223
  * @maximum Infinity
223
224
  * @step 1
224
225
  */
225
- count: number;
226
+ count?: number | undefined;
226
227
  }
227
228
  /**
228
229
  * Texts for `text.concat`, joined with nothing between them.
@@ -233,7 +234,7 @@ export declare namespace Text {
233
234
  * The texts to join, in order.
234
235
  * @default ["hello", " ", "world"]
235
236
  */
236
- texts: string[];
237
+ texts?: string[] | undefined;
237
238
  }
238
239
  /**
239
240
  * A text and a regular expression for `text.regexTest`, `text.regexMatch`, `text.regexSearch`
@@ -245,19 +246,19 @@ export declare namespace Text {
245
246
  * The text the pattern is applied to.
246
247
  * @default hello123world
247
248
  */
248
- text: string;
249
+ text?: string | undefined;
249
250
  /**
250
251
  * The regular expression, written as it would be between the slashes in JavaScript, such as
251
252
  * `[0-9]+`.
252
253
  * @default [0-9]+
253
254
  */
254
- pattern: string;
255
+ pattern?: string | undefined;
255
256
  /**
256
257
  * The regular expression flags: `g` for every match, `i` to ignore case, `m` for
257
258
  * line-by-line anchors, and `s`, `u`, `y` as in JavaScript.
258
259
  * @default g
259
260
  */
260
- flags: string;
261
+ flags?: string | undefined;
261
262
  }
262
263
  /**
263
264
  * A text, a regular expression and a replacement for `text.regexReplace`.
@@ -268,25 +269,25 @@ export declare namespace Text {
268
269
  * The text to make the replacements in.
269
270
  * @default hello123world456
270
271
  */
271
- text: string;
272
+ text?: string | undefined;
272
273
  /**
273
274
  * The regular expression, written as it would be between the slashes in JavaScript, such as
274
275
  * `[0-9]+`.
275
276
  * @default [0-9]+
276
277
  */
277
- pattern: string;
278
+ pattern?: string | undefined;
278
279
  /**
279
280
  * The regular expression flags: `g` replaces every match instead of the first, `i` ignores
280
281
  * case, and `m`, `s`, `u`, `y` work as in JavaScript.
281
282
  * @default g
282
283
  */
283
- flags: string;
284
+ flags?: string | undefined;
284
285
  /**
285
286
  * The text that takes the place of each match; `$1` and the like refer to capture groups,
286
287
  * as in JavaScript.
287
288
  * @default X
288
289
  */
289
- replaceWith: string;
290
+ replaceWith?: string | undefined;
290
291
  }
291
292
  /**
292
293
  * One character and its size and placement for `text.vectorChar`, which draws it as stroke
@@ -299,7 +300,7 @@ export declare namespace Text {
299
300
  * question mark.
300
301
  * @default A
301
302
  */
302
- char: string;
303
+ char?: string | undefined;
303
304
  /**
304
305
  * How far to shift the strokes along X, in model units.
305
306
  * @default 0
@@ -314,13 +315,13 @@ export declare namespace Text {
314
315
  * @minimum -Infinity
315
316
  * @maximum Infinity
316
317
  * @step 0.1
317
- * @optional true
318
+ * @default 0
318
319
  */
319
320
  yOffset?: number | undefined;
320
321
  /**
321
322
  * The height of a capital letter, in model units; the strokes are scaled to it.
322
323
  * @default 1
323
- * @minimum -Infinity
324
+ * @minimum 0
324
325
  * @maximum Infinity
325
326
  * @step 0.1
326
327
  */
@@ -365,7 +366,7 @@ export declare namespace Text {
365
366
  /**
366
367
  * The height of a capital letter, in model units.
367
368
  * @default 1
368
- * @minimum -Infinity
369
+ * @minimum 0
369
370
  * @maximum Infinity
370
371
  * @step 0.1
371
372
  */
@@ -1,4 +1,5 @@
1
1
  /* eslint-disable @typescript-eslint/no-namespace */
2
+ import { Base } from "./base-inputs";
2
3
  /**
3
4
 
4
5
 
@@ -196,15 +197,6 @@ export var Text;
196
197
  * @step 1
197
198
  */
198
199
  this.start = 0;
199
- /**
200
- * Position just after the last character to take; leave it out to take everything to the
201
- * end.
202
- * @default 5
203
- * @minimum 0
204
- * @maximum Infinity
205
- * @step 1
206
- */
207
- this.end = 5;
208
200
  if (text !== undefined) {
209
201
  this.text = text;
210
202
  }
@@ -426,13 +418,13 @@ export var Text;
426
418
  * @minimum -Infinity
427
419
  * @maximum Infinity
428
420
  * @step 0.1
429
- * @optional true
421
+ * @default 0
430
422
  */
431
423
  this.yOffset = 0;
432
424
  /**
433
425
  * The height of a capital letter, in model units; the strokes are scaled to it.
434
426
  * @default 1
435
- * @minimum -Infinity
427
+ * @minimum 0
436
428
  * @maximum Infinity
437
429
  * @step 0.1
438
430
  */
@@ -470,6 +462,11 @@ export var Text;
470
462
  */
471
463
  class VectorTextDto {
472
464
  constructor(text, xOffset, yOffset, height, lineSpacing, letterSpacing, align, extrudeOffset, centerOnOrigin) {
465
+ /**
466
+ * The text to draw; a line break starts a new line.
467
+ * @default Hello World
468
+ */
469
+ this.text = "Hello World";
473
470
  /**
474
471
  * How far to shift the whole block along X, in model units.
475
472
  * @default 0
@@ -489,7 +486,7 @@ export var Text;
489
486
  /**
490
487
  * The height of a capital letter, in model units.
491
488
  * @default 1
492
- * @minimum -Infinity
489
+ * @minimum 0
493
490
  * @maximum Infinity
494
491
  * @step 0.1
495
492
  */
@@ -512,6 +509,12 @@ export var Text;
512
509
  * @step 0.1
513
510
  */
514
511
  this.letterSpacing = 0;
512
+ /**
513
+ * How lines of different length line up: at their left edge, their center or their right
514
+ * edge.
515
+ * @default left
516
+ */
517
+ this.align = Base.horizontalAlignEnum.left;
515
518
  /**
516
519
  * A margin, in model units, taken off the height and split above and below each character,
517
520
  * so extruded text keeps its full size.
@@ -19,17 +19,17 @@ export declare namespace Transforms {
19
19
  * @maximum Infinity
20
20
  * @step 1
21
21
  */
22
- angle: number;
22
+ angle?: number | undefined;
23
23
  /**
24
24
  * The direction of the axis to turn around.
25
25
  * @default [0, 1, 0]
26
26
  */
27
- axis: Base.Vector3;
27
+ axis?: Base.Vector3 | undefined;
28
28
  /**
29
29
  * A point the axis passes through; it stays in place.
30
30
  * @default [0, 0, 0]
31
31
  */
32
- center: Base.Point3;
32
+ center?: Base.Point3 | undefined;
33
33
  }
34
34
  /**
35
35
  * A center and an angle for `transforms.rotationCenterX`, `transforms.rotationCenterY` and
@@ -45,12 +45,12 @@ export declare namespace Transforms {
45
45
  * @maximum Infinity
46
46
  * @step 1
47
47
  */
48
- angle: number;
48
+ angle?: number | undefined;
49
49
  /**
50
50
  * The point the axis passes through; it stays in place.
51
51
  * @default [0, 0, 0]
52
52
  */
53
- center: Base.Point3;
53
+ center?: Base.Point3 | undefined;
54
54
  }
55
55
  /**
56
56
  * Three angles and a center for `transforms.rotationCenterYawPitchRoll`.
@@ -64,7 +64,7 @@ export declare namespace Transforms {
64
64
  * @maximum Infinity
65
65
  * @step 1
66
66
  */
67
- yaw: number;
67
+ yaw?: number | undefined;
68
68
  /**
69
69
  * The turn about the X axis, in degrees.
70
70
  * @default 0
@@ -72,7 +72,7 @@ export declare namespace Transforms {
72
72
  * @maximum Infinity
73
73
  * @step 1
74
74
  */
75
- pitch: number;
75
+ pitch?: number | undefined;
76
76
  /**
77
77
  * The turn about the Z axis, in degrees.
78
78
  * @default 0
@@ -80,12 +80,12 @@ export declare namespace Transforms {
80
80
  * @maximum Infinity
81
81
  * @step 1
82
82
  */
83
- roll: number;
83
+ roll?: number | undefined;
84
84
  /**
85
85
  * The point the rotation turns around; it stays in place.
86
86
  * @default [0, 0, 0]
87
87
  */
88
- center: Base.Point3;
88
+ center?: Base.Point3 | undefined;
89
89
  }
90
90
  /**
91
91
  * A factor per axis for `transforms.scaleXYZ`, measured from the origin.
@@ -97,7 +97,7 @@ export declare namespace Transforms {
97
97
  * X and Z as they are.
98
98
  * @default [1, 1, 1]
99
99
  */
100
- scaleXyz: Base.Vector3;
100
+ scaleXyz?: Base.Vector3 | undefined;
101
101
  }
102
102
  /**
103
103
  * A center, a direction and a factor for `transforms.stretchDirFromCenter`.
@@ -134,13 +134,13 @@ export declare namespace Transforms {
134
134
  * The point that stays in place while everything else moves away from it or toward it.
135
135
  * @default [0, 0, 0]
136
136
  */
137
- center: Base.Point3;
137
+ center?: Base.Point3 | undefined;
138
138
  /**
139
139
  * The factor for each axis as `[x, y, z]`: `[1, 2, 1]` doubles distances along Y and leaves
140
140
  * X and Z as they are.
141
141
  * @default [1, 1, 1]
142
142
  */
143
- scaleXyz: Base.Vector3;
143
+ scaleXyz?: Base.Vector3 | undefined;
144
144
  }
145
145
  /**
146
146
  * One factor for `transforms.uniformScale`, applied on every axis from the origin.
@@ -155,7 +155,7 @@ export declare namespace Transforms {
155
155
  * @maximum Infinity
156
156
  * @step 0.1
157
157
  */
158
- scale: number;
158
+ scale?: number | undefined;
159
159
  }
160
160
  /**
161
161
  * One factor and a center for `transforms.uniformScaleFromCenter`.
@@ -170,12 +170,12 @@ export declare namespace Transforms {
170
170
  * @maximum Infinity
171
171
  * @step 0.1
172
172
  */
173
- scale: number;
173
+ scale?: number | undefined;
174
174
  /**
175
175
  * The point that stays in place while everything else moves away from it or toward it.
176
176
  * @default [0, 0, 0]
177
177
  */
178
- center: Base.Point3;
178
+ center?: Base.Point3 | undefined;
179
179
  }
180
180
  /**
181
181
  * A vector for `transforms.translationXYZ`, which builds the matrix that moves by it.
@@ -186,7 +186,7 @@ export declare namespace Transforms {
186
186
  * How far to move along each axis, as `[x, y, z]` in model units.
187
187
  * @default [0, 0, 0]
188
188
  */
189
- translation: Base.Vector3;
189
+ translation?: Base.Vector3 | undefined;
190
190
  }
191
191
  /**
192
192
  * Several vectors for `transforms.translationsXYZ`, one transformation each.
@@ -53,7 +53,7 @@ export declare namespace Vector {
53
53
  * @minimum 0
54
54
  * @maximum Infinity
55
55
  */
56
- tolerance: number;
56
+ tolerance?: number | undefined;
57
57
  }
58
58
  /**
59
59
  * Vectors to filter with `vector.removeConsecutiveDuplicateVectors`: only a vector that repeats
@@ -71,14 +71,14 @@ export declare namespace Vector {
71
71
  * of points cleanly.
72
72
  * @default false
73
73
  */
74
- checkFirstAndLast: boolean;
74
+ checkFirstAndLast?: boolean | undefined;
75
75
  /**
76
76
  * Two vectors count as the same when every entry differs by less than this.
77
77
  * @default 1e-7
78
78
  * @minimum 0
79
79
  * @maximum Infinity
80
80
  */
81
- tolerance: number;
81
+ tolerance?: number | undefined;
82
82
  }
83
83
  /**
84
84
  * Two vectors to compare with `vector.vectorsTheSame`, and how close their entries must be.
@@ -101,7 +101,7 @@ export declare namespace Vector {
101
101
  * @minimum 0
102
102
  * @maximum Infinity
103
103
  */
104
- tolerance: number;
104
+ tolerance?: number | undefined;
105
105
  }
106
106
  /**
107
107
  * One vector of any length for the single-vector methods of `vector`: `sum`, `min`, `max`,
@@ -149,7 +149,7 @@ export declare namespace Vector {
149
149
  * @maximum Infinity
150
150
  * @step 1
151
151
  */
152
- max: number;
152
+ max?: number | undefined;
153
153
  }
154
154
  /**
155
155
  * The three values `vector.vectorXYZ` puts together into `[x, y, z]`.
@@ -163,7 +163,7 @@ export declare namespace Vector {
163
163
  * @maximum Infinity
164
164
  * @step 0.5
165
165
  */
166
- x: number;
166
+ x?: number | undefined;
167
167
  /**
168
168
  * The Y value, the second entry; Y is up.
169
169
  * @default 0
@@ -171,7 +171,7 @@ export declare namespace Vector {
171
171
  * @maximum Infinity
172
172
  * @step 0.5
173
173
  */
174
- y: number;
174
+ y?: number | undefined;
175
175
  /**
176
176
  * The Z value, the third entry.
177
177
  * @default 0
@@ -179,7 +179,7 @@ export declare namespace Vector {
179
179
  * @maximum Infinity
180
180
  * @step 0.5
181
181
  */
182
- z: number;
182
+ z?: number | undefined;
183
183
  }
184
184
  /**
185
185
  * The two values `vector.vectorXY` puts together into `[x, y]`.
@@ -193,7 +193,7 @@ export declare namespace Vector {
193
193
  * @maximum Infinity
194
194
  * @step 0.5
195
195
  */
196
- x: number;
196
+ x?: number | undefined;
197
197
  /**
198
198
  * The Y value, the second entry.
199
199
  * @default 0
@@ -201,7 +201,7 @@ export declare namespace Vector {
201
201
  * @maximum Infinity
202
202
  * @step 0.5
203
203
  */
204
- y: number;
204
+ y?: number | undefined;
205
205
  }
206
206
  /**
207
207
  * A start, an end and a step for `vector.span`, which lists every number from `min` to `max` in
@@ -213,11 +213,12 @@ export declare namespace Vector {
213
213
  * Distance between neighboring numbers; the last number is `max` only when a step lands on
214
214
  * it.
215
215
  * @default 0.1
216
- * @minimum -Infinity
216
+ * @minimum 0
217
+ * @exclusiveMinimum true
217
218
  * @maximum Infinity
218
219
  * @step 0.1
219
220
  */
220
- step: number;
221
+ step?: number | undefined;
221
222
  /**
222
223
  * The first number of the span.
223
224
  * @default 0
@@ -225,7 +226,7 @@ export declare namespace Vector {
225
226
  * @maximum Infinity
226
227
  * @step 1
227
228
  */
228
- min: number;
229
+ min?: number | undefined;
229
230
  /**
230
231
  * The end of the span; included when a step lands on it.
231
232
  * @default 1
@@ -233,7 +234,7 @@ export declare namespace Vector {
233
234
  * @maximum Infinity
234
235
  * @step 1
235
236
  */
236
- max: number;
237
+ max?: number | undefined;
237
238
  }
238
239
  /**
239
240
  * A start, an end, a count and an easing curve for `vector.spanEaseItems`, which spaces the
@@ -248,7 +249,7 @@ export declare namespace Vector {
248
249
  * @maximum Infinity
249
250
  * @step 1
250
251
  */
251
- nrItems: number;
252
+ nrItems?: number | undefined;
252
253
  /**
253
254
  * The first number.
254
255
  * @default 0
@@ -256,7 +257,7 @@ export declare namespace Vector {
256
257
  * @maximum Infinity
257
258
  * @step 1
258
259
  */
259
- min: number;
260
+ min?: number | undefined;
260
261
  /**
261
262
  * The last number.
262
263
  * @default 1
@@ -264,19 +265,19 @@ export declare namespace Vector {
264
265
  * @maximum Infinity
265
266
  * @step 1
266
267
  */
267
- max: number;
268
+ max?: number | undefined;
268
269
  /**
269
270
  * The easing curve that spaces the numbers: an `easeIn` curve bunches them near `min`, an
270
271
  * `easeOut` curve near `max`, an `easeInOut` curve at both ends.
271
272
  * @default easeInSine
272
273
  */
273
- ease: Math.easeEnum;
274
+ ease?: Math.easeEnum | undefined;
274
275
  /**
275
276
  * When true, the result holds the gaps between neighboring numbers instead of the numbers
276
277
  * themselves; the first entry is `min`.
277
278
  * @default false
278
279
  */
279
- intervals: boolean;
280
+ intervals?: boolean | undefined;
280
281
  }
281
282
  /**
282
283
  * A start, an end and a count for `vector.spanLinearItems`, which spaces the numbers evenly.
@@ -290,7 +291,7 @@ export declare namespace Vector {
290
291
  * @maximum Infinity
291
292
  * @step 1
292
293
  */
293
- nrItems: number;
294
+ nrItems?: number | undefined;
294
295
  /**
295
296
  * The first number.
296
297
  * @default 0
@@ -298,7 +299,7 @@ export declare namespace Vector {
298
299
  * @maximum Infinity
299
300
  * @step 1
300
301
  */
301
- min: number;
302
+ min?: number | undefined;
302
303
  /**
303
304
  * The last number.
304
305
  * @default 1
@@ -306,7 +307,7 @@ export declare namespace Vector {
306
307
  * @maximum Infinity
307
308
  * @step 1
308
309
  */
309
- max: number;
310
+ max?: number | undefined;
310
311
  }
311
312
  /**
312
313
  * A start point, a direction and a distance for `vector.onRay`, which finds the point that far
@@ -327,7 +328,7 @@ export declare namespace Vector {
327
328
  * @maximum Infinity
328
329
  * @step 1
329
330
  */
330
- distance: number;
331
+ distance?: number | undefined;
331
332
  /**
332
333
  * The direction to travel in, used as given; a unit vector makes `distance` a length in
333
334
  * model units.
@@ -360,7 +361,7 @@ export declare namespace Vector {
360
361
  * @maximum Infinity
361
362
  * @step 0.1
362
363
  */
363
- fraction: number;
364
+ fraction?: number | undefined;
364
365
  /**
365
366
  * The vector the blend reaches at fraction 1.
366
367
  * @default undefined
@@ -385,7 +386,7 @@ export declare namespace Vector {
385
386
  * @maximum Infinity
386
387
  * @step 0.1
387
388
  */
388
- scalar: number;
389
+ scalar?: number | undefined;
389
390
  /**
390
391
  * The vector to scale.
391
392
  * @default undefined
@@ -244,7 +244,8 @@ export var Vector;
244
244
  * Distance between neighboring numbers; the last number is `max` only when a step lands on
245
245
  * it.
246
246
  * @default 0.1
247
- * @minimum -Infinity
247
+ * @minimum 0
248
+ * @exclusiveMinimum true
248
249
  * @maximum Infinity
249
250
  * @step 0.1
250
251
  */
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Calls the method a dotted path names under `root`, with `inputs` as its one argument:
3
+ * `"shapes.solid.createBox"` calls `root.shapes.solid.createBox(inputs)`, with the owning object as
4
+ * `this`. Any depth is walked.
5
+ * @param root - The object the path starts from
6
+ * @param path - The dotted path of the method
7
+ * @param inputs - The single argument the method receives
8
+ * @returns What the method returns
9
+ * @throws Error when a segment is empty or reaches an object's prototype machinery, when a segment
10
+ * on the way is not an object, or when the last one is not a method
11
+ */
12
+ export declare function callByPath(root: object, path: string, inputs: unknown): unknown;