5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-23 01:46:21 +00:00
panel/app/views/components/_instances_btn_box.haml

12 lines
451 B
Text
Raw Permalink Normal View History

-# Componente botonera de moderación de Instancias
- local_data = {}
- InstanceModeration.events.each do |event|
- possible = instance_moderation.public_send(:"may_#{event}?")
= render 'components/btn_base',
path: public_send(:"site_instance_moderation_#{event}_path", instance_moderation_id: instance_moderation),
text: t(".text_#{event}"),
class: ('btn-secondary' if possible),
disabled: !possible,
data: local_data[event]