Quaff

QBadge

Badges highlight notifications, counts, or status beside related content. Display a dot for a simple signal, or a number or short label.

THE TOOLSHED

Lending updates

Unread requests3
New arrivals
Precision driver setNEW
info QBadge API Source

interface QBadgeProps extends HTMLAttributes<HTMLSpanElement>

floating
?: boolean = false
Anchors the badge to the top trailing edge of a positioned icon wrapper.

label
?: string | number = undefined
Count or short status. Negative numbers display as 0; numbers above 999 as 999+. Keep text to four characters.

Usage

Floating Counts and Dots
Place a floating badge inside a positioned icon wrapper. Empty badges show a dot; label adds a count. Review a notification to clear its badge, or add a request to increase the count. Use dots when a count would crowd nearby controls.
THE TOOLSHED

Lending notifications

Show unread counts

3 unread requests and one new arrival.

Counts Alongside Text
Inline badges sit beside a label without covering it. Numeric labels display zero for negative numbers and cap at 999+. Keep the full count in the accessible name. Switch the report to try these boundaries.

Tools, used again

1,200 loans in this report

999+
Short Status Labels
Use label or the default snippet for short text, ideally four characters or fewer. Keep longer information alongside the badge. Badges communicate status; actions belong on their associated buttons or links.

Precision driver set

NEW

Available on shelf B.

For an icon button, connect the badge with aria-describedby and give dots a meaningful description. The desk example hides the badge from separate announcement while keeping it as the button's description. A changing count can also be summarized in a nearby role="status" message.