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

Update Figma import script + move generated code to separate files #65

Merged
merged 6 commits into from
Dec 20, 2024

Conversation

mkrause
Copy link
Collaborator

@mkrause mkrause commented Dec 18, 2024

This PR refactors the scripts/import.ts script:

  • Add a new command to import primitive color values
  • Automatically write the generated code to files in the new src/styles/generated directory (rather than the user having to do it manually)
  • Also generate TypeScript files to read the tokens if necessary (e.g. to support the Colors.mdx Storybook documentation)

TODO:

  • Give the same treatment to the other token types: font sizes, border radii, and sizings
  • Update the components that are using tokens that are now missing in Figma.

@mkrause mkrause self-assigned this Dec 18, 2024
@spli02 spli02 self-requested a review December 19, 2024 12:55
scripts/import.ts Outdated Show resolved Hide resolved
scripts/import.ts Show resolved Hide resolved
scripts/import.ts Show resolved Hide resolved
@mkrause mkrause requested a review from spli02 December 20, 2024 13:09
@mkrause mkrause merged commit c218c94 into master Dec 20, 2024
2 checks passed
@mkrause mkrause deleted the mkrause/241218-refactor-codegen branch December 20, 2024 13:16
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