Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #17692 - Add messaging in the UI about 5% tipping fee when tipping #9867

Merged
merged 1 commit into from
Aug 27, 2021

Conversation

jumde
Copy link
Contributor

@jumde jumde commented Aug 26, 2021

Resolves brave/brave-browser#17692

Submitter Checklist:

  • I confirm that no security/privacy review is needed, or that I have requested one
  • There is a ticket for my issue
  • Used Github auto-closing keywords in the PR description above
  • Wrote a good PR/commit description
  • Added appropriate labels (QA/Yes or QA/No; release-notes/include or release-notes/exclude; OS/...) to the associated issue
  • Checked the PR locally: npm run test -- brave_browser_tests, npm run test -- brave_unit_tests, npm run lint, npm run gn_check, npm run tslint
  • Ran git rebase master (if needed)

Reviewer Checklist:

  • A security review is not needed, or a link to one is included in the PR description
  • New files have MPL-2.0 license header
  • Adequate test coverage exists to prevent regressions
  • Major classes, functions and non-trivial code blocks are well-commented
  • Changes in component dependencies are properly reflected in gn
  • Code follows the style guide
  • Test plan is specified in PR before merging

After-merge Checklist:

Test Plan:

  1. Try initiating a tip to a creator. Messaging should be updated to -
Brave collects 5% of the tip amount as a processing fee. By proceeding, you agree to the Terms of Service and Privacy Policy.

Screen Shot 2021-08-26 at 11 36 33 PM

@jumde jumde self-assigned this Aug 26, 2021
@@ -639,7 +639,7 @@
<message name="IDS_BRAVE_REWARDS_ONBOARDING_SETUP_CONTRIBUTE_SUBHEADER" desc="">(from your ads earnings)</message>
<message name="IDS_BRAVE_REWARDS_ONBOARDING_START_USING_REWARDS" desc="">Start using Brave Rewards</message>
<message name="IDS_BRAVE_REWARDS_ONBOARDING_TAKE_TOUR" desc="">Take a quick tour</message>
<message name="IDS_BRAVE_REWARDS_ONBOARDING_TERMS" desc="">By proceeding, you agree to the <ph name="TOS_LINK_BEGIN">$1</ph>Terms of Service<ph name="TOS_LINK_END">$2</ph> and <ph name="PP_LINK_BEGIN">$3</ph>Privacy Policy<ph name="PP_LINK_END">$4</ph>.</message>
<message name="IDS_BRAVE_REWARDS_ONBOARDING_TERMS" desc="">Brave collects 5% of the tip amount as a processing fee. By proceeding, you agree to the <ph name="TOS_LINK_BEGIN">$1</ph>Terms of Service<ph name="TOS_LINK_END">$2</ph> and <ph name="PP_LINK_BEGIN">$3</ph>Privacy Policy<ph name="PP_LINK_END">$4</ph>.</message>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, I think this will update the terms of service text for all Rewards onboarding components. Also, I think we only want to show this message for users with a verified external wallet. We'll probably need to add a component to the tip application for this specific case.

@jumde jumde requested a review from a team as a code owner August 27, 2021 04:33
@jumde jumde requested a review from zenparsing August 27, 2021 04:36
@@ -968,6 +968,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 },
{ "tipNote", IDS_BRAVE_REWARDS_TIP_NOTE },
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To make this a little more self-documenting, let's name this string "tippingFeeNote" / IDS_BRAVE_REWARDS_TIPPING_FEE_NOTE.

Also, let's add a "tippingFeeNote" entry to tip/stories/locale_strings.ts for storybook.

@@ -160,6 +161,7 @@ export function BatTipForm (props: Props) {
</style.main>
<style.footer>
<style.terms>
<TipNote />
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this component is just wrapping a string with styles, then we can get away with not defining a new component, and we can just use the string directly:

<style.terms>
  <style.feeNote>
    {getString('tippingFeeNote')}
  </style.feeNote>
  <TermsOfService />
</style.terms>

@jumde jumde requested a review from zenparsing August 27, 2021 18:26
@kjozwiak
Copy link
Member

Verification PASSED on Win 10 x64 using the following build:

Brave | 1.31.5 Chromium: 93.0.4577.58 (Official Build) nightly (64-bit)
-- | --
Revision | c4410ece044414ea42fa4ba328d08195e818a99c-refs/branch-heads/4577@{#1076}
OS | Windows 10 OS Version 2009 (Build 19042.1165)

One-time Tip Examples

Example Example Example
onetimeTip customOnetimeTip oneTimeSend

Monthly Contribution Examples

Example Example Example
monthlyTip customMonthlyTip montlySend

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add messaging in the UI about 5% tipping fee when tipping
4 participants