From 9b3b4381fe7f04918f66c4f4d0740baf8fe22fc8 Mon Sep 17 00:00:00 2001 From: Claas Kazzer <kazzer@ub.uni-leipzig.de> Date: Thu, 9 May 2019 14:58:35 +0200 Subject: [PATCH] refs #15148 * fixes jumping content when changing tabs bug * changes searchtools links into buttons on XS, SM * fixes add-to-bookbag in sidebar (again) --- themes/finc/scss/compiled.scss | 30 +++++++++++++++++++++- themes/finc/templates/search/results.phtml | 7 +++-- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/themes/finc/scss/compiled.scss b/themes/finc/scss/compiled.scss index b928d4071a2..e08c6f042e4 100644 --- a/themes/finc/scss/compiled.scss +++ b/themes/finc/scss/compiled.scss @@ -65,6 +65,12 @@ section { // width: auto; // } // + +// Prevent content from jumping when changing tabs in record view +html { + overflow-y: scroll; +} + // Add top-padding to body to accommodate fixed navbar; -- padding should equal navbar-height -- // the home page, however, has a lower navbar because there is no breadcrumbs there body { @@ -1409,6 +1415,7 @@ footer { .sort select { max-width: 12em; } + //// Off-Canvas @media only screen and (max-width: $screen-sm-max) { // Define position of VF5.1 offcanvas toggler @@ -1561,6 +1568,25 @@ footer { } } +// Display searchtools-links as buttons on XS, SM +@media screen and (max-width: $screen-sm-max) { + .searchtools { + a { + background-color: $white; + border: 1px solid $iron; + color: $oil; + // align on top of each other + display: block; + margin-bottom: 5px; + padding: 6px 12px; + text-align: center; + touch-action: manipulation; + vertical-align: middle; + white-space: nowrap; + } + } +} + ////// Pagination & Searchtools - END //// Search results - END @@ -1805,6 +1831,7 @@ footer { text-align: center; } } + //// pull content to right border for sidebar right .container .sidebar { &.right { @@ -1961,8 +1988,9 @@ footer { } } +// Keep padding at 2px or "Add to Bookbag" in Record View will be out of line .nav .btn-bookbag-toggle a { - padding-left: 8px; + padding-left: 2px; } //// Toolbar in Detailview - END diff --git a/themes/finc/templates/search/results.phtml b/themes/finc/templates/search/results.phtml index 75e6ee8afd5..fe22d92e56b 100644 --- a/themes/finc/templates/search/results.phtml +++ b/themes/finc/templates/search/results.phtml @@ -127,16 +127,15 @@ $this->headScript()->appendFile("check_save_statuses.js"); <div class="searchtools hidden-print"> <strong><?=$this->transEsc('Search Tools')?>:</strong> <a href="<?=$this->results->getUrlQuery()->setViewParam('rss')?>"><i class="fa fa-bell" aria-hidden="true"></i> <?=$this->transEsc('Get RSS Feed')?></a> - — + <span class="hidden-xs hidden-sm">—</span> <a href="<?=$this->url('search-email')?>" class="mailSearch" data-lightbox id="mailSearch<?=$this->escapeHtmlAttr($this->results->getSearchId())?>"> <i class="fa fa-envelope" aria-hidden="true"></i> <?=$this->transEsc('Email this Search')?> </a> <?php if ($this->accountCapabilities()->getSavedSearchSetting() === 'enabled'): ?> - — + <span class="hidden-xs hidden-sm">—</span> <?php if (is_numeric($this->results->getSearchId())): ?> <?php if ($this->results->isSavedSearch()): ?> - <a href="<?=$this->url('myresearch-savesearch')?>?delete=<?=urlencode($this->results->getSearchId())?>"><i class="fa fa-remove" - aria-hidden="true"></i> <?=$this->transEsc('save_search_remove')?></a> + <a href="<?=$this->url('myresearch-savesearch')?>?delete=<?=urlencode($this->results->getSearchId())?>"><i class="fa fa-remove" aria-hidden="true"></i> <?=$this->transEsc('save_search_remove')?></a> <?php else: ?> <a href="<?=$this->url('myresearch-savesearch')?>?save=<?=urlencode($this->results->getSearchId())?>"><i class="fa fa-save" aria-hidden="true"></i> <?=$this->transEsc('save_search')?></a> <?php endif; ?> -- GitLab