Skip to content

Commit 008d1ad

Browse files
author
Valentin Hervieu
committed
Refactorize even more the LESS file
1 parent 9c659bf commit 008d1ad

File tree

1 file changed

+27
-31
lines changed

1 file changed

+27
-31
lines changed

src/rzslider.less

Lines changed: 27 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,12 @@ rzslider {
5757
z-index: 1;
5858
background: @barNormalColor;
5959
.rounded(@barHeight/2);
60-
}
6160

62-
&.rz-bar.rz-selection {
63-
z-index: 2;
64-
background: @barFillColor;
65-
.rounded(@barHeight/2);
61+
&.rz-selection {
62+
z-index: 2;
63+
background: @barFillColor;
64+
.rounded(@barHeight/2);
65+
}
6666
}
6767

6868
&.rz-pointer {
@@ -77,40 +77,36 @@ rzslider {
7777
// -moz-transition:all linear 0.15s;
7878
// -o-transition:all linear 0.15s;
7979
// transition:all linear 0.15s;
80-
}
8180

82-
&.rz-pointer:after {
83-
content: '';
84-
width: @handlePointerSize;
85-
height: @handlePointerSize;
86-
position: absolute;
87-
top: @handleSize/2 - @handlePointerSize/2;
88-
left: @handleSize/2 - @handlePointerSize/2;
89-
.rounded(@handlePointerSize/2);
90-
background: @handleInnerColor;
91-
}
92-
93-
&.rz-pointer:hover:after {
94-
background-color: @handleHoverColor;
95-
}
96-
97-
&.rz-pointer.rz-active:after {
98-
background-color: @handleActiveColor;
81+
&:after {
82+
content: '';
83+
width: @handlePointerSize;
84+
height: @handlePointerSize;
85+
position: absolute;
86+
top: @handleSize/2 - @handlePointerSize/2;
87+
left: @handleSize/2 - @handlePointerSize/2;
88+
.rounded(@handlePointerSize/2);
89+
background: @handleInnerColor;
90+
}
91+
&:hover:after {
92+
background-color: @handleHoverColor;
93+
}
94+
&.rz-active:after {
95+
background-color: @handleActiveColor;
96+
}
9997
}
10098

10199
&.rz-bubble {
102100
cursor: default;
103101
bottom: @handleSize/2;
104102
padding: @bubblePadding;
105103
color: @labelTextColor;
106-
}
107-
108-
&.rz-bubble.rz-selection {
109-
top: @handleSize/2;
110-
}
111-
112-
&.rz-bubble.rz-limit {
113-
color: @limitLabelTextColor;
104+
&.rz-selection {
105+
top: @handleSize/2;
106+
}
107+
&.rz-limit {
108+
color: @limitLabelTextColor;
109+
}
114110
}
115111
}
116112

0 commit comments

Comments
 (0)