Closed samsiegart closed 2 months ago
@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?
@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.
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 |
@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
?
Maybe just
makeOffer
and make the other functionmakeOfferWithoutSmarWalletCheck
?
That's my vote.
Made the provision dialog the default makeOffer
, and renamed the previous makeOffer
to makeOfferWithoutModal
fixes https://github.com/Agoric/ui-kit/issues/78
Adds a function
checkSmartWalletProvisionAndMakeOffer
which will automatically show the provision wallet notice before attempting to sign the offer.Builds upon https://github.com/Agoric/ui-kit/pull/98 to provide the "Deposit IST" button with leap elements.
Testing
Tested with dapp-offer-up in https://github.com/Agoric/dapp-offer-up/commit/f0c2f731f9cfb0b3d47e1fb4f956ef95974cbfcd (using
yarn link @agoric/react-components
). Simply replacedmakeOffer
withcheckSmartWalletProvisionAndMakeOffer
and now it shows the dialog before signing the transaction.Screenshot