简体   繁体   English

断点 sass mixin

[英]Breakpoint sass mixin

Very very simple HTML SASS Why the breakpoint does not work and does not change the background and does not expand the size of the table HTML <table >nocontent</table>非常非常简单 HTML SASS 为什么断点不起作用 不改变背景 不扩大表格大小 HTML <table >nocontent</table>

CSS CSS

$lg: 992px;
$xl: 1200px;
$xxl: 1400px;

$md : 768px;
@mixin for-up($size) {

  @media screen and (max-device-width: $size) {
    @content;

  }

  .table-main {
    height: 100vh;
    border: greenyellow solid;

    @include for-up($sm)
    {
      background-color: black;
      width: 100%;
      max-width: none;
    }
  }
}

$md : 768px;
@mixin for-up($size) {

  @media screen and (max-device-width: $size) {
    @content;

  }

.table-main {
  height: 100vh;
  border: greenyellow solid;

@include for-up($md)
  {
      background-color: black;
      width: 100%;
      max-width: none;
  }
  }
}

just add the proper starting and closing brackets, and than you good to go.只需添加正确的开始和结束括号,而不是 go。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM