Skip to content

Instantly share code, notes, and snippets.

@davidhellmann
Created March 18, 2022 12:25
Show Gist options
  • Save davidhellmann/603f2505729c2bafc206ccc041e83556 to your computer and use it in GitHub Desktop.
Save davidhellmann/603f2505729c2bafc206ccc041e83556 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
@use 'sass:map';
$themes: ['default', 'yellow', 'purple-yellow', 'gold', 'midnight-blue', 'purple-blue'];
@mixin themesIcon($icon) {
@each $theme in $themes {
.t-color--#{$theme} & {
background-image: url('~ASSETS/svg/single/#{$theme}/#{$icon}.svg');
}
}
}
.blabla__image {
@include themesIcon('dot-ring');
}
.t-color--default .blabla__image {
background-image: url("~ASSETS/svg/single/default/dot-ring.svg");
}
.t-color--yellow .blabla__image {
background-image: url("~ASSETS/svg/single/yellow/dot-ring.svg");
}
.t-color--purple-yellow .blabla__image {
background-image: url("~ASSETS/svg/single/purple-yellow/dot-ring.svg");
}
.t-color--gold .blabla__image {
background-image: url("~ASSETS/svg/single/gold/dot-ring.svg");
}
.t-color--midnight-blue .blabla__image {
background-image: url("~ASSETS/svg/single/midnight-blue/dot-ring.svg");
}
.t-color--purple-blue .blabla__image {
background-image: url("~ASSETS/svg/single/purple-blue/dot-ring.svg");
}
{
"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