Interface motion / CSS
Morphing toggle
A toggle knob stretches during a change of state, then returns to a circle.

DKC reference implementation; not an original creator video. You can play, pause, and inspect time in the reference.
Make it fit your project.
Use a real checkbox with an associated label. Move its visual thumb between two endpoints over 220ms, stretching the leading edge briefly with scaleX before settling. Keep checked state and assistive-technology state synchronized.
Build and check.
- Confirm the supplied content, target environment, and required assets before implementing.
- Use a real checkbox with an associated label. Move its visual thumb between two endpoints over 220ms, stretching the leading edge briefly with scaleX before settling. Keep checked state and assistive-technology state synchronized.
- Implement idle, active, keyboard, touch, reduced-motion, and failure states as relevant.
- Inspect the opening, midpoint, and final state at desktop and mobile sizes; report any dependency or output limitation.
Know the limits.
- The label and checked state must remain understandable without animation.
- The prompt guides a coding agent; output quality depends on its implementation and review.
Want us to build it?
Send an optional project brief. We’ll receive your contact details, project description, and this recipe’s ID.
Catalog 2026-10-22.a82e12098f76 · Source revision sha256:dfbe6519cbc4fc84acc4cbf926d8a01c7f2e248dd46cedd67a9112b0e928c2ba