mirror of
https://github.com/spliit-app/spliit.git
synced 2026-02-08 00:26:12 +01:00
Add French translation (#196)
* Added french version and title/description from json messages * Revert back default language to en-US * Code reviewed with prettier :) * Updated json to add information field * Updated json to add information block (missed on previous) * Reviewed code language * correction traduction "groupes étoilés" en "groupes favoris" --------- Co-authored-by: Andy Trouvé <andy@strekol.eu>
This commit is contained in:
@@ -1,31 +1,35 @@
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { Github } from 'lucide-react'
|
||||
import { useTranslations } from 'next-intl'
|
||||
import Link from 'next/link'
|
||||
|
||||
// FIX for https://github.com/vercel/next.js/issues/58615
|
||||
// export const dynamic = 'force-dynamic'
|
||||
|
||||
export default function HomePage() {
|
||||
const t = useTranslations()
|
||||
return (
|
||||
<main>
|
||||
<section className="py-16 md:py-24 lg:py-32">
|
||||
<div className="container flex max-w-screen-md flex-col items-center gap-4 text-center">
|
||||
<h1 className="!leading-none font-bold text-3xl sm:text-5xl md:text-6xl lg:text-7xl landing-header py-2">
|
||||
Share <strong>Expenses</strong> <br /> with <strong>Friends</strong>{' '}
|
||||
& <strong>Family</strong>
|
||||
<h1 className="!leading-none font-bold text-2xl sm:text-3xl md:text-4xl lg:text-5xl landing-header py-2">
|
||||
{t.rich('Homepage.title', {
|
||||
strong: (chunks) => <strong>{chunks}</strong>,
|
||||
})}
|
||||
</h1>
|
||||
<p className="max-w-[42rem] leading-normal text-muted-foreground sm:text-xl sm:leading-8">
|
||||
Welcome to your new <strong>Spliit</strong> instance! <br />
|
||||
Customize this page by editing <em>src/app/page.tsx</em>.
|
||||
{t.rich('Homepage.description', {
|
||||
strong: (chunks) => <strong>{chunks}</strong>,
|
||||
})}
|
||||
</p>
|
||||
<div className="flex gap-2">
|
||||
<Button asChild>
|
||||
<Link href="/groups">Go to groups</Link>
|
||||
<Link href="/groups">{t('Homepage.button.groups')}</Link>
|
||||
</Button>
|
||||
<Button asChild variant="secondary">
|
||||
<Link href="https://github.com/spliit-app/spliit">
|
||||
<Github className="w-4 h-4 mr-2" />
|
||||
GitHub
|
||||
{t('Homepage.button.github')}
|
||||
</Link>
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { getRequestConfig } from 'next-intl/server'
|
||||
import { getUserLocale } from './lib/locale'
|
||||
|
||||
export const locales = ['en-US', 'fi'] as const
|
||||
export const locales = ['en-US', 'fi', 'fr-FR'] as const
|
||||
export type Locale = (typeof locales)[number]
|
||||
export type Locales = ReadonlyArray<Locale>
|
||||
export const defaultLocale: Locale = 'en-US'
|
||||
|
||||
Reference in New Issue
Block a user