• sass mixin 持续更新


    控制多行显示省略号...

    //文字溢出省略号
    @mixin coveText($num:1)
    { @if $num == 1{ white-space: normal; overflow: hidden; text-overflow: ellipsis; } @else{ display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: $num; overflow: hidden; } }

     0.5像素border

    @mixin borderPart($color,$position:null,$type:solid) {
      position: relative;
      &:before {
        content: '';
        position: absolute;
        width: 200%;
        height: 200%;
        top: 0;
        transform-origin: 0 0;
        transform: scale(0.5, 0.5);
        box-sizing: border-box;
        @if $position == null {
          border: 1px $type $color;
        } @else if $position == top {
          border-top: 1px $type $color;
        } @else if $position == left {
          border-left: 1px $type $color;
        } @else if $position == right {
          border-right: 1px $type $color;
        } @else if $position == bottom {
          border-bottom: 1px $type $color;
        }
      }
    }
  • 相关阅读:
    Linux_vi编辑器
    Linux_几个符号命令
    Linux_权限
    Linux_用户/用户组
    Linux_文件及文件夹[创建][复制][移动][删除][重命名]
    Linux_文件查看
    Linux_初识
    码农网站
    学习网站
    软件设计师考试范围
  • 原文地址:https://www.cnblogs.com/lvyueyang/p/7443126.html
Copyright © 2020-2023  润新知