Skip to content

Commit

Permalink
chore: simplify reserved color values check
Browse files Browse the repository at this point in the history
  • Loading branch information
viktorrusakov committed Feb 3, 2023
1 parent 38898a1 commit db1201a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tokens/style-dictionary.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ const { formattedVariables, fileHeader, sortByReference } = StyleDictionary.form

const colorTransform = (token) => {
const { value, modify = [], original } = token;
const inheritedPropsKeywords = ['inherit', 'initial', 'revert', 'unset'];
const reservedColorValues = ['inherit', 'initial', 'revert', 'unset'];

if (inheritedPropsKeywords.includes(original.value) || inheritedPropsKeywords.includes(value)) {
if (reservedColorValues.includes(original.value)) {
return original.value;
}

Expand Down

0 comments on commit db1201a

Please sign in to comment.