sass-site/source/assets/sass/config/_utility.scss
2023-02-09 15:15:01 -06:00

19 lines
563 B
SCSS

@use 'sass:map';
@use 'sass:meta';
@use 'scale';
@use 'color';
/// Returns all the variables defined in a module,
/// as a map from variable names (without $)
/// to the values of those variables.
/// @link https://sass-lang.com/documentation/modules/meta#module-variables
$scale: meta.module-variables('scale');
$colors: meta.module-variables('color');
// Loops through and returns all tokens from above files as CSS variables.
@mixin tokens($map, $prefix: null) {
@each $tokenname, $tokenvalue in $map {
--#{$prefix}#{$tokenname}: #{$tokenvalue};
}
}