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: Icon generation now using newest version of SVGR and SVGO #1755

Merged
merged 9 commits into from
Apr 25, 2023

Conversation

KevinGhadyani-Okta
Copy link
Contributor

Description

Before, we had SVGR on v5. When the upgrade to v7 occurred, all our configs and settings were broken, but we didn't know because we hadn't generated icons in a while.

I converted the SVGR and SVGO libraries to use TypeScript so we'll get TS failures in the future if an upgrade causes icon generation to break.

I also had to change how we generated the index file. Templating it is no longer possible, so we have to maintain that file by hand ;(.

@edburyenegren-okta
Copy link
Contributor

@KevinGhadyani-Okta this updates the build but not the Icons themselves, correct?

@KevinGhadyani-Okta
Copy link
Contributor Author

@edburyenegren-okta If we had any icons that were updated in that Figma folder, then it does update them. But I didn't make changes to that folder, so everything should be the same. I did a look-over, and they looked fine to me. The Add icon went through the most significant changes, and it looks the same.

@edburyenegren-okta
Copy link
Contributor

Weird that we're getting more compression than before. I think that's 🆗 for now, and we can get a complete design review when @jordankoschei-okta updates us with the new icon set.

As long as we're okay doing some additional config tweaking if design wants less path compression, we're good to merge!

@KevinGhadyani-Okta KevinGhadyani-Okta merged commit 89a30a3 into develop Apr 25, 2023
@KevinGhadyani-Okta KevinGhadyani-Okta deleted the kg/OKTA-596520 branch April 25, 2023 19:23
jordankoschei-okta pushed a commit that referenced this pull request Apr 26, 2023
* fix: upgraded SVGR and converted to TS to address API change

* fix: upgraded odyssey-svgr to TypeScript

* fix: refactored odyssey-icons package to TypeScript

* fix: reverted to previous config in odyssey-icons

* fix: updated location and filename for svgo.config.ts

* fix: updated SVGR config to no longer build the icons/index.ts itself

* fix: updated icons per the latest SVGR v7

* docs(odyssey-storybook): added docs for how to generate new icons
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.

2 participants