vue-slider-component
Advanced tools
Comparing version 3.0.11 to 3.0.12
# CHANGELOG | ||
## v3.0.7 | ||
## v3.0.12 | ||
> `2019-03-07` | ||
> `2019-03-14` | ||
### 🎉 Feature | ||
- `width` and `height` support `String` type | ||
## v3.0.11 | ||
> `2019-03-13` | ||
### 🔧 Chore | ||
- Optimize package size | ||
- Upgrade vue-property-decorator, fix [#320](https://github.com/NightCatSama/vue-slider-component/issues/320) | ||
## v3.0.8 | ||
> `2019-03-11` | ||
### 🐞 Bug Fixes | ||
@@ -8,0 +23,0 @@ - Component not updated when array length changes |
@@ -1,7 +0,7 @@ | ||
(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e(require("vue")):"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["vue-slider-component"]=e(require("vue")):t["vue-slider-component"]=e(t["Vue"])})("undefined"!==typeof self?self:this,function(t){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)r.d(n,o,function(e){return t[e]}.bind(null,o));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s="fb15")}({2350:function(t,e){function r(t,e){var r=t[1]||"",o=t[3];if(!o)return r;if(e&&"function"===typeof btoa){var i=n(o),a=o.sources.map(function(t){return"/*# sourceURL="+o.sourceRoot+t+" */"});return[r].concat(a).concat([i]).join("\n")}return[r].join("\n")}function n(t){var e=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),r="sourceMappingURL=data:application/json;charset=utf-8;base64,"+e;return"/*# "+r+" */"}t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var n=r(e,t);return e[2]?"@media "+e[2]+"{"+n+"}":n}).join("")},e.i=function(t,r){"string"===typeof t&&(t=[[null,t,""]]);for(var n={},o=0;o<this.length;o++){var i=this[o][0];"number"===typeof i&&(n[i]=!0)}for(o=0;o<t.length;o++){var a=t[o];"number"===typeof a[0]&&n[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),e.push(a))}},e}},"499e":function(t,e,r){"use strict";function n(t,e){for(var r=[],n={},o=0;o<e.length;o++){var i=e[o],a=i[0],s=i[1],u=i[2],l=i[3],c={id:t+":"+o,css:s,media:u,sourceMap:l};n[a]?n[a].parts.push(c):r.push(n[a]={id:a,parts:[c]})}return r}r.r(e),r.d(e,"default",function(){return h});var o="undefined"!==typeof document;if("undefined"!==typeof DEBUG&&DEBUG&&!o)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var i={},a=o&&(document.head||document.getElementsByTagName("head")[0]),s=null,u=0,l=!1,c=function(){},d=null,f="data-vue-ssr-id",p="undefined"!==typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function h(t,e,r,o){l=r,d=o||{};var a=n(t,e);return v(a),function(e){for(var r=[],o=0;o<a.length;o++){var s=a[o],u=i[s.id];u.refs--,r.push(u)}e?(a=n(t,e),v(a)):a=[];for(o=0;o<r.length;o++){u=r[o];if(0===u.refs){for(var l=0;l<u.parts.length;l++)u.parts[l]();delete i[u.id]}}}}function v(t){for(var e=0;e<t.length;e++){var r=t[e],n=i[r.id];if(n){n.refs++;for(var o=0;o<n.parts.length;o++)n.parts[o](r.parts[o]);for(;o<r.parts.length;o++)n.parts.push(m(r.parts[o]));n.parts.length>r.parts.length&&(n.parts.length=r.parts.length)}else{var a=[];for(o=0;o<r.parts.length;o++)a.push(m(r.parts[o]));i[r.id]={id:r.id,refs:1,parts:a}}}}function y(){var t=document.createElement("style");return t.type="text/css",a.appendChild(t),t}function m(t){var e,r,n=document.querySelector("style["+f+'~="'+t.id+'"]');if(n){if(l)return c;n.parentNode.removeChild(n)}if(p){var o=u++;n=s||(s=y()),e=g.bind(null,n,o,!1),r=g.bind(null,n,o,!0)}else n=y(),e=k.bind(null,n),r=function(){n.parentNode.removeChild(n)};return e(t),function(n){if(n){if(n.css===t.css&&n.media===t.media&&n.sourceMap===t.sourceMap)return;e(t=n)}else r()}}var b=function(){var t=[];return function(e,r){return t[e]=r,t.filter(Boolean).join("\n")}}();function g(t,e,r,n){var o=r?"":n.css;if(t.styleSheet)t.styleSheet.cssText=b(e,o);else{var i=document.createTextNode(o),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(i,a[e]):t.appendChild(i)}}function k(t,e){var r=e.css,n=e.media,o=e.sourceMap;if(n&&t.setAttribute("media",n),d.ssrId&&t.setAttribute(f,e.id),o&&(r+="\n/*# sourceURL="+o.sources[0]+" */",r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */"),t.styleSheet)t.styleSheet.cssText=r;else{while(t.firstChild)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(r))}}},"4abb":function(t,e,r){var n=r("df80");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("3e7284f8",n,!0,{sourceMap:!1,shadowMode:!1})},"4ed8":function(t,e,r){var n=r("ae61");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("57c2b2f0",n,!0,{sourceMap:!1,shadowMode:!1})},"556c":function(t,e,r){var n=r("d5ac");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("f3ffc7f8",n,!0,{sourceMap:!1,shadowMode:!1})},"65d9":function(t,e,r){"use strict"; | ||
(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e(require("vue")):"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["vue-slider-component"]=e(require("vue")):t["vue-slider-component"]=e(t["Vue"])})("undefined"!==typeof self?self:this,function(t){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)r.d(n,o,function(e){return t[e]}.bind(null,o));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s="fb15")}({2350:function(t,e){function r(t,e){var r=t[1]||"",o=t[3];if(!o)return r;if(e&&"function"===typeof btoa){var i=n(o),s=o.sources.map(function(t){return"/*# sourceURL="+o.sourceRoot+t+" */"});return[r].concat(s).concat([i]).join("\n")}return[r].join("\n")}function n(t){var e=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),r="sourceMappingURL=data:application/json;charset=utf-8;base64,"+e;return"/*# "+r+" */"}t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var n=r(e,t);return e[2]?"@media "+e[2]+"{"+n+"}":n}).join("")},e.i=function(t,r){"string"===typeof t&&(t=[[null,t,""]]);for(var n={},o=0;o<this.length;o++){var i=this[o][0];"number"===typeof i&&(n[i]=!0)}for(o=0;o<t.length;o++){var s=t[o];"number"===typeof s[0]&&n[s[0]]||(r&&!s[2]?s[2]=r:r&&(s[2]="("+s[2]+") and ("+r+")"),e.push(s))}},e}},"499e":function(t,e,r){"use strict";function n(t,e){for(var r=[],n={},o=0;o<e.length;o++){var i=e[o],s=i[0],a=i[1],u=i[2],l=i[3],c={id:t+":"+o,css:a,media:u,sourceMap:l};n[s]?n[s].parts.push(c):r.push(n[s]={id:s,parts:[c]})}return r}r.r(e),r.d(e,"default",function(){return p});var o="undefined"!==typeof document;if("undefined"!==typeof DEBUG&&DEBUG&&!o)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var i={},s=o&&(document.head||document.getElementsByTagName("head")[0]),a=null,u=0,l=!1,c=function(){},d=null,f="data-vue-ssr-id",h="undefined"!==typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function p(t,e,r,o){l=r,d=o||{};var s=n(t,e);return v(s),function(e){for(var r=[],o=0;o<s.length;o++){var a=s[o],u=i[a.id];u.refs--,r.push(u)}e?(s=n(t,e),v(s)):s=[];for(o=0;o<r.length;o++){u=r[o];if(0===u.refs){for(var l=0;l<u.parts.length;l++)u.parts[l]();delete i[u.id]}}}}function v(t){for(var e=0;e<t.length;e++){var r=t[e],n=i[r.id];if(n){n.refs++;for(var o=0;o<n.parts.length;o++)n.parts[o](r.parts[o]);for(;o<r.parts.length;o++)n.parts.push(m(r.parts[o]));n.parts.length>r.parts.length&&(n.parts.length=r.parts.length)}else{var s=[];for(o=0;o<r.parts.length;o++)s.push(m(r.parts[o]));i[r.id]={id:r.id,refs:1,parts:s}}}}function y(){var t=document.createElement("style");return t.type="text/css",s.appendChild(t),t}function m(t){var e,r,n=document.querySelector("style["+f+'~="'+t.id+'"]');if(n){if(l)return c;n.parentNode.removeChild(n)}if(h){var o=u++;n=a||(a=y()),e=g.bind(null,n,o,!1),r=g.bind(null,n,o,!0)}else n=y(),e=k.bind(null,n),r=function(){n.parentNode.removeChild(n)};return e(t),function(n){if(n){if(n.css===t.css&&n.media===t.media&&n.sourceMap===t.sourceMap)return;e(t=n)}else r()}}var b=function(){var t=[];return function(e,r){return t[e]=r,t.filter(Boolean).join("\n")}}();function g(t,e,r,n){var o=r?"":n.css;if(t.styleSheet)t.styleSheet.cssText=b(e,o);else{var i=document.createTextNode(o),s=t.childNodes;s[e]&&t.removeChild(s[e]),s.length?t.insertBefore(i,s[e]):t.appendChild(i)}}function k(t,e){var r=e.css,n=e.media,o=e.sourceMap;if(n&&t.setAttribute("media",n),d.ssrId&&t.setAttribute(f,e.id),o&&(r+="\n/*# sourceURL="+o.sources[0]+" */",r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */"),t.styleSheet)t.styleSheet.cssText=r;else{while(t.firstChild)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(r))}}},"4abb":function(t,e,r){var n=r("df80");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("3e7284f8",n,!0,{sourceMap:!1,shadowMode:!1})},"4ed8":function(t,e,r){var n=r("ae61");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("57c2b2f0",n,!0,{sourceMap:!1,shadowMode:!1})},"556c":function(t,e,r){var n=r("d5ac");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=r("499e").default;o("f3ffc7f8",n,!0,{sourceMap:!1,shadowMode:!1})},"8bbf":function(e,r){e.exports=t},ae61:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider-dot{position:absolute;will-change:transform;-webkit-transition:all 0s;transition:all 0s;z-index:5}.vue-slider-dot-tooltip{position:absolute;visibility:hidden}.vue-slider-dot-tooltip-show{visibility:visible}.vue-slider-dot-tooltip-top{top:-10px;left:50%;-webkit-transform:translate(-50%,-100%);transform:translate(-50%,-100%)}.vue-slider-dot-tooltip-bottom{bottom:-10px;left:50%;-webkit-transform:translate(-50%,100%);transform:translate(-50%,100%)}.vue-slider-dot-tooltip-left{left:-10px;top:50%;-webkit-transform:translate(-100%,-50%);transform:translate(-100%,-50%)}.vue-slider-dot-tooltip-right{right:-10px;top:50%;-webkit-transform:translate(100%,-50%);transform:translate(100%,-50%)}",""])},c89a:function(t,e,r){"use strict"; | ||
/** | ||
* vue-class-component v7.0.1 | ||
* vue-class-component v6.3.0 | ||
* (c) 2015-present Evan You | ||
* @license MIT | ||
*/function n(t){return t&&"object"===typeof t&&"default"in t?t["default"]:t}Object.defineProperty(e,"__esModule",{value:!0});var o=n(r("8bbf")),i="undefined"!==typeof Reflect&&Reflect.defineMetadata&&Reflect.getOwnMetadataKeys;function a(t,e){s(t,e),Object.getOwnPropertyNames(e.prototype).forEach(function(r){s(t.prototype,e.prototype,r)}),Object.getOwnPropertyNames(e).forEach(function(r){s(t,e,r)})}function s(t,e,r){var n=r?Reflect.getOwnMetadataKeys(e,r):Reflect.getOwnMetadataKeys(e);n.forEach(function(n){var o=r?Reflect.getOwnMetadata(n,e,r):Reflect.getOwnMetadata(n,e);r?Reflect.defineMetadata(n,o,t,r):Reflect.defineMetadata(n,o,t)})}var u={__proto__:[]},l=u instanceof Array;function c(t){return function(e,r,n){var o="function"===typeof e?e:e.constructor;o.__decorators__||(o.__decorators__=[]),"number"!==typeof n&&(n=void 0),o.__decorators__.push(function(e){return t(e,r,n)})}}function d(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return o.extend({mixins:t})}function f(t){var e=typeof t;return null==t||"object"!==e&&"function"!==e}function p(t,e){var r=e.prototype._init;e.prototype._init=function(){var e=this,r=Object.getOwnPropertyNames(t);if(t.$options.props)for(var n in t.$options.props)t.hasOwnProperty(n)||r.push(n);r.forEach(function(r){"_"!==r.charAt(0)&&Object.defineProperty(e,r,{get:function(){return t[r]},set:function(e){t[r]=e},configurable:!0})})};var n=new e;e.prototype._init=r;var o={};return Object.keys(n).forEach(function(t){void 0!==n[t]&&(o[t]=n[t])}),o}var h=["data","beforeCreate","created","beforeMount","mounted","beforeDestroy","destroyed","beforeUpdate","updated","activated","deactivated","render","errorCaptured","serverPrefetch"];function v(t,e){void 0===e&&(e={}),e.name=e.name||t._componentTag||t.name;var r=t.prototype;Object.getOwnPropertyNames(r).forEach(function(t){if("constructor"!==t)if(h.indexOf(t)>-1)e[t]=r[t];else{var n=Object.getOwnPropertyDescriptor(r,t);void 0!==n.value?"function"===typeof n.value?(e.methods||(e.methods={}))[t]=n.value:(e.mixins||(e.mixins=[])).push({data:function(){var e;return e={},e[t]=n.value,e}}):(n.get||n.set)&&((e.computed||(e.computed={}))[t]={get:n.get,set:n.set})}}),(e.mixins||(e.mixins=[])).push({data:function(){return p(this,t)}});var n=t.__decorators__;n&&(n.forEach(function(t){return t(e)}),delete t.__decorators__);var s=Object.getPrototypeOf(t.prototype),u=s instanceof o?s.constructor:o,l=u.extend(e);return y(l,t,u),i&&a(l,t),l}function y(t,e,r){Object.getOwnPropertyNames(e).forEach(function(n){if("prototype"!==n){var o=Object.getOwnPropertyDescriptor(t,n);if(!o||o.configurable){var i=Object.getOwnPropertyDescriptor(e,n);if(!l){if("cid"===n)return;var a=Object.getOwnPropertyDescriptor(r,n);if(!f(i.value)&&a&&a.value===i.value)return}0,Object.defineProperty(t,n,i)}}})}function m(t){return"function"===typeof t?v(t):function(e){return v(e,t)}}m.registerHooks=function(t){h.push.apply(h,t)},e.default=m,e.createDecorator=c,e.mixins=d},"8bbf":function(e,r){e.exports=t},ae61:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider-dot{position:absolute;will-change:transform;-webkit-transition:all 0s;transition:all 0s;z-index:5}.vue-slider-dot-tooltip{position:absolute;visibility:hidden}.vue-slider-dot-tooltip-show{visibility:visible}.vue-slider-dot-tooltip-top{top:-10px;left:50%;-webkit-transform:translate(-50%,-100%);transform:translate(-50%,-100%)}.vue-slider-dot-tooltip-bottom{bottom:-10px;left:50%;-webkit-transform:translate(-50%,100%);transform:translate(-50%,100%)}.vue-slider-dot-tooltip-left{left:-10px;top:50%;-webkit-transform:translate(-100%,-50%);transform:translate(-100%,-50%)}.vue-slider-dot-tooltip-right{right:-10px;top:50%;-webkit-transform:translate(100%,-50%);transform:translate(100%,-50%)}",""])},d5ac:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider-marks{position:relative;width:100%;height:100%}.vue-slider-mark{position:absolute;z-index:1}.vue-slider-ltr .vue-slider-mark,.vue-slider-rtl .vue-slider-mark{width:0;height:100%;top:50%}.vue-slider-ltr .vue-slider-mark-step,.vue-slider-rtl .vue-slider-mark-step{top:0}.vue-slider-ltr .vue-slider-mark-label,.vue-slider-rtl .vue-slider-mark-label{top:100%;margin-top:10px}.vue-slider-ltr .vue-slider-mark{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.vue-slider-ltr .vue-slider-mark-step{left:0}.vue-slider-ltr .vue-slider-mark-label{left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.vue-slider-rtl .vue-slider-mark{-webkit-transform:translate(50%,-50%);transform:translate(50%,-50%)}.vue-slider-rtl .vue-slider-mark-step{right:0}.vue-slider-rtl .vue-slider-mark-label{right:50%;-webkit-transform:translateX(50%);transform:translateX(50%)}.vue-slider-btt .vue-slider-mark,.vue-slider-ttb .vue-slider-mark{width:100%;height:0;left:50%}.vue-slider-btt .vue-slider-mark-step,.vue-slider-ttb .vue-slider-mark-step{left:0}.vue-slider-btt .vue-slider-mark-label,.vue-slider-ttb .vue-slider-mark-label{left:100%;margin-left:10px}.vue-slider-btt .vue-slider-mark{-webkit-transform:translate(-50%,50%);transform:translate(-50%,50%)}.vue-slider-btt .vue-slider-mark-step{top:0}.vue-slider-btt .vue-slider-mark-label{top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.vue-slider-ttb .vue-slider-mark{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.vue-slider-ttb .vue-slider-mark-step{bottom:0}.vue-slider-ttb .vue-slider-mark-label{bottom:50%;-webkit-transform:translateY(50%);transform:translateY(50%)}.vue-slider-mark-label,.vue-slider-mark-step{position:absolute}",""])},df80:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider{position:relative;-webkit-box-sizing:content-box;box-sizing:content-box;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:block;-ms-touch-action:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.vue-slider-disabled{pointer-events:none}.vue-slider-rail{position:relative;width:100%;height:100%;-webkit-transition-property:width,height,left,right,top,bottom;transition-property:width,height,left,right,top,bottom}.vue-slider-process{position:absolute;z-index:1}.vue-slider-sr-only{clip:rect(1px,1px,1px,1px);height:1px;width:1px;overflow:hidden;position:absolute!important}",""])},fb15:function(t,e,r){"use strict";var n;(r.r(e),"undefined"!==typeof window)&&((n=window.document.currentScript)&&(n=n.src.match(/(.+\/)[^\/]+\.js(\?.*)?$/))&&(r.p=n[1]));function o(t,e,r,n){var o,i=arguments.length,a=i<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,r):n;if("object"===typeof Reflect&&"function"===typeof Reflect.decorate)a=Reflect.decorate(t,e,r,n);else for(var s=t.length-1;s>=0;s--)(o=t[s])&&(a=(i<3?o(a):i>3?o(e,r,a):o(e,r))||a);return i>3&&a&&Object.defineProperty(e,r,a),a}var i=r("8bbf"),a=r.n(i),s=r("65d9"),u=r.n(s);function l(t,e){return void 0===e&&(e={}),Object(s["createDecorator"])(function(r,n){(r.props||(r.props={}))[n]=e,r.model={prop:n,event:t||n}})}function c(t){return void 0===t&&(t={}),Object(s["createDecorator"])(function(e,r){(e.props||(e.props={}))[r]=t})}function d(t,e){void 0===e&&(e={});var r=e.deep,n=void 0!==r&&r,o=e.immediate,i=void 0!==o&&o;return Object(s["createDecorator"])(function(e,r){"object"!==typeof e.watch&&(e.watch=Object.create(null));var o=e.watch;"object"!==typeof o[t]||Array.isArray(o[t])?"undefined"===typeof o[t]&&(o[t]=[]):o[t]=[o[t]],o[t].push({handler:r,deep:n,immediate:i})})}r("4ed8");function f(t){return f="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},f(t)}function p(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function h(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function v(t,e,r){return e&&h(t.prototype,e),r&&h(t,r),t}function y(t,e){return!e||"object"!==f(e)&&"function"!==typeof e?m(t):e}function m(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function b(t){return b=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},b(t)}function g(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&k(t,e)}function k(t,e){return k=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},k(t,e)}var w=function(t){function e(){return p(this,e),y(this,b(e).apply(this,arguments))}return g(e,t),v(e,[{key:"dragStart",value:function(t){if(this.disabled)return!1;this.$emit("drag-start")}},{key:"render",value:function(){var t=arguments[0];return t("div",{ref:"dot",class:this.dotClasses,on:{mousedown:this.dragStart,touchstart:this.dragStart}},[this.$slots.dot||t("div",{class:this.handleClasses,style:this.dotStyle}),"none"!==this.tooltip?t("div",{class:this.tooltipClasses},[this.$slots.tooltip||t("div",{class:this.tooltipInnerClasses,style:this.tooltipStyle},[t("span",{class:"vue-slider-dot-tooltip-text"},[this.tooltipValue])])]):null])}},{key:"dotClasses",get:function(){return["vue-slider-dot",{"vue-slider-dot-disabled":this.disabled,"vue-slider-dot-focus":this.focus}]}},{key:"handleClasses",get:function(){return["vue-slider-dot-handle",{"vue-slider-dot-handle-disabled":this.disabled,"vue-slider-dot-handle-focus":this.focus}]}},{key:"tooltipClasses",get:function(){return["vue-slider-dot-tooltip",["vue-slider-dot-tooltip-".concat(this.tooltipPlacement)],{"vue-slider-dot-tooltip-show":this.showTooltip}]}},{key:"tooltipInnerClasses",get:function(){return["vue-slider-dot-tooltip-inner",["vue-slider-dot-tooltip-inner-".concat(this.tooltipPlacement)],{"vue-slider-dot-tooltip-inner-disabled":this.disabled,"vue-slider-dot-tooltip-inner-focus":this.focus}]}},{key:"showTooltip",get:function(){switch(this.tooltip){case"always":return!0;case"none":return!1;case"focus":return!!this.focus;default:return!1}}},{key:"tooltipValue",get:function(){return this.tooltipFormatter?"string"===typeof this.tooltipFormatter?this.tooltipFormatter.replace(/\{value\}/,String(this.value)):this.tooltipFormatter(this.value):this.value}}]),e}(a.a);o([c({default:0})],w.prototype,"value",void 0),o([c()],w.prototype,"tooltip",void 0),o([c()],w.prototype,"dotStyle",void 0),o([c()],w.prototype,"tooltipStyle",void 0),o([c({type:String,validator:function(t){return["top","right","bottom","left"].includes(t)},required:!0})],w.prototype,"tooltipPlacement",void 0),o([c({type:[String,Function]})],w.prototype,"tooltipFormatter",void 0),o([c({type:Boolean,default:!1})],w.prototype,"focus",void 0),o([c({default:!1})],w.prototype,"disabled",void 0),w=o([u.a],w);var x=w;r("556c");function P(t){return P="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},P(t)}function S(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function O(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function E(t,e,r){return e&&O(t.prototype,e),r&&O(t,r),t}function R(t,e){return!e||"object"!==P(e)&&"function"!==typeof e?D(t):e}function D(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function A(t){return A=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},A(t)}function j(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&_(t,e)}function _(t,e){return _=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},_(t,e)}var M=function(t){function e(){return S(this,e),R(this,A(e).apply(this,arguments))}return j(e,t),E(e,[{key:"labelClickHandle",value:function(t){t.stopPropagation(),this.$emit("pressLabel",this.mark.pos)}},{key:"render",value:function(){var t=arguments[0],e=this.mark;return t("div",{class:this.marksClasses},[this.$slots.step||t("div",{class:this.stepClasses,style:[this.stepStyle,e.style,e.active?this.stepActiveStyle:null,e.active?e.activeStyle:null]}),this.hideLabel?null:this.$slots.label||t("div",{class:this.labelClasses,style:[this.labelStyle,e.labelStyle,e.active?this.labelActiveStyle:null,e.active?e.labelActiveStyle:null],on:{click:this.labelClickHandle}},[e.label])])}},{key:"marksClasses",get:function(){return["vue-slider-mark",{"vue-slider-mark-active":this.mark.active}]}},{key:"stepClasses",get:function(){return["vue-slider-mark-step",{"vue-slider-mark-step-active":this.mark.active}]}},{key:"labelClasses",get:function(){return["vue-slider-mark-label",{"vue-slider-mark-label-active":this.mark.active}]}}]),e}(a.a);o([c({required:!0})],M.prototype,"mark",void 0),o([c(Boolean)],M.prototype,"hideLabel",void 0),o([c()],M.prototype,"stepStyle",void 0),o([c()],M.prototype,"stepActiveStyle",void 0),o([c()],M.prototype,"labelStyle",void 0),o([c()],M.prototype,"labelActiveStyle",void 0),M=o([u.a],M);var C,V=M,N=function(t){return"number"===typeof t?"".concat(t,"px"):t},T=function(t,e,r){var n=t instanceof MouseEvent?t:t.targetTouches[0],o=e.getBoundingClientRect(),i={x:n.pageX-o.left,y:n.pageY-o.top};return{x:r?e.offsetWidth-i.x:i.x,y:r?e.offsetHeight-i.y:i.y}};(function(t){t[t["PAGE_UP"]=33]="PAGE_UP",t[t["PAGE_DOWN"]=34]="PAGE_DOWN",t[t["END"]=35]="END",t[t["HOME"]=36]="HOME",t[t["LEFT"]=37]="LEFT",t[t["UP"]=38]="UP",t[t["RIGHT"]=39]="RIGHT",t[t["DOWN"]=40]="DOWN"})(C||(C={}));var B=function(t,e){switch(t.keyCode){case C.UP:return function(t){return"ttb"===e.direction?t-1:t+1};case C.RIGHT:return function(t){return"rtl"===e.direction?t-1:t+1};case C.DOWN:return function(t){return"ttb"===e.direction?t+1:t-1};case C.LEFT:return function(t){return"rtl"===e.direction?t+1:t-1};case C.END:return function(){return e.max};case C.HOME:return function(){return e.min};case C.PAGE_UP:return function(t){return t+10};case C.PAGE_DOWN:return function(t){return t-10};default:return null}};function I(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function L(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function z(t,e,r){return e&&L(t.prototype,e),r&&L(t,r),t}var H,F,$=function(){function t(e){I(this,t),this.num=e}return z(t,[{key:"decimal",value:function(t,e,r){var n=this.num,o="".concat(n).split(".")[1]||"",i="".concat(t).split(".")[1]||"",a=o.length>i.length?o:i,s=a?Math.pow(10,a.length):1,u=Math.round(n*s),l=Math.round(t*s),c=0;switch(e){case"+":c=u+l;break;case"-":c=u-l;break;case"*":c=u*l,s*=s;break;case"/":c=u/l,s=1;break;case"%":c=u%l,s=1;break}return this.num=c/s,this}},{key:"plus",value:function(t){return this.decimal(t,"+")}},{key:"minus",value:function(t){return this.decimal(t,"-")}},{key:"multiply",value:function(t){return this.decimal(t,"*")}},{key:"divide",value:function(t){return this.decimal(t,"/")}},{key:"remainder",value:function(t){return this.decimal(t,"%")}},{key:"toNumber",value:function(){return this.num}}]),t}();function U(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"===typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){rt(t,e,r[e])})}return t}function G(t,e){return K(t)||X(t,e)||W()}function W(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function X(t,e){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=t[Symbol.iterator]();!(n=(a=s.next()).done);n=!0)if(r.push(a.value),e&&r.length===e)break}catch(u){o=!0,i=u}finally{try{n||null==s["return"]||s["return"]()}finally{if(o)throw i}}return r}function K(t){if(Array.isArray(t))return t}function Y(t){return Q(t)||J(t)||q()}function q(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function J(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}function Q(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function Z(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function tt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function et(t,e,r){return e&&tt(t.prototype,e),r&&tt(t,r),t}function rt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}(function(t){t[t["VALUE"]=1]="VALUE",t[t["INTERVAL"]=2]="INTERVAL",t[t["MIN"]=3]="MIN",t[t["MAX"]=4]="MAX",t[t["ORDER"]=5]="ORDER"})(F||(F={}));var nt=(H={},rt(H,F.VALUE,'The type of the "value" is illegal'),rt(H,F.INTERVAL,'The prop "interval" is invalid, "(max - min)" cannot be divisible by "interval"'),rt(H,F.MIN,'The "value" cannot be less than the minimum.'),rt(H,F.MAX,'The "value" cannot be greater than the maximum.'),rt(H,F.ORDER,'When "order" is false, the parameters "minRange", "maxRange", "fixed", "enabled" are invalid.'),H),ot=function(){function t(e){Z(this,t),this.dotsPos=[],this.dotsValue=[],this.data=e.data,this.max=e.max,this.min=e.min,this.interval=e.interval,this.order=e.order,this.marks=e.marks,this.process=e.process,this.onError=e.onError,this.order?(this.minRange=e.minRange||0,this.maxRange=e.maxRange||0,this.enableCross=e.enableCross,this.fixed=e.fixed):((e.minRange||e.maxRange||!e.enableCross||e.fixed)&&this.emitError(F.ORDER),this.minRange=0,this.maxRange=0,this.enableCross=!0,this.fixed=!1),this.setValue(e.value)}return et(t,[{key:"setValue",value:function(t){this.dotsValue=Array.isArray(t)?Y(t):[t],this.syncDotsPos()}},{key:"setDotsPos",value:function(t){var e=this,r=this.order?Y(t).sort(function(t,e){return t-e}):t;this.dotsPos=r,this.dotsValue=r.map(function(t){return e.parsePos(t)})}},{key:"syncDotsPos",value:function(){var t=this;this.dotsPos=this.dotsValue.map(function(e){return t.parseValue(e)})}},{key:"getRecentDot",value:function(t){var e=this.dotsPos.map(function(e){return Math.abs(e-t)});return e.indexOf(Math.min.apply(Math,Y(e)))}},{key:"getIndexByValue",value:function(t){return this.data?this.data.indexOf(t):new $(+t).minus(this.min).divide(this.interval).toNumber()}},{key:"getValueByIndex",value:function(t){return t<0?t=0:t>this.total&&(t=this.total),this.data?this.data[t]:new $(t).multiply(this.interval).plus(this.min).toNumber()}},{key:"setDotPos",value:function(t,e){t=this.getValidPos(t,e).pos;var r=t-this.dotsPos[e];if(r){var n=new Array(this.dotsPos.length);this.fixed?n=this.getFixedChangePosArr(r,e):this.minRange||this.maxRange?n=this.getLimitRangeChangePosArr(t,r,e):n[e]=r,this.setDotsPos(this.dotsPos.map(function(t,e){return t+(n[e]||0)}))}}},{key:"getFixedChangePosArr",value:function(t,e){var r=this;return this.dotsPos.forEach(function(n,o){if(o!==e){var i=r.getValidPos(n+t,o),a=i.pos,s=i.inRange;s||(t=Math.min(Math.abs(a-n),Math.abs(t))*(t<0?-1:1))}}),this.dotsPos.map(function(e){return t})}},{key:"getLimitRangeChangePosArr",value:function(t,e,r){var n=this,o=[{index:r,changePos:e}],i=e;return[this.minRange,this.maxRange].forEach(function(a,s){if(!a)return!1;var u=0===s,l=e>0,c=0;c=u?l?1:-1:l?-1:1;var d=function(t,e){var r=Math.abs(t-e);return u?r<n.minRangeDir:r>n.maxRangeDir},f=r+c,p=n.dotsPos[f],h=t;while(n.isPos(p)&&d(p,h)){var v=n.getValidPos(p+i,f),y=v.pos;o.push({index:f,changePos:y-p}),f+=c,h=y,p=n.dotsPos[f]}}),this.dotsPos.map(function(t,e){var r=o.filter(function(t){return t.index===e});return r.length?r[0].changePos:0})}},{key:"isPos",value:function(t){return"number"===typeof t}},{key:"getValidPos",value:function(t,e){var r=this.valuePosRange[e],n=!0;return t<r[0]?(t=r[0],n=!1):t>r[1]&&(t=r[1],n=!1),{pos:t,inRange:n}}},{key:"parseValue",value:function(t){if(this.data)t=this.data.indexOf(t);else if("number"===typeof t||"string"===typeof t){if(t=+t,t<this.min)return this.emitError(F.MIN),0;if(t>this.max)return this.emitError(F.MAX),0;if("number"!==typeof t||t!==t)return this.emitError(F.VALUE),0;t=new $(t).minus(this.min).divide(this.interval).toNumber()}var e=new $(t).multiply(this.gap).toNumber();return e<0?0:e>100?100:e}},{key:"parsePos",value:function(t){var e=Math.round(t/this.gap);return this.getValueByIndex(e)}},{key:"isActiveByPos",value:function(t){return this.processArray.some(function(e){var r=G(e,2),n=r[0],o=r[1];return t>=n&&t<=o})}},{key:"getValues",value:function(){var t=this;return this.data?this.data:Array.from(new Array(this.total),function(e,r){return new $(r).multiply(t.interval).plus(t.min).toNumber()}).concat([this.max])}},{key:"emitError",value:function(t){this.onError&&this.onError(t,nt[t])}},{key:"markList",get:function(){var t=this;if(!this.marks)return[];var e=function(e,r){var n=t.parseValue(e);return U({pos:n,value:"string"===typeof e?parseFloat(e):e,label:e,active:t.isActiveByPos(n)},r)};return!0===this.marks?this.getValues().map(function(t){return e(t)}):"[object Object]"===Object.prototype.toString.call(this.marks)?Object.keys(this.marks).sort(function(t,e){return+t-+e}).map(function(r){var n=t.marks[r];return e(r,"string"!==typeof n?n:{label:n})}):Array.isArray(this.marks)?this.marks.map(function(t){return e(t)}):"function"===typeof this.marks?this.getValues().map(function(e){return{value:e,result:t.marks(e)}}).filter(function(t){var e=t.result;return!!e}).map(function(t){var r=t.value,n=t.result;return e(r,n)}):[]}},{key:"processArray",get:function(){if(this.process){if("function"===typeof this.process)return this.process(this.dotsPos);if(1===this.dotsPos.length)return[[0,this.dotsPos[0]]];if(this.dotsPos.length>1)return[[Math.min.apply(Math,Y(this.dotsPos)),Math.max.apply(Math,Y(this.dotsPos))]]}return[]}},{key:"total",get:function(){var t=0;return t=this.data?this.data.length-1:new $(this.max).minus(this.min).divide(this.interval).toNumber(),t-Math.floor(t)!==0?(this.emitError(F.INTERVAL),0):t}},{key:"gap",get:function(){return 100/this.total}},{key:"minRangeDir",get:function(){return this.minRange?this.minRange*this.gap:0}},{key:"maxRangeDir",get:function(){return this.maxRange?this.maxRange*this.gap:100}},{key:"valuePosRange",get:function(){var t=this,e=this.dotsPos,r=[];return e.forEach(function(n,o){r.push([Math.max(t.minRange?t.minRangeDir*o:0,t.enableCross?0:e[o-1]||0),Math.min(t.minRange?100-t.minRangeDir*(e.length-1-o):100,t.enableCross?100:e[o+1]||100)])}),r}},{key:"dotsIndex",get:function(){var t=this;return this.dotsValue.map(function(e){return t.getIndexByValue(e)})}}]),t}();function it(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function at(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function st(t,e,r){return e&&at(t.prototype,e),r&&at(t,r),t}var ut=function(){function t(e){it(this,t),this.states=0,this.map=e}return st(t,[{key:"add",value:function(t){this.states|=t}},{key:"delete",value:function(t){this.states&=~t}},{key:"toggle",value:function(t){this.has(t)?this.delete(t):this.add(t)}},{key:"has",value:function(t){return!!(this.states&t)}}]),t}();r("4abb");function lt(t){return lt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lt(t)}function ct(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"===typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){vt(t,e,r[e])})}return t}function dt(t,e){return ht(t)||pt(t,e)||ft()}function ft(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function pt(t,e){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=t[Symbol.iterator]();!(n=(a=s.next()).done);n=!0)if(r.push(a.value),e&&r.length===e)break}catch(u){o=!0,i=u}finally{try{n||null==s["return"]||s["return"]()}finally{if(o)throw i}}return r}function ht(t){if(Array.isArray(t))return t}function vt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function yt(t){return gt(t)||bt(t)||mt()}function mt(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function bt(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}function gt(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function kt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function wt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function xt(t,e,r){return e&&wt(t.prototype,e),r&&wt(t,r),t}function Pt(t,e){return!e||"object"!==lt(e)&&"function"!==typeof e?St(t):e}function St(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Ot(t){return Ot=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ot(t)}function Et(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Rt(t,e)}function Rt(t,e){return Rt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Rt(t,e)}var Dt={None:0,Drag:1,Focus:2},At=4,jt=function(t){function e(){var t;return kt(this,e),t=Pt(this,Ot(e).apply(this,arguments)),t.states=new ut(Dt),t.scale=1,t.focusDotIndex=0,t}return Et(e,t),xt(e,[{key:"onValueChanged",value:function(){!this.states.has(Dt.Drag)&&this.isNotSync&&this.control.setValue(this.value)}},{key:"created",value:function(){this.initControl()}},{key:"mounted",value:function(){this.bindEvent()}},{key:"beforeDestroy",value:function(){this.unbindEvent()}},{key:"bindEvent",value:function(){document.addEventListener("touchmove",this.dragMove,{passive:!1}),document.addEventListener("touchend",this.dragEnd,{passive:!1}),document.addEventListener("mousedown",this.blurHandle),document.addEventListener("mousemove",this.dragMove),document.addEventListener("mouseup",this.dragEnd),document.addEventListener("mouseleave",this.dragEnd),document.addEventListener("keydown",this.keydownHandle)}},{key:"unbindEvent",value:function(){document.removeEventListener("touchmove",this.dragMove),document.removeEventListener("touchend",this.dragEnd),document.removeEventListener("mousemove",this.dragMove),document.removeEventListener("mouseup",this.dragEnd),document.removeEventListener("mouseleave",this.dragEnd),document.removeEventListener("keydown",this.keydownHandle)}},{key:"setScale",value:function(){this.scale=new $(Math.floor(this.isHorizontal?this.$el.offsetWidth:this.$el.offsetHeight)).divide(100).toNumber()}},{key:"initControl",value:function(){var t=this;this.control=new ot({value:this.value,data:this.data,enableCross:this.enableCross,fixed:this.fixed,max:this.max,min:this.min,interval:this.interval,minRange:this.minRange,maxRange:this.maxRange,order:this.order,marks:this.marks,process:this.process,onError:this.emitError}),["data","enableCross","fixed","max","min","interval","minRange","maxRange","order","marks","process"].forEach(function(e){t.$watch(e,function(r){if("data"===e&&Array.isArray(t.control.data)&&Array.isArray(r)&&t.control.data.length===r.length&&r.every(function(e,r){return e===t.control.data[r]}))return!1;t.control[e]=r,["data","max","min","interval"].includes(e)&&t.control.syncDotsPos()})})}},{key:"isDisabledByDotIndex",value:function(t){return this.dots[t].disabled}},{key:"syncValueByPos",value:function(){var t=this,e=this.control.dotsValue;if(this.included&&this.control.markList.length>0){var r=function(e){var r=e,n=t.max-t.min;return t.control.markList.forEach(function(t){if("number"===typeof t.value&&"number"===typeof e){var o=Math.abs(t.value-e);o<n&&(n=o,r=t.value)}}),r};e=e.map(function(t){return r(t)})}this.isDiff(e,Array.isArray(this.value)?this.value:[this.value])&&this.$emit("change",1===e.length?e[0]:yt(e))}},{key:"isDiff",value:function(t,e){return t.length!==e.length||t.some(function(t,r){return t!==e[r]})}},{key:"emitError",value:function(t,e){this.$emit("error",t,e)}},{key:"dragStart",value:function(t){this.focusDotIndex=t,this.setScale(),this.states.add(Dt.Drag),this.states.add(Dt.Focus),this.$emit("drag-start")}},{key:"dragMove",value:function(t){if(!this.states.has(Dt.Drag))return!1;t.preventDefault();var e=this.getPosByEvent(t);this.isCrossDot(e),this.control.setDotPos(e,this.focusDotIndex),this.lazy||this.syncValueByPos();var r=this.control.dotsValue;this.$emit("dragging",1===r.length?r[0]:yt(r))}},{key:"isCrossDot",value:function(t){if(this.canSort){var e=this.focusDotIndex,r=t;r>this.dragRange[1]?(r=this.dragRange[1],this.focusDotIndex++):r<this.dragRange[0]&&(r=this.dragRange[0],this.focusDotIndex--),e!==this.focusDotIndex&&this.control.setDotPos(r,e)}}},{key:"dragEnd",value:function(){var t=this;if(!this.states.has(Dt.Drag))return!1;this.lazy&&this.syncValueByPos(),setTimeout(function(){t.included&&t.isNotSync?t.control.setValue(t.value):t.control.syncDotsPos(),t.states.delete(Dt.Drag),t.useKeyboard||t.states.delete(Dt.Focus),t.$emit("drag-end")})}},{key:"blurHandle",value:function(t){if(!this.states.has(Dt.Focus)||!this.$refs.container||this.$refs.container.contains(t.target))return!1;this.states.delete(Dt.Focus)}},{key:"clickHandle",value:function(t){if(!this.clickable)return!1;if(!this.states.has(Dt.Drag)){this.setScale();var e=this.getPosByEvent(t);this.setValueByPos(e)}}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.states.add(Dt.Focus),this.focusDotIndex=t}},{key:"blur",value:function(){this.states.delete(Dt.Focus)}},{key:"getValue",value:function(){var t=this.control.dotsValue;return 1===t.length?t[0]:t}},{key:"getIndex",value:function(){var t=this.control.dotsIndex;return 1===t.length?t[0]:t}},{key:"setValueByPos",value:function(t){var e=this,r=this.control.getRecentDot(t);if(this.isDisabledByDotIndex(r))return!1;this.focusDotIndex=r,this.control.setDotPos(t,r),this.syncValueByPos(),this.useKeyboard&&this.states.add(Dt.Focus),setTimeout(function(){e.included&&e.isNotSync?e.control.setValue(e.value):e.control.syncDotsPos()})}},{key:"keydownHandle",value:function(t){if(!this.useKeyboard||!this.states.has(Dt.Focus))return!1;var e=B(t,{direction:this.direction,max:this.control.total,min:0});if(e){t.preventDefault();var r=this.control.getIndexByValue(this.control.dotsValue[this.focusDotIndex]),n=e(r),o=this.control.parseValue(this.control.getValueByIndex(n));this.isCrossDot(o),this.control.setDotPos(o,this.focusDotIndex),this.syncValueByPos()}}},{key:"getPosByEvent",value:function(t){return T(t,this.$el,this.isReverse)[this.isHorizontal?"x":"y"]/this.scale}},{key:"renderSlot",value:function(t,e,r,n){var o=this.$createElement,i=this.$scopedSlots[t];return i?n?i(e):o("template",{slot:t},[i(e)]):r}},{key:"render",value:function(){var t=this,e=arguments[0];return e("div",{ref:"container",class:this.containerClasses,style:this.containerStyles,attrs:{"aria-hidden":!0},on:{click:this.clickHandle}},[e("div",{class:"vue-slider-rail",style:this.railStyle},[this.processBaseStyleArray.map(function(r,n){return e("div",{class:"vue-slider-process",key:"process-".concat(n),style:[r,t.processStyle]})}),this.marks?e("div",{class:"vue-slider-marks"},[this.control.markList.map(function(r){var n;return t.renderSlot("mark",r,e("vue-slider-mark",{attrs:{mark:r,hideLabel:t.hideLabel,stepStyle:t.stepStyle,stepActiveStyle:t.stepActiveStyle,labelStyle:t.labelStyle,labelActiveStyle:t.labelActiveStyle},style:(n={},vt(n,t.isHorizontal?"height":"width","100%"),vt(n,t.isHorizontal?"width":"height","".concat(t.tailSize,"px")),vt(n,t.mainDirection,"".concat(r.pos,"%")),n),on:{pressLabel:function(e){return t.setValueByPos(e)}}},[t.renderSlot("step",r,null),t.renderSlot("label",r,null)]),!0)})]):null,this.dots.map(function(r,n){var o;return e("vue-slider-dot",{ref:"dot-".concat(n),key:"dot-".concat(n),attrs:{value:r.value,disabled:r.disabled,focus:r.focus,"dot-style":[r.style,r.disabled?r.disabledStyle:null,r.focus?r.focusStyle:null],tooltip:r.tooltip||t.tooltip,"tooltip-style":[t.tooltipStyle,r.tooltipStyle,r.disabled?r.tooltipDisabledStyle:null,r.focus?r.tooltipFocusStyle:null],"tooltip-formatter":t.tooltipFormatter,"tooltip-placement":t.tooltipDirections[n]},style:[t.dotBaseStyle,(o={},vt(o,t.mainDirection,"".concat(r.pos,"%")),vt(o,"transition","".concat(t.mainDirection," ").concat(t.animateTime,"s")),o)],on:{"drag-start":function(){return t.dragStart(n)}}},[t.renderSlot("dot",r,null),t.renderSlot("tooltip",r,null)])})]),1!==this.dots.length||this.data?null:e("input",{class:"vue-slider-sr-only",attrs:{type:"range",min:this.min,max:this.max},domProps:{value:this.value}})])}},{key:"tailSize",get:function(){return(this.isHorizontal?this.height:this.width)||At}},{key:"containerClasses",get:function(){return["vue-slider",["vue-slider-".concat(this.direction)],{"vue-slider-disabled":this.disabled}]}},{key:"containerStyles",get:function(){var t=Array.isArray(this.dotSize)?this.dotSize:[this.dotSize,this.dotSize],e=dt(t,2),r=e[0],n=e[1],o=this.width?N(this.width):this.isHorizontal?"auto":N(At),i=this.height?N(this.height):this.isHorizontal?N(At):"auto";return{padding:"".concat(n/2,"px ").concat(r/2,"px"),width:o,height:i}}},{key:"processBaseStyleArray",get:function(){var t=this;return this.control.processArray.map(function(e){var r,n=dt(e,3),o=n[0],i=n[1],a=n[2];if(o>i){var s=[i,o];o=s[0],i=s[1]}var u=t.isHorizontal?"width":"height";return ct((r={},vt(r,t.isHorizontal?"height":"width","100%"),vt(r,t.isHorizontal?"top":"left",0),vt(r,t.mainDirection,"".concat(o,"%")),vt(r,u,"".concat(i-o,"%")),vt(r,"transitionProperty","".concat(u,",").concat(t.mainDirection)),vt(r,"transitionDuration","".concat(t.animateTime,"s")),r),a)})}},{key:"dotBaseStyle",get:function(){var t,e,r,n=Array.isArray(this.dotSize)?this.dotSize:[this.dotSize,this.dotSize],o=dt(n,2),i=o[0],a=o[1];this.isHorizontal?(e={marginTop:"-".concat((a-this.tailSize)/2,"px")},vt(e,"ltr"===this.direction?"marginLeft":"marginRight","-".concat(i/2,"px")),vt(e,"top","0"),vt(e,"ltr"===this.direction?"left":"right","0"),t=e):(r={marginLeft:"-".concat((i-this.tailSize)/2,"px")},vt(r,"btt"===this.direction?"marginBottom":"marginTop","-".concat(a/2,"px")),vt(r,"left","0"),vt(r,"btt"===this.direction?"bottom":"top","0"),t=r);return ct({width:"".concat(i,"px"),height:"".concat(a,"px")},t)}},{key:"mainDirection",get:function(){switch(this.direction){case"ltr":return"left";case"rtl":return"right";case"btt":return"bottom";case"ttb":return"top"}}},{key:"isHorizontal",get:function(){return"ltr"===this.direction||"rtl"===this.direction}},{key:"isReverse",get:function(){return"rtl"===this.direction||"btt"===this.direction}},{key:"tooltipDirections",get:function(){var t=this.tooltipPlacement||(this.isHorizontal?"top":"left");return Array.isArray(t)?t:Array.from(new Array(this.dots.length),function(){return t})}},{key:"dots",get:function(){var t=this;return this.control.dotsPos.map(function(e,r){return ct({pos:e,index:r,value:t.control.dotsValue[r],focus:t.states.has(Dt.Focus)&&t.focusDotIndex===r,disabled:!1,style:t.dotStyle},(Array.isArray(t.dotOptions)?t.dotOptions[r]:t.dotOptions)||{})})}},{key:"animateTime",get:function(){return this.states.has(Dt.Drag)?0:this.duration}},{key:"canSort",get:function(){return this.order&&!this.minRange&&!this.maxRange&&!this.fixed&&this.enableCross}},{key:"isNotSync",get:function(){var t=this.control.dotsValue;return Array.isArray(this.value)?this.value.length!==t.length||this.value.some(function(e,r){return e!==t[r]}):this.value!==t[0]}},{key:"dragRange",get:function(){var t=this.dots[this.focusDotIndex-1],e=this.dots[this.focusDotIndex+1];return[t?t.pos:-1/0,e?e.pos:1/0]}}]),e}(a.a);o([l("change",{default:0})],jt.prototype,"value",void 0),o([c({default:"ltr",validator:function(t){return["ltr","rtl","ttb","btt"].indexOf(t)>-1}})],jt.prototype,"direction",void 0),o([c(Number)],jt.prototype,"width",void 0),o([c(Number)],jt.prototype,"height",void 0),o([c({default:14})],jt.prototype,"dotSize",void 0),o([c({type:Number,default:0})],jt.prototype,"min",void 0),o([c({type:Number,default:100})],jt.prototype,"max",void 0),o([c({type:Number,default:1})],jt.prototype,"interval",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"disabled",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"clickable",void 0),o([c({type:Number,default:.5})],jt.prototype,"duration",void 0),o([c(Array)],jt.prototype,"data",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"lazy",void 0),o([c({type:String,validator:function(t){return["none","always","focus"].includes(t)},default:"focus"})],jt.prototype,"tooltip",void 0),o([c({type:String,validator:function(t){return["top","right","bottom","left"].includes(t)}})],jt.prototype,"tooltipPlacement",void 0),o([c({type:[String,Function]})],jt.prototype,"tooltipFormatter",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"useKeyboard",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"enableCross",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"fixed",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"order",void 0),o([c(Number)],jt.prototype,"minRange",void 0),o([c(Number)],jt.prototype,"maxRange",void 0),o([c({type:[Boolean,Object,Array,Function],default:!1})],jt.prototype,"marks",void 0),o([c({type:[Boolean,Function],default:!0})],jt.prototype,"process",void 0),o([c(Boolean)],jt.prototype,"included",void 0),o([c(Boolean)],jt.prototype,"hideLabel",void 0),o([c()],jt.prototype,"dotOptions",void 0),o([c()],jt.prototype,"railStyle",void 0),o([c()],jt.prototype,"processStyle",void 0),o([c()],jt.prototype,"dotStyle",void 0),o([c()],jt.prototype,"tooltipStyle",void 0),o([c()],jt.prototype,"stepStyle",void 0),o([c()],jt.prototype,"stepActiveStyle",void 0),o([c()],jt.prototype,"labelStyle",void 0),o([c()],jt.prototype,"labelActiveStyle",void 0),o([d("value")],jt.prototype,"onValueChanged",null),jt=o([u()({data:function(){return{control:null}},components:{VueSliderDot:x,VueSliderMark:V},inheritAttrs:!1})],jt);var _t=jt,Mt=_t;r.d(e,"ERROR_TYPE",function(){return F});e["default"]=Mt}})["default"]}); | ||
*/function n(t){return t&&"object"===typeof t&&"default"in t?t["default"]:t}Object.defineProperty(e,"__esModule",{value:!0});var o=n(r("8bbf"));function i(){return void 0!==(Reflect&&Reflect.defineMetadata)}function s(t,e){a(t,e),Object.getOwnPropertyNames(e.prototype).forEach(function(r){a(t.prototype,e.prototype,r)}),Object.getOwnPropertyNames(e).forEach(function(r){a(t,e,r)})}function a(t,e,r){var n=r?Reflect.getOwnMetadataKeys(e,r):Reflect.getOwnMetadataKeys(e);n.forEach(function(n){var o=r?Reflect.getOwnMetadata(n,e,r):Reflect.getOwnMetadata(n,e);r?Reflect.defineMetadata(n,o,t,r):Reflect.defineMetadata(n,o,t)})}var u={__proto__:[]},l=u instanceof Array;function c(t){return function(e,r,n){var o="function"===typeof e?e:e.constructor;o.__decorators__||(o.__decorators__=[]),"number"!==typeof n&&(n=void 0),o.__decorators__.push(function(e){return t(e,r,n)})}}function d(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return o.extend({mixins:t})}function f(t){var e=typeof t;return null==t||"object"!==e&&"function"!==e}function h(t,e){var r=e.prototype._init;e.prototype._init=function(){var e=this,r=Object.getOwnPropertyNames(t);if(t.$options.props)for(var n in t.$options.props)t.hasOwnProperty(n)||r.push(n);r.forEach(function(r){"_"!==r.charAt(0)&&Object.defineProperty(e,r,{get:function(){return t[r]},set:function(e){t[r]=e},configurable:!0})})};var n=new e;e.prototype._init=r;var o={};return Object.keys(n).forEach(function(t){void 0!==n[t]&&(o[t]=n[t])}),o}var p=["data","beforeCreate","created","beforeMount","mounted","beforeDestroy","destroyed","beforeUpdate","updated","activated","deactivated","render","errorCaptured"];function v(t,e){void 0===e&&(e={}),e.name=e.name||t._componentTag||t.name;var r=t.prototype;Object.getOwnPropertyNames(r).forEach(function(t){if("constructor"!==t)if(p.indexOf(t)>-1)e[t]=r[t];else{var n=Object.getOwnPropertyDescriptor(r,t);void 0!==n.value?"function"===typeof n.value?(e.methods||(e.methods={}))[t]=n.value:(e.mixins||(e.mixins=[])).push({data:function(){var e;return e={},e[t]=n.value,e}}):(n.get||n.set)&&((e.computed||(e.computed={}))[t]={get:n.get,set:n.set})}}),(e.mixins||(e.mixins=[])).push({data:function(){return h(this,t)}});var n=t.__decorators__;n&&(n.forEach(function(t){return t(e)}),delete t.__decorators__);var a=Object.getPrototypeOf(t.prototype),u=a instanceof o?a.constructor:o,l=u.extend(e);return y(l,t,u),i()&&s(l,t),l}function y(t,e,r){Object.getOwnPropertyNames(e).forEach(function(n){if("prototype"!==n){var o=Object.getOwnPropertyDescriptor(t,n);if(!o||o.configurable){var i=Object.getOwnPropertyDescriptor(e,n);if(!l){if("cid"===n)return;var s=Object.getOwnPropertyDescriptor(r,n);if(!f(i.value)&&s&&s.value===i.value)return}0,Object.defineProperty(t,n,i)}}})}function m(t){return"function"===typeof t?v(t):function(e){return v(e,t)}}m.registerHooks=function(t){p.push.apply(p,t)},e.default=m,e.createDecorator=c,e.mixins=d},d5ac:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider-marks{position:relative;width:100%;height:100%}.vue-slider-mark{position:absolute;z-index:1}.vue-slider-ltr .vue-slider-mark,.vue-slider-rtl .vue-slider-mark{width:0;height:100%;top:50%}.vue-slider-ltr .vue-slider-mark-step,.vue-slider-rtl .vue-slider-mark-step{top:0}.vue-slider-ltr .vue-slider-mark-label,.vue-slider-rtl .vue-slider-mark-label{top:100%;margin-top:10px}.vue-slider-ltr .vue-slider-mark{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.vue-slider-ltr .vue-slider-mark-step{left:0}.vue-slider-ltr .vue-slider-mark-label{left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.vue-slider-rtl .vue-slider-mark{-webkit-transform:translate(50%,-50%);transform:translate(50%,-50%)}.vue-slider-rtl .vue-slider-mark-step{right:0}.vue-slider-rtl .vue-slider-mark-label{right:50%;-webkit-transform:translateX(50%);transform:translateX(50%)}.vue-slider-btt .vue-slider-mark,.vue-slider-ttb .vue-slider-mark{width:100%;height:0;left:50%}.vue-slider-btt .vue-slider-mark-step,.vue-slider-ttb .vue-slider-mark-step{left:0}.vue-slider-btt .vue-slider-mark-label,.vue-slider-ttb .vue-slider-mark-label{left:100%;margin-left:10px}.vue-slider-btt .vue-slider-mark{-webkit-transform:translate(-50%,50%);transform:translate(-50%,50%)}.vue-slider-btt .vue-slider-mark-step{top:0}.vue-slider-btt .vue-slider-mark-label{top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.vue-slider-ttb .vue-slider-mark{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.vue-slider-ttb .vue-slider-mark-step{bottom:0}.vue-slider-ttb .vue-slider-mark-label{bottom:50%;-webkit-transform:translateY(50%);transform:translateY(50%)}.vue-slider-mark-label,.vue-slider-mark-step{position:absolute}",""])},df80:function(t,e,r){e=t.exports=r("2350")(!1),e.push([t.i,".vue-slider{position:relative;-webkit-box-sizing:content-box;box-sizing:content-box;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:block;-ms-touch-action:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.vue-slider-disabled{pointer-events:none}.vue-slider-rail{position:relative;width:100%;height:100%;-webkit-transition-property:width,height,left,right,top,bottom;transition-property:width,height,left,right,top,bottom}.vue-slider-process{position:absolute;z-index:1}.vue-slider-sr-only{clip:rect(1px,1px,1px,1px);height:1px;width:1px;overflow:hidden;position:absolute!important}",""])},fb15:function(t,e,r){"use strict";var n;(r.r(e),"undefined"!==typeof window)&&((n=window.document.currentScript)&&(n=n.src.match(/(.+\/)[^\/]+\.js(\?.*)?$/))&&(r.p=n[1]));function o(t,e,r,n){var o,i=arguments.length,s=i<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,r):n;if("object"===typeof Reflect&&"function"===typeof Reflect.decorate)s=Reflect.decorate(t,e,r,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,r,s):o(e,r))||s);return i>3&&s&&Object.defineProperty(e,r,s),s}var i=r("8bbf"),s=r.n(i),a=r("c89a"),u=r.n(a);function l(t,e){return void 0===e&&(e={}),Object(a["createDecorator"])(function(r,n){(r.props||(r.props={}))[n]=e,r.model={prop:n,event:t||n}})}function c(t){return void 0===t&&(t={}),Object(a["createDecorator"])(function(e,r){(e.props||(e.props={}))[r]=t})}function d(t,e){void 0===e&&(e={});var r=e.deep,n=void 0!==r&&r,o=e.immediate,i=void 0!==o&&o;return Object(a["createDecorator"])(function(e,r){"object"!==typeof e.watch&&(e.watch=Object.create(null)),e.watch[t]={handler:r,deep:n,immediate:i}})}r("4ed8");function f(t){return f="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},f(t)}function h(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function p(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function v(t,e,r){return e&&p(t.prototype,e),r&&p(t,r),t}function y(t,e){return!e||"object"!==f(e)&&"function"!==typeof e?m(t):e}function m(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function b(t){return b=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},b(t)}function g(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&k(t,e)}function k(t,e){return k=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},k(t,e)}var w=function(t){function e(){return h(this,e),y(this,b(e).apply(this,arguments))}return g(e,t),v(e,[{key:"dragStart",value:function(t){if(this.disabled)return!1;this.$emit("drag-start")}},{key:"render",value:function(){var t=arguments[0];return t("div",{ref:"dot",class:this.dotClasses,on:{mousedown:this.dragStart,touchstart:this.dragStart}},[this.$slots.dot||t("div",{class:this.handleClasses,style:this.dotStyle}),"none"!==this.tooltip?t("div",{class:this.tooltipClasses},[this.$slots.tooltip||t("div",{class:this.tooltipInnerClasses,style:this.tooltipStyle},[t("span",{class:"vue-slider-dot-tooltip-text"},[this.tooltipValue])])]):null])}},{key:"dotClasses",get:function(){return["vue-slider-dot",{"vue-slider-dot-disabled":this.disabled,"vue-slider-dot-focus":this.focus}]}},{key:"handleClasses",get:function(){return["vue-slider-dot-handle",{"vue-slider-dot-handle-disabled":this.disabled,"vue-slider-dot-handle-focus":this.focus}]}},{key:"tooltipClasses",get:function(){return["vue-slider-dot-tooltip",["vue-slider-dot-tooltip-".concat(this.tooltipPlacement)],{"vue-slider-dot-tooltip-show":this.showTooltip}]}},{key:"tooltipInnerClasses",get:function(){return["vue-slider-dot-tooltip-inner",["vue-slider-dot-tooltip-inner-".concat(this.tooltipPlacement)],{"vue-slider-dot-tooltip-inner-disabled":this.disabled,"vue-slider-dot-tooltip-inner-focus":this.focus}]}},{key:"showTooltip",get:function(){switch(this.tooltip){case"always":return!0;case"none":return!1;case"focus":return!!this.focus;default:return!1}}},{key:"tooltipValue",get:function(){return this.tooltipFormatter?"string"===typeof this.tooltipFormatter?this.tooltipFormatter.replace(/\{value\}/,String(this.value)):this.tooltipFormatter(this.value):this.value}}]),e}(s.a);o([c({default:0})],w.prototype,"value",void 0),o([c()],w.prototype,"tooltip",void 0),o([c()],w.prototype,"dotStyle",void 0),o([c()],w.prototype,"tooltipStyle",void 0),o([c({type:String,validator:function(t){return["top","right","bottom","left"].includes(t)},required:!0})],w.prototype,"tooltipPlacement",void 0),o([c({type:[String,Function]})],w.prototype,"tooltipFormatter",void 0),o([c({type:Boolean,default:!1})],w.prototype,"focus",void 0),o([c({default:!1})],w.prototype,"disabled",void 0),w=o([u.a],w);var x=w;r("556c");function S(t){return S="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function P(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function O(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function E(t,e,r){return e&&O(t.prototype,e),r&&O(t,r),t}function R(t,e){return!e||"object"!==S(e)&&"function"!==typeof e?D(t):e}function D(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function A(t){return A=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},A(t)}function j(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&_(t,e)}function _(t,e){return _=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},_(t,e)}var M=function(t){function e(){return P(this,e),R(this,A(e).apply(this,arguments))}return j(e,t),E(e,[{key:"labelClickHandle",value:function(t){t.stopPropagation(),this.$emit("pressLabel",this.mark.pos)}},{key:"render",value:function(){var t=arguments[0],e=this.mark;return t("div",{class:this.marksClasses},[this.$slots.step||t("div",{class:this.stepClasses,style:[this.stepStyle,e.style,e.active?this.stepActiveStyle:null,e.active?e.activeStyle:null]}),this.hideLabel?null:this.$slots.label||t("div",{class:this.labelClasses,style:[this.labelStyle,e.labelStyle,e.active?this.labelActiveStyle:null,e.active?e.labelActiveStyle:null],on:{click:this.labelClickHandle}},[e.label])])}},{key:"marksClasses",get:function(){return["vue-slider-mark",{"vue-slider-mark-active":this.mark.active}]}},{key:"stepClasses",get:function(){return["vue-slider-mark-step",{"vue-slider-mark-step-active":this.mark.active}]}},{key:"labelClasses",get:function(){return["vue-slider-mark-label",{"vue-slider-mark-label-active":this.mark.active}]}}]),e}(s.a);o([c({required:!0})],M.prototype,"mark",void 0),o([c(Boolean)],M.prototype,"hideLabel",void 0),o([c()],M.prototype,"stepStyle",void 0),o([c()],M.prototype,"stepActiveStyle",void 0),o([c()],M.prototype,"labelStyle",void 0),o([c()],M.prototype,"labelActiveStyle",void 0),M=o([u.a],M);var C,V=M,N=function(t){return"number"===typeof t?"".concat(t,"px"):t},T=function(t,e,r){var n=t instanceof MouseEvent?t:t.targetTouches[0],o=e.getBoundingClientRect(),i={x:n.pageX-o.left,y:n.pageY-o.top};return{x:r?e.offsetWidth-i.x:i.x,y:r?e.offsetHeight-i.y:i.y}};(function(t){t[t["PAGE_UP"]=33]="PAGE_UP",t[t["PAGE_DOWN"]=34]="PAGE_DOWN",t[t["END"]=35]="END",t[t["HOME"]=36]="HOME",t[t["LEFT"]=37]="LEFT",t[t["UP"]=38]="UP",t[t["RIGHT"]=39]="RIGHT",t[t["DOWN"]=40]="DOWN"})(C||(C={}));var I=function(t,e){switch(t.keyCode){case C.UP:return function(t){return"ttb"===e.direction?t-1:t+1};case C.RIGHT:return function(t){return"rtl"===e.direction?t-1:t+1};case C.DOWN:return function(t){return"ttb"===e.direction?t+1:t-1};case C.LEFT:return function(t){return"rtl"===e.direction?t+1:t-1};case C.END:return function(){return e.max};case C.HOME:return function(){return e.min};case C.PAGE_UP:return function(t){return t+10};case C.PAGE_DOWN:return function(t){return t-10};default:return null}};function B(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function L(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function z(t,e,r){return e&&L(t.prototype,e),r&&L(t,r),t}var H,F,$=function(){function t(e){B(this,t),this.num=e}return z(t,[{key:"decimal",value:function(t,e,r){var n=this.num,o="".concat(n).split(".")[1]||"",i="".concat(t).split(".")[1]||"",s=o.length>i.length?o:i,a=s?Math.pow(10,s.length):1,u=Math.round(n*a),l=Math.round(t*a),c=0;switch(e){case"+":c=u+l;break;case"-":c=u-l;break;case"*":c=u*l,a*=a;break;case"/":c=u/l,a=1;break;case"%":c=u%l,a=1;break}return this.num=c/a,this}},{key:"plus",value:function(t){return this.decimal(t,"+")}},{key:"minus",value:function(t){return this.decimal(t,"-")}},{key:"multiply",value:function(t){return this.decimal(t,"*")}},{key:"divide",value:function(t){return this.decimal(t,"/")}},{key:"remainder",value:function(t){return this.decimal(t,"%")}},{key:"toNumber",value:function(){return this.num}}]),t}();function U(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"===typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){rt(t,e,r[e])})}return t}function W(t,e){return K(t)||X(t,e)||G()}function G(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function X(t,e){var r=[],n=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(n=(s=a.next()).done);n=!0)if(r.push(s.value),e&&r.length===e)break}catch(u){o=!0,i=u}finally{try{n||null==a["return"]||a["return"]()}finally{if(o)throw i}}return r}function K(t){if(Array.isArray(t))return t}function Y(t){return Q(t)||J(t)||q()}function q(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function J(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}function Q(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function Z(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function tt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function et(t,e,r){return e&&tt(t.prototype,e),r&&tt(t,r),t}function rt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}(function(t){t[t["VALUE"]=1]="VALUE",t[t["INTERVAL"]=2]="INTERVAL",t[t["MIN"]=3]="MIN",t[t["MAX"]=4]="MAX",t[t["ORDER"]=5]="ORDER"})(F||(F={}));var nt=(H={},rt(H,F.VALUE,'The type of the "value" is illegal'),rt(H,F.INTERVAL,'The prop "interval" is invalid, "(max - min)" cannot be divisible by "interval"'),rt(H,F.MIN,'The "value" cannot be less than the minimum.'),rt(H,F.MAX,'The "value" cannot be greater than the maximum.'),rt(H,F.ORDER,'When "order" is false, the parameters "minRange", "maxRange", "fixed", "enabled" are invalid.'),H),ot=function(){function t(e){Z(this,t),this.dotsPos=[],this.dotsValue=[],this.data=e.data,this.max=e.max,this.min=e.min,this.interval=e.interval,this.order=e.order,this.marks=e.marks,this.process=e.process,this.onError=e.onError,this.order?(this.minRange=e.minRange||0,this.maxRange=e.maxRange||0,this.enableCross=e.enableCross,this.fixed=e.fixed):((e.minRange||e.maxRange||!e.enableCross||e.fixed)&&this.emitError(F.ORDER),this.minRange=0,this.maxRange=0,this.enableCross=!0,this.fixed=!1),this.setValue(e.value)}return et(t,[{key:"setValue",value:function(t){this.dotsValue=Array.isArray(t)?Y(t):[t],this.syncDotsPos()}},{key:"setDotsPos",value:function(t){var e=this,r=this.order?Y(t).sort(function(t,e){return t-e}):t;this.dotsPos=r,this.dotsValue=r.map(function(t){return e.parsePos(t)})}},{key:"syncDotsPos",value:function(){var t=this;this.dotsPos=this.dotsValue.map(function(e){return t.parseValue(e)})}},{key:"getRecentDot",value:function(t){var e=this.dotsPos.map(function(e){return Math.abs(e-t)});return e.indexOf(Math.min.apply(Math,Y(e)))}},{key:"getIndexByValue",value:function(t){return this.data?this.data.indexOf(t):new $(+t).minus(this.min).divide(this.interval).toNumber()}},{key:"getValueByIndex",value:function(t){return t<0?t=0:t>this.total&&(t=this.total),this.data?this.data[t]:new $(t).multiply(this.interval).plus(this.min).toNumber()}},{key:"setDotPos",value:function(t,e){t=this.getValidPos(t,e).pos;var r=t-this.dotsPos[e];if(r){var n=new Array(this.dotsPos.length);this.fixed?n=this.getFixedChangePosArr(r,e):this.minRange||this.maxRange?n=this.getLimitRangeChangePosArr(t,r,e):n[e]=r,this.setDotsPos(this.dotsPos.map(function(t,e){return t+(n[e]||0)}))}}},{key:"getFixedChangePosArr",value:function(t,e){var r=this;return this.dotsPos.forEach(function(n,o){if(o!==e){var i=r.getValidPos(n+t,o),s=i.pos,a=i.inRange;a||(t=Math.min(Math.abs(s-n),Math.abs(t))*(t<0?-1:1))}}),this.dotsPos.map(function(e){return t})}},{key:"getLimitRangeChangePosArr",value:function(t,e,r){var n=this,o=[{index:r,changePos:e}],i=e;return[this.minRange,this.maxRange].forEach(function(s,a){if(!s)return!1;var u=0===a,l=e>0,c=0;c=u?l?1:-1:l?-1:1;var d=function(t,e){var r=Math.abs(t-e);return u?r<n.minRangeDir:r>n.maxRangeDir},f=r+c,h=n.dotsPos[f],p=t;while(n.isPos(h)&&d(h,p)){var v=n.getValidPos(h+i,f),y=v.pos;o.push({index:f,changePos:y-h}),f+=c,p=y,h=n.dotsPos[f]}}),this.dotsPos.map(function(t,e){var r=o.filter(function(t){return t.index===e});return r.length?r[0].changePos:0})}},{key:"isPos",value:function(t){return"number"===typeof t}},{key:"getValidPos",value:function(t,e){var r=this.valuePosRange[e],n=!0;return t<r[0]?(t=r[0],n=!1):t>r[1]&&(t=r[1],n=!1),{pos:t,inRange:n}}},{key:"parseValue",value:function(t){if(this.data)t=this.data.indexOf(t);else if("number"===typeof t||"string"===typeof t){if(t=+t,t<this.min)return this.emitError(F.MIN),0;if(t>this.max)return this.emitError(F.MAX),0;if("number"!==typeof t||t!==t)return this.emitError(F.VALUE),0;t=new $(t).minus(this.min).divide(this.interval).toNumber()}var e=new $(t).multiply(this.gap).toNumber();return e<0?0:e>100?100:e}},{key:"parsePos",value:function(t){var e=Math.round(t/this.gap);return this.getValueByIndex(e)}},{key:"isActiveByPos",value:function(t){return this.processArray.some(function(e){var r=W(e,2),n=r[0],o=r[1];return t>=n&&t<=o})}},{key:"getValues",value:function(){var t=this;return this.data?this.data:Array.from(new Array(this.total),function(e,r){return new $(r).multiply(t.interval).plus(t.min).toNumber()}).concat([this.max])}},{key:"emitError",value:function(t){this.onError&&this.onError(t,nt[t])}},{key:"markList",get:function(){var t=this;if(!this.marks)return[];var e=function(e,r){var n=t.parseValue(e);return U({pos:n,value:"string"===typeof e?parseFloat(e):e,label:e,active:t.isActiveByPos(n)},r)};return!0===this.marks?this.getValues().map(function(t){return e(t)}):"[object Object]"===Object.prototype.toString.call(this.marks)?Object.keys(this.marks).sort(function(t,e){return+t-+e}).map(function(r){var n=t.marks[r];return e(r,"string"!==typeof n?n:{label:n})}):Array.isArray(this.marks)?this.marks.map(function(t){return e(t)}):"function"===typeof this.marks?this.getValues().map(function(e){return{value:e,result:t.marks(e)}}).filter(function(t){var e=t.result;return!!e}).map(function(t){var r=t.value,n=t.result;return e(r,n)}):[]}},{key:"processArray",get:function(){if(this.process){if("function"===typeof this.process)return this.process(this.dotsPos);if(1===this.dotsPos.length)return[[0,this.dotsPos[0]]];if(this.dotsPos.length>1)return[[Math.min.apply(Math,Y(this.dotsPos)),Math.max.apply(Math,Y(this.dotsPos))]]}return[]}},{key:"total",get:function(){var t=0;return t=this.data?this.data.length-1:new $(this.max).minus(this.min).divide(this.interval).toNumber(),t-Math.floor(t)!==0?(this.emitError(F.INTERVAL),0):t}},{key:"gap",get:function(){return 100/this.total}},{key:"minRangeDir",get:function(){return this.minRange?this.minRange*this.gap:0}},{key:"maxRangeDir",get:function(){return this.maxRange?this.maxRange*this.gap:100}},{key:"valuePosRange",get:function(){var t=this,e=this.dotsPos,r=[];return e.forEach(function(n,o){r.push([Math.max(t.minRange?t.minRangeDir*o:0,t.enableCross?0:e[o-1]||0),Math.min(t.minRange?100-t.minRangeDir*(e.length-1-o):100,t.enableCross?100:e[o+1]||100)])}),r}},{key:"dotsIndex",get:function(){var t=this;return this.dotsValue.map(function(e){return t.getIndexByValue(e)})}}]),t}();function it(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function st(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function at(t,e,r){return e&&st(t.prototype,e),r&&st(t,r),t}var ut=function(){function t(e){it(this,t),this.states=0,this.map=e}return at(t,[{key:"add",value:function(t){this.states|=t}},{key:"delete",value:function(t){this.states&=~t}},{key:"toggle",value:function(t){this.has(t)?this.delete(t):this.add(t)}},{key:"has",value:function(t){return!!(this.states&t)}}]),t}();r("4abb");function lt(t){return lt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lt(t)}function ct(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"===typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){vt(t,e,r[e])})}return t}function dt(t,e){return pt(t)||ht(t,e)||ft()}function ft(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function ht(t,e){var r=[],n=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(n=(s=a.next()).done);n=!0)if(r.push(s.value),e&&r.length===e)break}catch(u){o=!0,i=u}finally{try{n||null==a["return"]||a["return"]()}finally{if(o)throw i}}return r}function pt(t){if(Array.isArray(t))return t}function vt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function yt(t){return gt(t)||bt(t)||mt()}function mt(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function bt(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}function gt(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function kt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function wt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function xt(t,e,r){return e&&wt(t.prototype,e),r&&wt(t,r),t}function St(t,e){return!e||"object"!==lt(e)&&"function"!==typeof e?Pt(t):e}function Pt(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Ot(t){return Ot=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ot(t)}function Et(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Rt(t,e)}function Rt(t,e){return Rt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Rt(t,e)}var Dt={None:0,Drag:1,Focus:2},At=4,jt=function(t){function e(){var t;return kt(this,e),t=St(this,Ot(e).apply(this,arguments)),t.states=new ut(Dt),t.scale=1,t.focusDotIndex=0,t}return Et(e,t),xt(e,[{key:"onValueChanged",value:function(){!this.states.has(Dt.Drag)&&this.isNotSync&&this.control.setValue(this.value)}},{key:"created",value:function(){this.initControl()}},{key:"mounted",value:function(){this.bindEvent()}},{key:"beforeDestroy",value:function(){this.unbindEvent()}},{key:"bindEvent",value:function(){document.addEventListener("touchmove",this.dragMove,{passive:!1}),document.addEventListener("touchend",this.dragEnd,{passive:!1}),document.addEventListener("mousedown",this.blurHandle),document.addEventListener("mousemove",this.dragMove),document.addEventListener("mouseup",this.dragEnd),document.addEventListener("mouseleave",this.dragEnd),document.addEventListener("keydown",this.keydownHandle)}},{key:"unbindEvent",value:function(){document.removeEventListener("touchmove",this.dragMove),document.removeEventListener("touchend",this.dragEnd),document.removeEventListener("mousemove",this.dragMove),document.removeEventListener("mouseup",this.dragEnd),document.removeEventListener("mouseleave",this.dragEnd),document.removeEventListener("keydown",this.keydownHandle)}},{key:"setScale",value:function(){this.scale=new $(Math.floor(this.isHorizontal?this.$el.offsetWidth:this.$el.offsetHeight)).divide(100).toNumber()}},{key:"initControl",value:function(){var t=this;this.control=new ot({value:this.value,data:this.data,enableCross:this.enableCross,fixed:this.fixed,max:this.max,min:this.min,interval:this.interval,minRange:this.minRange,maxRange:this.maxRange,order:this.order,marks:this.marks,process:this.process,onError:this.emitError}),["data","enableCross","fixed","max","min","interval","minRange","maxRange","order","marks","process"].forEach(function(e){t.$watch(e,function(r){if("data"===e&&Array.isArray(t.control.data)&&Array.isArray(r)&&t.control.data.length===r.length&&r.every(function(e,r){return e===t.control.data[r]}))return!1;t.control[e]=r,["data","max","min","interval"].includes(e)&&t.control.syncDotsPos()})})}},{key:"isDisabledByDotIndex",value:function(t){return this.dots[t].disabled}},{key:"syncValueByPos",value:function(){var t=this,e=this.control.dotsValue;if(this.included&&this.control.markList.length>0){var r=function(e){var r=e,n=t.max-t.min;return t.control.markList.forEach(function(t){if("number"===typeof t.value&&"number"===typeof e){var o=Math.abs(t.value-e);o<n&&(n=o,r=t.value)}}),r};e=e.map(function(t){return r(t)})}this.isDiff(e,Array.isArray(this.value)?this.value:[this.value])&&this.$emit("change",1===e.length?e[0]:yt(e))}},{key:"isDiff",value:function(t,e){return t.length!==e.length||t.some(function(t,r){return t!==e[r]})}},{key:"emitError",value:function(t,e){this.$emit("error",t,e)}},{key:"dragStart",value:function(t){this.focusDotIndex=t,this.setScale(),this.states.add(Dt.Drag),this.states.add(Dt.Focus),this.$emit("drag-start")}},{key:"dragMove",value:function(t){if(!this.states.has(Dt.Drag))return!1;t.preventDefault();var e=this.getPosByEvent(t);this.isCrossDot(e),this.control.setDotPos(e,this.focusDotIndex),this.lazy||this.syncValueByPos();var r=this.control.dotsValue;this.$emit("dragging",1===r.length?r[0]:yt(r))}},{key:"isCrossDot",value:function(t){if(this.canSort){var e=this.focusDotIndex,r=t;r>this.dragRange[1]?(r=this.dragRange[1],this.focusDotIndex++):r<this.dragRange[0]&&(r=this.dragRange[0],this.focusDotIndex--),e!==this.focusDotIndex&&this.control.setDotPos(r,e)}}},{key:"dragEnd",value:function(){var t=this;if(!this.states.has(Dt.Drag))return!1;this.lazy&&this.syncValueByPos(),setTimeout(function(){t.included&&t.isNotSync?t.control.setValue(t.value):t.control.syncDotsPos(),t.states.delete(Dt.Drag),t.useKeyboard||t.states.delete(Dt.Focus),t.$emit("drag-end")})}},{key:"blurHandle",value:function(t){if(!this.states.has(Dt.Focus)||!this.$refs.container||this.$refs.container.contains(t.target))return!1;this.states.delete(Dt.Focus)}},{key:"clickHandle",value:function(t){if(!this.clickable)return!1;if(!this.states.has(Dt.Drag)){this.setScale();var e=this.getPosByEvent(t);this.setValueByPos(e)}}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.states.add(Dt.Focus),this.focusDotIndex=t}},{key:"blur",value:function(){this.states.delete(Dt.Focus)}},{key:"getValue",value:function(){var t=this.control.dotsValue;return 1===t.length?t[0]:t}},{key:"getIndex",value:function(){var t=this.control.dotsIndex;return 1===t.length?t[0]:t}},{key:"setValueByPos",value:function(t){var e=this,r=this.control.getRecentDot(t);if(this.isDisabledByDotIndex(r))return!1;this.focusDotIndex=r,this.control.setDotPos(t,r),this.syncValueByPos(),this.useKeyboard&&this.states.add(Dt.Focus),setTimeout(function(){e.included&&e.isNotSync?e.control.setValue(e.value):e.control.syncDotsPos()})}},{key:"keydownHandle",value:function(t){if(!this.useKeyboard||!this.states.has(Dt.Focus))return!1;var e=I(t,{direction:this.direction,max:this.control.total,min:0});if(e){t.preventDefault();var r=this.control.getIndexByValue(this.control.dotsValue[this.focusDotIndex]),n=e(r),o=this.control.parseValue(this.control.getValueByIndex(n));this.isCrossDot(o),this.control.setDotPos(o,this.focusDotIndex),this.syncValueByPos()}}},{key:"getPosByEvent",value:function(t){return T(t,this.$el,this.isReverse)[this.isHorizontal?"x":"y"]/this.scale}},{key:"renderSlot",value:function(t,e,r,n){var o=this.$createElement,i=this.$scopedSlots[t];return i?n?i(e):o("template",{slot:t},[i(e)]):r}},{key:"render",value:function(){var t=this,e=arguments[0];return e("div",{ref:"container",class:this.containerClasses,style:this.containerStyles,attrs:{"aria-hidden":!0},on:{click:this.clickHandle}},[e("div",{class:"vue-slider-rail",style:this.railStyle},[this.processBaseStyleArray.map(function(r,n){return e("div",{class:"vue-slider-process",key:"process-".concat(n),style:[r,t.processStyle]})}),this.marks?e("div",{class:"vue-slider-marks"},[this.control.markList.map(function(r){var n;return t.renderSlot("mark",r,e("vue-slider-mark",{attrs:{mark:r,hideLabel:t.hideLabel,stepStyle:t.stepStyle,stepActiveStyle:t.stepActiveStyle,labelStyle:t.labelStyle,labelActiveStyle:t.labelActiveStyle},style:(n={},vt(n,t.isHorizontal?"height":"width","100%"),vt(n,t.isHorizontal?"width":"height",t.tailSize),vt(n,t.mainDirection,"".concat(r.pos,"%")),n),on:{pressLabel:function(e){return t.setValueByPos(e)}}},[t.renderSlot("step",r,null),t.renderSlot("label",r,null)]),!0)})]):null,this.dots.map(function(r,n){var o;return e("vue-slider-dot",{ref:"dot-".concat(n),key:"dot-".concat(n),attrs:{value:r.value,disabled:r.disabled,focus:r.focus,"dot-style":[r.style,r.disabled?r.disabledStyle:null,r.focus?r.focusStyle:null],tooltip:r.tooltip||t.tooltip,"tooltip-style":[t.tooltipStyle,r.tooltipStyle,r.disabled?r.tooltipDisabledStyle:null,r.focus?r.tooltipFocusStyle:null],"tooltip-formatter":t.tooltipFormatter,"tooltip-placement":t.tooltipDirections[n]},style:[t.dotBaseStyle,(o={},vt(o,t.mainDirection,"".concat(r.pos,"%")),vt(o,"transition","".concat(t.mainDirection," ").concat(t.animateTime,"s")),o)],on:{"drag-start":function(){return t.dragStart(n)}}},[t.renderSlot("dot",r,null),t.renderSlot("tooltip",r,null)])})]),1!==this.dots.length||this.data?null:e("input",{class:"vue-slider-sr-only",attrs:{type:"range",min:this.min,max:this.max},domProps:{value:this.value}})])}},{key:"tailSize",get:function(){return N((this.isHorizontal?this.height:this.width)||At)}},{key:"containerClasses",get:function(){return["vue-slider",["vue-slider-".concat(this.direction)],{"vue-slider-disabled":this.disabled}]}},{key:"containerStyles",get:function(){var t=Array.isArray(this.dotSize)?this.dotSize:[this.dotSize,this.dotSize],e=dt(t,2),r=e[0],n=e[1],o=this.width?N(this.width):this.isHorizontal?"auto":N(At),i=this.height?N(this.height):this.isHorizontal?N(At):"auto";return{padding:this.isHorizontal?"".concat(n/2,"px 0"):"0 ".concat(r/2,"px"),width:o,height:i}}},{key:"processBaseStyleArray",get:function(){var t=this;return this.control.processArray.map(function(e){var r,n=dt(e,3),o=n[0],i=n[1],s=n[2];if(o>i){var a=[i,o];o=a[0],i=a[1]}var u=t.isHorizontal?"width":"height";return ct((r={},vt(r,t.isHorizontal?"height":"width","100%"),vt(r,t.isHorizontal?"top":"left",0),vt(r,t.mainDirection,"".concat(o,"%")),vt(r,u,"".concat(i-o,"%")),vt(r,"transitionProperty","".concat(u,",").concat(t.mainDirection)),vt(r,"transitionDuration","".concat(t.animateTime,"s")),r),s)})}},{key:"dotBaseStyle",get:function(){var t,e=Array.isArray(this.dotSize)?this.dotSize:[this.dotSize,this.dotSize],r=dt(e,2),n=r[0],o=r[1];return t=this.isHorizontal?vt({transform:"translate(".concat(this.isReverse?"50%":"-50%",", -50%)"),WebkitTransform:"translate(".concat(this.isReverse?"50%":"-50%",", -50%)"),top:"50%"},"ltr"===this.direction?"left":"right","0"):vt({transform:"translate(-50%, ".concat(this.isReverse?"50%":"-50%",")"),WebkitTransform:"translate(-50%, ".concat(this.isReverse?"50%":"-50%",")"),left:"50%"},"btt"===this.direction?"bottom":"top","0"),ct({width:"".concat(n,"px"),height:"".concat(o,"px")},t)}},{key:"mainDirection",get:function(){switch(this.direction){case"ltr":return"left";case"rtl":return"right";case"btt":return"bottom";case"ttb":return"top"}}},{key:"isHorizontal",get:function(){return"ltr"===this.direction||"rtl"===this.direction}},{key:"isReverse",get:function(){return"rtl"===this.direction||"btt"===this.direction}},{key:"tooltipDirections",get:function(){var t=this.tooltipPlacement||(this.isHorizontal?"top":"left");return Array.isArray(t)?t:Array.from(new Array(this.dots.length),function(){return t})}},{key:"dots",get:function(){var t=this;return this.control.dotsPos.map(function(e,r){return ct({pos:e,index:r,value:t.control.dotsValue[r],focus:t.states.has(Dt.Focus)&&t.focusDotIndex===r,disabled:!1,style:t.dotStyle},(Array.isArray(t.dotOptions)?t.dotOptions[r]:t.dotOptions)||{})})}},{key:"animateTime",get:function(){return this.states.has(Dt.Drag)?0:this.duration}},{key:"canSort",get:function(){return this.order&&!this.minRange&&!this.maxRange&&!this.fixed&&this.enableCross}},{key:"isNotSync",get:function(){var t=this.control.dotsValue;return Array.isArray(this.value)?this.value.length!==t.length||this.value.some(function(e,r){return e!==t[r]}):this.value!==t[0]}},{key:"dragRange",get:function(){var t=this.dots[this.focusDotIndex-1],e=this.dots[this.focusDotIndex+1];return[t?t.pos:-1/0,e?e.pos:1/0]}}]),e}(s.a);o([l("change",{default:0})],jt.prototype,"value",void 0),o([c({default:"ltr",validator:function(t){return["ltr","rtl","ttb","btt"].indexOf(t)>-1}})],jt.prototype,"direction",void 0),o([c({type:[Number,String]})],jt.prototype,"width",void 0),o([c({type:[Number,String]})],jt.prototype,"height",void 0),o([c({default:14})],jt.prototype,"dotSize",void 0),o([c({type:Number,default:0})],jt.prototype,"min",void 0),o([c({type:Number,default:100})],jt.prototype,"max",void 0),o([c({type:Number,default:1})],jt.prototype,"interval",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"disabled",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"clickable",void 0),o([c({type:Number,default:.5})],jt.prototype,"duration",void 0),o([c(Array)],jt.prototype,"data",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"lazy",void 0),o([c({type:String,validator:function(t){return["none","always","focus"].includes(t)},default:"focus"})],jt.prototype,"tooltip",void 0),o([c({type:String,validator:function(t){return["top","right","bottom","left"].includes(t)}})],jt.prototype,"tooltipPlacement",void 0),o([c({type:[String,Function]})],jt.prototype,"tooltipFormatter",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"useKeyboard",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"enableCross",void 0),o([c({type:Boolean,default:!1})],jt.prototype,"fixed",void 0),o([c({type:Boolean,default:!0})],jt.prototype,"order",void 0),o([c(Number)],jt.prototype,"minRange",void 0),o([c(Number)],jt.prototype,"maxRange",void 0),o([c({type:[Boolean,Object,Array,Function],default:!1})],jt.prototype,"marks",void 0),o([c({type:[Boolean,Function],default:!0})],jt.prototype,"process",void 0),o([c(Boolean)],jt.prototype,"included",void 0),o([c(Boolean)],jt.prototype,"hideLabel",void 0),o([c()],jt.prototype,"dotOptions",void 0),o([c()],jt.prototype,"railStyle",void 0),o([c()],jt.prototype,"processStyle",void 0),o([c()],jt.prototype,"dotStyle",void 0),o([c()],jt.prototype,"tooltipStyle",void 0),o([c()],jt.prototype,"stepStyle",void 0),o([c()],jt.prototype,"stepActiveStyle",void 0),o([c()],jt.prototype,"labelStyle",void 0),o([c()],jt.prototype,"labelActiveStyle",void 0),o([d("value")],jt.prototype,"onValueChanged",null),jt=o([u()({data:function(){return{control:null}},components:{VueSliderDot:x,VueSliderMark:V},inheritAttrs:!1})],jt);var _t=jt,Mt=_t;r.d(e,"ERROR_TYPE",function(){return F});e["default"]=Mt}})["default"]}); | ||
//# sourceMappingURL=vue-slider-component.umd.min.js.map |
@@ -8,3 +8,3 @@ import { Direction } from '../typings' | ||
export const toPx = (value: number | string): string => { | ||
export const getSize = (value: number | string): string => { | ||
return typeof value === 'number' ? `${value}px` : value | ||
@@ -11,0 +11,0 @@ } |
{ | ||
"name": "vue-slider-component", | ||
"version": "3.0.11", | ||
"version": "3.0.12", | ||
"description": "A highly customized slider component", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -33,3 +33,3 @@ # Props | ||
- **Type**: `number` | ||
- **Type**: `number | string` | ||
@@ -44,3 +44,3 @@ - **Default**: `undefined` | ||
- **Type**: `number` | ||
- **Type**: `number | string` | ||
@@ -47,0 +47,0 @@ - **Default**: `undefined` |
@@ -33,3 +33,3 @@ # 参数 | ||
- **类型**:`number` | ||
- **类型**:`number | string` | ||
@@ -44,3 +44,3 @@ - **默认值**:`undefined` | ||
- **类型**:`number` | ||
- **类型**:`number | string` | ||
@@ -47,0 +47,0 @@ - **默认值**:`undefined` |
@@ -1,4 +0,3 @@ | ||
import VueSlider from './vue-slider' | ||
import { ERROR_TYPE } from './utils/control' | ||
export { ERROR_TYPE } | ||
export default VueSlider | ||
import VueSlider from './vue-slider'; | ||
export { ERROR_TYPE } from './utils/control'; | ||
export default VueSlider; |
@@ -1,11 +0,13 @@ | ||
import { Value, Mark, MarksProp, ProcessProp, ProcessOption } from '../typings' | ||
export const enum ERROR_TYPE { | ||
VALUE = 1, | ||
INTERVAL = 2, | ||
MIN = 3, | ||
MAX = 4, | ||
ORDER = 5, | ||
import { Value, Mark, MarksProp, ProcessProp, ProcessOption } from '../typings'; | ||
export declare const enum ERROR_TYPE { | ||
VALUE = 1, | ||
INTERVAL = 2, | ||
MIN = 3, | ||
MAX = 4, | ||
ORDER = 5 | ||
} | ||
declare type ERROR_MESSAGE = { [key in ERROR_TYPE]: string } | ||
export declare const ERROR_MSG: ERROR_MESSAGE | ||
declare type ERROR_MESSAGE = { | ||
[key in ERROR_TYPE]: string; | ||
}; | ||
export declare const ERROR_MSG: ERROR_MESSAGE; | ||
/** | ||
@@ -18,157 +20,155 @@ * Slider logic control center | ||
export default class Control { | ||
dotsPos: number[] | ||
dotsValue: Value[] | ||
data?: Value[] | ||
enableCross: boolean | ||
fixed: boolean | ||
max: number | ||
min: number | ||
interval: number | ||
minRange: number | ||
maxRange: number | ||
order: boolean | ||
marks?: MarksProp | ||
process?: ProcessProp | ||
onError?: (type: ERROR_TYPE, message: string) => void | ||
constructor(options: { | ||
value: Value | Value[] | ||
data?: Value[] | ||
enableCross: boolean | ||
fixed: boolean | ||
max: number | ||
min: number | ||
interval: number | ||
order: boolean | ||
minRange?: number | ||
maxRange?: number | ||
marks?: MarksProp | ||
process?: ProcessProp | ||
onError?: (type: ERROR_TYPE, message: string) => void | ||
}) | ||
setValue(value: Value | Value[]): void | ||
setDotsPos(dotsPos: number[]): void | ||
syncDotsPos(): void | ||
/** | ||
* Get all the marks | ||
* | ||
* @readonly | ||
* @type {Mark[]} | ||
* @memberof Control | ||
*/ | ||
readonly markList: Mark[] | ||
/** | ||
* Get the most recent slider index by position | ||
* | ||
* @param {number} pos | ||
* @returns {number} | ||
* @memberof Control | ||
*/ | ||
getRecentDot(pos: number): number | ||
/** | ||
* Get index by value | ||
* | ||
* @param {Value} value | ||
* @returns {number} | ||
* @memberof Control | ||
*/ | ||
getIndexByValue(value: Value): number | ||
/** | ||
* Get value by index | ||
* | ||
* @param {index} number | ||
* @returns {Value} | ||
* @memberof Control | ||
*/ | ||
getValueByIndex(index: number): Value | ||
/** | ||
* Set the position of a single slider | ||
* | ||
* @param {number} pos | ||
* @param {number} index | ||
*/ | ||
setDotPos(pos: number, index: number): void | ||
/** | ||
* In fixed mode, get the position of all slider changes | ||
* | ||
* @param {number} changePos Change distance of a single slider | ||
* @param {number} index slider index | ||
* @returns {DotsPosChangeArray} | ||
* @memberof Control | ||
*/ | ||
private getFixedChangePosArr | ||
/** | ||
* In minRange/maxRange mode, get the position of all slider changes | ||
* | ||
* @param {number} pos position of a single slider | ||
* @param {number} changePos Change distance of a single slider | ||
* @param {number} index slider index | ||
* @returns {DotsPosChangeArray} | ||
* @memberof Control | ||
*/ | ||
private getLimitRangeChangePosArr | ||
private isPos | ||
/** | ||
* Get a valid position by pos | ||
* | ||
* @param {number} pos | ||
* @param {number} index | ||
* @returns {{ pos: number, inRange: boolean }} | ||
*/ | ||
getValidPos( | ||
pos: number, | ||
index: number, | ||
): { | ||
pos: number | ||
inRange: boolean | ||
} | ||
/** | ||
* Calculate the position of the slider by value | ||
* | ||
* @param {Value} val | ||
* @returns {number} | ||
*/ | ||
parseValue(val: Value): number | ||
/** | ||
* Calculate the value by position | ||
* | ||
* @param {number} pos | ||
* @returns {Value} | ||
* @memberof Control | ||
*/ | ||
parsePos(pos: number): Value | ||
/** | ||
* Determine if the location is active | ||
* | ||
* @param {number} pos | ||
* @returns {boolean} | ||
* @memberof Control | ||
*/ | ||
isActiveByPos(pos: number): boolean | ||
/** | ||
* Get each value | ||
* | ||
* @returns {Value[]} | ||
* @memberof Control | ||
*/ | ||
getValues(): Value[] | ||
private emitError | ||
readonly processArray: ProcessOption | ||
/** | ||
* The total number of values | ||
* | ||
* @type {number} | ||
* @memberof Control | ||
*/ | ||
readonly total: number | ||
readonly gap: number | ||
readonly minRangeDir: number | ||
readonly maxRangeDir: number | ||
/** | ||
* Sliding range of each slider | ||
* | ||
* @type {Array<[number, number]>} | ||
* @memberof Control | ||
*/ | ||
readonly valuePosRange: Array<[number, number]> | ||
dotsPos: number[]; | ||
dotsValue: Value[]; | ||
data?: Value[]; | ||
enableCross: boolean; | ||
fixed: boolean; | ||
max: number; | ||
min: number; | ||
interval: number; | ||
minRange: number; | ||
maxRange: number; | ||
order: boolean; | ||
marks?: MarksProp; | ||
process?: ProcessProp; | ||
onError?: (type: ERROR_TYPE, message: string) => void; | ||
constructor(options: { | ||
value: Value | Value[]; | ||
data?: Value[]; | ||
enableCross: boolean; | ||
fixed: boolean; | ||
max: number; | ||
min: number; | ||
interval: number; | ||
order: boolean; | ||
minRange?: number; | ||
maxRange?: number; | ||
marks?: MarksProp; | ||
process?: ProcessProp; | ||
onError?: (type: ERROR_TYPE, message: string) => void; | ||
}); | ||
setValue(value: Value | Value[]): void; | ||
setDotsPos(dotsPos: number[]): void; | ||
syncDotsPos(): void; | ||
/** | ||
* Get all the marks | ||
* | ||
* @readonly | ||
* @type {Mark[]} | ||
* @memberof Control | ||
*/ | ||
readonly markList: Mark[]; | ||
/** | ||
* Get the most recent slider index by position | ||
* | ||
* @param {number} pos | ||
* @returns {number} | ||
* @memberof Control | ||
*/ | ||
getRecentDot(pos: number): number; | ||
/** | ||
* Get index by value | ||
* | ||
* @param {Value} value | ||
* @returns {number} | ||
* @memberof Control | ||
*/ | ||
getIndexByValue(value: Value): number; | ||
/** | ||
* Get value by index | ||
* | ||
* @param {index} number | ||
* @returns {Value} | ||
* @memberof Control | ||
*/ | ||
getValueByIndex(index: number): Value; | ||
/** | ||
* Set the position of a single slider | ||
* | ||
* @param {number} pos | ||
* @param {number} index | ||
*/ | ||
setDotPos(pos: number, index: number): void; | ||
/** | ||
* In fixed mode, get the position of all slider changes | ||
* | ||
* @param {number} changePos Change distance of a single slider | ||
* @param {number} index slider index | ||
* @returns {DotsPosChangeArray} | ||
* @memberof Control | ||
*/ | ||
private getFixedChangePosArr; | ||
/** | ||
* In minRange/maxRange mode, get the position of all slider changes | ||
* | ||
* @param {number} pos position of a single slider | ||
* @param {number} changePos Change distance of a single slider | ||
* @param {number} index slider index | ||
* @returns {DotsPosChangeArray} | ||
* @memberof Control | ||
*/ | ||
private getLimitRangeChangePosArr; | ||
private isPos; | ||
/** | ||
* Get a valid position by pos | ||
* | ||
* @param {number} pos | ||
* @param {number} index | ||
* @returns {{ pos: number, inRange: boolean }} | ||
*/ | ||
getValidPos(pos: number, index: number): { | ||
pos: number; | ||
inRange: boolean; | ||
}; | ||
/** | ||
* Calculate the position of the slider by value | ||
* | ||
* @param {Value} val | ||
* @returns {number} | ||
*/ | ||
parseValue(val: Value): number; | ||
/** | ||
* Calculate the value by position | ||
* | ||
* @param {number} pos | ||
* @returns {Value} | ||
* @memberof Control | ||
*/ | ||
parsePos(pos: number): Value; | ||
/** | ||
* Determine if the location is active | ||
* | ||
* @param {number} pos | ||
* @returns {boolean} | ||
* @memberof Control | ||
*/ | ||
isActiveByPos(pos: number): boolean; | ||
/** | ||
* Get each value | ||
* | ||
* @returns {Value[]} | ||
* @memberof Control | ||
*/ | ||
getValues(): Value[]; | ||
private emitError; | ||
readonly processArray: ProcessOption; | ||
/** | ||
* The total number of values | ||
* | ||
* @type {number} | ||
* @memberof Control | ||
*/ | ||
readonly total: number; | ||
readonly gap: number; | ||
readonly minRangeDir: number; | ||
readonly maxRangeDir: number; | ||
/** | ||
* Sliding range of each slider | ||
* | ||
* @type {Array<[number, number]>} | ||
* @memberof Control | ||
*/ | ||
readonly valuePosRange: Array<[number, number]>; | ||
readonly dotsIndex: number[]; | ||
} | ||
export {} | ||
export {}; |
@@ -1,2 +0,2 @@ | ||
declare type Operator = '+' | '-' | '*' | '/' | '%' | ||
declare type Operator = '+' | '-' | '*' | '/' | '%'; | ||
/** | ||
@@ -9,12 +9,12 @@ * For any precise floating point calculation | ||
export default class Decimal { | ||
num: number | ||
constructor(num: number) | ||
decimal(num2: number, operator: Operator, isChain?: boolean): this | ||
plus(num2: number): this | ||
minus(num2: number): this | ||
multiply(num2: number): this | ||
divide(num2: number): this | ||
remainder(num2: number): this | ||
toNumber(): number | ||
num: number; | ||
constructor(num: number); | ||
decimal(num2: number, operator: Operator, isChain?: boolean): this; | ||
plus(num2: number): this; | ||
minus(num2: number): this; | ||
multiply(num2: number): this; | ||
divide(num2: number): this; | ||
remainder(num2: number): this; | ||
toNumber(): number; | ||
} | ||
export {} | ||
export {}; |
@@ -1,21 +0,14 @@ | ||
import { Direction } from '../typings' | ||
import { Direction } from '../typings'; | ||
interface IPosObject { | ||
x: number | ||
y: number | ||
x: number; | ||
y: number; | ||
} | ||
export declare const toPx: (value: string | number) => string | ||
export declare const getPos: ( | ||
e: MouseEvent | TouchEvent, | ||
elem: HTMLDivElement, | ||
isReverse: boolean, | ||
) => IPosObject | ||
declare type HandleFunction = (i: number) => number | ||
export declare const getKeyboardHandleFunc: ( | ||
e: KeyboardEvent, | ||
params: { | ||
direction: Direction | ||
max: number | ||
min: number | ||
}, | ||
) => HandleFunction | null | ||
export {} | ||
export declare const getSize: (value: string | number) => string; | ||
export declare const getPos: (e: MouseEvent | TouchEvent, elem: HTMLDivElement, isReverse: boolean) => IPosObject; | ||
declare type HandleFunction = (i: number) => number; | ||
export declare const getKeyboardHandleFunc: (e: KeyboardEvent, params: { | ||
direction: Direction; | ||
max: number; | ||
min: number; | ||
}) => HandleFunction | null; | ||
export {}; |
export interface StateMap { | ||
[key: string]: number | ||
[key: string]: number; | ||
} | ||
export default class State { | ||
map: StateMap | ||
states: number | ||
constructor(map: StateMap) | ||
add(state: number): void | ||
delete(state: number): void | ||
toggle(state: number): void | ||
has(state: number): boolean | ||
map: StateMap; | ||
states: number; | ||
constructor(map: StateMap); | ||
add(state: number): void; | ||
delete(state: number): void; | ||
toggle(state: number): void; | ||
has(state: number): boolean; | ||
} |
@@ -1,45 +0,35 @@ | ||
import { Vue } from 'vue-property-decorator' | ||
import { Value, Styles, Position, TooltipProp, TooltipFormatter } from './typings' | ||
import './styles/dot.scss' | ||
import { Vue } from 'vue-property-decorator'; | ||
import { Value, Styles, Position, TooltipProp, TooltipFormatter } from './typings'; | ||
import './styles/dot.scss'; | ||
export default class VueSliderDot extends Vue { | ||
$refs: { | ||
dot: HTMLDivElement | ||
} | ||
value: Value | ||
tooltip: TooltipProp | ||
dotStyle?: Styles | ||
tooltipStyle?: Styles | ||
tooltipPlacement: Position | ||
tooltipFormatter?: TooltipFormatter | ||
focus: boolean | ||
disabled: boolean | ||
readonly dotClasses: ( | ||
| string | ||
| { | ||
'vue-slider-dot-disabled': boolean | ||
'vue-slider-dot-focus': boolean | ||
})[] | ||
readonly handleClasses: ( | ||
| string | ||
| { | ||
'vue-slider-dot-handle-disabled': boolean | ||
'vue-slider-dot-handle-focus': boolean | ||
})[] | ||
readonly tooltipClasses: ( | ||
| string | ||
| string[] | ||
| { | ||
'vue-slider-dot-tooltip-show': boolean | ||
})[] | ||
readonly tooltipInnerClasses: ( | ||
| string | ||
| string[] | ||
| { | ||
'vue-slider-dot-tooltip-inner-disabled': boolean | ||
'vue-slider-dot-tooltip-inner-focus': boolean | ||
})[] | ||
readonly showTooltip: boolean | ||
readonly tooltipValue: Value | ||
dragStart(e: MouseEvent | TouchEvent): false | undefined | ||
render(): JSX.Element | ||
$refs: { | ||
dot: HTMLDivElement; | ||
}; | ||
value: Value; | ||
tooltip: TooltipProp; | ||
dotStyle?: Styles; | ||
tooltipStyle?: Styles; | ||
tooltipPlacement: Position; | ||
tooltipFormatter?: TooltipFormatter; | ||
focus: boolean; | ||
disabled: boolean; | ||
readonly dotClasses: (string | { | ||
'vue-slider-dot-disabled': boolean; | ||
'vue-slider-dot-focus': boolean; | ||
})[]; | ||
readonly handleClasses: (string | { | ||
'vue-slider-dot-handle-disabled': boolean; | ||
'vue-slider-dot-handle-focus': boolean; | ||
})[]; | ||
readonly tooltipClasses: (string | string[] | { | ||
'vue-slider-dot-tooltip-show': boolean; | ||
})[]; | ||
readonly tooltipInnerClasses: (string | string[] | { | ||
'vue-slider-dot-tooltip-inner-disabled': boolean; | ||
'vue-slider-dot-tooltip-inner-focus': boolean; | ||
})[]; | ||
readonly showTooltip: boolean; | ||
readonly tooltipValue: Value; | ||
dragStart(e: MouseEvent | TouchEvent): false | undefined; | ||
render(): JSX.Element; | ||
} |
@@ -1,28 +0,22 @@ | ||
import { Vue } from 'vue-property-decorator' | ||
import { Mark, Styles } from './typings' | ||
import './styles/mark.scss' | ||
import { Vue } from 'vue-property-decorator'; | ||
import { Mark, Styles } from './typings'; | ||
import './styles/mark.scss'; | ||
export default class VueSlideMark extends Vue { | ||
mark: Mark | ||
hideLabel?: boolean | ||
stepStyle?: Styles | ||
stepActiveStyle?: Styles | ||
labelStyle?: Styles | ||
labelActiveStyle?: Styles | ||
readonly marksClasses: ( | ||
| string | ||
| { | ||
'vue-slider-mark-active': boolean | undefined | ||
})[] | ||
readonly stepClasses: ( | ||
| string | ||
| { | ||
'vue-slider-mark-step-active': boolean | undefined | ||
})[] | ||
readonly labelClasses: ( | ||
| string | ||
| { | ||
'vue-slider-mark-label-active': boolean | undefined | ||
})[] | ||
labelClickHandle(e: MouseEvent | TouchEvent): void | ||
render(): JSX.Element | ||
mark: Mark; | ||
hideLabel?: boolean; | ||
stepStyle?: Styles; | ||
stepActiveStyle?: Styles; | ||
labelStyle?: Styles; | ||
labelActiveStyle?: Styles; | ||
readonly marksClasses: (string | { | ||
'vue-slider-mark-active': boolean | undefined; | ||
})[]; | ||
readonly stepClasses: (string | { | ||
'vue-slider-mark-step-active': boolean | undefined; | ||
})[]; | ||
readonly labelClasses: (string | { | ||
'vue-slider-mark-label-active': boolean | undefined; | ||
})[]; | ||
labelClickHandle(e: MouseEvent | TouchEvent): void; | ||
render(): JSX.Element; | ||
} |
@@ -1,121 +0,109 @@ | ||
import { Vue } from 'vue-property-decorator' | ||
import { | ||
Value, | ||
MarksProp, | ||
Styles, | ||
DotOption, | ||
Dot, | ||
Direction, | ||
Position, | ||
ProcessProp, | ||
TooltipProp, | ||
TooltipFormatter, | ||
} from './typings' | ||
import Control from './utils/control' | ||
import State, { StateMap } from './utils/state' | ||
import './styles/slider.scss' | ||
export declare const SliderState: StateMap | ||
import { Vue } from 'vue-property-decorator'; | ||
import { Value, MarksProp, Styles, DotOption, Dot, Direction, Position, ProcessProp, TooltipProp, TooltipFormatter } from './typings'; | ||
import Control from './utils/control'; | ||
import State, { StateMap } from './utils/state'; | ||
import './styles/slider.scss'; | ||
export declare const SliderState: StateMap; | ||
export default class VueSlider extends Vue { | ||
control: Control | ||
states: State | ||
scale: number | ||
focusDotIndex: number | ||
$refs: { | ||
container: HTMLDivElement | ||
} | ||
$el: HTMLDivElement | ||
value: Value | Value[] | ||
direction: Direction | ||
width?: number | ||
height?: number | ||
dotSize: [number, number] | number | ||
min: number | ||
max: number | ||
interval: number | ||
disabled: boolean | ||
clickable: boolean | ||
duration: number | ||
data?: Value[] | ||
lazy: boolean | ||
tooltip: TooltipProp | ||
tooltipPlacement?: Position | ||
tooltipFormatter?: TooltipFormatter | ||
useKeyboard?: boolean | ||
enableCross: boolean | ||
fixed: boolean | ||
order: boolean | ||
minRange?: number | ||
maxRange?: number | ||
marks?: MarksProp | ||
process?: ProcessProp | ||
included?: boolean | ||
hideLabel?: boolean | ||
dotOptions?: DotOption | DotOption[] | ||
railStyle?: Styles | ||
processStyle?: Styles | ||
dotStyle?: Styles | ||
tooltipStyle?: Styles | ||
stepStyle?: Styles | ||
stepActiveStyle?: Styles | ||
labelStyle?: Styles | ||
labelActiveStyle?: Styles | ||
readonly tailSize: number | ||
readonly containerClasses: ( | ||
| string | ||
| string[] | ||
| { | ||
'vue-slider-disabled': boolean | ||
})[] | ||
readonly containerStyles: { | ||
padding: string | ||
width: string | ||
height: string | ||
} | ||
readonly processBaseStyleArray: Styles[] | ||
readonly dotBaseStyle: { | ||
width: string | ||
height: string | ||
} | ||
readonly mainDirection: string | ||
readonly isHorizontal: boolean | ||
readonly isReverse: boolean | ||
readonly tooltipDirections: Position[] | ||
readonly dots: Dot[] | ||
readonly animateTime: number | ||
readonly canSort: boolean | ||
onValueChanged(): void | ||
created(): void | ||
mounted(): void | ||
beforeDestroy(): void | ||
bindEvent(): void | ||
unbindEvent(): void | ||
setScale(): void | ||
initControl(): void | ||
isDisabledByDotIndex(index: number): boolean | ||
private syncValueByPos | ||
private readonly isNotSync | ||
private isDiff | ||
private emitError | ||
/** | ||
* Get the drag range of the slider | ||
* | ||
* @private | ||
* @param {number} index slider index | ||
* @returns {[number, number]} range [start, end] | ||
* @memberof VueSlider | ||
*/ | ||
private readonly dragRange | ||
private dragStart | ||
private dragMove | ||
private isCrossDot | ||
private dragEnd | ||
private blurHandle | ||
private clickHandle | ||
focus(index?: number): void | ||
blur(): void | ||
setValueByPos(pos: number): false | undefined | ||
keydownHandle(e: KeyboardEvent): false | undefined | ||
private getPosByEvent | ||
private renderSlot | ||
render(): JSX.Element | ||
control: Control; | ||
states: State; | ||
scale: number; | ||
focusDotIndex: number; | ||
$refs: { | ||
container: HTMLDivElement; | ||
}; | ||
$el: HTMLDivElement; | ||
value: Value | Value[]; | ||
direction: Direction; | ||
width?: number | string; | ||
height?: number | string; | ||
dotSize: [number, number] | number; | ||
min: number; | ||
max: number; | ||
interval: number; | ||
disabled: boolean; | ||
clickable: boolean; | ||
duration: number; | ||
data?: Value[]; | ||
lazy: boolean; | ||
tooltip: TooltipProp; | ||
tooltipPlacement?: Position; | ||
tooltipFormatter?: TooltipFormatter; | ||
useKeyboard?: boolean; | ||
enableCross: boolean; | ||
fixed: boolean; | ||
order: boolean; | ||
minRange?: number; | ||
maxRange?: number; | ||
marks?: MarksProp; | ||
process?: ProcessProp; | ||
included?: boolean; | ||
hideLabel?: boolean; | ||
dotOptions?: DotOption | DotOption[]; | ||
railStyle?: Styles; | ||
processStyle?: Styles; | ||
dotStyle?: Styles; | ||
tooltipStyle?: Styles; | ||
stepStyle?: Styles; | ||
stepActiveStyle?: Styles; | ||
labelStyle?: Styles; | ||
labelActiveStyle?: Styles; | ||
readonly tailSize: string; | ||
readonly containerClasses: (string | string[] | { | ||
'vue-slider-disabled': boolean; | ||
})[]; | ||
readonly containerStyles: { | ||
padding: string; | ||
width: string; | ||
height: string; | ||
}; | ||
readonly processBaseStyleArray: Styles[]; | ||
readonly dotBaseStyle: { | ||
width: string; | ||
height: string; | ||
}; | ||
readonly mainDirection: string; | ||
readonly isHorizontal: boolean; | ||
readonly isReverse: boolean; | ||
readonly tooltipDirections: Position[]; | ||
readonly dots: Dot[]; | ||
readonly animateTime: number; | ||
readonly canSort: boolean; | ||
onValueChanged(): void; | ||
created(): void; | ||
mounted(): void; | ||
beforeDestroy(): void; | ||
bindEvent(): void; | ||
unbindEvent(): void; | ||
setScale(): void; | ||
initControl(): void; | ||
isDisabledByDotIndex(index: number): boolean; | ||
private syncValueByPos; | ||
private readonly isNotSync; | ||
private isDiff; | ||
private emitError; | ||
/** | ||
* Get the drag range of the slider | ||
* | ||
* @private | ||
* @param {number} index slider index | ||
* @returns {[number, number]} range [start, end] | ||
* @memberof VueSlider | ||
*/ | ||
private readonly dragRange; | ||
private dragStart; | ||
private dragMove; | ||
private isCrossDot; | ||
private dragEnd; | ||
private blurHandle; | ||
private clickHandle; | ||
focus(index?: number): void; | ||
blur(): void; | ||
getValue(): string | number | (string | number)[]; | ||
getIndex(): number | number[]; | ||
setValueByPos(pos: number): false | undefined; | ||
keydownHandle(e: KeyboardEvent): false | undefined; | ||
private getPosByEvent; | ||
private renderSlot; | ||
render(): JSX.Element; | ||
} |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
898947
124
10332