-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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: add privacy mode #28021
feat: add privacy mode #28021
Conversation
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. |
Builds ready [02b49f1]
Page Load Metrics (2013 ± 72 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a few comments on the SensitiveText
component
ui/components/component-library/sensitive-text/sensitive-text.tsx
Outdated
Show resolved
Hide resolved
ui/components/component-library/sensitive-text/sensitive-text.tsx
Outdated
Show resolved
Hide resolved
ui/components/component-library/sensitive-text/sensitive-text.tsx
Outdated
Show resolved
Hide resolved
ui/components/component-library/sensitive-text/sensitive-text.types.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @jonybur, this is looking great! Could we pull out the SensitiveText
component into its own PR for review? This way, we can ensure the docs, tests, and Storybook stories accurately reflect the component, making it more valuable for the rest of the org. Let me know if you have any questions or need support!
Builds ready [8fc378a]
Page Load Metrics (2052 ± 128 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [72198f0]
Page Load Metrics (2075 ± 71 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
…28089) ## **Description** This PR updates the Storybook stories for the `SensitiveText` component to align with extension component library standards. The changes include: - Updating Storybook stories to use the CSF 3.0 format for better organization and future-proofing. - Converting `README.md` to `README.mdx`, leveraging Storybook stories for documentation and improving the accessibility and usability of the component documentation. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28089?quickstart=1) ## **Related issues** Related: #28021 ## **Manual testing steps** 1. Run Storybook locally and navigate to the `SensitiveText` component. 2. Verify that the stories render correctly in the CSF 3.0 format. 3. Check that the new `README.mdx` renders properly in the Storybook Docs tab. ## **Screenshots/Recordings** ### **Before** https://github.com/user-attachments/assets/e1804283-72d2-45e6-829b-e2ce38776e1e ### **After** https://github.com/user-attachments/assets/5d776529-6fe3-4646-90f2-57f2ceceefd6 ## **Pre-merge author checklist** - [x] I’ve followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I’ve completed the PR template to the best of my ability. - [x] I’ve included tests if applicable. - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable. - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I’ve manually tested the PR (e.g., pulled and built the branch, ran the app, tested the code being changed). - [ ] I confirm that this PR addresses all acceptance criteria and includes the necessary testing evidence, such as recordings or screenshots.
Builds ready [475a2d8]
Page Load Metrics (1883 ± 70 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left one small comment!
Builds ready [ac9c738]
Page Load Metrics (1905 ± 60 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes in files owned by confirmation team look good 👍
<!-- Please submit this PR as a draft initially. Do not mark it as "Ready for review" until the template has been completely filled out, and PR status checks have passed at least once. --> ## **Description** Adds a privacy mode toggle (an eye icon next to the main balance) that hides all sensitive information/token balances **UPDATE** Here is feedback from @amandaye0h and has been currently implemented in this PR [Figma](https://www.figma.com/design/aMYisczaJyEsYl1TYdcPUL/Portfolio-View?node-id=6219-62460&t=aeTv5cenoUPUrg1c-4) [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28021?quickstart=1) ## **Related issues** Fixes: MetaMask/MetaMask-planning#3416 MetaMask/MetaMask-planning#3418 MetaMask/MetaMask-planning#3419 ## **Manual testing steps** 1. Go to the Wallet page 2. Click on the new Eye icon next to the balance 3. All balances should be hidden 4. Click on the Eye icon once again 5. All balances should be shown ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** <!-- [screenshots/recordings] --> ### **After** https://github.com/user-attachments/assets/2950ac0c-593d-4daa-aa5d-3e6c3a2d5598 https://github.com/user-attachments/assets/6371c2a2-04fa-48a3-8744-991a1540d5f2 <img width="496" alt="Screenshot 2024-10-22 at 18 43 19" src="https://github.com/user-attachments/assets/d7c2f681-75c7-4be0-921b-f3c5186f8d4a"> ## **Pre-merge author checklist** - [ ] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [ ] I've completed the PR template to the best of my ability - [ ] I’ve included tests if applicable - [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **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. --------- Co-authored-by: vinnyhoward <vincenguyenhoward@gmail.com> Co-authored-by: David Walsh <davidwalsh83@gmail.com>
Builds ready [3d0eeda]
Page Load Metrics (1964 ± 65 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
…28089) ## **Description** This PR updates the Storybook stories for the `SensitiveText` component to align with extension component library standards. The changes include: - Updating Storybook stories to use the CSF 3.0 format for better organization and future-proofing. - Converting `README.md` to `README.mdx`, leveraging Storybook stories for documentation and improving the accessibility and usability of the component documentation. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28089?quickstart=1) ## **Related issues** Related: #28021 ## **Manual testing steps** 1. Run Storybook locally and navigate to the `SensitiveText` component. 2. Verify that the stories render correctly in the CSF 3.0 format. 3. Check that the new `README.mdx` renders properly in the Storybook Docs tab. ## **Screenshots/Recordings** ### **Before** https://github.com/user-attachments/assets/e1804283-72d2-45e6-829b-e2ce38776e1e ### **After** https://github.com/user-attachments/assets/5d776529-6fe3-4646-90f2-57f2ceceefd6 ## **Pre-merge author checklist** - [x] I’ve followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I’ve completed the PR template to the best of my ability. - [x] I’ve included tests if applicable. - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable. - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I’ve manually tested the PR (e.g., pulled and built the branch, ran the app, tested the code being changed). - [ ] I confirm that this PR addresses all acceptance criteria and includes the necessary testing evidence, such as recordings or screenshots.
Description
Adds a privacy mode toggle (an eye icon next to the main balance) that hides all sensitive information/token balances
UPDATE
Here is feedback from @amandaye0h and has been currently implemented in this PR
Figma
Related issues
Fixes:
https://github.com/MetaMask/MetaMask-planning/issues/3416
https://github.com/MetaMask/MetaMask-planning/issues/3418
https://github.com/MetaMask/MetaMask-planning/issues/3419
Manual testing steps
Screenshots/Recordings
Before
After
nocontent2.mp4
demo2.mp4
Pre-merge author checklist
Pre-merge reviewer checklist