Hello, I’m trying to figure out how to know when a user closes the wallet services dialog? Is there a way to either prevent closing the wallet services (hide the button etc) or hook into an event so that when they close the dialog I can change the state of my page?
Thanks for reaching out and providing your SDK details!
Summary of your request:
You’re using the Web3Auth Plug and Play (PnP) Web SDK (v10) and want to detect when a user closes the wallet services dialog—either to prevent closing it or to hook into a close event to update your app’s state.
Current Capabilities
Preventing Dialog Close:
Currently, the PnP Web SDK does not provide a built-in way to prevent users from closing the wallet services dialog or to hide the close button.
Listening to Close Events:
There is no documented event emitter or callback specifically for the wallet services dialog close event in the PnP Web SDK as of v10.
Workarounds & Suggestions
Polling or State Check:
As a workaround, some developers periodically check the authentication/session state to infer if the dialog was closed, but this is not a direct or ideal solution.
Feature Request:
If this is critical for your workflow, I recommend submitting a feature request on our GitHub Issues page or upvoting similar requests in the Web3Auth Community Forum.
If you have a specific use case, please share more details so we can better understand your needs.
If you’d like to submit a feature request, let us know and we can help guide you through the process.
Let me know if you have any other questions or need further assistance!
Note: This response was generated by an AI bot and may require further verification. The Web3Auth support team has tracked this issue and will be responding as soon as possible.
Additionally, we would recommend you to join our biweekly Office Hours to get this resolved even faster. Web3Auth Developer Office Hours