Skip to content

cherry-pick: feat improvement for how we display big and small numbers#25720

Merged
jpuri merged 4 commits intoVersion-v12.1.0from
permit_value_display_fix
Jul 11, 2024
Merged

cherry-pick: feat improvement for how we display big and small numbers#25720
jpuri merged 4 commits intoVersion-v12.1.0from
permit_value_display_fix

Conversation

@jpuri
Copy link
Copy Markdown
Contributor

@jpuri jpuri commented Jul 9, 2024

Description

Improvement in how we display big and small token value on permit signature page.

Related issues

Fixes: https://github.com/MetaMask/MetaMask-planning/issues/2649

Manual testing steps

  1. Go to test DAPP
  2. Submit permit signature request
  3. Check the token value in page displayed

Screenshots/Recordings

Screenshot 2024-06-20 at 5 29 42 PM Screenshot 2024-06-20 at 5 29 34 PM

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.

@jpuri jpuri added confirmation-redesign team-confirmations Push issues to confirmations team release-12.1.0 Issue or pull request that will be included in release 12.1.0 labels Jul 9, 2024
@jpuri jpuri requested review from a team as code owners July 9, 2024 15:42
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jul 9, 2024

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
Copy Markdown
Collaborator

Builds ready [d5c603f]
Page Load Metrics (461 ± 367 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint691551162311
domContentLoaded87334189
load432165461765367
domInteractive87334189
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 3.3 KiB (0.05%)
  • common: 0 Bytes (0.00%)

@codecov
Copy link
Copy Markdown

codecov bot commented Jul 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.58%. Comparing base (bb39806) to head (d5c603f).

Additional details and impacted files
@@                    Coverage Diff                    @@
##           permit_token_decimal_fix   #25720   +/-   ##
=========================================================
  Coverage                     69.58%   69.58%           
=========================================================
  Files                          1360     1360           
  Lines                         48190    48200   +10     
  Branches                      13304    13306    +2     
=========================================================
+ Hits                          33529    33536    +7     
- Misses                        14661    14664    +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Base automatically changed from permit_token_decimal_fix to Version-v12.1.0 July 10, 2024 22:36
@jpuri jpuri merged commit ce982e3 into Version-v12.1.0 Jul 11, 2024
@jpuri jpuri deleted the permit_value_display_fix branch July 11, 2024 09:12
@github-actions github-actions bot locked and limited conversation to collaborators Jul 11, 2024
tokenValue: formatAmount('en-US', valueBN),
tokenValueMaxPrecision: formatAmountMaxPrecision('en-US', valueBN),
};
}, [tokenDecimals, value]);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

parseInt(value, 10) / Math.pow(10, tokenDecimals),
);
const tokenValue = formatAmount('en-US', valueBN);
const tokenValueMaxPrecision = formatAmountMaxPrecision('en-US', valueBN);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

confirmation-redesign release-12.1.0 Issue or pull request that will be included in release 12.1.0 team-confirmations Push issues to confirmations team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants