From ebaa7bfa87c9c4045baf9252244cc0ef6e07e854 Mon Sep 17 00:00:00 2001 From: Andreas Nedbal Date: Sat, 19 Feb 2022 00:36:20 +0100 Subject: [PATCH] Add translation for none-placeholder --- app/views/settings/_data.haml | 14 +++++++------- config/locales/views.en.yml | 1 + 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/app/views/settings/_data.haml b/app/views/settings/_data.haml index 5022ea68..43baa7a0 100644 --- a/app/views/settings/_data.haml +++ b/app/views/settings/_data.haml @@ -14,28 +14,28 @@ %p.font-weight-bold.mb-0= t("activerecord.attributes.profile.display_name") %p.text-muted - if current_user.profile.display_name.blank? - None set! + = t(".none") - else = current_user.profile.display_name %p.font-weight-bold.mb-0= t("activerecord.attributes.profile.description") %p.text-muted - if current_user.profile.description.blank? - None set! + = t(".none") - else = current_user.profile.description %p.font-weight-bold.mb-0= t("activerecord.attributes.profile.location") %p.text-muted - if current_user.profile.location.blank? - None set! + = t(".none") - else = current_user.profile.location %p.font-weight-bold.mb-0= t("activerecord.attributes.profile.website") %p.text-muted - if current_user.profile.website.blank? - None set! + = t(".none") - else = current_user.profile.website .col-md-6.col-sm-6.col-xs-12.mb-3 @@ -79,7 +79,7 @@ %p.font-weight-bold.mb-0= t("activerecord.attributes.user.locale") %p.text-muted - if current_user.locale.blank? - None set! + = t(".none") - else = current_user.locale @@ -107,7 +107,7 @@ = localize(current_user.created_at) = " (#{time_ago_in_words(current_user.created_at)} ago)" - else - Not set + = t(".none") %p.font-weight-bold.mb-0= t("activerecord.attributes.user.updated at") %p.text-muted @@ -115,4 +115,4 @@ = localize(current_user.updated_at) = " (#{time_ago_in_words(current_user.updated_at)} ago)" - else - Not set + = t(".none") diff --git a/config/locales/views.en.yml b/config/locales/views.en.yml index 5fb54440..91b6d33b 100644 --- a/config/locales/views.en.yml +++ b/config/locales/views.en.yml @@ -46,6 +46,7 @@ en: data: heading: "Your Profile Data" body: "Everything we have about you! Really, not that much as you might expect." + none: "None set!" section: general: "General" profile: "Profile"