CountBadge
Properties
Use CountBadge
A compact count with an optional cap or unread dot.
Design notes
- Use CountBadge for a passive count beside the destination or label it qualifies. It adds no focus stop. Use formatLabel for a localized accessible description.
- The default visual cap is 99. Counts above max display the cap with a plus sign while assistive technology receives the exact count. Use locale to format the digits.
- Zero is hidden by default. Set showZero when an explicit zero is useful. Dot presentation signals a nonzero count in tight spaces and always hides zero.
- Use NavigationItem compactBadge to put an unread dot on a compact navigation control without moving its icon.
API reference
View TypeScript source