Skip to content
Shapemetry

Model - Annotation styles

API reference for src/lanes/annotationStyles/annotationStyles 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.

ANNOTATION_STYLE_METHOD

const

annotationStyles lane — evaluation of annotationStyle nodes into resolved AnnotationStyle records (the DIMSTYLE half of the split described in schema/lanes.ts and types' textStyle.ts).

Same lane shape as textStyles next door. Every field but name and textStyle is optional: absent means "the drawn form leaves that part out" (arrowSize 0 = no arrowheads), which is a real answer, not a guess.

const ANNOTATION_STYLE_METHOD: "annotationStyle"

collectAnnotationStyles

function

Evaluate every annotationStyles[] node on the scope.

collectAnnotationStyles(scope: ModelScope): AnnotationStyle[]

evaluateAnnotationStyleNode

function

Evaluate one annotationStyle node. Null when the name cannot be resolved.

evaluateAnnotationStyleNode(node: Operation, context: ReturnType<typeof laneParameterContext>, namespaces?: Record<string, unknown>): AnnotationStyle | null

isAnnotationStyleNode

function

isAnnotationStyleNode(node: (Operation | Container)): node is Operation
Last updated: 📖 1 min readEdit on GitHub