From cb99f0723b94552d1b99a103ec32b11d20869f55 Mon Sep 17 00:00:00 2001 From: Volpeon Date: Sun, 20 Feb 2022 18:11:37 +0100 Subject: Added display none utility --- src/_utils.scss | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/src/_utils.scss b/src/_utils.scss index 69885ba..e0dbcc5 100644 --- a/src/_utils.scss +++ b/src/_utils.scss @@ -1,5 +1,6 @@ @use 'iro-sass/src/index' as iro; @use 'functions' as fn; +@use 'include-media/dist/include-media' as media; $dirs: ( '': '', @@ -17,6 +18,24 @@ $dirs: ( display: contents; } +@include iro.bem-utility('d-none') { + display: none; + + @each $breakpoint in map-keys(media.$breakpoints) { + @include media('<=#{$breakpoint}') { + @include suffix('#{$breakpoint}-lo') { + display: none; + } + } + + @include media('>#{$breakpoint}') { + @include suffix('#{$breakpoint}-hi') { + display: none; + } + } + } +} + @include iro.bem-utility('o-auto') { overflow: auto; } -- cgit v1.2.3-54-g00ecf