Annotation

entity

Sticky-note canvas annotation. Constructed via Annotation(...) and chained with the field setters. Annotations sit on the flow's Metadata.Annotations[] array.

Factories

Annotation

Annotation() -> Annotation

Construct a fresh annotation with an auto-generated id.

Annotation

Annotation(id: String) -> Annotation

Construct an annotation pinned to a specific id.

ParameterTypeRequiredDescription
idStringyesOperator-supplied annotation identifier (typically a UUID).

Methods

kind

kind(value: String) -> Annotation

Set the annotation kind.

ParameterTypeRequiredDescription
valueStringyesAnnotation kind. Connect emits "default" today.

content

content(value: String) -> Annotation

Set the annotation's text.

ParameterTypeRequiredDescription
valueStringyesAnnotation body text.

action_id

action_id(target: Handle | String) -> Annotation

Tie the annotation to a specific block. Pass "" for a free-floating annotation.

ParameterTypeRequiredDescription
targetHandle | StringyesBlock handle (preferred) or wire identifier this annotation documents.

position

position(x: Number, y: Number) -> Annotation

Set the annotation's canvas position.

ParameterTypeRequiredDescription
xNumberyesCanvas X. Floats accepted; integers preferred where possible.
yNumberyesCanvas Y.

size

size(height: i64, width: i64) -> Annotation

Set the annotation box's dimensions.

ParameterTypeRequiredDescription
heighti64yesAnnotation box height in pixels.
widthi64yesAnnotation box width in pixels.

folded

folded(value: bool) -> Annotation

Toggle the folded UI state.

ParameterTypeRequiredDescription
valueboolyesTrue when the operator has collapsed the annotation in the console.