Schneller, Ramez

This commit is contained in:
BuildTools
2025-12-19 23:36:05 +01:00
parent 5d780e0c36
commit e70d305cdb
17 changed files with 928 additions and 83 deletions

21
i18n/de.json Normal file
View File

@@ -0,0 +1,21 @@
{
"main": {
"title": "Hier entsteht etwas Großartiges.",
"text": "Keine Lust, zu warten? Kontaktieren Sie uns über ",
"imprint": "Impressum"
},
"imprint": {
"title": "Impressum",
"company": "GSH Digital Services",
"ceo": "Geschäftsführer: Tim Herb",
"street": "Horrenberger Straße 25",
"city": "74909 Meckesheim",
"country": "Deutschland",
"back": "Zurück"
},
"notFound": {
"title": "404 | Nicht gefunden",
"text": "Die angeforderte Ressource existiert nicht.",
"back": "Zurück"
}
}

21
i18n/en.json Normal file
View File

@@ -0,0 +1,21 @@
{
"main": {
"title": "Something great is being built here.",
"text": "Can't wait? Contact us via ",
"imprint": "Imprint"
},
"imprint": {
"title": "Imprint",
"company": "GSH Digital Services",
"ceo": "CEO Tim Herb",
"street": "Horrenberger Straße 25",
"city": "74909 Meckesheim",
"country": "Germany",
"back": "Go back"
},
"notFound": {
"title": "404 | Not found",
"text": "The requested resource does not exist.",
"back": "Go back"
}
}

4
i18n/navigation.ts Normal file
View File

@@ -0,0 +1,4 @@
import { createNavigation } from 'next-intl/navigation';
import { routing } from '@/i18n/routing';
export const { Link, redirect, usePathname, useRouter, getPathname } = createNavigation(routing);

23
i18n/request.ts Normal file
View File

@@ -0,0 +1,23 @@
import { getRequestConfig } from 'next-intl/server';
import { routing } from '@/i18n/routing';
type Routing = {
locales: readonly string[];
defaultLocale: string;
};
const { locales, defaultLocale }: Routing = routing;
export default getRequestConfig(async ({ requestLocale }) => {
const requested = await requestLocale;
const locale =
requested !== undefined && locales.includes(requested)
? requested
: defaultLocale;
return {
locale,
messages: (await import(`./${locale}.json`)).default
};
});

8
i18n/routing.ts Normal file
View File

@@ -0,0 +1,8 @@
import { defineRouting } from 'next-intl/routing';
export const routing = defineRouting({
locales: [ 'en', 'de' ],
defaultLocale: 'en',
localeDetection: true,
localeCookie: false
});