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

feat: provision wallet notice dialog #99

Merged
merged 7 commits into from
Apr 25, 2024
Merged

feat: provision wallet notice dialog #99

merged 7 commits into from
Apr 25, 2024

Conversation

samsiegart
Copy link
Contributor

@samsiegart samsiegart commented Mar 28, 2024

fixes #78

Adds a function checkSmartWalletProvisionAndMakeOffer which will automatically show the provision wallet notice before attempting to sign the offer.

Builds upon #98 to provide the "Deposit IST" button with leap elements.

Testing

Tested with dapp-offer-up in Agoric/dapp-offer-up@f0c2f73 (using yarn link @agoric/react-components). Simply replaced makeOffer with checkSmartWalletProvisionAndMakeOffer and now it shows the dialog before signing the transaction.

Screenshot

image

@otoole-brendan
Copy link

@samsiegart what do you mean by 'shows the dialog before signing the transaction'? Do you mean the dialog will appear to the user when they land on the dapp before they attempt the wallet spend action i.e. 'Create vault'? or do you mean it appears right after they hit 'create vault' but before txn is signed?

@samsiegart
Copy link
Contributor Author

@otoole-brendan When you click the "make offer" button the dialog will pop up if there's no smart wallet, otherwise it just goes straight to keplr.

Base automatically changed from provision-dialog to main April 24, 2024 17:43
Copy link

cloudflare-workers-and-pages bot commented Apr 24, 2024

Deploying ui-kit with  Cloudflare Pages  Cloudflare Pages

Latest commit: 2adac06
Status: ✅  Deploy successful!
Preview URL: https://dd62859a.ui-kit-dwm.pages.dev
Branch Preview URL: https://provision-dialog-2.ui-kit-dwm.pages.dev

View logs

@samsiegart samsiegart marked this pull request as ready for review April 24, 2024 19:00
@samsiegart samsiegart requested a review from turadg April 24, 2024 19:01
@samsiegart samsiegart requested a review from ivanlei April 25, 2024 16:48
@samsiegart
Copy link
Contributor Author

@ivanlei I know you mentioned before checkSmartWalletProvisionAndMakeOffer isn't a great name, agreed. I wanted to ask before merging, what's a better name? makeOfferWithProvision ? Maybe just makeOffer and make the other function makeOfferWithoutSmarWalletCheck?

@ivanlei
Copy link

ivanlei commented Apr 25, 2024

Maybe just makeOffer and make the other function makeOfferWithoutSmarWalletCheck?

That's my vote.

@samsiegart
Copy link
Contributor Author

Made the provision dialog the default makeOffer, and renamed the previous makeOffer to makeOfferWithoutModal

@samsiegart samsiegart merged commit 1329752 into main Apr 25, 2024
2 checks passed
@samsiegart samsiegart deleted the provision-dialog-2 branch April 25, 2024 19:29
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.

Create Provision Smart Wallet Component
4 participants