diff --git a/src/components/Header.astro b/src/components/Header.astro index 9867c76..fbca34c 100644 --- a/src/components/Header.astro +++ b/src/components/Header.astro @@ -2,9 +2,9 @@ import themeConfig from '@/config' const { title, subtitle } = themeConfig.site -const { titleSpace = 2 } = themeConfig.global +const { titleSpace } = themeConfig.global -const marginClass = { +const marginBottom = { 1: 'mb-1', 2: 'mb-2', 3: 'mb-3', @@ -13,18 +13,13 @@ const marginClass = { ---
-

+

{title}

-

+ +

{subtitle}

diff --git a/src/components/LangSwitch.astro b/src/components/LanguageSwitcher.astro similarity index 60% rename from src/components/LangSwitch.astro rename to src/components/LanguageSwitcher.astro index 14d5173..4fb3ea8 100644 --- a/src/components/LangSwitch.astro +++ b/src/components/LanguageSwitcher.astro @@ -6,26 +6,30 @@ const langs = ['', ...themeConfig.global.moreLocale] const currentLocale = themeConfig.global.locale function getLanguageDisplayName(code: string) { - if (!code) -return 'Default' + if (!code) { + return 'Default' + } return new Intl.DisplayNames(['en'], { type: 'language' }).of(code) || code } --- diff --git a/src/components/Navbar.astro b/src/components/Navbar.astro index a4e3ccf..fa1bc69 100644 --- a/src/components/Navbar.astro +++ b/src/components/Navbar.astro @@ -51,13 +51,13 @@ const isTagActive = isTagPage(currentPath) const isAboutActive = isAboutPage(currentPath) --- -