Skip to content

Commit

Permalink
en/one-time-donation.js: Swap the places of {{totalAmount}} and {{amo…
Browse files Browse the repository at this point in the history
…unt}}

Matches the BG translation string

Fixes podkrepi-bg#1244
  • Loading branch information
sashko9807 committed Feb 10, 2023
1 parent 5eb34f8 commit 8489eb4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion public/locales/bg/one-time-donation.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"card": "Карта",
"card-include-fees": "Искам да покрия таксата за карта издадена в: ",
"card-fees": "При дарение с карта използваме услугите на Stripe, като за всеки трансфер Stripe начисляват такса според региона на картоиздателя ви. За да се ориентирате за нетното дарение, след като изберете желаната сума, ще ви покажем изчислената такса. Повече за таксите от Страйп вижте тук: ",
"card-calculated-fees": "За вашия превод от <strong>{{totalAmount}}</strong>, таксата на Stripe ще е <strong>{{fees}}</strong>, а кампанията ще получи <strong>{{amount}}</strong>",
"card-calculated-fees": "За вашия превод от <strong>{{amount}}</strong>, таксата на Stripe ще е <strong>{{fees}}</strong>, а кампанията ще получи <strong>{{totalAmount}}</strong>",
"card-region": {
"title": "регион",
"EU": "Европа",
Expand Down
6 changes: 3 additions & 3 deletions src/components/one-time-donation/steps/FirstStep.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@ export default function FirstStep() {
stripeIncludeFeeCalculator(chosenAmount, formik.values.cardRegion),
)
} else {
formik.setFieldValue('amountWithoutFees', chosenAmount)
formik.setFieldValue(
'amountWithoutFees',
'amountWithFees',
chosenAmount - stripeFeeCalculator(chosenAmount, formik.values.cardRegion),
)
formik.setFieldValue('amountWithFees', chosenAmount)
}
}, [
formik.values.otherAmount,
Expand Down Expand Up @@ -267,7 +267,7 @@ export default function FirstStep() {
i18nKey="third-step.card-calculated-fees"
values={{
amount: moneyPublicDecimals2(amountWithoutFees.value),
fees: moneyPublicDecimals2(amountWithFees.value - amountWithoutFees.value),
fees: moneyPublicDecimals2(amountWithoutFees.value - amountWithFees.value),
totalAmount: moneyPublicDecimals2(amountWithFees.value),
}}
/>
Expand Down

0 comments on commit 8489eb4

Please sign in to comment.