refactor(i18n): simplify language handling across components
use Astro.currentLocale as single source of truth for language remove manual lang prop passing to components components now read language from document lang attribute
This commit is contained in:
@@ -39,7 +39,7 @@ const lang = Astro.currentLocale as Lang || defaultLang;
|
||||
<div class="absolute inset-0 bg-gradient-to-br from-purple-50/30 via-transparent to-blue-50/20 dark:from-purple-950/20 dark:via-transparent dark:to-blue-950/10"></div>
|
||||
</div>
|
||||
<!-- Glass Header with navigation -->
|
||||
<GlassHeader lang={lang} client:load />
|
||||
<GlassHeader client:load />
|
||||
|
||||
<!-- Main content with proper spacing for fixed header -->
|
||||
<div class="pt-16">
|
||||
@@ -47,7 +47,7 @@ const lang = Astro.currentLocale as Lang || defaultLang;
|
||||
</div>
|
||||
|
||||
<!-- Footer -->
|
||||
<Footer lang={lang} client:load />
|
||||
<Footer client:load />
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user