@xysfe/actui
Version:
A fantastic mobile ui lib implement by Vue
1 lines • 133 kB
JavaScript
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.GoldFinanceV2=e():t.GoldFinanceV2=e()}("undefined"!=typeof self?self:this,function(){return function(t){function e(n){if(i[n])return i[n].exports;var r=i[n]={i:n,l:!1,exports:{}};return t[n].call(r.exports,r,r.exports,e),r.l=!0,r.exports}var i={};return e.m=t,e.c=i,e.d=function(t,i,n){e.o(t,i)||Object.defineProperty(t,i,{configurable:!1,enumerable:!0,get:n})},e.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(i,"a",i),i},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="../lib",e(e.s=2077)}({0:function(t,e){var i=t.exports={version:"2.6.12"};"number"==typeof __e&&(__e=i)},1:function(t,e,i){"use strict";function n(t,e,i,n,r,o,s,a){t=t||{};var c=typeof t.default;"object"!==c&&"function"!==c||(t=t.default);var l="function"==typeof t?t.options:t;e&&(l.render=e,l.staticRenderFns=i,l._compiled=!0),n&&(l.functional=!0),o&&(l._scopeId=o);var h;if(s?(h=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},l._ssrRegister=h):r&&(h=a?function(){r.call(this,this.$root.$options.shadowRoot)}:r),h)if(l.functional){l._injectStyles=h;var u=l.render;l.render=function(t,e){return h.call(e),u(t,e)}}else{var p=l.beforeCreate;l.beforeCreate=p?[].concat(p,h):[h]}return{exports:t,options:l}}e.a=n},10:function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},100:function(t,e,i){t.exports={default:i(101),__esModule:!0}},101:function(t,e,i){i(55),t.exports=i(0).Object.getOwnPropertySymbols},102:function(t,e,i){"use strict";function n(t){var e={},i={},n={};for(var c in t)if(t.hasOwnProperty(c))if(-1!==a.indexOf(c))e[c]=t[c];else if(s.test(c)){var l=s.exec(c)[1];l=Object(o.a)(l),n[l]=t[c]}else i[c]=t[c];return e.on=Object(r.a)(n,e.on),e.props=Object(r.a)(i,e.props),e}e.a=n;var r=i(62),o=i(103),s=new RegExp(/^on(.+)/),a=["class","style","attrs","props","domProps","on","nativeOn","directives","scopedSlots","slot","key","ref","refInFor"]},103:function(t,e,i){"use strict";function n(t,e){var i=c(t,e);return i.charAt(0).toLowerCase()+i.slice(1)}e.a=n;var r=i(28),o=i.n(r),s=i(4),a=function(t){for(var e=!1,i=!1,n=!1,r=0;r<t.length;r++){var o=t[r];e&&/[a-zA-Z]/.test(o)&&o.toUpperCase()===o?(t=t.slice(0,r)+"-"+t.slice(r),e=!1,n=i,i=!0,r++):i&&n&&/[a-zA-Z]/.test(o)&&o.toLowerCase()===o?(t=t.slice(0,r-1)+"-"+t.slice(r-1),n=i,i=!1,e=!0):(e=o.toLowerCase()===o&&o.toUpperCase()!==o,n=i,i=o.toUpperCase()===o&&o.toLowerCase()!==o)}return t},c=function(t,e){if("string"!=typeof t&&!Object(s.p)(t))throw new TypeError("Expected the input to be `string | string[]`");e=o()({pascalCase:!1},e);return t=Array.isArray(t)?t.map(function(t){return t.trim()}).filter(function(t){return t.length}).join("-"):t.trim(),0===t.length?"":1===t.length?e.pascalCase?t.toUpperCase():t.toLowerCase():(t!==t.toLowerCase()&&(t=a(t)),t=t.replace(/^[_.\- ]+/,"").toLowerCase().replace(/[_.\- ]+(\w|$)/g,function(t,e){return e.toUpperCase()}).replace(/\d+(\w|$)/g,function(t){return t.toUpperCase()}),function(t){return e.pascalCase?t.charAt(0).toUpperCase()+t.slice(1):t}(t))}},104:function(t,e,i){"use strict";function n(t,e,i,n){var o=void 0,s=void 0,a=new t({render:function(t){var i=s&&s(t);return i&&!Object(r.p)(i)&&(i=[i]),t(e,o,i||[])},methods:{init:function(){document.body.appendChild(this.$el)},destroy:function(){this.$destroy(),document.body.removeChild(this.$el)}}});return a.updateRenderData=function(t,e){o=t,s=e},a.updateRenderData(i,n),a.$mount(),a.init(),a.$children[0]}e.a=n;var r=i(4)},106:function(t,e,i){"use strict";e.__esModule=!0;var n=i(28),r=function(t){return t&&t.__esModule?t:{default:t}}(n);e.default=r.default||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n]=i[n])}return t}},107:function(t,e,i){var n=i(26),r=i(3)("toStringTag"),o="Arguments"==n(function(){return arguments}()),s=function(t,e){try{return t[e]}catch(t){}};t.exports=function(t){var e,i,a;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(i=s(e=Object(t),r))?i:o?n(e):"Object"==(a=n(e))&&"function"==typeof e.callee?"Arguments":a}},11:function(t,e,i){var n=i(47),r=i(29);t.exports=function(t){return n(r(t))}},110:function(t,e,i){var n=i(9),r=i(40),o=i(3)("species");t.exports=function(t,e){var i,s=n(t).constructor;return void 0===s||void 0==(i=n(s)[o])?e:r(i)}},111:function(t,e,i){var n,r,o,s=i(38),a=i(146),c=i(60),l=i(41),h=i(2),u=h.process,p=h.setImmediate,f=h.clearImmediate,d=h.MessageChannel,m=h.Dispatch,v=0,g={},y=function(){var t=+this;if(g.hasOwnProperty(t)){var e=g[t];delete g[t],e()}},b=function(t){y.call(t.data)};p&&f||(p=function(t){for(var e=[],i=1;arguments.length>i;)e.push(arguments[i++]);return g[++v]=function(){a("function"==typeof t?t:Function(t),e)},n(v),v},f=function(t){delete g[t]},"process"==i(26)(u)?n=function(t){u.nextTick(s(y,t,1))}:m&&m.now?n=function(t){m.now(s(y,t,1))}:d?(r=new d,o=r.port2,r.port1.onmessage=b,n=s(o.postMessage,o,1)):h.addEventListener&&"function"==typeof postMessage&&!h.importScripts?(n=function(t){h.postMessage(t+"","*")},h.addEventListener("message",b,!1)):n="onreadystatechange"in l("script")?function(t){c.appendChild(l("script")).onreadystatechange=function(){c.removeChild(this),y.call(t)}}:function(t){setTimeout(s(y,t,1),0)}),t.exports={set:p,clear:f}},112:function(t,e){t.exports=function(t){try{return{e:!1,v:t()}}catch(t){return{e:!0,v:t}}}},113:function(t,e,i){var n=i(9),r=i(10),o=i(68);t.exports=function(t,e){if(n(t),r(e)&&e.constructor===t)return e;var i=o.f(t);return(0,i.resolve)(e),i.promise}},115:function(t,e,i){var n=i(107),r=i(3)("iterator"),o=i(18);t.exports=i(0).getIteratorMethod=function(t){if(void 0!=t)return t[r]||t["@@iterator"]||o[n(t)]}},118:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=i(154);e.default=n.a},12:function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},123:function(t,e,i){var n=i(38),r=i(136),o=i(137),s=i(9),a=i(59),c=i(115),l={},h={},e=t.exports=function(t,e,i,u,p){var f,d,m,v,g=p?function(){return t}:c(t),y=n(i,u,e?2:1),b=0;if("function"!=typeof g)throw TypeError(t+" is not iterable!");if(o(g)){for(f=a(t.length);f>b;b++)if((v=e?y(s(d=t[b])[0],d[1]):y(t[b]))===l||v===h)return v}else for(m=g.call(t);!(d=m.next()).done;)if((v=r(m,y,d.value,e))===l||v===h)return v};e.BREAK=l,e.RETURN=h},124:function(t,e,i){t.exports={default:i(186),__esModule:!0}},1243:function(t,e,i){t.exports={default:i(1244),__esModule:!0}},1244:function(t,e,i){i(1245),t.exports=i(0).Object.values},1245:function(t,e,i){var n=i(13),r=i(1246)(!1);n(n.S,"Object",{values:function(t){return r(t)}})},1246:function(t,e,i){var n=i(5),r=i(15),o=i(11),s=i(25).f;t.exports=function(t){return function(e){for(var i,a=o(e),c=r(a),l=c.length,h=0,u=[];l>h;)i=c[h++],n&&!s.call(a,i)||u.push(t?[i,a[i]]:a[i]);return u}}},13:function(t,e,i){var n=i(2),r=i(0),o=i(38),s=i(7),a=i(6),c=function(t,e,i){var l,h,u,p=t&c.F,f=t&c.G,d=t&c.S,m=t&c.P,v=t&c.B,g=t&c.W,y=f?r:r[e]||(r[e]={}),b=y.prototype,x=f?n:d?n[e]:(n[e]||{}).prototype;f&&(i=e);for(l in i)(h=!p&&x&&void 0!==x[l])&&a(y,l)||(u=h?x[l]:i[l],y[l]=f&&"function"!=typeof x[l]?i[l]:v&&h?o(u,n):g&&x[l]==u?function(t){var e=function(e,i,n){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,i)}return new t(e,i,n)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(u):m&&"function"==typeof u?o(Function.call,u):u,m&&((y.virtual||(y.virtual={}))[l]=u,t&c.R&&b&&!b[l]&&s(b,l,u)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,t.exports=c},136:function(t,e,i){var n=i(9);t.exports=function(t,e,i,r){try{return r?e(n(i)[0],i[1]):e(i)}catch(e){var o=t.return;throw void 0!==o&&n(o.call(t)),e}}},137:function(t,e,i){var n=i(18),r=i(3)("iterator"),o=Array.prototype;t.exports=function(t){return void 0!==t&&(n.Array===t||o[r]===t)}},139:function(t,e){t.exports=function(t,e,i,n){if(!(t instanceof e)||void 0!==n&&n in t)throw TypeError(i+": incorrect invocation!");return t}},14:function(t,e,i){"use strict";function n(t,e){return function(i,n){var s=this,a=Object(r.a)(i),c=Object(o.a)(e,t,a,n),l=c.$parent,h=c.remove,u=c.show,p=c.hide;return c.remove=function(){c.$removed=!0,h&&h.call(this),l.destroy()},c.show=function(){return u&&u.call.apply(u,[this].concat(Array.prototype.slice.call(arguments))),this},c.hide=function(){return p&&p.call.apply(p,[this].concat(Array.prototype.slice.call(arguments))),this},s&&s._isVue&&s.$once("hook:beforeDestroy",function(){c.$removed||c.remove()}),c}}e.a=n;var r=i(102),o=i(104)},140:function(t,e,i){var n=i(7);t.exports=function(t,e,i){for(var r in e)i&&t[r]?t[r]=e[r]:n(t,r,e[r]);return t}},141:function(t,e,i){var n=i(3)("iterator"),r=!1;try{var o=[7][n]();o.return=function(){r=!0},Array.from(o,function(){throw 2})}catch(t){}t.exports=function(t,e){if(!e&&!r)return!1;var i=!1;try{var o=[7],s=o[n]();s.next=function(){return{done:i=!0}},o[n]=function(){return s},t(o)}catch(t){}return i}},142:function(t,e,i){"use strict";var n=i(2),r=i(0),o=i(8),s=i(5),a=i(3)("species");t.exports=function(t){var e="function"==typeof r[t]?r[t]:n[t];s&&e&&!e[a]&&o.f(e,a,{configurable:!0,get:function(){return this}})}},144:function(t,e,i){i(61),i(53),i(56),i(145),i(149),i(150),t.exports=i(0).Promise},145:function(t,e,i){"use strict";var n,r,o,s,a=i(16),c=i(2),l=i(38),h=i(107),u=i(13),p=i(10),f=i(40),d=i(139),m=i(123),v=i(110),g=i(111).set,y=i(147)(),b=i(68),x=i(112),w=i(148),_=i(113),S=c.TypeError,T=c.process,P=T&&T.versions,E=P&&P.v8||"",O=c.Promise,M="process"==h(T),k=function(){},C=r=b.f,A=!!function(){try{var t=O.resolve(1),e=(t.constructor={})[i(3)("species")]=function(t){t(k,k)};return(M||"function"==typeof PromiseRejectionEvent)&&t.then(k)instanceof e&&0!==E.indexOf("6.6")&&-1===w.indexOf("Chrome/66")}catch(t){}}(),D=function(t){var e;return!(!p(t)||"function"!=typeof(e=t.then))&&e},I=function(t,e){if(!t._n){t._n=!0;var i=t._c;y(function(){for(var n=t._v,r=1==t._s,o=0;i.length>o;)!function(e){var i,o,s,a=r?e.ok:e.fail,c=e.resolve,l=e.reject,h=e.domain;try{a?(r||(2==t._h&&j(t),t._h=1),!0===a?i=n:(h&&h.enter(),i=a(n),h&&(h.exit(),s=!0)),i===e.promise?l(S("Promise-chain cycle")):(o=D(i))?o.call(i,c,l):c(i)):l(n)}catch(t){h&&!s&&h.exit(),l(t)}}(i[o++]);t._c=[],t._n=!1,e&&!t._h&&Y(t)})}},Y=function(t){g.call(c,function(){var e,i,n,r=t._v,o=X(t);if(o&&(e=x(function(){M?T.emit("unhandledRejection",r,t):(i=c.onunhandledrejection)?i({promise:t,reason:r}):(n=c.console)&&n.error&&n.error("Unhandled promise rejection",r)}),t._h=M||X(t)?2:1),t._a=void 0,o&&e.e)throw e.v})},X=function(t){return 1!==t._h&&0===(t._a||t._c).length},j=function(t){g.call(c,function(){var e;M?T.emit("rejectionHandled",t):(e=c.onrejectionhandled)&&e({promise:t,reason:t._v})})},W=function(t){var e=this;e._d||(e._d=!0,e=e._w||e,e._v=t,e._s=2,e._a||(e._a=e._c.slice()),I(e,!0))},L=function(t){var e,i=this;if(!i._d){i._d=!0,i=i._w||i;try{if(i===t)throw S("Promise can't be resolved itself");(e=D(t))?y(function(){var n={_w:i,_d:!1};try{e.call(t,l(L,n,1),l(W,n,1))}catch(t){W.call(n,t)}}):(i._v=t,i._s=1,I(i,!1))}catch(t){W.call({_w:i,_d:!1},t)}}};A||(O=function(t){d(this,O,"Promise","_h"),f(t),n.call(this);try{t(l(L,this,1),l(W,this,1))}catch(t){W.call(this,t)}},n=function(t){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},n.prototype=i(140)(O.prototype,{then:function(t,e){var i=C(v(this,O));return i.ok="function"!=typeof t||t,i.fail="function"==typeof e&&e,i.domain=M?T.domain:void 0,this._c.push(i),this._a&&this._a.push(i),this._s&&I(this,!1),i.promise},catch:function(t){return this.then(void 0,t)}}),o=function(){var t=new n;this.promise=t,this.resolve=l(L,t,1),this.reject=l(W,t,1)},b.f=C=function(t){return t===O||t===s?new o(t):r(t)}),u(u.G+u.W+u.F*!A,{Promise:O}),i(27)(O,"Promise"),i(142)("Promise"),s=i(0).Promise,u(u.S+u.F*!A,"Promise",{reject:function(t){var e=C(this);return(0,e.reject)(t),e.promise}}),u(u.S+u.F*(a||!A),"Promise",{resolve:function(t){return _(a&&this===s?O:this,t)}}),u(u.S+u.F*!(A&&i(141)(function(t){O.all(t).catch(k)})),"Promise",{all:function(t){var e=this,i=C(e),n=i.resolve,r=i.reject,o=x(function(){var i=[],o=0,s=1;m(t,!1,function(t){var a=o++,c=!1;i.push(void 0),s++,e.resolve(t).then(function(t){c||(c=!0,i[a]=t,--s||n(i))},r)}),--s||n(i)});return o.e&&r(o.v),i.promise},race:function(t){var e=this,i=C(e),n=i.reject,r=x(function(){m(t,!1,function(t){e.resolve(t).then(i.resolve,n)})});return r.e&&n(r.v),i.promise}})},146:function(t,e){t.exports=function(t,e,i){var n=void 0===i;switch(e.length){case 0:return n?t():t.call(i);case 1:return n?t(e[0]):t.call(i,e[0]);case 2:return n?t(e[0],e[1]):t.call(i,e[0],e[1]);case 3:return n?t(e[0],e[1],e[2]):t.call(i,e[0],e[1],e[2]);case 4:return n?t(e[0],e[1],e[2],e[3]):t.call(i,e[0],e[1],e[2],e[3])}return t.apply(i,e)}},147:function(t,e,i){var n=i(2),r=i(111).set,o=n.MutationObserver||n.WebKitMutationObserver,s=n.process,a=n.Promise,c="process"==i(26)(s);t.exports=function(){var t,e,i,l=function(){var n,r;for(c&&(n=s.domain)&&n.exit();t;){r=t.fn,t=t.next;try{r()}catch(n){throw t?i():e=void 0,n}}e=void 0,n&&n.enter()};if(c)i=function(){s.nextTick(l)};else if(!o||n.navigator&&n.navigator.standalone)if(a&&a.resolve){var h=a.resolve(void 0);i=function(){h.then(l)}}else i=function(){r.call(n,l)};else{var u=!0,p=document.createTextNode("");new o(l).observe(p,{characterData:!0}),i=function(){p.data=u=!u}}return function(n){var r={fn:n,next:void 0};e&&(e.next=r),t||(t=r,i()),e=r}}},148:function(t,e,i){var n=i(2),r=n.navigator;t.exports=r&&r.userAgent||""},149:function(t,e,i){"use strict";var n=i(13),r=i(0),o=i(2),s=i(110),a=i(113);n(n.P+n.R,"Promise",{finally:function(t){var e=s(this,r.Promise||o.Promise),i="function"==typeof t;return this.then(i?function(i){return a(e,t()).then(function(){return i})}:t,i?function(i){return a(e,t()).then(function(){throw i})}:t)}})},15:function(t,e,i){var n=i(50),r=i(33);t.exports=Object.keys||function(t){return n(t,r)}},150:function(t,e,i){"use strict";var n=i(13),r=i(68),o=i(112);n(n.S,"Promise",{try:function(t){var e=r.f(this),i=o(t);return(i.e?e.reject:e.resolve)(i.v),e.promise}})},154:function(t,e,i){"use strict";function n(){return window.performance&&window.performance.now?window.performance.now()+window.performance.timing.navigationStart:+new Date}function r(t){for(var e=arguments.length,i=Array(e>1?e-1:0),n=1;n<e;n++)i[n-1]=arguments[n];for(var r=0;r<i.length;r++){var o=i[r];for(var s in o)t[s]=o[s]}return t}function o(t){return void 0===t||null===t}function s(t,e){return Math.sqrt(t*t+e*e)}function a(t){return!1!==j&&("standard"===j?"transitionEnd"===t?"transitionend":t:j+t.charAt(0).toUpperCase()+t.substr(1))}function c(t,e,i,n){t.addEventListener(e,i,{passive:!1,capture:!!n})}function l(t,e,i,n){t.removeEventListener(e,i,{passive:!1,capture:!!n})}function h(t){for(var e=0,i=0;t;)e-=t.offsetLeft,i-=t.offsetTop,t=t.offsetParent;return{left:e,top:i}}function u(t){var e=t.getBoundingClientRect();return{left:-(e.left+window.pageXOffset),top:-(e.top+window.pageYOffset)}}function p(t){if(t instanceof window.SVGElement){var e=t.getBoundingClientRect();return{top:e.top,left:e.left,width:e.width,height:e.height}}return{top:t.offsetTop,left:t.offsetLeft,width:t.offsetWidth,height:t.offsetHeight}}function f(t,e){for(var i in e)if(e[i].test(t[i]))return!0;return!1}function d(t,e){var i=document.createEvent("Event");i.initEvent(e,!0,!0),i.pageX=t.pageX,i.pageY=t.pageY,t.target.dispatchEvent(i)}function m(t){function e(){s=document.createEvent("Event"),s.initEvent(i,a,c),r(s,o)}var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"click",n=void 0;"mouseup"===t.type||"mousecancel"===t.type?n=t:"touchend"!==t.type&&"touchcancel"!==t.type||(n=t.changedTouches[0]);var o={};n&&(o.screenX=n.screenX||0,o.screenY=n.screenY||0,o.clientX=n.clientX||0,o.clientY=n.clientY||0);var s=void 0,a=!0,c=!0;if("undefined"!=typeof MouseEvent)try{s=new MouseEvent(i,r({bubbles:a,cancelable:c},o))}catch(t){e()}else e();s.forwardedTouchEvent=!0,s._constructed=!0,t.target.dispatchEvent(s)}function v(t){m(t,"dblclick")}function g(t,e){e.firstChild?y(t,e.firstChild):e.appendChild(t)}function y(t,e){e.parentNode.insertBefore(t,e)}function b(t,e){t.removeChild(e)}function x(t,e,i,n,r,o,s){var a=t-e,c=Math.abs(a)/i,l=s.deceleration,h=s.itemHeight,u=s.swipeBounceTime,p=s.wheel,f=s.swipeTime,d=f,m=p?4:15,v=t+c/l*(a<0?-1:1);return p&&h&&(v=Math.round(v/h)*h),v<n?(v=o?Math.max(n-o/4,n-o/m*c):n,d=u):v>r&&(v=o?Math.min(r+o/4,r+o/m*c):r,d=u),{destination:Math.round(v),duration:d}}function w(){}function _(t){console.error("[BScroll warn]: "+t)}function S(t,e){if(!t)throw new Error("[BScroll] "+e)}function T(t){var e=document.createElement("div"),i=document.createElement("div");return e.style.cssText="position:absolute;z-index:9999;pointerEvents:none",i.style.cssText="box-sizing:border-box;position:absolute;background:rgba(0,0,0,0.5);border:1px solid rgba(255,255,255,0.9);border-radius:3px;",i.className="bscroll-indicator","horizontal"===t?(e.style.cssText+=";height:7px;left:2px;right:2px;bottom:0",i.style.height="100%",e.className="bscroll-horizontal-scrollbar"):(e.style.cssText+=";width:7px;bottom:2px;top:2px;right:1px",i.style.width="100%",e.className="bscroll-vertical-scrollbar"),e.style.cssText+=";overflow:hidden",e.appendChild(i),e}function P(t,e){this.wrapper=e.el,this.wrapperStyle=this.wrapper.style,this.indicator=this.wrapper.children[0],this.indicatorStyle=this.indicator.style,this.scroller=t,this.direction=e.direction,e.fade?(this.visible=0,this.wrapperStyle.opacity="0"):this.visible=1,this.sizeRatioX=1,this.sizeRatioY=1,this.maxPosX=0,this.maxPosY=0,this.x=0,this.y=0,e.interactive&&this._addDOMEvents()}function E(t){if(t&&t.classList)return t.classList.contains("tombstone")}function O(t,e){var i=this;this.options=e,S("function"==typeof this.options.createTombstone,"Infinite scroll need createTombstone Function to create tombstone"),S("function"==typeof this.options.fetch,"Infinite scroll need fetch Function to fetch new data."),S("function"==typeof this.options.render,"Infinite scroll need render Function to render each item."),this.firstAttachedItem=0,this.lastAttachedItem=0,this.anchorScrollTop=0,this.anchorItem={index:0,offset:0},this.tombstoneHeight=0,this.tombstoneWidth=0,this.tombstones=[],this.items=[],this.loadedItems=0,this.requestInProgress=!1,this.hasMore=!0,this.scroller=t,this.wrapperEl=this.scroller.wrapper,this.scrollerEl=this.scroller.scroller,this.scroller.on("scroll",function(){i.onScroll()}),this.scroller.on("resize",function(){i.onResize()}),this.onResize()}function M(t,e){this.wrapper="string"==typeof t?document.querySelector(t):t,this.wrapper||_("Can not resolve the wrapper DOM."),this.scroller=this.wrapper.children[0],this.scroller||_("The wrapper need at least one child element to be scroller."),this.scrollerStyle=this.scroller.style,this._init(t,e)}var k=function(){function t(t,e){var i=[],n=!0,r=!1,o=void 0;try{for(var s,a=t[Symbol.iterator]();!(n=(s=a.next()).done)&&(i.push(s.value),!e||i.length!==e);n=!0);}catch(t){r=!0,o=t}finally{try{!n&&a.return&&a.return()}finally{if(r)throw o}}return i}return function(e,i){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,i);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),C=function(t){if(Array.isArray(t)){for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}return Array.from(t)},A="undefined"!=typeof window,D=A&&navigator.userAgent.toLowerCase(),I=D&&/wechatdevtools/.test(D),Y=D&&D.indexOf("android")>0,X=A&&document.createElement("div").style,j=function(){if(!A)return!1;var t={webkit:"webkitTransform",Moz:"MozTransform",O:"OTransform",ms:"msTransform",standard:"transform"};for(var e in t)if(void 0!==X[t[e]])return e;return!1}(),W=a("transform"),L=A&&a("perspective")in X,R=A&&("ontouchstart"in window||I),N=!1!==W,F=A&&a("transition")in X,V={transform:W,transitionTimingFunction:a("transitionTimingFunction"),transitionDuration:a("transitionDuration"),transitionDelay:a("transitionDelay"),transformOrigin:a("transformOrigin"),transitionEnd:a("transitionEnd")},H=1,z={touchstart:H,touchmove:H,touchend:H,mousedown:2,mousemove:2,mouseup:2},U={startX:0,startY:0,scrollX:!1,scrollY:!0,freeScroll:!1,directionLockThreshold:5,eventPassthrough:"",click:!1,tap:!1,bounce:!0,bounceTime:800,momentum:!0,momentumLimitTime:300,momentumLimitDistance:15,swipeTime:2500,swipeBounceTime:500,deceleration:.0015,flickLimitTime:200,flickLimitDistance:100,resizePolling:60,probeType:0,preventDefault:!0,preventDefaultException:{tagName:/^(INPUT|TEXTAREA|BUTTON|SELECT)$/},HWCompositing:!0,useTransition:!0,useTransform:!0,bindToWrapper:!1,disableMouse:R,disableTouch:!R,observeDOM:!0,autoBlur:!0,wheel:!1,snap:!1,scrollbar:!1,pullDownRefresh:!1,pullUpLoad:!1,mouseWheel:!1,stopPropagation:!1,zoom:!1,infinity:!1,dblclick:!1},$={swipe:{style:"cubic-bezier(0.23, 1, 0.32, 1)",fn:function(t){return 1+--t*t*t*t*t}},swipeBounce:{style:"cubic-bezier(0.25, 0.46, 0.45, 0.94)",fn:function(t){return t*(2-t)}},bounce:{style:"cubic-bezier(0.165, 0.84, 0.44, 1)",fn:function(t){return 1- --t*t*t*t}}},B=function(){return A?window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||function(t){return window.setTimeout(t,(t.interval||100/60)/2)}:w}(),G=function(){return A?window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.oCancelAnimationFrame||function(t){window.clearTimeout(t)}:w}(),q=1,J=-1,Z=1,K=-1,Q=1,tt=3;P.prototype.handleEvent=function(t){switch(t.type){case"touchstart":case"mousedown":this._start(t);break;case"touchmove":case"mousemove":this._move(t);break;case"touchend":case"mouseup":case"touchcancel":case"mousecancel":this._end(t)}},P.prototype.refresh=function(){this._shouldShow()&&(this.transitionTime(),this._calculate(),this.updatePosition())},P.prototype.fade=function(t,e){var i=this;if(!e||this.visible){var n=t?250:500;t=t?"1":"0",this.wrapperStyle[V.transitionDuration]=n+"ms",clearTimeout(this.fadeTimeout),this.fadeTimeout=setTimeout(function(){i.wrapperStyle.opacity=t,i.visible=+t},0)}},P.prototype.updatePosition=function(){if("vertical"===this.direction){var t=Math.round(this.sizeRatioY*this.scroller.y);if(t<0){this.transitionTime(500);var e=Math.max(this.indicatorHeight+3*t,8);this.indicatorStyle.height=e+"px",t=0}else if(t>this.maxPosY){this.transitionTime(500);var i=Math.max(this.indicatorHeight-3*(t-this.maxPosY),8);this.indicatorStyle.height=i+"px",t=this.maxPosY+this.indicatorHeight-i}else this.indicatorStyle.height=this.indicatorHeight+"px";this.y=t,this.scroller.options.useTransform?this.indicatorStyle[V.transform]="translateY("+t+"px)"+this.scroller.translateZ:this.indicatorStyle.top=t+"px"}else{var n=Math.round(this.sizeRatioX*this.scroller.x);if(n<0){this.transitionTime(500);var r=Math.max(this.indicatorWidth+3*n,8);this.indicatorStyle.width=r+"px",n=0}else if(n>this.maxPosX){this.transitionTime(500);var o=Math.max(this.indicatorWidth-3*(n-this.maxPosX),8);this.indicatorStyle.width=o+"px",n=this.maxPosX+this.indicatorWidth-o}else this.indicatorStyle.width=this.indicatorWidth+"px";this.x=n,this.scroller.options.useTransform?this.indicatorStyle[V.transform]="translateX("+n+"px)"+this.scroller.translateZ:this.indicatorStyle.left=n+"px"}},P.prototype.transitionTime=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.indicatorStyle[V.transitionDuration]=t+"ms"},P.prototype.transitionTimingFunction=function(t){this.indicatorStyle[V.transitionTimingFunction]=t},P.prototype.destroy=function(){this._removeDOMEvents(),this.wrapper.parentNode.removeChild(this.wrapper)},P.prototype._start=function(t){var e=t.touches?t.touches[0]:t;t.preventDefault(),t.stopPropagation(),this.transitionTime(),this.initiated=!0,this.moved=!1,this.lastPointX=e.pageX,this.lastPointY=e.pageY,this.startTime=n(),this._handleMoveEvents(c),this.scroller.trigger("beforeScrollStart")},P.prototype._move=function(t){var e=t.touches?t.touches[0]:t;t.preventDefault(),t.stopPropagation(),this.moved||this.scroller.trigger("scrollStart"),this.moved=!0;var i=e.pageX-this.lastPointX;this.lastPointX=e.pageX;var n=e.pageY-this.lastPointY;this.lastPointY=e.pageY;var r=this.x+i,o=this.y+n;this._pos(r,o)},P.prototype._end=function(t){if(this.initiated){this.initiated=!1,t.preventDefault(),t.stopPropagation(),this._handleMoveEvents(l);var e=this.scroller.options.snap;if(e){var i=e.speed,n=e.easing,r=void 0===n?$.bounce:n,o=this.scroller._nearestSnap(this.scroller.x,this.scroller.y),s=i||Math.max(Math.max(Math.min(Math.abs(this.scroller.x-o.x),1e3),Math.min(Math.abs(this.scroller.y-o.y),1e3)),300);this.scroller.x===o.x&&this.scroller.y===o.y||(this.scroller.directionX=0,this.scroller.directionY=0,this.scroller.currentPage=o,this.scroller.scrollTo(o.x,o.y,s,r))}this.moved&&this.scroller.trigger("scrollEnd",{x:this.scroller.x,y:this.scroller.y})}},P.prototype._pos=function(t,e){t<0?t=0:t>this.maxPosX&&(t=this.maxPosX),e<0?e=0:e>this.maxPosY&&(e=this.maxPosY),t=Math.round(t/this.sizeRatioX),e=Math.round(e/this.sizeRatioY),this.scroller.scrollTo(t,e),this.scroller.trigger("scroll",{x:this.scroller.x,y:this.scroller.y})},P.prototype._shouldShow=function(){return"vertical"===this.direction&&this.scroller.hasVerticalScroll||"horizontal"===this.direction&&this.scroller.hasHorizontalScroll?(this.wrapper.style.display="",!0):(this.wrapper.style.display="none",!1)},P.prototype._calculate=function(){if("vertical"===this.direction){var t=this.wrapper.clientHeight;this.indicatorHeight=Math.max(Math.round(t*t/(this.scroller.scrollerHeight||t||1)),8),this.indicatorStyle.height=this.indicatorHeight+"px",this.maxPosY=t-this.indicatorHeight,this.sizeRatioY=this.maxPosY/this.scroller.maxScrollY}else{var e=this.wrapper.clientWidth;this.indicatorWidth=Math.max(Math.round(e*e/(this.scroller.scrollerWidth||e||1)),8),this.indicatorStyle.width=this.indicatorWidth+"px",this.maxPosX=e-this.indicatorWidth,this.sizeRatioX=this.maxPosX/this.scroller.maxScrollX}},P.prototype._addDOMEvents=function(){var t=c;this._handleDOMEvents(t)},P.prototype._removeDOMEvents=function(){var t=l;this._handleDOMEvents(t),this._handleMoveEvents(t)},P.prototype._handleMoveEvents=function(t){this.scroller.options.disableTouch||t(window,"touchmove",this),this.scroller.options.disableMouse||t(window,"mousemove",this)},P.prototype._handleDOMEvents=function(t){this.scroller.options.disableTouch||(t(this.indicator,"touchstart",this),t(window,"touchend",this)),this.scroller.options.disableMouse||(t(this.indicator,"mousedown",this),t(window,"mouseup",this))};var et=2e3;O.prototype.onScroll=function(){var t=-this.scroller.y,e=t-this.anchorScrollTop;this.anchorItem=0===t?{index:0,offset:0}:this._calculateAnchoredItem(this.anchorItem,e),this.anchorScrollTop=t;var i=this._calculateAnchoredItem(this.anchorItem,this.wrapperEl.offsetHeight),n=this.anchorItem.index,r=i.index;e<0?(n-=30,r+=10):(n-=10,r+=30),this.fill(n,r),this.maybeRequestContent()},O.prototype.onResize=function(){var t=this.options.createTombstone();t.style.position="absolute",this.scrollerEl.appendChild(t),t.style.display="",this.tombstoneHeight=t.offsetHeight,this.tombstoneWidth=t.offsetWidth,this.scrollerEl.removeChild(t);for(var e=0;e<this.items.length;e++)this.items[e].height=this.items[e].width=0;this.onScroll()},O.prototype.fill=function(t,e){this.firstAttachedItem=Math.max(0,t),this.hasMore||(e=Math.min(e,this.items.length)),this.lastAttachedItem=e,this.attachContent()},O.prototype.maybeRequestContent=function(){var t=this;if(!this.requestInProgress&&this.hasMore){var e=this.lastAttachedItem-this.loadedItems;e<=0||(this.requestInProgress=!0,this.options.fetch(e).then(function(e){if(t.requestInProgress=!1,e)t.addContent(e);else{t.hasMore=!1;var i=t._removeTombstones(),n=0;t.anchorItem.index<=t.items.length?(n=t._fixScrollPosition(),t._setupAnimations({},n),t.scroller.resetPosition(t.scroller.options.bounceTime)):(t.anchorItem.index-=i,n=t._fixScrollPosition(),t._setupAnimations({},n),t.scroller.stop(),t.scroller.resetPosition(),t.onScroll())}}))}},O.prototype.addContent=function(t){for(var e=0;e<t.length;e++)this.items.length<=this.loadedItems&&this._addItem(),this.items[this.loadedItems++].data=t[e];this.attachContent(),this.maybeRequestContent()},O.prototype.attachContent=function(){var t=this._collectUnusedNodes(),e=this._createDOMNodes(t);this._cleanupUnusedNodes(t),this._cacheNodeSize();var i=this._fixScrollPosition();this._setupAnimations(e,i)},O.prototype.resetMore=function(){this.hasMore=!0},O.prototype._removeTombstones=function(){for(var t=void 0,e=0,i=this.items.length,n=0;n<i;n++){var r=this.items[n].node,o=this.items[n].data;r&&!E(r)||o||(t||(t=n),r&&this.scrollerEl.removeChild(r))}return e=i-t,this.items.splice(t),this.lastAttachedItem=Math.min(this.lastAttachedItem,this.items.length),e},O.prototype._collectUnusedNodes=function(){for(var t=[],e=0;e<this.items.length;e++)if(e!==this.firstAttachedItem){var i=this.items[e].node;i&&(E(i)?(this.tombstones.push(i),this.tombstones[this.tombstones.length-1].style.display="none"):t.push(i)),this.items[e].node=null}else e=this.lastAttachedItem-1;return t},O.prototype._createDOMNodes=function(t){for(var e={},i=this.firstAttachedItem;i<this.lastAttachedItem;i++){for(;this.items.length<=i;)this._addItem();var n=this.items[i].node,r=this.items[i].data;if(n){if(!E(n)||!r)continue;n.style.zIndex=1,e[i]=[n,this.items[i].top-this.anchorScrollTop],this.items[i].node=null}var o=r?this.options.render(r,t.pop()):this._getTombStone();o.style.position="absolute",this.items[i].top=-1,this.scrollerEl.appendChild(o),this.items[i].node=o}return e},O.prototype._cleanupUnusedNodes=function(t){for(;t.length;)this.scrollerEl.removeChild(t.pop())},O.prototype._cacheNodeSize=function(){for(var t=this.firstAttachedItem;t<this.lastAttachedItem;t++)this.items[t].data&&!this.items[t].height&&(this.items[t].height=this.items[t].node.offsetHeight,this.items[t].width=this.items[t].node.offsetWidth)},O.prototype._fixScrollPosition=function(){this.anchorScrollTop=0;for(var t=0;t<this.anchorItem.index;t++)this.anchorScrollTop+=this.items[t].height||this.tombstoneHeight;this.anchorScrollTop+=this.anchorItem.offset;for(var e=this.anchorScrollTop-this.anchorItem.offset,i=this.anchorItem.index;i>this.firstAttachedItem;)e-=this.items[i-1].height||this.tombstoneHeight,i--;return e},O.prototype._setupAnimations=function(t,e){var i=this;for(var n in t){var r=t[n];this.items[n].node.style.transform="translateY("+(this.anchorScrollTop+r[1])+"px) scale("+this.tombstoneWidth/this.items[n].width+", "+this.tombstoneHeight/this.items[n].height+")",this.items[n].node.offsetTop,r[0].offsetTop,this.items[n].node.style.transition="transform 200ms"}for(var o=this.firstAttachedItem;o<this.lastAttachedItem;o++){var s=t[o];if(s){var a=s[0];a.style.transition="transform 200ms, opacity 200ms",a.style.transform="translateY("+e+"px) scale("+this.items[o].width/this.tombstoneWidth+", "+this.items[o].height/this.tombstoneHeight+")",a.style.opacity=0}e!==this.items[o].top&&(s||(this.items[o].node.style.transition=""),this.items[o].node.style.transform="translateY("+e+"px)"),this.items[o].top=e,e+=this.items[o].height||this.tombstoneHeight}this.scroller.maxScrollY=-(e-this.wrapperEl.offsetHeight+(this.hasMore?et:0)),setTimeout(function(){for(var e in t){var n=t[e];n[0].style.display="none",i.tombstones.push(n[0])}},200)},O.prototype._getTombStone=function(){var t=this.tombstones.pop();return t?(t.style.display="",t.style.opacity=1,t.style.transform="",t.style.transition="",t):this.options.createTombstone()},O.prototype._addItem=function(){this.items.push({data:null,node:null,height:0,width:0,top:0})},O.prototype._calculateAnchoredItem=function(t,e){if(0===e)return t;var i=t.index,n=0;if((e+=t.offset)<0){for(;e<0&&i>0&&this.items[i-1].height;)e+=this.items[i-1].height,i--;n=Math.max(-i,Math.ceil(Math.min(e,0)/this.tombstoneHeight))}else{for(;e>0&&i<this.items.length&&this.items[i].height&&this.items[i].height<e;)e-=this.items[i].height,i++;(i>=this.items.length||!this.items[i].height)&&(n=Math.floor(Math.max(e,0)/this.tombstoneHeight))}return i+=n,e-=n*this.tombstoneHeight,{index:i,offset:e}},function(t){t.prototype._init=function(t,e){this._handleOptions(e),this._events={},this.x=0,this.y=0,this.directionX=0,this.directionY=0,this.setScale(1),this._addDOMEvents(),this._initExtFeatures(),this._watchTransition(),this.options.observeDOM&&this._initDOMObserver(),this.options.autoBlur&&this._handleAutoBlur(),this.refresh(),this.options.snap||this.scrollTo(this.options.startX,this.options.startY),this.enable()},t.prototype.setScale=function(t){this.lastScale=o(this.scale)?t:this.scale,this.scale=t},t.prototype._handleOptions=function(t){this.options=r({},U,t),this.translateZ=this.options.HWCompositing&&L?" translateZ(0)":"",this.options.useTransition=this.options.useTransition&&F,this.options.useTransform=this.options.useTransform&&N,this.options.preventDefault=!this.options.eventPassthrough&&this.options.preventDefault,this.options.scrollX="horizontal"!==this.options.eventPassthrough&&this.options.scrollX,this.options.scrollY="vertical"!==this.options.eventPassthrough&&this.options.scrollY,this.options.freeScroll=this.options.freeScroll&&!this.options.eventPassthrough,this.options.directionLockThreshold=this.options.eventPassthrough?0:this.options.directionLockThreshold,!0===this.options.tap&&(this.options.tap="tap")},t.prototype._addDOMEvents=function(){var t=c;this._handleDOMEvents(t)},t.prototype._removeDOMEvents=function(){var t=l;this._handleDOMEvents(t)},t.prototype._handleDOMEvents=function(t){var e=this.options.bindToWrapper?this.wrapper:window;t(window,"orientationchange",this),t(window,"resize",this),this.options.click&&t(this.wrapper,"click",this,!0),this.options.disableMouse||(t(this.wrapper,"mousedown",this),t(e,"mousemove",this),t(e,"mousecancel",this),t(e,"mouseup",this)),R&&!this.options.disableTouch&&(t(this.wrapper,"touchstart",this),t(e,"touchmove",this),t(e,"touchcancel",this),t(e,"touchend",this)),t(this.scroller,V.transitionEnd,this)},t.prototype._initExtFeatures=function(){this.options.snap&&this._initSnap(),this.options.scrollbar&&this._initScrollbar(),this.options.pullUpLoad&&this._initPullUp(),this.options.pullDownRefresh&&this._initPullDown(),this.options.wheel&&this._initWheel(),this.options.mouseWheel&&this._initMouseWheel(),this.options.zoom&&this._initZoom(),this.options.infinity&&this._initInfinite()},t.prototype._watchTransition=function(){if("function"==typeof Object.defineProperty){var t=this,e=!1,i=this.useTransition?"isInTransition":"isAnimating";Object.defineProperty(this,i,{get:function(){return e},set:function(i){e=i;for(var n=t.scroller.children.length?t.scroller.children:[t.scroller],r=e&&!t.pulling?"none":"auto",o=0;o<n.length;o++)n[o].style.pointerEvents=r}})}},t.prototype._handleAutoBlur=function(){this.on("scrollStart",function(){var t=document.activeElement;!t||"INPUT"!==t.tagName&&"TEXTAREA"!==t.tagName||t.blur()})},t.prototype._initDOMObserver=function(){var t=this;if("undefined"!=typeof MutationObserver){var e=void 0,i=new MutationObserver(function(i){if(!t._shouldNotRefresh()){for(var n=!1,r=!1,o=0;o<i.length;o++){var s=i[o];if("attributes"!==s.type){n=!0;break}if(s.target!==t.scroller){r=!0;break}}n?t.refresh():r&&(clearTimeout(e),e=setTimeout(function(){t._shouldNotRefresh()||t.refresh()},60))}}),n={attributes:!0,childList:!0,subtree:!0};i.observe(this.scroller,n),this.on("destroy",function(){i.disconnect()})}else this._checkDOMUpdate()},t.prototype._shouldNotRefresh=function(){var t=this.x>this.minScrollX||this.x<this.maxScrollX||this.y>this.minScrollY||this.y<this.maxScrollY;return this.isInTransition||this.stopFromTransition||t},t.prototype._checkDOMUpdate=function(){function t(){if(!this.destroyed){i=p(this.scroller);var t=i.width,o=i.height;n===t&&r===o||this.refresh(),n=t,r=o,e.call(this)}}function e(){var e=this;setTimeout(function(){t.call(e)},1e3)}var i=p(this.scroller),n=i.width,r=i.height;e.call(this)},t.prototype.handleEvent=function(t){switch(t.type){case"touchstart":case"mousedown":this._start(t),this.options.zoom&&t.touches&&t.touches.length>1&&this._zoomStart(t);break;case"touchmove":case"mousemove":this.options.zoom&&t.touches&&t.touches.length>1?this._zoom(t):this._move(t);break;case"touchend":case"mouseup":case"touchcancel":case"mousecancel":this.scaled?this._zoomEnd(t):this._end(t);break;case"orientationchange":case"resize":this._resize();break;case"transitionend":case"webkitTransitionEnd":case"oTransitionEnd":case"MSTransitionEnd":this._transitionEnd(t);break;case"click":this.enabled&&!t._constructed&&(f(t.target,this.options.preventDefaultException)||(t.preventDefault(),t.stopPropagation()));break;case"wheel":case"DOMMouseScroll":case"mousewheel":this._onMouseWheel(t)}},t.prototype.refresh=function(){var t="static"===window.getComputedStyle(this.wrapper,null).position,e=p(this.wrapper);this.wrapperWidth=e.width,this.wrapperHeight=e.height;var i=p(this.scroller);this.scrollerWidth=Math.round(i.width*this.scale),this.scrollerHeight=Math.round(i.height*this.scale),this.relativeX=i.left,this.relativeY=i.top,t&&(this.relativeX-=e.left,this.relativeY-=e.top),this.minScrollX=0,this.minScrollY=0;var n=this.options.wheel;n?(this.items=this.scroller.children,this.options.itemHeight=this.itemHeight=this.items.length?this.scrollerHeight/this.items.length:0,void 0===this.selectedIndex&&(this.selectedIndex=n.selectedIndex||0),this.options.startY=-this.selectedIndex*this.itemHeight,this.maxScrollX=0,this.maxScrollY=-this.itemHeight*(this.items.length-1)):(this.maxScrollX=this.wrapperWidth-this.scrollerWidth,this.options.infinity||(this.maxScrollY=this.wrapperHeight-this.scrollerHeight),this.maxScrollX<0?(this.maxScrollX-=this.relativeX,this.minScrollX=-this.relativeX):this.scale>1&&(this.maxScrollX=this.maxScrollX/2-this.relativeX,this.minScrollX=this.maxScrollX),this.maxScrollY<0?(this.maxScrollY-=this.relativeY,this.minScrollY=-this.relativeY):this.scale>1&&(this.maxScrollY=this.maxScrollY/2-this.relativeY,this.minScrollY=this.maxScrollY)),this.hasHorizontalScroll=this.options.scrollX&&this.maxScrollX<this.minScrollX,this.hasVerticalScroll=this.options.scrollY&&this.maxScrollY<this.minScrollY,this.hasHorizontalScroll||(this.maxScrollX=this.minScrollX,this.scrollerWidth=this.wrapperWidth),this.hasVerticalScroll||(this.maxScrollY=this.minScrollY,this.scrollerHeight=this.wrapperHeight),this.endTime=0,this.directionX=0,this.directionY=0,this.wrapperOffset=h(this.wrapper),this.trigger("refresh"),!this.scaled&&this.resetPosition()},t.prototype.enable=function(){this.enabled=!0},t.prototype.disable=function(){this.enabled=!1}}(M),function(t){t.prototype._start=function(t){var e=z[t.type];if((e===H||0===t.button)&&!(!this.enabled||this.destroyed||this.initiated&&this.initiated!==e)){this.initiated=e,this.options.preventDefault&&!f(t.target,this.options.preventDefaultException)&&t.preventDefault(),this.options.stopPropagation&&t.stopPropagation(),this.moved=!1,this.distX=0,this.distY=0,this.directionX=0,this.directionY=0,this.movingDirectionX=0,this.movingDirectionY=0,this.directionLocked=0,this._transitionTime(),this.startTime=n(),this.options.wheel&&(this.target=t.target),this.stop();var i=t.touches?t.touches[0]:t;this.startX=this.x,this.startY=this.y,this.absStartX=this.x,this.absStartY=this.y,this.pointX=i.pageX,this.pointY=i.pageY,this.trigger("beforeScrollStart")}},t.prototype._move=function(t){if(this.enabled&&!this.destroyed&&z[t.type]===this.initiated){this.options.preventDefault&&t.preventDefault(),this.options.stopPropagation&&t.stopPropagation();var e=t.touches?t.touches[0]:t,i=e.pageX-this.pointX,r=e.pageY-this.pointY;this.pointX=e.pageX,this.pointY=e.pageY,this.distX+=i,this.distY+=r;var o=Math.abs(this.distX),s=Math.abs(this.distY),a=n();if(!(a-this.endTime>this.options.momentumLimitTime&&s<this.options.momentumLimitDistance&&o<this.options.momentumLimitDistance)){if(this.directionLocked||this.options.freeScroll||(o>s+this.options.directionLockThreshold?this.directionLocked="h":s>=o+this.options.directionLockThreshold?this.directionLocked="v":this.directionLocked="n"),"h"===this.directionLocked){if("vertical"===this.options.eventPassthrough)t.preventDefault();else if("horizontal"===this.options.eventPassthrough)return void(this.initiated=!1);r=0}else if("v"===this.directionLocked){if("horizontal"===this.options.eventPassthrough)t.preventDefault();else if("vertical"===this.options.eventPassthrough)return void(this.initiated=!1);i=0}i=this.hasHorizontalScroll?i:0,r=this.hasVerticalScroll?r:0,this.movingDirectionX=i>0?K:i<0?Z:0,this.movingDirectionY=r>0?J:r<0?q:0;var c=this.x+i,l=this.y+r,h=!1,u=!1,p=!1,f=!1,d=this.options.bounce;!1!==d&&(h=void 0===d.top||d.top,u=void 0===d.bottom||d.bottom,p=void 0===d.left||d.left,f=void 0===d.right||d.right),(c>this.minScrollX||c<this.maxScrollX)&&(c=c>this.minScrollX&&p||c<this.maxScrollX&&f?this.x+i/3:c>this.minScrollX?this.minScrollX:this.maxScrollX),(l>this.minScrollY||l<this.maxScrollY)&&(l=l>this.minScrollY&&h||l<this.maxScrollY&&u?this.y+r/3:l>this.minScrollY?this.minScrollY:this.maxScrollY),this.moved||(this.moved=!0,this.trigger("scrollStart")),this._translate(c,l),a-this.startTime>this.options.momentumLimitTime&&(this.startTime=a,this.startX=this.x,this.startY=this.y,this.options.probeType===Q&&this.trigger("scroll",{x:this.x,y:this.y})),this.options.probeType>Q&&this.trigger("scroll",{x:this.x,y:this.y});var m=document.documentElement.scrollLeft||window.pageXOffset||document.body.scrollLeft,v=document.documentElement.scrollTop||window.pageYOffset||document.body.scrollTop,g=this.pointX-m,y=this.pointY-v;(g>document.documentElement.clientWidth-this.options.momentumLimitDistance||g<this.options.momentumLimitDistance||y<this.options.momentumLimitDistance||y>document.documentElement.clientHeight-this.options.momentumLimitDistance)&&this._end(t)}}},t.prototype._end=function(t){if(this.enabled&&!this.destroyed&&z[t.type]===this.initiated){this.initiated=!1,this.options.preventDefault&&!f(t.target,this.options.preventDefaultException)&&t.preventDefault(),this.options.stopPropagation&&t.stopPropagation(),this.trigger("touchEnd",{x:this.x,y:this.y}),this.isInTransition=!1;var e=Math.round(this.x),i=Math.round(this.y),r=e-this.absStartX,o=i-this.absStartY;if(this.directionX=r>0?K:r<0?Z:0,this.directionY=o>0?J:o<0?q:0,!this.options.pullDownRefresh||!this._checkPullDown()){if(this._checkClick(t))return void this.trigger("scrollCancel");if(!this.resetPosition(this.options.bounceTime,$.bounce)){this._translate(e,i),this.endTime=n();var s=this.endTime-this.startTime,a=Math.abs(e-this.startX),c=Math.abs(i-this.startY);if(this._events.flick&&s<this.options.flickLimitTime&&a<this.options.flickLimitDistance&&c<this.options.flickLimitDistance)return void this.trigger("flick");var l=0;if(this.options.momentum&&s<this.options.momentumLimitTime&&(c>this.options.momentumLimitDistance||a>this.options.momentumLimitDistance)){var h=!1,u=!1,p=!1,d=!1,m=this.options.bounce;!1!==m&&(h=void 0===m.top||m.top,u=void 0===m.bottom||m.bottom,p=void 0===m.left||m.left,d=void 0===m.right||m.right);var v=this.directionX===K&&p||this.directionX===Z&&d?this.wrapperWidth:0,g=this.directionY===J&&h||this.directionY===q&&u?this.wrapperHeight:0,y=this.hasHorizontalScroll?x(this.x,this.startX,s,this.maxScrollX,this.minScrollX,v,this.options):{destination:e,duration:0},b=this.hasVerticalScroll?x(this.y,this.startY,s,this.maxScrollY,this.minScrollY,g,this.options):{destination:i,duration:0};e=y.destination,i=b.destination,l=Math.max(y.duration,b.duration),this.isInTransition=!0}else this.options.wheel&&(i=Math.round(i/this.itemHeight)*this.itemHeight,l=this.options.wheel.adjustTime||400);var w=$.swipe;if(this.options.snap){var _=this._nearestSnap(e,i);this.currentPage=_,l=this.options.snapSpeed||Math.max(Math.max(Math.min(Math.abs(e-_.x),1e3),Math.min(Math.abs(i-_.y),1e3)),300),e=_.x,i=_.y,this.directionX=0,this.directionY=0,w=this.options.snap.easing||$.bounce}if(e!==this.x||i!==this.y)return(e>this.minScrollX||e<this.maxScrollX||i>this.minScrollY||i<this.maxScrollY)&&(w=$.swipeBounce),void this.scrollTo(e,i,l,w);this.options.wheel&&(this.selectedIndex=Math.round(Math.abs(this.y/this.itemHeight))),this.trigger("scrollEnd",{x:this.x,y:this.y})}}}},t.prototype._checkClick=function(t){var e=this.stopFromTransition&&!this.pulling;if(this.stopFromTransition=!1,!this.moved){if(this.options.wheel){if(this.target&&this.target.classList.contains(this.options.wheel.wheelWrapperClass)){var i=Math.abs(Math.round(this.y/this.itemHeight)),r=Math.round((this.pointY+u(this.wrapper).top-this.wrapperHeight/2)/this.itemHeight);this.target=this.items[i+r]}return this.scrollToElement(this.target,this.options.wheel.adjustTime||400,!0,!0,$.swipe),!0}if(!e){var o=this.options.dblclick,s=!1;if(o&&this.lastClickTime){var a=o.delay,c=void 0===a?300:a;n()-this.lastClickTime<c&&(s=!0,v(t))}return this.options.tap&&d(t,this.options.tap),this.options.click&&!f(t.target,this.options.preventDefaultException)&&m(t),this.lastClickTime=s?null:n(),!0}return!1}return!1},t.prototype._resize=function(){var t=this;this.enabled&&(Y&&(this.wrapper.scrollTop=0),clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(function(){t.refresh()},this.options.resizePolling))},t.prototype._startProbe=function(){function t(){var i=e.getComputedPosition();if(e.trigger("scroll",i),!e.isInTransition)return void e.trigger("scrollEnd",i);e.probeTimer=B(t)}G(this.probeTimer),this.probeTimer=B(t);var e=this},t.prototype._transitionTime=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(this.scrollerStyle[V.transitionDuration]=t+"ms",this.options.wheel)for(var e=0;e<this.items.length;e++)this.items[e].style[V.transitionDuration]=t+"ms";if(this.indicators)for(var i=0;i<this.indicators.length;i++)this.indicators[i].transitionTime(t)},t.prototype._transitionTimingFunction=function(t){if(this.scrollerStyle[V.transitionTimingFunction]=t,this.options.wheel)for(var e=0;e<this.items.length;e++)this.items[e].style[V.transitionTimingFunction]=t;if(this.indicators)for(var i=0;i<this.indicators.length;i++)this.indicators[i].transitionTimingFunction(t)},t.prototype._transitionEnd=function(t){t.target===this.scroller&&this.isInTransition&&(this._transitionTime(),(!this.pulling||this.movingDirectionY===q)&&!this.resetPosition(this.options.bounceTime,$.bounce)&&(this.isInTransition=!1,this.options.probeType!==tt&&this.trigger("scrollEnd",{x:this.x,y:this.y})))},t.prototype._translate=function(t,e,i){if(S(!o(t)&&!o(e),"Translate x or y is null or undefined."),o(i)&&(i=this.scale),this.options.useTransform?this.scrollerStyle[V.transform]="translate("+t+"px,"+e+"px) scale("+i+")"+this.translateZ:(t=Math.round(t),e=Math.round(e),this.scrollerStyle.left=t+"px",this.scrollerStyle.top=e+"px"),this.options.wheel)for(var n=this.options.wheel.rotate,r=void 0===n?25:n,s=0;s<this.items.length;s++){var a=r*(e/this.itemHeight+s);this.items[s].style[V.transform]="rotateX("+a+"deg)"}if(this.x=t,this.y=e,this.setScale(i),this.indicators)for(var c=0;c<this.indicators.length;c++)this.indicators[c].updatePosition()},t.prototype._animate=function(t,e,i,r){function o(){var f=n();if(f>=p)return s.isAnimating=!1,s._translate(t,e,h),s.trigger("scroll",{x:s.x,y:s.y}),void(s.pulling||s.resetPosition(s.options.bounceTime)||s.trigger("scrollEnd",{x:s.x,y:s.y}));f=(f-u)/i;var d=r(f),m=(t-a)*d+a,v=(e-c)*d+c,g=(h-l)*d+l;s._translate(m,v,g),s.isAnimating&&(s.animateTimer=B(o)),s.options.probeType===tt&&s.trigger("scroll",{x:s.x,y:s.y})}var s=this,a=this.x,c=this.y,l=this.lastScale,h=this.scale,u=n(),p=u+i;this.isAnimating=!0,G(this.animateTimer),o()},t.prototype.scrollBy=function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:$.bounce;t=this.x+t,e=this.y+e,this.scrollTo(t,e,i,n)},t.prototype.scrollTo=function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:$.bounce;this.isInTransition=this.options.useTransition&&i>0&&(t!==this.x||e!==this.y),!i||this.options.useTransition?(this._transitionTimingFunction(n.style),this._transitionTime(i),this._translate(t,e),i&&this.options.probeType===tt&&this._startProbe(),i||t===this.x&&e===this.y||(this.trigger("scroll",{x:t,y:e}),this._reflow=document.body.offsetHeight,this.resetPosition(this.options.bounceTime,$.bounce)||this.trigger("scrollEnd",{x:t,y:e})),this.options.wheel&&(e>this.minScrollY?this.selectedIndex=0:e<this.maxScrollY?this.selectedIndex=this.items.length-1:this.selectedIndex=Math.round(Math.abs(e/this.itemHeight)))):this._animate(t,e,i,n.fn)},t.prototype.scrollToElement=function(t,e,i,n,r){if(t&&(t=t.nodeType?t:this.scroller.querySelector(t),!this.options.wheel||t.classList.contains(this.options.wheel.wheelItemClass))){var o=h(t);o.left-=this.wrapperOffset.left,o.top-=this.wrapperOffset.top,!0===i&&(i=Math.round(t.offsetWidth/2-this.wrapper.offsetWidth/2)),!0===n&&(n=Math.round(t.offsetHeight/2-this.wrapper.offsetHeight/2)),o.left-=i||0,o.top-=n||0,o.left=o.left>this.minScrollX?this.minScrollX:o.left<this.maxScrollX?this.maxScrollX:o.left,o.top=o.top>this.minScrollY?this.minScrollY:o.top<this.maxScrollY?this.maxScrollY:o.top,this.options.wheel&&(o.top=Math.round(o.top/this.itemHeight)*this.itemHeight),this.scrollTo(o.left,o.top,e,r)}},t.prototype.resetPosition=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]