Skip to content
This is the alpha v4 version website. Looking for the v3 documentation?

EdgeLabelColorSpecification

EdgeLabelColorSpecification = string | { attribute: string; color?: string; } | { attribute?: undefined; color: string; }

Defined in: packages/sigma/src/rendering/edges/types.ts:436

Color specification for edge labels - either a fixed color string or attribute-based.

This type follows the same pattern as settings.edgeLabelColor:

  • Fixed color: "#ff0000" or { color: "#ff0000" }
  • Attribute-based: { attribute: "labelColor" } with optional fallback color

Examples:

  • "#ff0000" - Fixed red color
  • { attribute: "labelColor" } - Read from edge attribute
  • { attribute: "labelColor", color: "#000" } - Attribute with fallback