Permalink
Browse files

Slider & Rangeslider: new input styling, keep inputs always next to s…

…lider.
  • Loading branch information...
1 parent 2adfab9 commit 1c463cdd439516f3a34b50307ed7fe4d16c0473e @jaspermdegroot jaspermdegroot committed Dec 28, 2012
@@ -10,32 +10,26 @@
.ui-rangeslider:after {
clear: both;
}
-.ui-rangeslider label.ui-slider {
- margin-bottom: 0;
-}
-.ui-field-contain .ui-rangeslider label.ui-slider {
- margin-bottom: .4em;
+/* Margin-top/bottom: .5em * 16px/14px to make it equal to ui-rangeslider-sliders margin (input font-size is 14px) */
+.ui-rangeslider input.ui-input-text.ui-slider-input {
+ margin: .57143em 0;
}
-/* Margin-top/bottom: .25em * 16px/14px to make it equal to ui-rangeslider-sliders margin (input font-size is 14px) */
.ui-rangeslider.ui-mini input.ui-slider-input {
margin: .28571em 0;
}
.ui-rangeslider input.ui-slider-input.ui-rangeslider-last {
float: right;
}
-.ui-rangeslider .ui-rangeslider-dash {
- display: none;
-}
.ui-rangeslider .ui-rangeslider-sliders {
position: relative;
overflow: visible;
- height: 32px;
- margin: .5em 89px .5em 89px;
- font-size: 14px;
+ height: 30px;
+ margin: .5em 65px;
}
.ui-rangeslider.ui-mini .ui-rangeslider-sliders {
- margin: .25em 75px .25em 75px;
+ margin: .25em 65px;
}
+.ui-field-contain .ui-rangeslider input.ui-slider-input,
.ui-field-contain .ui-rangeslider.ui-mini input.ui-slider-input,
.ui-field-contain .ui-rangeslider .ui-rangeslider-sliders,
.ui-field-contain .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
@@ -44,104 +38,64 @@
}
.ui-rangeslider .ui-rangeslider-sliders .ui-slider-track {
position: absolute;
- top: 7px;
+ top: 6px;
right: 0;
left: 0;
margin: 0;
- font-size: 1em;
}
.ui-rangeslider.ui-mini .ui-rangeslider-sliders .ui-slider-track {
- top: 9px;
+ top: 8px;
}
.ui-rangeslider .ui-slider-track:first-child .ui-slider-bg {
display: none;
}
.ui-rangeslider .ui-rangeslider-sliders .ui-slider-track:first-child {
background-color: transparent;
background: none;
- border: none;
+ border-width: 0;
height: 0;
}
/* this makes ie6 and ie7 set height to 0 to fix z-index problem */
html >/**/body .ui-rangeslider .ui-rangeslider-sliders .ui-slider-track:first-child {
height: 15px;
+ border-width: 1px;
}
html >/**/body .ui-rangeslider.ui-mini .ui-rangeslider-sliders .ui-slider-track:first-child {
height: 12px;
}
-@media all and (max-width: 27.9375em){
- .ui-rangeslider label.ui-slider {
- margin-right: 15px;
- }
- .ui-rangeslider.ui-mini label.ui-slider {
- margin-right: 8px;
- }
- .ui-rangeslider label.ui-slider,
- .ui-field-contain .ui-rangeslider label.ui-slider,
- .ui-rangeslider input.ui-slider-input.ui-rangeslider-first,
- .ui-rangeslider input.ui-slider-input.ui-rangeslider-last,
- .ui-rangeslider .ui-rangeslider-dash {
- float: none;
- display: inline-block;
- margin-bottom: 0;
- }
- .ui-rangeslider .ui-rangeslider-dash {
- margin: 0 2px 0 5px;
- padding: .4em;
- font-size: 14px;
- line-height: 1.4;
- }
- .ui-rangeslider .ui-rangeslider-sliders,
- .ui-field-contain .ui-rangeslider .ui-rangeslider-sliders {
- margin: 1em 15px 0 15px;
- }
- .ui-rangeslider.ui-mini .ui-rangeslider-sliders,
- .ui-field-contain .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
- margin: 1em 8px 0 8px;
- }
-}
-
@media all and (min-width: 28em){
.ui-field-contain .ui-rangeslider label.ui-slider {
- float:left;
+ float: left;
}
- .ui-field-contain .ui-rangeslider.ui-mini input.ui-slider-input.ui-rangeslider-first {
- margin-right: 16px;
+ .ui-field-contain .ui-rangeslider input.ui-slider-input {
+ position: relative;
+ z-index: 1;
}
- .ui-field-contain .ui-rangeslider input.ui-slider-input.ui-rangeslider-last,
- .ui-field-contain .ui-rangeslider.ui-mini input.ui-slider-input.ui-rangeslider-last {
- margin-right: 0;
+ .ui-field-contain .ui-rangeslider input.ui-slider-input.ui-rangeslider-first,
+ .ui-field-contain .ui-rangeslider.ui-mini input.ui-slider-input.ui-rangeslider-first {
+ margin-right: 17px;
}
- .ui-field-contain .ui-rangeslider .ui-rangeslider-sliders {
+ .ui-field-contain .ui-rangeslider .ui-rangeslider-sliders,
+ .ui-field-contain .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
float: left;
width: 78%;
- margin: 0 -89px 0 -89px;
- }
- .ui-field-contain .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
- margin: 0 -75px 0 -75px;
- }
- .ui-field-contain .ui-rangeslider .ui-slider-track {
- right: 89px;
- left: 89px;
+ margin: 0 -65px;
}
+ .ui-field-contain .ui-rangeslider .ui-slider-track,
.ui-field-contain .ui-rangeslider.ui-mini .ui-slider-track {
- right: 75px;
- left: 75px;
+ right: 65px;
+ left: 65px;
}
- .ui-field-contain.ui-hide-label .ui-rangeslider input.ui-slider-input.ui-rangeslider-first,
- .ui-field-contain.ui-hide-label .ui-rangeslider input.ui-slider-input.ui-rangeslider-last {
+ .ui-field-contain.ui-hide-label .ui-rangeslider input.ui-slider-input.ui-rangeslider-first {
margin: 0;
}
.ui-field-contain.ui-hide-label .ui-rangeslider .ui-rangeslider-sliders,
.ui-field-contain.ui-hide-label .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
width: auto;
float: none;
- margin: 0 89px;
- }
- .ui-field-contain.ui-hide-label .ui-rangeslider.ui-mini .ui-rangeslider-sliders {
- margin: 0 75px;
+ margin: 0 65px;
}
.ui-field-contain.ui-hide-label .ui-rangeslider .ui-slider-track,
.ui-field-contain.ui-hide-label .ui-rangeslider.ui-mini .ui-slider-track {
Oops, something went wrong.

0 comments on commit 1c463cd

Please sign in to comment.