Vials
Markup where the component goes, CSS in your stylesheet. No JavaScript.
Paste into Claude, ChatGPT or Cursor after filling in {{USER_STACK}}, {{USER_STYLING}} and {{USER_CONSTRAINTS}}. Neutral keeps the greys you see here; Match my project asks the model to map them onto your own colour tokens.
Install with shadcn
Needs a free account token. Get a token
npx shadcn@latest add @movin/radio-vialsAbout this component
Four test tubes in a rack, each with a little coloured liquid at the bottom. The one you pick fills nearly to the lip and starts to fizz; the last one drains back down.
Triggers
- Click
- State change
- Fill
- Loop
Techniques
- CSS transition
- Keyframes
- Radial gradient
- CSS variables
- Pseudo elements
Difficulty
Intermediate
Accessibility
Keyboard and screen readers
Native radios in a fieldset with a visually hidden legend ("Reagent"), each in a <label> and named by aria-label (Rose, Amber, Mint, Indigo); the tubes and rack are aria-hidden. :focus-visible outlines the tube.
Reduced motion
The fill is instant and the fizz is switched off.
Use it in anything you build, commercial and client work included. Licence