5 of 20 · sets in 8 s · Enter pours a new slab
Candy heart
7 of 14 · Enter boxes it
Markup where the component goes, CSS in your stylesheet, script before </body>. In Vue, Svelte or Angular, call initFieldCandyHeart(el) on the mounted element instead.
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/input-candy-heartAbout this component
A message stamped on a conversation heart: each letter is pressed into the chalky sugar with a dip of the heart, a long message squeezes onto two lines, and Enter tumbles the heart into the box and slides in a blank one.
- Dependencies
- None
- Difficulty
- Intermediate
- Reduced motion
- Respected
- Theme
- Light and dark
- Follows page color-scheme
Triggers3
- State change
- Click
- Spring
Techniques4
- clip-path
- Keyframes
- Radial gradient
- State machine
Accessibility
Keyboard and screen readers
One native input named "Message on the candy heart"; the tray is aria-hidden and the count, the boxing and any refusal are announced.
Reduced motion
The heart swaps without tumbling.
Use it in anything you build, commercial and client work included. Licence
More inputs
See all27 of 44 · the first letter is illuminated
5 of 8 · hard enamel, gold plate
5 of 10 · Enter varnishes it