Groovy

Mood
No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/radio-groovy

About this component

A seventies mood picker: Mellow, Groovy and Funky as fat outlined pills on a cream panel, each with a daisy for its radio. The pill you pick floods with its colour, retro rainbow stripes slide in at its end, and its daisy blooms and turns.

Triggers

  • Click
  • State change
  • Fill
  • Spring
  • Loop

Techniques

  • clip-path
  • SVG
  • Keyframes
  • CSS transition
  • CSS variables

Difficulty

Intermediate

Accessibility

Keyboard and screen readers

Native radios in a fieldset with a visually hidden legend ("Mood"), each in a <label> with its visible name (Mellow, Groovy, Funky); the daisies and stripes are aria-hidden. :focus-visible outlines the pill.

Reduced motion

The flood, stripes and bloom are switched off and the picked pill is shown coloured at once.

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

More radios

See all
Cover photo
LightboxGet code
How much do you agree?
AgreeGet code
Pattern
Op-artGet code
Reaction
ReactionGet code