'use client' import type { Locale } from '@/i18n-config' import Divider from '@/app/components/base/divider' import LocaleSigninSelect from '@/app/components/base/select/locale-signin' import { useGlobalPublicStore } from '@/context/global-public-context' import { useLocale } from '@/context/i18n' import { setLocaleOnClient } from '@/i18n-config' import { languages } from '@/i18n-config/language' import dynamic from '@/next/dynamic' // Avoid rendering the logo and theme selector on the server const DifyLogo = dynamic(() => import('@/app/components/base/logo/dify-logo'), { ssr: false, loading: () =>
, }) const ThemeSelector = dynamic(() => import('@/app/components/base/theme-selector'), { ssr: false, loading: () => , }) const Header = () => { const locale = useLocale() const systemFeatures = useGlobalPublicStore(s => s.systemFeatures) return (