Documentation / @ripl/charts / SegmentLabelLayout
Interface: SegmentLabelLayout
Defined in: charts/src/core/labels.ts:256
Fully resolved layout for a segment label: placement, content, styling, and leader-line points.
Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
connector | Point[] | Leader-line points; always ≥2 (a degenerate line at the anchor when hidden/inside). | charts/src/core/labels.ts:274 |
content | string | Text content, or '' when hidden. | charts/src/core/labels.ts:260 |
fill | string | Colour of the label text. | charts/src/core/labels.ts:270 |
font? | string | CSS font shorthand for the label text (falls back to the shared segment-label font). | charts/src/core/labels.ts:272 |
showConnector | boolean | Whether the leader line should be shown (visible outside labels only). | charts/src/core/labels.ts:276 |
textAlign | TextAlignment | undefined | Horizontal text alignment for the label. | charts/src/core/labels.ts:266 |
textBaseline | TextBaseline | undefined | Vertical text baseline for the label. | charts/src/core/labels.ts:268 |
visible | boolean | Whether the label should be shown (respects labels.visible and the min-angle guard). | charts/src/core/labels.ts:258 |
x | number | Label anchor x coordinate, in chart pixels. | charts/src/core/labels.ts:262 |
y | number | Label anchor y coordinate, in chart pixels. | charts/src/core/labels.ts:264 |