Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div id="warp">
<label for="molette">
<input id="molette" name="foo" type="range" name="molette" min="0" value="25" max="100"  >
<output for="foo" onforminput="value = foo.valueAsNumber;"></output>
</label>
</div>
              
            
!

CSS

              
                /*CSS Reset*/
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
button,form, fieldset, input, textarea {
margin: 0;
padding: 0;
border: 0;
outline: 0;
font-size: 100%;
vertical-align: baseline;
background: transparent;
}
body {line-height: 1;}
h1, h2, h3, h4, h5, h6 {font-weight: normal;}
ol, ul {list-style: none;}
blockquote, q {quotes: none;}
blockquote:before, blockquote:after,
q:before, q:after {content: '';content: none;}
/* remember to define focus styles! */
:focus {outline: 0;}
/* remember to highlight inserts somehow! */
ins {text-decoration: none;}
del {text-decoration: line-through;}
/* tables still need 'cellspacing="0"' in the markup */
table {border-collapse: collapse;border-spacing: 0;}
address, caption, cite, code, dfn, em, strong, var { font-style: normal; font-weight: normal;}
caption, th { text-align: left; font-weight: normal; font-style: normal;}
/* starting */
body{
  background-color: #DBD9D2;
  background-image: url(http://subtlepatterns.subtlepatterns.netdna-cdn.com/patterns/nasty_fabric.png);
  font-family: "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
	font-weight: 600;
	-webkit-font-smoothing: subpixel-antialiased;
}
#warp{
	width:400px;
	margin:40px auto;
	display: block;
	position: relative;
}
/* slide */ 
label{
	display:block;
	position: relative;
	width: 400px;
	height: 42px;
	border-radius: 25px;
	background-clip: padding-box;
	box-shadow: 	0 5px 10px rgba(0,0,0,.75),inset 0 0px 2px rgba(0,0,0,.75);
	background: #3BB0F0;
	margin: 70px auto;
	border: 2px solid white;
}

input[type='range']{
-webkit-appearance: none;
	width: 100%;
	height: 40px;
	position: relative;
	top: 0px;
	cursor: col-resize;
	z-index: 5;
 }
/* hover fx */ 
input[type='range']::-webkit-slider-thumb{
	-webkit-appearance: none;
	width:65px;
	height: 38px;
	top:1px;
	border-radius: 30px;
	background-clip: padding-box;
	background:-webkit-linear-gradient(bottom, #FFF 0%, #e3e7ec 45%, #e3e7ec 75%, #FFF 100%);
	background:linear-gradient(bottom,  #FFF 0%, #e3e7ec 45%, #e3e7ec 75%, #FFF 100%);
	box-shadow: 	inset 0 2px 0 rgba(250,248,244,.65),
					inset 0 -3px 0 rgba(0,0,0,.125);
  -webkit-transition:all .5s ease-out;
          transition:all .5s ease-out;
 }
 input[type='range']::-webkit-slider-thumb:hover,
 input[type='range']::-webkit-slider-thumb:focus{
	height: 82px;
	border-radius: 20px;
  position: relative;
	top:-22px;
	background: -webkit-linear-gradient(bottom, #c9c9c9 0%, #9d9d9d 10%, #f1f1f1 70%);
	background: linear-gradient(bottom, #c9c9c9 0%, #9d9d9d 10%, #f1f1f1 70%);
	box-shadow: 	 0 0px 5px rgba(0,0,0,.75);
  -webkit-transition:all .25s ease-in;
          transition:all .25s ease-in;
 
 }
/* grip */ 
input[type='range']:hover::-webkit-slider-thumb:before{
	 content: "";
	width: 14px;
	height: 10px;
	margin-left: 25px;
	bottom: 15px;
	display: block;
	 position: absolute;
	background-image: -webkit-linear-gradient(0deg, transparent 25%, rgba(132, 136, 149, .75) 25%, rgba(132, 136, 149, .75) 50%, transparent 50%, transparent 75%, rgba(132, 136, 149, .75) 75%, rgba(132, 136, 149, .75) 100%, transparent 100%);
	background-image: linear-gradient(90deg, transparent 25%, rgba(132, 136, 149, .75) 25%, rgba(132, 136, 149, .75) 50%, transparent 50%,transparent 75%, rgba(132, 136, 149, .75) 75%,rgba(132, 136, 149, .75) 100%, transparent 100%);
	background-size: 8px;
  z-index: 20;
 }

/* fleche */
input[type='range']::-webkit-slider-thumb:after{
	content: "◀           ►";
	color:#b5b3b3;
	font-size: 12px;
	margin-left: 5px;
	bottom: 0px;
	width: 100%;
	line-height: 38px;
	display: inline-block;
	position: absolute;
	z-index: 20;
}
input[type='range']::-webkit-slider-thumb:after{color:#333;}
/* nombres */
output { 
  position: absolute;
  width: 12%; 
  height: 40px; 
  text-align: right; 
  color: black;  
  display: block; 
  font-size:18px;
  line-height:35px;
  bottom: 0px;
  z-index:10;
  -webkit-transition:bottom font-size left .30s ease-out;
          transition:bottom font-size left .30s ease-out;
}

 input[type='range']:hover ~ output  {
  bottom: 40px;
  font-size:24px;  
  -webkit-transition:bottom font-size left .55s ease-in;  
          transition:bottom font-size left .55s ease-in;
}
              
            
!

JS

              
                // DOM Ready
$(function() {
 var el, newPoint, newPlace, offset;
 
 // Select all range inputs, watch for change
 $("input[type='range']").change(function() {
 
   // Cache this for efficiency
   el = $(this);
   
   // Measure width of range input
   width = el.width();
   
   // Figure out placement percentage between left and right of input
   newPoint = (el.val() - el.attr("min")) / (el.attr("max") - el.attr("min"));
   
   // Janky value to get pointer to line up better
   offset = -3.33;
   
   // Prevent bubble from going beyond left or right (unsupported browsers)
   if (newPoint < 0) { newPlace = 0; }
   else if (newPoint > 1) { newPlace = width; }
   else { newPlace = width/1.128  * newPoint + offset; offset -= newPoint; }
   
   // Move bubble
   el
     .next("output")
     .css({
       left: newPlace ,
       marginLeft: offset + "%"
     })
     .text(el.val());
 })
 // Fake a change to position bubble at page load
 .trigger('change');
});

modifyInputs();
              
            
!
999px

Console