fix: localize 404 and ensure header when no lang

This commit is contained in:
Christel Westerberg
2024-06-04 13:35:45 +02:00
parent 74b05ed6a0
commit d5b08e3a36
8 changed files with 282 additions and 12 deletions

View File

@@ -0,0 +1,48 @@
import { texts } from "./Texts"
import styles from "./notFound.module.css"
import { LangParams } from "@/types/params"
export default function NotFound({ lang }: LangParams) {
const infoTexts = texts[lang]
return (
<div className={styles.container}>
<div className={styles.content}>
<h1 className={styles.header}>{infoTexts.title}</h1>
<div className={styles.pitch}>
<p className={styles.text}>
{infoTexts.goToStartPage.question}
<a
className={styles.link}
title={infoTexts.goToStartPage.linkText}
href={infoTexts.goToStartPage.link}
>
{infoTexts.goToStartPage.linkText}
</a>
?
</p>
<p className={styles.text}>
{infoTexts.goToDestinations.question}
<a
className={styles.link}
title={infoTexts.goToDestinations.linkText}
href={infoTexts.goToDestinations.link}
>
{infoTexts.goToDestinations.linkText}
</a>
{infoTexts.goToOffers.question}
<a
className={styles.link}
title={infoTexts.goToOffers.linkText}
href={infoTexts.goToOffers.link}
>
{infoTexts.goToOffers.linkText}
</a>
.
</p>
</div>
</div>
</div>
)
}