scss CSS-断点,mixins.scss

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了scss CSS-断点,mixins.scss相关的知识,希望对你有一定的参考价值。

@mixin for-phone-only {
  @media (max-width: 599px) { @content; }
}
@mixin for-tablet-portrait-up {
  @media (min-width: 600px) { @content; }
}
@mixin for-tablet-landscape-up {
  @media (min-width: 900px) { @content; }
}
@mixin for-desktop-up {
  @media (min-width: 1200px) { @content; }
}
@mixin for-big-desktop-up {
  @media (min-width: 1800px) { @content; }
}

// usage
.my-box {
  padding: 10px;
  
  @include for-desktop-up {
    padding: 20px;
  }
}

以上是关于scss CSS-断点,mixins.scss的主要内容,如果未能解决你的问题,请参考以下文章

scss CSS-断点,mixins.scss

scss CSS-断点,mixins.scss

scss CSS-断点,mixins.scss

scss Mixins.scss

scss mixins.scss

scss mixins.scss