mirror of
https://github.com/Dokploy/dokploy
synced 2025-06-26 18:27:59 +00:00
feat: add translation for not-found
This commit is contained in:
@@ -1,8 +1,10 @@
|
|||||||
import Link from 'next/link'
|
import Link from 'next/link'
|
||||||
import { Footer } from './Footer'
|
import { Footer } from './Footer'
|
||||||
import { Header } from './Header'
|
import { Header } from './Header'
|
||||||
|
import { useTranslations } from 'next-intl'
|
||||||
|
|
||||||
export function SlimLayout({ children }: { children: React.ReactNode }) {
|
export function SlimLayout() {
|
||||||
|
const t = useTranslations('404')
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div>
|
<div>
|
||||||
@@ -14,14 +16,13 @@ export function SlimLayout({ children }: { children: React.ReactNode }) {
|
|||||||
404
|
404
|
||||||
</h1>
|
</h1>
|
||||||
<p className="mb-4 text-lg text-muted-foreground">
|
<p className="mb-4 text-lg text-muted-foreground">
|
||||||
Oops! Looks like you're lost.
|
{t('title')}
|
||||||
</p>
|
</p>
|
||||||
<p className="mt-4 text-muted-foreground">
|
<p className="mt-4 text-muted-foreground">
|
||||||
Let's get you back{' '}
|
{t('des')}{' '}
|
||||||
<Link href="/" className="text-primary">
|
<Link href="/" className="text-primary">
|
||||||
home
|
{t('action')}
|
||||||
</Link>
|
</Link>
|
||||||
.
|
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
|
|||||||
@@ -78,5 +78,10 @@
|
|||||||
"footer": {
|
"footer": {
|
||||||
"copyright": "Copyright © {year} Dokploy. All rights reserved."
|
"copyright": "Copyright © {year} Dokploy. All rights reserved."
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"404": {
|
||||||
|
"title": "Oops! Looks like you're lost.",
|
||||||
|
"des": "Let's get you back",
|
||||||
|
"action": "home"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -78,5 +78,10 @@
|
|||||||
"footer": {
|
"footer": {
|
||||||
"copyright": "版权属于 © {year} Dokploy, 保留所有权利"
|
"copyright": "版权属于 © {year} Dokploy, 保留所有权利"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"404": {
|
||||||
|
"title": "糟糕!看起来你迷路了。",
|
||||||
|
"des": "让我们送你",
|
||||||
|
"action": "回家"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user