From ab1186d08a12c4adc10c3cb3f1b548b70b6030b1 Mon Sep 17 00:00:00 2001 From: maki Date: Tue, 6 Feb 2024 17:22:44 -0300 Subject: [PATCH] =?UTF-8?q?feat:=20apartado=20de=20instancias=20dentro=20d?= =?UTF-8?q?e=20actividades=20de=20moderaci=C3=B3n=20#15091?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/moderation_queue/_instance.haml | 11 +++++++++++ app/views/moderation_queue/_instances.haml | 4 +++- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 app/views/moderation_queue/_instance.haml diff --git a/app/views/moderation_queue/_instance.haml b/app/views/moderation_queue/_instance.haml new file mode 100644 index 00000000..d3b56a03 --- /dev/null +++ b/app/views/moderation_queue/_instance.haml @@ -0,0 +1,11 @@ +- host = instance['domain'] +- host ||= instance['uri'] +- host = "https://#{host}" + + +%a{href: host}= instance['title'] +%p= instance['description'] +%span Users: +%span + = instance.dig('usage', 'users', 'active_month') + = instance.dig('stats', 'user_count') diff --git a/app/views/moderation_queue/_instances.haml b/app/views/moderation_queue/_instances.haml index 811aeaec..88a1e11c 100644 --- a/app/views/moderation_queue/_instances.haml +++ b/app/views/moderation_queue/_instances.haml @@ -9,7 +9,9 @@ = render 'components/dropdown_item', text: t('moderation_queue.filter_box.submenu_allow'), path: '/' = render 'components/dropdown_item', text: t('moderation_queue.filter_box.submenu_reject'), path: '/' -= render 'moderation_queue/button_box', btn_params: @instances_btn_params +- @instances.each do |instance| + = render 'moderation_queue/instance', instance: instance + = render 'moderation_queue/button_box', btn_params: @instances_btn_params %h3.cyan.mt-5= t('moderation_queue.instances.title') %p.pb-2= t('moderation_queue.instances.description')