From d391193a03cf3803c3c745d450614854725a92df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?marcin=20miko=C5=82ajczak?= Date: Fri, 25 Aug 2023 22:43:21 +0200 Subject: [PATCH] Make all profile badges translatable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: marcin mikołajczak --- app/soapbox/components/profile-hover-card.tsx | 6 +++--- app/soapbox/features/ui/components/profile-info-panel.tsx | 2 +- app/soapbox/locales/en.json | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/soapbox/components/profile-hover-card.tsx b/app/soapbox/components/profile-hover-card.tsx index 842844ec1..363c69c1a 100644 --- a/app/soapbox/components/profile-hover-card.tsx +++ b/app/soapbox/components/profile-hover-card.tsx @@ -30,13 +30,13 @@ const getBadges = ( const badges = []; if (account?.admin) { - badges.push(); + badges.push(} />); } else if (account?.moderator) { - badges.push(); + badges.push(} />); } if (patronUser?.is_patron) { - badges.push(); + badges.push(} />); } return badges; diff --git a/app/soapbox/features/ui/components/profile-info-panel.tsx b/app/soapbox/features/ui/components/profile-info-panel.tsx index addeff9d2..769e6c4bc 100644 --- a/app/soapbox/features/ui/components/profile-info-panel.tsx +++ b/app/soapbox/features/ui/components/profile-info-panel.tsx @@ -83,7 +83,7 @@ const ProfileInfoPanel: React.FC = ({ account, username }) => } if (isPatron) { - badges.push(); + badges.push(} key='patron' />); } return [...badges, ...custom]; diff --git a/app/soapbox/locales/en.json b/app/soapbox/locales/en.json index b2d0469e9..f2ac576c9 100644 --- a/app/soapbox/locales/en.json +++ b/app/soapbox/locales/en.json @@ -38,6 +38,7 @@ "account.mute": "Mute @{name}", "account.muted": "Muted", "account.never_active": "Never", + "account.patron": "Patron", "account.posts": "Posts", "account.posts_with_replies": "Posts & replies", "account.profile": "Profile",