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

fix: fix snaps permission flow ui #30116

Merged
merged 6 commits into from
Feb 5, 2025

Conversation

ffmcgee725
Copy link
Member

@ffmcgee725 ffmcgee725 commented Feb 4, 2025

Issue described here

This commit fixes the snaps permission flow UI bug detected after #29824

Screenshots after fix:

Screenshot 2025-02-04 at 20 20 37 Screenshot 2025-02-04 at 20 20 53

Description

Open in GitHub Codespaces

Related issues

Fixes: #30087

Manual testing steps

  1. Go to this page...

Screenshots/Recordings

Before

After

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Comment on lines +55 to 59
[Caip25EndowmentPermissionName]: ({ t, isLegacySwitchEthereumChain }) => {
if (isLegacySwitchEthereumChain) {
return {
label: t('permission_walletSwitchEthereumChain'),
leftIcon: IconName.Wifi,
Copy link
Member Author

Choose a reason for hiding this comment

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

we are now pulling the flag directly from the request object provided by calling approvalController.addAndShowApprovalRequest for wallet_switchEthereumChain legacy request.

For all other flows, UI should remain untouched now with no unpredictable behaviour 👍🏾

@ffmcgee725 ffmcgee725 marked this pull request as ready for review February 4, 2025 19:39
@ffmcgee725 ffmcgee725 requested a review from a team as a code owner February 4, 2025 19:39
@metamaskbot
Copy link
Collaborator

Builds ready [43fbe34]
Page Load Metrics (1576 ± 75 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint28821721515321154
domContentLoaded14202160155915574
load14302174157615675
domInteractive2290402210
backgroundConnect65217115
firstReactRender1596452713
getState44911126
initialActions0482105
loadScripts9981645113812862
setupStore65911115
uiStartup16032382179718689
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 76 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link
Contributor

@adonesky1 adonesky1 left a comment

Choose a reason for hiding this comment

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

LGTM!

@ffmcgee725 ffmcgee725 enabled auto-merge February 4, 2025 21:48
@ffmcgee725 ffmcgee725 added this pull request to the merge queue Feb 5, 2025
auto-merge was automatically disabled February 5, 2025 10:18

Pull Request is not mergeable

Merged via the queue into main with commit d62b731 Feb 5, 2025
74 checks passed
@ffmcgee725 ffmcgee725 deleted the fix/account-permissions-snaps-caip25 branch February 5, 2025 10:33
@github-actions github-actions bot locked and limited conversation to collaborators Feb 5, 2025
@metamaskbot metamaskbot added the release-12.13.0 Issue or pull request that will be included in release 12.13.0 label Feb 5, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-12.13.0 Issue or pull request that will be included in release 12.13.0 team-wallet-api-platform
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Wrong copy when requesting account permissions for Snaps
4 participants