Status
Meter
A meter shows how much of a known total is done or used, such as focus minutes against the day's goal, items done or each person's share in a project.
In kanso-ui as Meter
Accessibility
- One value:
role="progressbar"on the meter,aria-labelledbyits label,aria-valuemin,aria-valuemax,aria-valuenow, andaria-valuetextin words ("2 of 4 done, 1 late"). ARIA'smeterrole is closer in meaning, but screen readers announce it unevenly. - Two values, such as shares against a target:
role="img"with the whole sentence inaria-label. - Contrast: the
accentfill is 7.3:1 on paper in light and 9.0:1 in dark, and 6.3:1 and 6.8:1 on thecontainertrack (computed from the tokens). Theinkfill is 14.3:1 and 12.0:1 on the track; anon-inkmarker on it 16.7:1 and 15.9:1. - "1 late" in
cautionis 4.6:1 on paper and 4.8:1 on surface in light, 11.0:1 and 10.0:1 in dark: keep it on paper or surface. - Motion: the fill does not animate. A product that animates a change stops it under
prefers-reduced-motion.