21 lines
428 B
TypeScript
21 lines
428 B
TypeScript
'use client'
|
|
|
|
import * as React from 'react'
|
|
import {
|
|
ThemeProvider as NextThemesProvider,
|
|
type ThemeProviderProps,
|
|
} from 'next-themes'
|
|
|
|
export function ThemeProvider({ children, ...props }: ThemeProviderProps) {
|
|
return (
|
|
<NextThemesProvider
|
|
attribute="class"
|
|
defaultTheme="system"
|
|
enableSystem
|
|
disableTransitionOnChange
|
|
{...props}
|
|
>
|
|
{children}
|
|
</NextThemesProvider>
|
|
)
|
|
}
|