Reaction
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-reactionAbout this component
A reaction picker in a floating pill: Like, Love, Cheer and Insight. The one you pick fills with its own colour, its icon springs up in white and a ring of two-colour sparks bursts out round it once.
Triggers
- Click
- State change
- Spring
- Icon
- Keyframe
Techniques
- Pseudo elements
- Keyframes
- CSS variables
- SVG
- Radial gradient
Difficulty
Intermediate
Accessibility
Keyboard and screen readers
Native radios in a fieldset with a visually hidden legend ("Reaction"), each in a <label> with its visible name (Like, Love, Cheer, Insight); the faces and sparks are aria-hidden. :focus-visible outlines the face.
Reduced motion
The pop, ring and sparks are switched off and the picked face is shown filled at once.
Use it in anything you build, commercial and client work included. Licence