!function(){function r(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function e(r,e){return function(r){if(Array.isArray(r))return r}(r)||function(r,e){var t=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null==t)return;var a,n,i=[],o=!0,l=!1;try{for(t=t.call(r);!(o=(a=t.next()).done)&&(i.push(a.value),!e||i.length!==e);o=!0);}catch(u){l=!0,n=u}finally{try{o||null==t.return||t.return()}finally{if(l)throw n}}return i}(r,e)||function(r,e){if(!r)return;if("string"==typeof r)return t(r,e);var a=Object.prototype.toString.call(r).slice(8,-1);"Object"===a&&r.constructor&&(a=r.constructor.name);if("Map"===a||"Set"===a)return Array.from(r);if("Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a))return t(r,e)}(r,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function t(r,e){(null==e||e>r.length)&&(e=r.length);for(var t=0,a=new Array(e);ti?[i,n]:[n,i]}(r).map(O):O(r),j(r,t.modelValue)||y("update:modelValue",r),e&&!j(r,o)&&y("change",r)},B=function(r){if(r.stopPropagation(),!t.disabled&&!t.readonly){var a=t.min,n=t.reverse,i=t.vertical,o=t.modelValue,l=b(x),u=i?l.height:l.width,d=Number(a)+(i?n?l.bottom-r.clientY:r.clientY-l.top:n?l.right-r.clientX:r.clientX-l.left)/u*V.value;if(A(o)){var s=e(o,2),v=s[0],c=s[1];T(d<=(v+c)/2?[d,c]:[v,d],!0)}else T(d,!0)}},z=function(r){if(!t.disabled&&!t.readonly){"start"===k.value&&y("drag-start",r),g(r,!0),S.move(r),k.value="dragging";var e=b(x),a=(t.vertical?S.deltaY.value:S.deltaX.value)/(t.vertical?e.height:e.width)*V.value;if(t.reverse&&(a=-a),A(o)){var l=t.reverse?1-n:n;i[l]=o[l]+a}else i=o+a;T(i)}},Y=function(r){t.disabled||t.readonly||("dragging"===k.value&&(T(i,!0),y("drag-end",r)),k.value="")},E=function(r){if("number"==typeof r){return _("button-wrapper",["left","right"][r])}return _("button-wrapper",t.reverse?"left":"right")},H=function(r,e){if("number"==typeof e){var a=w[0===e?"left-button":"right-button"];if(a)return a({value:r})}return w.button?w.button({value:r}):c("div",{class:_("button"),style:h(t.buttonSize)},null)},I=function(r){var e="number"==typeof r?t.modelValue[r]:t.modelValue;return c("div",{role:"slider",class:E(r),tabindex:t.disabled?void 0:0,"aria-valuemin":t.min,"aria-valuenow":e,"aria-valuemax":t.max,"aria-disabled":t.disabled||void 0,"aria-readonly":t.readonly||void 0,"aria-orientation":t.vertical?"vertical":"horizontal",onTouchstart:function(e){"number"==typeof r&&(n=r),function(r){t.disabled||t.readonly||(S.start(r),i=t.modelValue,o=A(i)?i.map(O):O(i),k.value="start")}(e)},onTouchmove:z,onTouchend:Y,onTouchcancel:Y,onClick:f},[H(e,r)])};return T(t.modelValue),v((function(){return t.modelValue})),function(){return c("div",{ref:x,style:N.value,class:_({vertical:t.vertical,disabled:t.disabled}),onClick:B},[c("div",{class:_("bar"),style:C.value},[t.range?[I(0),I(1)]:I()])])}}});t("S",y(S))}}}))}();