5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-23 08:26:23 +00:00

feat: extraer en un componente

This commit is contained in:
f 2024-03-04 15:10:20 -03:00
parent a7d33976ec
commit 3967a63163
No known key found for this signature in database
3 changed files with 15 additions and 3 deletions

View file

@ -0,0 +1,13 @@
-#
Contenedor para las acciones en masa.
Es un formulario auto-contenido, que permite colocar los elementos
fuera del formulario para evitar anidarlos. Mientras los elementos
tengan el atributo `form` con el mismo parámetro `form_id`, el
navegador los va a asignar a este formulario.
@param path [String]
@param form_id [String]
= form_tag path, id: form_id, method: :patch do
-# nada

View file

@ -1,6 +1,6 @@
- form_id = 'actor_moderations_action_on_several' - form_id = 'actor_moderations_action_on_several'
= form_tag site_actor_moderations_action_on_several_path, id: form_id, method: :patch = render 'components/select_all_container', path: site_actor_moderations_action_on_several_path, form_id: form_id
.row.no-gutters.pt-2{ data: { controller: 'select-all' } } .row.no-gutters.pt-2{ data: { controller: 'select-all' } }
.col-1.d-flex.align-items-center .col-1.d-flex.align-items-center

View file

@ -1,8 +1,7 @@
- form_id = 'instance_moderation_action_on_several' - form_id = 'instance_moderation_action_on_several'
%section %section
= form_tag site_instance_moderations_action_on_several_path, id: form_id, method: :patch = render 'components/select_all_container', path: site_instance_moderations_action_on_several_path, form_id: form_id
.row.no-gutters.pt-2{ data: { controller: 'select-all' } } .row.no-gutters.pt-2{ data: { controller: 'select-all' } }
.col-1.d-flex.align-items-center .col-1.d-flex.align-items-center
= render 'components/select_all', id: 'instances', form_id: form_id = render 'components/select_all', id: 'instances', form_id: form_id