nbotond20/SVG Color Replace
Replace colors in SVG files with CSS variables from a JSON file token set
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| svg-folder-path | The path to the folder containing the SVG files to process | yes | — |
| token-set-input-paths | The path to the JSON file containing the token set | yes | — |
| base-token-set-input-path | The path to the JSON file containing the base token set | yes | — |
| dry-run | If true, the action will not write any files, only log the changes that would be made | no | false |
| token-set-keys | The keys in the token set to use for the color replacement (e.g. "color.primary") | no | — |
| prefer-deep-key | If true, the action will prefer a deep key in the token set (e.g. "color.primary.500") over a shallow key (e.g. "color.primary") | no | false |
| file-extensions | The file extensions to process (e.g. ".svg, .tsx") | no | — |
| inject-into-html | If true, the action will inject the CSS variables into the head of the HTML file | no | false |
| html-path | The path to the HTML file to inject the CSS variables into | no | — |
| css-file-output-folder-path | The path to the folder to output the CSS file to | no | — |
| css-file-href-prefix | The prefix to add to the CSS file href in the HTML file | no | — |
| svg-output-folder-path | The path to the folder to output the SVG files to | no | — |
| mark-generated-files | If true, the action will add .generated to the file name of the generated files | no | false |
Outputs
no outputs