@snaptrude/plugin-core 1.0.2-plainpoint-20261026.2 → 1.1.0-pbr-20261026.1

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 (95) hide show
  1. package/dist/api/core/camera/index.d.ts +4 -12
  2. package/dist/api/core/camera/index.d.ts.map +1 -1
  3. package/dist/api/core/comment/index.d.ts +3 -7
  4. package/dist/api/core/comment/index.d.ts.map +1 -1
  5. package/dist/api/core/geom/create/index.d.ts +21 -69
  6. package/dist/api/core/geom/create/index.d.ts.map +1 -1
  7. package/dist/api/core/geom/query/circle.d.ts +11 -31
  8. package/dist/api/core/geom/query/circle.d.ts.map +1 -1
  9. package/dist/api/core/geom/query/contour.d.ts +7 -19
  10. package/dist/api/core/geom/query/contour.d.ts.map +1 -1
  11. package/dist/api/core/geom/query/curve.d.ts +24 -72
  12. package/dist/api/core/geom/query/curve.d.ts.map +1 -1
  13. package/dist/api/core/geom/query/profile.d.ts +7 -19
  14. package/dist/api/core/geom/query/profile.d.ts.map +1 -1
  15. package/dist/api/core/geom/update/contour.d.ts +12 -36
  16. package/dist/api/core/geom/update/contour.d.ts.map +1 -1
  17. package/dist/api/core/geom/update/curve.d.ts +5 -13
  18. package/dist/api/core/geom/update/curve.d.ts.map +1 -1
  19. package/dist/api/core/geom/update/profile.d.ts +12 -36
  20. package/dist/api/core/geom/update/profile.d.ts.map +1 -1
  21. package/dist/api/core/io/import/index.d.ts +3 -7
  22. package/dist/api/core/io/import/index.d.ts.map +1 -1
  23. package/dist/api/core/math/quat.d.ts +2 -2
  24. package/dist/api/core/math/quat.d.ts.map +1 -1
  25. package/dist/api/core/math/vec3.d.ts +15 -15
  26. package/dist/api/core/math/vec3.d.ts.map +1 -1
  27. package/dist/api/design/boolean/index.d.ts +4 -20
  28. package/dist/api/design/boolean/index.d.ts.map +1 -1
  29. package/dist/api/design/create/bulk-items.d.ts +4 -20
  30. package/dist/api/design/create/bulk-items.d.ts.map +1 -1
  31. package/dist/api/design/create/index.d.ts +27 -67
  32. package/dist/api/design/create/index.d.ts.map +1 -1
  33. package/dist/api/design/delete/index.d.ts +7 -14
  34. package/dist/api/design/delete/index.d.ts.map +1 -1
  35. package/dist/api/design/dimensions.d.ts +6 -14
  36. package/dist/api/design/dimensions.d.ts.map +1 -1
  37. package/dist/api/design/edit/index.d.ts +3 -7
  38. package/dist/api/design/edit/index.d.ts.map +1 -1
  39. package/dist/api/design/erase/index.d.ts +2 -10
  40. package/dist/api/design/erase/index.d.ts.map +1 -1
  41. package/dist/api/design/family.d.ts +12 -5
  42. package/dist/api/design/family.d.ts.map +1 -1
  43. package/dist/api/design/index.d.ts +5 -0
  44. package/dist/api/design/index.d.ts.map +1 -1
  45. package/dist/api/design/lights/index.d.ts +504 -0
  46. package/dist/api/design/lights/index.d.ts.map +1 -0
  47. package/dist/api/design/lock.d.ts +0 -3
  48. package/dist/api/design/lock.d.ts.map +1 -1
  49. package/dist/api/design/materials/index.d.ts +63 -7
  50. package/dist/api/design/materials/index.d.ts.map +1 -1
  51. package/dist/api/design/transform/index.d.ts +8 -28
  52. package/dist/api/design/transform/index.d.ts.map +1 -1
  53. package/dist/api/design/windows/index.d.ts +34 -1
  54. package/dist/api/design/windows/index.d.ts.map +1 -1
  55. package/dist/api/entity/space.d.ts +6 -30
  56. package/dist/api/entity/space.d.ts.map +1 -1
  57. package/dist/api/presentation/drawings.d.ts +1 -1
  58. package/dist/handles.d.ts +0 -8
  59. package/dist/handles.d.ts.map +1 -1
  60. package/dist/index.cjs +2570 -2428
  61. package/dist/index.cjs.map +1 -1
  62. package/dist/index.js +2553 -2427
  63. package/dist/index.js.map +1 -1
  64. package/package.json +13 -13
  65. package/src/api/core/camera/index.ts +5 -5
  66. package/src/api/core/comment/index.ts +3 -3
  67. package/src/api/core/geom/create/index.ts +25 -25
  68. package/src/api/core/geom/query/circle.ts +11 -11
  69. package/src/api/core/geom/query/contour.ts +6 -7
  70. package/src/api/core/geom/query/curve.ts +25 -25
  71. package/src/api/core/geom/query/profile.ts +6 -7
  72. package/src/api/core/geom/update/contour.ts +11 -12
  73. package/src/api/core/geom/update/curve.ts +5 -5
  74. package/src/api/core/geom/update/profile.ts +11 -12
  75. package/src/api/core/io/import/index.ts +2 -3
  76. package/src/api/core/math/quat.ts +2 -2
  77. package/src/api/core/math/vec3.ts +16 -16
  78. package/src/api/design/boolean/index.ts +2 -2
  79. package/src/api/design/create/bulk-items.ts +2 -3
  80. package/src/api/design/create/index.ts +26 -27
  81. package/src/api/design/delete/index.ts +7 -14
  82. package/src/api/design/dimensions.ts +4 -5
  83. package/src/api/design/edit/index.ts +3 -3
  84. package/src/api/design/erase/index.ts +2 -2
  85. package/src/api/design/family.ts +12 -2
  86. package/src/api/design/index.ts +5 -0
  87. package/src/api/design/lights/index.ts +406 -0
  88. package/src/api/design/lock.ts +0 -6
  89. package/src/api/design/materials/index.ts +58 -7
  90. package/src/api/design/transform/index.ts +7 -15
  91. package/src/api/design/windows/index.ts +38 -1
  92. package/src/api/entity/space.ts +4 -5
  93. package/src/handles.ts +0 -11
  94. package/api-manifest.json +0 -10607
  95. package/test/handles.test.mjs +0 -36
@@ -21,6 +21,12 @@ import { ComponentHandle, MaterialHandle } from "../../../handles"
21
21
  * is durable only while the component's BREP topology (face count/order) is unchanged.
22
22
  *
23
23
  * `copy` (needs an undo wrapper) lands in a later pass.
24
+ *
25
+ * A material is a reusable finish, not a fixture source. Emissive appearance alone does not
26
+ * create a physical light. Author new fixtures through schema 1.3 family.fixture.emitters:
27
+ * generated side geometry, total lumens, temperature and enabled state belong to the placed
28
+ * fixture, not its shared material. Its visible emission is derived from the same photometry
29
+ * used by direct and DDGI lighting. Repainting a source must not change output or another lamp.
24
30
  */
25
31
  export abstract class PluginDesignMaterialsApi {
26
32
  constructor() {}
@@ -48,16 +54,20 @@ export abstract class PluginDesignMaterialsApi {
48
54
 
49
55
  /**
50
56
  * List the preset material library — the catalog the app's material browser
51
- * shows (the built-in finishes plus the workspace's uploaded materials),
52
- * fetched from the material library service. Library entries are **not**
53
- * scene materials and carry no {@linkcode MaterialHandle}; each is a named
54
- * texture record. To use one, feed it to
57
+ * shows: the deployment PBR catalogue plus the server library and workspace uploads.
58
+ * Library entries are **not** scene materials and carry no {@linkcode MaterialHandle}.
59
+ * PBR names include an identity-qualified suffix `[catalogId@catalogVersion]`:
60
+ * preserve the EXACT returned name and pass `{ name: preset.name }` to create/apply.
61
+ * The host resolves all authored PBR maps, physical coverage and glass properties;
62
+ * do not strip the suffix, substitute an image-only finish, or override color/alpha.
63
+ * Scalar paints and clear glass can have an empty textureUrl and are still valid.
64
+ * For legacy image entries, feed the returned record to
55
65
  * {@linkcode PluginDesignMaterialsApi.create} /
56
66
  * {@linkcode PluginDesignMaterialsApi.apply} as a
57
67
  * {@linkcode PluginMaterialSpec}: `{ name, textureUrl, materialType: category }`.
58
68
  *
59
- * @returns The library as {@linkcode PluginPresetMaterial}`[]` (`[]` when the
60
- * library service is unreachable)
69
+ * @returns The library as {@linkcode PluginPresetMaterial}`[]`. Missing/malformed
70
+ * deployment PBR data rejects; the legacy server library may return `[]` on failure.
61
71
  *
62
72
  * @examplePrompt Show me the preset materials library
63
73
  * @examplePrompt What wood finishes are available in the material library?
@@ -167,6 +177,25 @@ export abstract class PluginDesignMaterialsApi {
167
177
  save?: boolean,
168
178
  ): PluginApiReturn<PluginMaterialResult>
169
179
 
180
+ /**
181
+ * Paint only glazing or frame slots, never the whole window/door. This preserves
182
+ * clear panes when painting metal frames. Families change with their linked copies;
183
+ * legacy instanced types change every instance of that type. BREP components are
184
+ * refused (use applyToFaces), as are locked targets or locked linked/type members.
185
+ * Slot roles come from the authored appearance, not a previously applied paint.
186
+ * Always one undo step. Catalogue selectors use the exact listPresets name.
187
+ * @param components Components whose family/type slots to paint
188
+ * @param slot Authored glazing slots or every other (frame/hardware) slot
189
+ * @param material Existing handle or inline spec, e.g. `{ name: preset.name }`
190
+ * @returns Count of targets whose family/type had at least one matching slot
191
+ * @examplePrompt Paint only the window frames with a catalogue metal finish
192
+ */
193
+ public abstract applyToSlot(
194
+ components: ComponentHandle[],
195
+ slot: "glazing" | "frame",
196
+ material: MaterialHandle | PluginMaterialSpec,
197
+ ): PluginApiReturn<PluginMaterialResult>
198
+
170
199
  /**
171
200
  * Reset one or more components back to the default material for their type,
172
201
  * removing any applied finish. The inverse of `apply`; undoable when `save`
@@ -319,9 +348,11 @@ export abstract class PluginDesignMaterialsApi {
319
348
  * @examplePrompt Make a material from this texture image URL
320
349
  * @examplePrompt Add a semi-transparent glass material to the project
321
350
  * @examplePrompt Define a dark grey concrete finish I can reuse
351
+ * @examplePrompt Make the lampshade a linen that glows when the lamp is on
322
352
  *
323
353
  * # Example
324
354
  * ```ts
355
+ * const linen = await snaptrude.design.materials.create({ name: "Linen Shade", color: "#efe6d4", transmission: 0.3 })
325
356
  * const glass = await snaptrude.design.materials.create({ name: "Frosted Glass", color: "#cfe4e8", alpha: 0.4 })
326
357
  * const walls = await snaptrude.design.query.listWalls({ storeys: [1] })
327
358
  * await snaptrude.design.materials.apply(walls, glass)
@@ -425,6 +456,7 @@ export abstract class PluginDesignMaterialsApi {
425
456
  * | `alpha` | `number` | Opacity `0..1` |
426
457
  * | `materialType` | `string` | Material type tag (optional) |
427
458
  * | `textureUrl` | `string` | Diffuse texture URL (optional) |
459
+ * | `transmission` | `number` | Diffuse transmission `0..1` (optional; absent when none) |
428
460
  */
429
461
  export const PluginMaterialInfo = z.object({
430
462
  name: z.string(),
@@ -433,6 +465,7 @@ export const PluginMaterialInfo = z.object({
433
465
  alpha: z.number(),
434
466
  materialType: z.string().optional(),
435
467
  textureUrl: z.string().optional(),
468
+ transmission: z.number().optional(),
436
469
  })
437
470
  export type PluginMaterialInfo = z.infer<typeof PluginMaterialInfo>
438
471
 
@@ -441,11 +474,18 @@ export type PluginMaterialInfo = z.infer<typeof PluginMaterialInfo>
441
474
  *
442
475
  * | Property | Type | Description |
443
476
  * |---|---|---|
444
- * | `name` | `string` | Name (optional; generated if omitted) |
477
+ * | `name` | `string` | Name (optional; generated if omitted); an exact identity-qualified listPresets name selects the full authored PBR finish |
445
478
  * | `color` | `string` | Diffuse color `#rrggbb` (optional) |
446
479
  * | `textureUrl` | `string` | Diffuse texture URL (optional; wins over color) |
447
480
  * | `alpha` | `number` | Opacity `0..1` (optional) |
448
481
  * | `materialType` | `string` | Material type tag (optional) |
482
+ * | `transmission` | `number` | Diffuse transmission `0..1` (optional): the share of a fixture light the material passes through, scattered |
483
+ *
484
+ * `transmission` is for lampshades and lenses: a fabric or paper shade (linen ~0.3, paper ~0.5)
485
+ * or an opal diffuser (~0.6). A component painted with it glows from the fixture lights
486
+ * (`design.lights`) behind it and passes that share of their light into the room. Fixture
487
+ * lights only: daylight does not pass. Leave it out for opaque finishes. Not combinable with a
488
+ * catalog (listPresets) name.
449
489
  */
450
490
  export const PluginMaterialSpec = z.object({
451
491
  name: z.string().optional(),
@@ -453,6 +493,7 @@ export const PluginMaterialSpec = z.object({
453
493
  textureUrl: z.string().optional(),
454
494
  alpha: z.number().optional(),
455
495
  materialType: z.string().optional(),
496
+ transmission: z.number().min(0).max(1).optional(),
456
497
  })
457
498
  export type PluginMaterialSpec = z.infer<typeof PluginMaterialSpec>
458
499
 
@@ -544,6 +585,16 @@ export type PluginDesignMaterialsApplyArgs = z.infer<
544
585
  typeof PluginDesignMaterialsApplyArgs
545
586
  >
546
587
 
588
+ /** Arguments for the existing host slot-paint contract. */
589
+ export const PluginDesignMaterialsApplyToSlotArgs = z.object({
590
+ components: z.array(ComponentHandle),
591
+ slot: z.enum(["glazing", "frame"]),
592
+ material: z.union([MaterialHandle, PluginMaterialSpec]),
593
+ })
594
+ export type PluginDesignMaterialsApplyToSlotArgs = z.infer<
595
+ typeof PluginDesignMaterialsApplyToSlotArgs
596
+ >
597
+
547
598
  /** Arguments for {@linkcode PluginDesignMaterialsApi.reset}. */
548
599
  export const PluginDesignMaterialsResetArgs = z.object({
549
600
  components: z.array(ComponentHandle),
@@ -1,6 +1,6 @@
1
1
  import * as z from "zod"
2
2
  import { PluginApiReturn } from "../../../types"
3
- import { ComponentHandle, Vec3Handle, Vec3Input } from "../../../handles"
3
+ import { ComponentHandle, Vec3Handle } from "../../../handles"
4
4
  import { PluginDesignChangeResult } from "../lock"
5
5
 
6
6
  /**
@@ -22,17 +22,9 @@ export abstract class PluginDesignTransformApi {
22
22
  * component's absolute position as the anchor). Undoable.
23
23
  *
24
24
  * @param components - Entities to move
25
- * @param displacement - Relative translation as a {@linkcode Vec3Handle}. A displacement
26
- * shorter than 1e-6 is a no-op that succeeds (hosts before Oct 2026 throw
27
- * `OPERATION_FAILED` "No movement occurred" instead, so skip the call when nothing moves).
25
+ * @param displacement - Relative translation as a {@linkcode Vec3Handle}
28
26
  * @param options - `is2D`, `trackParentChange`
29
27
  * @returns {@linkcode PluginDesignChangeResult}
30
- * @throws `OPERATION_FAILED` when the engine drops the whole move. A single connected
31
- * parametric wall moves only across its own line: the vertical part and the part along
32
- * the line are dropped. Move the whole connected run in one call to lift walls; to slide
33
- * or lengthen one wall, delete it and create it again on the new line. Graph-bound walls
34
- * made by Sketch-to-BIM refuse `move` outright (`TOPOLOGY_ERROR` / `ZERO_MOVEMENT`):
35
- * adjust the room boundary that owns the wall instead.
36
28
  *
37
29
  * @examplePrompt Move the selected room 5 metres to the right
38
30
  * @examplePrompt Shift these walls 3m along the x axis
@@ -51,7 +43,7 @@ export abstract class PluginDesignTransformApi {
51
43
  */
52
44
  public abstract move(
53
45
  components: ComponentHandle[],
54
- displacement: Vec3Input,
46
+ displacement: Vec3Handle,
55
47
  options?: { is2D?: boolean; trackParentChange?: boolean },
56
48
  ): PluginApiReturn<PluginDesignChangeResult>
57
49
 
@@ -89,7 +81,7 @@ export abstract class PluginDesignTransformApi {
89
81
  public abstract rotate(
90
82
  components: ComponentHandle[],
91
83
  angleInDegrees: number,
92
- options?: { axis?: Vec3Input; pivot?: Vec3Input; is2D?: boolean },
84
+ options?: { axis?: Vec3Handle; pivot?: Vec3Handle; is2D?: boolean },
93
85
  ): PluginApiReturn<PluginDesignChangeResult>
94
86
 
95
87
  /**
@@ -213,7 +205,7 @@ export type PluginAlignEdge = z.infer<typeof PluginAlignEdge>
213
205
  */
214
206
  export const PluginDesignMoveArgs = z.object({
215
207
  components: z.array(ComponentHandle).min(1),
216
- displacement: Vec3Input,
208
+ displacement: Vec3Handle,
217
209
  is2D: z.boolean().optional(),
218
210
  trackParentChange: z.boolean().optional(),
219
211
  })
@@ -225,9 +217,9 @@ export type PluginDesignMoveArgs = z.infer<typeof PluginDesignMoveArgs>
225
217
  export const PluginDesignRotateArgs = z.object({
226
218
  components: z.array(ComponentHandle).min(1),
227
219
  angleInDegrees: z.number(),
228
- axis: Vec3Input.optional(),
220
+ axis: Vec3Handle.optional(),
229
221
  is2D: z.boolean().optional(),
230
- pivot: Vec3Input.optional(),
222
+ pivot: Vec3Handle.optional(),
231
223
  })
232
224
  export type PluginDesignRotateArgs = z.infer<typeof PluginDesignRotateArgs>
233
225
 
@@ -1,8 +1,9 @@
1
1
  import * as z from "zod"
2
2
  import { PluginApiReturn } from "../../../types"
3
- import { ComponentHandle } from "../../../handles"
3
+ import { ComponentHandle, MaterialHandle } from "../../../handles"
4
4
  import { PluginDesignChangeResult } from "../lock"
5
5
  import { PluginObjectCatalogGroup, PluginObjectCatalogItem } from "../doors"
6
+ import { PluginMaterialSpec } from "../materials"
6
7
 
7
8
  /**
8
9
  * `snaptrude.design.windows` — window-specific reads. Creation lives at
@@ -22,6 +23,33 @@ import { PluginObjectCatalogGroup, PluginObjectCatalogItem } from "../doors"
22
23
  export abstract class PluginDesignWindowsApi {
23
24
  constructor() {}
24
25
 
26
+ /**
27
+ * Paint only the window's authored glazing, preserving its frame. Families change
28
+ * with linked copies; legacy catalogue types change every instance of that type.
29
+ * Undoable; refuses locked linked/type members or out-of-proposal targets.
30
+ * @param window Window whose glazing to paint
31
+ * @param material Handle or spec; preserve the exact listPresets name for PBR glass
32
+ * @returns Components affected, including linked/type instances
33
+ * @examplePrompt Use clear glass for this window without changing its frame
34
+ */
35
+ public abstract setGlazing(
36
+ window: ComponentHandle,
37
+ material: MaterialHandle | PluginMaterialSpec,
38
+ ): PluginApiReturn<PluginDesignChangeResult>
39
+
40
+ /**
41
+ * Paint only non-glazing slots (frames, sashes, hardware), never the clear panes.
42
+ * Scope, locking and undo match setGlazing and design.materials.applyToSlot.
43
+ * @param window Window whose frame to paint
44
+ * @param material Handle or spec, e.g. `{ name: preset.name }` from listPresets
45
+ * @returns Components affected, including linked/type instances
46
+ * @examplePrompt Use brushed metal for this window's frame without changing the glass
47
+ */
48
+ public abstract setFrame(
49
+ window: ComponentHandle,
50
+ material: MaterialHandle | PluginMaterialSpec,
51
+ ): PluginApiReturn<PluginDesignChangeResult>
52
+
25
53
  /**
26
54
  * Get the type name of a window — the label that identifies which kind of
27
55
  * window the instance is, as shown in its properties.
@@ -310,6 +338,15 @@ export type PluginDesignWindowSetHeightArgs = z.infer<
310
338
  typeof PluginDesignWindowSetHeightArgs
311
339
  >
312
340
 
341
+ /** Arguments for setGlazing / setFrame; both preserve the other authored slot kind. */
342
+ export const PluginDesignWindowSetSlotArgs = z.object({
343
+ window: ComponentHandle,
344
+ material: z.union([MaterialHandle, PluginMaterialSpec]),
345
+ })
346
+ export type PluginDesignWindowSetSlotArgs = z.infer<
347
+ typeof PluginDesignWindowSetSlotArgs
348
+ >
349
+
313
350
  // ---------------------------------------------------------------------------
314
351
  // catalog (shared DTOs defined in ../doors, re-exported here for symmetry)
315
352
  // ---------------------------------------------------------------------------
@@ -6,7 +6,6 @@ import * as z from "zod"
6
6
  import {
7
7
  ProfileHandle,
8
8
  Vec3Handle,
9
- Vec3Input,
10
9
  Vec3Components,
11
10
  QuatComponents,
12
11
  CurveHandle,
@@ -22,7 +21,7 @@ import {
22
21
  * | `dimensions` | `{ width, height, depth }` | Box dimensions in Babylon units |
23
22
  */
24
23
  export const PluginSpaceCreateRectangularArgs = z.object({
25
- position: Vec3Input,
24
+ position: Vec3Handle,
26
25
  dimensions: z.object({
27
26
  width: z.number(),
28
27
  height: z.number(),
@@ -63,7 +62,7 @@ export const PluginSpaceCreateFromProfileArgs = z.object({
63
62
  profile: ProfileHandle,
64
63
  innerProfiles: z.array(ProfileHandle).optional(),
65
64
  extrudeHeight: z.number(),
66
- position: Vec3Input,
65
+ position: Vec3Handle,
67
66
  })
68
67
 
69
68
  export type PluginSpaceCreateFromProfileArgs = z.infer<
@@ -467,7 +466,7 @@ export type PluginSpaceUpdateResult = z.infer<typeof PluginSpaceUpdateResult>
467
466
  export const PluginSpaceBulkCreateItem = z.discriminatedUnion("kind", [
468
467
  z.object({
469
468
  kind: z.literal("rectangular"),
470
- position: Vec3Input,
469
+ position: Vec3Handle,
471
470
  dimensions: z.object({
472
471
  width: z.number(),
473
472
  height: z.number(),
@@ -483,7 +482,7 @@ export const PluginSpaceBulkCreateItem = z.discriminatedUnion("kind", [
483
482
  profile: ProfileHandle,
484
483
  innerProfiles: z.array(ProfileHandle).optional(),
485
484
  extrudeHeight: z.number(),
486
- position: Vec3Input,
485
+ position: Vec3Handle,
487
486
  room_type: z.string().optional(),
488
487
  spaceType: PluginSpaceType.optional(),
489
488
  massType: PluginMassType.optional(),
package/src/handles.ts CHANGED
@@ -288,17 +288,6 @@ export const EdgeHandle = handleSchema("edge")
288
288
  export const HalfEdgeHandle = handleSchema("halfedge")
289
289
  export const VertexHandle = handleSchema("vertex")
290
290
  export const Vec3Components = z.object({ x: z.number(), y: z.number(), z: z.number() })
291
- /**
292
- * A vec3 ARGUMENT: a {@linkcode Vec3Handle} in any inbound form, or a plain finite
293
- * `{ x, y, z }` point. Geometry reads return plain points, and callers pass them straight
294
- * back where a vec3 is expected; the host resolves the point as a vector. Returns stay
295
- * {@linkcode Vec3Handle}. Explicitly typed to keep handles.d.ts inside its size budget.
296
- */
297
- export type Vec3Input = Handle<"vec3"> | Vec3Components
298
- export const Vec3Input: z.ZodUnion<readonly [typeof Vec3Handle, typeof Vec3Components]> = z.union(
299
- [Vec3Handle, Vec3Components],
300
- { error: 'expected a "vec3" handle or a plain { x, y, z } point' }
301
- )
302
291
  export const QuatComponents = z.object({
303
292
  x: z.number(),
304
293
  y: z.number(),