Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Commit

Permalink
Adds verify notification
Browse files Browse the repository at this point in the history
  • Loading branch information
NejcZdovc committed Jul 10, 2019
1 parent c1279d3 commit 8ad5ec1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/features/rewards/walletWrapper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ export type NotificationType =
'tipsProcessed' |
'error' |
'pendingContribution' |
'verifyWallet' |
''

export type WalletState =
Expand Down Expand Up @@ -299,6 +300,10 @@ export default class WalletWrapper extends React.PureComponent<Props, State> {
buttonText = getLocale('addFunds')
buttonAction = this.onNotificationClick
break
case 'verifyWallet':
buttonText = getLocale('whyHow').toUpperCase()
buttonAction = this.onNotificationClick
break
default:
buttonText = getLocale('ok').toUpperCase()
break
Expand Down Expand Up @@ -432,6 +437,8 @@ export default class WalletWrapper extends React.PureComponent<Props, State> {
case 'ads':
case 'ads-launch':
case 'backupWallet':
case 'insufficientFunds':
case 'verifyWallet':
icon = megaphoneIconUrl
break
case 'contribute':
Expand All @@ -442,9 +449,6 @@ export default class WalletWrapper extends React.PureComponent<Props, State> {
case 'grant':
icon = giftIconUrl
break
case 'insufficientFunds':
icon = megaphoneIconUrl
break
default:
icon = ''
break
Expand Down Expand Up @@ -487,6 +491,9 @@ export default class WalletWrapper extends React.PureComponent<Props, State> {
case 'pendingContribution':
typeText = getLocale('pendingContributionTitle')
break
case 'verifyWallet':
typeText = getLocale('verifyWalletTitle')
break
default:
typeText = ''
break
Expand Down
2 changes: 2 additions & 0 deletions stories/assets/locale.ts
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ const locale: Record<string, string> = {
unVerifiedText: 'This creator has not yet signed up to receive contributions from Brave users.',
unVerifiedTextMore: 'Learn more.',
verifiedPublisher: 'Verified Creator',
verifyWalletTitle: 'Verify your wallet',
viewDetails: 'View Details',
viewMonthly: 'View Monthly Statement for Details',
walletActivity: 'Wallet Activity',
Expand Down Expand Up @@ -272,6 +273,7 @@ const locale: Record<string, string> = {
whyBraveRewards: 'Why Brave Rewards?',
whyBraveRewardsDesc1: 'With conventional browsers, you pay to browse the web by viewing ads with your valuable attention, spending your valuable time downloading invasive ad technology, that transmits your valuable private data to advertisers — without your consent.',
whyBraveRewardsDesc2: 'Well, you\'ve come to the right place. Brave welcomes you to the new internet. One where your time is valued, your personal data is kept private, and you actually get paid for your attention.',
whyHow: 'Why & How',
yourWallet: 'Your wallet'
}

Expand Down

0 comments on commit 8ad5ec1

Please sign in to comment.