/*! =======================================================
                      VERSION  10.2.0              
========================================================= */
"use strict";var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},windowIsDefined="object"===("undefined"==typeof window?"undefined":_typeof(window));!function(n){if("function"==typeof define&&define.amd)define(["jquery"],n);else if("object"===("undefined"==typeof module?"undefined":_typeof(module))&&module.exports){var t;try{t=require("jquery")}catch(i){t=null}module.exports=n(t)}else window&&(window.Slider=n(window.jQuery))}(function(n){var i="slider",r="bootstrapSlider",t;return windowIsDefined&&!window.console&&(window.console={}),windowIsDefined&&!window.console.log&&(window.console.log=function(){}),windowIsDefined&&!window.console.warn&&(window.console.warn=function(){}),function(n){function t(){}function i(n){function u(t){t.prototype.option||(t.prototype.option=function(t){n.isPlainObject(t)&&(this.options=n.extend(!0,this.options,t))})}function f(t,u){n.fn[t]=function(f){var c,e,s,o;if("string"==typeof f){for(var l=r.call(arguments,1),h=0,a=this.length;a>h;h++)if(c=this[h],e=n.data(c,t),e)if(n.isFunction(e[f])&&"_"!==f.charAt(0)){if(s=e[f].apply(e,l),void 0!==s&&s!==e)return s}else i("no such method '"+f+"' for "+t+" instance");else i("cannot call methods on "+t+" prior to initialization; attempted to call '"+f+"'");return this}return o=this.map(function(){var i=n.data(this,t);return i?(i.option(f),i._init()):(i=new u(this,f),n.data(this,t,i)),n(this)}),!o||o.length>1?o:o[0]}}if(n){var i="undefined"==typeof console?t:function(n){console.error(n)};return n.bridget=function(n,t){u(t);f(n,t)},n.bridget}}var r=Array.prototype.slice;i(n)}(n),function(n){function f(t,i){function yt(n,t){var r="data-slider-"+t.replace(/_/g,"-"),i=n.getAttribute(r);try{return JSON.parse(i)}catch(u){return i}}var rt,r,c,e,s,a,k,d,ht,g,h,tt,v,y,p,lt,at,ft,vt,et;for(this._state={value:null,enabled:null,offset:null,size:null,percentage:null,inDrag:!1,over:!1},this.ticksCallbackMap={},this.handleCallbackMap={},"string"==typeof t?this.element=document.querySelector(t):t instanceof HTMLElement&&(this.element=t),i=i?i:{},rt=Object.keys(this.defaultOptions),r=0;r<rt.length;r++)c=rt[r],e=i[c],e="undefined"!=typeof e?e:yt(this.element,c),e=null!==e?e:this.defaultOptions[c],this.options||(this.options={}),this.options[c]=e;"auto"===this.options.rtl&&(this.options.rtl="rtl"===window.getComputedStyle(this.element).direction);"vertical"!==this.options.orientation||"top"!==this.options.tooltip_position&&"bottom"!==this.options.tooltip_position?"horizontal"!==this.options.orientation||"left"!==this.options.tooltip_position&&"right"!==this.options.tooltip_position||(this.options.tooltip_position="top"):this.options.tooltip_position=this.options.rtl?"left":"right";var l,w,b,u,f,pt=this.element.style.width,ut=!1,wt=this.element.parentNode;if(this.sliderElem)ut=!0;else{if(this.sliderElem=document.createElement("div"),this.sliderElem.className="slider",s=document.createElement("div"),s.className="slider-track",w=document.createElement("div"),w.className="slider-track-low",l=document.createElement("div"),l.className="slider-selection",b=document.createElement("div"),b.className="slider-track-high",u=document.createElement("div"),u.className="slider-handle min-slider-handle",u.setAttribute("role","slider"),u.setAttribute("aria-valuemin",this.options.min),u.setAttribute("aria-valuemax",this.options.max),f=document.createElement("div"),f.className="slider-handle max-slider-handle",f.setAttribute("role","slider"),f.setAttribute("aria-valuemin",this.options.min),f.setAttribute("aria-valuemax",this.options.max),s.appendChild(w),s.appendChild(l),s.appendChild(b),this.rangeHighlightElements=[],a=this.options.rangeHighlights,Array.isArray(a)&&a.length>0)for(k=0;k<a.length;k++)d=document.createElement("div"),ht=a[k]["class"]||"",d.className="slider-rangeHighlight slider-selection "+ht,this.rangeHighlightElements.push(d),s.appendChild(d);if(g=Array.isArray(this.options.labelledby),g&&this.options.labelledby[0]&&u.setAttribute("aria-labelledby",this.options.labelledby[0]),g&&this.options.labelledby[1]&&f.setAttribute("aria-labelledby",this.options.labelledby[1]),!g&&this.options.labelledby&&(u.setAttribute("aria-labelledby",this.options.labelledby),f.setAttribute("aria-labelledby",this.options.labelledby)),this.ticks=[],Array.isArray(this.options.ticks)&&this.options.ticks.length>0){for(this.ticksContainer=document.createElement("div"),this.ticksContainer.className="slider-tick-container",r=0;r<this.options.ticks.length;r++){if(h=document.createElement("div"),h.className="slider-tick",this.options.ticks_tooltip){var ct=this._addTickListener(),bt=ct.addMouseEnter(this,h,r),kt=ct.addMouseLeave(this,h);this.ticksCallbackMap[r]={mouseEnter:bt,mouseLeave:kt}}this.ticks.push(h);this.ticksContainer.appendChild(h)}l.className+=" tick-slider-selection"}if(this.tickLabels=[],Array.isArray(this.options.ticks_labels)&&this.options.ticks_labels.length>0)for(this.tickLabelContainer=document.createElement("div"),this.tickLabelContainer.className="slider-tick-label-container",r=0;r<this.options.ticks_labels.length;r++){var nt=document.createElement("div"),dt=0===this.options.ticks_positions.length,gt=this.options.reversed&&dt?this.options.ticks_labels.length-(r+1):r;nt.className="slider-tick-label";nt.innerHTML=this.options.ticks_labels[gt];this.tickLabels.push(nt);this.tickLabelContainer.appendChild(nt)}tt=function(n){var i=document.createElement("div"),t;i.className="tooltip-arrow";t=document.createElement("div");t.className="tooltip-inner";n.appendChild(i);n.appendChild(t)};v=document.createElement("div");v.className="tooltip tooltip-main";v.setAttribute("role","presentation");tt(v);y=document.createElement("div");y.className="tooltip tooltip-min";y.setAttribute("role","presentation");tt(y);p=document.createElement("div");p.className="tooltip tooltip-max";p.setAttribute("role","presentation");tt(p);this.sliderElem.appendChild(s);this.sliderElem.appendChild(v);this.sliderElem.appendChild(y);this.sliderElem.appendChild(p);this.tickLabelContainer&&this.sliderElem.appendChild(this.tickLabelContainer);this.ticksContainer&&this.sliderElem.appendChild(this.ticksContainer);this.sliderElem.appendChild(u);this.sliderElem.appendChild(f);wt.insertBefore(this.sliderElem,this.element);this.element.style.display="none"}if(n&&(this.$element=n(this.element),this.$sliderElem=n(this.sliderElem)),this.eventToCallbackMap={},this.sliderElem.id=this.options.id,this.touchCapable="ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch,this.touchX=0,this.touchY=0,this.tooltip=this.sliderElem.querySelector(".tooltip-main"),this.tooltipInner=this.tooltip.querySelector(".tooltip-inner"),this.tooltip_min=this.sliderElem.querySelector(".tooltip-min"),this.tooltipInner_min=this.tooltip_min.querySelector(".tooltip-inner"),this.tooltip_max=this.sliderElem.querySelector(".tooltip-max"),this.tooltipInner_max=this.tooltip_max.querySelector(".tooltip-inner"),o[this.options.scale]&&(this.options.scale=o[this.options.scale]),ut===!0&&(this._removeClass(this.sliderElem,"slider-horizontal"),this._removeClass(this.sliderElem,"slider-vertical"),this._removeClass(this.sliderElem,"slider-rtl"),this._removeClass(this.tooltip,"hide"),this._removeClass(this.tooltip_min,"hide"),this._removeClass(this.tooltip_max,"hide"),["left","right","top","width","height"].forEach(function(n){this._removeProperty(this.trackLow,n);this._removeProperty(this.trackSelection,n);this._removeProperty(this.trackHigh,n)},this),[this.handle1,this.handle2].forEach(function(n){this._removeProperty(n,"left");this._removeProperty(n,"right");this._removeProperty(n,"top")},this),[this.tooltip,this.tooltip_min,this.tooltip_max].forEach(function(n){this._removeProperty(n,"left");this._removeProperty(n,"right");this._removeProperty(n,"top");this._removeClass(n,"right");this._removeClass(n,"left");this._removeClass(n,"top")},this)),"vertical"===this.options.orientation?(this._addClass(this.sliderElem,"slider-vertical"),this.stylePos="top",this.mousePos="pageY",this.sizePos="offsetHeight"):(this._addClass(this.sliderElem,"slider-horizontal"),this.sliderElem.style.width=pt,this.options.orientation="horizontal",this.stylePos=this.options.rtl?"right":"left",this.mousePos="clientX",this.sizePos="offsetWidth"),this.options.rtl&&this._addClass(this.sliderElem,"slider-rtl"),this._setTooltipPosition(),Array.isArray(this.options.ticks)&&this.options.ticks.length>0&&(this.options.max=Math.max.apply(Math,this.options.ticks),this.options.min=Math.min.apply(Math,this.options.ticks)),Array.isArray(this.options.value)?(this.options.range=!0,this._state.value=this.options.value):this._state.value=this.options.range?[this.options.value,this.options.max]:this.options.value,this.trackLow=w||this.trackLow,this.trackSelection=l||this.trackSelection,this.trackHigh=b||this.trackHigh,"none"===this.options.selection?(this._addClass(this.trackLow,"hide"),this._addClass(this.trackSelection,"hide"),this._addClass(this.trackHigh,"hide")):("after"===this.options.selection||"before"===this.options.selection)&&(this._removeClass(this.trackLow,"hide"),this._removeClass(this.trackSelection,"hide"),this._removeClass(this.trackHigh,"hide")),this.handle1=u||this.handle1,this.handle2=f||this.handle2,ut===!0)for(this._removeClass(this.handle1,"round triangle"),this._removeClass(this.handle2,"round triangle hide"),r=0;r<this.ticks.length;r++)this._removeClass(this.ticks[r],"round triangle hide");if(lt=["round","triangle","custom"],at=-1!==lt.indexOf(this.options.handle),at)for(this._addClass(this.handle1,this.options.handle),this._addClass(this.handle2,this.options.handle),r=0;r<this.ticks.length;r++)this._addClass(this.ticks[r],this.options.handle);if(this._state.offset=this._offset(this.sliderElem),this._state.size=this.sliderElem[this.sizePos],this.setValue(this._state.value),this.handle1Keydown=this._keydown.bind(this,0),this.handle1.addEventListener("keydown",this.handle1Keydown,!1),this.handle2Keydown=this._keydown.bind(this,1),this.handle2.addEventListener("keydown",this.handle2Keydown,!1),this.mousedown=this._mousedown.bind(this),this.touchstart=this._touchstart.bind(this),this.touchmove=this._touchmove.bind(this),this.touchCapable){ft=!1;try{vt=Object.defineProperty({},"passive",{get:function(){ft=!0}});window.addEventListener("test",null,vt)}catch(ni){}et=ft?{passive:!0}:!1;this.sliderElem.addEventListener("touchstart",this.touchstart,et);this.sliderElem.addEventListener("touchmove",this.touchmove,et)}if(this.sliderElem.addEventListener("mousedown",this.mousedown,!1),this.resize=this._resize.bind(this),window.addEventListener("resize",this.resize,!1),"hide"===this.options.tooltip)this._addClass(this.tooltip,"hide"),this._addClass(this.tooltip_min,"hide"),this._addClass(this.tooltip_max,"hide");else if("always"===this.options.tooltip)this._showTooltip(),this._alwaysShowTooltip=!0;else{if(this.showTooltip=this._showTooltip.bind(this),this.hideTooltip=this._hideTooltip.bind(this),this.options.ticks_tooltip){var it=this._addTickListener(),ot=it.addMouseEnter(this,this.handle1),st=it.addMouseLeave(this,this.handle1);this.handleCallbackMap.handle1={mouseEnter:ot,mouseLeave:st};ot=it.addMouseEnter(this,this.handle2);st=it.addMouseLeave(this,this.handle2);this.handleCallbackMap.handle2={mouseEnter:ot,mouseLeave:st}}else this.sliderElem.addEventListener("mouseenter",this.showTooltip,!1),this.sliderElem.addEventListener("mouseleave",this.hideTooltip,!1);this.handle1.addEventListener("focus",this.showTooltip,!1);this.handle1.addEventListener("blur",this.hideTooltip,!1);this.handle2.addEventListener("focus",this.showTooltip,!1);this.handle2.addEventListener("blur",this.hideTooltip,!1)}this.options.enabled?this.enable():this.disable()}var e={formatInvalidInputErrorMsg:function(n){return"Invalid input value '"+n+"' passed in"},callingContextNotSliderInstance:"Calling context element does not have instance of Slider bound to it. Check your code to make sure the JQuery object returned from the call to the slider() initializer is calling the method"},o={linear:{toValue:function(n){var e=n/100*(this.options.max-this.options.min),o=!0,r,s,u,f,t,h,c,i;if(this.options.ticks_positions.length>0){for(f=0,t=1;t<this.options.ticks_positions.length;t++)if(n<=this.options.ticks_positions[t]){r=this.options.ticks[t-1];u=this.options.ticks_positions[t-1];s=this.options.ticks[t];f=this.options.ticks_positions[t];break}h=(n-u)/(f-u);e=r+h*(s-r);o=!1}return c=o?this.options.min:0,i=c+Math.round(e/this.options.step)*this.options.step,i<this.options.min?this.options.min:i>this.options.max?this.options.max:i},toPercentage:function(n){var i,f,r,u,t,e;if(this.options.max===this.options.min)return 0;if(this.options.ticks_positions.length>0){for(u=0,t=0;t<this.options.ticks.length;t++)if(n<=this.options.ticks[t]){i=t>0?this.options.ticks[t-1]:0;r=t>0?this.options.ticks_positions[t-1]:0;f=this.options.ticks[t];u=this.options.ticks_positions[t];break}if(t>0)return e=(n-i)/(f-i),r+e*(u-r)}return 100*(n-this.options.min)/(this.options.max-this.options.min)}},logarithmic:{toValue:function(n){var i=1-this.options.min,u=Math.log(this.options.min+i),r=Math.log(this.options.max+i),t=Math.exp(u+(r-u)*n/100)-i;return Math.round(t)===r?r:(t=this.options.min+Math.round((t-this.options.min)/this.options.step)*this.options.step,t<this.options.min?this.options.min:t>this.options.max?this.options.max:t)},toPercentage:function(n){if(this.options.max===this.options.min)return 0;var t=1-this.options.min,r=Math.log(this.options.max+t),i=Math.log(this.options.min+t),u=Math.log(n+t);return 100*(u-i)/(r-i)}}},u;(t=function(n,t){return f.call(this,n,t),this},t.prototype={_init:function(){},constructor:t,defaultOptions:{id:"",min:0,max:10,step:1,precision:0,orientation:"horizontal",value:5,range:!1,selection:"before",tooltip:"show",tooltip_split:!1,handle:"round",reversed:!1,rtl:"auto",enabled:!0,formatter:function(n){return Array.isArray(n)?n[0]+" : "+n[1]:n},natural_arrow_keys:!1,ticks:[],ticks_positions:[],ticks_labels:[],ticks_snap_bounds:0,ticks_tooltip:!1,scale:"linear",focus:!1,tooltip_position:null,labelledby:null,rangeHighlights:[]},getElement:function(){return this.sliderElem},getValue:function(){return this.options.range?this._state.value:this._state.value[0]},setValue:function(n,t,i){var f,u,r;return n||(n=0),f=this.getValue(),this._state.value=this._validateInputValue(n),u=this._applyPrecision.bind(this),this.options.range?(this._state.value[0]=u(this._state.value[0]),this._state.value[1]=u(this._state.value[1]),this._state.value[0]=Math.max(this.options.min,Math.min(this.options.max,this._state.value[0])),this._state.value[1]=Math.max(this.options.min,Math.min(this.options.max,this._state.value[1]))):(this._state.value=u(this._state.value),this._state.value=[Math.max(this.options.min,Math.min(this.options.max,this._state.value))],this._addClass(this.handle2,"hide"),this._state.value[1]="after"===this.options.selection?this.options.max:this.options.min),this._state.percentage=this.options.max>this.options.min?[this._toPercentage(this._state.value[0]),this._toPercentage(this._state.value[1]),100*this.options.step/(this.options.max-this.options.min)]:[0,0,100],this._layout(),r=this.options.range?this._state.value:this._state.value[0],this._setDataVal(r),t===!0&&this._trigger("slide",r),f!==r&&i===!0&&this._trigger("change",{oldValue:f,newValue:r}),this},destroy:function(){this._removeSliderEventHandlers();this.sliderElem.parentNode.removeChild(this.sliderElem);this.element.style.display="";this._cleanUpEventCallbacksMap();this.element.removeAttribute("data");n&&(this._unbindJQueryEventHandlers(),this.$element.removeData("slider"))},disable:function(){return this._state.enabled=!1,this.handle1.removeAttribute("tabindex"),this.handle2.removeAttribute("tabindex"),this._addClass(this.sliderElem,"slider-disabled"),this._trigger("slideDisabled"),this},enable:function(){return this._state.enabled=!0,this.handle1.setAttribute("tabindex",0),this.handle2.setAttribute("tabindex",0),this._removeClass(this.sliderElem,"slider-disabled"),this._trigger("slideEnabled"),this},toggle:function(){return this._state.enabled?this.disable():this.enable(),this},isEnabled:function(){return this._state.enabled},on:function(n,t){return this._bindNonQueryEventHandler(n,t),this},off:function(t,i){n?(this.$element.off(t,i),this.$sliderElem.off(t,i)):this._unbindNonQueryEventHandler(t,i)},getAttribute:function(n){return n?this.options[n]:this.options},setAttribute:function(n,t){return this.options[n]=t,this},refresh:function(){return this._removeSliderEventHandlers(),f.call(this,this.element,this.options),n&&n.data(this.element,"slider",this),this},relayout:function(){return this._resize(),this._layout(),this},_removeSliderEventHandlers:function(){if(this.handle1.removeEventListener("keydown",this.handle1Keydown,!1),this.handle2.removeEventListener("keydown",this.handle2Keydown,!1),this.options.ticks_tooltip){for(var t=this.ticksContainer.getElementsByClassName("slider-tick"),n=0;n<t.length;n++)t[n].removeEventListener("mouseenter",this.ticksCallbackMap[n].mouseEnter,!1),t[n].removeEventListener("mouseleave",this.ticksCallbackMap[n].mouseLeave,!1);this.handle1.removeEventListener("mouseenter",this.handleCallbackMap.handle1.mouseEnter,!1);this.handle2.removeEventListener("mouseenter",this.handleCallbackMap.handle2.mouseEnter,!1);this.handle1.removeEventListener("mouseleave",this.handleCallbackMap.handle1.mouseLeave,!1);this.handle2.removeEventListener("mouseleave",this.handleCallbackMap.handle2.mouseLeave,!1)}this.handleCallbackMap=null;this.ticksCallbackMap=null;this.showTooltip&&(this.handle1.removeEventListener("focus",this.showTooltip,!1),this.handle2.removeEventListener("focus",this.showTooltip,!1));this.hideTooltip&&(this.handle1.removeEventListener("blur",this.hideTooltip,!1),this.handle2.removeEventListener("blur",this.hideTooltip,!1));this.showTooltip&&this.sliderElem.removeEventListener("mouseenter",this.showTooltip,!1);this.hideTooltip&&this.sliderElem.removeEventListener("mouseleave",this.hideTooltip,!1);this.sliderElem.removeEventListener("touchstart",this.touchstart,!1);this.sliderElem.removeEventListener("touchmove",this.touchmove,!1);this.sliderElem.removeEventListener("mousedown",this.mousedown,!1);window.removeEventListener("resize",this.resize,!1)},_bindNonQueryEventHandler:function(n,t){void 0===this.eventToCallbackMap[n]&&(this.eventToCallbackMap[n]=[]);this.eventToCallbackMap[n].push(t)},_unbindNonQueryEventHandler:function(n,t){var r=this.eventToCallbackMap[n],i;if(void 0!==r)for(i=0;i<r.length;i++)if(r[i]===t){r.splice(i,1);break}},_cleanUpEventCallbacksMap:function(){for(var i,t=Object.keys(this.eventToCallbackMap),n=0;n<t.length;n++)i=t[n],delete this.eventToCallbackMap[i]},_showTooltip:function(){this.options.tooltip_split===!1?(this._addClass(this.tooltip,"in"),this.tooltip_min.style.display="none",this.tooltip_max.style.display="none"):(this._addClass(this.tooltip_min,"in"),this._addClass(this.tooltip_max,"in"),this.tooltip.style.display="none");this._state.over=!0},_hideTooltip:function(){this._state.inDrag===!1&&this.alwaysShowTooltip!==!0&&(this._removeClass(this.tooltip,"in"),this._removeClass(this.tooltip_min,"in"),this._removeClass(this.tooltip_max,"in"));this._state.over=!1},_setToolTipOnMouseOver:function(n){function t(n,t){return t?[100-n.percentage[0],this.options.range?100-n.percentage[1]:n.percentage[1]]:[n.percentage[0],n.percentage[1]]}var i=this.options.formatter(n?n.value[0]:this._state.value[0]),r=n?t(n,this.options.reversed):t(this._state,this.options.reversed);this._setText(this.tooltipInner,i);this.tooltip.style[this.stylePos]=r[0]+"%"},_addTickListener:function(){return{addMouseEnter:function(n,t,i){var r=function(){var t=n._state,u=i>=0?i:this.attributes["aria-valuenow"].value,r=parseInt(u,10);t.value[0]=r;t.percentage[0]=n.options.ticks_positions[r];n._setToolTipOnMouseOver(t);n._showTooltip()};return t.addEventListener("mouseenter",r,!1),r},addMouseLeave:function(n,t){var i=function(){n._hideTooltip()};return t.addEventListener("mouseleave",i,!1),i}}},_layout:function(){var n,i,e,o,v,u,s,y,h,f,t,r,c,p,w,l,a;if(n=this.options.reversed?[100-this._state.percentage[0],this.options.range?100-this._state.percentage[1]:this._state.percentage[1]]:[this._state.percentage[0],this._state.percentage[1]],this.handle1.style[this.stylePos]=n[0]+"%",this.handle1.setAttribute("aria-valuenow",this._state.value[0]),isNaN(this.options.formatter(this._state.value[0]))&&this.handle1.setAttribute("aria-valuetext",this.options.formatter(this._state.value[0])),this.handle2.style[this.stylePos]=n[1]+"%",this.handle2.setAttribute("aria-valuenow",this._state.value[1]),isNaN(this.options.formatter(this._state.value[1]))&&this.handle2.setAttribute("aria-valuetext",this.options.formatter(this._state.value[1])),this.rangeHighlightElements.length>0&&Array.isArray(this.options.rangeHighlights)&&this.options.rangeHighlights.length>0)for(i=0;i<this.options.rangeHighlights.length;i++)e=this._toPercentage(this.options.rangeHighlights[i].start),o=this._toPercentage(this.options.rangeHighlights[i].end),this.options.reversed&&(v=100-o,o=100-e,e=v),u=this._createHighlightRange(e,o),u?"vertical"===this.options.orientation?(this.rangeHighlightElements[i].style.top=u.start+"%",this.rangeHighlightElements[i].style.height=u.size+"%"):(this.options.rtl?this.rangeHighlightElements[i].style.right=u.start+"%":this.rangeHighlightElements[i].style.left=u.start+"%",this.rangeHighlightElements[i].style.width=u.size+"%"):this.rangeHighlightElements[i].style.display="none";if(Array.isArray(this.options.ticks)&&this.options.ticks.length>0){if(y="vertical"===this.options.orientation?"height":"width",s="vertical"===this.options.orientation?"marginTop":this.options.rtl?"marginRight":"marginLeft",h=this._state.size/(this.options.ticks.length-1),this.tickLabelContainer){if(f=0,0===this.options.ticks_positions.length)"vertical"!==this.options.orientation&&(this.tickLabelContainer.style[s]=-h/2+"px"),f=this.tickLabelContainer.offsetHeight;else for(t=0;t<this.tickLabelContainer.childNodes.length;t++)this.tickLabelContainer.childNodes[t].offsetHeight>f&&(f=this.tickLabelContainer.childNodes[t].offsetHeight);"horizontal"===this.options.orientation&&(this.sliderElem.style.marginBottom=f+"px")}for(t=0;t<this.options.ticks.length;t++)r=this.options.ticks_positions[t]||this._toPercentage(this.options.ticks[t]),this.options.reversed&&(r=100-r),this.ticks[t].style[this.stylePos]=r+"%",this._removeClass(this.ticks[t],"in-selection"),this.options.range?r>=n[0]&&r<=n[1]&&this._addClass(this.ticks[t],"in-selection"):"after"===this.options.selection&&r>=n[0]?this._addClass(this.ticks[t],"in-selection"):"before"===this.options.selection&&r<=n[0]&&this._addClass(this.ticks[t],"in-selection"),this.tickLabels[t]&&(this.tickLabels[t].style[y]=h+"px","vertical"!==this.options.orientation&&void 0!==this.options.ticks_positions[t]?(this.tickLabels[t].style.position="absolute",this.tickLabels[t].style[this.stylePos]=r+"%",this.tickLabels[t].style[s]=-h/2+"px"):"vertical"===this.options.orientation&&(this.options.rtl?this.tickLabels[t].style.marginRight=this.sliderElem.offsetWidth+"px":this.tickLabels[t].style.marginLeft=this.sliderElem.offsetWidth+"px",this.tickLabelContainer.style[s]=this.sliderElem.offsetWidth/-2+"px"))}this.options.range?(c=this.options.formatter(this._state.value),this._setText(this.tooltipInner,c),this.tooltip.style[this.stylePos]=(n[1]+n[0])/2+"%",p=this.options.formatter(this._state.value[0]),this._setText(this.tooltipInner_min,p),w=this.options.formatter(this._state.value[1]),this._setText(this.tooltipInner_max,w),this.tooltip_min.style[this.stylePos]=n[0]+"%",this.tooltip_max.style[this.stylePos]=n[1]+"%"):(c=this.options.formatter(this._state.value[0]),this._setText(this.tooltipInner,c),this.tooltip.style[this.stylePos]=n[0]+"%");"vertical"===this.options.orientation?(this.trackLow.style.top="0",this.trackLow.style.height=Math.min(n[0],n[1])+"%",this.trackSelection.style.top=Math.min(n[0],n[1])+"%",this.trackSelection.style.height=Math.abs(n[0]-n[1])+"%",this.trackHigh.style.bottom="0",this.trackHigh.style.height=100-Math.min(n[0],n[1])-Math.abs(n[0]-n[1])+"%"):("right"===this.stylePos?this.trackLow.style.right="0":this.trackLow.style.left="0",this.trackLow.style.width=Math.min(n[0],n[1])+"%","right"===this.stylePos?this.trackSelection.style.right=Math.min(n[0],n[1])+"%":this.trackSelection.style.left=Math.min(n[0],n[1])+"%",this.trackSelection.style.width=Math.abs(n[0]-n[1])+"%","right"===this.stylePos?this.trackHigh.style.left="0":this.trackHigh.style.right="0",this.trackHigh.style.width=100-Math.min(n[0],n[1])-Math.abs(n[0]-n[1])+"%",l=this.tooltip_min.getBoundingClientRect(),a=this.tooltip_max.getBoundingClientRect(),"bottom"===this.options.tooltip_position?l.right>a.left?(this._removeClass(this.tooltip_max,"bottom"),this._addClass(this.tooltip_max,"top"),this.tooltip_max.style.top="",this.tooltip_max.style.bottom="22px"):(this._removeClass(this.tooltip_max,"top"),this._addClass(this.tooltip_max,"bottom"),this.tooltip_max.style.top=this.tooltip_min.style.top,this.tooltip_max.style.bottom=""):l.right>a.left?(this._removeClass(this.tooltip_max,"top"),this._addClass(this.tooltip_max,"bottom"),this.tooltip_max.style.top="18px"):(this._removeClass(this.tooltip_max,"bottom"),this._addClass(this.tooltip_max,"top"),this.tooltip_max.style.top=this.tooltip_min.style.top))},_createHighlightRange:function(n,t){return this._isHighlightRange(n,t)?n>t?{start:t,size:n-t}:{start:n,size:t-n}:null},_isHighlightRange:function(n,t){return n>=0&&100>=n&&t>=0&&100>=t?!0:!1},_resize:function(){this._state.offset=this._offset(this.sliderElem);this._state.size=this.sliderElem[this.sizePos];this._layout()},_removeProperty:function(n,t){n.style.removeProperty?n.style.removeProperty(t):n.style.removeAttribute(t)},_mousedown:function(n){var t,r,u,i;return this._state.enabled?(n.preventDefault&&n.preventDefault(),this._state.offset=this._offset(this.sliderElem),this._state.size=this.sliderElem[this.sizePos],t=this._getPercentage(n),this.options.range?(r=Math.abs(this._state.percentage[0]-t),u=Math.abs(this._state.percentage[1]-t),this._state.dragged=u>r?0:1,this._adjustPercentageForRangeSliders(t)):this._state.dragged=0,this._state.percentage[this._state.dragged]=t,this._layout(),this.touchCapable&&(document.removeEventListener("touchmove",this.mousemove,!1),document.removeEventListener("touchend",this.mouseup,!1)),this.mousemove&&document.removeEventListener("mousemove",this.mousemove,!1),this.mouseup&&document.removeEventListener("mouseup",this.mouseup,!1),this.mousemove=this._mousemove.bind(this),this.mouseup=this._mouseup.bind(this),this.touchCapable&&(document.addEventListener("touchmove",this.mousemove,!1),document.addEventListener("touchend",this.mouseup,!1)),document.addEventListener("mousemove",this.mousemove,!1),document.addEventListener("mouseup",this.mouseup,!1),this._state.inDrag=!0,i=this._calculateValue(),this._trigger("slideStart",i),this._setDataVal(i),this.setValue(i,!1,!0),n.returnValue=!1,this.options.focus&&this._triggerFocusOnHandle(this._state.dragged),!0):!1},_touchstart:function(n){if(void 0===n.changedTouches)return void this._mousedown(n);var t=n.changedTouches[0];this.touchX=t.pageX;this.touchY=t.pageY},_triggerFocusOnHandle:function(n){0===n&&this.handle1.focus();1===n&&this.handle2.focus()},_keydown:function(n,t){var r,u,f,i,e,o,s;if(!this._state.enabled)return!1;switch(t.keyCode){case 37:case 40:r=-1;break;case 39:case 38:r=1}if(r)return this.options.natural_arrow_keys&&(u="vertical"===this.options.orientation&&!this.options.reversed,f="horizontal"===this.options.orientation&&this.options.reversed,(u||f)&&(r=-r)),i=this._state.value[n]+r*this.options.step,e=i/this.options.max*100,(this._state.keyCtrl=n,this.options.range)&&(this._adjustPercentageForRangeSliders(e),o=this._state.keyCtrl?this._state.value[0]:i,s=this._state.keyCtrl?i:this._state.value[1],i=[o,s]),this._trigger("slideStart",i),this._setDataVal(i),this.setValue(i,!0,!0),this._setDataVal(i),this._trigger("slideStop",i),this._layout(),this._pauseEvent(t),delete this._state.keyCtrl,!1},_pauseEvent:function(n){n.stopPropagation&&n.stopPropagation();n.preventDefault&&n.preventDefault();n.cancelBubble=!0;n.returnValue=!1},_mousemove:function(n){var t,i;return this._state.enabled?(t=this._getPercentage(n),this._adjustPercentageForRangeSliders(t),this._state.percentage[this._state.dragged]=t,this._layout(),i=this._calculateValue(!0),this.setValue(i,!0,!0),!1):!1},_touchmove:function(n){if(void 0!==n.changedTouches){var r=n.changedTouches[0],t=r.pageX-this.touchX,i=r.pageY-this.touchY;this._state.inDrag||("vertical"===this.options.orientation&&5>=t&&t>=-5&&(i>=15||-15>=i)?this._mousedown(n):5>=i&&i>=-5&&(t>=15||-15>=t)&&this._mousedown(n))}},_adjustPercentageForRangeSliders:function(n){var t,i;this.options.range&&(t=this._getNumDigitsAfterDecimalPlace(n),t=t?t-1:0,i=this._applyToFixedAndParseFloat(n,t),0===this._state.dragged&&this._applyToFixedAndParseFloat(this._state.percentage[1],t)<i?(this._state.percentage[0]=this._state.percentage[1],this._state.dragged=1):1===this._state.dragged&&this._applyToFixedAndParseFloat(this._state.percentage[0],t)>i?(this._state.percentage[1]=this._state.percentage[0],this._state.dragged=0):0===this._state.keyCtrl&&this._state.value[1]/this.options.max*100<n?(this._state.percentage[0]=this._state.percentage[1],this._state.keyCtrl=1,this.handle2.focus()):1===this._state.keyCtrl&&this._state.value[0]/this.options.max*100>n&&(this._state.percentage[1]=this._state.percentage[0],this._state.keyCtrl=0,this.handle1.focus()))},_mouseup:function(){if(!this._state.enabled)return!1;this.touchCapable&&(document.removeEventListener("touchmove",this.mousemove,!1),document.removeEventListener("touchend",this.mouseup,!1));document.removeEventListener("mousemove",this.mousemove,!1);document.removeEventListener("mouseup",this.mouseup,!1);this._state.inDrag=!1;this._state.over===!1&&this._hideTooltip();var n=this._calculateValue(!0);return this._layout(),this._setDataVal(n),this._trigger("slideStop",n),!1},_calculateValue:function(n){var t,i,r,u;if(this.options.range?(t=[this.options.min,this.options.max],0!==this._state.percentage[0]&&(t[0]=this._toValue(this._state.percentage[0]),t[0]=this._applyPrecision(t[0])),100!==this._state.percentage[1]&&(t[1]=this._toValue(this._state.percentage[1]),t[1]=this._applyPrecision(t[1]))):(t=this._toValue(this._state.percentage[0]),t=parseFloat(t),t=this._applyPrecision(t)),n){for(i=[t,1/0],r=0;r<this.options.ticks.length;r++)u=Math.abs(this.options.ticks[r]-t),u<=i[1]&&(i=[this.options.ticks[r],u]);if(i[1]<=this.options.ticks_snap_bounds)return i[0]}return t},_applyPrecision:function(n){var t=this.options.precision||this._getNumDigitsAfterDecimalPlace(this.options.step);return this._applyToFixedAndParseFloat(n,t)},_getNumDigitsAfterDecimalPlace:function(n){var t=(""+n).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return t?Math.max(0,(t[1]?t[1].length:0)-(t[2]?+t[2]:0)):0},_applyToFixedAndParseFloat:function(n,t){var i=n.toFixed(t);return parseFloat(i)},_getPercentage:function(n){var t;this.touchCapable&&("touchstart"===n.type||"touchmove"===n.type)&&(n=n.touches[0]);var r=n[this.mousePos],u=this._state.offset[this.stylePos],i=r-u;return"right"===this.stylePos&&(i=-i),t=i/this._state.size*100,t=Math.round(t/this._state.percentage[2])*this._state.percentage[2],this.options.reversed&&(t=100-t),Math.max(0,Math.min(100,t))},_validateInputValue:function(n){if(isNaN(+n)){if(Array.isArray(n))return this._validateArray(n),n;throw new Error(e.formatInvalidInputErrorMsg(n));}return+n},_validateArray:function(n){for(var i,t=0;t<n.length;t++)if(i=n[t],"number"!=typeof i)throw new Error(e.formatInvalidInputErrorMsg(i));},_setDataVal:function(n){this.element.setAttribute("data-value",n);this.element.setAttribute("value",n);this.element.value=n},_trigger:function(t,i){var r,u,f;if(i=i||0===i?i:void 0,r=this.eventToCallbackMap[t],r&&r.length)for(u=0;u<r.length;u++)f=r[u],f(i);n&&this._triggerJQueryEvent(t,i)},_triggerJQueryEvent:function(n,t){var i={type:n,value:t};this.$element.trigger(i);this.$sliderElem.trigger(i)},_unbindJQueryEventHandlers:function(){this.$element.off();this.$sliderElem.off()},_setText:function(n,t){"undefined"!=typeof n.textContent?n.textContent=t:"undefined"!=typeof n.innerText&&(n.innerText=t)},_removeClass:function(n,t){for(var f,e,u=t.split(" "),i=n.className,r=0;r<u.length;r++)f=u[r],e=new RegExp("(?:\\s|^)"+f+"(?:\\s|$)"),i=i.replace(e," ");n.className=i.trim()},_addClass:function(n,t){for(var u=t.split(" "),i=n.className,r=0;r<u.length;r++){var f=u[r],e=new RegExp("(?:\\s|^)"+f+"(?:\\s|$)"),o=e.test(i);o||(i+=" "+f)}n.className=i.trim()},_offsetLeft:function(n){return n.getBoundingClientRect().left},_offsetRight:function(n){return n.getBoundingClientRect().right},_offsetTop:function(n){for(var t=n.offsetTop;(n=n.offsetParent)&&!isNaN(n.offsetTop);)t+=n.offsetTop,"BODY"!==n.tagName&&(t-=n.scrollTop);return t},_offset:function(n){return{left:this._offsetLeft(n),right:this._offsetRight(n),top:this._offsetTop(n)}},_css:function(t,i,r){if(n)n.style(t,i,r);else{var u=i.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(n,t){return t.toUpperCase()});t.style[u]=r}},_toValue:function(n){return this.options.scale.toValue.apply(this,[n])},_toPercentage:function(n){return this.options.scale.toPercentage.apply(this,[n])},_setTooltipPosition:function(){var n=[this.tooltip,this.tooltip_min,this.tooltip_max],t,i;"vertical"===this.options.orientation?(t=this.options.tooltip_position?this.options.tooltip_position:this.options.rtl?"left":"right",i="left"===t?"right":"left",n.forEach(function(n){this._addClass(n,t);n.style[i]="100%"}.bind(this))):"bottom"===this.options.tooltip_position?n.forEach(function(n){this._addClass(n,"bottom");n.style.top="22px"}.bind(this)):n.forEach(function(n){this._addClass(n,"top");n.style.top=-this.tooltip.outerHeight-14+"px"}.bind(this))}},n&&n.fn)&&(u=void 0,n.fn.slider?(windowIsDefined&&window.console.warn("bootstrap-slider.js - WARNING: $.fn.slider namespace is already bound. Use the $.fn.bootstrapSlider namespace instead."),u=r):(n.bridget(i,t),u=i),n.bridget(r,t),n(function(){n("input[data-provide=slider]")[u]()}))}(n),t})