diff --git a/src/layouts/BaseLayout.astro b/src/layouts/BaseLayout.astro index 8e82335..af2bff9 100644 --- a/src/layouts/BaseLayout.astro +++ b/src/layouts/BaseLayout.astro @@ -40,6 +40,11 @@ const ogImageUrl = new URL(ogImage, SITE.url).href; const isZh = lang === 'zh'; const resolvedSwitchHref = switchHref ?? (isZh ? '/' : '/zh/'); const switchLabel = isZh ? 'EN' : '中文'; + +// Locale-aware nav labels +const nav = isZh + ? { posts: '文章', categories: '分类', about: '关于', rss: 'RSS' } + : { posts: 'posts', categories: 'categories', about: 'about', rss: 'rss' }; --- @@ -128,10 +133,10 @@ const switchLabel = isZh ? 'EN' : '中文';