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

Add hide wallet discovery param in Modal #1980

Merged
merged 5 commits into from
Oct 10, 2024

Conversation

tanguyenvn
Copy link
Contributor

@tanguyenvn tanguyenvn commented Oct 10, 2024

Motivation and Context

Some clients want to hide wallet discovery in PnP Modal SDK

Jira Link: https://toruslabs.atlassian.net/browse/PD-3994

Description

  • add hideWalletDiscovery param in modal config params
web3auth.initModal({ hideWalletDiscovery: true });
  • update vue-composables, react hooks
  • update vue-app-new example

How has this been tested?

Screenshots (if appropriate):

image

  • When hideWalletDiscovery=false (default=false)
    -- if no wallet adapters configured -> hide "Connect with a wallet" button
    image
    -- if only wallet connect is configured -> show full wallet discovery with WC QR-code
    image
    -- if wallet connect is not configured, other adapters configured -> show full wallet discovery without QR code
    image

  • When hideWalletDiscovery=true
    -- if no wallet adapters configured -> hide "Connect with a wallet" button
    image
    -- if only wallet connect is configured -> hide "Connect with a wallet" button
    image
    -- if other wallet adapters configured -> show "Connect with a wallet" button and show external wallets only
    image

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My code follows the code style of this project. (run lint)
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@tanguyenvn tanguyenvn marked this pull request as ready for review October 10, 2024 10:20
Copy link
Member

@chaitanyapotti chaitanyapotti left a comment

Choose a reason for hiding this comment

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

lgtm

@chaitanyapotti chaitanyapotti merged commit 41865b7 into master Oct 10, 2024
3 checks passed
@chaitanyapotti chaitanyapotti deleted the feat/hide-wallet-discovery branch October 10, 2024 11:04
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.

2 participants