JSFiddle - React, Tailwind, and code Playground
by dixalex
CSS
.ui-slider-wrapper {
position: relative;
}
.ui-slider-wrapper .ui-slider-horizontal {
width: 100%;
}
.ui-slider-labels {
position: absolute;
border: 1px solid transparent;
}
.ui-slider-label-ticks {
border: 1px solid transparent;
position: absolute;
white-space: nowrap;
}
.ui-slider-label-ticks span {
font-size: 0.9em;
min-width: 1.2em;
}
.ui-slider-wrapper.horizontal {
height: 4.5em;
}
.horizontal .ui-slider-labels {
left: 0;
right: 0;
top: 0.7em
}
.horizontal .ui-slider-label-ticks {
width: 1.2em;
height: .8em;
text-align: center;
border-left: 1px solid #999;
}
.horizontal .ui-slider-label-ticks span {
position: relative;
display: inline-block;
margin-left: -1.2em;
top: .8em;
}
.ui-slider-wrapper.vertical {
width: 4.5em;
}
.vertical .ui-slider-labels {
top: 1px;
bottom: 0;
left: 0.7em;
}
.vertical .ui-slider-label-ticks {
height: 1.2em;
width: 0.8em;
border-bottom: 1px solid #999;
}
.vertical .ui-slider-label-ticks span {
position: relative;
display: inline-block;
margin-left: 1em;
top: .6em;
}
.ncp_slider_container {
margin: 2em auto 4em auto;
max-width: 740px;
width: auto;
}
.ncp_slider_range_div {
display: inline-block;
float: left;
width: 72%;
cursor: pointer;
}
.ui-slider-range {
background: #FFF;
}
.ncp_slider_range_div.ui-slider .ui-slider-handle {
width: 15px;
height: 1.5em;
margin-left: -.47em;
border: solid 1px #000;
cursor: pointer;
}
.ncp_slider_range_div .ui-state-default {
background: none;
}
.ncp_slider_range_div.ui-slider div.minHandle {
border: solid 1px #c1e4e8;
background-color: #c1e4e8;
}
.ncp_slider_range_div.ui-slider div.maxHandle {
background-color: red;
display: none;
}
.ui-slider-range.ui-corner-all.ui-widget-header {
background-color: #48bfbb;
}
.ui-slider-label-ticks>span {
line-height: 1.33em;
font-weight: bold;
color: blue;
text-align: left;
margin-top: .45em;
min-width: 3em;
min-height: 3em;
...