Controls

Theme Toggle

Theme Toggle
Click to toggle theme

Theme Toggle

A toggle button that flips between light and dark mode with an expanding circular reveal.

Dependencies

next-themeslucide-react

Installation

npx shadcn@latest add ikislay/pixel-ui/theme-toggle

How to use

import { ThemeToggle } from "@/components/ui/theme-toggle";
export default function Demo() {
return <ThemeToggle />;
}

Source Code

// Loading…

Props

Options you can pass to customize this component.

Prop
Type
Description
className
string

Classes applied to the root button element.