feat: add meta data (#105)
This commit is contained in:
@@ -1,3 +1,14 @@
|
||||
import { LocaleCodeType } from '@/types/locale';
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
|
||||
export async function generateMetadata({ params: { locale } }: { params: { locale: LocaleCodeType } }) {
|
||||
const t = await getTranslations({ locale, namespace: 'Auth' });
|
||||
return {
|
||||
title: `${t('account')} | UnitTCMS`,
|
||||
robots: { index: false, follow: false },
|
||||
};
|
||||
}
|
||||
|
||||
export default function AuthLayout({ children }: { children: React.ReactNode }) {
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -9,7 +9,6 @@ export default function Page({ params }: PageType) {
|
||||
yourProjects: t('your_projects'),
|
||||
public: t('public'),
|
||||
private: t('private'),
|
||||
noProjectsFound: t('no_projects_found'),
|
||||
notOwnAnyProjects: t('not_own_any_projects'),
|
||||
findProjects: t('find_projects'),
|
||||
};
|
||||
|
||||
@@ -1,8 +1,17 @@
|
||||
import { PageType } from '@/types/base';
|
||||
import AuthPage from '../authPage';
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { LocaleCodeType } from '@/types/locale';
|
||||
|
||||
export async function generateMetadata({ params: { locale } }: { params: { locale: LocaleCodeType } }) {
|
||||
const t = await getTranslations({ locale, namespace: 'Auth' });
|
||||
return {
|
||||
title: `${t('signin')} | UnitTCMS`,
|
||||
robots: { index: false, follow: false },
|
||||
};
|
||||
}
|
||||
|
||||
export default function Page({ params }: PageType) {
|
||||
const t = useTranslations('Auth');
|
||||
const messages = {
|
||||
|
||||
@@ -1,8 +1,17 @@
|
||||
import { PageType } from '@/types/base';
|
||||
import AuthPage from '../authPage';
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { LocaleCodeType } from '@/types/locale';
|
||||
|
||||
export async function generateMetadata({ params: { locale } }: { params: { locale: LocaleCodeType } }) {
|
||||
const t = await getTranslations({ locale, namespace: 'Auth' });
|
||||
return {
|
||||
title: `${t('signup')} | UnitTCMS`,
|
||||
robots: { index: false, follow: false },
|
||||
};
|
||||
}
|
||||
|
||||
export default function Page({ params }: PageType) {
|
||||
const t = useTranslations('Auth');
|
||||
const messages = {
|
||||
|
||||
Reference in New Issue
Block a user