Skip to content

Commit

Permalink
Merge pull request #8765 from brave/pr8761_ksmith-jp-tip-verify-butto…
Browse files Browse the repository at this point in the history
…n_1.24.x

Fix "verify wallet" button on tip dialog rewards onboarding (uplift to 1.24.x)
  • Loading branch information
kjozwiak authored May 11, 2021
2 parents 7cf3d5d + f6c5cf4 commit c6c272d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,8 @@ export function getVerifyWalletPanel (
locale: Locale,
props: RewardsTourProps
): TourPanel | null {
if (!props.firstTimeSetup || props.onlyAnonWallet) {
if (!props.firstTimeSetup || props.onlyAnonWallet ||
!props.onVerifyWalletClick) {
return null
}

Expand All @@ -144,7 +145,7 @@ export function getVerifyWalletPanel (
formatMessage(getString('onboardingPanelBitflyerLearnMore'), {
tags: {
$1: (content) => (
<NewTabLink href='https://brave.com/ja/users-bitflyer/'>
<NewTabLink key='learn-more' href='https://brave.com/ja/users-bitflyer/'>
{content}
</NewTabLink>
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,11 @@ export function TipForm () {

const onTourDone = () => setShowTour(false)

const onVerifyClick = () => {
window.open('chrome://rewards/#verify', '_blank')
setShowTour(false)
}

return (
<style.tour>
<RewardsTour
Expand All @@ -137,6 +142,7 @@ export function TipForm () {
autoContributeAmountOptions={autoContributeChoices}
onAdsPerHourChanged={host.setAdsPerHour}
onAutoContributeAmountChanged={host.setAutoContributeAmount}
onVerifyWalletClick={onVerifyClick}
onDone={onTourDone}
/>
</style.tour>
Expand Down

0 comments on commit c6c272d

Please sign in to comment.