Skip to main content

Rating Column

PRO
Pro preview

This feature is part of FD Components Pro, which is documented as a preview and is not publicly available yet. See Editions and Availability.

FdcRatingColumn is a Pro column that renders numeric values as editable rating icons. It supports both whole-step and half-step rating workflows.

Use it when a bounded qualitative score is easier to scan and edit visually than as raw text, such as satisfaction, quality, risk, or priority. Use a regular integer or decimal column when exact numeric comparison is the primary task.

Rating column sample
Loading FDC sample…
FdcGrid(
dataSet: featureRows,
options: const FdcGridOptions(autoEdit: true),
columns: [
const FdcTextColumn(fieldName: 'feature', width: 180),
FdcRatingColumn(
fieldName: 'ease_of_use',
width: 132,
maxRating: 5,
showIndicator: false,
style: FdcRatingStyle(filledColor: Color(0xFFEAB308)),
),
FdcRatingColumn(
fieldName: 'satisfaction',
width: 168,
maxRating: 5,
showIndicator: false,
step: FdcRatingStep.half,
style: FdcRatingStyle(
filledIcon: Icons.favorite_rounded,
emptyIcon: Icons.favorite_border_rounded,
filledColor: Color(0xFFDB2777),
),
),
FdcRatingColumn(
fieldName: 'coverage_score',
width: 220,
maxRating: 10,
showIndicator: false,
style: FdcRatingStyle(
filledIcon: Icons.circle,
emptyIcon: Icons.circle_outlined,
filledColor: Color(0xFF2563EB),
iconSize: 14,
spacing: 1.5,
),
),
],
);

Key characteristics​

  • Pro-only column type.
  • Supports FdcRatingStep.whole and FdcRatingStep.half.
  • Uses FdcIntegerField for whole ratings and FdcDecimalField for half-step ratings.
  • Supports maxRating, minRating, and FdcRatingStyle customization.

Example​

FdcRatingColumn(
fieldName: 'satisfaction',
maxRating: 5,
step: FdcRatingStep.half,
)

Field compatibility​

Whole-step ratings require an FdcIntegerField. Half-step ratings require an FdcDecimalField, and selected half values are stored as FdcDecimal rather than binary floating-point values.

minRating must align with the selected step, cannot be negative, and cannot exceed maxRating. A whole-step minimum must be an integer; a half-step minimum must align to 0.5 increments.

Editing and filtering behavior​

Pointer interaction selects values between minRating and maxRating. With the default minimum of zero, selecting the already active first step can clear the rating back to zero. A positive minimum prevents pointer interaction from clearing below that value.

The default header filter is a non-searchable list built from the configured range and step. It supports in-list, not-in-list, equality, inequality, and null checks. Set an explicit filterConfig only when the domain needs a different policy.

Use FdcRatingStyle to customize filled and empty icons, size, spacing, and colors. Keep the column wide enough for maxRating icons; unusually high ranges are often clearer as a numeric or progress column.