1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-07-03 14:26:41 -04:00

hush SCSS deprecation warning about global variables (fixes #221)

https://sass-lang.com/documentation/variables#scope
This commit is contained in:
2021-05-01 18:07:23 -04:00
parent 298e8ed70f
commit a6c8966c53

View File

@ -41,10 +41,10 @@
// https://medium.com/@katiemctigue/how-to-create-a-dark-mode-in-sass-609f131a3995
//
// Note: ONLY color rules should go in here (eg: just `border-color`, not the whole `border` rule)
$theme-map: (); // now declaring global variables this way: https://sass-lang.com/documentation/variables#scope
@mixin colors() {
@each $theme, $map in $themes {
body.#{$theme} & {
$theme-map: () !global;
@each $key, $submap in $map {
$value: map-get(map-get($themes, $theme), "#{$key}");
$theme-map: map-merge(
@ -55,7 +55,6 @@
) !global;
}
@content;
$theme-map: null !global;
}
}
}