From d18762a4c1adbfcd509ff0efd5be7f13f3632dee Mon Sep 17 00:00:00 2001 From: Dorian Merz <merz@ub.uni-leipzig.de> Date: Wed, 4 Sep 2019 11:12:39 +0200 Subject: [PATCH] refs #15983 [fid_bbi] header mobile display * fixes burger menu bg color * fixes overlapping search box * shows breadcrumb area to enable login/logout functionality * remove gutter next to header --- themes/fid_bbi/scss/compiled.scss | 25 +++++++++++++++++++ themes/fid_bbi/templates/header.phtml | 2 +- themes/fid_bbi/templates/layout/layout.phtml | 2 +- .../fid_bbi/templates/search/searchbox.phtml | 2 +- 4 files changed, 28 insertions(+), 3 deletions(-) diff --git a/themes/fid_bbi/scss/compiled.scss b/themes/fid_bbi/scss/compiled.scss index 95e4fcb8eb2..d65218c943a 100644 --- a/themes/fid_bbi/scss/compiled.scss +++ b/themes/fid_bbi/scss/compiled.scss @@ -42,6 +42,10 @@ body { flex-grow: 2; } +.flex-short { + flex-shrink: 4; +} + .flex-justify-end { justify-content: flex-end; } @@ -100,6 +104,20 @@ body { #header-collapse { flex: 1 1; } +#header-collapse.collapse.in { + background-color: transparent; + text-align: right; +} +#header-collapse.collapse.in li > a.btn { + text-align: right; +} + +//// override finc: push navbar in from right, to allow for offcanvas scrollbar +.offcanvas .navbar-fixed-top { + @media only screen and (max-width: $screen-xs-max) { + right: 0; + } +} // Menu and Language Selector // set font color in header to white for better visibility @@ -198,6 +216,13 @@ input.searchFormKeepFilters { margin: 0 5px 0 0; } +.flex-column-xs { + @media screen and (max-width: $screen-xs-max) { + display: flex; + flex-flow: column; + } +} + .searchForm .flex-checkbox { align-self: end; diff --git a/themes/fid_bbi/templates/header.phtml b/themes/fid_bbi/templates/header.phtml index a9cd194f0ae..c22a5876507 100644 --- a/themes/fid_bbi/templates/header.phtml +++ b/themes/fid_bbi/templates/header.phtml @@ -6,7 +6,7 @@ '$navbar-height', '$navbar-height-xs' and '$navbar-height-sm' in _customVariables.scss to '=0' or set the paddings-top under 'body' in compiled.scss to '=0' */ ?> -<div class="banner container navbar navbar-fixed-top flex"> +<div class="banner container navbar navbar-fixed-top flex-column-xs"> <?php /* This element only holds the mobile toggler and the navbar-brand/library name - CK */ ?> <div class="navbar-header flex-long"> <?php /* mobile navigation toggler - CK */ ?> diff --git a/themes/fid_bbi/templates/layout/layout.phtml b/themes/fid_bbi/templates/layout/layout.phtml index e1418c70ed5..680b0bf56b2 100644 --- a/themes/fid_bbi/templates/layout/layout.phtml +++ b/themes/fid_bbi/templates/layout/layout.phtml @@ -150,7 +150,7 @@ if (!isset($this->layout()->searchbox)) { </header> <nav class="breadcrumbs"> <? /* finc: Don't use .container here or the breadcrumbs will get a left+right padding - CK */ ?> - <ul class="breadcrumb large-centered hidden-xs hidden-print"> + <ul class="breadcrumb large-centered hidden-print"> <? if (is_object($account) && $account->loginEnabled()): // hide login/logout if unavailable ?> <li class="logoutOptions<? if (!$account->isLoggedIn()): ?> hidden<? endif ?>"> <a class="btn" href="<?=$this->url('myresearch-home', array(), array('query' => array('redirect' => 0)))?>"> diff --git a/themes/fid_bbi/templates/search/searchbox.phtml b/themes/fid_bbi/templates/search/searchbox.phtml index c143826a6c8..68354b4b977 100644 --- a/themes/fid_bbi/templates/search/searchbox.phtml +++ b/themes/fid_bbi/templates/search/searchbox.phtml @@ -108,7 +108,7 @@ $hiddenFilterParams = $this->searchTabs()->getCurrentHiddenFilterParams($this->s <?php endforeach; ?> <?php endforeach; ?> <?php if ($advSearch): ?> - <div class="hidden-xs margin-t-third"> + <div class="margin-t-third"> <a href="<?=$this->url($advSearch) . ((isset($this->searchId) && $this->searchId) ? '?edit=' . $this->escapeHtmlAttr($this->searchId) : $hiddenFilterParams)?>" class="btn btn-primary" role="button" rel="nofollow"><i class="fa fa-cog"></i> <span class="hidden-xs hidden-sm hidden-md"><?=$this->transEsc("Advanced")?></span></a> </div> <?php endif; ?> -- GitLab