Theme Provider

Context provider for light/dark theme switching.

Report a bug

Preview

Switch between light and dark to inspect the embedded Storybook preview.

Installation

pnpm dlx shadcn@latest add https://ui.vllnt.ai/r/theme-provider.json

Storybook

Explore all variants, controls, and accessibility checks in the interactive Storybook playground.

View in Storybook

Code

"use client"; import { ThemeProvider as NextThemesProvider, type ThemeProviderProps, } from "next-themes"; export function ThemeProvider({ children, ...props }: ThemeProviderProps) { return <NextThemesProvider {...props}>{children}</NextThemesProvider>; }

Dependencies

  • @vllnt/ui@^0.2.1