From 0595f91222f1c4d2bb389802675c9c45da60d46c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Mon, 28 Dec 2020 15:59:52 +0100 Subject: [PATCH] Simplify advanced search layout width rules This way, adding a new element is going to be easier. --- app/assets/stylesheets/advanced_search.scss | 34 ++++++++++++-- .../shared/advanced_search_component.html.erb | 44 +++++++++---------- 2 files changed, 51 insertions(+), 27 deletions(-) diff --git a/app/assets/stylesheets/advanced_search.scss b/app/assets/stylesheets/advanced_search.scss index 5e144e755..4ea3a5fd1 100644 --- a/app/assets/stylesheets/advanced_search.scss +++ b/app/assets/stylesheets/advanced_search.scss @@ -14,11 +14,37 @@ .advanced-search-form { + @include breakpoint(large) { + .filter { + @include grid-column; + width: 25%; + } + + .date-filters { + float: left; + width: 50%; + + .filter { + width: 50%; + } + + .custom-date-filters { + clear: both; + } + } + + .submit { + width: 25%; + } + } + + .general-search, + .filter, + .submit { + @include grid-column-gutter; + } + select { height: $line-height * 2; } - - .column.end.clear { - clear: both; - } } diff --git a/app/components/shared/advanced_search_component.html.erb b/app/components/shared/advanced_search_component.html.erb index 0daf76477..a0f5006d8 100644 --- a/app/components/shared/advanced_search_component.html.erb +++ b/app/components/shared/advanced_search_component.html.erb @@ -6,7 +6,7 @@ <%= form_tag request.path, id: "advanced_search_form", method: :get do %>