Created
September 28, 2022 08:17
-
-
Save believer/113731ab1f66b9e28c6b402f9cfbda4d to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
This file contains hidden or 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
// Defined in asset library | |
$color-data-blue: #5d8aff; | |
$color-data-purple: #a858ff; | |
// Map colors | |
$colors: ( | |
blue: $color-data-blue, | |
purple: $color-data-purple, | |
// and so on... | |
); | |
// Generate class names | |
@each $name, $color in $colors { | |
.data-#{$name} { | |
background-color: $color; | |
} | |
} |
This file contains hidden or 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
.data-blue { | |
background-color: #5d8aff; | |
} | |
.data-purple { | |
background-color: #a858ff; | |
} |
This file contains hidden or 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
{ | |
"sass": { | |
"compiler": "dart-sass/1.32.12", | |
"extensions": {}, | |
"syntax": "SCSS", | |
"outputStyle": "expanded" | |
}, | |
"autoprefixer": false | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment