Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

helper-js

Package Overview
Dependencies
Maintainers
1
Versions
143
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

helper-js - npm Package Compare versions

Comparing version 1.4.37 to 1.4.38

4

dist/helper-js.min.js
/*!
* helper-js v1.4.37
* helper-js v1.4.38
* (c) phphe <phphe@outlook.com> (https://github.com/phphe)

@@ -7,2 +7,2 @@ * Homepage: undefined

*/
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).helperJs={})}(this,(function(e){"use strict";var t=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e};function n(e,t){return e(t={exports:{}},t.exports),t.exports}var r=n((function(e){function t(n){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},t(n)}e.exports=t}));var o=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=r(e)););return e},i=n((function(e){function t(n,r,i){return"undefined"!=typeof Reflect&&Reflect.get?e.exports=t=Reflect.get:e.exports=t=function(e,t,n){var r=o(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}},t(n,r,i||n)}e.exports=t})),a=n((function(e){function t(n,r){return e.exports=t=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},t(n,r)}e.exports=t}));var c=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)},u=n((function(e){function t(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?e.exports=t=function(e){return typeof e}:e.exports=t=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(n)}e.exports=t}));var l=function(e,n){return!n||"object"!==u(n)&&"function"!=typeof n?t(e):n};var s=function(e){if(Array.isArray(e))return e};var f=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,c=e[Symbol.iterator]();!(r=(a=c.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw i}}return n}};var h=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r};var d=function(e,t){if(e){if("string"==typeof e)return h(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?h(e,t):void 0}};var v=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.")};var p=function(e,t){return s(e)||f(e,t)||d(e,t)||v()};var y=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e};function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var m=function(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e};var b=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},w=n((function(e){var t=function(e){var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},o=r.iterator||"@@iterator",i=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function c(e,t,n,r){var o=t&&t.prototype instanceof s?t:s,i=Object.create(o.prototype),a=new O(r||[]);return i._invoke=function(e,t,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return j()}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=b(a,n);if(c){if(c===l)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=u(e,t,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===l)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}(e,n,a),i}function u(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var l={};function s(){}function f(){}function h(){}var d={};d[o]=function(){return this};var v=Object.getPrototypeOf,p=v&&v(v(k([])));p&&p!==t&&n.call(p,o)&&(d=p);var y=h.prototype=s.prototype=Object.create(d);function g(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function m(e,t){var r;this._invoke=function(o,i){function a(){return new t((function(r,a){!function r(o,i,a,c){var l=u(e[o],e,i);if("throw"!==l.type){var s=l.arg,f=s.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,a,c)}),(function(e){r("throw",e,a,c)})):t.resolve(f).then((function(e){s.value=e,a(s)}),(function(e){return r("throw",e,a,c)}))}c(l.arg)}(o,i,r,a)}))}return r=r?r.then(a,a):a()}}function b(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,b(e,t),"throw"===t.method))return l;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return l}var r=u(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,l;var o=r.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,l):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,l)}function w(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function x(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(w,this),this.reset(!0)}function k(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:j}}function j(){return{value:void 0,done:!0}}return f.prototype=y.constructor=h,h.constructor=f,h[a]=f.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===f||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,a in e||(e[a]="GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},g(m.prototype),m.prototype[i]=function(){return this},e.AsyncIterator=m,e.async=function(t,n,r,o,i){void 0===i&&(i=Promise);var a=new m(c(t,n,r,o),i);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},g(y),y[a]="Generator",y[o]=function(){return this},y.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=k,O.prototype={constructor:O,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(x),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,l):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),l},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),x(n),l}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;x(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:k(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),l}},e}(e.exports);try{regeneratorRuntime=t}catch(e){Function("r","regeneratorRuntime = r")(t)}}));var x=function(e){if(Array.isArray(e))return h(e)};var O=function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)};var k=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")};var j=function(e){return x(e)||O(e)||d(e)||k()};function S(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function P(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){y(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var A=w.mark(X);function T(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(!e)return;if("string"==typeof e)return N(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return N(e,t)}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var L={};function C(){if(L.glb)return L.glb;var e;try{e=global}catch(t){e=window}return L.glb=e,e}function _(e){return void 0!==e}function I(e){return"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"[object Boolean]"===Object.prototype.toString.call(e)}function F(e){return"[object Number]"===Object.prototype.toString.call(e)}function M(e){return isFinite(e)&&!isNaN(parseFloat(e))}function R(e){return"[object String]"===Object.prototype.toString.call(e)}function B(e){return"[object Object]"===Object.prototype.toString.call(e)}function U(e){return"function"==typeof e}function G(e,t){return 1===arguments.length&&(t=e,e=0),Math.floor(Math.random()*(t-e+1)+e)}function H(e,t){return e<t?e:t}function W(e){return e&&e[0].toUpperCase()+e.substr(1)}function K(e){return e.replace(/ /g,"-").replace(/_/g,"-").replace(/([A-Z])/g,"-$1").replace(/--+/g,"-").replace(/^-|-$|/g,"").toLowerCase()}function z(e){for(var t=e.toString().split(/[-_]/),n=1;n<t.length;n++)t[n]=W(t[n]);return t.join("")}function Y(e){return e.toString().trim().split(/(?=[A-Z])/)}function $(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:8,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n="",r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",o=0;o<e;o++)n+=r[G(r.length-1)];return t+n}function q(e,t){for(var n,r=0;(n=e.indexOf(t))>-1;)e.splice(n,1),r++;return r}function J(e){return e[e.length-1]}function V(e){return I(e)?e:[e]}function Q(e,t){var n=[];if(U(t))for(var r=t,o=1,i=0;i<e.length;){var a=i+r(o);n.push(e.slice(i,a)),i=a,o++}else for(var c=0;c<e.length;){var u=c+t;n.push(e.slice(c,u)),c=u}return n}function X(e){var t,n,r,o,i,a,c,u,l,s,f,h,d,v,p=arguments;return w.wrap((function(y){for(;;)switch(y.prev=y.next){case 0:if((t=p.length>1&&void 0!==p[1]?p[1]:{}).reverse){y.next=30;break}if(null==e.length){y.next=14;break}n=0;case 4:if(!(n<e.length)){y.next=12;break}if(r={value:e[n],index:n},t.exclude&&t.exclude(r)){y.next=9;break}return y.next=9,r;case 9:n++,y.next=4;break;case 12:y.next=28;break;case 14:if(!B(e)){y.next=27;break}o=0,i=Object.keys(e);case 16:if(!(o<i.length)){y.next=25;break}if(a=i[o],c={value:e[a],key:a},t.exclude&&t.exclude(c)){y.next=22;break}return y.next=22,c;case 22:o++,y.next=16;break;case 25:y.next=28;break;case 27:throw"Unsupported type";case 28:y.next=58;break;case 30:if(null==e.length){y.next=42;break}u=e.length-1;case 32:if(!(u>=0)){y.next=40;break}if(l={value:e[u],index:u},t.exclude&&t.exclude(l)){y.next=37;break}return y.next=37,l;case 37:u--,y.next=32;break;case 40:y.next=58;break;case 42:if(!B(e)){y.next=57;break}(s=Object.keys(e)).reverse(),f=0,h=s;case 46:if(!(f<h.length)){y.next=55;break}if(d=h[f],v={value:e[d],key:d},t.exclude&&t.exclude(v)){y.next=52;break}return y.next=52,v;case 52:f++,y.next=46;break;case 55:y.next=58;break;case 57:throw"Unsupported type";case 58:case"end":return y.stop()}}),A)}var Z=X;function ee(e,t,n){var r=I(t)?t:t.split("."),o=e;try{var i,a=T(r);try{for(a.s();!(i=a.n()).done;){o=o[i.value]}}catch(e){a.e(e)}finally{a.f()}}catch(e){if(n)throw"Path does not exist"}return o}function te(e,t){for(var n={},r=e.length,o=0;o<r;o++){var i=e[o];n[U(t)?t(i,o):i[t]]=i}return n}function ne(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"children",r=arguments.length>3?arguments[3]:void 0,o=I(e)?e:[e],i=function e(){b(this,e)},a=function e(o,a,c){r&&(o=o.slice()).reverse();for(var u=o.length,l=0;l<u;l++){var s=o[l],f=r?u-l-1:l,h=c?[].concat(j(c),[f]):[],d=t(s,f,a,h);if(!1===d)throw new i;if("skip children"!==d){if("skip siblings"===d)break;null!=s[n]&&e(s[n],s,h)}}};try{a(o,null,I(e)?[]:null)}catch(e){if(!(e instanceof i))throw e}}var re=ne,oe=function(){function e(t){b(this,e),this.childrenKey="children",this.data=t}return m(e,[{key:"iteratePath",value:w.mark((function e(t){var n,r,o,i,a,c,u,l,s,f,h,d,v,p,y,g,m=arguments;return w.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=m.length>1&&void 0!==m[1]?m[1]:{},r=this.childrenKey,o=this.rootChildren,n.reverse){e.next=29;break}i=[],a=o,c=T(t),e.prev=6,c.s();case 8:if((u=c.n()).done){e.next=19;break}return l=u.value,s=[].concat(j(i),[l]),f=a[l],e.next=14,{path:s,node:f};case 14:i=s,a=f[r];case 17:e.next=8;break;case 19:e.next=24;break;case 21:e.prev=21,e.t0=e.catch(6),c.e(e.t0);case 24:return e.prev=24,c.f(),e.finish(24);case 27:e.next=48;break;case 29:(h=j(this.iteratePath(t,P({},n,{reverse:!1})))).reverse(),d=T(h),e.prev=32,d.s();case 34:if((v=d.n()).done){e.next=40;break}return p=v.value,y=p.path,g=p.node,e.next=38,{path:y,node:g};case 38:e.next=34;break;case 40:e.next=45;break;case 42:e.prev=42,e.t1=e.catch(32),d.e(e.t1);case 45:return e.prev=45,d.f(),e.finish(45);case 48:case"end":return e.stop()}}),e,this,[[6,21,24,27],[32,42,45,48]])}))},{key:"getAllNodes",value:function(e){var t,n=[],r=T(this.iteratePath(e));try{for(r.s();!(t=r.n()).done;){var o=t.value.node;n.push(o)}}catch(e){r.e(e)}finally{r.f()}return n}},{key:"getNode",value:function(e){return J(this.getAllNodes(e))}},{key:"getNodeIndexAndParent",value:function(e){var t=e.slice(),n=t.pop();return{parent:this.getNode(t),index:n,parentPath:t}}},{key:"getNodeParent",value:function(e){return this.getNodeIndexAndParent(e).parent}},{key:"setPathNode",value:function(e,t){if(null==e||0===e.length)this.data=t;else{var n=this.childrenKey,r=this.rootChildren,o=this.getNodeIndexAndParent(e),i=o.parent,a=o.index;(1===e.length?r:i[n])[a]=t}}},{key:"removeNode",value:function(e){var t=this.childrenKey,n=this.rootChildren,r=this.getNodeIndexAndParent(e),o=r.parent,i=r.index,a=1===e.length?n:o[t],c=a[i];return a.splice(i,1),c}},{key:"walk",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.childrenKey,r=this.data;return re(r,e,n,t.reverse)}},{key:"clone",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=this.childrenKey,r=new e;return this.walk((function(e,o,i,a){var c=Object.assign({},e);c[n]&&(c[n]=[]),t.afterNodeCreated&&t.afterNodeCreated(c,{oldNode:e,index:o,parent:i,path:a}),r.setPathNode(a,c)})),r.data}},{key:"rootChildren",get:function(){var e=this.childrenKey;this.data||(this.data=[]);var t=this.data;return I(t)?t:t[e]}}]),e}();function ie(e){var t,n,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=[],a=[],c=function(){for(var c=this,u=arguments.length,l=new Array(u),s=0;s<u;s++)l[s]=arguments[s];return new Promise((function(u,s){i.push(u),a.push(s),r=l,n||(n=!0,t=setTimeout((function(){var o=e.call.apply(e,[c].concat(j(r)));t=null,n=!1,i.forEach((function(e){return e(o)})),i=[],a=[]}),o))}))};return c.stop=function(){t&&(clearTimeout(t),t=null),n=!1,i=[],a.forEach((function(e){return e()})),a=[]},c}function ae(e){var t,n,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=function(){var i=this;return new Promise((function(a,c){n?a(r):(n=!0,a(r=e.call.apply(e,[i].concat(j(lastArgs)))),t=setTimeout((function(){t=null,n=!1,r=null}),o))}))};return i.stop=function(){t&&(clearTimeout(t),t=null),n=!1},i}function ce(){if("undefined"!=typeof pageYOffset)return{top:pageYOffset,left:pageXOffset};var e=document.body,t=document.documentElement;return{top:(t=t.clientHeight?t:e).scrollTop,left:t.scrollLeft}}function ue(e){var t=se(e),n=ce();return{x:t.left+n.left,y:t.top+n.top}}function le(e){var t=e.offsetParent;return(!t||t===document.body&&"static"===getComputedStyle(document.body).position)&&(t=document.body.parentElement),t}function se(e){var t=e.getBoundingClientRect(),n=t.top-document.documentElement.clientTop,r=t.bottom,o=t.left-document.documentElement.clientLeft,i=t.right;return{top:n,right:i,bottom:r,left:o,width:t.width||i-o,height:t.height||r-n,x:o,y:n}}var fe=se;function he(e,t,n){for(var r=n&&n.withSelf?e:e.parentElement;r;){var o=t(r);if("break"===o)return;if(o)return r;r=r.parentElement}}function de(e,t){e["original_".concat(t)]=e.getAttribute(t)}function ve(e,t){var n="original_".concat(t);e.setAttribute(t,e[n])}function pe(e,t){return e.classList?e.classList.contains(t):new RegExp("(^| )"+t+"( |$)","gi").test(e.className)}function ye(e){de(e,"style"),e.style.display="block";var t=se(e),n={width:t.width,height:t.height};return ve(e,"style"),n}var ge=ye;function me(e,t,n){for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];e.addEventListener?e.addEventListener.apply(e,[t,n].concat(o)):e.attachEvent&&e.attachEvent.apply(e,["on".concat(t),n].concat(o))}function be(e,t,n){for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];e.removeEventListener?e.removeEventListener.apply(e,[t,n].concat(o)):e.detachEvent&&e.detachEvent.apply(e,["on".concat(t),n].concat(o))}function we(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=X(e,{reverse:r.reverse}),i=T(o);try{for(i.s();!(n=i.n()).done;){var a=n.value,c=a.value,u=a.index;if(t(c,u))return c}}catch(e){i.e(e)}finally{i.f()}}function xe(e){return new Date(e.getTime())}function Oe(e,t,n){["year","month","day","date"].includes(n)||(n+="s"),"Day"===(n=W(n))&&(n="Date");var r="get"+n;return e["set"+n](e[r]()+t),e}function ke(e){var t=xe(e);return t.setDate(1),t}function je(e){var t=xe(e);return Oe(t,1,"month"),t.setDate(0),t}function Se(e,t,n,r,o){var i,a,c=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1e3;null==n&&(n=0,r=e.length-1);for(var u,l=0;n>=0&&n<=r;){if(l>=c)throw Error("binarySearch: loop times is over ".concat(c,", you can increase the limit."));if((u=t(a=e[i=Math.floor((r-n)/2+n)],l))>0)r=i-1;else{if(!(u<0))return{index:i,value:a,count:l+1,hit:!0};n=i+1}l++}return o?{index:i,value:a,count:l+1,hit:!1,bigger:u>0}:null}function Ee(e,t){return new Promise((function(n,r){setTimeout((function(){t&&t(),n()}),e)}))}function Pe(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};C().open(e,t,Object.keys(n).map((function(e){return"".concat(e,"=").concat(n[e])})).join(","))}var Ae=function(){function e(t){var n=this;b(this,e),this.baseUrl="",this.search={};var r=decodeURI(t).split("?");this.baseUrl=r[0],r[1]&&r[1].split("&").forEach((function(e){var t=e.split("=");n.search[t[0]]=null==t[1]?"":decodeURIComponent(t[1])}))}return m(e,[{key:"getHref",value:function(){var e=this,t=[this.baseUrl],n=Object.keys(this.search).map((function(t){return"".concat(t,"=").concat(encodeURIComponent(e.search[t]))})).join("&");return n&&t.push(n),t.join("?")}}]),e}();function Te(e){return{storage:e,set:function(e,t,n){null==t?this.storage.removeItem(e):this.storage.setItem(e,JSON.stringify({value:t,expired_at:n?(new Date).getTime()+60*n*1e3:null}))},get:function(e){var t=this.storage.getItem(e);if(t){if(!(t=JSON.parse(t)).expired_at||t.expired_at>(new Date).getTime())return t.value;this.storage.removeItem(e)}return null},clear:function(){this.storage.clear()}}}var Ne=function(){function e(){b(this,e),this.eventStore=[]}return m(e,[{key:"on",value:function(e,t){this.eventStore.push({name:e,handler:t})}},{key:"once",value:function(e,t){var n=this,r=function(){n.off(e,o)},o=function(){t.apply(void 0,arguments),r()};return this.on(e,o),r}},{key:"onceTimeout",value:function(e,t,n){var r,o=this;return{off:function(){r&&r()},promise:new Promise((function(i,a){r=o.once(e,(function(){t.apply(void 0,arguments),i()})),Ee(n).then((function(){r(),a()}))}))}}},{key:"off",value:function(e,t){for(var n=[],r=this.eventStore.length,o=0;o<r;o++){var i=this.eventStore[o];i.name===e&&i.handler===t&&n.unshift(o)}for(var a=0,c=n;a<c.length;a++){var u=c[a];this.eventStore.splice(u,1)}}},{key:"emit",value:function(e){var t,n=[],r=T(this.eventStore);try{for(r.s();!(t=r.n()).done;){var o=t.value;o.name===e&&n.push(o)}}catch(e){r.e(e)}finally{r.f()}for(var i=arguments.length,a=new Array(i>1?i-1:0),c=1;c<i;c++)a[c-1]=arguments[c];for(var u=0,l=n;u<l.length;u++){var s=l[u];s.handler.apply(s,a)}}}]),e}(),Le=function(e){c(a,e);var n,o=(n=a,function(){var e,t=r(n);if(S()){var o=r(this).constructor;e=Reflect.construct(t,arguments,o)}else e=t.apply(this,arguments);return l(this,e)});function a(e){var n;return b(this,a),(n=o.call(this)).storageName="_crossWindow",n.windows=[],n.timeout=200,n.BROADCAST="__BROADCAST__",e&&Object.assign(t(n),e),me(window,"storage",(function(e){if(e.key===n.storageName){var t,r=JSON.parse(e.newValue);if(!r.targets||r.targets.includes(n.id))(t=n).emitLocal.apply(t,[r.name].concat(j(r.args)))}})),n.id=$(),n.windows=[n.id],n.ready=new Promise((function(e,t){n.onceTimeout("_windows_updated",(function(e){var t=e.windows;n.windows=t}),n.timeout).promise.then((function(){e()}),(function(){e()})),n.broadcast("_join",n.id)})),n.ready.then((function(){n.on("_join",(function(e){n.windows.push(e),n.isMain()&&n.broadcast("_windows_updated",{windows:n.windows,type:"join",id:e})})),n.on("_windows_updated",(function(e){var t=e.windows;n.windows=t})),n.on("_exit",(function(e){var t=n.windows[0];q(n.windows,e),n.isMain()&&(n.emit("_windows_updated",{windows:n.windows,type:"exit",id:e}),t!=n.id&&n.emit("_main_updated",{windows:n.windows,old:t,new:n.id}))})),me(window,"beforeunload",(function(){n.exitGroup()}))})),n}return m(a,[{key:"isMain",value:function(){return this.id===this.windows[0]}},{key:"emitTo",value:function(e,t){for(var n=arguments.length,o=new Array(n>2?n-2:0),c=2;c<n;c++)o[c-2]=arguments[c];var u;t===this.BROADCAST?t=null:(t&&!I(t)&&(t=[t]),t.includes(this.id)&&(u=i(r(a.prototype),"emit",this)).call.apply(u,[this,e].concat(o)));C().localStorage.setItem(this.storageName,JSON.stringify({name:e,targets:t,args:o,random:Math.random()}))}},{key:"emitLocal",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.id].concat(n))}},{key:"broadcast",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.BROADCAST].concat(n))}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.windows].concat(n))}},{key:"exitGroup",value:function(){this.broadcast("_exit",this.id)}}]),a}(Ne),Ce=Le;var _e=function(){function e(){b(this,e),this.store={}}return m(e,[{key:"has",value:function(e){return this.store.hasOwnProperty(e)}},{key:"remember",value:function(e,t){return this.has(e)||(this.store[e]={value:t()}),this.store[e].value}},{key:"forget",value:function(e){e?this.has(e)&&delete this.store[e]:this.store={}}}]),e}();e.Cache=_e,e.CrossWindow=Ce,e.CrossWindowEventProcessor=Le,e.EventProcessor=Ne,e.TreeData=oe,e.URLHelper=Ae,e.addClass=function(e,t){pe(e,t)||(e.classList?e.classList.add(t):e.className+=" "+t)},e.addDate=Oe,e.appendTo=function(e,t){t.appendChild(e)},e.arrayAt=function(e,t){return e[t>=0?t:e.length+t]},e.arrayDiff=function(e,t){for(var n=e.length,r=[];n--;)t.indexOf(e[n])<0&&r.push(e[n]);return r},e.arrayDistinct=function(e){return C().Set?j(new Set(e)):e.filter((function(e,t,n){return n.indexOf(e)===t}))},e.arrayFirst=function(e){return e[0]},e.arrayGet=function(e,t,n){return t<0&&(t+=e.length),null==n?e[t]:(n<0&&(n+=e.length),e.slice(t,n-t+1))},e.arrayLast=J,e.arrayRemove=q,e.arrayRemoveBySortedIndexes=function(e,t){for(var n=t.length-1;n>=0;n--){var r=t[n];e.splice(r,1)}},e.arraySibling=function(e,t,n){var r=e.indexOf(t);if(-1===r)throw"item is not in array";return I(n)?n.map((function(t){return e[r+t]})):e[r+n]},e.arrayWithoutEnd=function(e,t){return e.slice(0,e.length-t)},e.assignIfDifferent=function(e,t,n){e[t]!==n&&(e[t]=n)},e.attachCache=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new _e,r=function(r){var o=t[r];Object.defineProperty(e,r,{get:function(){var e=this;return n.remember(r,(function(){return o.call(e)}))}})};for(var o in t)r(o)},e.backupAttr=de,e.binarySearch=Se,e.camelCase=z,e.camelToWords=Y,e.cloneDate=xe,e.cloneObj=function e(t,n){switch(u(t)){case"undefined":case"boolean":case"nuber":case"string":case"function":return t;case"object":if(null===t)return t;var r;if(I(t)){r=[];var o,i=T(t);try{for(i.s();!(o=i.n()).done;){var a=o.value;r.push(e(a,n))}}catch(e){i.e(e)}finally{i.f()}}else{r={};for(var c=0,l=Object.keys(t);c<l.length;c++){var s=l[c];n&&(!I(n)||n.includes(s))&&n(s,t[s],t)||(r[s]=e(t[s],n))}}return r;default:return t}},e.copyTextToClipboard=function(e){try{return void navigator.clipboard.writeText(e)}catch(e){}var t=document.createElement("textarea");t.style.position="fixed",t.style.top=0,t.style.left=0,t.style.width="2em",t.style.height="2em",t.style.padding=0,t.style.border="none",t.style.outline="none",t.style.boxShadow="none",t.style.background="transparent",t.value=e,document.body.appendChild(t),t.select();try{var n=document.execCommand("copy")?"successful":"unsuccessful";console.log("Copying text command was "+n)}catch(e){console.log("Oops, unable to copy")}document.body.removeChild(t)},e.createElementFromHTML=function(e){var t=document.createElement("div");return t.innerHTML=e.trim(),t.childNodes.length>1?t.childNodes:t.childNodes[0]},e.debounce=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.immediate?ae(e,t):ie(e,t)},e.debounceImmediate=ae,e.debounceTrailing=ie,e.depthFirstSearch=ne,e.elementsFromPoint=function(){for(var e=document.elementsFromPoint||document.msElementsFromPoint||o,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.apply(document,n);function o(e,t){var n=[],r=void 0;do{r!==document.elementFromPoint(e,t)?(r=document.elementFromPoint(e,t),n.push(r),r.style.pointerEvents="none"):r=!1}while(r);return n.forEach((function(e){return e.style.pointerEvents="all"})),n}},e.empty=function(e){return null==e||(null!=e.length?0===e.length:!D(e)&&(F(e)?isNaN(e):B(e)?0===Object.keys(e).length:void 0))},e.executeOnceInScopeByName=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:scope_executeOnceInScopeByName,r=arguments.length>3?arguments[3]:void 0;if(e="executeOnceInScopeByName_".concat(e),!n[e]){var o=t(),i=function(){delete n[e]};n[e]={destroy:i},r&&(n[e].value=o)}return n[e]},e.executePromiseGetters=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=new Promise((function(r,o){var i=[],a=Q(e,n),c=Promise.resolve();a.forEach((function(e){c=c.then((function(n){if(n&&i.push.apply(i,j(n)),!t)return Promise.all(e.map((function(e){return e()})));o("stopped")}))})),c.then((function(e){i.push.apply(i,j(e)),r(i)}))}));return{promise:r,destroy:function(){t=!0}}},e.executeWithCount=function(e){var t=0;return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return e.call.apply(e,[this,t++].concat(r))}},e.findNodeList=we,e.findNodeListReverse=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.reverse=!0,we(e,t,n)},e.findParent=he,e.forAll=function(e,t,n){if(n){if(I(e)||R(e)||e.hasOwnProperty("length"))for(var r=e.length-1;r>=0&&!1!==t(e[r],r);r--);else if(B(e)){var o=Object.keys(e);o.reverse();for(var i=0,a=o;i<a.length;i++){var c=a[i];if(!1===t(e[c],c))break}}else if(Number.isInteger(e))for(var u=e-1;u>=0&&!1!==t(u,u);u--);}else if(I(e)||R(e)||e.hasOwnProperty("length"))for(var l=0;l<e.length&&!1!==t(e[l],l);l++);else if(B(e))for(var s=0,f=Object.keys(e);s<f.length;s++){var h=f[s];if(!1===t(e[h],h))break}else if(Number.isInteger(e))for(var d=0;d<e&&!1!==t(d,d);d++);},e.getBorder=function(e){var t=document.body,n=he(e,(function(e){return pe(e,"work-area")})),r=ue(n);return{left:r.x,right:r.x+n.offsetWidth,top:r.y+50,bottom:t.offsetHeight<C().innerHeight?C().innerHeight:t.offsetHeight}},e.getBoundingClientRect=se,e.getCalendar=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=[],o=new Date(e,t-1);e=o.getFullYear(),t=o.getMonth()+1;var i=ke(o),a=i.getDay(),c=Oe(xe(i),-(a+n),"day");if(a>n)for(var u=c.getDate(),l=c.getFullYear(),s=c.getMonth()+1,f=n;f<a;f++){var h=u+f;r.push({year:l,month:s,date:h,text:h,prevMonth:!0})}for(var d=je(o),v=d.getDate(),p=1;p<=v;p++){var y=p;r.push({year:e,month:t,date:y,text:y,currentMonth:!0})}var g=d.getDay(),m=6-n;if(g<m)for(var b=Oe(xe(o),1,"month"),w=b.getFullYear(),x=b.getMonth()+1,O=g+1,k=1;O<=m;O++,k++)r.push({year:w,month:x,date:k,text:k,nextMonth:!0});return Q(r,7)},e.getCss3Prefix=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(e.noCache||null==L.css3Prefix)&&(L.css3Prefix=t()),L.css3Prefix;function t(){var e=document.createElement("div");e.style.cssText="-webkit-transition:all .1s; -moz-transition:all .1s; -o-transition:all .1s; -ms-transition:all .1s; transition:all .1s;";var t=e.style;return t.webkitTransition?"-webkit-":t.MozTransition?"-moz-":t.oTransition?"-o-":t.msTransition?"-ms-":""}},e.getElSize=ye,e.getElSizeEvenInvisible=ge,e.getImageSizeByUrl=function(e){var t=document.createElement("img");return new Promise((function(n,r){me(t,"load",(function(){n({width:t.width,height:t.height})})),me(t,"error",(function(e){r(e)})),t.src=e}))},e.getLocalStorage2=function(){return L.localStorage2||(L.localStorage2=Te(C().localStorage)),L.localStorage2},e.getMonthEnd=je,e.getMonthStart=ke,e.getOffset=ue,e.getOffsetParent=le,e.getOuterAttachedHeight=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({margin:!0,border:!0},t);var n=getComputedStyle(e),r=0,o=[];return t.margin&&o.push("margin-top","margin-bottom"),t.border&&o.push("border-top-width","border-bottom-width"),o.forEach((function(e){r+=parseFloat(n[e])})),r},e.getOuterAttachedWidth=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({margin:!0,border:!0},t);var n=getComputedStyle(e),r=0,o=[];return t.margin&&o.push("margin-left","margin-right"),t.border&&o.push("border-left-width","border-right-width"),o.forEach((function(e){r+=parseFloat(n[e])})),r},e.getPosition=function(e){for(var t=le(e),n={x:e.offsetLeft,y:e.offsetTop},r=e;(r=r.parentElement)!==t&&r;)n.x-=r.scrollLeft,n.y-=r.scrollTop;return n},e.getPositionFromOffset=function(e,t){var n=ue(le(e));return{x:t.x-n.x,y:t.y-n.y}},e.getScroll=ce,e.getSessionStorage2=function(){return L.sessionStorage2||(L.sessionStorage2=Te(C().sessionStorage)),L.sessionStorage2},e.getUrlParam=function(e){var t=document.location.href,n=t.indexOf(e+"=");if(-1==n)return!1;var r=t.slice(e.length+n+1),o=r.indexOf("&");return-1!=o&&(r=r.slice(0,o)),r},e.getUserLanguage=function(){return navigator.language||navigator.userLanguage},e.getViewportPosition=fe,e.glb=C,e.groupArray=function(e,t){var n=new Map;e.forEach((function(e){var r=t(e);n.has(r)||n.set(r,[]),n.get(r).push(e)}));var r=[];return n.forEach((function(e,t){r.push([t,e])})),r},e.hasClass=pe,e.insertAfter=function(e,t){t.parentElement.insertBefore(e,t.nextSibling)},e.insertBefore=function(e,t){t.parentElement.insertBefore(e,t)},e.isArray=I,e.isBool=D,e.isDescendantOf=function(e,t){for(;;){if(null==e.parentElement)return!1;if(e.parentElement===t)return!0;e=e.parentElement}},e.isDocumentExisted=function(){try{document}catch(e){return!1}return!0},e.isFunction=U,e.isIE=function(){return Boolean(window.ActiveXObject||"ActiveXObject"in window)},e.isIsoFormat=function(e){return e.length>15&&e.length<30&&e.match(/^\d{4}-\d{2}-\d{2}T.*Z$/)},e.isNode=function(){return Boolean(void 0!==C().module&&C().module.exports)},e.isNumber=F,e.isNumeric=M,e.isObject=B,e.isOffsetInEl=function(e,t,n){var r=ue(n);return r.x<=e&&r.x+n.offsetWidth>=e&&r.y<=t&&r.y+n.offsetHeight>=t},e.isPromise=function(e){return"[object Promise]"===Object.prototype.toString.call(e)},e.isString=R,e.isWindowDefined=function(){try{return window&&!0}catch(e){return!1}},e.isset=_,e.iterateALL=Z,e.iterateAll=X,e.joinFunctionsByNext=function(e){var t,n=function(){},r=T(X(e,{reverse:!0}));try{for(r.s();!(t=r.n()).done;){n=o(t.value.value,n)}}catch(e){r.e(e)}finally{r.f()}return n;function o(e,t){return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return e.apply(void 0,[t].concat(r))}}},e.joinFunctionsByResult=function(e){for(var t=e[0],n=1;n<e.length;n++)t=r(t,e[n]);return t;function r(e,t){return function(n){args;var r=e(n);return t(r)}}},e.joinMethods=function(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",o=T(e);try{var i=function(){var e=n.value,o=t;t=o?function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return e.call.apply(e,[this,"value"===r?o.call.apply(o,[this].concat(n)):o].concat(n))}:e};for(o.s();!(n=o.n()).done;)i()}catch(e){o.e(e)}finally{o.f()}return t},e.jqFixedSize=function(e){var t=C().jQuery;t(e).each((function(){var e=t(this);e.css({width:e.width()+"px",height:e.height()+"px"})}))},e.jqMakeCarousel=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1e3,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:16,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"left",a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0;o.toString().match(/^\d+$/)&&(o+="px");var c=parseFloat(o),u=C().jQuery,l=u(e),s=l.find(t);l.css({position:"relative",height:l.height()+"px"});var f=s.find(n);f.css({margin:"0",marginRight:o});var h=(Math.ceil(f.width())+c)*f.length;s.css({position:"absolute",margin:"0",width:h+"px"});var d=s.height(),v=s.clone(),p=s.clone();s.css({left:0}),v.css({left:h+"px"}),p.css({left:2*h+"px"});var y=u("<div></div>");y.css({position:"absolute",width:3*h+"px",height:d+"px",left:0,top:a}),y.append(s).append(v).append(p),l.append(y);var g=0;function m(){"left"===i?g-=100:g+=100,y.animate({left:"".concat(g,"px")},r,"linear",(function(){Math.abs(g)>h&&("left"===i?g+=h:g-=h,y.css({left:g+"px"})),m()}))}m()},e.kebabCase=K,e.makeStorageHelper=Te,e.mapObjectTree=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e4,o=0,i=[{value:e}],a=function(){if(o>=r)throw"mapObjectTree: limit(".concat(r,") reached, object may has circular reference");o++;var e=i.shift(),a=e.value,c=e.key,u=e.parent,l=e.newParent,s=t(a,c,u,l),f=function(e,t,r){return I(e)?e=[]:B(e)&&(e={}),u?I(l)&&r?l.push(e):l[t]=e:n=e,e},h=void 0,d=void 0,v=void 0,p=void 0,y=void 0;if(s){var g=s.key,m=s.value;d=m,s.delete||!1===g?v=!0:null==g?h=f(m,c,!0):s.hasOwnProperty("value")&&(h=f(m,g)),p=s.stop,y=s.skip}else d=a,h=f(a,c);if(v)return"continue";if(y)return"continue";if(p)return"break";if(I(d))for(var b=d.length,w=0;w<b;w++)i.push({value:d[w],key:w,parent:d,newParent:h});else B(d)&&Object.keys(d).forEach((function(e){i.push({value:d[e],key:e,parent:d,newParent:h})}))};e:for(;i.length>0;){var c=a();switch(c){case"continue":continue;case"break":break e}}return n},e.mapObjects=te,e.max=H,e.min=function(e,t){return e<t?t:e},e.newArrayRemoveAt=function(e,t){var n,r={},o=T(t=V(t));try{for(o.s();!(n=o.n()).done;){r[n.value]=!0}}catch(e){o.e(e)}finally{o.f()}for(var i=[],a=e.length,c=0;c<a;c++)r[c]||i.push(e[c]);return i},e.numPad=function(e,t){for(var n=e.toString().length;n<t;)e="0"+e,n++;return e},e.numRand=G,e.objectExcept=function(e,t){var n={};for(var r in e)-1===t.indexOf(r)&&(n[r]=e[r]);return n},e.objectGet=ee,e.objectMap=function(e,t){var n={};for(var r in e)n[r]=t(e[r],r,e);return n},e.objectMerge=function(e,t){for(var n in t)e.hasOwnProperty(n)&&B(e[n])&&B(t[n])?Object.assign(e[n],t[n]):e[n]=t[n];return e},e.objectOnly=function(e,t){var n={};for(var r in e)t.indexOf(r)>-1&&(n[r]=e[r]);return n},e.objectSet=function(e,t,n){var r=I(t)?t:t.split("."),o=J(r),i=ee(e,r.slice(0,r.length-1));if(!i)throw"Path does not exist";i[o]=n},e.offDOM=be,e.offsetToViewportPosition=function(e){var t=document.body,n=ue(t),r=fe(t);return{x:e.x+r.x-n.x,y:e.y+r.y-n.y}},e.onDOM=me,e.onDOMMany=function(e,t,n){e=V(e),t=V(t);for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];var a,c=T(e);try{for(c.s();!(a=c.n()).done;){var u,l=a.value,s=T(t);try{for(s.s();!(u=s.n()).done;){var f=u.value;me.apply(void 0,[l,f,n].concat(o))}}catch(e){s.e(e)}finally{s.f()}}}catch(e){c.e(e)}finally{c.f()}var h=function(){var r,o=T(e);try{for(o.s();!(r=o.n()).done;){var i,a=r.value,c=T(t);try{for(c.s();!(i=c.n()).done;){be(a,i.value,n)}}catch(e){c.e(e)}finally{c.f()}}}catch(e){o.e(e)}finally{o.f()}};return h},e.onQuickKeydown=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({timeout:1e3},t);var n,r="",o=function(o){o.key&&1===o.key.length&&(r="".concat(r).concat(o.key),e(r),n&&(clearTimeout(n),n=null),n=setTimeout((function(){r=""}),t.timeout))};return me(document,"keydown",o),function(){be(document,"keydown",o)}},e.openCenterWindow=function(e,t,n,r){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},i={width:n,height:r,top:(C().screen.availHeight-30-r)/2,left:(C().screen.availWidth-30-n)/2};Object.assign(i,o),Pe(e,t,i)},e.openWindow=Pe,e.pairRows=function(e,t,n,r){r||(r=n);var o=te(t,r);return e.map((function(e){return[e,o[e[n]]]}))},e.parseISO=function(e){var t,n,r,o=e.split("T"),i=p(o,2),a=i[0],c=i[1],u=0,l=0,s=0,f=a.split("-").map((function(e){return parseInt(e)})),h=p(f,3);if(t=h[0],n=h[1],r=h[2],n-=1,c){var d=c.split("-").map((function(e){return parseFloat(e)}));u=d[0],null!=d[1]&&(l=d[1]),null!=d[2]&&(s=d[2])}var v=new Date(t,n,r,u,l,s);return v.setUTCHours(u),v},e.prependTo=function(e,t){t.insertBefore(e,t.firstChild)},e.promiseTimeout=function(e,t){return new Promise((function(n,r){var o,i;e.then((function(){clearTimeout(o),n.apply(void 0,arguments)}),(function(){i||(clearTimeout(o),r.apply(void 0,arguments))})),o=setTimeout((function(){i=!0;var e=new Error("Promise timeout!");e.name="timeout",r(e)}),t)}))},e.removeClass=function(e,t){e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi")," ")},e.removeEl=function(e){if(null!==e.parentNode)return e.parentNode.removeChild(e)},e.replaceMultiple=function(e,t){var n=new RegExp(Object.keys(e).join("|"),"g");return t.replace(n,(function(t){return e[t]}))},e.resolveArgsByType=function(e,t){var n=0;return t.map((function(t){var r,o;if(I(t)?(r=t[0],o=t[1]):(r=t,o=void 0),!U(r))if(null==r)r=function(){return!0};else{var i=r;r=function(e){return Object.prototype.toString.call(e)==="[object ".concat(i,"]")}}var a=e[n];return r(a)?(n++,a):o}))},e.resolveValueOrGettter=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return U(e)?e.apply(void 0,j(t)):e},e.restoreAttr=ve,e.retry=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;L.retry||(L.retry={});var r=e,o=a();return r[o]=0,i;function i(e,a,c){return t(e,a,c).then((function(e){return delete r[o],e})).catch((function(t){return r[o]++,r[o]>=n?(delete r[o],Promise.reject(t)):i(e,a,c)}))}function a(){var e=Math.random()+"";return r[e]?a():e}},e.setElChildByIndex=function(e,t,n){n.childComponentIndex=t;var r=e.childNodes.length;if(0===r)e.appendChild(n);else if(0===t)e.insertBefore(n,e.childNodes[0]);else{var o=Se(e.childNodes,(function(e){return e.childComponentIndex-t}),0,H(t,r-1),!0),i=o.index,a=o.value;if(o.bigger)e.insertBefore(n,a);else{var c=e.childNodes[i+1];c?e.insertBefore(n,c):e.appendChild(n)}}},e.snakeCase=function(e){return K(e).replace(/-/g,"_")},e.splitArray=Q,e.store=L,e.store_executeOnceInScopeByName={},e.strRand=$,e.studlyCase=W,e.titleCase=function(e){return Y(W(z(e))).join(" ").replace(/\bid\b/gi,"ID")},e.toArrayIfNot=V,e.uniqueId=function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"id_",n=t+$();L.uniqueId||(L.uniqueId={});var r=L.uniqueId;return document.getElementById(n)||r[n]?e(t):(r[n]=!0,n)},e.unset=function(e,t){e[t]=void 0;try{delete e[t]}catch(e){}},e.viewportPositionToOffset=function(e){var t=document.body,n=ue(t),r=fe(t);return{x:e.x+n.x-r.x,y:e.y+n.y-r.y}},e.waitFor=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1e3;U(e)&&(r=n,n=M(t)?t:100,t=e,e=null),L.waitFor||(L.waitFor={});var o=L.waitFor;return e&&_(o[e])&&(C().clearInterval(o[e]),delete o[e]),new Promise((function(i,a){var c=0;function u(n){c<=r?t()&&(l(n,e),i()):(l(n,e),a(new Error("waitFor: Limit is reached"))),c++}function l(e,t){e&&(t&&_(o[t])?(C().clearInterval(o[t]),delete o[t]):C().clearInterval(e))}var s=C().setInterval((function(){u(s)}),n);e&&(o[e]=s),u()}))},e.waitTime=Ee,e.walkTreeData=re,e.watchChange=function(e,t){var n;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=e.apply(void 0,o);n!==a&&t.apply(void 0,[a].concat(o)),n=a}},e.windowLoaded=function(){return new Promise((function(e,t){document&&"complete"===document.readyState?e():C().addEventListener("load",(function t(){e(),C().removeEventListener("load",t)}))}))},Object.defineProperty(e,"__esModule",{value:!0})}));
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).helperJs={})}(this,(function(e){"use strict";var t=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e};function n(e,t){return e(t={exports:{}},t.exports),t.exports}var r=n((function(e){function t(n){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},t(n)}e.exports=t}));var o=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=r(e)););return e},i=n((function(e){function t(n,r,i){return"undefined"!=typeof Reflect&&Reflect.get?e.exports=t=Reflect.get:e.exports=t=function(e,t,n){var r=o(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}},t(n,r,i||n)}e.exports=t})),a=n((function(e){function t(n,r){return e.exports=t=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},t(n,r)}e.exports=t}));var c=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)},u=n((function(e){function t(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?e.exports=t=function(e){return typeof e}:e.exports=t=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(n)}e.exports=t}));var l=function(e,n){return!n||"object"!==u(n)&&"function"!=typeof n?t(e):n};var s=function(e){if(Array.isArray(e))return e};var f=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,c=e[Symbol.iterator]();!(r=(a=c.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw i}}return n}};var h=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r};var d=function(e,t){if(e){if("string"==typeof e)return h(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?h(e,t):void 0}};var v=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.")};var p=function(e,t){return s(e)||f(e,t)||d(e,t)||v()};var y=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e};function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var m=function(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e};var b=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},w=n((function(e){var t=function(e){var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},o=r.iterator||"@@iterator",i=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function c(e,t,n,r){var o=t&&t.prototype instanceof s?t:s,i=Object.create(o.prototype),a=new O(r||[]);return i._invoke=function(e,t,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return j()}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=b(a,n);if(c){if(c===l)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=u(e,t,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===l)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}(e,n,a),i}function u(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var l={};function s(){}function f(){}function h(){}var d={};d[o]=function(){return this};var v=Object.getPrototypeOf,p=v&&v(v(k([])));p&&p!==t&&n.call(p,o)&&(d=p);var y=h.prototype=s.prototype=Object.create(d);function g(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function m(e,t){var r;this._invoke=function(o,i){function a(){return new t((function(r,a){!function r(o,i,a,c){var l=u(e[o],e,i);if("throw"!==l.type){var s=l.arg,f=s.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,a,c)}),(function(e){r("throw",e,a,c)})):t.resolve(f).then((function(e){s.value=e,a(s)}),(function(e){return r("throw",e,a,c)}))}c(l.arg)}(o,i,r,a)}))}return r=r?r.then(a,a):a()}}function b(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,b(e,t),"throw"===t.method))return l;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return l}var r=u(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,l;var o=r.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,l):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,l)}function w(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function x(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(w,this),this.reset(!0)}function k(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:j}}function j(){return{value:void 0,done:!0}}return f.prototype=y.constructor=h,h.constructor=f,h[a]=f.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===f||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,a in e||(e[a]="GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},g(m.prototype),m.prototype[i]=function(){return this},e.AsyncIterator=m,e.async=function(t,n,r,o,i){void 0===i&&(i=Promise);var a=new m(c(t,n,r,o),i);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},g(y),y[a]="Generator",y[o]=function(){return this},y.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=k,O.prototype={constructor:O,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(x),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,l):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),l},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),x(n),l}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;x(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:k(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),l}},e}(e.exports);try{regeneratorRuntime=t}catch(e){Function("r","regeneratorRuntime = r")(t)}}));var x=function(e){if(Array.isArray(e))return h(e)};var O=function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)};var k=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")};var j=function(e){return x(e)||O(e)||d(e)||k()};function S(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function P(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){y(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var A=w.mark(X);function T(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(!e)return;if("string"==typeof e)return N(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return N(e,t)}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var L={};function C(){if(L.glb)return L.glb;var e;try{e=global}catch(t){e=window}return L.glb=e,e}function _(e){return void 0!==e}function I(e){return"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"[object Boolean]"===Object.prototype.toString.call(e)}function F(e){return"[object Number]"===Object.prototype.toString.call(e)}function M(e){return isFinite(e)&&!isNaN(parseFloat(e))}function R(e){return"[object String]"===Object.prototype.toString.call(e)}function B(e){return"[object Object]"===Object.prototype.toString.call(e)}function U(e){return"function"==typeof e}function G(e,t){return 1===arguments.length&&(t=e,e=0),Math.floor(Math.random()*(t-e+1)+e)}function H(e,t){return e<t?e:t}function W(e){return e&&e[0].toUpperCase()+e.substr(1)}function K(e){return e.replace(/ /g,"-").replace(/_/g,"-").replace(/([A-Z])/g,"-$1").replace(/--+/g,"-").replace(/^-|-$|/g,"").toLowerCase()}function z(e){for(var t=e.toString().split(/[-_]/),n=1;n<t.length;n++)t[n]=W(t[n]);return t.join("")}function Y(e){return e.toString().trim().split(/(?=[A-Z])/)}function $(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:8,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n="",r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",o=0;o<e;o++)n+=r[G(r.length-1)];return t+n}function q(e,t){for(var n,r=0;(n=e.indexOf(t))>-1;)e.splice(n,1),r++;return r}function J(e){return e[e.length-1]}function V(e){return I(e)?e:[e]}function Q(e,t){var n=[];if(U(t))for(var r=t,o=1,i=0;i<e.length;){var a=i+r(o);n.push(e.slice(i,a)),i=a,o++}else for(var c=0;c<e.length;){var u=c+t;n.push(e.slice(c,u)),c=u}return n}function X(e){var t,n,r,o,i,a,c,u,l,s,f,h,d,v,p=arguments;return w.wrap((function(y){for(;;)switch(y.prev=y.next){case 0:if((t=p.length>1&&void 0!==p[1]?p[1]:{}).reverse){y.next=30;break}if(null==e.length){y.next=14;break}n=0;case 4:if(!(n<e.length)){y.next=12;break}if(r={value:e[n],index:n},t.exclude&&t.exclude(r)){y.next=9;break}return y.next=9,r;case 9:n++,y.next=4;break;case 12:y.next=28;break;case 14:if(!B(e)){y.next=27;break}o=0,i=Object.keys(e);case 16:if(!(o<i.length)){y.next=25;break}if(a=i[o],c={value:e[a],key:a},t.exclude&&t.exclude(c)){y.next=22;break}return y.next=22,c;case 22:o++,y.next=16;break;case 25:y.next=28;break;case 27:throw"Unsupported type";case 28:y.next=58;break;case 30:if(null==e.length){y.next=42;break}u=e.length-1;case 32:if(!(u>=0)){y.next=40;break}if(l={value:e[u],index:u},t.exclude&&t.exclude(l)){y.next=37;break}return y.next=37,l;case 37:u--,y.next=32;break;case 40:y.next=58;break;case 42:if(!B(e)){y.next=57;break}(s=Object.keys(e)).reverse(),f=0,h=s;case 46:if(!(f<h.length)){y.next=55;break}if(d=h[f],v={value:e[d],key:d},t.exclude&&t.exclude(v)){y.next=52;break}return y.next=52,v;case 52:f++,y.next=46;break;case 55:y.next=58;break;case 57:throw"Unsupported type";case 58:case"end":return y.stop()}}),A)}var Z=X;function ee(e,t,n){var r=I(t)?t:t.split("."),o=e;try{var i,a=T(r);try{for(a.s();!(i=a.n()).done;){o=o[i.value]}}catch(e){a.e(e)}finally{a.f()}}catch(e){if(n)throw"Path does not exist"}return o}function te(e,t){for(var n={},r=e.length,o=0;o<r;o++){var i=e[o];n[U(t)?t(i,o):i[t]]=i}return n}function ne(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"children",r=arguments.length>3?arguments[3]:void 0,o=I(e)?e:[e],i=function e(){b(this,e)},a=function e(o,a,c){r&&(o=o.slice()).reverse();for(var u=o.length,l=0;l<u;l++){var s=o[l],f=r?u-l-1:l,h=c?[].concat(j(c),[f]):[],d=t(s,f,a,h);if(!1===d)throw new i;if("skip children"!==d){if("skip siblings"===d)break;null!=s[n]&&e(s[n],s,h)}}};try{a(o,null,I(e)?[]:null)}catch(e){if(!(e instanceof i))throw e}}var re=ne,oe=function(){function e(t){b(this,e),this.childrenKey="children",this.data=t}return m(e,[{key:"iteratePath",value:w.mark((function e(t){var n,r,o,i,a,c,u,l,s,f,h,d,v,p,y,g,m=arguments;return w.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=m.length>1&&void 0!==m[1]?m[1]:{},r=this.childrenKey,o=this.rootChildren,n.reverse){e.next=29;break}i=[],a=o,c=T(t),e.prev=6,c.s();case 8:if((u=c.n()).done){e.next=19;break}return l=u.value,s=[].concat(j(i),[l]),f=a[l],e.next=14,{path:s,node:f};case 14:i=s,a=f[r];case 17:e.next=8;break;case 19:e.next=24;break;case 21:e.prev=21,e.t0=e.catch(6),c.e(e.t0);case 24:return e.prev=24,c.f(),e.finish(24);case 27:e.next=48;break;case 29:(h=j(this.iteratePath(t,P({},n,{reverse:!1})))).reverse(),d=T(h),e.prev=32,d.s();case 34:if((v=d.n()).done){e.next=40;break}return p=v.value,y=p.path,g=p.node,e.next=38,{path:y,node:g};case 38:e.next=34;break;case 40:e.next=45;break;case 42:e.prev=42,e.t1=e.catch(32),d.e(e.t1);case 45:return e.prev=45,d.f(),e.finish(45);case 48:case"end":return e.stop()}}),e,this,[[6,21,24,27],[32,42,45,48]])}))},{key:"getAllNodes",value:function(e){var t,n=[],r=T(this.iteratePath(e));try{for(r.s();!(t=r.n()).done;){var o=t.value.node;n.push(o)}}catch(e){r.e(e)}finally{r.f()}return n}},{key:"getNode",value:function(e){return J(this.getAllNodes(e))}},{key:"getNodeIndexAndParent",value:function(e){var t=e.slice(),n=t.pop();return{parent:this.getNode(t),index:n,parentPath:t}}},{key:"getNodeParent",value:function(e){return this.getNodeIndexAndParent(e).parent}},{key:"setPathNode",value:function(e,t){if(null==e||0===e.length)this.data=t;else{var n=this.childrenKey,r=this.rootChildren,o=this.getNodeIndexAndParent(e),i=o.parent,a=o.index;(1===e.length?r:i[n])[a]=t}}},{key:"removeNode",value:function(e){var t=this.childrenKey,n=this.rootChildren,r=this.getNodeIndexAndParent(e),o=r.parent,i=r.index,a=1===e.length?n:o[t],c=a[i];return a.splice(i,1),c}},{key:"walk",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.childrenKey,r=this.data;return re(r,e,n,t.reverse)}},{key:"clone",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=this.childrenKey,r=new e;return this.walk((function(e,o,i,a){var c=Object.assign({},e);c[n]&&(c[n]=[]),t.afterNodeCreated&&t.afterNodeCreated(c,{oldNode:e,index:o,parent:i,path:a}),r.setPathNode(a,c)})),r.data}},{key:"rootChildren",get:function(){var e=this.childrenKey;this.data||(this.data=[]);var t=this.data;return I(t)?t:t[e]}}]),e}();function ie(e){var t,n,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=[],a=[],c=function(){for(var c=this,u=arguments.length,l=new Array(u),s=0;s<u;s++)l[s]=arguments[s];return new Promise((function(u,s){i.push(u),a.push(s),r=l,n||(n=!0,t=setTimeout((function(){var o=e.call.apply(e,[c].concat(j(r)));t=null,n=!1,i.forEach((function(e){return e(o)})),i=[],a=[]}),o))}))};return c.stop=function(){t&&(clearTimeout(t),t=null),n=!1,i=[],a.forEach((function(e){return e()})),a=[]},c}function ae(e){var t,n,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=function(){var i=this;return new Promise((function(a,c){n?a(r):(n=!0,a(r=e.call.apply(e,[i].concat(j(lastArgs)))),t=setTimeout((function(){t=null,n=!1,r=null}),o))}))};return i.stop=function(){t&&(clearTimeout(t),t=null),n=!1},i}function ce(){if("undefined"!=typeof pageYOffset)return{top:pageYOffset,left:pageXOffset};var e=document.body,t=document.documentElement;return{top:(t=t.clientHeight?t:e).scrollTop,left:t.scrollLeft}}function ue(e){var t=se(e),n=ce();return{x:t.left+n.left,y:t.top+n.top}}function le(e){var t=e.offsetParent;return(!t||t===document.body&&"static"===getComputedStyle(document.body).position)&&(t=document.body.parentElement),t}function se(e){var t=e.getBoundingClientRect(),n=t.top-document.documentElement.clientTop,r=t.bottom,o=t.left-document.documentElement.clientLeft,i=t.right;return{top:n,right:i,bottom:r,left:o,width:t.width||i-o,height:t.height||r-n,x:o,y:n}}var fe=se;function he(e,t,n){for(var r=n&&n.withSelf?e:e.parentElement;r;){var o=t(r);if("break"===o)return;if(o)return r;r=r.parentElement}}function de(e,t){e["original_".concat(t)]=e.getAttribute(t)}function ve(e,t){var n="original_".concat(t);e.setAttribute(t,e[n])}function pe(e,t){return e.classList?e.classList.contains(t):new RegExp("(^| )"+t+"( |$)","gi").test(e.className)}function ye(e){de(e,"style"),e.style.display="block";var t=se(e),n={width:t.width,height:t.height};return ve(e,"style"),n}var ge=ye;function me(e,t,n){for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];e.addEventListener?e.addEventListener.apply(e,[t,n].concat(o)):e.attachEvent&&e.attachEvent.apply(e,["on".concat(t),n].concat(o))}function be(e,t,n){for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];e.removeEventListener?e.removeEventListener.apply(e,[t,n].concat(o)):e.detachEvent&&e.detachEvent.apply(e,["on".concat(t),n].concat(o))}function we(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=X(e,{reverse:r.reverse}),i=T(o);try{for(i.s();!(n=i.n()).done;){var a=n.value,c=a.value,u=a.index;if(t(c,u))return c}}catch(e){i.e(e)}finally{i.f()}}function xe(e){return new Date(e.getTime())}function Oe(e,t,n){["year","month","day","date"].includes(n)||(n+="s"),"Day"===(n=W(n))&&(n="Date");var r="get"+n;return e["set"+n](e[r]()+t),e}function ke(e){var t=xe(e);return t.setDate(1),t}function je(e){var t=xe(e);return Oe(t,1,"month"),t.setDate(0),t}function Se(e,t,n,r,o){var i,a,c=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1e3;null==n&&(n=0,r=e.length-1);for(var u,l=0;n>=0&&n<=r;){if(l>=c)throw Error("binarySearch: loop times is over ".concat(c,", you can increase the limit."));if((u=t(a=e[i=Math.floor((r-n)/2+n)],l))>0)r=i-1;else{if(!(u<0))return{index:i,value:a,count:l+1,hit:!0};n=i+1}l++}return o?{index:i,value:a,count:l+1,hit:!1,bigger:u>0}:null}function Ee(e,t){return new Promise((function(n,r){setTimeout((function(){t&&t(),n()}),e)}))}function Pe(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};C().open(e,t,Object.keys(n).map((function(e){return"".concat(e,"=").concat(n[e])})).join(","))}var Ae=function(){function e(t){var n=this;b(this,e),this.baseUrl="",this.search={};var r=decodeURI(t).split("?");this.baseUrl=r[0],r[1]&&r[1].split("&").forEach((function(e){var t=e.split("=");n.search[t[0]]=null==t[1]?"":decodeURIComponent(t[1])}))}return m(e,[{key:"getHref",value:function(){var e=this,t=[this.baseUrl],n=Object.keys(this.search).map((function(t){return"".concat(t,"=").concat(encodeURIComponent(e.search[t]))})).join("&");return n&&t.push(n),t.join("?")}}]),e}();function Te(e){return{storage:e,set:function(e,t,n){null==t?this.storage.removeItem(e):this.storage.setItem(e,JSON.stringify({value:t,expired_at:n?(new Date).getTime()+60*n*1e3:null}))},get:function(e){var t=this.storage.getItem(e);if(t){if(!(t=JSON.parse(t)).expired_at||t.expired_at>(new Date).getTime())return t.value;this.storage.removeItem(e)}return null},clear:function(){this.storage.clear()}}}var Ne=function(){function e(){b(this,e),this.eventStore=[]}return m(e,[{key:"on",value:function(e,t){this.eventStore.push({name:e,handler:t})}},{key:"once",value:function(e,t){var n=this,r=function(){n.off(e,o)},o=function(){t.apply(void 0,arguments),r()};return this.on(e,o),r}},{key:"onceTimeout",value:function(e,t,n){var r,o=this;return{off:function(){r&&r()},promise:new Promise((function(i,a){r=o.once(e,(function(){t.apply(void 0,arguments),i()})),Ee(n).then((function(){r(),a()}))}))}}},{key:"off",value:function(e,t){for(var n=[],r=this.eventStore.length,o=0;o<r;o++){var i=this.eventStore[o];i.name===e&&i.handler===t&&n.unshift(o)}for(var a=0,c=n;a<c.length;a++){var u=c[a];this.eventStore.splice(u,1)}}},{key:"emit",value:function(e){var t,n=[],r=T(this.eventStore);try{for(r.s();!(t=r.n()).done;){var o=t.value;o.name===e&&n.push(o)}}catch(e){r.e(e)}finally{r.f()}for(var i=arguments.length,a=new Array(i>1?i-1:0),c=1;c<i;c++)a[c-1]=arguments[c];for(var u=0,l=n;u<l.length;u++){var s=l[u];s.handler.apply(s,a)}}}]),e}(),Le=function(e){c(a,e);var n,o=(n=a,function(){var e,t=r(n);if(S()){var o=r(this).constructor;e=Reflect.construct(t,arguments,o)}else e=t.apply(this,arguments);return l(this,e)});function a(e){var n;return b(this,a),(n=o.call(this)).storageName="_crossWindow",n.windows=[],n.timeout=200,n.BROADCAST="__BROADCAST__",e&&Object.assign(t(n),e),me(window,"storage",(function(e){if(e.key===n.storageName){var t,r=JSON.parse(e.newValue);if(!r.targets||r.targets.includes(n.id))(t=n).emitLocal.apply(t,[r.name].concat(j(r.args)))}})),n.id=$(),n.windows=[n.id],n.ready=new Promise((function(e,t){n.onceTimeout("_windows_updated",(function(e){var t=e.windows;n.windows=t}),n.timeout).promise.then((function(){e()}),(function(){e()})),n.broadcast("_join",n.id)})),n.ready.then((function(){n.on("_join",(function(e){n.windows.push(e),n.isMain()&&n.broadcast("_windows_updated",{windows:n.windows,type:"join",id:e})})),n.on("_windows_updated",(function(e){var t=e.windows;n.windows=t})),n.on("_exit",(function(e){var t=n.windows[0];q(n.windows,e),n.isMain()&&(n.emit("_windows_updated",{windows:n.windows,type:"exit",id:e}),t!=n.id&&n.emit("_main_updated",{windows:n.windows,old:t,new:n.id}))})),me(window,"beforeunload",(function(){n.exitGroup()}))})),n}return m(a,[{key:"isMain",value:function(){return this.id===this.windows[0]}},{key:"emitTo",value:function(e,t){for(var n=arguments.length,o=new Array(n>2?n-2:0),c=2;c<n;c++)o[c-2]=arguments[c];var u;t===this.BROADCAST?t=null:(t&&!I(t)&&(t=[t]),t.includes(this.id)&&(u=i(r(a.prototype),"emit",this)).call.apply(u,[this,e].concat(o)));C().localStorage.setItem(this.storageName,JSON.stringify({name:e,targets:t,args:o,random:Math.random()}))}},{key:"emitLocal",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.id].concat(n))}},{key:"broadcast",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.BROADCAST].concat(n))}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.emitTo.apply(this,[e,this.windows].concat(n))}},{key:"exitGroup",value:function(){this.broadcast("_exit",this.id)}}]),a}(Ne),Ce=Le;var _e=function(){function e(){b(this,e),this.store={}}return m(e,[{key:"has",value:function(e){return this.store.hasOwnProperty(e)}},{key:"remember",value:function(e,t){return this.has(e)||(this.store[e]={value:t()}),this.store[e].value}},{key:"forget",value:function(e){e?this.has(e)&&delete this.store[e]:this.store={}}}]),e}();e.Cache=_e,e.CrossWindow=Ce,e.CrossWindowEventProcessor=Le,e.EventProcessor=Ne,e.TreeData=oe,e.URLHelper=Ae,e.addClass=function(e,t){pe(e,t)||(e.classList?e.classList.add(t):e.className+=" "+t)},e.addDate=Oe,e.appendTo=function(e,t){t.appendChild(e)},e.arrayAt=function(e,t){return e[t>=0?t:e.length+t]},e.arrayDiff=function(e,t){for(var n=e.length,r=[];n--;)t.indexOf(e[n])<0&&r.push(e[n]);return r},e.arrayDistinct=function(e){return C().Set?j(new Set(e)):e.filter((function(e,t,n){return n.indexOf(e)===t}))},e.arrayFirst=function(e){return e[0]},e.arrayFlat=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,n=[],r=function e(r,o){var i,a=T(r);try{for(a.s();!(i=a.n()).done;){var c=i.value;I(c)&&o<t?e(c,o+1):n.push(c)}}catch(e){a.e(e)}finally{a.f()}};return r(e,0),n},e.arrayGet=function(e,t,n){return t<0&&(t+=e.length),null==n?e[t]:(n<0&&(n+=e.length),e.slice(t,n-t+1))},e.arrayLast=J,e.arrayRemove=q,e.arrayRemoveBySortedIndexes=function(e,t){for(var n=t.length-1;n>=0;n--){var r=t[n];e.splice(r,1)}},e.arraySibling=function(e,t,n){var r=e.indexOf(t);if(-1===r)throw"item is not in array";return I(n)?n.map((function(t){return e[r+t]})):e[r+n]},e.arrayWithoutEnd=function(e,t){return e.slice(0,e.length-t)},e.assignIfDifferent=function(e,t,n){e[t]!==n&&(e[t]=n)},e.attachCache=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new _e,r=function(r){var o=t[r];Object.defineProperty(e,r,{get:function(){var e=this;return n.remember(r,(function(){return o.call(e)}))}})};for(var o in t)r(o)},e.backupAttr=de,e.binarySearch=Se,e.camelCase=z,e.camelToWords=Y,e.cloneDate=xe,e.cloneObj=function e(t,n){switch(u(t)){case"undefined":case"boolean":case"nuber":case"string":case"function":return t;case"object":if(null===t)return t;var r;if(I(t)){r=[];var o,i=T(t);try{for(i.s();!(o=i.n()).done;){var a=o.value;r.push(e(a,n))}}catch(e){i.e(e)}finally{i.f()}}else{r={};for(var c=0,l=Object.keys(t);c<l.length;c++){var s=l[c];n&&(!I(n)||n.includes(s))&&n(s,t[s],t)||(r[s]=e(t[s],n))}}return r;default:return t}},e.copyTextToClipboard=function(e){try{return void navigator.clipboard.writeText(e)}catch(e){}var t=document.createElement("textarea");t.style.position="fixed",t.style.top=0,t.style.left=0,t.style.width="2em",t.style.height="2em",t.style.padding=0,t.style.border="none",t.style.outline="none",t.style.boxShadow="none",t.style.background="transparent",t.value=e,document.body.appendChild(t),t.select();try{var n=document.execCommand("copy")?"successful":"unsuccessful";console.log("Copying text command was "+n)}catch(e){console.log("Oops, unable to copy")}document.body.removeChild(t)},e.createElementFromHTML=function(e){var t=document.createElement("div");return t.innerHTML=e.trim(),t.childNodes.length>1?t.childNodes:t.childNodes[0]},e.debounce=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.immediate?ae(e,t):ie(e,t)},e.debounceImmediate=ae,e.debounceTrailing=ie,e.depthFirstSearch=ne,e.elementsFromPoint=function(){for(var e=document.elementsFromPoint||document.msElementsFromPoint||o,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.apply(document,n);function o(e,t){var n=[],r=void 0;do{r!==document.elementFromPoint(e,t)?(r=document.elementFromPoint(e,t),n.push(r),r.style.pointerEvents="none"):r=!1}while(r);return n.forEach((function(e){return e.style.pointerEvents="all"})),n}},e.empty=function(e){return null==e||(null!=e.length?0===e.length:!D(e)&&(F(e)?isNaN(e):B(e)?0===Object.keys(e).length:void 0))},e.executeOnceInScopeByName=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:scope_executeOnceInScopeByName,r=arguments.length>3?arguments[3]:void 0;if(e="executeOnceInScopeByName_".concat(e),!n[e]){var o=t(),i=function(){delete n[e]};n[e]={destroy:i},r&&(n[e].value=o)}return n[e]},e.executePromiseGetters=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=new Promise((function(r,o){var i=[],a=Q(e,n),c=Promise.resolve();a.forEach((function(e){c=c.then((function(n){if(n&&i.push.apply(i,j(n)),!t)return Promise.all(e.map((function(e){return e()})));o("stopped")}))})),c.then((function(e){i.push.apply(i,j(e)),r(i)}))}));return{promise:r,destroy:function(){t=!0}}},e.executeWithCount=function(e){var t=0;return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return e.call.apply(e,[this,t++].concat(r))}},e.findNodeList=we,e.findNodeListReverse=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.reverse=!0,we(e,t,n)},e.findParent=he,e.forAll=function(e,t,n){if(n){if(I(e)||R(e)||e.hasOwnProperty("length"))for(var r=e.length-1;r>=0&&!1!==t(e[r],r);r--);else if(B(e)){var o=Object.keys(e);o.reverse();for(var i=0,a=o;i<a.length;i++){var c=a[i];if(!1===t(e[c],c))break}}else if(Number.isInteger(e))for(var u=e-1;u>=0&&!1!==t(u,u);u--);}else if(I(e)||R(e)||e.hasOwnProperty("length"))for(var l=0;l<e.length&&!1!==t(e[l],l);l++);else if(B(e))for(var s=0,f=Object.keys(e);s<f.length;s++){var h=f[s];if(!1===t(e[h],h))break}else if(Number.isInteger(e))for(var d=0;d<e&&!1!==t(d,d);d++);},e.getBorder=function(e){var t=document.body,n=he(e,(function(e){return pe(e,"work-area")})),r=ue(n);return{left:r.x,right:r.x+n.offsetWidth,top:r.y+50,bottom:t.offsetHeight<C().innerHeight?C().innerHeight:t.offsetHeight}},e.getBoundingClientRect=se,e.getCalendar=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=[],o=new Date(e,t-1);e=o.getFullYear(),t=o.getMonth()+1;var i=ke(o),a=i.getDay(),c=Oe(xe(i),-(a+n),"day");if(a>n)for(var u=c.getDate(),l=c.getFullYear(),s=c.getMonth()+1,f=n;f<a;f++){var h=u+f;r.push({year:l,month:s,date:h,text:h,prevMonth:!0})}for(var d=je(o),v=d.getDate(),p=1;p<=v;p++){var y=p;r.push({year:e,month:t,date:y,text:y,currentMonth:!0})}var g=d.getDay(),m=6-n;if(g<m)for(var b=Oe(xe(o),1,"month"),w=b.getFullYear(),x=b.getMonth()+1,O=g+1,k=1;O<=m;O++,k++)r.push({year:w,month:x,date:k,text:k,nextMonth:!0});return Q(r,7)},e.getCss3Prefix=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(e.noCache||null==L.css3Prefix)&&(L.css3Prefix=t()),L.css3Prefix;function t(){var e=document.createElement("div");e.style.cssText="-webkit-transition:all .1s; -moz-transition:all .1s; -o-transition:all .1s; -ms-transition:all .1s; transition:all .1s;";var t=e.style;return t.webkitTransition?"-webkit-":t.MozTransition?"-moz-":t.oTransition?"-o-":t.msTransition?"-ms-":""}},e.getElSize=ye,e.getElSizeEvenInvisible=ge,e.getImageSizeByUrl=function(e){var t=document.createElement("img");return new Promise((function(n,r){me(t,"load",(function(){n({width:t.width,height:t.height})})),me(t,"error",(function(e){r(e)})),t.src=e}))},e.getLocalStorage2=function(){return L.localStorage2||(L.localStorage2=Te(C().localStorage)),L.localStorage2},e.getMonthEnd=je,e.getMonthStart=ke,e.getOffset=ue,e.getOffsetParent=le,e.getOuterAttachedHeight=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({margin:!0,border:!0},t);var n=getComputedStyle(e),r=0,o=[];return t.margin&&o.push("margin-top","margin-bottom"),t.border&&o.push("border-top-width","border-bottom-width"),o.forEach((function(e){r+=parseFloat(n[e])})),r},e.getOuterAttachedWidth=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({margin:!0,border:!0},t);var n=getComputedStyle(e),r=0,o=[];return t.margin&&o.push("margin-left","margin-right"),t.border&&o.push("border-left-width","border-right-width"),o.forEach((function(e){r+=parseFloat(n[e])})),r},e.getPosition=function(e){for(var t=le(e),n={x:e.offsetLeft,y:e.offsetTop},r=e;(r=r.parentElement)!==t&&r;)n.x-=r.scrollLeft,n.y-=r.scrollTop;return n},e.getPositionFromOffset=function(e,t){var n=ue(le(e));return{x:t.x-n.x,y:t.y-n.y}},e.getScroll=ce,e.getSessionStorage2=function(){return L.sessionStorage2||(L.sessionStorage2=Te(C().sessionStorage)),L.sessionStorage2},e.getUrlParam=function(e){var t=document.location.href,n=t.indexOf(e+"=");if(-1==n)return!1;var r=t.slice(e.length+n+1),o=r.indexOf("&");return-1!=o&&(r=r.slice(0,o)),r},e.getUserLanguage=function(){return navigator.language||navigator.userLanguage},e.getViewportPosition=fe,e.glb=C,e.groupArray=function(e,t){var n=new Map;e.forEach((function(e){var r=t(e);n.has(r)||n.set(r,[]),n.get(r).push(e)}));var r=[];return n.forEach((function(e,t){r.push([t,e])})),r},e.hasClass=pe,e.insertAfter=function(e,t){t.parentElement.insertBefore(e,t.nextSibling)},e.insertBefore=function(e,t){t.parentElement.insertBefore(e,t)},e.isArray=I,e.isBool=D,e.isDescendantOf=function(e,t){for(;;){if(null==e.parentElement)return!1;if(e.parentElement===t)return!0;e=e.parentElement}},e.isDocumentExisted=function(){try{document}catch(e){return!1}return!0},e.isFunction=U,e.isIE=function(){return Boolean(window.ActiveXObject||"ActiveXObject"in window)},e.isIsoFormat=function(e){return e.length>15&&e.length<30&&e.match(/^\d{4}-\d{2}-\d{2}T.*Z$/)},e.isNode=function(){return Boolean(void 0!==C().module&&C().module.exports)},e.isNumber=F,e.isNumeric=M,e.isObject=B,e.isOffsetInEl=function(e,t,n){var r=ue(n);return r.x<=e&&r.x+n.offsetWidth>=e&&r.y<=t&&r.y+n.offsetHeight>=t},e.isPromise=function(e){return"[object Promise]"===Object.prototype.toString.call(e)},e.isString=R,e.isWindowDefined=function(){try{return window&&!0}catch(e){return!1}},e.isset=_,e.iterateALL=Z,e.iterateAll=X,e.joinFunctionsByNext=function(e){var t,n=function(){},r=T(X(e,{reverse:!0}));try{for(r.s();!(t=r.n()).done;){n=o(t.value.value,n)}}catch(e){r.e(e)}finally{r.f()}return n;function o(e,t){return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return e.apply(void 0,[t].concat(r))}}},e.joinFunctionsByResult=function(e){for(var t=e[0],n=1;n<e.length;n++)t=r(t,e[n]);return t;function r(e,t){return function(n){args;var r=e(n);return t(r)}}},e.joinMethods=function(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",o=T(e);try{var i=function(){var e=n.value,o=t;t=o?function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return e.call.apply(e,[this,"value"===r?o.call.apply(o,[this].concat(n)):o].concat(n))}:e};for(o.s();!(n=o.n()).done;)i()}catch(e){o.e(e)}finally{o.f()}return t},e.jqFixedSize=function(e){var t=C().jQuery;t(e).each((function(){var e=t(this);e.css({width:e.width()+"px",height:e.height()+"px"})}))},e.jqMakeCarousel=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1e3,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:16,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"left",a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0;o.toString().match(/^\d+$/)&&(o+="px");var c=parseFloat(o),u=C().jQuery,l=u(e),s=l.find(t);l.css({position:"relative",height:l.height()+"px"});var f=s.find(n);f.css({margin:"0",marginRight:o});var h=(Math.ceil(f.width())+c)*f.length;s.css({position:"absolute",margin:"0",width:h+"px"});var d=s.height(),v=s.clone(),p=s.clone();s.css({left:0}),v.css({left:h+"px"}),p.css({left:2*h+"px"});var y=u("<div></div>");y.css({position:"absolute",width:3*h+"px",height:d+"px",left:0,top:a}),y.append(s).append(v).append(p),l.append(y);var g=0;function m(){"left"===i?g-=100:g+=100,y.animate({left:"".concat(g,"px")},r,"linear",(function(){Math.abs(g)>h&&("left"===i?g+=h:g-=h,y.css({left:g+"px"})),m()}))}m()},e.kebabCase=K,e.makeStorageHelper=Te,e.mapObjectTree=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e4,o=0,i=[{value:e}],a=function(){if(o>=r)throw"mapObjectTree: limit(".concat(r,") reached, object may has circular reference");o++;var e=i.shift(),a=e.value,c=e.key,u=e.parent,l=e.newParent,s=t(a,c,u,l),f=function(e,t,r){return I(e)?e=[]:B(e)&&(e={}),u?I(l)&&r?l.push(e):l[t]=e:n=e,e},h=void 0,d=void 0,v=void 0,p=void 0,y=void 0;if(s){var g=s.key,m=s.value;d=m,s.delete||!1===g?v=!0:null==g?h=f(m,c,!0):s.hasOwnProperty("value")&&(h=f(m,g)),p=s.stop,y=s.skip}else d=a,h=f(a,c);if(v)return"continue";if(y)return"continue";if(p)return"break";if(I(d))for(var b=d.length,w=0;w<b;w++)i.push({value:d[w],key:w,parent:d,newParent:h});else B(d)&&Object.keys(d).forEach((function(e){i.push({value:d[e],key:e,parent:d,newParent:h})}))};e:for(;i.length>0;){var c=a();switch(c){case"continue":continue;case"break":break e}}return n},e.mapObjects=te,e.max=H,e.min=function(e,t){return e<t?t:e},e.newArrayRemoveAt=function(e,t){var n,r={},o=T(t=V(t));try{for(o.s();!(n=o.n()).done;){r[n.value]=!0}}catch(e){o.e(e)}finally{o.f()}for(var i=[],a=e.length,c=0;c<a;c++)r[c]||i.push(e[c]);return i},e.numPad=function(e,t){for(var n=e.toString().length;n<t;)e="0"+e,n++;return e},e.numRand=G,e.objectExcept=function(e,t){var n={};for(var r in e)-1===t.indexOf(r)&&(n[r]=e[r]);return n},e.objectGet=ee,e.objectMap=function(e,t){var n={};for(var r in e)n[r]=t(e[r],r,e);return n},e.objectMerge=function(e,t){for(var n in t)e.hasOwnProperty(n)&&B(e[n])&&B(t[n])?Object.assign(e[n],t[n]):e[n]=t[n];return e},e.objectOnly=function(e,t){var n={};for(var r in e)t.indexOf(r)>-1&&(n[r]=e[r]);return n},e.objectSet=function(e,t,n){var r=I(t)?t:t.split("."),o=J(r),i=ee(e,r.slice(0,r.length-1));if(!i)throw"Path does not exist";i[o]=n},e.offDOM=be,e.offsetToViewportPosition=function(e){var t=document.body,n=ue(t),r=fe(t);return{x:e.x+r.x-n.x,y:e.y+r.y-n.y}},e.onDOM=me,e.onDOMMany=function(e,t,n){e=V(e),t=V(t);for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];var a,c=T(e);try{for(c.s();!(a=c.n()).done;){var u,l=a.value,s=T(t);try{for(s.s();!(u=s.n()).done;){var f=u.value;me.apply(void 0,[l,f,n].concat(o))}}catch(e){s.e(e)}finally{s.f()}}}catch(e){c.e(e)}finally{c.f()}var h=function(){var r,o=T(e);try{for(o.s();!(r=o.n()).done;){var i,a=r.value,c=T(t);try{for(c.s();!(i=c.n()).done;){be(a,i.value,n)}}catch(e){c.e(e)}finally{c.f()}}}catch(e){o.e(e)}finally{o.f()}};return h},e.onQuickKeydown=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=P({timeout:1e3},t);var n,r="",o=function(o){o.key&&1===o.key.length&&(r="".concat(r).concat(o.key),e(r),n&&(clearTimeout(n),n=null),n=setTimeout((function(){r=""}),t.timeout))};return me(document,"keydown",o),function(){be(document,"keydown",o)}},e.openCenterWindow=function(e,t,n,r){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},i={width:n,height:r,top:(C().screen.availHeight-30-r)/2,left:(C().screen.availWidth-30-n)/2};Object.assign(i,o),Pe(e,t,i)},e.openWindow=Pe,e.pairRows=function(e,t,n,r){r||(r=n);var o=te(t,r);return e.map((function(e){return[e,o[e[n]]]}))},e.parseISO=function(e){var t,n,r,o=e.split("T"),i=p(o,2),a=i[0],c=i[1],u=0,l=0,s=0,f=a.split("-").map((function(e){return parseInt(e)})),h=p(f,3);if(t=h[0],n=h[1],r=h[2],n-=1,c){var d=c.split("-").map((function(e){return parseFloat(e)}));u=d[0],null!=d[1]&&(l=d[1]),null!=d[2]&&(s=d[2])}var v=new Date(t,n,r,u,l,s);return v.setUTCHours(u),v},e.prependTo=function(e,t){t.insertBefore(e,t.firstChild)},e.promiseTimeout=function(e,t){return new Promise((function(n,r){var o,i;e.then((function(){clearTimeout(o),n.apply(void 0,arguments)}),(function(){i||(clearTimeout(o),r.apply(void 0,arguments))})),o=setTimeout((function(){i=!0;var e=new Error("Promise timeout!");e.name="timeout",r(e)}),t)}))},e.removeClass=function(e,t){e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi")," ")},e.removeEl=function(e){if(null!==e.parentNode)return e.parentNode.removeChild(e)},e.replaceMultiple=function(e,t){var n=new RegExp(Object.keys(e).join("|"),"g");return t.replace(n,(function(t){return e[t]}))},e.resolveArgsByType=function(e,t){var n=0;return t.map((function(t){var r,o;if(I(t)?(r=t[0],o=t[1]):(r=t,o=void 0),!U(r))if(null==r)r=function(){return!0};else{var i=r;r=function(e){return Object.prototype.toString.call(e)==="[object ".concat(i,"]")}}var a=e[n];return r(a)?(n++,a):o}))},e.resolveValueOrGettter=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return U(e)?e.apply(void 0,j(t)):e},e.restoreAttr=ve,e.retry=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;L.retry||(L.retry={});var r=e,o=a();return r[o]=0,i;function i(e,a,c){return t(e,a,c).then((function(e){return delete r[o],e})).catch((function(t){return r[o]++,r[o]>=n?(delete r[o],Promise.reject(t)):i(e,a,c)}))}function a(){var e=Math.random()+"";return r[e]?a():e}},e.setElChildByIndex=function(e,t,n){n.childComponentIndex=t;var r=e.childNodes.length;if(0===r)e.appendChild(n);else if(0===t)e.insertBefore(n,e.childNodes[0]);else{var o=Se(e.childNodes,(function(e){return e.childComponentIndex-t}),0,H(t,r-1),!0),i=o.index,a=o.value;if(o.bigger)e.insertBefore(n,a);else{var c=e.childNodes[i+1];c?e.insertBefore(n,c):e.appendChild(n)}}},e.snakeCase=function(e){return K(e).replace(/-/g,"_")},e.splitArray=Q,e.store=L,e.store_executeOnceInScopeByName={},e.strRand=$,e.studlyCase=W,e.titleCase=function(e){return Y(W(z(e))).join(" ").replace(/\bid\b/gi,"ID")},e.toArrayIfNot=V,e.uniqueId=function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"id_",n=t+$();L.uniqueId||(L.uniqueId={});var r=L.uniqueId;return document.getElementById(n)||r[n]?e(t):(r[n]=!0,n)},e.unset=function(e,t){e[t]=void 0;try{delete e[t]}catch(e){}},e.viewportPositionToOffset=function(e){var t=document.body,n=ue(t),r=fe(t);return{x:e.x+n.x-r.x,y:e.y+n.y-r.y}},e.waitFor=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1e3;U(e)&&(r=n,n=M(t)?t:100,t=e,e=null),L.waitFor||(L.waitFor={});var o=L.waitFor;return e&&_(o[e])&&(C().clearInterval(o[e]),delete o[e]),new Promise((function(i,a){var c=0;function u(n){c<=r?t()&&(l(n,e),i()):(l(n,e),a(new Error("waitFor: Limit is reached"))),c++}function l(e,t){e&&(t&&_(o[t])?(C().clearInterval(o[t]),delete o[t]):C().clearInterval(e))}var s=C().setInterval((function(){u(s)}),n);e&&(o[e]=s),u()}))},e.waitTime=Ee,e.walkTreeData=re,e.watchChange=function(e,t){var n;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=e.apply(void 0,o);n!==a&&t.apply(void 0,[a].concat(o)),n=a}},e.windowLoaded=function(){return new Promise((function(e,t){document&&"complete"===document.readyState?e():C().addEventListener("load",(function t(){e(),C().removeEventListener("load",t)}))}))},Object.defineProperty(e,"__esModule",{value:!0})}));
{
"name": "helper-js",
"version": "1.4.37",
"version": "1.4.38",
"description": "",

@@ -5,0 +5,0 @@ "main": "dist/helper-js.cjs.js",

@@ -63,2 +63,3 @@ # helper-js

###### arrayWithoutEnd(arr, len)
###### arrayFlat(arr, depth=10)
###### assignIfDifferent(obj, key, val)

@@ -65,0 +66,0 @@ ###### objectMerge (obj1, obj2) // merge obj2 to obj1, and merge obj2 chldren to obj1 if it is object

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc