Skip to content

Interface: RectData ​

Experimental

Data accepted by RectPrimitive. Coordinates are in data space; sizes in CSS px.

Properties ​

PropertyTypeDescription
borderAlignRectBorderAlignExperimental Default 'inside'.
borderColorColorInputExperimental sRGB RGBA border color. Default transparent.
borderWidthScalarInputExperimental Border width in CSS px. Default 0.
cornerRadiusScalarInputExperimental Corner radius in CSS px, clamped to half the smaller side. Default 0.
depthScalarInputExperimental Reserved for extrusion (plan E8.9); currently ignored.
fillColorInputExperimental sRGB RGBA fill. Default opaque mid-grey.
items?ArrayLike<number>Experimental The item each rect stands for (e.g. a treemap tile's node), for the 2.5D view of domain traces (extrusion-domain.ts: per-item depth). Ignored when drawing.
opacitynumberExperimental Multiplies every color's alpha. Default 1.
patternPatternFill | nullExperimental Pattern fills per rect (plan E8.10), or null (the default) for plain fills.
snapbooleanExperimental Snap edges to device pixels for crisp 1 px borders (2D). Default false.
x0NumericArrayExperimental Corner coordinates (data space). Float64Array preferred. The count is the shortest array.
x1NumericArrayExperimental
y0NumericArrayExperimental
y1NumericArrayExperimental
z?NumericArrayExperimental Plane z per rect, for 3D scenes (data space). Default 0.

Released under the MIT License.