Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/components/longevity/Hero/Hero.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,14 @@
padding: 40px 0;
}

@media (max-width: 1160px) {
.heroRu {
h1 {
font-family: Cormorant_Garamond-Regular, sans-serif !important;
font-weight: 200 !important;
}
}

@media (max-width: 1350px) {
.hero {
text-align: center;

Expand Down
22 changes: 19 additions & 3 deletions src/components/longevity/Hero/Hero.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
import { FC } from 'react';
import styles from './Hero.module.scss';
import { useRouter } from 'next/router';

import Heading from '@components/Heading';

import type { TRouter } from '@local-types/global';

import longevityData from '@data/longevity';

import styles from './Hero.module.scss';
import cn from 'classnames';

const Hero: FC = ({}) => {
const router = useRouter();
const { locale } = router as TRouter;
const { mainTitle } = longevityData[locale];

return (
<section className={styles.hero}>
<Heading text={'practical longevity protocol'} />
<section
className={cn(styles.hero, {
[styles.heroRu]: locale === 'ru',
})}
>
<Heading text={mainTitle} />
<Heading
text={'BY WOLF ALEXANYAN'}
Tag={'h2'}
Expand Down
1 change: 1 addition & 0 deletions src/data/longevity/en.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const en = {
mainTitle: 'Practical longevity protocol',
habitTooltipTitle: 'Why do this?',
foodScienceFactsTitle: 'Food-science facts that most influenced my choices',
whatNotToEatTitle: 'What not to eat',
Expand Down
1 change: 1 addition & 0 deletions src/data/longevity/hy.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const hy = {
mainTitle: 'Practical longevity protocol',
habitTooltipTitle: 'Why do this?',
foodScienceFactsTitle: 'Food-science facts that most influenced my choices',
whatNotToEatTitle: 'What not to eat',
Expand Down
1 change: 1 addition & 0 deletions src/data/longevity/ru.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const ru = {
mainTitle: 'ПРАКТИЧЕСКИЙ ПРОТОКОЛ ДОЛГОЛЕТИЯ',
habitTooltipTitle: 'Зачем это делать?',
foodScienceFactsTitle: 'Научные факты повлиявшие на меня больше всего',
whatNotToEatTitle: 'Что не есть',
Expand Down
2 changes: 0 additions & 2 deletions src/data/longevity/words.ts

This file was deleted.

Loading