Use CSS to style the search component

We simplify the view, and so make it easier to customize.
This commit is contained in:
Javi Martín
2020-12-03 11:39:33 +01:00
parent b453ed6c14
commit 49c22b880c
2 changed files with 21 additions and 10 deletions

View File

@@ -0,0 +1,17 @@
.admin [role=search] {
display: flex;
[type="submit"] {
@include button($background: $link);
border-radius: 0;
font-size: 1rem;
&[disabled] {
@include button-disabled;
}
}
@include breakpoint(medium) {
width: 50%;
}
}

View File

@@ -1,10 +1,4 @@
<div class="small-12 medium-6">
<%= form_tag(url, method: :get, role: "search") do |f| %>
<div class="input-group">
<%= text_field_tag :search, search_terms.to_s, placeholder: label, "aria-label": label %>
<div class="input-group-button">
<%= submit_tag t("admin.shared.user_search.button"), class: "button" %>
</div>
</div>
<% end %>
</div>
<%= form_tag(url, method: :get, role: "search") do |f| %>
<%= text_field_tag :search, search_terms.to_s, placeholder: label, "aria-label": label %>
<%= submit_tag t("admin.shared.user_search.button") %>
<% end %>