Skip to content

Commit 5fba2b1

Browse files
committed
Update elements nesting
Option values table was not meant to be nested inside the form.
1 parent d575a79 commit 5fba2b1

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

admin/app/components/solidus_admin/option_types/edit/component.html.erb

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,15 @@
88
<% end %>
99
<% end %>
1010

11-
<%= form_for @option_type, url: form_url, html: { id: form_id, class: "flex flex-col gap-4" } do |f| %>
12-
<%= render component("ui/panel").new(title: t(".panels.option_type.title")) do |panel| %>
13-
<% panel.with_section(class: "flex flex-col gap-4") do %>
14-
<div class="flex gap-4 w-full">
15-
<%= render component("ui/forms/field").text_field(f, :name, class: "required") %>
16-
<%= render component("ui/forms/field").text_field(f, :presentation, class: "required") %>
17-
</div>
11+
<div class="flex flex-col gap-4">
12+
<%= form_for @option_type, url: form_url, html: { id: form_id } do |f| %>
13+
<%= render component("ui/panel").new(title: t(".panels.option_type.title")) do |panel| %>
14+
<% panel.with_section(class: "flex flex-col gap-4") do %>
15+
<div class="flex gap-4 w-full">
16+
<%= render component("ui/forms/field").text_field(f, :name, class: "required") %>
17+
<%= render component("ui/forms/field").text_field(f, :presentation, class: "required") %>
18+
</div>
19+
<% end %>
1820
<% end %>
1921
<% end %>
2022

@@ -25,10 +27,10 @@
2527

2628
<% panel.with_action(name: t(".panels.option_values.add"), href: "#") %>
2729
<% end %>
28-
<% end %>
2930

30-
<%= page_footer do %>
31-
<%= render component("ui/button").new(text: t(".save"), form: form_id) %>
32-
<% end %>
31+
<%= page_footer do %>
32+
<%= render component("ui/button").new(text: t(".save"), form: form_id) %>
33+
<% end %>
34+
</div>
3335
<% end %>
3436
<% end %>

0 commit comments

Comments
 (0)