@snaptrude/plugin-core 0.0.0-dev-20260708130115 → 0.0.0-dev-20260827135706
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/CHANGELOG.md +152 -1
- package/api-manifest.json +3620 -276
- package/dist/api/analysis/daylight.d.ts +603 -0
- package/dist/api/analysis/daylight.d.ts.map +1 -0
- package/dist/api/analysis/heatmaps.d.ts +658 -0
- package/dist/api/analysis/heatmaps.d.ts.map +1 -0
- package/dist/api/analysis/illuminance.d.ts +145 -0
- package/dist/api/analysis/illuminance.d.ts.map +1 -0
- package/dist/api/analysis/index.d.ts +59 -0
- package/dist/api/analysis/index.d.ts.map +1 -0
- package/dist/api/analysis/shadows.d.ts +165 -0
- package/dist/api/analysis/shadows.d.ts.map +1 -0
- package/dist/api/analysis/solar.d.ts +249 -0
- package/dist/api/analysis/solar.d.ts.map +1 -0
- package/dist/api/analysis/sunlightHours.d.ts +208 -0
- package/dist/api/analysis/sunlightHours.d.ts.map +1 -0
- package/dist/api/analysis/sunpath.d.ts +80 -0
- package/dist/api/analysis/sunpath.d.ts.map +1 -0
- package/dist/api/analysis/weather.d.ts +193 -0
- package/dist/api/analysis/weather.d.ts.map +1 -0
- package/dist/api/core/camera/index.d.ts +261 -0
- package/dist/api/core/camera/index.d.ts.map +1 -0
- package/dist/api/core/comment/index.d.ts +105 -2
- package/dist/api/core/comment/index.d.ts.map +1 -1
- package/dist/api/core/geom/create/index.d.ts +840 -14
- package/dist/api/core/geom/create/index.d.ts.map +1 -1
- package/dist/api/core/geom/delete/index.d.ts +8 -2
- package/dist/api/core/geom/delete/index.d.ts.map +1 -1
- package/dist/api/core/geom/query/arc.d.ts +5 -5
- package/dist/api/core/geom/query/brep.d.ts +130 -18
- package/dist/api/core/geom/query/brep.d.ts.map +1 -1
- package/dist/api/core/geom/query/circle.d.ts +18 -18
- package/dist/api/core/geom/query/contour.d.ts +20 -20
- package/dist/api/core/geom/query/curve.d.ts +49 -49
- package/dist/api/core/geom/query/edge.d.ts +5 -5
- package/dist/api/core/geom/query/face.d.ts +16 -16
- package/dist/api/core/geom/query/halfedge.d.ts +8 -8
- package/dist/api/core/geom/query/profile.d.ts +19 -19
- package/dist/api/core/geom/query/vertex.d.ts +8 -8
- package/dist/api/core/geom/update/contour.d.ts +14 -14
- package/dist/api/core/geom/update/curve.d.ts +7 -7
- package/dist/api/core/geom/update/profile.d.ts +16 -16
- package/dist/api/core/handles/index.d.ts +210 -0
- package/dist/api/core/handles/index.d.ts.map +1 -0
- package/dist/api/core/index.d.ts +34 -0
- package/dist/api/core/index.d.ts.map +1 -1
- package/dist/api/core/io/export/index.d.ts +134 -0
- package/dist/api/core/io/export/index.d.ts.map +1 -0
- package/dist/api/core/io/import/index.d.ts +453 -0
- package/dist/api/core/io/import/index.d.ts.map +1 -0
- package/dist/api/core/io/index.d.ts +40 -0
- package/dist/api/core/io/index.d.ts.map +1 -0
- package/dist/api/core/io/job/index.d.ts +139 -0
- package/dist/api/core/io/job/index.d.ts.map +1 -0
- package/dist/api/core/io/query/index.d.ts +74 -0
- package/dist/api/core/io/query/index.d.ts.map +1 -0
- package/dist/api/core/io/terrain/index.d.ts +341 -0
- package/dist/api/core/io/terrain/index.d.ts.map +1 -0
- package/dist/api/core/io/underlay/index.d.ts +805 -0
- package/dist/api/core/io/underlay/index.d.ts.map +1 -0
- package/dist/api/core/layers.d.ts +7 -7
- package/dist/api/core/mode/index.d.ts +99 -0
- package/dist/api/core/mode/index.d.ts.map +1 -0
- package/dist/api/core/project/index.d.ts +68 -1
- package/dist/api/core/project/index.d.ts.map +1 -1
- package/dist/api/core/proposals/index.d.ts +531 -0
- package/dist/api/core/proposals/index.d.ts.map +1 -0
- package/dist/api/core/storeys/index.d.ts +265 -0
- package/dist/api/core/storeys/index.d.ts.map +1 -0
- package/dist/api/core/tags.d.ts +24 -0
- package/dist/api/core/tags.d.ts.map +1 -1
- package/dist/api/core/user.d.ts +44 -0
- package/dist/api/core/user.d.ts.map +1 -0
- package/dist/api/core/zoom/index.d.ts +4 -0
- package/dist/api/core/zoom/index.d.ts.map +1 -1
- package/dist/api/design/boolean/index.d.ts +4 -4
- package/dist/api/design/create/index.d.ts +568 -45
- package/dist/api/design/create/index.d.ts.map +1 -1
- package/dist/api/design/delete/index.d.ts +3 -0
- package/dist/api/design/delete/index.d.ts.map +1 -1
- package/dist/api/design/doors/index.d.ts +195 -0
- package/dist/api/design/doors/index.d.ts.map +1 -1
- package/dist/api/design/edit/index.d.ts +1 -1
- package/dist/api/design/erase/index.d.ts +2 -2
- package/dist/api/design/family.d.ts +349 -0
- package/dist/api/design/family.d.ts.map +1 -0
- package/dist/api/design/furniture/index.d.ts +181 -8
- package/dist/api/design/furniture/index.d.ts.map +1 -1
- package/dist/api/design/index.d.ts +98 -0
- package/dist/api/design/index.d.ts.map +1 -1
- package/dist/api/design/lock.d.ts +26 -0
- package/dist/api/design/lock.d.ts.map +1 -1
- package/dist/api/design/materials/index.d.ts +270 -16
- package/dist/api/design/materials/index.d.ts.map +1 -1
- package/dist/api/design/query/geometry/index.d.ts +112 -0
- package/dist/api/design/query/geometry/index.d.ts.map +1 -1
- package/dist/api/design/query/index.d.ts +282 -11
- package/dist/api/design/query/index.d.ts.map +1 -1
- package/dist/api/design/query/referenceLines.d.ts +45 -0
- package/dist/api/design/query/referenceLines.d.ts.map +1 -0
- package/dist/api/design/query/spaces.d.ts +181 -8
- package/dist/api/design/query/spaces.d.ts.map +1 -1
- package/dist/api/design/selection/index.d.ts +144 -0
- package/dist/api/design/selection/index.d.ts.map +1 -1
- package/dist/api/design/transform/index.d.ts +172 -10
- package/dist/api/design/transform/index.d.ts.map +1 -1
- package/dist/api/design/types/index.d.ts +181 -0
- package/dist/api/design/types/index.d.ts.map +1 -0
- package/dist/api/design/update/index.d.ts +553 -2
- package/dist/api/design/update/index.d.ts.map +1 -1
- package/dist/api/design/visibility.d.ts +126 -0
- package/dist/api/design/visibility.d.ts.map +1 -0
- package/dist/api/design/windows/index.d.ts +113 -2
- package/dist/api/design/windows/index.d.ts.map +1 -1
- package/dist/api/entity/buildableEnvelope.d.ts +4 -0
- package/dist/api/entity/buildableEnvelope.d.ts.map +1 -1
- package/dist/api/entity/referenceLine.d.ts +10 -2
- package/dist/api/entity/referenceLine.d.ts.map +1 -1
- package/dist/api/entity/space.d.ts +21 -21
- package/dist/api/entity/story.d.ts +242 -15
- package/dist/api/entity/story.d.ts.map +1 -1
- package/dist/api/index.d.ts +10 -0
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/presentation/aiInspiration.d.ts +25 -25
- package/dist/api/presentation/annotate.d.ts +467 -0
- package/dist/api/presentation/annotate.d.ts.map +1 -0
- package/dist/api/presentation/diagrams.d.ts +111 -8
- package/dist/api/presentation/diagrams.d.ts.map +1 -1
- package/dist/api/presentation/export.d.ts +108 -0
- package/dist/api/presentation/export.d.ts.map +1 -0
- package/dist/api/presentation/import.d.ts +55 -4
- package/dist/api/presentation/import.d.ts.map +1 -1
- package/dist/api/presentation/index.d.ts +58 -1
- package/dist/api/presentation/index.d.ts.map +1 -1
- package/dist/api/presentation/placedViews.d.ts +1139 -0
- package/dist/api/presentation/placedViews.d.ts.map +1 -0
- package/dist/api/presentation/shapes.d.ts +481 -0
- package/dist/api/presentation/shapes.d.ts.map +1 -0
- package/dist/api/presentation/sheets.d.ts +452 -13
- package/dist/api/presentation/sheets.d.ts.map +1 -1
- package/dist/api/presentation/slideshow.d.ts +125 -0
- package/dist/api/presentation/slideshow.d.ts.map +1 -0
- package/dist/api/presentation/tables.d.ts +81 -0
- package/dist/api/presentation/tables.d.ts.map +1 -0
- package/dist/api/presentation/views.d.ts +367 -7
- package/dist/api/presentation/views.d.ts.map +1 -1
- package/dist/api/program/areas.d.ts +102 -12
- package/dist/api/program/areas.d.ts.map +1 -1
- package/dist/api/program/cores.d.ts +3 -99
- package/dist/api/program/cores.d.ts.map +1 -1
- package/dist/api/program/index.d.ts +7 -15
- package/dist/api/program/index.d.ts.map +1 -1
- package/dist/api/program/layout.d.ts +346 -11
- package/dist/api/program/layout.d.ts.map +1 -1
- package/dist/api/program/site.d.ts +469 -13
- package/dist/api/program/site.d.ts.map +1 -1
- package/dist/api/program/spreadsheet.d.ts +365 -41
- package/dist/api/program/spreadsheet.d.ts.map +1 -1
- package/dist/api/workspace/index.d.ts +505 -0
- package/dist/api/workspace/index.d.ts.map +1 -0
- package/dist/errors/codes.d.ts +34 -0
- package/dist/errors/codes.d.ts.map +1 -0
- package/dist/errors/envelope.d.ts +56 -0
- package/dist/errors/envelope.d.ts.map +1 -0
- package/dist/errors/index.d.ts +6 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/plugin-error.d.ts +69 -0
- package/dist/errors/plugin-error.d.ts.map +1 -0
- package/dist/handles.d.ts +97 -25
- package/dist/handles.d.ts.map +1 -1
- package/dist/host-utils.d.ts +4 -0
- package/dist/host-utils.d.ts.map +1 -1
- package/dist/index.cjs +4582 -1422
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4171 -1411
- package/dist/index.js.map +1 -1
- package/package.json +4 -2
- package/scripts/generate-manifest.mjs +45 -0
- package/scripts/generate-manifest.test.mjs +103 -4
- package/src/api/analysis/daylight.ts +470 -0
- package/src/api/analysis/heatmaps.ts +683 -0
- package/src/api/analysis/illuminance.ts +155 -0
- package/src/api/analysis/index.ts +61 -0
- package/src/api/analysis/shadows.ts +183 -0
- package/src/api/analysis/solar.ts +237 -0
- package/src/api/analysis/sunlightHours.ts +211 -0
- package/src/api/analysis/sunpath.ts +83 -0
- package/src/api/analysis/weather.ts +179 -0
- package/src/api/core/camera/index.ts +268 -0
- package/src/api/core/comment/index.ts +120 -2
- package/src/api/core/geom/create/index.ts +912 -1
- package/src/api/core/geom/delete/index.ts +6 -0
- package/src/api/core/geom/query/brep.ts +119 -0
- package/src/api/core/handles/index.ts +233 -0
- package/src/api/core/index.ts +34 -0
- package/src/api/core/io/export/index.ts +126 -0
- package/src/api/core/io/import/index.ts +496 -0
- package/src/api/core/io/index.ts +42 -0
- package/src/api/core/io/job/index.ts +140 -0
- package/src/api/core/io/query/index.ts +71 -0
- package/src/api/core/io/terrain/index.ts +360 -0
- package/src/api/core/io/underlay/index.ts +705 -0
- package/src/api/core/mode/index.ts +96 -0
- package/src/api/core/project/index.ts +62 -1
- package/src/api/core/proposals/index.ts +569 -0
- package/src/api/core/storeys/index.ts +294 -0
- package/src/api/core/tags.ts +27 -0
- package/src/api/core/user.ts +46 -0
- package/src/api/core/zoom/index.ts +4 -0
- package/src/api/design/create/index.ts +670 -30
- package/src/api/design/delete/index.ts +3 -0
- package/src/api/design/doors/index.ts +208 -0
- package/src/api/design/erase/index.ts +1 -1
- package/src/api/design/family.ts +388 -0
- package/src/api/design/furniture/index.ts +197 -8
- package/src/api/design/index.ts +102 -0
- package/src/api/design/lock.ts +27 -0
- package/src/api/design/materials/index.ts +334 -27
- package/src/api/design/query/geometry/index.ts +125 -3
- package/src/api/design/query/index.ts +217 -7
- package/src/api/design/query/referenceLines.ts +52 -0
- package/src/api/design/query/spaces.ts +143 -0
- package/src/api/design/selection/index.ts +129 -0
- package/src/api/design/transform/index.ts +170 -9
- package/src/api/design/types/index.ts +156 -0
- package/src/api/design/update/index.ts +631 -3
- package/src/api/design/visibility.ts +143 -0
- package/src/api/design/windows/index.ts +128 -2
- package/src/api/entity/buildableEnvelope.ts +4 -0
- package/src/api/entity/referenceLine.ts +8 -0
- package/src/api/entity/story.ts +259 -15
- package/src/api/index.ts +10 -0
- package/src/api/presentation/annotate.ts +385 -0
- package/src/api/presentation/diagrams.ts +118 -8
- package/src/api/presentation/export.ts +108 -0
- package/src/api/presentation/import.ts +51 -4
- package/src/api/presentation/index.ts +66 -1
- package/src/api/presentation/placedViews.ts +1120 -0
- package/src/api/presentation/shapes.ts +274 -0
- package/src/api/presentation/sheets.ts +400 -13
- package/src/api/presentation/slideshow.ts +134 -0
- package/src/api/presentation/tables.ts +84 -0
- package/src/api/presentation/views.ts +376 -8
- package/src/api/program/areas.ts +88 -15
- package/src/api/program/cores.ts +3 -91
- package/src/api/program/index.ts +7 -15
- package/src/api/program/layout.ts +365 -11
- package/src/api/program/site.ts +435 -13
- package/src/api/program/spreadsheet.ts +376 -35
- package/src/api/workspace/index.ts +563 -0
- package/src/errors/codes.ts +136 -0
- package/src/errors/envelope.ts +75 -0
- package/src/errors/index.ts +21 -0
- package/src/errors/plugin-error.ts +134 -0
- package/src/handles.ts +123 -13
- package/src/host-utils.ts +4 -0
- package/src/index.ts +1 -0
- package/test/errors.test.mjs +184 -0
- package/tsconfig.json +7 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,84 @@
|
|
|
1
1
|
# @snaptrude/plugin-core
|
|
2
2
|
|
|
3
|
-
## 0.
|
|
3
|
+
## 0.9.6
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Add five APIs the plugin agent repeatedly reached for but that did not exist.
|
|
8
|
+
- `core.project.getInfo()` — project id, display name, unit type, storey count (scoped to the active building), active storey, and site location in one call. Closes a genuine capability gap: nothing previously returned the current project's identity.
|
|
9
|
+
- `core.storeys.getActive()` — `setActive` had no getter, unlike `core.buildings`, `core.layers` and `core.proposals`.
|
|
10
|
+
- `core.camera.getMode()` — `setMode` had no getter, while `getProjection`/`setProjection` on the same class were paired.
|
|
11
|
+
- `design.visibility.show(components)` — `hide` previously had only `showAll` as its inverse, so specific components could not be revealed.
|
|
12
|
+
- `design.furniture.listCatalogGroups()` — matches `design.doors` and `design.windows`, so all three catalog surfaces are named alike. `design.furniture.listCategories()` is deprecated but still supported.
|
|
13
|
+
|
|
14
|
+
## 0.9.4
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- 0008010: `brepFromLoft` auto-matches section edge counts (deterministic vertex insertion) and auto-aligns seams for straight-edge sections; `brepFromSweep` accepts closed (ring) paths and gains an optional taper scale law (`startScale`/`endScale` or per-point `scales`).
|
|
19
|
+
- f54ea17: `brepFromLoft` gains `options` (`compatibility: "strict" | "auto"`, `seamAlignment: "authored" | "auto"` — strict+authored restores pre-0.9.4 lofting); `brepFromSweep` options gain `transition` (`"miter"` default, `"round"` on open paths, `{ bevel }` chamfered corners on open and closed paths); new pure read `core.geom.query.brep.getEdgeCurve` returns exact line/arc/circle edge curve data.
|
|
20
|
+
|
|
21
|
+
## 0.9.3
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- 3584bde: Expose configured BIM creation and Site Analysis sheet APIs: `design.create.opening` (catalog door/window with width/height/sillHeight), staircase `dimensions` overrides (strict-validated, quarter-turn rotation), and `program.site.getSiteAnalysis`/`updateSiteAnalysis` with merge/append semantics. `PluginSiteAnalysisUpdateOptions` accepts `null` as "no options".
|
|
26
|
+
|
|
27
|
+
## 0.9.2
|
|
28
|
+
|
|
29
|
+
### Patch Changes
|
|
30
|
+
|
|
31
|
+
- 5b91c7b: OCC geometry batch: new `core.geom.create` brep constructors — `brepFromFillet`, `brepFromChamfer`, `brepFromOffset`, `brepFromShell`, `brepsFromSplit`, `brepFromSweep`, `brepFromRevolution`; `brepFromLoft` widened with optional `intermediateContours` (multi-section lofts); new `core.geom.query.brep.getDistance` (minimum distance between two solids with witness points).
|
|
32
|
+
|
|
33
|
+
## 0.9.1
|
|
34
|
+
|
|
35
|
+
### Patch Changes
|
|
36
|
+
|
|
37
|
+
- Plugin API 0.9.1 — strictly additive: the terrain mesh lane and the Present-mode styling/canvas lane. No signatures changed, no behavior of existing methods changed; deployed plugins are unaffected (`versionGate` compares major.minor only).
|
|
38
|
+
- **`core.io.terrain.replaceMesh(positions, indices, units?, options?)`** — replace the site terrain surface with a caller-supplied triangle mesh. World-space flat arrays (the `getTriangulatedMeshes` frame, so read-modify-write round-trips); `units: "meters"` converts on the way in. Validated before any engine call (finiteness, index bounds, degenerate topology, scene-bound extents, **500k vertex/triangle caps** — the surface's first explicit payload ceiling); a predominantly down-facing mesh is auto-flipped with a warning. Datum, geolocation, opacity, lock state and the elevation/satellite toggles survive; the map texture is re-projected best-effort; cut/fill history resets by contract. One undo step restores the prior surface exactly (buffers, UVs, submesh layout, cut/fill data, volumes). The replacement **persists with the project**: the mesh uploads to bucket storage and reload applies it instead of the heightmap build. The optional `options` mirrors the requester's contract: `coordinateSpace`, `expectedTerrain` (session optimistic check), `expectedModelRevision` (session terrain-mesh revision, returned as `modelRevision` in the result), `baseline: "make-replacement-original"`, `preserve` opt-outs (`datum`/`satellite`/`material` have real opt-out behavior; `geolocation: false` rejects — always preserved), and `clientMutationId` (session-scoped idempotent replay). For projects without terrain, compose `core.io.import.terrain` + `replaceMesh` (a separate `createFromMesh` was deliberately not added).
|
|
39
|
+
- **`presentation.placedViews` — per-instance styling** (`getStyles` / `updateStyles` / `resetStyles` / `updateFontStyles`): the Present sidebar's full per-category styling surface — 7 line dash styles, line color, dash-length multiplier, **cut vs projection line weights in mm** (plus tree/parking weights), fills (`department`/`texture`/`monochrome`/`tag:<tagCategoryId>`), per-category opacity, category hide (cascades to labels), view-style restyles (block/rounded/bubble with radius + inset), Topography map/building sub-controls, and Text-tab typography per label type (font family incl. Google Fonts, weight, italic, px size, visible label types). Writes are host-validated (typed VALIDATION with the supported-setting list), land as **one undo step per call**, re-render immediately, and fan out across an auto-diagram sheet's set. `getStyles` returns fully-resolved values plus each category's supported setting ids.
|
|
40
|
+
- **`presentation.placedViews` — labels** (`listLabels` / `moveLabel` / `setLabelHidden`): a placed view's generated labels (space names, departments, areas, dimensions) as addressable shapes — read text/category/position, reposition them, hide/show individually (independent of category-level hides).
|
|
41
|
+
- **`presentation.placedViews` — generic canvas shapes** (`listShapes` / `getShape` / `moveShape` / `resizeShape` / `deleteShapes` / `setOpacity` / `setMask`): every top-level Present-canvas shape — AI-generated outputs, placed diagram images, plugin shapes, annotations — addressable by id with an `origin` classification. Previously `aiInspiration.generate` and `diagrams.place` returned shape ids nothing could act on. `deleteShapes` is atomic (any rejected id deletes nothing), protects sheets (use `sheets.delete`) and user-drawn annotations, and closes the placed-view no-delete gap. `setOpacity` is the whole-shape slider; `setMask` toggles context-building masking on views.
|
|
42
|
+
- **`presentation.sheets.setMargin(sheetId, margin)`** — set a sheet's print margin to one of the canonical unit-agnostic presets `0 | 0.25 | 0.5 | 0.75 | 1` (displayed None / 1/4″ / 1/2″ / 3/4″ / 1″ on imperial projects, None / 5mm / 10mm / 15mm / 20mm on metric) — the sheet header's margin dropdown; one undo step. Sheet reads (`list`/`get`) now report `margin` (`null` when absent/unrecognized).
|
|
43
|
+
- **`presentation.placedViews.setRotation(shapeId, rotation)`** — set a placed view's **absolute** rotation in radians (tldraw convention) about its bounds center (the UI rotation handle's pivot); one undo step. Angles are canonicalized into `[0, 2π)`, so the round-trip with the record's `rotation` read is exact only in that range (`setRotation(-0.1)` reads back `2π − 0.1`). **3D placed views only** — 2D/site-plan views cannot rotate (the canvas reverts any rotation applied to them) and are refused with a typed `PRECONDITION_FAILED`. Joins the absolute-setter family (`setScale`/`setCrop`/`setOpacity`/`setMask`).
|
|
44
|
+
- **`presentation.placedViews.rotateShape(shapeId, rotation)`** — the same absolute center-pivot rotation for any top-level Present-canvas shape (AI outputs, diagram images, plugin shapes, annotations — placed views too); targets and refusals mirror `moveShape`. Same `[0, 2π)` canonicalization (exact round-trip only in that range), and a placed view passed here falls under the same 3D-only rule — 2D/site-plan views refuse with a typed `PRECONDITION_FAILED`.
|
|
45
|
+
- **`presentation.tables.place(sheetId, { rows }, options?)`** — new `tables` namespace: place plain string rows as a table shape on a sheet (the same shape the Present canvas creates when a Program-mode / Google Sheets / Excel table is pasted). Rows may be ragged, capped at 10000 cells total; `options.position` is sheet-local like `annotate.*` (default: the paste flow's viewport-center auto-placement); returns the created shape as a canvas-shape record; one undo step.
|
|
46
|
+
- **`presentation.slideshow`** (`start` / `stop` / `getState`) — new namespace: run the Present-mode slideshow programmatically. The slideshow plays **all** sheets in order; `start` options only pick the opening slide (`startIndex` wins over a single-entry `sheetIds`, clamped into range). Browsers grant fullscreen only on a user gesture, so a plugin-triggered `start` typically runs **non-fullscreen** (the rejection is caught). `start`/`stop` are write-gated; `getState` is a never-throw read (`running` + current `index`, `null` when not running). No `next`/`prev`/`goTo` — slide navigation stays with the user.
|
|
47
|
+
- **`workspace.openPresentMode()` / `closePresentMode()`** — open/close the Present-mode documentation editor. `openPresentMode` resolves only once the Present canvas has mounted (up to ~15s, then a typed `PRECONDITION_FAILED`), so follow-up `presentation.*` calls find Present mode open; both are idempotent and **write-gated** (a mode switch under the user's feet is approval-controlled by design). Overlaps `core.mode.set("present")`/`set("design")` but adds the mount-await + idempotency contract.
|
|
48
|
+
- **`presentation.diagrams.generateSite(options?)`** — run the site-diagram auto-generation (location / streetview / climate sheets from the map terrain) and return the created `sheetIds`. `options.types` selects a subset (default all three); generation is tracked per-proposal — already-generated types are **skipped, not duplicated** (mount-time-flow semantics; existing site-diagram sheets are never replaced), so `sheetIds` can be empty. Requires Present mode and a map terrain.
|
|
49
|
+
- **`presentation.annotate.text` typography** — the existing text args gain optional `fontFamily` (system family or any Google Font, loaded automatically — the Present text panel's loader), `fontWeight` (numeric string like `"400"`/`"700"`, `-italic` suffix allowed; unavailable weights fall back to regular), and `fontSizePx` (exact pixel size overriding the `size` preset — `size` alone keeps working). Existing calls are unaffected.
|
|
50
|
+
- **`program.site.listEdges()`** — read each site parcel's boundary edges with their **front / side / rear** classification: the exact resolution the buildable-envelope setback pills show on canvas (user per-edge overrides win over the tangent heuristic; `roleSource` says which applied), so a plugin picks up the user's edge tagging without asking them to set it up again. Per edge: canonical `edgeIndex` (the envelope `edgeOverrides` index space), endpoints and length in **world meters** (`lengthUnit: "m"` — unlike `listPolygons`' Snaptrude-unit footprints), and the **effective base setback** (per-edge exception, else the role value; `null` for parcels with no zoning envelope — those still classify by heuristic). Entries also report the linked `buildableEnvelopeId` and whether stale index-misaligned overrides were dropped. Never throws; `"street"` resolves to `front`.
|
|
51
|
+
|
|
52
|
+
## 0.9.0
|
|
53
|
+
|
|
54
|
+
### Minor Changes
|
|
55
|
+
|
|
56
|
+
- Plugin API 0.9.0 — namespace reorganization (deprecate-in-place, nothing breaks), the analysis wave, and the spreadsheet data lane.
|
|
57
|
+
- **Namespace map** — `entity.*` retired via aliases (storeys → `core.storeys`, reference lines / buildable envelopes → `design.*`), `core.zoom` → `core.camera`, `core.tags.getTagsForComponent` → `core.tags.listForComponent`, new `workspace.*` (projects/teams) and `core.mode` top-levels. Every deprecated path still works and delegates to its canonical implementation.
|
|
58
|
+
- **Analysis wave** — `analysis.weather.getSeries` (hourly EPW rows + station metadata + quality flags), `analysis.solar.sampleGrid` (per-point GPU-raytraced visibility/shade/SVF/irradiance), `analysis.daylight.compute` (LM-83 numeric ASE + sDA with full provenance — see the sDA entry below), `program.site.getWeather`/`getTimezone`, `.epw` import + project weather override via `core.io.import`.
|
|
59
|
+
- **sDA (LM-83 Spatial Daylight Autonomy)** — `analysis.daylight` now computes real sDA300/50% with dynamic blind operation (LM-83 2% rule, 5% diffuse closed-blind default) via Radiance. Runs including `"sDA"` are asynchronous: `compute` returns `{ status: "running", runId }` and the new `analysis.daylight.poll({ runId, cursor? })` fetches results; ASE-only runs stay synchronous and unchanged. New optional `optics` arg overrides surface optics per material (keyed by Snaptrude material name) or per category, over LM-83/convention defaults (wall 0.5 / ceiling 0.7 / floor 0.2 / furniture 0.5 / glazing Tvis 0.65 / context 0.2); glazing takes visible transmittance (Tvis), converted to Radiance transmissivity backend-side. Sensor records gain `da300Percent`/`sdaPass`, aggregates gain `sdaPercent`, results gain `runId`, and the ASE fields (`directSunHoursAtOrAbove1000Lux`/`aseFail`/`asePercent`) are now optional — present when ASE is requested.
|
|
60
|
+
- **Heatmaps** — named overlays (up to 16, `analysis.heatmaps.overlays.*`), `renderField` arbitrary cell geometry, `renderSurfaceGrid` façade grids, discrete/threshold/categorical scales, hover tooltips.
|
|
61
|
+
- **Geometry reads** — `design.query.geometry.getTriangulatedMeshes` (world-space triangles, optional per-triangle `materialIds` and B-rep `faceIds`), `design.query.spaces.getEnclosure` (geometric v1).
|
|
62
|
+
- **Spreadsheet data lane** — `program.spreadsheet.datasets.{set, list}` (plugin datasets, upsert + auto-refresh of bound ranges), binding `source` widened to `{ dataset: "takeoff" } | { dataset: "plugin", name }` (takeoff unchanged), `addImage` (data-URI floating pictures, stable-name replace-on-rerun), `addChart` accepts the ratified `"column"`/`"bar"` enum on the wire.
|
|
63
|
+
- **Presentation** — `presentation.shapes` keyed shape lifecycle on Present sheets (`upsert`/`remove`/`removeAll`/`list`).
|
|
64
|
+
- **Constructive geometry (brep kernel)** — the full `core.geom.create.brepFrom*` constructor family minting `BrepHandle`s at authored coordinates: `brepFromFaces` (plain face-point loops; host validates welding, planarity, edge coherence and fixes global orientation), `brepFromExtrusion` (prisms along any direction, holes + arc profiles), `brepFromLoft` (tapered solids between two contours; lofts producing non-planar side faces are rejected), `brepFromMesh` (indexed vertex + face-index input), and the OpenCascade booleans `brepFromUnion` / `brepFromSubtraction` (`a` minus `b`) / `brepFromIntersection` (scene-derived `getBrep` handles accepted as read-only inputs; empty/disjoint results throw typed VALIDATION).
|
|
65
|
+
- **`design.create.massFromBrep(brep, label?)`** — commit a mass from any `core.geom.create` brep constructor's handle (scene-derived breps stay read-only): generic mass at authored coordinates, single undo step, collab-synced.
|
|
66
|
+
- **`presentation.placedViews`** — layout control over placed views (`list`/`get`/`move`/`scale`/`setScale`/`setCrop`): sheet-local position, size, architectural scale, rotation, crop and link state; uniform corner-drag-equivalent `scale`, Scale-dropdown `setScale` (2D only), native crop fractions with page-anchored visible region — crop survives `sheets.updatePlacedView` refreshes.
|
|
67
|
+
|
|
68
|
+
## 0.8.0
|
|
69
|
+
|
|
70
|
+
### Minor Changes
|
|
71
|
+
|
|
72
|
+
- More additions to the APIs, infra changes.
|
|
73
|
+
- Plugin API 0.8.0 — the 0.8 API wave, handle lifecycle, events, and geometry/data-integrity fixes.
|
|
74
|
+
- **The 0.8 API wave** — model/presentation **export** (`core.io.export`, `presentation.export`), **element editing** widenings on `design.update`/`design.edit`, **`core.camera.*`**, **storey management**, **`design.visibility.*`**, **dimensions**, **locale/user** reads (`core.user`), `design.types.list`, presentation annotate, plus completeness widenings across existing families. The discovery manifest grows from 423 to 595 method paths (including the new `core.handles.*` lifecycle below).
|
|
75
|
+
- **Events** — `model:changed` subscription contract: debounced model-change notifications delivered to the plugin worker for user and plugin edits alike (client API: `PluginWorker.subscribe`). `selection:changed`, `tool:activated`, `project:saved`, `view:changed` are reserved names, not yet emitted.
|
|
76
|
+
- **BREAKING — `program.site` footprints are world Snaptrude units.** Previously the only plan-geometry read scaled to scene metres (×0.254), so site parcels could not be overlaid on `planPoints`. Now the same world XZ plan space as every other plan read; areas and the geographic reads are unchanged.
|
|
77
|
+
- **BREAKING — real beam/column geometry.** `design.create.beam` with a horizontal direction (the documented canonical call) used to build a zero-height flat sheet; it now builds a true beam with tool-parity semantics (section X extent = width, Z extent = depth, body hangs below the authoring plane by its depth). `design.create.column` builds exactly the requested height (the silent slab-thickness deduction is gone). Degenerate extrusions (zero/diagonal/in-plane directions, zero height) throw VALIDATION errors instead of silently building corrupt solids; directions are normalized.
|
|
78
|
+
- **Data integrity** — `design.query.list*` no longer returns engine-internal shells (originals parked by instance copies, disposed phantoms), so one copy no longer doubles `listSpaces`/schedules; `design.delete.entities` orders instance copies before their source meshes so mixed batches cannot fail midway; `design.update.wall` documents that rebuilds replace the wall — re-bind from `affected[0]`.
|
|
79
|
+
- **Handle lifecycle (`core.handles.*`) + GC-backed `Handle` objects** — `Handle` is now a class wrapping the wire id (public type names unchanged): `handle.id`, `toString()` stays the bare id, `equals()` compares by id, and `toJSON()` emits the `{__h: id}` wire tag — `JSON.stringify` output containing handles changes shape. New namespace: `core.handles.release(handles[])` (batched, arena-agnostic, silent no-op on unknown/released ids), `core.handles.releaseAll(kind?)`, mint-recording scopes `beginScope()` / `endScope(scope, retain?)` (token-addressed, retain promotes to the enclosing scope), and `core.handles.stats()`. The client runs a FinalizationRegistry-backed auto-release queue, so unreferenced handles are reclaimed host-side without explicit code. `core.geom.delete.profile/contour` are retained as deprecated aliases of `core.handles.release`. Entity-style kinds (component/material/underlay/terrain/importJob) remain branded strings.
|
|
80
|
+
|
|
81
|
+
## 0.7.1
|
|
4
82
|
|
|
5
83
|
### Patch Changes
|
|
6
84
|
|
|
@@ -8,6 +86,79 @@
|
|
|
8
86
|
- New methods: `getModelCapabilities`, `getSelection`, `getPresetCatalog`, `getJob`, `cancelJob`, `listJobs`, `getWorkflowForShape`, `getSelectedBranchRerunPlan`, `rerunSelectedBranch`, `extractRecipeFromShape`, `listRecipes`, `saveRecipe`, `deleteRecipe`, `runRecipe` (plus job/workflow/recipe Zod schemas).
|
|
9
87
|
- `generate`/`refine` (and `rerunSelectedBranch`/`runRecipe`) accept `runMode: "blocking" | "job"`; `PluginAIInspirationRunResult` is accordingly loosened to `{ jobId?, output?, outputs?, metadata? }` — job-mode calls resolve with a `jobId` instead of outputs.
|
|
10
88
|
|
|
89
|
+
## 0.7.0
|
|
90
|
+
|
|
91
|
+
### Minor Changes
|
|
92
|
+
|
|
93
|
+
- e1915e4: Plugin API 0.7.0 — new families and methods (supersedes the cancelled `design.update.setLabel` 0.6.1 patch, now folded in).
|
|
94
|
+
- **`core.proposals.*`** — design options as infrastructure: `list` / `get` / `getActive` / `listForComponent` / `isActive` (reads) plus `create` / `rename` / `setActive` / `delete` (non-undoable writes).
|
|
95
|
+
- **`program.layout.*`** — the space-solver promoted to a real async-job family: `arrange` / `pack` now start a backend job and return immediately, with `getState` (poll) and `cancel`.
|
|
96
|
+
- **Door & window catalogs + placement** — `design.doors.*` / `design.windows.*` gain `listCatalogGroups` / `listCatalog` / `getCatalogItem` / `exists` (shared catalog DTOs), and `design.create.door` / `design.create.window` place a catalog item into a host wall.
|
|
97
|
+
- **`design.create.smartLayout`** — clone an in-scene template cluster into one or more target spaces in a single undo batch.
|
|
98
|
+
- **Furniture categories** — `design.furniture.listCategories` plus a `category` filter on `listCatalog`, and `thumbnailUrl` on catalog items.
|
|
99
|
+
- **`design.transform.align`** — snap components' bounding-box edges (left/right/center/top/bottom/middle), optionally to a reference.
|
|
100
|
+
- **Per-face materials** — `design.materials.applyToFaces` / `resetFaces` / `getByFace` / `listByFace` (BREP faces by durable index, visual-only).
|
|
101
|
+
- **Staircase params** — `design.query.getStaircaseParams` (read) and `design.update.staircase` (sparse parametric write).
|
|
102
|
+
- **Footprint-area lock** — `design.lockArea` / `unlockArea` / `isAreaLocked` / `listAreaLocked` for Room/Department spaces.
|
|
103
|
+
- **`entity.story.duplicate`** — duplicate a storey (or a subset) up/down, auto-creating the target storey.
|
|
104
|
+
- **`presentation.import.svg`** — import a guaranteed-vector SVG onto the Present sheet.
|
|
105
|
+
- **View display settings** — `presentation.views.getSettings` / `updateSettings` (background, color mode, axis, edges, labels).
|
|
106
|
+
- **`design.update.setLabel`** — set any component's panel Label (write pair of `design.query.getLabel`); undoable, lock-aware, validated.
|
|
107
|
+
- **`program.areas`** — area members now report their `areaClass` (`NET` / `GROSS` / `EXCLUDED`), with net/gross documented as the plain-English synonyms for carpet/built-up.
|
|
108
|
+
- **Typed plugin API errors** — every host failure now crosses the wire as a structured envelope instead of a flattened `Execution error: <msg>` string: a stable `code` from the shared plugin-core error registry, the offending handle, an authored `hint`, and `retryAfterMs` / `didYouMean` enrichment where applicable. Zod validation failures forward the first 10 issues, each projected to `{path, code, message}` (full count in `details.issueCount`); internal faults are sanitized and host-logged under an `errorId`. Every handler across the API surface now throws typed codes, each doc page gained an Errors section, and a drift test pins thrown code literals to the registry.
|
|
109
|
+
|
|
110
|
+
## 0.6.0
|
|
111
|
+
|
|
112
|
+
### Minor Changes
|
|
113
|
+
|
|
114
|
+
- 934405e: New `analysis.heatmaps` family — render plugin-computed scalar data as a
|
|
115
|
+
heatmap: `renderSpaces` (flat colour per space top face), `renderGrid`
|
|
116
|
+
(coloured grid mesh from world-coordinate samples), `reset`, `isActive`.
|
|
117
|
+
Single active heatmap (a render replaces the previous one); values outside
|
|
118
|
+
`[min, max]` clamp to the end colours; ephemeral (auto-cleared on
|
|
119
|
+
scene-mutating edits, never persisted). The react host has landed, so all
|
|
120
|
+
members are required `abstract` and in the discovery manifest.
|
|
121
|
+
- a68e866: New top-level `analysis` namespace:
|
|
122
|
+
`analysis.sunpath` (enable/disable/isActive), `analysis.shadows`
|
|
123
|
+
(enable/disable/isEnabled/setDateTime/getDateTime — ISO date-time strings),
|
|
124
|
+
and the async heatmap job families `analysis.sunlightHours` and
|
|
125
|
+
`analysis.illuminance` (compute/get/cancel/reset; illuminance is Pro-gated).
|
|
126
|
+
Also extends `program.site` with `getLocation()` and `getNorthAngle()` geo
|
|
127
|
+
reads. The react host has landed, so all new members are required `abstract`
|
|
128
|
+
and in the discovery manifest; the plugin-client mounts the `analysis` RPC
|
|
129
|
+
namespace.
|
|
130
|
+
- New `core.io` namespace — file import, import jobs, and underlay/terrain
|
|
131
|
+
management:
|
|
132
|
+
- `core.io.import` — bring external files onto a storey: `image`, `pdf`
|
|
133
|
+
(page-selectable), `dwg`, `cadJson` (parsed CAD geometry as a sketch),
|
|
134
|
+
`model` (3D formats), and `terrain` (map snapshot at a lat/lng with
|
|
135
|
+
optional elevation). Slow formats return an `ImportJobHandle` instead of
|
|
136
|
+
blocking.
|
|
137
|
+
- `core.io.job` — poll those imports: `getStatus`, `isComplete`, `getResult`,
|
|
138
|
+
`getError`.
|
|
139
|
+
- `core.io.query` — pre-import inspection: `getPdfPageCount`,
|
|
140
|
+
`listCadLayers`.
|
|
141
|
+
- `core.io.underlay` — manage imported image/PDF/CAD underlays: `list`,
|
|
142
|
+
`getBounds`, `getScale`/`setScale`/`resetScale`, `getOpacity`/`setOpacity`,
|
|
143
|
+
`delete`.
|
|
144
|
+
- `core.io.terrain` — manage the imported map terrain: `exists`, `get`,
|
|
145
|
+
`getDatum` (current vertical position, world Y) / `setDatum` (relative
|
|
146
|
+
datum shift, not an absolute elevation), `delete`, `getReport`, elevation and satellite-imagery toggles
|
|
147
|
+
(`isElevationEnabled`/`enableElevation`/`disableElevation`,
|
|
148
|
+
`isSatelliteEnabled`/`enableSatellite`/`disableSatellite`), and
|
|
149
|
+
`getOpacity`/`setOpacity`.
|
|
150
|
+
|
|
151
|
+
- New `design.selection.setByFilter(filter)` — the programmatic equivalent of
|
|
152
|
+
the editor's **Story selection** and **Filter selection** menus. Replaces the
|
|
153
|
+
selection with every visible entity of the active building matching
|
|
154
|
+
`{ storeys?: number[], types?: PluginSelectionEntityType[] }` (fields AND,
|
|
155
|
+
values within a field OR; at least one field required — use `clear()` to
|
|
156
|
+
deselect). The new `PluginSelectionEntityType` vocabulary covers all 24 menu
|
|
157
|
+
kinds, including selection-only kinds the query surface can't reach (sites,
|
|
158
|
+
terrain, CAD/PDF/image imports, dimension lines, 3D models, neighborhood
|
|
159
|
+
buildings, program blocks). One-shot bulk select, not a persistent mode; not
|
|
160
|
+
undoable, like the other selection mutators.
|
|
161
|
+
|
|
11
162
|
## 0.5.0
|
|
12
163
|
|
|
13
164
|
### Minor Changes
|