Created
June 24, 2021 02:19
-
-
Save takaya1992/fc435e292ffc7a89258f13c0abddeb26 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
$sns: ( | |
"apple": ( | |
"background": #ccc, | |
"color": #ccc, | |
), | |
"twitter": ( | |
"background": #ccc, | |
"color": #ccc, | |
), | |
"facebook": ( | |
"background": #ccc, | |
"color": #ccc, | |
), | |
"mixi": ( | |
"background": #ccc, | |
"color": #ccc, | |
), | |
); | |
@mixin button-color($background, $color) { | |
background: $background; | |
color: $color; | |
} | |
.sns-button { | |
@each $name, $colors in $sns { | |
&.sns-button--#{$name} { | |
@include button-color( | |
$background: map-get($colors, "background"), | |
$color: map-get($colors, "color") | |
); | |
} | |
} | |
} |
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
.sns-button.sns-button--apple { | |
background: #ccc; | |
color: #ccc; | |
} | |
.sns-button.sns-button--twitter { | |
background: #ccc; | |
color: #ccc; | |
} | |
.sns-button.sns-button--facebook { | |
background: #ccc; | |
color: #ccc; | |
} | |
.sns-button.sns-button--mixi { | |
background: #ccc; | |
color: #ccc; | |
} |
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