Skip to content

Commit

Permalink
feat: incorporate chakra type generation in the workflow (#1207)
Browse files Browse the repository at this point in the history
* fix: generate the types in the post-install script

* chore(types): fix icon prop types

* chore(typing): use design token

* feat: utility styles

* chore(typing): use design system tokens in storybook

* chore(typing): kick the type checker on the showcase component

* chore: update readme

* chore: new scripts

* chore: add `none` and `currentColor` color utilities
  • Loading branch information
Averethel authored Nov 15, 2024
1 parent 18e27ed commit 2b01e16
Show file tree
Hide file tree
Showing 12 changed files with 475 additions and 30 deletions.
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,22 @@ cd <project directory>
npm link ../smg-automotive-components-pkg
```
### Type generation
Chakra UI provides type generation for tokens. This is incorporated into the `typegen` script.
If you're adding new tokens you will need to re-generate the types:
```bash
$ npm run typegen
```

If you're heavily modifying the theme you can watch the changes with:
```bash
$ npm run typegen:watch
```

Since re-installing chakra ui will clean the generated types we're running the type generation as a post-install script.

## Theming

As agreed upon in the [RFC](https://github.com/smg-automotive/au-docs/discussions/3) we will handle the differences between AS24 and MS24 with two different themes. They can be then used via a theme provider that needs to wrap the application:
Expand Down
Loading

0 comments on commit 2b01e16

Please sign in to comment.