mirror of
https://github.com/Permissionless-Software-Foundation/bch-dex-taker-v2.git
synced 2026-09-21 16:52:01 -07:00
1 line
1.4 MiB
JavaScript
1 line
1.4 MiB
JavaScript
!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).SlpWallet=t();}}(function(){for(var define,module,exports,createModuleFactory=function(t){var e;return function(r){return e||t(e={exports:{},parent:r},e.exports),e.exports;};},_$defaults_172=createModuleFactory(function(t,e){(function(e){(function(){"use strict";var r={"Content-Type":"application/x-www-form-urlencoded"};function i(t,e){!_$utils_185.isUndefined(t)&&_$utils_185.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e);}var n,o={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==e&&"[object process]"===Object.prototype.toString.call(e))&&(n=_$xhr_158({})),n),transformRequest:[function(t,e){return _$normalizeHeaderName_181(e,"Accept"),_$normalizeHeaderName_181(e,"Content-Type"),_$utils_185.isFormData(t)||_$utils_185.isArrayBuffer(t)||_$utils_185.isBuffer(t)||_$utils_185.isStream(t)||_$utils_185.isFile(t)||_$utils_185.isBlob(t)?t:_$utils_185.isArrayBufferView(t)?t.buffer:_$utils_185.isURLSearchParams(t)?(i(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):_$utils_185.isObject(t)||e&&"application/json"===e["Content-Type"]?(i(e,"application/json"),function(t,e,r){if(_$utils_185.isString(t))try{return(0,JSON.parse)(t),_$utils_185.trim(t);}catch(i){if("SyntaxError"!==i.name)throw i;}return(0,JSON.stringify)(t);}(t)):t;}],transformResponse:[function(t){var e=this.transitional||o.transitional,r=e&&e.silentJSONParsing,i=e&&e.forcedJSONParsing,n=!r&&"json"===this.responseType;if(n||i&&_$utils_185.isString(t)&&t.length)try{return JSON.parse(t);}catch(a){if(n){if("SyntaxError"===a.name)throw _$enhanceError_168(a,this,"E_JSON_PARSE");throw a;}}return t;}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300;},headers:{common:{Accept:"application/json, text/plain, */*"}}};_$utils_185.forEach(["delete","get","head"],function(t){o.headers[t]={};}),_$utils_185.forEach(["post","put","patch"],function(t){o.headers[t]=_$utils_185.merge(r);}),t.exports=o;}).call(this);}).call(this,_$browser_416);}),_$xhr_158=createModuleFactory(function(t,e){"use strict";var r=_$defaults_172({});t.exports=function(t){return new Promise(function(e,i){var n,o=t.data,a=t.headers,s=t.responseType;function u(){t.cancelToken&&t.cancelToken.unsubscribe(n),t.signal&&t.signal.removeEventListener("abort",n);}_$utils_185.isFormData(o)&&delete a["Content-Type"];var h=new XMLHttpRequest();if(t.auth){var f=t.auth.username||"",c=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";a.Authorization="Basic "+btoa(f+":"+c);}var l=_$buildFullPath_165(t.baseURL,t.url);function d(){if(h){var r=("getAllResponseHeaders"in h)?_$parseHeaders_182(h.getAllResponseHeaders()):null,n={data:s&&"text"!==s&&"json"!==s?h.response:h.responseText,status:h.status,statusText:h.statusText,headers:r,config:t,request:h};_$settle_170(function(t){e(t),u();},function(t){i(t),u();},n),h=null;}}if(h.open(t.method.toUpperCase(),_$buildURL_175(l,t.params,t.paramsSerializer),!0),h.timeout=t.timeout,("onloadend"in h)?h.onloadend=d:h.onreadystatechange=function(){h&&4===h.readyState&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))&&setTimeout(d);},h.onabort=function(){h&&(i(_$createError_166("Request aborted",t,"ECONNABORTED",h)),h=null);},h.onerror=function(){i(_$createError_166("Network Error",t,null,h)),h=null;},h.ontimeout=function(){var e=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded",n=t.transitional||r.transitional;t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),i(_$createError_166(e,t,n.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",h)),h=null;},_$utils_185.isStandardBrowserEnv()){var _=(t.withCredentials||_$isURLSameOrigin_180(l))&&t.xsrfCookieName?_$cookies_177.read(t.xsrfCookieName):void
|