Theme switcher and dark mode toggle components

Letting people change a theme is easy to build badly: colours that fail contrast, a flash on switch, settings that never reach the real page. A good theme control shows the change on a real page and keeps it readable.

Livery is eight components on one theme model that writes CSS variables, each driving a live mini page that animates every change: a 60-30-10 palette builder with harmony rules, swatches that open a new colour in a circle from where you touched, a light and dark toggle whose sun becomes a moon, an accent picker that checks WCAG contrast live and snaps to the nearest passing shade, a font pairer, a radius, density and shadow tuner, an export panel for CSS variables, Tailwind config or JSON, and a preset gallery.

The pack

What a good one needs

Questions

Does it include the colour maths?

Yes. HSL, mixing, relative luminance and contrast ratios are included.

Does it work in React, Vue and plain HTML?

Yes. Every screen ships as one framework-free core with React, Next.js, Vue, HTML, Tailwind and Motion versions.

How much does it cost?

Livery is $2, paid once for the whole pack.

Which frameworks are included?

React (TypeScript), Next.js App Router, Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion. React, Vue and HTML are each a thin wrapper over one framework-free core, so they look and move the same. The Next.js version is the React component marked as a client component, with an app/page.tsx example. The Tailwind version adds the pack colours as Tailwind theme tokens, so you place, size and recolour it with utility classes. The Motion version wraps it in a motion.div so you can animate it in, out and on scroll with Motion props; the motion inside still runs on its own engine. Most packs need no npm packages; the 3D ones use Three.js.

Can I use it in client and commercial projects?

Yes. Every pack can be used in unlimited personal and commercial projects, including client work. Paid packs cannot be resold or redistributed as a component library, template or UI kit; free packs are open source under the MIT License, so you may share them too.

Related