Inputs & Switches
Tag Chips
Colored tag chips auto-fill and remove inside a dark input field with spring pop-in and shrink-out transitions; a blinking cursor mimics live typing.
cssmedium complexitymoderate motionclick
Open on the canvas to copy the code → Free account · 3 copies a day · membership goes unlimited
Worth keeping?
Votes steer what gets built next — sign in to cast one, free to read
When to use it
Demonstrating tag input UIs, filter selectors, or skill/interest pickers in dark-themed product contexts.
When not to
Production tag input without wiring real keyboard entry — auto-cycle is demo-only; remove the rAF loop and add actual input handling before shipping.
Working with an AI agent
Every component ships agent-ready metadata. An example instruction for this one:
Change the word list to ['figma','motion','tailwind','a11y','token'] and update the colors array to use a warm palette: ['#ea580c','#b45309','#15803d','#0f766e','#8C8478']. Theme: dark tokens live in :root, the light variant in :root[data-theme="light"]; ?theme=light or a {type:'forever:theme'} postMessage switches at runtime.
Safe to edit
- word list (words array)
- chip color palette (colors array)
- max chip count before removal (>=7)
- spring pop-in timing (cubic-bezier .2,1.5,.4,1)
- chip font size and padding
- theme tokens (:root dark defaults + [data-theme=light] overrides)
Keep intact
- IIFE wrapper
- prefers-reduced-motion guard (static fallback)
- visibilitychange pause
- cursor element inside field
- theme hook (?theme= bootstrap + forever:theme message listener + theme tokens)
Known limitations
- Auto-cycles via rAF loop — must be replaced with keyboard input handling for real use
- Word list is finite (10 items), so duplicates appear quickly
- No aria roles on chips or remove buttons — needs role=button + aria-label for accessibility
More Inputs & Switches components
- Liquid ToggleSVG toggle with a goo filter — the knob slides with trailing liquid droplets; track color fades between off and on states.
- Glow SliderSVG range slider with a plum-to-teal gradient fill, glowing knob, and a floating value bubble that tracks the handle; auto-oscillates when idle.
- Spring StepperMint-themed +/- stepper with a number reel that springs and overshoots between digits 0–9; auto-cycles as a demo. Dark green palette.
- Segmented ControlSlate-to-sage gradient pill slides between Day/Week/Month/Year segments with elastic spring stretch. Auto-cycles; click pauses briefly.
- Checkbox MorphThree amber rounded checkboxes auto-cycle and respond to clicks; the box fills and a checkmark strokes in via animated dashoffset.
- Star RatingFive gold stars auto-sweep ratings up and down; the active star pops with a scale bounce. Pointer sets the hover rating instantly.