Tally

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/button-tally

About this component

A heads-up display upvote: a dark glass plate with cyan corner brackets, an arrow and a count in mono digits. Pressing it fires the arrow upward, rolls the count up by one and turns the display amber. Press again to take the vote back.

Triggers

  • Click
  • State change
  • Icon
  • Ambient

Techniques

  • CSS variables
  • Transform only
  • CSS transition
  • Keyframes

Difficulty

Intermediate

Accessibility

Keyboard and screen readers

A native toggle button with aria-pressed; its aria-label carries the count ("Upvote, 129 votes") and the drawn label and digits are aria-hidden.

Reduced motion

The count and colour change at once.

Use it in anything you build, commercial and client work included. Licence

More buttons

See all
TankGet code
TerrazzoGet code
TorchGet code
TraceGet code