chore: layout UI upgrade (#6577)

This commit is contained in:
Joel 2024-07-23 17:11:02 +08:00 • committed by GitHub
commit 6a9d202414
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 51 additions and 19 deletions

View file

@ -1,5 +1,7 @@
'use client'
import type { FC } from 'react'
import classNames from '@/utils/classnames'
import { useSelector } from '@/context/app-context'
type LogoSiteProps = {
className?: string
@ -8,9 +10,16 @@ type LogoSiteProps = {
const LogoSite: FC<LogoSiteProps> = ({
className,
}) => {
const { theme } = useSelector((s) => {
return {
theme: s.theme,
}
})
const src = theme === 'light' ? '/logo/logo-site.png' : `/logo/logo-site-${theme}.png`
return (
<img
src='/logo/logo-site.png'
src={src}
className={classNames('block w-auto h-10', className)}
alt='logo'
/>