Skip to content

Commit

Permalink
Merge pull request #8761 from brave/ksmith-jp-tip-verify-button
Browse files Browse the repository at this point in the history
Fix "verify wallet" button on tip dialog rewards onboarding
  • Loading branch information
zenparsing authored May 10, 2021
2 parents 0dc6140 + 315277a commit ab419e3
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 ab419e3

Please sign in to comment.