|
8 | 8 | @tooltip-arrow-width: 4px;
|
9 | 9 | @tooltip-distance: @tooltip-arrow-width+4;
|
10 | 10 | @tooltip-arrow-color: @tooltip-bg;
|
11 |
| -@ease-out-quint : cubic-bezier(0.23, 1, 0.32, 1); |
12 |
| -@ease-in-quint : cubic-bezier(0.755, 0.05, 0.855, 0.06); |
| 11 | +@ease-out-quint: cubic-bezier(0.23, 1, 0.32, 1); |
| 12 | +@ease-in-quint: cubic-bezier(0.755, 0.05, 0.855, 0.06); |
13 | 13 |
|
14 | 14 | .borderBox() {
|
15 | 15 | box-sizing: border-box;
|
|
23 | 23 |
|
24 | 24 | .@{prefixClass} {
|
25 | 25 | position: relative;
|
| 26 | + width: 100%; |
26 | 27 | height: 14px;
|
27 | 28 | padding: 5px 0;
|
28 |
| - width: 100%; |
29 | 29 | border-radius: @border-radius-base;
|
30 | 30 | touch-action: none;
|
31 | 31 | .borderBox();
|
32 | 32 |
|
33 | 33 | &-rail {
|
34 | 34 | position: absolute;
|
35 | 35 | width: 100%;
|
36 |
| - background-color: #e9e9e9; |
37 | 36 | height: 4px;
|
| 37 | + background-color: #e9e9e9; |
38 | 38 | border-radius: @border-radius-base;
|
39 | 39 | }
|
40 | 40 |
|
41 | 41 | &-track {
|
42 | 42 | position: absolute;
|
43 |
| - left: 0; |
44 | 43 | height: 4px;
|
45 |
| - border-radius: @border-radius-base; |
46 | 44 | background-color: tint(@primary-color, 60%);
|
| 45 | + border-radius: @border-radius-base; |
47 | 46 | }
|
48 | 47 |
|
49 | 48 | &-handle {
|
50 | 49 | position: absolute;
|
51 | 50 | width: 14px;
|
52 | 51 | height: 14px;
|
| 52 | + margin-top: -5px; |
| 53 | + background-color: #fff; |
| 54 | + border: solid 2px tint(@primary-color, 50%); |
| 55 | + border-radius: 50%; |
53 | 56 | cursor: pointer;
|
54 | 57 | cursor: -webkit-grab;
|
55 |
| - margin-top: -5px; |
56 | 58 | cursor: grab;
|
57 |
| - border-radius: 50%; |
58 |
| - border: solid 2px tint(@primary-color, 50%); |
59 |
| - background-color: #fff; |
| 59 | + opacity: 0.8; |
60 | 60 | touch-action: pan-x;
|
61 | 61 |
|
62 | 62 | &-dragging&-dragging&-dragging {
|
|
66 | 66 |
|
67 | 67 | &:focus {
|
68 | 68 | outline: none;
|
| 69 | + box-shadow: 0 0 0 3px tint(@primary-color, 50%); |
69 | 70 | }
|
70 | 71 |
|
71 | 72 | &-click-focused:focus {
|
|
96 | 97 | &-mark-text {
|
97 | 98 | position: absolute;
|
98 | 99 | display: inline-block;
|
99 |
| - vertical-align: middle; |
| 100 | + color: #999; |
100 | 101 | text-align: center;
|
| 102 | + vertical-align: middle; |
101 | 103 | cursor: pointer;
|
102 |
| - color: #999; |
103 | 104 |
|
104 | 105 | &-active {
|
105 | 106 | color: #666;
|
|
111 | 112 | width: 100%;
|
112 | 113 | height: 4px;
|
113 | 114 | background: transparent;
|
| 115 | + pointer-events: none; |
114 | 116 | }
|
115 | 117 |
|
116 | 118 | &-dot {
|
117 | 119 | position: absolute;
|
118 | 120 | bottom: -2px;
|
119 |
| - margin-left: -4px; |
120 | 121 | width: 8px;
|
121 | 122 | height: 8px;
|
122 |
| - border: 2px solid #e9e9e9; |
| 123 | + // margin-left: -4px; |
| 124 | + vertical-align: middle; |
123 | 125 | background-color: #fff;
|
124 |
| - cursor: pointer; |
| 126 | + border: 2px solid #e9e9e9; |
125 | 127 | border-radius: 50%;
|
126 |
| - vertical-align: middle; |
| 128 | + cursor: pointer; |
127 | 129 | &-active {
|
128 | 130 | border-color: tint(@primary-color, 50%);
|
129 | 131 | }
|
|
139 | 141 | background-color: @disabledColor;
|
140 | 142 | }
|
141 | 143 |
|
142 |
| - .@{prefixClass}-handle, .@{prefixClass}-dot { |
| 144 | + .@{prefixClass}-handle, |
| 145 | + .@{prefixClass}-dot { |
| 146 | + background-color: #fff; |
143 | 147 | border-color: @disabledColor;
|
144 | 148 | box-shadow: none;
|
145 |
| - background-color: #fff; |
146 | 149 | cursor: not-allowed;
|
147 | 150 | }
|
148 | 151 |
|
149 |
| - .@{prefixClass}-mark-text, .@{prefixClass}-dot { |
150 |
| - cursor: not-allowed!important; |
| 152 | + .@{prefixClass}-mark-text, |
| 153 | + .@{prefixClass}-dot { |
| 154 | + cursor: not-allowed !important; |
151 | 155 | }
|
152 | 156 | }
|
153 | 157 | }
|
|
159 | 163 |
|
160 | 164 | .@{prefixClass} {
|
161 | 165 | &-rail {
|
162 |
| - height: 100%; |
163 | 166 | width: 4px;
|
| 167 | + height: 100%; |
164 | 168 | }
|
165 | 169 |
|
166 | 170 | &-track {
|
167 |
| - left: 5px; |
168 | 171 | bottom: 0;
|
| 172 | + left: 5px; |
169 | 173 | width: 4px;
|
170 | 174 | }
|
171 | 175 |
|
172 | 176 | &-handle {
|
| 177 | + margin-top: 0; |
173 | 178 | margin-left: -5px;
|
174 | 179 | touch-action: pan-y;
|
175 | 180 | }
|
|
181 | 186 | }
|
182 | 187 |
|
183 | 188 | &-step {
|
184 |
| - height: 100%; |
185 | 189 | width: 4px;
|
| 190 | + height: 100%; |
186 | 191 | }
|
187 | 192 |
|
188 | 193 | &-dot {
|
189 |
| - left: 2px; |
190 |
| - margin-bottom: -4px; |
191 |
| - &:first-child { |
192 |
| - margin-bottom: -4px; |
193 |
| - } |
194 |
| - &:last-child { |
195 |
| - margin-bottom: -4px; |
196 |
| - } |
| 194 | + margin-left: -2px; |
| 195 | + // margin-bottom: -4px; |
| 196 | + // &:first-child { |
| 197 | + // margin-bottom: -4px; |
| 198 | + // } |
| 199 | + // &:last-child { |
| 200 | + // margin-bottom: -4px; |
| 201 | + // } |
197 | 202 | }
|
198 | 203 | }
|
199 | 204 | }
|
200 | 205 |
|
201 | 206 | .motion-common() {
|
202 |
| - animation-duration: .3s; |
203 |
| - animation-fill-mode: both; |
204 | 207 | display: block !important;
|
| 208 | + animation-duration: 0.3s; |
| 209 | + animation-fill-mode: both; |
205 | 210 | }
|
206 | 211 |
|
207 | 212 | .make-motion(@className, @keyframeName) {
|
208 |
| - .@{className}-enter, .@{className}-appear { |
| 213 | + .@{className}-enter, |
| 214 | + .@{className}-appear { |
209 | 215 | .motion-common();
|
210 | 216 | animation-play-state: paused;
|
211 | 217 | }
|
212 | 218 | .@{className}-leave {
|
213 | 219 | .motion-common();
|
214 | 220 | animation-play-state: paused;
|
215 | 221 | }
|
216 |
| - .@{className}-enter.@{className}-enter-active, .@{className}-appear.@{className}-appear-active { |
217 |
| - animation-name: ~"@{keyframeName}In"; |
| 222 | + .@{className}-enter.@{className}-enter-active, |
| 223 | + .@{className}-appear.@{className}-appear-active { |
| 224 | + animation-name: ~'@{keyframeName}In'; |
218 | 225 | animation-play-state: running;
|
219 | 226 | }
|
220 | 227 | .@{className}-leave.@{className}-leave-active {
|
221 |
| - animation-name: ~"@{keyframeName}Out"; |
| 228 | + animation-name: ~'@{keyframeName}Out'; |
222 | 229 | animation-play-state: running;
|
223 | 230 | }
|
224 | 231 | }
|
225 | 232 | .zoom-motion(@className, @keyframeName) {
|
226 | 233 | .make-motion(@className, @keyframeName);
|
227 |
| - .@{className}-enter, .@{className}-appear { |
| 234 | + .@{className}-enter, |
| 235 | + .@{className}-appear { |
228 | 236 | transform: scale(0, 0); // need this by yiminghe
|
229 | 237 | animation-timing-function: @ease-out-quint;
|
230 | 238 | }
|
|
236 | 244 |
|
237 | 245 | @keyframes rcSliderTooltipZoomDownIn {
|
238 | 246 | 0% {
|
239 |
| - opacity: 0; |
240 |
| - transform-origin: 50% 100%; |
241 | 247 | transform: scale(0, 0);
|
| 248 | + transform-origin: 50% 100%; |
| 249 | + opacity: 0; |
242 | 250 | }
|
243 | 251 | 100% {
|
244 |
| - transform-origin: 50% 100%; |
245 | 252 | transform: scale(1, 1);
|
| 253 | + transform-origin: 50% 100%; |
246 | 254 | }
|
247 | 255 | }
|
248 | 256 |
|
249 | 257 | @keyframes rcSliderTooltipZoomDownOut {
|
250 | 258 | 0% {
|
251 |
| - transform-origin: 50% 100%; |
252 | 259 | transform: scale(1, 1);
|
| 260 | + transform-origin: 50% 100%; |
253 | 261 | }
|
254 | 262 | 100% {
|
255 |
| - opacity: 0; |
256 |
| - transform-origin: 50% 100%; |
257 | 263 | transform: scale(0, 0);
|
| 264 | + transform-origin: 50% 100%; |
| 265 | + opacity: 0; |
258 | 266 | }
|
259 | 267 | }
|
260 | 268 |
|
261 | 269 | .@{prefixClass}-tooltip {
|
262 | 270 | position: absolute;
|
263 |
| - left: -9999px; |
264 | 271 | top: -9999px;
|
| 272 | + left: -9999px; |
265 | 273 | visibility: visible;
|
266 | 274 |
|
267 | 275 | .borderBox();
|
|
275 | 283 | }
|
276 | 284 |
|
277 | 285 | &-inner {
|
278 |
| - padding: 6px 2px; |
279 | 286 | min-width: 24px;
|
280 | 287 | height: 24px;
|
| 288 | + padding: 6px 2px; |
| 289 | + color: @tooltip-color; |
281 | 290 | font-size: 12px;
|
282 | 291 | line-height: 1;
|
283 |
| - color: @tooltip-color; |
284 | 292 | text-align: center;
|
285 | 293 | text-decoration: none;
|
286 | 294 | background-color: @tooltip-bg;
|
|
0 commit comments