Day/Night Landscape Switch

Motion Components · Vol. 1

Component

Day/Night Landscape Switch

The switch track is a tiny landscape and so is the screen. Flip it: the sun sinks behind the ridges, the sky burns orange, stars ignite, the moon rises and the lake reflects all of it. Click the lake to ripple it.

Variants

Sizes and states, all built from the same markup.

Small
Default
Disabled

Usage

Paste the markup, include assets/css/tokens.css and assets/css/tailwind.css, then run the script from this page.

Accessibility