// 清除浮动
.clearfix() {
  &:before,
  &:after {
    display: table;
    content: ' ';
  }

  &:after {
    clear: both;
  }
}

// 水平居中
.center-block() {
  display: block;
  margin-right: auto;
  margin-left: auto;
}

// 尺码助手
.size(@width, @height) {
  width: @width;
  height: @height;
}

.square(@size) {
  .size(@size, @size);
}

// 可调整大小的文本区域
.resizable(@direction: both) {
  // Safari fix
  overflow: auto;
  // Options: horizontal, vertical, both
  resize: @direction;
}

// 截断文本
.text-truncate() {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

// mixins函数
.set-text-color() {
  color: @zaui-text;
}

.set-brand-color() {
  color: @zaui-brand;
}

.set-disabled-color() {
  color: @zaui-disabled-text !important;
  background: @zaui-disabled-bg !important;
}

.set-text-size() {
  font-size: @zaui-font-size;
}

.set-lg-text-size() {
  font-size: calc(@zaui-font-size + 2px);
}

.set-sm-text-size() {
  font-size: calc(@zaui-font-size - 2px);
}

.pro-icon.drag-icon {
  // height: 20px;
  // width: 20px;
  margin-right: var(--zaui-space-size-xs, 4px);
  cursor: move;
}
