Glass ToggleOn/off toggles with glass housing and liquid-feel spring animation.

Buttons & TogglesGlassInteractive

Preferences

Dark ModeOn
NotificationsOn
Auto-UpdateOff
AnalyticsOff
Haptic FeedbackOn

Add to your project

One command adds this component to your project.

1

Run the following command. New project? Run npx shadcn@latest init first to set up Tailwind and path aliases.

npx shadcn@latest add @aicanvas/glass-toggle
2

For dark mode, add the dark class to your <html> element:

Optional
<html class="dark">

More like this