@pascal-app/core 0.8.0 → 0.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/events/bus.d.ts +67 -13
- package/dist/events/bus.d.ts.map +1 -1
- package/dist/hooks/scene-registry/item-clip-registry.d.ts +18 -0
- package/dist/hooks/scene-registry/item-clip-registry.d.ts.map +1 -0
- package/dist/hooks/scene-registry/item-clip-registry.js +10 -0
- package/dist/hooks/scene-registry/scene-registry.d.ts +14 -23
- package/dist/hooks/scene-registry/scene-registry.d.ts.map +1 -1
- package/dist/hooks/scene-registry/scene-registry.js +59 -26
- package/dist/hooks/scene-registry/scene-registry.test.d.ts +2 -0
- package/dist/hooks/scene-registry/scene-registry.test.d.ts.map +1 -0
- package/dist/hooks/scene-registry/scene-registry.test.js +26 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.d.ts +14 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.d.ts.map +1 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.js +51 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.test.d.ts +2 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.test.d.ts.map +1 -0
- package/dist/hooks/spatial-grid/floor-placed-elevation.test.js +366 -0
- package/dist/hooks/spatial-grid/spatial-grid-manager.d.ts +79 -11
- package/dist/hooks/spatial-grid/spatial-grid-manager.d.ts.map +1 -1
- package/dist/hooks/spatial-grid/spatial-grid-manager.js +508 -141
- package/dist/hooks/spatial-grid/spatial-grid-sync.d.ts +28 -1
- package/dist/hooks/spatial-grid/spatial-grid-sync.d.ts.map +1 -1
- package/dist/hooks/spatial-grid/spatial-grid-sync.js +109 -18
- package/dist/hooks/spatial-grid/wall-slab-overlap.test.d.ts +2 -0
- package/dist/hooks/spatial-grid/wall-slab-overlap.test.d.ts.map +1 -0
- package/dist/hooks/spatial-grid/wall-slab-overlap.test.js +363 -0
- package/dist/index.d.ts +36 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +33 -6
- package/dist/lib/level-name.d.ts +4 -0
- package/dist/lib/level-name.d.ts.map +1 -0
- package/dist/lib/level-name.js +10 -0
- package/dist/lib/measurement-geometry.d.ts +19 -0
- package/dist/lib/measurement-geometry.d.ts.map +1 -0
- package/dist/lib/measurement-geometry.js +232 -0
- package/dist/lib/measurement-geometry.test.d.ts +2 -0
- package/dist/lib/measurement-geometry.test.d.ts.map +1 -0
- package/dist/lib/measurement-geometry.test.js +102 -0
- package/dist/lib/polygon-geometry.d.ts +0 -1
- package/dist/lib/polygon-geometry.d.ts.map +1 -1
- package/dist/lib/polygon-geometry.js +0 -18
- package/dist/lib/polygon-relations.d.ts +10 -0
- package/dist/lib/polygon-relations.d.ts.map +1 -0
- package/dist/lib/polygon-relations.js +73 -0
- package/dist/lib/selection-proxy.d.ts +4 -0
- package/dist/lib/selection-proxy.d.ts.map +1 -0
- package/dist/lib/selection-proxy.js +12 -0
- package/dist/lib/slab-polygon.d.ts +31 -2
- package/dist/lib/slab-polygon.d.ts.map +1 -1
- package/dist/lib/slab-polygon.js +525 -31
- package/dist/lib/slab-polygon.test.d.ts +2 -0
- package/dist/lib/slab-polygon.test.d.ts.map +1 -0
- package/dist/lib/slab-polygon.test.js +635 -0
- package/dist/lib/slots.d.ts +14 -0
- package/dist/lib/slots.d.ts.map +1 -0
- package/dist/lib/slots.js +26 -0
- package/dist/lib/space-detection-pause.test.d.ts +2 -0
- package/dist/lib/space-detection-pause.test.d.ts.map +1 -0
- package/dist/lib/space-detection-pause.test.js +42 -0
- package/dist/lib/space-detection.d.ts +54 -2
- package/dist/lib/space-detection.d.ts.map +1 -1
- package/dist/lib/space-detection.js +599 -124
- package/dist/lib/space-detection.test.d.ts +2 -0
- package/dist/lib/space-detection.test.d.ts.map +1 -0
- package/dist/lib/space-detection.test.js +376 -0
- package/dist/lib/wall-distance.d.ts +60 -0
- package/dist/lib/wall-distance.d.ts.map +1 -0
- package/dist/lib/wall-distance.js +85 -0
- package/dist/lib/zone-quantities.d.ts +21 -0
- package/dist/lib/zone-quantities.d.ts.map +1 -0
- package/dist/lib/zone-quantities.js +183 -0
- package/dist/lib/zone-quantities.test.d.ts +2 -0
- package/dist/lib/zone-quantities.test.d.ts.map +1 -0
- package/dist/lib/zone-quantities.test.js +82 -0
- package/dist/material-library.d.ts +20 -1
- package/dist/material-library.d.ts.map +1 -1
- package/dist/material-library.js +3737 -200
- package/dist/registry/__bench__/relations-resolver.bench.d.ts +15 -0
- package/dist/registry/__bench__/relations-resolver.bench.d.ts.map +1 -0
- package/dist/registry/__bench__/relations-resolver.bench.js +170 -0
- package/dist/registry/handles.d.ts +394 -0
- package/dist/registry/handles.d.ts.map +1 -0
- package/dist/registry/handles.js +24 -0
- package/dist/registry/index.d.ts +7 -0
- package/dist/registry/index.d.ts.map +1 -0
- package/dist/registry/index.js +4 -0
- package/dist/registry/registry.d.ts +136 -0
- package/dist/registry/registry.d.ts.map +1 -0
- package/dist/registry/registry.js +282 -0
- package/dist/registry/registry.test.d.ts +2 -0
- package/dist/registry/registry.test.d.ts.map +1 -0
- package/dist/registry/registry.test.js +196 -0
- package/dist/registry/relations-resolver.d.ts +42 -0
- package/dist/registry/relations-resolver.d.ts.map +1 -0
- package/dist/registry/relations-resolver.js +77 -0
- package/dist/registry/relations-resolver.test.d.ts +2 -0
- package/dist/registry/relations-resolver.test.d.ts.map +1 -0
- package/dist/registry/relations-resolver.test.js +183 -0
- package/dist/registry/scene-api.d.ts +44 -0
- package/dist/registry/scene-api.d.ts.map +1 -0
- package/dist/registry/scene-api.js +111 -0
- package/dist/registry/scene-api.test.d.ts +2 -0
- package/dist/registry/scene-api.test.d.ts.map +1 -0
- package/dist/registry/scene-api.test.js +183 -0
- package/dist/registry/subtree.d.ts +67 -0
- package/dist/registry/subtree.d.ts.map +1 -0
- package/dist/registry/subtree.js +123 -0
- package/dist/registry/subtree.test.d.ts +2 -0
- package/dist/registry/subtree.test.d.ts.map +1 -0
- package/dist/registry/subtree.test.js +163 -0
- package/dist/registry/types.d.ts +2099 -0
- package/dist/registry/types.d.ts.map +1 -0
- package/dist/registry/types.js +1 -0
- package/dist/schema/index.d.ts +35 -4
- package/dist/schema/index.d.ts.map +1 -1
- package/dist/schema/index.js +32 -4
- package/dist/schema/material.d.ts +13 -2
- package/dist/schema/material.d.ts.map +1 -1
- package/dist/schema/material.js +17 -5
- package/dist/schema/material.test.d.ts +2 -0
- package/dist/schema/material.test.d.ts.map +1 -0
- package/dist/schema/material.test.js +43 -0
- package/dist/schema/nodes/box-vent.d.ts +74 -0
- package/dist/schema/nodes/box-vent.d.ts.map +1 -0
- package/dist/schema/nodes/box-vent.js +63 -0
- package/dist/schema/nodes/building.d.ts +1 -1
- package/dist/schema/nodes/building.d.ts.map +1 -1
- package/dist/schema/nodes/building.js +3 -2
- package/dist/schema/nodes/cabinet.d.ts +534 -0
- package/dist/schema/nodes/cabinet.d.ts.map +1 -0
- package/dist/schema/nodes/cabinet.js +137 -0
- package/dist/schema/nodes/ceiling.d.ts +5 -2
- package/dist/schema/nodes/ceiling.d.ts.map +1 -1
- package/dist/schema/nodes/ceiling.js +5 -1
- package/dist/schema/nodes/chimney.d.ts +158 -0
- package/dist/schema/nodes/chimney.d.ts.map +1 -0
- package/dist/schema/nodes/chimney.js +67 -0
- package/dist/schema/nodes/column.d.ts +600 -7
- package/dist/schema/nodes/column.d.ts.map +1 -1
- package/dist/schema/nodes/column.js +589 -6
- package/dist/schema/nodes/cupola.d.ts +66 -0
- package/dist/schema/nodes/cupola.d.ts.map +1 -0
- package/dist/schema/nodes/cupola.js +28 -0
- package/dist/schema/nodes/door.d.ts +13 -5
- package/dist/schema/nodes/door.d.ts.map +1 -1
- package/dist/schema/nodes/door.js +12 -0
- package/dist/schema/nodes/dormer.d.ts +228 -0
- package/dist/schema/nodes/dormer.d.ts.map +1 -0
- package/dist/schema/nodes/dormer.js +119 -0
- package/dist/schema/nodes/downspout.d.ts +75 -0
- package/dist/schema/nodes/downspout.d.ts.map +1 -0
- package/dist/schema/nodes/downspout.js +63 -0
- package/dist/schema/nodes/duct-fitting.d.ts +91 -0
- package/dist/schema/nodes/duct-fitting.d.ts.map +1 -0
- package/dist/schema/nodes/duct-fitting.js +92 -0
- package/dist/schema/nodes/duct-segment.d.ts +61 -0
- package/dist/schema/nodes/duct-segment.d.ts.map +1 -0
- package/dist/schema/nodes/duct-segment.js +73 -0
- package/dist/schema/nodes/duct-terminal.d.ts +57 -0
- package/dist/schema/nodes/duct-terminal.d.ts.map +1 -0
- package/dist/schema/nodes/duct-terminal.js +51 -0
- package/dist/schema/nodes/elevator.d.ts +106 -0
- package/dist/schema/nodes/elevator.d.ts.map +1 -0
- package/dist/schema/nodes/elevator.js +57 -0
- package/dist/schema/nodes/eyebrow-vent.d.ts +68 -0
- package/dist/schema/nodes/eyebrow-vent.d.ts.map +1 -0
- package/dist/schema/nodes/eyebrow-vent.js +40 -0
- package/dist/schema/nodes/fence.d.ts +19 -2
- package/dist/schema/nodes/fence.d.ts.map +1 -1
- package/dist/schema/nodes/fence.js +27 -2
- package/dist/schema/nodes/gutter.d.ts +84 -0
- package/dist/schema/nodes/gutter.d.ts.map +1 -0
- package/dist/schema/nodes/gutter.js +76 -0
- package/dist/schema/nodes/hvac-equipment.d.ts +63 -0
- package/dist/schema/nodes/hvac-equipment.d.ts.map +1 -0
- package/dist/schema/nodes/hvac-equipment.js +55 -0
- package/dist/schema/nodes/item.d.ts +12 -0
- package/dist/schema/nodes/item.d.ts.map +1 -1
- package/dist/schema/nodes/item.js +20 -0
- package/dist/schema/nodes/level.d.ts +1 -1
- package/dist/schema/nodes/level.d.ts.map +1 -1
- package/dist/schema/nodes/level.js +4 -0
- package/dist/schema/nodes/lineset.d.ts +42 -0
- package/dist/schema/nodes/lineset.d.ts.map +1 -0
- package/dist/schema/nodes/lineset.js +38 -0
- package/dist/schema/nodes/liquid-line.d.ts +34 -0
- package/dist/schema/nodes/liquid-line.d.ts.map +1 -0
- package/dist/schema/nodes/liquid-line.js +24 -0
- package/dist/schema/nodes/measurement.d.ts +306 -0
- package/dist/schema/nodes/measurement.d.ts.map +1 -0
- package/dist/schema/nodes/measurement.js +87 -0
- package/dist/schema/nodes/measurement.test.d.ts +2 -0
- package/dist/schema/nodes/measurement.test.d.ts.map +1 -0
- package/dist/schema/nodes/measurement.test.js +139 -0
- package/dist/schema/nodes/pipe-fitting.d.ts +56 -0
- package/dist/schema/nodes/pipe-fitting.d.ts.map +1 -0
- package/dist/schema/nodes/pipe-fitting.js +45 -0
- package/dist/schema/nodes/pipe-segment.d.ts +48 -0
- package/dist/schema/nodes/pipe-segment.d.ts.map +1 -0
- package/dist/schema/nodes/pipe-segment.js +36 -0
- package/dist/schema/nodes/pipe-trap.d.ts +43 -0
- package/dist/schema/nodes/pipe-trap.d.ts.map +1 -0
- package/dist/schema/nodes/pipe-trap.js +36 -0
- package/dist/schema/nodes/ridge-vent-defaults.test.d.ts +2 -0
- package/dist/schema/nodes/ridge-vent-defaults.test.d.ts.map +1 -0
- package/dist/schema/nodes/ridge-vent-defaults.test.js +205 -0
- package/dist/schema/nodes/ridge-vent.d.ts +82 -0
- package/dist/schema/nodes/ridge-vent.d.ts.map +1 -0
- package/dist/schema/nodes/ridge-vent.js +248 -0
- package/dist/schema/nodes/roof-segment-shape.d.ts +90 -0
- package/dist/schema/nodes/roof-segment-shape.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-shape.js +318 -0
- package/dist/schema/nodes/roof-segment-shape.test.d.ts +2 -0
- package/dist/schema/nodes/roof-segment-shape.test.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-shape.test.js +175 -0
- package/dist/schema/nodes/roof-segment-surface.test.d.ts +2 -0
- package/dist/schema/nodes/roof-segment-surface.test.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-surface.test.js +48 -0
- package/dist/schema/nodes/roof-segment-trim.test.d.ts +2 -0
- package/dist/schema/nodes/roof-segment-trim.test.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-trim.test.js +107 -0
- package/dist/schema/nodes/roof-segment-walls.d.ts +101 -0
- package/dist/schema/nodes/roof-segment-walls.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-walls.js +330 -0
- package/dist/schema/nodes/roof-segment-walls.test.d.ts +2 -0
- package/dist/schema/nodes/roof-segment-walls.test.d.ts.map +1 -0
- package/dist/schema/nodes/roof-segment-walls.test.js +92 -0
- package/dist/schema/nodes/roof-segment.d.ts +273 -3
- package/dist/schema/nodes/roof-segment.d.ts.map +1 -1
- package/dist/schema/nodes/roof-segment.js +539 -3
- package/dist/schema/nodes/roof.d.ts +8 -8
- package/dist/schema/nodes/roof.d.ts.map +1 -1
- package/dist/schema/nodes/roof.js +4 -16
- package/dist/schema/nodes/shelf.d.ts +106 -0
- package/dist/schema/nodes/shelf.d.ts.map +1 -0
- package/dist/schema/nodes/shelf.js +90 -0
- package/dist/schema/nodes/site.d.ts +1 -122
- package/dist/schema/nodes/site.d.ts.map +1 -1
- package/dist/schema/nodes/site.js +2 -6
- package/dist/schema/nodes/skylight.d.ts +279 -0
- package/dist/schema/nodes/skylight.d.ts.map +1 -0
- package/dist/schema/nodes/skylight.js +152 -0
- package/dist/schema/nodes/slab.d.ts +5 -2
- package/dist/schema/nodes/slab.d.ts.map +1 -1
- package/dist/schema/nodes/slab.js +5 -1
- package/dist/schema/nodes/solar-panel.d.ts +117 -0
- package/dist/schema/nodes/solar-panel.d.ts.map +1 -0
- package/dist/schema/nodes/solar-panel.js +47 -0
- package/dist/schema/nodes/stair-segment.d.ts +4 -4
- package/dist/schema/nodes/stair.d.ts +13 -12
- package/dist/schema/nodes/stair.d.ts.map +1 -1
- package/dist/schema/nodes/stair.js +3 -0
- package/dist/schema/nodes/surface-hole-metadata.d.ts +2 -0
- package/dist/schema/nodes/surface-hole-metadata.d.ts.map +1 -1
- package/dist/schema/nodes/surface-hole-metadata.js +3 -1
- package/dist/schema/nodes/turbine-vent.d.ts +68 -0
- package/dist/schema/nodes/turbine-vent.d.ts.map +1 -0
- package/dist/schema/nodes/turbine-vent.js +41 -0
- package/dist/schema/nodes/wall.d.ts +245 -6
- package/dist/schema/nodes/wall.d.ts.map +1 -1
- package/dist/schema/nodes/wall.js +257 -0
- package/dist/schema/nodes/wall.test.d.ts +2 -0
- package/dist/schema/nodes/wall.test.d.ts.map +1 -0
- package/dist/schema/nodes/wall.test.js +208 -0
- package/dist/schema/nodes/window.d.ts +11 -3
- package/dist/schema/nodes/window.d.ts.map +1 -1
- package/dist/schema/nodes/window.js +12 -0
- package/dist/schema/nodes/zone.d.ts +2 -0
- package/dist/schema/nodes/zone.d.ts.map +1 -1
- package/dist/schema/nodes/zone.js +6 -0
- package/dist/schema/scene-material.d.ts +41 -0
- package/dist/schema/scene-material.d.ts.map +1 -0
- package/dist/schema/scene-material.js +9 -0
- package/dist/schema/types.d.ts +2850 -655
- package/dist/schema/types.d.ts.map +1 -1
- package/dist/schema/types.js +49 -0
- package/dist/services/alignment-anchors.d.ts +100 -0
- package/dist/services/alignment-anchors.d.ts.map +1 -0
- package/dist/services/alignment-anchors.js +312 -0
- package/dist/services/alignment-anchors.test.d.ts +2 -0
- package/dist/services/alignment-anchors.test.d.ts.map +1 -0
- package/dist/services/alignment-anchors.test.js +383 -0
- package/dist/services/alignment.d.ts +131 -0
- package/dist/services/alignment.d.ts.map +1 -0
- package/dist/services/alignment.js +171 -0
- package/dist/services/alignment.test.d.ts +2 -0
- package/dist/services/alignment.test.d.ts.map +1 -0
- package/dist/services/alignment.test.js +92 -0
- package/dist/services/drag-session.d.ts +47 -0
- package/dist/services/drag-session.d.ts.map +1 -0
- package/dist/services/drag-session.js +100 -0
- package/dist/services/drag-session.test.d.ts +2 -0
- package/dist/services/drag-session.test.d.ts.map +1 -0
- package/dist/services/drag-session.test.js +219 -0
- package/dist/services/hosting.d.ts +88 -0
- package/dist/services/hosting.d.ts.map +1 -0
- package/dist/services/hosting.js +131 -0
- package/dist/services/hosting.test.d.ts +2 -0
- package/dist/services/hosting.test.d.ts.map +1 -0
- package/dist/services/hosting.test.js +230 -0
- package/dist/services/index.d.ts +13 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/services/index.js +12 -0
- package/dist/services/level-height.d.ts +28 -0
- package/dist/services/level-height.d.ts.map +1 -0
- package/dist/services/level-height.js +62 -0
- package/dist/services/movement.d.ts +48 -0
- package/dist/services/movement.d.ts.map +1 -0
- package/dist/services/movement.js +65 -0
- package/dist/services/movement.test.d.ts +2 -0
- package/dist/services/movement.test.d.ts.map +1 -0
- package/dist/services/movement.test.js +133 -0
- package/dist/services/opening-guides.d.ts +141 -0
- package/dist/services/opening-guides.d.ts.map +1 -0
- package/dist/services/opening-guides.js +267 -0
- package/dist/services/opening-guides.test.d.ts +2 -0
- package/dist/services/opening-guides.test.d.ts.map +1 -0
- package/dist/services/opening-guides.test.js +208 -0
- package/dist/services/port-connectivity.d.ts +115 -0
- package/dist/services/port-connectivity.d.ts.map +1 -0
- package/dist/services/port-connectivity.js +300 -0
- package/dist/services/port-connectivity.test.d.ts +2 -0
- package/dist/services/port-connectivity.test.d.ts.map +1 -0
- package/dist/services/port-connectivity.test.js +297 -0
- package/dist/services/riser-diagram.d.ts +40 -0
- package/dist/services/riser-diagram.d.ts.map +1 -0
- package/dist/services/riser-diagram.js +110 -0
- package/dist/services/riser-diagram.test.d.ts +2 -0
- package/dist/services/riser-diagram.test.d.ts.map +1 -0
- package/dist/services/riser-diagram.test.js +66 -0
- package/dist/services/single-undo-dance.test.d.ts +2 -0
- package/dist/services/single-undo-dance.test.d.ts.map +1 -0
- package/dist/services/single-undo-dance.test.js +210 -0
- package/dist/services/snap.d.ts +80 -0
- package/dist/services/snap.d.ts.map +1 -0
- package/dist/services/snap.js +140 -0
- package/dist/services/snap.test.d.ts +2 -0
- package/dist/services/snap.test.d.ts.map +1 -0
- package/dist/services/snap.test.js +137 -0
- package/dist/services/system-graph.d.ts +30 -0
- package/dist/services/system-graph.d.ts.map +1 -0
- package/dist/services/system-graph.js +164 -0
- package/dist/services/system-graph.test.d.ts +2 -0
- package/dist/services/system-graph.test.d.ts.map +1 -0
- package/dist/services/system-graph.test.js +138 -0
- package/dist/services/validate-dwv.d.ts +32 -0
- package/dist/services/validate-dwv.d.ts.map +1 -0
- package/dist/services/validate-dwv.js +118 -0
- package/dist/services/validate-dwv.test.d.ts +2 -0
- package/dist/services/validate-dwv.test.d.ts.map +1 -0
- package/dist/services/validate-dwv.test.js +109 -0
- package/dist/solar-panel-presets.d.ts +17 -0
- package/dist/solar-panel-presets.d.ts.map +1 -0
- package/dist/solar-panel-presets.js +43 -0
- package/dist/store/actions/node-actions.d.ts +14 -2
- package/dist/store/actions/node-actions.d.ts.map +1 -1
- package/dist/store/actions/node-actions.js +585 -15
- package/dist/store/actions/node-mutation-sanitize.test.d.ts +2 -0
- package/dist/store/actions/node-mutation-sanitize.test.d.ts.map +1 -0
- package/dist/store/actions/node-mutation-sanitize.test.js +147 -0
- package/dist/store/actions/reparent.test.d.ts +2 -0
- package/dist/store/actions/reparent.test.d.ts.map +1 -0
- package/dist/store/actions/reparent.test.js +212 -0
- package/dist/store/actions/ridge-vent-update.test.d.ts +2 -0
- package/dist/store/actions/ridge-vent-update.test.d.ts.map +1 -0
- package/dist/store/actions/ridge-vent-update.test.js +264 -0
- package/dist/store/history-control.d.ts +11 -0
- package/dist/store/history-control.d.ts.map +1 -1
- package/dist/store/history-control.js +33 -0
- package/dist/store/use-interactive.d.ts +39 -0
- package/dist/store/use-interactive.d.ts.map +1 -1
- package/dist/store/use-interactive.js +75 -0
- package/dist/store/use-live-node-overrides.d.ts +22 -0
- package/dist/store/use-live-node-overrides.d.ts.map +1 -0
- package/dist/store/use-live-node-overrides.js +59 -0
- package/dist/store/use-scene-dirty-tracking.test.d.ts +2 -0
- package/dist/store/use-scene-dirty-tracking.test.d.ts.map +1 -0
- package/dist/store/use-scene-dirty-tracking.test.js +68 -0
- package/dist/store/use-scene-elevator-migration.test.d.ts +2 -0
- package/dist/store/use-scene-elevator-migration.test.d.ts.map +1 -0
- package/dist/store/use-scene-elevator-migration.test.js +109 -0
- package/dist/store/use-scene-measurement-roundtrip.test.d.ts +2 -0
- package/dist/store/use-scene-measurement-roundtrip.test.d.ts.map +1 -0
- package/dist/store/use-scene-measurement-roundtrip.test.js +97 -0
- package/dist/store/use-scene-plugins.test.d.ts +2 -0
- package/dist/store/use-scene-plugins.test.d.ts.map +1 -0
- package/dist/store/use-scene-plugins.test.js +51 -0
- package/dist/store/use-scene-wall-slot-migration.test.d.ts +2 -0
- package/dist/store/use-scene-wall-slot-migration.test.d.ts.map +1 -0
- package/dist/store/use-scene-wall-slot-migration.test.js +210 -0
- package/dist/store/use-scene-window-migration.test.d.ts +2 -0
- package/dist/store/use-scene-window-migration.test.d.ts.map +1 -0
- package/dist/store/use-scene-window-migration.test.js +85 -0
- package/dist/store/use-scene.d.ts +28 -2
- package/dist/store/use-scene.d.ts.map +1 -1
- package/dist/store/use-scene.js +546 -49
- package/dist/systems/elevator/elevator-dispatch.d.ts +12 -0
- package/dist/systems/elevator/elevator-dispatch.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-dispatch.js +57 -0
- package/dist/systems/elevator/elevator-geometry.d.ts +15 -0
- package/dist/systems/elevator/elevator-geometry.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-geometry.js +50 -0
- package/dist/systems/elevator/elevator-opening-sync.d.ts +6 -0
- package/dist/systems/elevator/elevator-opening-sync.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-opening-sync.js +218 -0
- package/dist/systems/elevator/elevator-opening-sync.test.d.ts +2 -0
- package/dist/systems/elevator/elevator-opening-sync.test.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-opening-sync.test.js +146 -0
- package/dist/systems/elevator/elevator-opening-system.d.ts +2 -0
- package/dist/systems/elevator/elevator-opening-system.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-opening-system.js +48 -0
- package/dist/systems/elevator/elevator-runtime-system.d.ts +2 -0
- package/dist/systems/elevator/elevator-runtime-system.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-runtime-system.js +8 -0
- package/dist/systems/elevator/elevator-runtime.d.ts +18 -0
- package/dist/systems/elevator/elevator-runtime.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-runtime.js +225 -0
- package/dist/systems/elevator/elevator-runtime.test.d.ts +2 -0
- package/dist/systems/elevator/elevator-runtime.test.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-runtime.test.js +64 -0
- package/dist/systems/elevator/elevator-service.d.ts +19 -0
- package/dist/systems/elevator/elevator-service.d.ts.map +1 -0
- package/dist/systems/elevator/elevator-service.js +111 -0
- package/dist/systems/fence/fence-centerline.d.ts +12 -0
- package/dist/systems/fence/fence-centerline.d.ts.map +1 -0
- package/dist/systems/fence/fence-centerline.js +37 -0
- package/dist/systems/fence/fence-spline.d.ts +39 -0
- package/dist/systems/fence/fence-spline.d.ts.map +1 -0
- package/dist/systems/fence/fence-spline.js +196 -0
- package/dist/systems/fence/fence-spline.test.d.ts +2 -0
- package/dist/systems/fence/fence-spline.test.d.ts.map +1 -0
- package/dist/systems/fence/fence-spline.test.js +136 -0
- package/dist/systems/stair/stair-footprint.d.ts +44 -0
- package/dist/systems/stair/stair-footprint.d.ts.map +1 -0
- package/dist/systems/stair/stair-footprint.js +178 -0
- package/dist/systems/stair/stair-opening-preview.d.ts +2447 -0
- package/dist/systems/stair/stair-opening-preview.d.ts.map +1 -0
- package/dist/systems/stair/stair-opening-preview.js +93 -0
- package/dist/systems/stair/stair-opening-preview.test.d.ts +2 -0
- package/dist/systems/stair/stair-opening-preview.test.d.ts.map +1 -0
- package/dist/systems/stair/stair-opening-preview.test.js +80 -0
- package/dist/systems/stair/stair-opening-sync.d.ts.map +1 -1
- package/dist/systems/stair/stair-opening-sync.js +155 -147
- package/dist/systems/stair/stair-opening-sync.test.js +424 -2
- package/dist/systems/stair/stair-opening-system.d.ts +2 -0
- package/dist/systems/stair/stair-opening-system.d.ts.map +1 -0
- package/dist/systems/stair/stair-opening-system.js +104 -0
- package/dist/systems/wall/wall-mitering.d.ts.map +1 -1
- package/dist/systems/wall/wall-mitering.js +38 -2
- package/dist/systems/wall/wall-mitering.test.d.ts +2 -0
- package/dist/systems/wall/wall-mitering.test.d.ts.map +1 -0
- package/dist/systems/wall/wall-mitering.test.js +63 -0
- package/dist/systems/wall/wall-move.d.ts +48 -0
- package/dist/systems/wall/wall-move.d.ts.map +1 -0
- package/dist/systems/wall/wall-move.js +193 -0
- package/dist/utils/clone-scene-graph.d.ts +7 -4
- package/dist/utils/clone-scene-graph.d.ts.map +1 -1
- package/dist/utils/clone-scene-graph.js +29 -7
- package/dist/utils/clone-scene-graph.test.d.ts +2 -0
- package/dist/utils/clone-scene-graph.test.d.ts.map +1 -0
- package/dist/utils/clone-scene-graph.test.js +62 -0
- package/dist/utils/heal-scene-graph.d.ts +18 -0
- package/dist/utils/heal-scene-graph.d.ts.map +1 -0
- package/dist/utils/heal-scene-graph.js +90 -0
- package/dist/utils/heal-scene-graph.test.d.ts +2 -0
- package/dist/utils/heal-scene-graph.test.d.ts.map +1 -0
- package/dist/utils/heal-scene-graph.test.js +88 -0
- package/dist/validation/validate-build-json.d.ts +44 -0
- package/dist/validation/validate-build-json.d.ts.map +1 -0
- package/dist/validation/validate-build-json.js +256 -0
- package/package.json +11 -4
|
@@ -1,4 +1,31 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { AnyNode, AnyNodeId } from '../../schema';
|
|
2
2
|
export declare function resolveLevelId(node: AnyNode, nodes: Record<string, AnyNode>): string;
|
|
3
|
+
/**
|
|
4
|
+
* Walks the parent chain of `nodeId` and returns the id of the first ancestor
|
|
5
|
+
* whose `type` is `'level'`, or `null` when no level ancestor exists (orphaned
|
|
6
|
+
* node, top-level building node, etc.). Unlike `resolveLevelId`, this variant:
|
|
7
|
+
*
|
|
8
|
+
* - accepts a node **id** rather than a resolved node, saving the caller a
|
|
9
|
+
* `nodes[id]` lookup when only the id is at hand.
|
|
10
|
+
* - returns `null` instead of the `'default'` fallback, which lets callers
|
|
11
|
+
* distinguish "genuinely has no level" from "is a level".
|
|
12
|
+
* - has a loop guard (16 iterations) so a corrupt parent-chain cycle cannot
|
|
13
|
+
* hang the frame loop.
|
|
14
|
+
*/
|
|
15
|
+
export declare function findLevelAncestorId(nodeId: AnyNodeId, nodes: Record<string, AnyNode>): string | null;
|
|
16
|
+
/**
|
|
17
|
+
* Returns the building id that contains the given level, or `null` if
|
|
18
|
+
* the level is unparented or no enclosing building exists.
|
|
19
|
+
*
|
|
20
|
+
* Most scenes record the relationship via `level.parentId →
|
|
21
|
+
* building.id`, but older serialisations occasionally drop `parentId`
|
|
22
|
+
* even though the building's `children` array still references the
|
|
23
|
+
* level. The fallback scan covers that case.
|
|
24
|
+
*
|
|
25
|
+
* Used by `FloorplanRegistryLayer` to discover building-scoped kinds
|
|
26
|
+
* (`def.floorplanScope === 'building'`) without hardcoding any kind
|
|
27
|
+
* name in the editor layer.
|
|
28
|
+
*/
|
|
29
|
+
export declare function resolveBuildingForLevel(levelId: AnyNodeId, nodes: Record<AnyNodeId, AnyNode>): AnyNodeId | null;
|
|
3
30
|
export declare function initSpatialGridSync(): () => void;
|
|
4
31
|
//# sourceMappingURL=spatial-grid-sync.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spatial-grid-sync.d.ts","sourceRoot":"","sources":["../../../src/hooks/spatial-grid/spatial-grid-sync.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"spatial-grid-sync.d.ts","sourceRoot":"","sources":["../../../src/hooks/spatial-grid/spatial-grid-sync.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,SAAS,EAAsB,MAAM,cAAc,CAAA;AAS1E,wBAAgB,cAAc,CAAC,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,MAAM,CAmBpF;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,SAAS,EACjB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC7B,MAAM,GAAG,IAAI,CASf;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,SAAS,EAClB,KAAK,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,GAChC,SAAS,GAAG,IAAI,CAgBlB;AAKD,wBAAgB,mBAAmB,IAAI,MAAM,IAAI,CAgFhD"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { getRenderableSlabPolygon } from '../../lib/slab-polygon';
|
|
2
|
+
import { nodeRegistry } from '../../registry';
|
|
2
3
|
import useScene from '../../store/use-scene';
|
|
4
|
+
import { getFloorPlacedFootprints } from './floor-placed-elevation';
|
|
3
5
|
import { itemOverlapsPolygon, spatialGridManager, wallOverlapsPolygon, } from './spatial-grid-manager';
|
|
4
6
|
export function resolveLevelId(node, nodes) {
|
|
5
7
|
// If the node itself is a level
|
|
@@ -21,6 +23,62 @@ export function resolveLevelId(node, nodes) {
|
|
|
21
23
|
}
|
|
22
24
|
return 'default'; // fallback for orphaned items
|
|
23
25
|
}
|
|
26
|
+
/**
|
|
27
|
+
* Walks the parent chain of `nodeId` and returns the id of the first ancestor
|
|
28
|
+
* whose `type` is `'level'`, or `null` when no level ancestor exists (orphaned
|
|
29
|
+
* node, top-level building node, etc.). Unlike `resolveLevelId`, this variant:
|
|
30
|
+
*
|
|
31
|
+
* - accepts a node **id** rather than a resolved node, saving the caller a
|
|
32
|
+
* `nodes[id]` lookup when only the id is at hand.
|
|
33
|
+
* - returns `null` instead of the `'default'` fallback, which lets callers
|
|
34
|
+
* distinguish "genuinely has no level" from "is a level".
|
|
35
|
+
* - has a loop guard (16 iterations) so a corrupt parent-chain cycle cannot
|
|
36
|
+
* hang the frame loop.
|
|
37
|
+
*/
|
|
38
|
+
export function findLevelAncestorId(nodeId, nodes) {
|
|
39
|
+
let current = nodes[nodeId];
|
|
40
|
+
let guard = 0;
|
|
41
|
+
while (current && guard < 16) {
|
|
42
|
+
if (current.type === 'level')
|
|
43
|
+
return current.id;
|
|
44
|
+
current = current.parentId ? nodes[current.parentId] : undefined;
|
|
45
|
+
guard += 1;
|
|
46
|
+
}
|
|
47
|
+
return null;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Returns the building id that contains the given level, or `null` if
|
|
51
|
+
* the level is unparented or no enclosing building exists.
|
|
52
|
+
*
|
|
53
|
+
* Most scenes record the relationship via `level.parentId →
|
|
54
|
+
* building.id`, but older serialisations occasionally drop `parentId`
|
|
55
|
+
* even though the building's `children` array still references the
|
|
56
|
+
* level. The fallback scan covers that case.
|
|
57
|
+
*
|
|
58
|
+
* Used by `FloorplanRegistryLayer` to discover building-scoped kinds
|
|
59
|
+
* (`def.floorplanScope === 'building'`) without hardcoding any kind
|
|
60
|
+
* name in the editor layer.
|
|
61
|
+
*/
|
|
62
|
+
export function resolveBuildingForLevel(levelId, nodes) {
|
|
63
|
+
const level = nodes[levelId];
|
|
64
|
+
if (!level)
|
|
65
|
+
return null;
|
|
66
|
+
const directParent = level.parentId ?? null;
|
|
67
|
+
if (directParent) {
|
|
68
|
+
const candidate = nodes[directParent];
|
|
69
|
+
if (candidate?.type === 'building')
|
|
70
|
+
return candidate.id;
|
|
71
|
+
}
|
|
72
|
+
for (const candidate of Object.values(nodes)) {
|
|
73
|
+
if (candidate?.type !== 'building')
|
|
74
|
+
continue;
|
|
75
|
+
const children = candidate.children;
|
|
76
|
+
if (Array.isArray(children) && children.includes(levelId)) {
|
|
77
|
+
return candidate.id;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return null;
|
|
81
|
+
}
|
|
24
82
|
// Call this once at app initialization. Returns an unsubscribe function that
|
|
25
83
|
// detaches the scene-store listener (useful when the editor is unmounted so
|
|
26
84
|
// the spatial grid singleton does not hold stale references to old scenes).
|
|
@@ -96,36 +154,69 @@ function arraysEqual(a, b) {
|
|
|
96
154
|
return a.length === b.length && a.every((v, i) => v === b[i]);
|
|
97
155
|
}
|
|
98
156
|
/**
|
|
99
|
-
* Mark all floor items
|
|
157
|
+
* Mark all floor items and walls that may be affected by a slab change as dirty.
|
|
100
158
|
*/
|
|
101
159
|
function markNodesOverlappingSlab(slab, nodes, markDirty) {
|
|
102
160
|
if (slab.polygon.length < 3)
|
|
103
161
|
return;
|
|
104
162
|
const slabLevelId = resolveLevelId(slab, nodes);
|
|
163
|
+
// Walls follow the slab's RENDERED footprint (band-adopted edges reach
|
|
164
|
+
// the wall's outer face), so the dirty gate must test the same polygon
|
|
165
|
+
// `getSlabElevationForWall` will re-evaluate — a stored polygon that
|
|
166
|
+
// stops short of the wall body would otherwise never re-elevate it.
|
|
167
|
+
const levelWalls = [];
|
|
168
|
+
const siblingSlabs = [];
|
|
105
169
|
for (const node of Object.values(nodes)) {
|
|
106
|
-
if (node.type === '
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
if (itemOverlapsPolygon(item.position, getScaledDimensions(item), item.rotation, slab.polygon, 0.01)) {
|
|
114
|
-
markDirty(node.id);
|
|
115
|
-
}
|
|
170
|
+
if (node.type === 'wall' && resolveLevelId(node, nodes) === slabLevelId) {
|
|
171
|
+
levelWalls.push(node);
|
|
172
|
+
}
|
|
173
|
+
else if (node.type === 'slab' &&
|
|
174
|
+
node.id !== slab.id &&
|
|
175
|
+
resolveLevelId(node, nodes) === slabLevelId) {
|
|
176
|
+
siblingSlabs.push(node);
|
|
116
177
|
}
|
|
117
|
-
|
|
178
|
+
}
|
|
179
|
+
const renderedPolygon = getRenderableSlabPolygon(slab, { walls: levelWalls, siblingSlabs });
|
|
180
|
+
for (const node of Object.values(nodes)) {
|
|
181
|
+
if (node.type === 'wall') {
|
|
118
182
|
const wall = node;
|
|
119
183
|
if (resolveLevelId(node, nodes) !== slabLevelId)
|
|
120
184
|
continue;
|
|
121
|
-
if (wallOverlapsPolygon(
|
|
185
|
+
if (wallOverlapsPolygon({
|
|
186
|
+
start: wall.start,
|
|
187
|
+
end: wall.end,
|
|
188
|
+
curveOffset: wall.curveOffset ?? 0,
|
|
189
|
+
thickness: wall.thickness,
|
|
190
|
+
}, renderedPolygon)) {
|
|
122
191
|
markDirty(node.id);
|
|
123
192
|
}
|
|
193
|
+
continue;
|
|
124
194
|
}
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
195
|
+
// Generic floor-placed sweep: any registry kind that opts in via
|
|
196
|
+
// `capabilities.floorPlaced` (item / shelf / column / spawn / …)
|
|
197
|
+
// re-elevates through `<FloorElevationSystem>` when a slab below
|
|
198
|
+
// changes. We dirty-mark when the kind's footprint overlaps the
|
|
199
|
+
// changed slab so the system picks it up next frame.
|
|
200
|
+
const def = nodeRegistry.get(node.type);
|
|
201
|
+
const floorPlaced = def?.capabilities?.floorPlaced;
|
|
202
|
+
if (!floorPlaced)
|
|
203
|
+
continue;
|
|
204
|
+
if (floorPlaced.applies && !floorPlaced.applies(node))
|
|
205
|
+
continue;
|
|
206
|
+
const parentId = node.parentId;
|
|
207
|
+
const parent = parentId ? nodes[parentId] : null;
|
|
208
|
+
if (parent && parent.type !== 'level')
|
|
209
|
+
continue;
|
|
210
|
+
if (resolveLevelId(node, nodes) !== slabLevelId)
|
|
211
|
+
continue;
|
|
212
|
+
const position = node.position;
|
|
213
|
+
if (!position)
|
|
214
|
+
continue;
|
|
215
|
+
for (const footprint of getFloorPlacedFootprints(floorPlaced, node, { nodes })) {
|
|
216
|
+
if (itemOverlapsPolygon(footprint.position ?? position, footprint.dimensions, footprint.rotation, slab.polygon, 0.01)) {
|
|
217
|
+
markDirty(node.id);
|
|
218
|
+
break;
|
|
219
|
+
}
|
|
129
220
|
}
|
|
130
221
|
}
|
|
131
222
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wall-slab-overlap.test.d.ts","sourceRoot":"","sources":["../../../src/hooks/spatial-grid/wall-slab-overlap.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,363 @@
|
|
|
1
|
+
import { describe, expect, it } from 'bun:test';
|
|
2
|
+
import { SlabNode, WallNode } from '../../schema';
|
|
3
|
+
import { computeWallSlabElevation, computeWallSlabSupport, wallOverlapsPolygon, } from './spatial-grid-manager';
|
|
4
|
+
// 4×4 square slab, like an auto-slab derived from a room's wall centerlines.
|
|
5
|
+
const SLAB = [
|
|
6
|
+
[0, 0],
|
|
7
|
+
[4, 0],
|
|
8
|
+
[4, 4],
|
|
9
|
+
[0, 4],
|
|
10
|
+
];
|
|
11
|
+
const wall = (start, end, curveOffset = 0) => ({
|
|
12
|
+
start,
|
|
13
|
+
end,
|
|
14
|
+
curveOffset,
|
|
15
|
+
thickness: 0.1,
|
|
16
|
+
});
|
|
17
|
+
describe('wallOverlapsPolygon', () => {
|
|
18
|
+
it('excludes perpendicular walls butting into the slab, on every side', () => {
|
|
19
|
+
// Regression: side-dependent ray-cast tie-breaking used to push some of
|
|
20
|
+
// these walls (depending on which slab edge they touched) but not others.
|
|
21
|
+
expect(wallOverlapsPolygon(wall([2, 4], [2, 7]), SLAB)).toBe(false); // top
|
|
22
|
+
expect(wallOverlapsPolygon(wall([2, 0], [2, -3]), SLAB)).toBe(false); // bottom
|
|
23
|
+
expect(wallOverlapsPolygon(wall([0, 2], [-3, 2]), SLAB)).toBe(false); // left
|
|
24
|
+
expect(wallOverlapsPolygon(wall([4, 2], [7, 2]), SLAB)).toBe(false); // right
|
|
25
|
+
// Reversed direction (endpoint order must not matter)
|
|
26
|
+
expect(wallOverlapsPolygon(wall([2, 7], [2, 4]), SLAB)).toBe(false);
|
|
27
|
+
expect(wallOverlapsPolygon(wall([-3, 2], [0, 2]), SLAB)).toBe(false);
|
|
28
|
+
});
|
|
29
|
+
it('includes walls lying on the slab boundary, on every side', () => {
|
|
30
|
+
expect(wallOverlapsPolygon(wall([0, 0], [4, 0]), SLAB)).toBe(true); // bottom
|
|
31
|
+
expect(wallOverlapsPolygon(wall([4, 0], [4, 4]), SLAB)).toBe(true); // right
|
|
32
|
+
expect(wallOverlapsPolygon(wall([4, 4], [0, 4]), SLAB)).toBe(true); // top
|
|
33
|
+
expect(wallOverlapsPolygon(wall([0, 4], [0, 0]), SLAB)).toBe(true); // left
|
|
34
|
+
// Partial edge coverage still counts
|
|
35
|
+
expect(wallOverlapsPolygon(wall([1, 0], [3, 0]), SLAB)).toBe(true);
|
|
36
|
+
});
|
|
37
|
+
it('includes a wall running past the slab if enough of it lies on the edge', () => {
|
|
38
|
+
// 4m on the edge + 6m beyond: whole wall follows the slab.
|
|
39
|
+
expect(wallOverlapsPolygon(wall([0, 0], [10, 0]), SLAB)).toBe(true);
|
|
40
|
+
});
|
|
41
|
+
it('excludes corner-only contact', () => {
|
|
42
|
+
expect(wallOverlapsPolygon(wall([4, 4], [6, 6]), SLAB)).toBe(false);
|
|
43
|
+
expect(wallOverlapsPolygon(wall([0, 0], [-2, -2]), SLAB)).toBe(false);
|
|
44
|
+
});
|
|
45
|
+
it('includes walls inside or crossing through the slab', () => {
|
|
46
|
+
expect(wallOverlapsPolygon(wall([1, 1], [3, 3]), SLAB)).toBe(true); // fully inside
|
|
47
|
+
expect(wallOverlapsPolygon(wall([-1, 2], [5, 2]), SLAB)).toBe(true); // crossing
|
|
48
|
+
});
|
|
49
|
+
it('uses wall thickness: a face grazing the slab counts, clear separation does not', () => {
|
|
50
|
+
// Centerline 4cm outside, body (half thickness 5cm) reaches the slab.
|
|
51
|
+
expect(wallOverlapsPolygon(wall([0, -0.04], [4, -0.04]), SLAB)).toBe(true);
|
|
52
|
+
// Centerline 1m outside: no contact.
|
|
53
|
+
expect(wallOverlapsPolygon(wall([0, -1], [4, -1]), SLAB)).toBe(false);
|
|
54
|
+
});
|
|
55
|
+
it('handles curved walls by their sampled body', () => {
|
|
56
|
+
// Chord below the slab, bowing into the slab interior (negative offset
|
|
57
|
+
// bows toward +z here).
|
|
58
|
+
expect(wallOverlapsPolygon(wall([0, -0.5], [4, -0.5], -1), SLAB)).toBe(true);
|
|
59
|
+
// Same chord bowing away from the slab: never touches it.
|
|
60
|
+
expect(wallOverlapsPolygon(wall([0, -0.5], [4, -0.5], 1), SLAB)).toBe(false);
|
|
61
|
+
});
|
|
62
|
+
it('supports the legacy (start, end, polygon) call shape', () => {
|
|
63
|
+
expect(wallOverlapsPolygon([1, 1], [3, 3], SLAB)).toBe(true);
|
|
64
|
+
expect(wallOverlapsPolygon([2, 4], [2, 7], SLAB)).toBe(false);
|
|
65
|
+
});
|
|
66
|
+
});
|
|
67
|
+
describe('computeWallSlabElevation', () => {
|
|
68
|
+
const parseWall = (start, end, thickness = 0.1) => WallNode.parse({ start, end, thickness });
|
|
69
|
+
it('lifts a wall standing on an auto slab stored at the centerlines', () => {
|
|
70
|
+
const walls = [
|
|
71
|
+
parseWall([0, 0], [4, 0]),
|
|
72
|
+
parseWall([4, 0], [4, 4]),
|
|
73
|
+
parseWall([4, 4], [0, 4]),
|
|
74
|
+
parseWall([0, 4], [0, 0]),
|
|
75
|
+
];
|
|
76
|
+
const slab = SlabNode.parse({ polygon: SLAB, elevation: 0.1 });
|
|
77
|
+
const bottom = walls[0];
|
|
78
|
+
expect(computeWallSlabElevation({ start: bottom.start, end: bottom.end, thickness: bottom.thickness }, [slab], walls)).toBeCloseTo(0.1);
|
|
79
|
+
});
|
|
80
|
+
it('lifts a wall whose body a legacy stored polygon falls short of', () => {
|
|
81
|
+
// Legacy hand-adjusted slab: edges 6cm inside the wall centerlines —
|
|
82
|
+
// 1cm short of even the inner faces, so the STORED polygon never
|
|
83
|
+
// touches the wall body and the old stored-polygon test returned 0.
|
|
84
|
+
// The rendered footprint band-adopts the edges out to the outer
|
|
85
|
+
// faces, so the wall stands on the slab.
|
|
86
|
+
const walls = [
|
|
87
|
+
parseWall([0, 0], [4, 0]),
|
|
88
|
+
parseWall([4, 0], [4, 4]),
|
|
89
|
+
parseWall([4, 4], [0, 4]),
|
|
90
|
+
parseWall([0, 4], [0, 0]),
|
|
91
|
+
];
|
|
92
|
+
const slab = SlabNode.parse({
|
|
93
|
+
polygon: [
|
|
94
|
+
[0.06, 0.06],
|
|
95
|
+
[3.94, 0.06],
|
|
96
|
+
[3.94, 3.94],
|
|
97
|
+
[0.06, 3.94],
|
|
98
|
+
],
|
|
99
|
+
elevation: 0.1,
|
|
100
|
+
});
|
|
101
|
+
const bottom = walls[0];
|
|
102
|
+
expect(computeWallSlabElevation({ start: bottom.start, end: bottom.end, thickness: bottom.thickness }, [slab], walls)).toBeCloseTo(0.1);
|
|
103
|
+
});
|
|
104
|
+
it('does not lift a wall clearly off the slab', () => {
|
|
105
|
+
const walls = [parseWall([0, 0], [4, 0])];
|
|
106
|
+
const slab = SlabNode.parse({ polygon: SLAB, elevation: 0.1 });
|
|
107
|
+
expect(computeWallSlabElevation({ start: [0, -1], end: [4, -1], thickness: 0.1 }, [slab], walls)).toBe(0);
|
|
108
|
+
});
|
|
109
|
+
it('ignores a slab when the wall runs entirely inside a hole', () => {
|
|
110
|
+
const walls = [parseWall([1, 2], [3, 2])];
|
|
111
|
+
const slab = SlabNode.parse({
|
|
112
|
+
polygon: SLAB,
|
|
113
|
+
elevation: 0.1,
|
|
114
|
+
holes: [
|
|
115
|
+
[
|
|
116
|
+
[0.5, 0.5],
|
|
117
|
+
[3.5, 0.5],
|
|
118
|
+
[3.5, 3.5],
|
|
119
|
+
[0.5, 3.5],
|
|
120
|
+
],
|
|
121
|
+
],
|
|
122
|
+
});
|
|
123
|
+
expect(computeWallSlabElevation({ start: [1, 2], end: [3, 2], thickness: 0.1 }, [slab], walls)).toBe(0);
|
|
124
|
+
});
|
|
125
|
+
it('keeps a wall on the lower slab when a higher slab only reaches one endpoint', () => {
|
|
126
|
+
// The floating-wall bug: a wall standing on the low room whose far
|
|
127
|
+
// endpoint pokes 0.2m onto a raised platform must NOT lift wholesale.
|
|
128
|
+
const low = SlabNode.parse({ polygon: SLAB, elevation: 0.05 });
|
|
129
|
+
const high = SlabNode.parse({
|
|
130
|
+
polygon: [
|
|
131
|
+
[4, 0],
|
|
132
|
+
[8, 0],
|
|
133
|
+
[8, 4],
|
|
134
|
+
[4, 4],
|
|
135
|
+
],
|
|
136
|
+
elevation: 0.6,
|
|
137
|
+
});
|
|
138
|
+
expect(computeWallSlabElevation({ start: [0.5, 2], end: [4.2, 2], thickness: 0.1 }, [low, high], [])).toBeCloseTo(0.05);
|
|
139
|
+
});
|
|
140
|
+
it('keeps a curved wall on the lower slab when a higher slab only reaches its end', () => {
|
|
141
|
+
const low = SlabNode.parse({ polygon: SLAB, elevation: 0.05 });
|
|
142
|
+
const high = SlabNode.parse({
|
|
143
|
+
polygon: [
|
|
144
|
+
[4, 0],
|
|
145
|
+
[8, 0],
|
|
146
|
+
[8, 4],
|
|
147
|
+
[4, 4],
|
|
148
|
+
],
|
|
149
|
+
elevation: 0.6,
|
|
150
|
+
});
|
|
151
|
+
expect(computeWallSlabElevation({ start: [0.5, 2], end: [4.2, 2], curveOffset: 0.5, thickness: 0.1 }, [low, high], [])).toBeCloseTo(0.05);
|
|
152
|
+
});
|
|
153
|
+
it('lifts a wall standing fully on a raised platform', () => {
|
|
154
|
+
const platform = SlabNode.parse({ polygon: SLAB, elevation: 0.6 });
|
|
155
|
+
expect(computeWallSlabElevation({ start: [1, 2], end: [3, 2], thickness: 0.1 }, [platform], [])).toBeCloseTo(0.6);
|
|
156
|
+
});
|
|
157
|
+
it('lifts a wall half on a raised platform, half in the air, onto the platform', () => {
|
|
158
|
+
// No elevation reaches majority (only 39% supported), so the
|
|
159
|
+
// best-covered slab wins — the only alternative would bury the
|
|
160
|
+
// supported half inside the platform.
|
|
161
|
+
const platform = SlabNode.parse({ polygon: SLAB, elevation: 0.6 });
|
|
162
|
+
expect(computeWallSlabElevation({ start: [0.1, 2], end: [10.1, 2], thickness: 0.1 }, [platform], [])).toBeCloseTo(0.6);
|
|
163
|
+
});
|
|
164
|
+
it('pools same-elevation slabs so a shared wall follows their common level', () => {
|
|
165
|
+
// Rooms A and B at the same elevation each cover exactly half the
|
|
166
|
+
// wall (interior edges seam at the x=2 midline); a raised slab covers
|
|
167
|
+
// just under half. Pooled, the common level covers 100% and must
|
|
168
|
+
// win — without pooling the raised slab's 0.4975 would beat either
|
|
169
|
+
// half alone.
|
|
170
|
+
const roomA = SlabNode.parse({
|
|
171
|
+
polygon: [
|
|
172
|
+
[0, 0],
|
|
173
|
+
[2, 0],
|
|
174
|
+
[2, 4],
|
|
175
|
+
[0, 4],
|
|
176
|
+
],
|
|
177
|
+
elevation: 0.1,
|
|
178
|
+
});
|
|
179
|
+
const roomB = SlabNode.parse({
|
|
180
|
+
polygon: [
|
|
181
|
+
[2, 0],
|
|
182
|
+
[4, 0],
|
|
183
|
+
[4, 4],
|
|
184
|
+
[2, 4],
|
|
185
|
+
],
|
|
186
|
+
elevation: 0.1,
|
|
187
|
+
});
|
|
188
|
+
const raised = SlabNode.parse({
|
|
189
|
+
polygon: [
|
|
190
|
+
[1.0, 1],
|
|
191
|
+
[2.99, 1],
|
|
192
|
+
[2.99, 3],
|
|
193
|
+
[1.0, 3],
|
|
194
|
+
],
|
|
195
|
+
elevation: 0.6,
|
|
196
|
+
});
|
|
197
|
+
expect(computeWallSlabElevation({ start: [0, 2], end: [4, 2], thickness: 0.1 }, [roomA, roomB, raised], [])).toBeCloseTo(0.1);
|
|
198
|
+
});
|
|
199
|
+
it('prefers the higher of two majority-supporting slabs (platform stacked on a floor)', () => {
|
|
200
|
+
const floor = SlabNode.parse({
|
|
201
|
+
polygon: [
|
|
202
|
+
[0, 0],
|
|
203
|
+
[8, 0],
|
|
204
|
+
[8, 4],
|
|
205
|
+
[0, 4],
|
|
206
|
+
],
|
|
207
|
+
elevation: 0.05,
|
|
208
|
+
});
|
|
209
|
+
const platform = SlabNode.parse({
|
|
210
|
+
polygon: [
|
|
211
|
+
[0, 0],
|
|
212
|
+
[5, 0],
|
|
213
|
+
[5, 4],
|
|
214
|
+
[0, 4],
|
|
215
|
+
],
|
|
216
|
+
elevation: 0.6,
|
|
217
|
+
});
|
|
218
|
+
// Wall 6m long: floor covers all of it, platform covers ~2/3 — both
|
|
219
|
+
// majorities, and the wall physically rests on the platform.
|
|
220
|
+
expect(computeWallSlabElevation({ start: [1, 2], end: [7, 2], thickness: 0.1 }, [floor, platform], [])).toBeCloseTo(0.6);
|
|
221
|
+
});
|
|
222
|
+
it('keeps a wall pushed up on a raised platform above a coincident floor', () => {
|
|
223
|
+
const floor = SlabNode.parse({ polygon: SLAB, elevation: 0.05 });
|
|
224
|
+
const platform = SlabNode.parse({ polygon: SLAB, elevation: 0.6 });
|
|
225
|
+
expect(computeWallSlabSupport({ start: [1, 2], end: [3, 2], thickness: 0.1 }, [floor, platform], [])).toEqual({
|
|
226
|
+
elevation: 0.6,
|
|
227
|
+
baseElevation: 0.6,
|
|
228
|
+
baseSegments: [{ start: 0, end: 1, elevation: 0.6 }],
|
|
229
|
+
});
|
|
230
|
+
});
|
|
231
|
+
it('fills down only when a lower support is exposed beyond a partial platform', () => {
|
|
232
|
+
const floor = SlabNode.parse({ polygon: SLAB, elevation: 0.05 });
|
|
233
|
+
const platform = SlabNode.parse({
|
|
234
|
+
polygon: [
|
|
235
|
+
[0, 0],
|
|
236
|
+
[2.5, 0],
|
|
237
|
+
[2.5, 4],
|
|
238
|
+
[0, 4],
|
|
239
|
+
],
|
|
240
|
+
elevation: 0.6,
|
|
241
|
+
});
|
|
242
|
+
expect(computeWallSlabSupport({ start: [0.5, 2], end: [3.5, 2], thickness: 0.1 }, [floor, platform], [])).toEqual({
|
|
243
|
+
elevation: 0.6,
|
|
244
|
+
baseElevation: 0.05,
|
|
245
|
+
baseSegments: [
|
|
246
|
+
{ start: 0, end: 2 / 3, elevation: 0.6 },
|
|
247
|
+
{ start: 2 / 3, end: 1, elevation: 0.05 },
|
|
248
|
+
],
|
|
249
|
+
});
|
|
250
|
+
});
|
|
251
|
+
it('keeps a shared wall on the higher slab that carries the full wall band', () => {
|
|
252
|
+
const sharedWall = parseWall([4, 0], [4, 4]);
|
|
253
|
+
const low = SlabNode.parse({ polygon: SLAB, elevation: 0.05 });
|
|
254
|
+
const high = SlabNode.parse({
|
|
255
|
+
polygon: [
|
|
256
|
+
[4, 0],
|
|
257
|
+
[8, 0],
|
|
258
|
+
[8, 4],
|
|
259
|
+
[4, 4],
|
|
260
|
+
],
|
|
261
|
+
elevation: 0.6,
|
|
262
|
+
});
|
|
263
|
+
expect(computeWallSlabSupport({ start: sharedWall.start, end: sharedWall.end, thickness: sharedWall.thickness }, [low, high], [sharedWall])).toEqual({
|
|
264
|
+
elevation: 0.6,
|
|
265
|
+
baseElevation: 0.6,
|
|
266
|
+
baseSegments: [{ start: 0, end: 1, elevation: 0.6 }],
|
|
267
|
+
});
|
|
268
|
+
});
|
|
269
|
+
it('profiles an offset-room wall as high-only, shared, then low-only', () => {
|
|
270
|
+
const sharedWall = parseWall([4, 0], [4, 4.5]);
|
|
271
|
+
const walls = [
|
|
272
|
+
parseWall([0, 0], [4, 0]),
|
|
273
|
+
parseWall([0, 3], [0, 0]),
|
|
274
|
+
parseWall([0, 3], [4, 3]),
|
|
275
|
+
sharedWall,
|
|
276
|
+
parseWall([4, 1.5], [8, 1.5]),
|
|
277
|
+
parseWall([8, 1.5], [8, 4.5]),
|
|
278
|
+
parseWall([8, 4.5], [4, 4.5]),
|
|
279
|
+
];
|
|
280
|
+
const high = SlabNode.parse({
|
|
281
|
+
polygon: [
|
|
282
|
+
[0, 0],
|
|
283
|
+
[4, 0],
|
|
284
|
+
[4, 3],
|
|
285
|
+
[0, 3],
|
|
286
|
+
],
|
|
287
|
+
elevation: 0.6,
|
|
288
|
+
});
|
|
289
|
+
const low = SlabNode.parse({
|
|
290
|
+
polygon: [
|
|
291
|
+
[4, 1.5],
|
|
292
|
+
[8, 1.5],
|
|
293
|
+
[8, 4.5],
|
|
294
|
+
[4, 4.5],
|
|
295
|
+
],
|
|
296
|
+
elevation: 0.05,
|
|
297
|
+
});
|
|
298
|
+
expect(computeWallSlabSupport({ start: sharedWall.start, end: sharedWall.end, thickness: sharedWall.thickness }, [high, low], walls)).toEqual({
|
|
299
|
+
elevation: 0.6,
|
|
300
|
+
baseElevation: 0.05,
|
|
301
|
+
baseSegments: [
|
|
302
|
+
{ start: 0, end: 3.05 / 4.5, elevation: 0.6 },
|
|
303
|
+
{ start: 3.05 / 4.5, end: 1, elevation: 0.05 },
|
|
304
|
+
],
|
|
305
|
+
});
|
|
306
|
+
});
|
|
307
|
+
it('lifts a tiny stub wall standing fully on a slab', () => {
|
|
308
|
+
const slab = SlabNode.parse({ polygon: SLAB, elevation: 0.3 });
|
|
309
|
+
expect(computeWallSlabElevation({ start: [2, 2], end: [2.08, 2], thickness: 0.1 }, [slab], [])).toBeCloseTo(0.3);
|
|
310
|
+
});
|
|
311
|
+
it('does not lift a wall whose run over a higher slab is mostly inside a hole', () => {
|
|
312
|
+
const low = SlabNode.parse({
|
|
313
|
+
polygon: [
|
|
314
|
+
[0, 0],
|
|
315
|
+
[8, 0],
|
|
316
|
+
[8, 4],
|
|
317
|
+
[0, 4],
|
|
318
|
+
],
|
|
319
|
+
elevation: 0.05,
|
|
320
|
+
});
|
|
321
|
+
const high = SlabNode.parse({
|
|
322
|
+
polygon: [
|
|
323
|
+
[0, 0],
|
|
324
|
+
[8, 0],
|
|
325
|
+
[8, 4],
|
|
326
|
+
[0, 4],
|
|
327
|
+
],
|
|
328
|
+
elevation: 0.6,
|
|
329
|
+
holes: [
|
|
330
|
+
[
|
|
331
|
+
[0.5, 0],
|
|
332
|
+
[8, 0],
|
|
333
|
+
[8, 4],
|
|
334
|
+
[0.5, 4],
|
|
335
|
+
],
|
|
336
|
+
],
|
|
337
|
+
});
|
|
338
|
+
// Net high support is only x ∈ [0, 0.5]; the low slab carries the wall.
|
|
339
|
+
expect(computeWallSlabElevation({ start: [0, 2], end: [8, 2], thickness: 0.1 }, [low, high], [])).toBeCloseTo(0.05);
|
|
340
|
+
});
|
|
341
|
+
it('keeps support for a wall running along a hole rim', () => {
|
|
342
|
+
// Hole boundaries count as solid: the wall ringing a stairwell sits
|
|
343
|
+
// on the rim, its outer face on solid slab.
|
|
344
|
+
const slab = SlabNode.parse({
|
|
345
|
+
polygon: [
|
|
346
|
+
[0, 0],
|
|
347
|
+
[6, 0],
|
|
348
|
+
[6, 6],
|
|
349
|
+
[0, 6],
|
|
350
|
+
],
|
|
351
|
+
elevation: 0.4,
|
|
352
|
+
holes: [
|
|
353
|
+
[
|
|
354
|
+
[2, 2],
|
|
355
|
+
[4, 2],
|
|
356
|
+
[4, 4],
|
|
357
|
+
[2, 4],
|
|
358
|
+
],
|
|
359
|
+
],
|
|
360
|
+
});
|
|
361
|
+
expect(computeWallSlabElevation({ start: [2, 2], end: [4, 2], thickness: 0.1 }, [slab], [])).toBeCloseTo(0.4);
|
|
362
|
+
});
|
|
363
|
+
});
|
package/dist/index.d.ts
CHANGED
|
@@ -1,24 +1,52 @@
|
|
|
1
|
-
export type { BuildingEvent, CameraControlEvent, CameraControlFitSceneEvent, CeilingEvent, ColumnEvent, DoorEvent, EventSuffix, FenceEvent, GridEvent, ItemEvent, LevelEvent, NodeEvent, RoofEvent, RoofSegmentEvent, SiteEvent, SlabEvent, SpawnEvent, StairEvent, StairSegmentEvent, WallEvent, WindowEvent, ZoneEvent, } from './events/bus';
|
|
1
|
+
export type { BoxVentEvent, BuildingEvent, CabinetEvent, CabinetModuleEvent, CameraControlEvent, CameraControlFitSceneEvent, CeilingEvent, ChimneyEvent, ColumnEvent, DoorEvent, DormerEvent, ElevatorEvent, EventSuffix, FenceEvent, GridEvent, GuideEvent, GutterEvent, ItemEvent, LevelEvent, MeasurementEvent, NodeEvent, RidgeVentEvent, RoofEvent, RoofSegmentEvent, RoomPresetCreateEvent, ScanEvent, ShelfEvent, SiteEvent, SkylightEvent, SlabEvent, SolarPanelEvent, SpawnEvent, StairEvent, StairSegmentEvent, WallEvent, WindowEvent, ZoneEvent, } from './events/bus';
|
|
2
2
|
export { emitter, eventSuffixes } from './events/bus';
|
|
3
|
+
export { type ItemClipEntry, itemClipRegistry } from './hooks/scene-registry/item-clip-registry';
|
|
3
4
|
export { sceneRegistry, useRegistry, } from './hooks/scene-registry/scene-registry';
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
5
|
+
export { type FloorPlacedElevationArgs, getFloorPlacedElevation, getFloorPlacedFootprints, getFloorStackedPosition, } from './hooks/spatial-grid/floor-placed-elevation';
|
|
6
|
+
export { pointInPolygon, spatialGridManager, type WallSlabSupportSegment, } from './hooks/spatial-grid/spatial-grid-manager';
|
|
7
|
+
export { findLevelAncestorId, initSpatialGridSync, resolveBuildingForLevel, resolveLevelId, } from './hooks/spatial-grid/spatial-grid-sync';
|
|
6
8
|
export { useSpatialQuery } from './hooks/spatial-grid/use-spatial-query';
|
|
7
9
|
export { loadAssetUrl, saveAsset } from './lib/asset-storage';
|
|
8
10
|
export { clampDoorOperationState, getDoorRenderOpenAmount, getGarageVisibleOpeningRatio, isOperationDoorType, SECTIONAL_GARAGE_RENDER_OPEN_SCALE, } from './lib/door-operation';
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
-
export {
|
|
11
|
+
export { getDefaultLevelName, getLevelDisplayName } from './lib/level-name';
|
|
12
|
+
export { areMeasurementPointsCoplanar, closestMeasurementFeatureBinding, MEASUREMENT_PLANAR_TOLERANCE, measurementAnchorFallback, measurementAngle, measurementArea, measurementAreaVector, measurementCentroid, measurementDistance, measurementFeatureLength, measurementNormal, measurementPerimeter, measurementPrismVolume, measurementReferenceNodeIds, remapMeasurementReferences, } from './lib/measurement-geometry';
|
|
13
|
+
export { type Point2D as PolygonPoint2D, pointInPolygon as pointInPolygon2D, pointOnSegment, polygonContainsPolygon, polygonsIntersect, polygonsOverlap, segmentsIntersect, } from './lib/polygon-relations';
|
|
14
|
+
export { resolveSelectionProxyId, selectionProxyIdFromMetadata } from './lib/selection-proxy';
|
|
15
|
+
export { getRenderableSlabPolygon, type SlabEdgeWallBandSnap, type SlabPolygonContext, slabPolygonContextFromGeometry, snapSlabEdgeToWallBand, } from './lib/slab-polygon';
|
|
16
|
+
export { deriveSlotId, isSlotMaterialName, SLOT_MATERIAL_PREFIX, slotLabelFromId, } from './lib/slots';
|
|
17
|
+
export { type AutoCeilingPlanningContext, type AutoCeilingSyncPlan, type AutoSlabSyncPlan, type AutoZoneSyncPlan, detectSpacesForLevel, initSpaceDetectionSync, isSpaceDetectionPaused, pauseSpaceDetection, planAutoCeilingsForLevel, planAutoSlabsForLevel, planAutoZonesForLevel, projectAutoSlabsForPlan, resolveAutoZonePolygon, resumeSpaceDetection, type Space, type SpaceBoundaryFace, wallClosesRoom, wallTouchesOthers, } from './lib/space-detection';
|
|
18
|
+
export { closestOnSegment, collectLevelWallSegments, nearestWallSegment, WALL_SNAP_DISTANCE_M, type WallSegment, type WallSegmentClosest, } from './lib/wall-distance';
|
|
19
|
+
export { deriveZoneQuantityReport, type ZoneQuantityReport, type ZoneQuantityValue, } from './lib/zone-quantities';
|
|
20
|
+
export { getCatalogMaterialById, getLibraryMaterialIdFromRef, getMaterialPresetByRef, getMaterialsForCategory, getSceneMaterialIdFromRef, LIBRARY_MATERIAL_REF_PREFIX, MATERIAL_CATALOG, MATERIAL_CATEGORIES, MATERIAL_SURFACES, type MaterialCatalogItem, type MaterialCategory, type MaterialRef, type MaterialSurface, type ParsedMaterialRef, parseMaterialRef, SCENE_MATERIAL_REF_PREFIX, toLibraryMaterialRef, toSceneMaterialRef, } from './material-library';
|
|
21
|
+
export type { FloorPlacedFootprint, FloorPlacedFootprintContext, FloorPlacedFootprintResolver, FloorPlacedFootprintsResolver, } from './registry';
|
|
22
|
+
export * from './registry';
|
|
12
23
|
export * from './schema';
|
|
13
|
-
export
|
|
14
|
-
export {
|
|
24
|
+
export * from './services';
|
|
25
|
+
export { isMovable, movePlanToward, moveToward, resolveMovable } from './services/movement';
|
|
26
|
+
export { getSceneHistoryPauseDepth, pauseSceneHistory, resetSceneHistoryPauseDepth, resumeSceneHistory, runAsSingleSceneHistoryStep, } from './store/history-control';
|
|
27
|
+
export { type ControlValue, type DoorAnimationState, type DoorInteractiveState, type ElevatorInteractiveState, type ElevatorPhase, type ItemInteractiveState, type SkylightAnimationState, type SkylightInteractiveState, useInteractive, type WindowAnimationState, type WindowInteractiveState, } from './store/use-interactive';
|
|
28
|
+
export { default as useLiveNodeOverrides, getEffectiveNode, type LiveNodeOverrides, } from './store/use-live-node-overrides';
|
|
15
29
|
export { default as useLiveTransforms, type LiveTransform } from './store/use-live-transforms';
|
|
16
30
|
export { clearSceneHistory, default as useScene } from './store/use-scene';
|
|
31
|
+
export { resolveElevatorDispatchTarget } from './systems/elevator/elevator-dispatch';
|
|
32
|
+
export { type ElevatorDoorSide, getElevatorCabCenterZ, getElevatorCabDepth, getElevatorCabWidth, getElevatorDoorLeafSides, getElevatorDoorLeafWidth, getElevatorDoorLeafX, getElevatorShaftDepth, getElevatorShaftWallThickness, getElevatorShaftWidth, getResolvedElevatorDoorPanelStyle, getResolvedElevatorDoorStyle, getResolvedElevatorShaftStyle, } from './systems/elevator/elevator-geometry';
|
|
33
|
+
export { syncAutoElevatorOpenings } from './systems/elevator/elevator-opening-sync';
|
|
34
|
+
export { ElevatorOpeningSystem } from './systems/elevator/elevator-opening-system';
|
|
35
|
+
export { createElevatorInteractiveState, openElevatorDoor, openElevatorDoorState, queueElevatorRequest, requestElevatorLevel, stepElevatorRuntimeState, stepElevatorRuntimes, } from './systems/elevator/elevator-runtime';
|
|
36
|
+
export { ElevatorRuntimeSystem } from './systems/elevator/elevator-runtime-system';
|
|
37
|
+
export { DEFAULT_ELEVATOR_LEVEL_HEIGHT, type ElevatorLevelEntry, getElevatorLevelHeight, resolveElevatorBuildingLevels, resolveElevatorLevels, resolveElevatorServiceLevelIds, resolveElevatorServiceLevels, } from './systems/elevator/elevator-service';
|
|
38
|
+
export { getFenceCenterlineFrameAt, getFenceCenterlineLength, sampleFenceCenterline, } from './systems/fence/fence-centerline';
|
|
39
|
+
export { getFenceControlHandle, getFenceSplineFrameAt, getFenceSplineLength, getTwoPointFenceCurveTangents, isSplineFence, sampleFenceSpline, } from './systems/fence/fence-spline';
|
|
40
|
+
export { type StairFootprintAABB, stairFootprintAABB } from './systems/stair/stair-footprint';
|
|
41
|
+
export { createSurfaceOpeningPreviewController } from './systems/stair/stair-opening-preview';
|
|
17
42
|
export { syncAutoStairOpenings } from './systems/stair/stair-opening-sync';
|
|
43
|
+
export { StairOpeningSystem } from './systems/stair/stair-opening-system';
|
|
18
44
|
export { getClampedWallCurveOffset, getMaxWallCurveOffset, getWallChordFrame, getWallCurveFrameAt, getWallCurveLength, getWallMidpointHandlePoint, getWallStraightSnapOffset, getWallSurfacePolygon, isCurvedWall, normalizeWallCurveOffset, sampleWallCenterline, } from './systems/wall/wall-curve';
|
|
19
45
|
export { DEFAULT_WALL_HEIGHT, DEFAULT_WALL_THICKNESS, getWallPlanFootprint, getWallThickness, } from './systems/wall/wall-footprint';
|
|
20
46
|
export { calculateLevelMiters, getAdjacentWallIds, getWallMiterBoundaryPoints, type Point2D, pointToKey, type WallMiterBoundaryPoints, type WallMiterData, } from './systems/wall/wall-mitering';
|
|
47
|
+
export { constrainWallMoveDeltaToAxis, getLinkedWallUpdates, getPerpendicularWallMoveAxis, getPlannedLinkedWallUpdates, planWallMoveJunctions, type WallMoveAxis, type WallMoveBridgePlan, type WallMoveJunctionPlan, type WallMoveLinkedWallTargetPlan, type WallPlanPoint, } from './systems/wall/wall-move';
|
|
21
48
|
export type { SceneGraph } from './utils/clone-scene-graph';
|
|
22
49
|
export { cloneLevelSubtree, cloneSceneGraph, forkSceneGraph } from './utils/clone-scene-graph';
|
|
23
50
|
export { isObject } from './utils/types';
|
|
51
|
+
export { type BuildStats, type ParsedBuildJson, type SchemaIssue, type ValidateBuildJsonResult, type ValidationIssue, type ValidationSeverity, validateBuildJson, } from './validation/validate-build-json';
|
|
24
52
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,aAAa,EACb,kBAAkB,EAClB,0BAA0B,EAC1B,YAAY,EACZ,WAAW,EACX,SAAS,EACT,WAAW,EACX,UAAU,EACV,SAAS,EACT,SAAS,EACT,UAAU,EACV,SAAS,EACT,SAAS,EACT,gBAAgB,EAChB,SAAS,EACT,SAAS,EACT,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,SAAS,EACT,WAAW,EACX,SAAS,GACV,MAAM,cAAc,CAAA;AACrB,OAAO,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AACrD,OAAO,EACL,aAAa,EACb,WAAW,GACZ,MAAM,uCAAuC,CAAA;AAC9C,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,YAAY,EACZ,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,0BAA0B,EAC1B,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,SAAS,EACT,WAAW,EACX,aAAa,EACb,WAAW,EACX,UAAU,EACV,SAAS,EACT,UAAU,EACV,WAAW,EACX,SAAS,EACT,UAAU,EACV,gBAAgB,EAChB,SAAS,EACT,cAAc,EACd,SAAS,EACT,gBAAgB,EAChB,qBAAqB,EACrB,SAAS,EACT,UAAU,EACV,SAAS,EACT,aAAa,EACb,SAAS,EACT,eAAe,EACf,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,SAAS,EACT,WAAW,EACX,SAAS,GACV,MAAM,cAAc,CAAA;AACrB,OAAO,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AACrD,OAAO,EAAE,KAAK,aAAa,EAAE,gBAAgB,EAAE,MAAM,2CAA2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