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

Part of #18714 and #17670:set-approval-for-all-warnings #19115

Merged
merged 4 commits into from
May 15, 2023

Conversation

dhruvv173
Copy link
Contributor

@dhruvv173 dhruvv173 commented May 13, 2023

Explanation

Replaces deprecated Typography and Button components in ui\components\app\set-approval-for-all-warning\set-approval-for-all-warning.js as well as fixes strong tag issue in Text component

Part of

Screenshots/Screencaps

Before

Screenshot 2023-05-15 at 9 21 41 AM

After

Screenshot 2023-05-15 at 9 20 52 AM

Manual Testing Steps

  • Pull this branch
  • Run yarn storybook
  • Check the SetApproveForAllWarning story

Pre-merge author checklist

  • I've clearly explained:
    • What problem this PR is solving
    • How this problem was solved
    • How reviewers can test my changes
  • Sufficient automated test coverage has been added

Pre-merge reviewer checklist

  • Manual testing (e.g. pull and build branch, run in browser, test code being changed)
  • PR is linked to the appropriate GitHub issue
  • IF this PR fixes a bug in the release milestone, add this PR to the release milestone

If further QA is required (e.g. new feature, complex testing steps, large refactor), add the Extension QA Board label.

In this case, a QA Engineer approval will be be required.

@dhruvv173 dhruvv173 requested a review from a team as a code owner May 13, 2023 15:04
@dhruvv173 dhruvv173 requested a review from legobeat May 13, 2023 15:04
@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.

@codecov
Copy link

codecov bot commented May 13, 2023

Codecov Report

Merging #19115 (1fc2f0c) into develop (c9f4202) will decrease coverage by 0.00%.
The diff coverage is 0.00%.

@@             Coverage Diff             @@
##           develop   #19115      +/-   ##
===========================================
- Coverage    69.54%   69.54%   -0.00%     
===========================================
  Files          960      960              
  Lines        36575    36574       -1     
  Branches      9497     9496       -1     
===========================================
- Hits         25434    25433       -1     
  Misses       11141    11141              
Impacted Files Coverage Δ
...al-for-all-warning/set-approval-for-all-warning.js 25.00% <0.00%> (+2.78%) ⬆️

... and 3 files with indirect coverage changes

@dhruvv173
Copy link
Contributor Author

dhruvv173 commented May 13, 2023

Hey @georgewrmarshall could you please review this PR?
I made the required changes, there has been no visual changes to the stories but theres a error in the line which required linting changes after replacing <Typography> with <Text> (refer the image below)
image
changed to
image

It shows no problems in the code, all ci tests passed aswell

@georgewrmarshall georgewrmarshall added the team-design-system All issues relating to design system in Extension label May 14, 2023
Copy link
Contributor

@georgewrmarshall georgewrmarshall left a comment

Choose a reason for hiding this comment

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

LGTM! Code coverage failing is because of linting formatting change

<Text
variant={TextVariant.headingSm}
as="h4"
fontWeight={FontWeight.Bold}
Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't need the bold weight as headingSm is already bold?

Suggested change
fontWeight={FontWeight.Bold}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I made the suggested changes but the same tests are failing again :/
Sorry for the inconvenience.

Comment on lines -16 to -19

&__bold {
color: var(--color-text-default);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Removed styles and made all text text/default color

@@ -33,7 +33,7 @@ $text-variants: (
color: var(--color-text-default);
font-family: var(--font-family-sans);

> strong {
strong {
Copy link
Contributor

Choose a reason for hiding this comment

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

Fixes issue where only the direct strong tag child would be bold font-weight. That meant if it was wrapped in a span which many of the translations are they would not receive the styles properly.

Copy link
Contributor

@georgewrmarshall georgewrmarshall left a comment

Choose a reason for hiding this comment

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

Hey @dhruvv173, by comparing the before and after screenshots in your PR description I was able to spot some issues with our Text component and strong tag. I went to the liberty of updating it in your PR I hope you don't mind. I've also updated some more deprecated components with the new ones as well as updated the PR description and before/after screenshots to the most recent. Thanks so much for your contribution!!

@dhruvv173
Copy link
Contributor Author

Hey @dhruvv173, by comparing the before and after screenshots in your PR description I was able to spot some issues with our Text component and strong tag. I went to the liberty of updating it in your PR I hope you don't mind. I've also updated some more deprecated components with the new ones as well as updated the PR description and before/after screenshots to the most recent. Thanks so much for your contribution!!

Hey @georgewrmarshall, apologies for the mistakes from my end and thanks a lot for your input and help. You've been very helpful and polite while handling issues, really appreciate it 🙏 ❤️

@georgewrmarshall
Copy link
Contributor

Hey @dhruvv173, there were no mistakes on your end. These were just further improvements that could be made that weren't outlined in the original issue. It was your added screenshots that helped with these improvements so thanks for making sure your PR description was detailed. It makes a lot of difference! 👍

@georgewrmarshall georgewrmarshall merged commit 488f212 into MetaMask:develop May 15, 2023
@github-actions github-actions bot locked and limited conversation to collaborators May 15, 2023
@dhruvv173 dhruvv173 deleted the Part-of-18714-and-17670 branch July 25, 2023 10:30
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
external-contributor team-design-system All issues relating to design system in Extension
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants