@import "./config.scss"; $B: null; $BE: null; @mixin b($block) { $temp-block: $B; $temp-block-element: $BE; $B: $namespace + "-" + $block !global; $BE: $B!global; .#{$B} { @content; } $B: $temp-block !global; $BE: $temp-block-element !global; } @mixin e($elements...) { $temp-block-element: $BE; $BEs: ''; @each $element in $elements { $BE: $B + "__" + $element !global; .#{$BE} { @content } } $BE: $temp-block-element !global; } @mixin m($modifiers...) { $BEMs: ''; @for $i from 0 to length($modifiers) { $modifier: nth($modifiers, $i + 1); @if $i == 0 { $BEMs: '&.' + $BE + '--' + $modifier; } @else { $BEMs: $BEMs + ', &.' + $BE + '--' + $modifier; } } #{$BEMs} { @content } } @mixin detachedContentWrapper { position: fixed; left: 0; top: 0; width: 0; height: 0; overflow: visible; } @mixin detachedContent { position: fixed; }