移动端1px

313 阅读1分钟

笔记

比较好的方法是才用css伪类加缩放来解决

单条border

    .shop_select {
      height: 30px;
      width: 30px;
      position: relative;
      &:after {
        content: '';
        position: absolute;
        right: 0;
        bottom: 0;
        background: #dddddd;
        width: 100%;
        height: 1px;
        transform: scaleY(0.5);
        transform-origin: 0 100%;
      }

4条border

          .show_wrap {
            position: relative;
            height: 80px;
            width: 80px;
            &:after {
              position: absolute;
              content: '';
              top: 0;
              left: 0;
              border: 1px solid #dddddd;
              box-sizing: border-box;
              width: 200%;
              height: 200%;
              transform: scale(0.5);
              transform-origin: left top;
            }