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

Semantic colors codemod #411

Merged
merged 18 commits into from
Jan 30, 2024
Merged

Semantic colors codemod #411

merged 18 commits into from
Jan 30, 2024

Conversation

martimalek
Copy link
Contributor

What

Adds a codemod to automatically migrate usages of SemanticColors and themeGet to getSemanticValue

SemanticColors example
From

SemanticColors.button.primary.backgroundDisabled

to

getSemanticValue('background-element-disabled-default')

themeGet example
From

themeGet('semanticColors.text.primary')

To

getSemanticValue('foreground-primary')

Why

To ease the migration effort throughout our codebase

How

  • Create semantic-colors-to-new-theme codemod
  • Dropped table.zebraStyles.backgroundSecondary color, it is not used in any project

Closes #395

@martimalek martimalek merged commit cb69cf6 into next Jan 30, 2024
10 checks passed
@martimalek martimalek deleted the semantic-colors-codemod branch January 30, 2024 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants