From 0f6dc1400b3450b503db3f8cdbeefb741345d969 Mon Sep 17 00:00:00 2001 From: Alex Medesan Date: Fri, 29 Jan 2021 15:24:13 +0200 Subject: [PATCH] implemented advanced search link in mobile menu --- .../theme/Navigation/Navigation.jsx | 15 +++++------- .../theme/SearchWidget/SearchWidget.jsx | 20 +++++++++++++++- theme/site/collections/menu.overrides | 2 +- theme/site/elements/input.overrides | 23 +++++++++++++++++++ 4 files changed, 49 insertions(+), 11 deletions(-) diff --git a/src/customizations/components/theme/Navigation/Navigation.jsx b/src/customizations/components/theme/Navigation/Navigation.jsx index 48c6ebe..5bfaddc 100644 --- a/src/customizations/components/theme/Navigation/Navigation.jsx +++ b/src/customizations/components/theme/Navigation/Navigation.jsx @@ -255,11 +255,7 @@ class Navigation extends Component { stackable pointing secondary - className={ - this.state.isMobileMenuOpen - ? 'open' - : 'large screen widescreen only' - } + className={this.state.isMobileMenuOpen ? 'open' : 'large screen only'} >
{this.props.items.map((item) => ( @@ -281,7 +277,6 @@ class Navigation extends Component {
- {/* */}
+
+ +
+ {!this.props.token && (
)} -
- -
+
+ +
+ + Advanced search + + + this.onLinkClick(evt, 'https://www.eea.europa.eu/help/glossary') + } + > + A-Z Glossary + +
); diff --git a/theme/site/collections/menu.overrides b/theme/site/collections/menu.overrides index 2653343..eff055e 100644 --- a/theme/site/collections/menu.overrides +++ b/theme/site/collections/menu.overrides @@ -91,7 +91,7 @@ .navigation-links { display: block !important; - margin-top: 4em; + margin-top: 6em; } .navigation-links a.item { diff --git a/theme/site/elements/input.overrides b/theme/site/elements/input.overrides index 66f8717..8fbbc90 100644 --- a/theme/site/elements/input.overrides +++ b/theme/site/elements/input.overrides @@ -69,6 +69,16 @@ } } +@media only screen and (max-width: @mobileWidth) { + .header-wrapper .ui.pointing.secondary.stackable.open.menu { + .eea-search-links { + a { + color: @white; + } + } + } +} + .clearfix:after { display: table; clear: both; @@ -86,6 +96,19 @@ padding-left: 0.5em !important; } +.searchbox { + .ui.accordion .title:not(.ui) { + padding: 0; + } + .ui.accordion:not(.styled) .title ~ .content.active { + position: absolute; + background: white; + width: 100%; + left: 0; + padding: 6px; + } +} + .ui.list > .item a.suggested-item { font-size: 16px; color: black;