Summary Files Commits Branches @commit @diff @stats
path: root / src / chips.less
blob: 95302643f4c7fedb5f8955466321ff04085cbe23 (plain) (blame)
1
2
3
4
5
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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
// Chips
.chip {
  display: flex;
  padding: .5rem;
  border-radius: .3rem;
  margin: 0;
  list-style: none;
  align-items: center;
  align-content: space-around;

  &:hover,
  &.selected {
    background-color: lighten(@control-color, 20%);
  }

  .chip-list-icon {
    flex: 0 0 auto;
  }
  .chip-list-content {
    flex: 1 1 auto;
    padding: 0 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .chip-list-action {
    flex: 0 0 auto;
  }
}

// Small chips
.chip-sm {
  display: inline-flex;
  width: auto;
  height: 2.4rem;
  padding: .3rem .6rem;
  border-radius: .3rem;
  font-size: 1.2rem;
  vertical-align: middle;
  align-items: center;
  background-color: @core-border-color;
  border: .1rem solid darken(@core-border-color, 2%);
  text-decoration: none;

  &:hover,
  &:focus {
    background-color: darken(@core-border-color, 4%);
    border-color: darken(@core-border-color, 6%);
  }

  .chip-name {
    margin-left: .4rem;
  }
  .avatar {
    width: 1.6rem;
    height: 1.6rem;
    font-size: .8rem;
  }
}

// Autocomplete
.form-autocomplete {
  position: relative;

  .form-autocomplete-input {
    display: block;
    width: 100%;
    max-width: 100%;
    min-height: 3.2rem;
    background-color: #fff;
    padding: .3rem .3rem 0 .3rem;
    border: .1rem solid @control-color;
    border-radius: .3rem;
    color: @body-font-color;
    font-size: 1.4rem;
    line-height: 1.6rem;
    outline: 0;

    .chip {
      margin-bottom: .3rem;
    }

    .form-input {
      display: inline-block;
      border-color: transparent;
      background-color: #fff;
      width: auto;
      height: 2.4rem;
      padding: .3rem;
      margin-bottom: .3rem;
      vertical-align: top;
    }
  }

  .form-autocomplete-list {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1988;
    display: block;
    width: 100%;
    height: auto;
    padding: .3rem;
    margin: -.4rem 0 0 0;
    border: .1rem solid @control-color;
    border-top: transparent;
    border-bottom-left-radius: .3rem;
    border-bottom-right-radius: .3rem;
    background-color: #fff;

    &::before {
      content: '';
      display: block;
      width: 100%;
      height: .5rem;
      border-top: .1rem solid @core-border-color;
    }
  }
}