// 重置input的样式
/deep/.el-input__inner {
  border-radius: 2px;
  text-align: left;
}

// 重置表单只读模式的样式
.x-form-onlyRead {
  /deep/.el-input.is-disabled .el-input__inner {
    background-color: #fff;
    cursor: default;
  }
}

// 定义表格模式下，form的展示形式
/deep/.x-form-layout-table {
  display: flex;
  flex-wrap: wrap;
  margin-top: 1px;

  .x-form-layout-table_column {
    border: 1px solid #f0f0f0;
    margin-top: -1px;
    margin-left: -1px;
  }

  $defaultItemHeight: 36px;
  .el-form-item {
    margin-bottom: 0;
    display: flex;
    min-height: $defaultItemHeight;

    .el-form-item__label {
      display: flex;
      background-color: #fafafa;
      border-right: 1px solid #f0f0f0;
      flex-shrink: 0;
      align-items: center;
      justify-content: flex-end;
    }
    .el-form-item__content {
      flex: 1;
      margin-left: 0 !important;
      border-left: 0;
      display: flex;
      align-items: center;
      padding-left: 15px;
      padding-right: 15px;
      line-height: initial;
      flex-wrap: wrap;
      overflow: hidden;
    }

    .el-form-item__error {
      z-index: 1;
      right: 0;
      top: 50%;
      transform: translateY(-50%);
      text-align: right;
      padding-right: 20px;
      pointer-events: none;
    }

    .el-input {
      height: 100%;
      width: calc(100% + 30px);
      margin-left: -15px;
      margin-right: -15px;
    }

    // 特定组件处理
    .el-input-number,
    .el-select,
    .el-slider {
      height: 100%;
      width: 100%;
      max-height: $defaultItemHeight;
    }

    // 上传组件
    .el-upload--picture-card,
    .el-upload-list__item {
      margin: 8px 4px;
      width: 80px;
      height: 80px;
      border-radius: 2px;
      line-height: 84px;
      &:first-child {
        margin-left: 0;
      }
    }

    .el-input__inner {
      border-radius: 0;
      height: 100%;
      text-align: left;
      border-color: transparent;
      &:focus {
        border-color: #409eff;
      }
    }
  }

  // input校验失败样式
  .is-error .el-input__inner {
    border-color: #f56c6c;
  }

  // 描述信息icon
  .chem-popover-icon {
    color: rgba(0, 0, 0, 0.45);
    font-size: 13px;
    margin-left: 4px;
  }
}
