From e7223ba86565013b950c655bb044876b6470f94a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sen=C3=A9n=20Rodero=20Rodr=C3=ADguez?= <15726+Senen@users.noreply.github.com> Date: Mon, 27 Nov 2023 14:15:03 +0100 Subject: [PATCH] Extract interactive map form to a component --- .../admin/settings/map_form_component.html.erb} | 0 app/components/admin/settings/map_form_component.rb | 2 ++ app/views/admin/settings/_map_configuration_tab.html.erb | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) rename app/{views/admin/settings/_map_form.html.erb => components/admin/settings/map_form_component.html.erb} (100%) create mode 100644 app/components/admin/settings/map_form_component.rb diff --git a/app/views/admin/settings/_map_form.html.erb b/app/components/admin/settings/map_form_component.html.erb similarity index 100% rename from app/views/admin/settings/_map_form.html.erb rename to app/components/admin/settings/map_form_component.html.erb diff --git a/app/components/admin/settings/map_form_component.rb b/app/components/admin/settings/map_form_component.rb new file mode 100644 index 000000000..29e5f5372 --- /dev/null +++ b/app/components/admin/settings/map_form_component.rb @@ -0,0 +1,2 @@ +class Admin::Settings::MapFormComponent < ApplicationComponent +end diff --git a/app/views/admin/settings/_map_configuration_tab.html.erb b/app/views/admin/settings/_map_configuration_tab.html.erb index e4b324e5d..9f0d4ab71 100644 --- a/app/views/admin/settings/_map_configuration_tab.html.erb +++ b/app/views/admin/settings/_map_configuration_tab.html.erb @@ -5,7 +5,7 @@
<%= t("admin.settings.index.map.help") %>
- <%= render "map_form" %> + <%= render Admin::Settings::MapFormComponent.new %> <% else %>