languages checked

This commit is contained in:
Selvi 2025-08-19 21:27:49 +05:30
parent a9f655930e
commit 3d0b7c3b18
2 changed files with 8 additions and 4 deletions

View File

@ -17,7 +17,7 @@ const BlogSingle = () => {
const router = useRouter();
const { slug } = router.query;
const { t } = useTranslation('blog');
const { t } = useTranslation(['blog', 'innerBanner']);
if (!slug) return null; // Avoid hydration mismatch on first load
@ -39,7 +39,7 @@ const BlogSingle = () => {
return (
<Fragment>
<Navbar2 />
<PageTitle pageTitle={blogContent.title} backgroundImage={bg} pagesub={blogContent.sub} />
<PageTitle pageTitle={blogContent.title} backgroundImage={bg} pagesub={t('blog-details.pageSub', { ns: 'innerBanner' })} />
<section className="wpo-blog-single-section section-padding">
<div className="container">
@ -96,7 +96,7 @@ export async function getStaticPaths() {
export async function getStaticProps({ locale }) {
return {
props: {
...(await serverSideTranslations(locale, ['common', 'menu', 'blog', 'footer'])),
...(await serverSideTranslations(locale, ['common', 'menu', 'blog', 'footer', 'innerBanner'])),
},
};
}

View File

@ -25,6 +25,10 @@
"pageTitle": "Blog",
"pageSub": "Blog"
},
"blog-details": {
"pageTitle": "Detalle del Blog",
"pageSub": "Detalle del Blog"
},
"contact": {
"pageTitle": "Contáctanos",
"pageSub": "Contacto"