Skip to content
This repository was archived by the owner on Dec 6, 2022. It is now read-only.

Process brand icons automagically#1188

Merged
jamie-lynch merged 1 commit intomainfrom
process-brand-icons
Nov 26, 2021
Merged

Process brand icons automagically#1188
jamie-lynch merged 1 commit intomainfrom
process-brand-icons

Conversation

@jamie-lynch
Copy link

What is the purpose of this change?

The get-icons scripts pull in the svg source for icons from the Figma API and undertakes a small amount of processing to align the source with the expected format. Previously, this process ignored brand icons as they did not follow the standard pattern. This PR updates the process to account for those differences.

The key difference is that the fill attribute is not removed from child components of the <svg> tag. There were some other inconsistencies which this script does not respect. It is hoped that those changes were the results of inconsistent practice and not deliberate differences and, therefore, the icons output by this script will remain visually consistent, despite the subtle changes to the source.

What does this change?

  • Don't filter out brand icons when getting relevant components from Figma
  • Don't remove attributes from child tags for brand icons

@jamie-lynch jamie-lynch requested a review from a team as a code owner November 26, 2021 09:31
@github-actions github-actions bot added the Icons Changes to icons label Nov 26, 2021
Copy link
Contributor

@SiAdcock SiAdcock left a comment

Choose a reason for hiding this comment

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

This is awesome, thanks so much @jamie-lynch 💎

It's probably a good idea to move icons with brand colours onto their own frame in Figma so we don't need to keep a list of those icons in here. I'll check with Akemi to see if she's happy with this. Let me know if you can think of other ways we can improve the organisation in Figma to make this script more efficient

@jamie-lynch jamie-lynch merged commit 04efa2c into main Nov 26, 2021
@jamie-lynch jamie-lynch deleted the process-brand-icons branch November 26, 2021 10:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Icons Changes to icons

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants