Created
November 15, 2021 15:10
-
-
Save ChucKN0risK/c22aea648659d9d9f6eb6576d2b39b46 to your computer and use it in GitHub Desktop.
Fixed config for Szymon
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"repository": "@juul/atom", | |
"rules": [ | |
{ | |
"name": "Design Tokens", | |
"path": "src/styles/atom/tokens/", | |
"filter": { | |
"types": [ | |
"color", | |
"measurement", | |
"shadow" | |
] | |
}, | |
"parsers": [ | |
{ | |
"name": "to-scss-map", | |
"options": { | |
"variableName": { | |
"color": "colors", | |
"measurement": "measurements", | |
"shadow": "shadows" | |
}, | |
"fileName": { | |
"color": "colors", | |
"measurement": "measurements", | |
"shadow": "shadows" | |
}, | |
"omitFunctionAndMixin": true, | |
"splitBy": "/" | |
} | |
} | |
] | |
}, | |
{ | |
"name": "Design Tokens", | |
"path": "src/styles/atom/tokens/typography.scss", | |
"filter": { | |
"types": [ | |
"textStyle" | |
] | |
}, | |
"parsers": [ | |
{ | |
"name": "round-number", | |
"options": { | |
"keys": [ | |
"value.letterSpacing.value.measure" | |
], | |
"precision": 2, | |
"mode": "auto" | |
} | |
}, | |
{ | |
"name": "to-scss-mixin-text-style", | |
"options": { | |
"exclude": [ | |
"text-align", | |
"vertical-align", | |
"font-family" | |
], | |
"prefix": "font-", | |
"genericFamily": "sans-serif" | |
} | |
} | |
] | |
}, | |
{ | |
"name": "Assets / Vector", | |
"path": "src/components/core/Icon/vectors/", | |
"filter": { | |
"types": [ | |
"vector" | |
] | |
}, | |
"parsers": [ | |
{ | |
"name": "name-assets-files-by-pattern", | |
"options": { | |
"pattern": "{{name}}.tsx" | |
} | |
}, | |
{ | |
"name": "svg-to-jsx", | |
"options": { | |
"prepend": "import React from 'react';", | |
"formatConfig": { | |
"exportDefault": true, | |
"singleQuote": true | |
} | |
} | |
}, | |
{ | |
"name": "replace-string", | |
"options": { | |
"keys": [ | |
"value.content" | |
], | |
"regex": { | |
"pattern": "style=\\\"mask-type:alpha\\\"", | |
"flags": "g" | |
}, | |
"replaceBy": "style={{ maskType: 'alpha' }}" | |
} | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment