Visitar URL original
Normalize SVG icons with SVGO by thisisdano · Pull Request #4683 · uswds/uswds · GitHub
Skip to content

Normalize SVG icons with SVGO - #4683

Merged
thisisdano merged 11 commits into
developfrom
dw-normalize-icons
Jun 3, 2022
Merged

thisisdano merged 11 commits into
developfrom
dw-normalize-icons

Conversation

@thisisdano

@thisisdano thisisdano commented May 9, 2022 •

Copy link
Copy Markdown
Contributor

This uses the SVGO defaults to normalize and compress all USWDS SVGs. Our config maintains both the height/width and viewBox.

  • Added height="24" and width="24" for some icons that were missing it
  • Updated all icons with new config
  • Install svgo@2.8.0 as a dependency

Fixes #4306

@thisisdano
thisisdano requested a review from mejiaj May 9, 2022 23:40
@thisisdano thisisdano changed the title Normalize icons with SVGO Normalize SVG icons with SVGO May 9, 2022
@mejiaj
mejiaj requested a review from amyleadem May 11, 2022 17:25
@amyleadem amyleadem mentioned this pull request May 12, 2022
2 of 4 tasks

@mejiaj mejiaj left a comment

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.

Icons look good and I don't see visual problems with the icons, how the spritesheet is compiled, or using icons from sprite.

I did notice some icons had their ID's removed. This probably won't be a problem since the IDs seemed to be inconsistently used.

@amyleadem

amyleadem commented May 23, 2022 •

Copy link
Copy Markdown
Contributor

This issue appears to have existed prior to this PR, and not sure if it can/should be resolved here, but wanted to flag that navigate_far_before and navigate_far_after do not appear to accept CSS control of fill, unlike the other icons:

image

Edit: Created issue #4752 to track this issue in case this isn't the appropriate place to solve.

@thisisdano
thisisdano merged commit 73d2857 into develop Jun 3, 2022
@thisisdano
thisisdano deleted the dw-normalize-icons branch June 3, 2022 17:31
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.

Remove unnecessary cruft in SVGs

3 participants