-
Notifications
You must be signed in to change notification settings - Fork 72
/
combo-select.scss
127 lines (108 loc) · 3.04 KB
/
combo-select.scss
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
120
121
122
123
124
125
126
127
@import "../../assets/scss/core/base";
$jigsaw-combo-select: #{$jigsaw-prefix}-combo-select;
.#{$jigsaw-combo-select}-host {
@include inline-block;
min-width: 240px;
max-width: 100%;
}
.#{$jigsaw-combo-select} {
position: relative;
color: $text-color;
font-size: $font-size-base;
cursor: pointer;
&-selection {
border-radius: $border-radius-base;
border: $border-width-base $border-style-base $border-color-base;
background: $component-background;
transition: all .3s $ease-in-out;
user-select: none;
padding: 0 30px 0 7px;
&:hover {
border-color: $primary-color;
box-shadow: $box-focus-shadow;
}
}
&-selection-rendered {
min-height: $height-base;
padding: 3px 0 0;
overflow: hidden;
font-size: 0;
.jigsaw-tag-host {
vertical-align: middle;
margin-right: 4px;
margin-bottom: 2px;
}
.jigsaw-input {
height: $height-base - 6;
line-height: $height-base - 6;
input {
padding: 0 !important;
font-size: $font-size-base;
border: none;
&:focus, &:hover {
box-shadow: none;
border: none;
}
}
}
}
&-placeholder {
@include inline-block();
font-size: $font-size-base;
color: $text-color-secondary;
padding-bottom: 3px;
height: $height-base - 3;
line-height: $height-base - 6;
}
&-disabled {
@include compatible(color, $disabled-color, $disabled-color-ie11);
pointer-events: none;
}
&-disabled &-placeholder {
@include compatible(color, $disabled-color, $disabled-color-ie11);
}
&-disabled &-selection {
background-color: $disabled-bg;
cursor: not-allowed;
&:hover, &:active, &:focus {
border-color: $disabled-bg;
box-shadow: none;
}
}
&-content {
position: absolute;
width: 100%;
z-index: $zindex-dropdown;
overflow: hidden;
margin-top: 3px;
padding: 5px;
border: $border-width-base $border-style-base $border-color-base;
background: $default-color;
box-shadow: $box-shadow-base;
border-radius: $border-radius-base;
@include opacity(0);
@include prefixer(transition, all 0.3s $ease-in-out);
}
&-opened &-arrow {
@include prefixer(transform, rotate(180deg));
}
&-arrow {
position: absolute;
top: 50%;
right: 8px;
transform-origin: 50% 20%;
transform: translateY(-50%);
transition: transform 0.3s $ease-in-out;
}
&-clear {
position: absolute;
top: 50%;
right: 18px;
width: 12px;
transform: translateY(-50%);
color: $text-color-secondary;
}
&-disabled &-clear {
color: darken($disabled-bg, 8%);
}
}