From e673d77eebcc19aa6d1575ef01610a4f786d65ba Mon Sep 17 00:00:00 2001 From: Daniela Mormocea Date: Tue, 18 Jan 2022 22:37:57 +0200 Subject: [PATCH] style --- .../theme/Header/HeaderNavigation.jsx | 88 +++++++++---------- .../volto/components/theme/Header/Header.jsx | 3 - 2 files changed, 44 insertions(+), 47 deletions(-) diff --git a/src/components/theme/Header/HeaderNavigation.jsx b/src/components/theme/Header/HeaderNavigation.jsx index 4798eff..39bf0f1 100644 --- a/src/components/theme/Header/HeaderNavigation.jsx +++ b/src/components/theme/Header/HeaderNavigation.jsx @@ -7,8 +7,7 @@ import downIcon from '@plone/volto/icons/down-key.svg'; import closeIcon from '@plone/volto/icons/clear.svg'; import { Icon } from '@plone/volto/components'; import { connect } from 'react-redux'; -import Sticky from 'react-stickynode'; - +import Sticky from 'react-stickynode'; import circleLeft from '@plone/volto/icons/circle-left.svg'; import circleRight from '@plone/volto/icons/circle-right.svg'; @@ -65,7 +64,6 @@ const MobileNav = ({ items, activeItem }) => { )} - ); }; @@ -78,7 +76,6 @@ const HeaderNavigation = ({ items, pageWidth }) => { items && items.length < 4 ? items.length : 4, ); - const [displayedItems, setDisplayedItems] = React.useState([]); const history = useHistory(); const pathname = history.location.pathname; @@ -148,48 +145,51 @@ const HeaderNavigation = ({ items, pageWidth }) => { {isMobile ? ( ) : ( - -
- {displayedItems.length > 0 && - displayedItems.map((item, index) => ( - - {item.title} - - ))} - {!noPrev && ( - - )} - {!noNext && ( - - )} -
+ +
+ {displayedItems.length > 0 && + displayedItems.map((item, index) => ( + + {item.title} + + ))} + {!noPrev && ( + + )} + {!noNext && ( + + )} +
)} - ); }; diff --git a/src/customizations/volto/components/theme/Header/Header.jsx b/src/customizations/volto/components/theme/Header/Header.jsx index 036a67a..e336f94 100644 --- a/src/customizations/volto/components/theme/Header/Header.jsx +++ b/src/customizations/volto/components/theme/Header/Header.jsx @@ -72,9 +72,6 @@ const Header = (props) => { const pathName = props.pathname; const hideSearch = ['/header', '/head', '/footer'].includes(pathName); - - - return (