Skip to content

Commit

Permalink
added clear filters btn for ransack form
Browse files Browse the repository at this point in the history
  • Loading branch information
igorSimash committed Nov 2, 2024
1 parent 3bff2f0 commit 7fa749a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/views/account/shared/_search_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
<%= search_form_for(q, url: search_url, method: :get, class: "d-flex mb-5") do |f| %>
<%= f.search_field search_attribute, placeholder: t(".search_placeholder"), class: "form-input me-2" %>
<%= f.button t(".search_button"), class: "btn btn-blue px-4 items-center" %>
<%= link_to t(".clear_button"), search_url, class:"btn btn-grey px-4 items-center ml-2" %>
<% end %>
</div>
1 change: 1 addition & 0 deletions config/locales/en/layouts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ en:
search_form:
search_placeholder: "Search"
search_button: "Search"
clear_button: "Clear"
1 change: 1 addition & 0 deletions config/locales/uk/layouts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ uk:
search_form:
search_placeholder: "Пошук"
search_button: "Шукати"
clear_button: "Очистити"

0 comments on commit 7fa749a

Please sign in to comment.