refactor(i18n): move Lang type to types/i18n directory
Update import paths for Lang type across layout files to use new location Add umami analytics script in production mode
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
---
|
||||
import Layout from './Layout.astro';
|
||||
import { type Lang } from '@/i18n/utils';
|
||||
import { type Lang } from '@/types/i18n';
|
||||
import { defaultLang } from '@/i18n/ui';
|
||||
import GlassHeader from '@/components/GlassHeader';
|
||||
import Footer from '@/components/Footer';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
---
|
||||
import Layout from './Layout.astro';
|
||||
import type { MarkdownLayoutProps } from 'astro';
|
||||
import { type Lang } from '@/i18n/utils';
|
||||
import { type Lang } from '@/types/i18n';
|
||||
import { type FrontmatterProps } from '@/types';
|
||||
import { defaultLang } from '@/i18n/ui';
|
||||
import GlassHeader from '@/components/GlassHeader';
|
||||
|
||||
@@ -30,6 +30,11 @@ const t = useTranslations(lang);
|
||||
href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap"
|
||||
rel="stylesheet"
|
||||
/>
|
||||
{
|
||||
import.meta.env.MODE === 'production' && (
|
||||
<script defer src="https://cloud.umami.is/script.js" data-website-id="a79f759b-74ae-4165-b738-56d123a1c6be"></script>
|
||||
)
|
||||
}
|
||||
</head>
|
||||
<body
|
||||
class="min-h-screen bg-background font-sans antialiased selection:bg-purple-500/20 selection:text-purple-500"
|
||||
|
||||
@@ -8,8 +8,7 @@ import BlogList from '../components/blog/BlogList.astro';
|
||||
import CategoryCard from '../components/blog/CategoryCard.astro';
|
||||
import TagCard from '../components/blog/TagCard.astro';
|
||||
import Container from '../components/ui/Container';
|
||||
import { type Lang } from '@/i18n/utils';
|
||||
import { defaultLang } from '@/i18n/ui';
|
||||
import { type Lang } from '@/types/i18n';
|
||||
import { type BlogPost } from '@/types';
|
||||
|
||||
interface Props {
|
||||
|
||||
Reference in New Issue
Block a user