You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
9.3 KiB
1 line
9.3 KiB
|
3 years ago
|
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var n=t();for(var r in n)("object"==typeof exports?exports:e)[r]=n[r]}}(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};e.exports={type:function(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()},isObject:function(e,t){return t?"object"===this.type(e):e&&"object"===(void 0===e?"undefined":r(e))},isFormData:function(e){return"undefined"!=typeof FormData&&e instanceof FormData},trim:function(e){return e.replace(/(^\s*)|(\s*$)/g,"")},encode:function(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")},formatParams:function(e){function t(e,s){var a=o.encode,i=o.type(e);if("array"==i)e.forEach(function(e,n){o.isObject(e)||(n=""),t(e,s+"%5B"+n+"%5D")});else if("object"==i)for(var u in e)s?t(e[u],s+"%5B"+a(u)+"%5D"):t(e[u],a(u));else r||(n+="&"),r=!1,n+=s+"="+a(e)}var n="",r=!0,o=this;return this.isObject(e)?(t(e,""),n):e},merge:function(e,t){for(var n in t)e.hasOwnProperty(n)?this.isObject(t[n],1)&&this.isObject(e[n],1)&&this.merge(e[n],t[n]):e[n]=t[n];return e}}},function(e,t,n){function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e){return function(){function t(){r(this,t),this.requestHeaders={},this.readyState=0,this.timeout=0,this.responseURL="",this.responseHeaders={}}return a(t,[{key:"_call",value:function(e){this[e]&&this[e].apply(this,[].splice.call(arguments,1))}},{key:"_changeReadyState",value:function(e){this.readyState=e,this._call("onreadystatechange")}},{key:"open",value:function(e,t){if(this.method=e,t){if(t=i.trim(t),0!==t.indexOf("http")&&u){var n=document.createElement("a");n.href=t,t=n.href}}else t=location.href;this.responseURL=t,this._changeReadyState(1)}},{key:"send",value:function(t){var n=this;t=t||null;var r=this;if(e){var o={method:r.method,url:r.responseURL,headers:r.requestHeaders||{},body:t};i.merge(o,r._options||{}),"GET"===o.method&&(o.body=null),r._changeReadyState(3);var a=void 0;r.timeout=r.timeout||0,r.timeout>0&&(a=setTimeout(function(){3===r.readyState&&(n._call("onloadend"),r._changeReadyState(0),r._call("ontimeout"))},r.timeout)),o.timeout=r.timeout,e(o,function(e){function t(t){var n=e[t];return delete e[t],n}if(3===r.readyState){clearTimeout(a),r.status=t("statusCode")-0;var n=t("responseText"),o=t("statusMessage");if(r.status){var i=t("headers"),c={};for(var f in i){var l=i[f],p=f.toLowerCase();"object"===(void 0===l?"undefined":s(l))?c[p]=l:(c[p]=c[p]||[],c[p].push(l))}var d=c["set-cookie"];u&&d&&d.forEach(function(e){document.cookie=e.replace(/;\s*httpOnly/gi,"")}),r.responseHeaders=c,r.statusText=o||"",r.response=r.responseText=n,r._response=e,r._changeReadyState(4),r._call("onload")}else r.statusText=n,r._call("onerror",{msg:o});r._call("onloadend")}})}else console.error("Ajax require adapter")}},{key:"setRequestHeader",value:function(e,t){this.requestHeaders[i.trim(e)]=t}},{key:"getResponseHeader",value:function(e){return(this.responseHeaders[e.toLowerCase()]||"").toString()||null}},{key:"getAllResponseHeaders",value:function(){var e="";for(var t in this.responseHeaders)e+=t+":"+this.getResponseHeader(t)+"\r\n";return e||null}},{key:"abort",value
|