-
-
Notifications
You must be signed in to change notification settings - Fork 28
/
section-3.tsx
39 lines (37 loc) · 1.47 KB
/
section-3.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import { DefaultPageProps } from '@/app/[lang]/[region]';
import { Translator } from '@socialincome/shared/src/utils/i18n';
import { Typography } from '@socialincome/ui';
import { FontColor } from '@socialincome/ui/src/interfaces/color';
import { CardTranslation, SectionCard } from './section-card';
export default async function Section3({ params }: DefaultPageProps) {
const translator = await Translator.getInstance({
language: params.lang,
namespaces: ['website-evidence'],
});
const cards = translator.t<CardTranslation[]>(`section-4.cards`);
const takeAction = translator.t('take-action');
return (
<div className="flex flex-col space-y-1 py-16">
<Typography size="xl" weight="medium" color="muted-foreground">
{translator.t(`section-4.topic`)}
</Typography>
<div className="pb-10">
{translator.t<{ text: string; color?: FontColor }[]>('section-4.title').map((title, index) => (
<Typography as="span" key={index} size="4xl" weight="bold" color={title.color}>
{title.text}
</Typography>
))}
</div>
<div className="my-32 grid grid-cols-1 gap-16 md:grid-cols-6 lg:grid-cols-8">
<Typography size="2xl" weight="medium" className="md:col-span-3">
{translator.t(`section-4.evidence`)}
</Typography>
<div className="h-full space-y-10 text-left md:col-span-3 lg:col-span-4">
{cards.map((card, key) => (
<SectionCard key={key} translations={{ card: card, takeAction: takeAction }} />
))}
</div>
</div>
</div>
);
}