Skip to content

Commit c74ff46

Browse files
committed
Fix: elasticsearchのindexビューをBootstrap5対応した
1 parent d44e498 commit c74ff46

File tree

1 file changed

+17
-13
lines changed

1 file changed

+17
-13
lines changed

app/views/elasticsearch/index.html.erb

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
<h2><%= link_to(t("views.elasticsearch.title"), elasticsearch_path, { class: "text-dark" }) %></h2>
22

3-
<%= form_with({ scope: :elasticsearch,
4-
url: elasticsearch_path,
5-
method: :get,
6-
local: true,
7-
class: "form-inline my-1", }) do |f| %>
8-
<%= f.label("search", class: "sr-only") %>
9-
<%= f.text_field(:word,
10-
{ placeholder: "Keyword",
11-
value: params.dig(:elasticsearch, :word),
12-
class: "form-control mr-sm-2", }) %>
13-
<%= button_tag(type: :submit, class: "btn btn-secondary") do %>
14-
<%= bootstrap_icon("search") %>
15-
<% end %>
3+
<%= form_with( scope: :elasticsearch,
4+
url: elasticsearch_path,
5+
method: :get,
6+
local: true,
7+
class: "row my-1",) do |f| %>
8+
<div class="col-auto">
9+
<%= f.label("search", class: "visually-hidden") %>
10+
<%= f.text_field(:word,
11+
{ placeholder: "Keyword",
12+
value: params.dig(:elasticsearch, :word),
13+
class: "form-control mr-sm-2", }) %>
14+
</div>
15+
<div class="col-auto">
16+
<%= button_tag(type: :submit, class: "btn btn-secondary") do %>
17+
<%= tag.i(class: "bi-search") %>
18+
<% end %>
19+
</div>
1620
<% end %>
1721

1822
<% @sakes.each do |sake| %>

0 commit comments

Comments
 (0)