From 539e808f7e7e7ed932970d73c9f3cb9cd74ef382 Mon Sep 17 00:00:00 2001 From: brave-builds Date: Fri, 27 Aug 2021 20:59:12 +0000 Subject: [PATCH] Uplift of #9867 (squashed) to release --- browser/ui/webui/brave_webui_source.cc | 1 + .../resources/tip/components/bat_tip_form.style.ts | 7 +++++++ .../resources/tip/components/bat_tip_form.tsx | 3 +++ .../brave_rewards/resources/tip/stories/locale_strings.ts | 1 + components/resources/brave_components_strings.grd | 1 + 5 files changed, 13 insertions(+) diff --git a/browser/ui/webui/brave_webui_source.cc b/browser/ui/webui/brave_webui_source.cc index 236d3eb6ede6..4083cbcbb92b 100644 --- a/browser/ui/webui/brave_webui_source.cc +++ b/browser/ui/webui/brave_webui_source.cc @@ -963,6 +963,7 @@ void CustomizeWebUIHTMLSource(const std::string &name, { "monthlyText", IDS_BRAVE_UI_MONTHLY_TEXT }, { "nextContributionDate", IDS_BRAVE_REWARDS_TIP_NEXT_CONTRIBUTION_DATE }, // NOLINT { "notEnoughTokens", IDS_BRAVE_REWARDS_TIP_NOT_ENOUGH_TOKENS }, + { "tippingFeeNote", IDS_BRAVE_REWARDS_TIPPING_FEE_NOTE }, { "on", IDS_BRAVE_UI_ON }, { "onboardingMaybeLater", IDS_BRAVE_REWARDS_ONBOARDING_MAYBE_LATER }, { "onboardingSetupAdsHeader", IDS_BRAVE_REWARDS_ONBOARDING_SETUP_ADS_HEADER }, // NOLINT diff --git a/components/brave_rewards/resources/tip/components/bat_tip_form.style.ts b/components/brave_rewards/resources/tip/components/bat_tip_form.style.ts index 6c9b1720c69e..613696f803f4 100644 --- a/components/brave_rewards/resources/tip/components/bat_tip_form.style.ts +++ b/components/brave_rewards/resources/tip/components/bat_tip_form.style.ts @@ -104,3 +104,10 @@ export const notEnoughFunds = styled.div` color: var(--brave-palette-neutral300); } ` + +export const feeNote = styled.div` + text-align: center; + font-size: 11px; + line-height: 16px; + color: var(--brave-palette-neutral600); +` diff --git a/components/brave_rewards/resources/tip/components/bat_tip_form.tsx b/components/brave_rewards/resources/tip/components/bat_tip_form.tsx index 1f9817b79db3..34f26e2eb19c 100644 --- a/components/brave_rewards/resources/tip/components/bat_tip_form.tsx +++ b/components/brave_rewards/resources/tip/components/bat_tip_form.tsx @@ -160,6 +160,9 @@ export function BatTipForm (props: Props) { + + {getString('tippingFeeNote')} + { diff --git a/components/brave_rewards/resources/tip/stories/locale_strings.ts b/components/brave_rewards/resources/tip/stories/locale_strings.ts index 5da359225281..e739ed247fdb 100644 --- a/components/brave_rewards/resources/tip/stories/locale_strings.ts +++ b/components/brave_rewards/resources/tip/stories/locale_strings.ts @@ -42,6 +42,7 @@ export const localeStrings = { supportThisCreator: 'Support this creator', thanksForTheSupport: 'Thanks for the support!', tipHasBeenSent: 'Your one-time tip has been sent.', + tippingFeeNote: 'Brave collects 5% of the tip amount as a processing fee.', tipPostSubtitle: 'for their post', tokens: 'tokens', tweetAboutSupport: 'Tweet about your support', diff --git a/components/resources/brave_components_strings.grd b/components/resources/brave_components_strings.grd index d5712b59ce44..a796ef09cf17 100644 --- a/components/resources/brave_components_strings.grd +++ b/components/resources/brave_components_strings.grd @@ -609,6 +609,7 @@ Monthly contribution has been set. Next contribution date: Not enough tokens. Please $1add funds$2. + Brave collects 5% of the tip amount as a processing fee. One-Time Tip One-time tip amount: Hold on, you can’t tip yet