Update translation for the annual plan

GitOrigin-RevId: 3a7e42f61f7820221df3be3c8bd4cd1738b5cb46
This commit is contained in:
Rebeka 2023-07-13 15:58:13 +02:00 committed by Copybot
parent 5dfe026123
commit 38d1e749fb
3 changed files with 23 additions and 9 deletions

View file

@ -326,6 +326,7 @@
"find_the_symbols_you_need_with_premium": "", "find_the_symbols_you_need_with_premium": "",
"first_name": "", "first_name": "",
"first_x_days_free_after_that_y_per_month": "", "first_x_days_free_after_that_y_per_month": "",
"first_x_days_free_after_that_y_per_year": "",
"fold_line": "", "fold_line": "",
"folder_location": "", "folder_location": "",
"following_paths_conflict": "", "following_paths_conflict": "",

View file

@ -2,7 +2,8 @@ import { Trans } from 'react-i18next'
import { usePaymentContext } from '../../../context/payment-context' import { usePaymentContext } from '../../../context/payment-context'
function TrialPrice() { function TrialPrice() {
const { currencySymbol, trialLength, recurlyPrice } = usePaymentContext() const { currencySymbol, plan, recurlyPrice, trialLength } =
usePaymentContext()
if (!trialLength || !recurlyPrice) { if (!trialLength || !recurlyPrice) {
return null return null
@ -10,6 +11,16 @@ function TrialPrice() {
return ( return (
<div> <div>
{plan.annual ? (
<Trans
i18nKey="first_x_days_free_after_that_y_per_year"
components={[<strong />, <strong />]} // eslint-disable-line react/jsx-key
values={{
trialLen: trialLength,
price: `${currencySymbol}${recurlyPrice.total}`,
}}
/>
) : (
<Trans <Trans
i18nKey="first_x_days_free_after_that_y_per_month" i18nKey="first_x_days_free_after_that_y_per_month"
components={[<strong />, <strong />]} // eslint-disable-line react/jsx-key components={[<strong />, <strong />]} // eslint-disable-line react/jsx-key
@ -18,6 +29,7 @@ function TrialPrice() {
price: `${currencySymbol}${recurlyPrice.total}`, price: `${currencySymbol}${recurlyPrice.total}`,
}} }}
/> />
)}
</div> </div>
) )
} }

View file

@ -528,6 +528,7 @@
"find_the_symbols_you_need_with_premium": "Find the symbols you need faster with Overleaf Premium", "find_the_symbols_you_need_with_premium": "Find the symbols you need faster with Overleaf Premium",
"first_name": "First Name", "first_name": "First Name",
"first_x_days_free_after_that_y_per_month": "First <0>__trialLen__ days free</0>, after that <0>__price__</0> per month", "first_x_days_free_after_that_y_per_month": "First <0>__trialLen__ days free</0>, after that <0>__price__</0> per month",
"first_x_days_free_after_that_y_per_year": "First <0>__trialLen__ days free</0>, after that <0>__price__</0> per year",
"fold_line": "Fold line", "fold_line": "Fold line",
"folder_location": "Folder location", "folder_location": "Folder location",
"folders": "Folders", "folders": "Folders",