From 3788e492dd6549981d655ec02e573f82cd88af07 Mon Sep 17 00:00:00 2001 From: Andreas Nedbal Date: Sat, 25 Jun 2022 02:02:12 +0200 Subject: [PATCH] Add text if no user is (anonymously) blocked --- app/views/settings/_blocks.haml | 5 +++++ config/locales/views.en.yml | 1 + 2 files changed, 6 insertions(+) diff --git a/app/views/settings/_blocks.haml b/app/views/settings/_blocks.haml index 4160b157..5592a372 100644 --- a/app/views/settings/_blocks.haml +++ b/app/views/settings/_blocks.haml @@ -13,6 +13,9 @@ .ml-auto.d-inline-flex %button.btn.btn-default.align-self-center{ data: { action: :unblock, target: block.target.screen_name } } %span.pe-none= t("views.actions.unblock") + + - if @blocks.empty? + %p.text-muted.text-center= t(".none") .card .card-body %h2= t(".section.anon_blocks.heading") @@ -28,3 +31,5 @@ %button.btn.btn-default.align-self-center{ data: { action: "anon-unblock", target: block.id } } %span.pe-none= t("views.actions.unblock") + - if @anonymous_blocks.empty? + %p.text-muted.text-center= t(".none") diff --git a/config/locales/views.en.yml b/config/locales/views.en.yml index 5eec4658..f3ad01cb 100644 --- a/config/locales/views.en.yml +++ b/config/locales/views.en.yml @@ -94,6 +94,7 @@ en: heading: "Unsatisfied?" blocks: blocked: "blocked %{time} ago" + none: "No one has been blocked yet" section: blocks: heading: "Blocks"