From 895fef7205ed7f369002f099cefd0a6245494e8a Mon Sep 17 00:00:00 2001 From: Dominik Hebeler <dominik@suma-ev.de> Date: Wed, 20 Feb 2019 13:36:34 +0100 Subject: [PATCH] added more space to the left of the results --- app/Http/Controllers/MetaGerSearch.php | 4 +- .../metager/pages/resultpage/result-page.less | 37 +++++++------------ .../views/layouts/researchandtabs.blade.php | 4 +- resources/views/layouts/resultPage.blade.php | 2 +- 4 files changed, 19 insertions(+), 28 deletions(-) diff --git a/app/Http/Controllers/MetaGerSearch.php b/app/Http/Controllers/MetaGerSearch.php index c26f1e957..31df5b28a 100644 --- a/app/Http/Controllers/MetaGerSearch.php +++ b/app/Http/Controllers/MetaGerSearch.php @@ -6,7 +6,7 @@ use App; use App\MetaGer; use Illuminate\Http\Request; -const TIP_SERVER = 'http://localhost:63825/tips.xml'; +const TIP_SERVER = 'http://metager3.de:63825/tips.xml'; class MetaGerSearch extends Controller { @@ -76,7 +76,7 @@ class MetaGerSearch extends Controller public function tips(Request $request) { $tips_text = file_get_contents(TIP_SERVER); - $tips = []; + $tips = []; try { $tips_xml = simplexml_load_string($tips_text); diff --git a/resources/less/metager/pages/resultpage/result-page.less b/resources/less/metager/pages/resultpage/result-page.less index 80d488c6f..25731ef64 100644 --- a/resources/less/metager/pages/resultpage/result-page.less +++ b/resources/less/metager/pages/resultpage/result-page.less @@ -334,21 +334,20 @@ a { margin: @padding-small-default; margin-left: @results-margin-left; display: grid; - grid-template-columns: @results-width-max @additions-width-max; - grid-template-areas: "searchbar ." "foki ." "options ." "results additions"; + grid-template-columns: minmax(0px, 150px) @results-width-max @additions-width-max; + grid-template-areas: "whitespace searchbar ." "whitespace foki ." "whitespace options ." "whitespace results additions" "whitespace footer ."; grid-column-gap: (@padding-small-default * 2); grid-row-gap: @padding-small-default; justify-items: stretch; align-items: stretch; /**/ background-color: @resultpage-background-color; - #research-bar-container { - grid-area: searchbar; + #whitespace { + grid-area: whitespace; } - #research-bar-placeholder { + #research-bar-container { grid-area: searchbar; - /**/ - max-width: @results-width-max; + position: sticky; } #foki { grid-area: foki; @@ -372,16 +371,19 @@ a { display: none; } } + footer { + grid-area: footer; + } @media (max-width: @resultpage-breakpoint-max) { @supports (display: grid) { grid-template-columns:~"calc(60% - 8px)"~"calc(40% - 8px)"; - grid-template-areas: "searchbar ." "foki ." "options ." "results additions"; + grid-template-areas: "searchbar ." "foki ." "options ." "results additions" "footer ."; } } @media (max-width: @resultpage-breakpoint-min) { margin-left: @padding-small-default; grid-template-columns: 100%; - grid-template-areas: "searchbar" "foki" "options" "results"; + grid-template-areas: "searchbar" "foki" "options" "results" "footer"; #additions-container { display: none; } @@ -389,24 +391,12 @@ a { } #research-bar-container { - margin-left: (@results-margin-left - @padding-small-default); - position: fixed; + position: sticky; z-index: 5; top: 0; left: 0; background-color: @resultpage-background-color; - padding: @padding-small-default @padding-small-default 0px @padding-small-default; - width: (@results-width-max + 2 * @padding-small-default); - max-width: (@results-width-max + 2 * @padding-small-default); - @media (max-width: @resultpage-breakpoint-max) { - @supports (display: grid) { - width: ~"calc(60% - 6px)"; - } - } - @media (max-width: @resultpage-breakpoint-min) { - width: 100%; - margin-left: 0px; - } + max-width: @results-width-max; #research-bar { background-color: white; border: 1px solid #ccc; @@ -568,6 +558,7 @@ a { } footer.resultPageFooter { + max-width: @results-width-max; margin-top: 20px; @media (max-width: (2 * @results-margin-left + @results-width-max - 1px)) { diff --git a/resources/views/layouts/researchandtabs.blade.php b/resources/views/layouts/researchandtabs.blade.php index d6834902b..72abf64f1 100644 --- a/resources/views/layouts/researchandtabs.blade.php +++ b/resources/views/layouts/researchandtabs.blade.php @@ -1,4 +1,5 @@ <div id="resultpage-container"> + <div id="whitespace"></div> <div id="research-bar-container"> <div id="research-bar"> <div id="header-logo"> @@ -15,8 +16,6 @@ <div class="sidebar-opener-placeholder"></div> </div> </div> - <div id="research-bar-placeholder"> - </div> <div id="foki"> <div class="scrollbox"> <div class="scrollfade-left"></div> @@ -81,4 +80,5 @@ </div> @endif </div> + @include('parts.footer', ['type' => 'resultpage', 'id' => 'resultPageFooter']) </div> diff --git a/resources/views/layouts/resultPage.blade.php b/resources/views/layouts/resultPage.blade.php index cbb53a0db..c462e8026 100644 --- a/resources/views/layouts/resultPage.blade.php +++ b/resources/views/layouts/resultPage.blade.php @@ -40,8 +40,8 @@ @yield('results') </div> </div> + @include('parts.footer', ['type' => 'resultpage', 'id' => 'resultPageFooter']) @endif - @include('parts.footer', ['type' => 'resultpage', 'id' => 'resultPageFooter']) <script src="{{ mix('js/lib.js') }}"></script> <script src="{{ mix('js/scriptResultPage.js') }}" defer></script> <script src="{{ mix('js/focus-creator.js') }}" defer></script> -- GitLab