Model - Graph extras
API reference for src/schema/graphExtras on @huukhanhnguyen/model, reachable from ..
See the Guide for the ModelJSON / evaluate pipeline.
API reference
Signatures are generated from the live package .d.ts - not hand-written.
ViewValue
type
One views[] entry resolved: the drawing it produced and the rectangle that bounds it. Model.evaluateView returns it inside the shared envelope, Resolved<ViewValue> — there is no ResolvedView alias, because an alias of a generic instantiation is a second name for one shape.
A view is the other BOUNDED space beside a sheet, and its bound is a BOX: the crop floats in the view plane, so both corners carry information. (A sheet's bound is a SIZE — the paper's corner is the origin — which is why SheetValue carries width/height instead.)
type ViewValue
// = {
/** View-plane drawing entities (u,v,0), y-up, model mm. */
entities: ViewEntities;
/** Either the head's declared `window`, or the bounds of what actually
* drew. Width and height are `maxX - minX` / `maxY - minY`: they used to
* be stored beside the corners, six fields carrying four facts. */
extent: BoundingBox2d;
}