Light/dark toggle with a glowing knob

A chunky neumorphic switch where the knob glows sunny yellow in light mode and moon-blue in dark mode as the whole scene dims.

By Zsolt Kacso (@kaolti) · View original post

Originally built with HTML/CSS. Members can get the prompt for React, SwiftUI, React Native or HTML/CSS.

Prompt

Build a tactile theme toggle in CSS/React.…

Free forever. Available for React, SwiftUI, React Native and HTML/CSS.

Build it with

Motion details

Details
Reduced-motion fallback

Keyframes

Six frames from the clip, left to right. Agents get this sheet as a reference with the prompt.

Six keyframes from Light/dark toggle with a glowing knob

Questions

How do I build the light/dark toggle with a glowing knob in HTML/CSS?
Copy the Kites Motion prompt for this clip (free account) and paste it into Claude Code, Cursor or Codex, or send it there in one click. The prompt describes the layout, timing and interactions, and links a keyframe sheet so your agent can match the motion. It is written for HTML/CSS and can be rewritten for React, SwiftUI, React Native.
What are the motion details?
Details: Reduced-motion fallback.
Who designed this animation?
Zsolt Kacso (@kaolti) shared it on X. Kites Motion links back to the original post.

More from Zsolt Kacso

All by @kaolti →