nouislider with pip highlighting

by Osama Qassar

HTML

<script src="//code.jquery.com/jquery-1.12.0.min.js"></script>
<div id="slider">

</div>
<div style="clear:both;width:100%;height:70px;">

</div>
<div class="values">
  <span class="min"></span>-<span class="max"></span>
</div>

CSS

/* Functional styling;
     * These styles are required for noUiSlider to function.
     * You don't need to change these rules to apply your design.
     */
	.noUi-target,
	.noUi-target * {
		-webkit-touch-callout: none;
		-webkit-user-select: none;
		-ms-touch-action: none;
		touch-action: none;
		-ms-user-select: none;
		-moz-user-select: none;
		-moz-box-sizing: border-box;
		box-sizing: border-box;
	}
	.noUi-target {
		position: relative;
		direction: ltr;
	}
	.noUi-base {
		width: 100%;
		height: 100%;
		position: relative;
		z-index: 1; /* Fix 401 */
	}
	.noUi-origin {
		position: absolute;
		right: 0;
		top: 0;
		left: 0;
		bottom: 0;
	}
	.noUi-handle {
		position: relative;
		z-index: 1;
	}
	.noUi-stacking .noUi-handle {
		/* This class is applied to the lower origin when
           its values is > 50%. */
		z-index: 10;
	}
	.noUi-state-tap .noUi-origin {
		-webkit-transition: left 0.3s, top 0.3s;
		transition: left 0.3s, top 0.3s;
	}
	.noUi-state-drag * {
		cursor: inherit !important;
	}

	/* Painting and performance;
     * Browsers can paint handles in their own layer.
     */
	.noUi-base {
		-webkit-transform: translate3d(0,0,0);
		transform: translate3d(0,0,0);
	}

	/* Slider size and handle placement;
     */
	.noUi-horizontal {
		height: 18px;
	}
	.noUi-horizontal .noUi-handle {
		width: 34px;
		height: 28px;
		left: -17px;
		top: -6px;
	}
	.noUi-vertical {
		width: 18px;
	}
	.noUi-vertical .noUi-handle {
		width: 28px;
		height: 34px;
		left: -6px;
		top: -17px;
	}

	/* Styling;
     */
	.noUi-background {
		background: #FAFAFA;
		box-shadow: inset 0 1px 1px #f0f0f0;
	}
	.noUi-connect {
		background: #3FB8AF;
		box-shadow: inset 0 0 3px rgba(51,51,51,0.45);
		-webkit-transition: background 450ms;
		transition: background 450ms;
	}
	.noUi-origin {
		border-radius: 2px;
	}
	.noUi-target {
		border-radius: 4px;
		border: 1px solid #D3D3D3;
		box-shadow: inset 0 1px 1px #F0F0F0, 0 3px 6px -5px #BBB;
	}
	.noUi-target.noUi-connect {
		box-shadow: inset...

JavaScript

/*! nouislider - 8.3.0 - 2016-02-14 17:37:19 */

!function(a){"function"==typeof define&&define.amd?define([],a):"object"==typeof exports?module.exports=a():window.noUiSlider=a()}(function(){"use strict";function a(a){return a.filter(function(a){return this[a]?!1:this[a]=!0},{})}function b(a,b){return Math.round(a/b)*b}function c(a){var b=a.getBoundingClientRect(),c=a.ownerDocument,d=c.documentElement,e=m();return/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(e.x=0),{top:b.top+e.y-d.clientTop,left:b.left+e.x-d.clientLeft}}function d(a){return"number"==typeof a&&!isNaN(a)&&isFinite(a)}function e(a){var b=Math.pow(10,7);return Number((Math.round(a*b)/b).toFixed(7))}function f(a,b,c){j(a,b),setTimeout(function(){k(a,b)},c)}function g(a){return Math.max(Math.min(a,100),0)}function h(a){return Array.isArray(a)?a:[a]}function i(a){var b=a.split(".");return b.length>1?b[1].length:0}function j(a,b){a.classList?a.classList.add(b):a.className+=" "+b}function k(a,b){a.classList?a.classList.remove(b):a.className=a.className.replace(new RegExp("(^|\\b)"+b.split(" ").join("|")+"(\\b|$)","gi")," ")}function l(a,b){return a.classList?a.classList.contains(b):new RegExp("\\b"+b+"\\b").test(a.className)}function m(){var a=void 0!==window.pageXOffset,b="CSS1Compat"===(document.compatMode||""),c=a?window.pageXOffset:b?document.documentElement.scrollLeft:document.body.scrollLeft,d=a?window.pageYOffset:b?document.documentElement.scrollTop:document.body.scrollTop;return{x:c,y:d}}function n(a){a.stopPropagation()}function o(a){return function(b){return a+b}}function p(a,b){return 100/(b-a)}function q(a,b){return 100*b/(a[1]-a[0])}function r(a,b){return q(a,a[0]<0?b+Math.abs(a[0]):b-a[0])}function s(a,b){return b*(a[1]-a[0])/100+a[0]}function t(a,b){for(var c=1;a>=b[c];)c+=1;return c}function u(a,b,c){if(c>=a.slice(-1)[0])return 100;var d,e,f,g,h=t(c,a);return d=a[h-1],e=a[h],f=b[h-1],g=b[h],f+r([d,e],c)/p(f,g)}function v(a,b,c){if(c>=100)return a.slice(-1)[0];var...