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

Skip the first token allowance screen if dapp proposing spending cap is 0 #16502

Merged

Conversation

adnansahovic
Copy link
Contributor

Explanation

When a dapp proposed value for the spending cap is zero, the user is sent directly to the second screen in the flow and the spending cap is kept as 0 and the title copy reads Revoke the spending cap for your.

Screenshots/Screencaps

Before

Screen.Recording.2022-11-15.at.12.13.16.mov

After

Screen.Recording.2022-11-15.at.12.09.20.mov

Manual Testing Steps

  1. Go to https://etherscan.io/token/0x6b175474e89094c44da98b954eedeac495271d0f#writeContract
  2. Connect your wallet
  3. Under approve input any address and 0 as the value
  4. Click on write

@github-actions
Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@metamaskbot
Copy link
Collaborator

Builds ready [c47a3f1]
Page Load Metrics (2094 ± 107 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint962221162613
domContentLoaded172924542077220106
load172924862094223107
domInteractive172924542077220106
Bundle size diffs
  • background: 0 bytes
  • ui: 58 bytes
  • common: 0 bytes

highlights:

storybook

@mirjanaKukic
Copy link
Contributor

Verified by QA

Copy link

@Prasert111 Prasert111 left a comment

Choose a reason for hiding this comment

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

@adnansahovic adnansahovic marked this pull request as ready for review November 16, 2022 13:19
@adnansahovic adnansahovic requested a review from a team as a code owner November 16, 2022 13:19
@brad-decker brad-decker merged commit f7cb184 into develop Nov 17, 2022
@brad-decker brad-decker deleted the token-allowance-screen-dapp-proposing-spending-cap branch November 17, 2022 14:12
@github-actions github-actions bot locked and limited conversation to collaborators Nov 17, 2022
@bschorchit
Copy link

Could this PR be cherry picked in 10.23, @seaona @danjm ? It improves the UX for transactions requests that are revoking allowances (setting them to 0). It's not a blocker for the feature release though so it's ok if we prefer to leave this for 10.24.

@seaona
Copy link
Contributor

seaona commented Nov 23, 2022

oh sorry I missed the comment @bschorchit ! I will cherry pick the PR now. Thank you!!

@seaona seaona added this to the v10.23.0 milestone Nov 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Skip the first token allowance screen if a dapp is proposing a spending cap of 0
9 participants