fix: fix Logo component
This commit is contained in:
parent
aa0aea352b
commit
43d6b2cbf7
Binary file not shown.
Before Width: | Height: | Size: 307 KiB After Width: | Height: | Size: 98 KiB |
@ -1,3 +1,5 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
import { websiteConfig } from '@/config';
|
import { websiteConfig } from '@/config';
|
||||||
import { cn } from '@/lib/utils';
|
import { cn } from '@/lib/utils';
|
||||||
import { useTheme } from 'next-themes';
|
import { useTheme } from 'next-themes';
|
||||||
@ -6,7 +8,7 @@ import Image from 'next/image';
|
|||||||
export function Logo({ className }: { className?: string }) {
|
export function Logo({ className }: { className?: string }) {
|
||||||
const theme = useTheme();
|
const theme = useTheme();
|
||||||
const logoLight = websiteConfig.logo.light ?? '/logo.png';
|
const logoLight = websiteConfig.logo.light ?? '/logo.png';
|
||||||
const logoDark = websiteConfig.logo.dark ?? '/logo-dark.png';
|
const logoDark = websiteConfig.logo.dark ?? logoLight;
|
||||||
const logo = theme.theme === 'dark' ? logoDark : logoLight;
|
const logo = theme.theme === 'dark' ? logoDark : logoLight;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
Loading…
Reference in New Issue
Block a user