Style once, use everywhere.
"A Style Dictionary uses design tokens to define styles once and use those styles on any platform or language. It provides a single place to create and edit your styles, and exports these tokens to all the places you need." - Amazon
Run:
npm run build
npm run test
npm run ci
You can create your own theme and extend all design tokens by forking this repo. After forking please look at the example custom tokens and custom themes on the branch called: custom-tokens-and-themes-example Run:
git checkout custom-tokens-and-themes-example
All files you add/create into your forked version will be always safe from being overriden when you get latest from upstream (qgds-tokens).
Please add a reference of your new theme on $metadata.json and on $themes.json. Please see the example branch for more info: custom-tokens-and-themes-example
Run:
npm run build
npm run test
npm run build:package
You should see no errors.
Run:
npm run build
npm run test
npm run ci
Using Tokens Studio to update tokens directly from Figma is welcomed. Sometimes, Tokens Studio may change or add $metadata and $theme tokens that had already been defined. In case this happens, we've added *.original to assist you in reverting back to how build-tokens is expecting these files to be configured.
https://github.com/amzn/style-dictionary
https://github.com/tokens-studio/sd-transforms
There is two publish subsystems, one is to npmjs and the other is to github repo package