From 8d8eafedabd83b3c7c44d9e737576887396bf6ec Mon Sep 17 00:00:00 2001 From: Konstantinos Paparas Date: Mon, 25 Nov 2024 17:27:50 +0100 Subject: [PATCH] refactor: fix issues reported by the i18n eslint plugin --- components/account/home/AccountDetails.vue | 4 +- .../account/home/CancelSubscription.vue | 6 +- components/account/signup/SignupAddress.vue | 2 +- components/checkout/pay/CardPayment.vue | 4 +- components/checkout/pay/CryptoPage.vue | 12 +- components/checkout/pay/SavedCardDisplay.vue | 87 +- components/common/CopyButton.vue | 4 +- components/common/Recaptcha.client.vue | 3 +- components/error/NotFoundError.vue | 6 +- components/footer/PageFooter.vue | 5 +- components/values/ValueBody.vue | 31 +- components/values/ValueBodyItem.vue | 10 +- components/values/ValueVision.vue | 11 +- composables/crypto-payment.ts | 2 +- eslint.config.js | 17 + i18n/locales/en.json | 1129 +++++++++-------- pages/health.vue | 6 +- pages/maintenance.vue | 21 +- 18 files changed, 683 insertions(+), 677 deletions(-) diff --git a/components/account/home/AccountDetails.vue b/components/account/home/AccountDetails.vue index 42407f08..ed84aff2 100644 --- a/components/account/home/AccountDetails.vue +++ b/components/account/home/AccountDetails.vue @@ -28,7 +28,7 @@ const { t } = useI18n(); diff --git a/components/common/Recaptcha.client.vue b/components/common/Recaptcha.client.vue index 4021373d..9e4d4467 100644 --- a/components/common/Recaptcha.client.vue +++ b/components/common/Recaptcha.client.vue @@ -33,6 +33,7 @@ const rendered = ref(false); // this will be populated once the deferred captcha script is loaded const grecaptcha = toRef(window, 'grecaptcha'); +const { t } = useI18n(); /** * Renders the captcha if not rendered and required fields are available @@ -89,7 +90,7 @@ onMounted(() => { v-if="invalid" :class="css.error" > - Invalid or expired captcha, please try again + {{ t('recaptcha.expired_captcha') }}

diff --git a/components/error/NotFoundError.vue b/components/error/NotFoundError.vue index abc5cbaf..356c35a0 100644 --- a/components/error/NotFoundError.vue +++ b/components/error/NotFoundError.vue @@ -19,12 +19,12 @@ const otherHeight = inject('otherHeight', 0);

- Page not found + {{ t('not_found.title') }}

- You may have mis-typed the URL or the page has been removed.
- Actually, there is nothing to see here... + {{ t('not_found.description.line_one') }}
+ {{ t('not_found.description.line_two') }}

(() => `© Rotki Solutions GmbH 2018-${year}.`);