diff --git a/i18n.json b/i18n.json index eafdfe3..000a0b6 100644 --- a/i18n.json +++ b/i18n.json @@ -1,12 +1,14 @@ { - "locales" : ["pt", "en", "es"], - "defaultLocale": "pt", - "pages" : { - "*" : ["common"], - "/" : ["homePage"], - "/kurumim" : ["kurumim"], - "/processo-seletivo": ["processoSeletivo"], - "/projetos" : ["projetos"], - "/zenith" : ["oZenith"] - } -} \ No newline at end of file + "locales": ["pt", "en", "es"], + "defaultLocale": "pt", + "pages": { + "*": ["common"], + "/": ["homePage"], + "/kurumim": ["kurumim"], + "/processo-seletivo": ["processoSeletivo"], + "/projetos": ["projetos"], + "/zenith": ["oZenith"], + "/launches": ["allLaunches"] + } +} + diff --git a/locales/en/allLaunches.json b/locales/en/allLaunches.json new file mode 100644 index 0000000..9dd5e55 --- /dev/null +++ b/locales/en/allLaunches.json @@ -0,0 +1,8 @@ +{ + "allLaunchesPage": { + "header": { + "title": "Lançamentos", + "description": "Acompanhe os lançamentos e os dados de cada missão." + } + } +} diff --git a/locales/es/allLaunches.json b/locales/es/allLaunches.json new file mode 100644 index 0000000..9dd5e55 --- /dev/null +++ b/locales/es/allLaunches.json @@ -0,0 +1,8 @@ +{ + "allLaunchesPage": { + "header": { + "title": "Lançamentos", + "description": "Acompanhe os lançamentos e os dados de cada missão." + } + } +} diff --git a/locales/pt/allLaunches.json b/locales/pt/allLaunches.json new file mode 100644 index 0000000..9dd5e55 --- /dev/null +++ b/locales/pt/allLaunches.json @@ -0,0 +1,8 @@ +{ + "allLaunchesPage": { + "header": { + "title": "Lançamentos", + "description": "Acompanhe os lançamentos e os dados de cada missão." + } + } +} diff --git a/pages/launches/index.tsx b/pages/launches/index.tsx index 49a175b..49833ac 100644 --- a/pages/launches/index.tsx +++ b/pages/launches/index.tsx @@ -16,6 +16,7 @@ import PinDropIcon from '@mui/icons-material/PinDrop'; import HeightIcon from '@mui/icons-material/Height'; import ChevronRightIcon from '@mui/icons-material/ChevronRight'; import ShareLocationIcon from '@mui/icons-material/ShareLocation'; +import useTranslation from 'next-translate/useTranslation'; const SELECTED_LAUNCH_STORAGE_KEY = 'zenith-selected-launch'; @@ -24,6 +25,10 @@ export default function LaunchesPage() { const { launches, isLoadingAllLaunches, error } = useAllLaunches(); const router = useRouter(); + const { t } = useTranslation(); + const launchesTitle = t('allLaunches:allLaunchesPage.header.title'); + const launchesDescription = t('allLaunches:allLaunchesPage.header.description'); + useEffect(() => {}, [isLoadingAllLaunches, launches]); const handleLaunchDetails = (launch: (typeof launches)[number]) => { @@ -35,10 +40,10 @@ export default function LaunchesPage() { - Lançamentos + {launchesTitle} - Acompanhe os lançamentos e os dados de cada missão. + {launchesDescription}