Skip to main content

Sparkline Columns

FdcSparklineColumn renders compact inline charts from fields in the same row.

FdcSparklineColumn(
label: 'Quarterly Sales',
width: 220,
fields: const [
FdcSparklineField(fieldName: 'q1'),
FdcSparklineField(fieldName: 'q2'),
FdcSparklineField(fieldName: 'q3'),
FdcSparklineField(fieldName: 'q4'),
],
type: FdcSparklineType.line,
highlightMin: true,
highlightMax: true,
highlightLast: true,
)

Sparkline columns are read-only visual columns. Sorting and header filtering are intentionally disabled because the chart represents a sequence rather than one scalar cell value.

Domain controls

Use fixed bounds when rows must share the same visual scale:

FdcSparklineColumn(
fields: salesFields,
min: 0,
max: 100000,
includeZero: true,
showZeroLine: true,
)

For automatic domains, omit min and max.

Tooltips and accessibility

Tooltips are enabled by default. Applications can provide tooltipBuilder and semanticsLabelBuilder for domain-specific text.