Last active
May 24, 2021 06:44
-
-
Save MichaelZaporozhets/32afd7a16269b989798fdf5726a5d5a7 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
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
$theme: 'Dark'; | |
$cumulus-Color: ( | |
"[Global] Color / Primary / Orange": ( | |
"name": "[Global] Color / Primary / Orange", | |
"component": "Color", | |
"data": rgba(254, 139, 22, 1), | |
"theme": "Global", | |
"category": "Primary", | |
"instance": "Orange", | |
"description": "Primary Orange Color", | |
"id": "235:9", | |
"type": "COMPONENT", | |
"value": rgba(254, 139, 22, 1) | |
), | |
"[Global] Color / Seconary / Neon Pink": ( | |
"name": "[Global] Color / Seconary / Neon Pink", | |
"component": "Color", | |
"data": rgba(255, 70, 146, 1), | |
"theme": "Global", | |
"category": "Seconary", | |
"instance": "Neon Pink", | |
"description": "?", | |
"id": "235:11", | |
"type": "COMPONENT", | |
"value": rgba(255, 70, 146, 1) | |
), | |
"[Dark] Color / Brand": ( | |
"mapTo": "[Global] Color / Primary / Orange" | |
), | |
"[Light] Color / Brand": ( | |
"mapTo": "[Global] Color / Seconary / Neon Pink" | |
) | |
); | |
; | |
@function getColor($name) { | |
$item: map-get($cumulus-Color, "[#{$theme}] Color / #{$name}"); | |
$mapToName: map-get($item, 'mapTo'); | |
$resolvedItem: map-get($cumulus-Color, $mapToName); | |
@return map-get($resolvedItem, 'value'); | |
} | |
h1 { | |
color: getColor('Brand'); | |
} |
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
h1 { | |
color: #fe8b16; | |
} |
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
{ | |
"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