Blame view

src/styles/btn.scss 1.91 KB
赵千 committed
1 2 3 4
@import './variables.scss';

@mixin colorBtn($color) {
  background: $color;
任超 committed
5
  color: #fff;
赵千 committed
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101

  &:hover {
    color: #fff;
    background-color: $color;

    &:before,
    &:after {
      background: $color;
    }
  }
}

.blue-btn {
  @include colorBtn($blue)
}

.light-blue-btn {
  @include colorBtn($light-blue)
}

.red-btn {
  @include colorBtn($red)
}

.pink-btn {
  @include colorBtn($pink)
}

.green-btn {
  @include colorBtn($green)
}

.tiffany-btn {
  @include colorBtn($tiffany)
}

.yellow-btn {
  @include colorBtn($yellow)
}

.pan-btn {
  font-size: 14px;
  color: #fff;
  padding: 14px 36px;
  border-radius: 8px;
  border: none;
  outline: none;
  transition: 600ms ease all;
  position: relative;
  display: inline-block;

  &:hover {
    background: #fff;

    &:before,
    &:after {
      width: 100%;
      transition: 600ms ease all;
    }
  }

  &:before,
  &:after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    height: 2px;
    width: 0;
    transition: 400ms ease all;
  }

  &::after {
    right: inherit;
    top: inherit;
    left: 0;
    bottom: 0;
  }
}

.custom-button {
  display: inline-block;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  background: #fff;
  color: #fff;
  -webkit-appearance: none;
  text-align: center;
  box-sizing: border-box;
  outline: 0;
  margin: 0;
  padding: 10px 15px;
  font-size: 14px;
  border-radius: 4px;
}
任超 committed
102

赵千 committed
103
// 搜索框按钮的位置
104
.btnColRight {
赵千 committed
105 106
  box-sizing: border-box;
  text-align: right;
任超 committed
107 108
}

109 110 111 112 113 114 115
// 搜索框按钮的位置 左
.btnColLeft {
  box-sizing: border-box;
  text-align: left;
}


任超 committed
116 117 118
.title-block {
  display: inline-block;
  position: relative;
任超 committed
119 120 121 122 123 124
  text-align: left;
  width: 100%;
  line-height: 26px;
  padding-left: 10px;
  font-size: 16px;
  border-bottom: 1px solid $borderColor;
任超 committed
125 126
}

任超 committed
127 128 129 130
.title-block:after {
  content: " ";
  width: 0;
  height: 16px;
任超 committed
131
  position: absolute;
任超 committed
132 133 134
  border-left: 3px solid $light-blue;
  left: 0;
  top: 5px;
任超 committed
135
}