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(icons): use rotated thumbs-up as thumbs-down #9107

Merged
merged 2 commits into from
Jun 16, 2023

Conversation

caugner
Copy link
Contributor

@caugner caugner commented Jun 16, 2023

Summary

(MP-481)

Problem

The thumbs-up and thumbs-down icons are not the same, but the thumbs-down button is slightly bigger and so more prominent, skewing our results.

Solution

Replace the thumbs-down.svg by reusing thumbs-up.svg and adding style="transform: rotate(180deg);".


Screenshots

Before

image

After

image

How did you test this change?

Opened http://localhost:3000/en-US/docs/Learn/HTML and verified that the icon has the same size.

The thumbs-down icon was more prominent than the thumbs-up icon.
@caugner caugner requested a review from LeoMcA June 16, 2023 16:50
Copy link
Member

@LeoMcA LeoMcA left a comment

Choose a reason for hiding this comment

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

Ha, I was a little confused how this worked at first, but it does work, so approved, however:

Alternatively, it might be better to use SVG's transform attribute to rotate?

Or, we could save the most marginal bit of bandwidth by removing the thumbs-down.svg and just setting the icon-thumbs-down class in icon scss file to use the thumbs-up.svg and the rotate css.

@caugner caugner merged commit f05db31 into main Jun 16, 2023
@caugner caugner deleted the reuse-rotated-thumbs-up-as-thumbs-down branch June 16, 2023 17:19
@yarusome
Copy link
Contributor

FWIW, the original orientation of thumb-down can be achived by scaleY(-1) on thumb-up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants