From 78ad25b17c9a522e2aeec882f375690fa58c4459 Mon Sep 17 00:00:00 2001 From: Harpreet Kataria Date: Wed, 15 Jul 2020 13:00:45 -0400 Subject: [PATCH] Fixed to translate menu titles in Navbar --- app/javascript/menu/first-level.jsx | 4 ++-- app/javascript/menu/second-level.jsx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/javascript/menu/first-level.jsx b/app/javascript/menu/first-level.jsx index 3674e1469c1..ce6b7a69b11 100644 --- a/app/javascript/menu/first-level.jsx +++ b/app/javascript/menu/first-level.jsx @@ -28,7 +28,7 @@ const MenuItem = ({ active, href, icon, id, title, type }) => ( renderIcon={carbonizeIcon(icon)} {...linkProps({ type, href, id })} > - {title} + {__(title)} ); @@ -52,7 +52,7 @@ const MenuSection = ({ active, hover, icon, id, items, title, setSection }) => ( e.stopPropagation(); }} renderIcon={carbonizeIcon(icon)} - title={title} + title={__(title)} /> ); diff --git a/app/javascript/menu/second-level.jsx b/app/javascript/menu/second-level.jsx index a4daea456f4..71fe0643f62 100644 --- a/app/javascript/menu/second-level.jsx +++ b/app/javascript/menu/second-level.jsx @@ -20,7 +20,7 @@ const MenuItem = ({ active, href, id, title, type, hideSecondary }) => ( isActive={active} {...linkProps({ type, href, id, hideSecondary })} > - {title} + {__(title)} ); @@ -39,7 +39,7 @@ const MenuSection = ({ active, id, items, title, hideSecondary }) => ( id={itemId(id, true)} isActive={active} defaultExpanded={active} // autoexpand active section - title={title} + title={__(title)} > {mapItems(items, hideSecondary)}