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

[v4] [icons] fix: clean up content string API; use type-fest #5007

Merged
merged 5 commits into from
Nov 3, 2021

Conversation

adidahiya
Copy link
Contributor

Changes proposed in this pull request:

  • ⚠️ BREAK: rename getIconFontCodepoint() to getIconContentString() to better reflect its semantics
    • also update its implementation to use String.fromCodePoint()
  • Port over some of the changes from [WIP] [v4] [icons] fix icon font visual regressions #5005 related to icon name types
    • install type-fest which allows us to remove our custom implementation of camel case / snake case / etc. mapped types
    • ⚠️ BREAK: the icon svg paths records are now keyed by PascalCase icon names, not camelCase names. this reduces the number of different variations of icon names in the library from 3 (kebab-case, camelCase, and PascalCase) down to just 2 (kebab-case and PascalCase). iconNameToPathsRecordKey() has been updated accordingly, so your code will continue working if you were using this utility function.

Reviewers should focus on:

No regressions in SVG icons

Screenshot

@blueprint-bot
Copy link

upgrade TS to 4.1 everywhere

Previews: documentation | landing | table | modern colors demo

@blueprint-bot
Copy link

fix lint

Previews: documentation | landing | table | modern colors demo

@adidahiya adidahiya merged commit d2ffdf8 into next Nov 3, 2021
@adidahiya adidahiya deleted the ad/v4-fix-icon-apis branch November 3, 2021 22:21
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