@yunzhijia/qing
Version:
> qingjs是为了方便前端人员在云之家环境调用native代码的工具类,兼容新版桌面端、老版桌面端、移动端、微信
10 lines • 27.8 kB
JavaScript
/** Fri Sep 15 2023 13:31:58 GMT+0800 (中国标准时间) **/
(()=>{var t={1145:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){var e=t.ready,r=["call","off","on","once","checkJsApi","trigger","register"];r.forEach(function(r){t[r]=function(){var i=(0,n.Z)(arguments);e(function(){t[r].apply(t,i),i=null})}}),t.Events=t.utils.Events,t.error=function(e){t.on("error",e)},e(function(){var e=t._bridge;r.forEach(function(r){console.log("map....",r),t[r]=e[r]})})})});var n=r(3022)},4441:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){t._simulate=a,t.ready(function(){t.checkJsApi=o,t.call=s})})});var n=window.qing,i={};function o(t){var e={};(t.jsApiList||[]).forEach(function(t){i[t]&&(e[t]=!0)});var r=t.success,o=t.complete;t.success=function(t,n){if(t.success)for(var i in e)t.data[i]=!0;n||(n={code:200,data:t}),r&&r(t,n),o&&o(t,n)},t.complete=void 0,n._bridge.checkJsApi(t)}function s(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=i[t],o=e;if(e.complete&&(!e.success||!e.success.__wrap)){for(var a in o={},e)o[a]=e[a];delete o.complete,o.success=function(t,r){r||(r={code:200,data:t}),e.success&&e.success(t,r),e.complete&&e.complete(t,r)},o.error=function(t,r){r||(r={code:200,data:t}),e.error&&e.error(t,r),e.complete&&e.complete(t,r)},o.success.__wrap=!0}if(r){var u=r(o);if(!u)return;if(u.raw)return u.raw;if("function"==typeof u.then)return u.then(function(t){s(t.name,t.params)});if(u.simulate)return s(u.name,u.params);t=u.name,o=u.params}return n._bridge.call(t,o)}function a(t,e,r){e&&(i[t]=e)}},4300:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){t.checkVersion=function(e){var r=t.nativeJsBridgeVersion;if(!r||"string"!=typeof e)return!1;if(r==e)return!0;for(var n=r.split("."),i=e.split("."),o=Math.max(n.length,i.length),s=0;s<o;s++){var a=~~i[s],u=~~n[s];if(a<u)return!0;if(a>u)return!1}}})})},903:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){t.config=function(e){t.debug=!!e.debug,t.ready(function(){t._bridge.config(e),(e.jsEventList||[]).forEach(function(e){-1==i.indexOf(e)&&(i.push(e),t.on(e,function(t){(0,n.Z)(e,{data:t})}))})})}})});var n=r(9165),i=[]},51:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){r(4300).S(t),r(634).S(t),r(2010).S(t),r(903).S(t),r(1145).S(t),r(2457).S(t),r(4441).S(t)})});r(7310)},2457:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){t.use=f,t.define=l})});var n=r(468),i=r(6276),o=r(492),s=r(9165),a={},u=new i.Z;function c(t,e,r){(0,o.log)("use "+t);var n=a[t];if(a[t]=!0,n){var i=e._bridge=e._bridge||(e._bridge={on:u.on,once:u.once,off:u.off,config:e.utils.noop,trigger:u.emit,has:u.has});Object.prototype.hasOwnProperty.call(i,"call")||Object.defineProperty(i,"call",{configurable:!0,get:function(){},set:function(t){Object.defineProperty(i,"call",{configurable:!0,writable:!0,value:t}),setTimeout(function(){(0,s.Z)("QingReady")})}}),n.call(e,i,r)}}function f(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.id||t,o=window.qing,s=a[i];if("function"!=typeof s){if(!s){var u=t;/^http[s]?:\/\//.test(u)?(a[i]="loading",(0,n.Z)(u,function(t){t?a[i]=!1:setTimeout(function(){c(i,o,e)})})):r(7940)("./"+u+"/app").then(function(){c(i,o,e)})}}else c(i,o,e)}function l(t,e){a[t]=e}},2010:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){var e=document;if(t._bridge)return void(t.ready=function(t){t&&t()});(t.ready=function(t){e.addEventListener("QingReady",function r(){t(),e.removeEventListener("QingReady",r)})})(function(){(0,n.log)("Ready"),t.isReady=!0,t.ready=function(t){t&&t()}})})});var n=r(492)},634:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){t.utils={today:u,noop:function(){},log:i,Events:n.Z,fetch:s,getURLParams:o.Z.get,emit:c.emit,once:c.once,on:c.on,off:c.off}})});var n=r(6276),i=r(492),o=r(9303);const s=window.fetch||r(4098);var a=new Date,u=a.getFullYear()+"-"+(a.getMonth()+1)+"-"+a.getDate(),c=new n.Z},338:(t,e,r)=>{"use strict";r.d(e,{S:()=>n});var n=function(t){var e=function(t){return t.replace(/(^|;|\s*)deviceName\s*:[^;]*(;|$)/i,";")}(navigator.userAgent.toLowerCase()||""),r=navigator.vendor&&navigator.vendor.toLowerCase()||"",n=navigator.appVersion.toLowerCase()||"",i=t.isWX=t.isWeiXin=/micromessenger/i.test(e);t.isWeCom=i&&/wxwork/i.test(e);t.isChrome=/chrome|chromium/i.test(e)&&/google inc/.test(r),t.isFirefox=/firefox/i.test(e),t.isOpera=/^Opera\//.test(e)||/\x20OPR\//.test(e),t.isSafari=/safari/i.test(e)&&/apple computer/i.test(r),t.isIe=function(t){return t?t>=11?"ActiveXObject"in window:new RegExp("msie "+t).test(e):/msie/i.test(e)||"ActiveXObject"in window};var o=t.isIphone=/iphone/i.test(e),s=t.isIpad=e.match(/(ipad)/i)||"MacIntel"===e.platform&&navigator.maxTouchPoints>1,a=t.isIpod=/ipod/i.test(e),u=(t.isIos=o||s||a,t.isAndroid=/android/i.test(e)),c=t.isAndroidPhone=u&&/mobile/i.test(e),f=t.isAndroidTablet=u&&!/mobile/i.test(e),l=t.isBlackberry=/blackberry/i.test(e),d=t.isCoolpad=/coolpad/i.test(e),h=(t.isMac=!s&&/mac/i.test(n),t.isWindows=/win/i.test(n)),p=t.isWindowsPhone=h&&/phone/i.test(e),y=t.isWindowsTablet=h&&!p&&/touch/i.test(e),v=t.isMobile=o||a||c||l||p||d,b=t.isTablet=s||f||y;t.isDesktop=!v&&!b,t.isTouchDevice="ontouchstart"in window||"DocumentTouch"in window&&document instanceof DocumentTouch;t.isMiniApp="miniapp:"==location.protocol||/miniapp/i.test(e),t.isCloudHub=t.isSupportNativeJsBridge,t.isCloudHubDesktop=t.isCloudHub&&t.isDesktop,t.isCloudHubMobile=t.isCloudHub&&t.isMobile,t.isCloudHubTablet=t.isCloudHub&&t.isTablet}},3022:(t,e,r)=>{"use strict";r.d(e,{Z:()=>(function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=t.length,n=[],i=e;i<r;i++)n.push(t[i]);return n})})},9165:(t,e,r)=>{"use strict";r.d(e,{Z:()=>(function(t,e){var r=document.createEvent("HTMLEvents");if(e)for(var n in e)r[n]=e[n];r.initEvent(t,!1,!1),document.dispatchEvent(r)})})},6276:(t,e,r)=>{"use strict";r.d(e,{Z:()=>(function(){var t={};this.once=function(e,r){t[e]?t[e][0].push(r):t[e]=[[r],[]]},this.on=function(e,r){t[e]?t[e][1].push(r):t[e]=[[],[r]]},this.emit=function(e){var r=(0,n.Z)(arguments,1),i=t[e];if(i){var o=this;i[0].forEach(function(t){t.apply(o,r)}),i[1].forEach(function(t){t.apply(o,r)}),i[0]=[]}},this.off=function(e,r){var n=t[e];n&&(r?n.forEach(function(t){if(t)for(var e=t.length-1;e>=0;e--)r==t[e]&&t.splice(e,1)}):n=[[],[]])},this.has=function(e){var r=t[e];return!!r&&(r[0].length>0||r[1].length>0)}})});var n=r(3022)},492:(t,e,r)=>{"use strict";r.r(e),r.d(e,{error:()=>u,log:()=>s,warn:()=>a});var n=window.localStorage,i=window.console,o=function(){};i&&n&&(o=function(t,e){"1"===n.getItem("__debug")&&i[t](e)});var s=function(t){o("log","[Qing] ".concat(t))},a=function(t){o("warn","[Qing] ".concat(t))},u=function(t){o("error","[Qing] ".concat(t))}},9303:(t,e,r)=>{"use strict";function n(t){var e=t,r={};if(!e)return r;for(var n=0,i=(e=e.replace(/^[?]{1}|[#]{1}.*$/g,"").split("&")).length;n<i;n++){var o=e[n].split("=");r[o[0]]=decodeURIComponent(o[1])}return r}r.d(e,{Z:()=>i});const i=n(window.location.search)},4283:(t,e,r)=>{"use strict";r.d(e,{S:()=>(function(t){n.XuntongJSBridge={call:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;n&&(r.complete=n),t.call(e,r)}}})});var n=window},468:(t,e,r)=>{"use strict";r.d(e,{Z:()=>(function(t,e){var r=document,n=r.getElementsByTagName("head")[0],i=r.createElement("script");i.src=t,e&&(i.onload=function(){e()},i.onerror=e);n.appendChild(i),i=null,n=null})})},4098:function(t,e){var r="undefined"!=typeof self?self:this,n=function(){function t(){this.fetch=!1,this.DOMException=r.DOMException}return t.prototype=r,new t}();!function(t){!function(e){var r={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};if(r.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],i=ArrayBuffer.isView||function(t){return t&&n.indexOf(Object.prototype.toString.call(t))>-1};function o(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function s(t){return"string"!=typeof t&&(t=String(t)),t}function a(t){var e={next:function(){var e=t.shift();return{done:void 0===e,value:e}}};return r.iterable&&(e[Symbol.iterator]=function(){return e}),e}function u(t){this.map={},t instanceof u?t.forEach(function(t,e){this.append(e,t)},this):Array.isArray(t)?t.forEach(function(t){this.append(t[0],t[1])},this):t&&Object.getOwnPropertyNames(t).forEach(function(e){this.append(e,t[e])},this)}function c(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function f(t){return new Promise(function(e,r){t.onload=function(){e(t.result)},t.onerror=function(){r(t.error)}})}function l(t){var e=new FileReader,r=f(e);return e.readAsArrayBuffer(t),r}function d(t){if(t.slice)return t.slice(0);var e=new Uint8Array(t.byteLength);return e.set(new Uint8Array(t)),e.buffer}function h(){return this.bodyUsed=!1,this._initBody=function(t){this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:r.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:r.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():r.arrayBuffer&&r.blob&&function(t){return t&&DataView.prototype.isPrototypeOf(t)}(t)?(this._bodyArrayBuffer=d(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):r.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||i(t))?this._bodyArrayBuffer=d(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},r.blob&&(this.blob=function(){var t=c(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?c(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(l)}),this.text=function(){var t=c(this);if(t)return t;if(this._bodyBlob)return function(t){var e=new FileReader,r=f(e);return e.readAsText(t),r}(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var e=new Uint8Array(t),r=new Array(e.length),n=0;n<e.length;n++)r[n]=String.fromCharCode(e[n]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},r.formData&&(this.formData=function(){return this.text().then(v)}),this.json=function(){return this.text().then(JSON.parse)},this}u.prototype.append=function(t,e){t=o(t),e=s(e);var r=this.map[t];this.map[t]=r?r+", "+e:e},u.prototype.delete=function(t){delete this.map[o(t)]},u.prototype.get=function(t){return t=o(t),this.has(t)?this.map[t]:null},u.prototype.has=function(t){return this.map.hasOwnProperty(o(t))},u.prototype.set=function(t,e){this.map[o(t)]=s(e)},u.prototype.forEach=function(t,e){for(var r in this.map)this.map.hasOwnProperty(r)&&t.call(e,this.map[r],r,this)},u.prototype.keys=function(){var t=[];return this.forEach(function(e,r){t.push(r)}),a(t)},u.prototype.values=function(){var t=[];return this.forEach(function(e){t.push(e)}),a(t)},u.prototype.entries=function(){var t=[];return this.forEach(function(e,r){t.push([r,e])}),a(t)},r.iterable&&(u.prototype[Symbol.iterator]=u.prototype.entries);var p=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function y(t,e){var r=(e=e||{}).body;if(t instanceof y){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,e.headers||(this.headers=new u(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,r||null==t._bodyInit||(r=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=e.credentials||this.credentials||"same-origin",!e.headers&&this.headers||(this.headers=new u(e.headers)),this.method=function(t){var e=t.toUpperCase();return p.indexOf(e)>-1?e:t}(e.method||this.method||"GET"),this.mode=e.mode||this.mode||null,this.signal=e.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&r)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(r)}function v(t){var e=new FormData;return t.trim().split("&").forEach(function(t){if(t){var r=t.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");e.append(decodeURIComponent(n),decodeURIComponent(i))}}),e}function b(t,e){e||(e={}),this.type="default",this.status=void 0===e.status?200:e.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in e?e.statusText:"OK",this.headers=new u(e.headers),this.url=e.url||"",this._initBody(t)}y.prototype.clone=function(){return new y(this,{body:this._bodyInit})},h.call(y.prototype),h.call(b.prototype),b.prototype.clone=function(){return new b(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new u(this.headers),url:this.url})},b.error=function(){var t=new b(null,{status:0,statusText:""});return t.type="error",t};var m=[301,302,303,307,308];b.redirect=function(t,e){if(-1===m.indexOf(e))throw new RangeError("Invalid status code");return new b(null,{status:e,headers:{location:t}})},e.DOMException=t.DOMException;try{new e.DOMException}catch(t){e.DOMException=function(t,e){this.message=t,this.name=e;var r=Error(t);this.stack=r.stack},e.DOMException.prototype=Object.create(Error.prototype),e.DOMException.prototype.constructor=e.DOMException}function g(t,n){return new Promise(function(i,o){var s=new y(t,n);if(s.signal&&s.signal.aborted)return o(new e.DOMException("Aborted","AbortError"));var a=new XMLHttpRequest;function c(){a.abort()}a.onload=function(){var t={status:a.status,statusText:a.statusText,headers:function(t){var e=new u;return t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach(function(t){var r=t.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();e.append(n,i)}}),e}(a.getAllResponseHeaders()||"")};t.url="responseURL"in a?a.responseURL:t.headers.get("X-Request-URL");var e="response"in a?a.response:a.responseText;i(new b(e,t))},a.onerror=function(){o(new TypeError("Network request failed"))},a.ontimeout=function(){o(new TypeError("Network request failed"))},a.onabort=function(){o(new e.DOMException("Aborted","AbortError"))},a.open(s.method,s.url,!0),"include"===s.credentials?a.withCredentials=!0:"omit"===s.credentials&&(a.withCredentials=!1),"responseType"in a&&r.blob&&(a.responseType="blob"),s.headers.forEach(function(t,e){a.setRequestHeader(e,t)}),s.signal&&(s.signal.addEventListener("abort",c),a.onreadystatechange=function(){4===a.readyState&&s.signal.removeEventListener("abort",c)}),a.send(void 0===s._bodyInit?null:s._bodyInit)})}g.polyfill=!0,t.fetch||(t.fetch=g,t.Headers=u,t.Request=y,t.Response=b),e.Headers=u,e.Request=y,e.Response=b,e.fetch=g,Object.defineProperty(e,"__esModule",{value:!0})}({})}(n),n.fetch.ponyfill=!0,delete n.fetch.polyfill;var i=n;(e=i.fetch).default=i.fetch,e.fetch=i.fetch,e.Headers=i.Headers,e.Request=i.Request,e.Response=i.Response,t.exports=e},7310:(t,e,r)=>{"use strict";t.exports=r(2702).polyfill()},2702:function(t,e,r){
/*!
* @overview es6-promise - a tiny implementation of Promises/A+.
* @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
* @license Licensed under MIT license
* See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
* @version v4.2.8+1e68dce6
*/
!function(e,n){t.exports=function(){"use strict";function t(t){return"function"==typeof t}var e=void 0;e=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var n=e,i=0,o=void 0,s=void 0,a=function(t,e){p[i]=t,p[i+1]=e,2===(i+=2)&&(s?s(y):v())};var u="undefined"!=typeof window?window:void 0,c=u||{},f=c.MutationObserver||c.WebKitMutationObserver,l="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function h(){var t=setTimeout;return function(){return t(y,1)}}var p=new Array(1e3);function y(){for(var t=0;t<i;t+=2){var e=p[t],r=p[t+1];e(r),p[t]=void 0,p[t+1]=void 0}i=0}var v=void 0;v=l?function(){return function(){return process.nextTick(y)}}():f?function(){var t=0,e=new f(y),r=document.createTextNode("");return e.observe(r,{characterData:!0}),function(){r.data=t=++t%2}}():d?function(){var t=new MessageChannel;return t.port1.onmessage=y,function(){return t.port2.postMessage(0)}}():void 0===u?function(){try{var t=Function("return this")().require("vertx");return o=t.runOnLoop||t.runOnContext,function(){if(void 0!==o)return function(){o(y)};return h()}()}catch(t){return h()}}():h();function b(t,e){var r=this,n=new this.constructor(w);void 0===n[g]&&C(n);var i=r._state;if(i){var o=arguments[i-1];a(function(){return q(i,n,o,r._result)})}else P(r,n,t,e);return n}function m(t){if(t&&"object"==typeof t&&t.constructor===this)return t;var e=new this(w);return O(e,t),e}var g=Math.random().toString(36).substring(2);function w(){}var _=void 0,E=1,j=2;function A(e,r,n){r.constructor===e.constructor&&n===b&&r.constructor.resolve===m?function(t,e){e._state===E?x(t,e._result):e._state===j?S(t,e._result):P(e,void 0,function(e){return O(t,e)},function(e){return S(t,e)})}(e,r):void 0===n?x(e,r):t(n)?function(t,e,r){a(function(t){var n=!1,i=function(t,e,r,n){try{t.call(e,r,n)}catch(t){return t}}(r,e,function(r){n||(n=!0,e!==r?O(t,r):x(t,r))},function(e){n||(n=!0,S(t,e))},t._label);!n&&i&&(n=!0,S(t,i))},t)}(e,r,n):x(e,r)}function O(t,e){if(t===e)S(t,function(){return new TypeError("You cannot resolve a promise with itself")}());else if(function(t){var e=typeof t;return null!==t&&("object"===e||"function"===e)}(e)){var r=void 0;try{r=e.then}catch(e){return void S(t,e)}A(t,e,r)}else x(t,e)}function T(t){t._onerror&&t._onerror(t._result),B(t)}function x(t,e){t._state===_&&(t._result=e,t._state=E,0!==t._subscribers.length&&a(B,t))}function S(t,e){t._state===_&&(t._state=j,t._result=e,a(T,t))}function P(t,e,r,n){var i=t._subscribers,o=i.length;t._onerror=null,i[o]=e,i[o+E]=r,i[o+j]=n,0===o&&t._state&&a(B,t)}function B(t){var e=t._subscribers,r=t._state;if(0!==e.length){for(var n=void 0,i=void 0,o=t._result,s=0;s<e.length;s+=3)n=e[s],i=e[s+r],n?q(r,n,i,o):i(o);t._subscribers.length=0}}function q(e,r,n,i){var o=t(n),s=void 0,a=void 0,u=!0;if(o){try{s=n(i)}catch(t){u=!1,a=t}if(r===s)return void S(r,function(){return new TypeError("A promises callback cannot return that same promise.")}())}else s=i;r._state!==_||(o&&u?O(r,s):!1===u?S(r,a):e===E?x(r,s):e===j&&S(r,s))}var D=0;function C(t){t[g]=D++,t._state=void 0,t._result=void 0,t._subscribers=[]}var M=function(){function t(t,e){this._instanceConstructor=t,this.promise=new t(w),this.promise[g]||C(this.promise),n(e)?(this.length=e.length,this._remaining=e.length,this._result=new Array(this.length),0===this.length?x(this.promise,this._result):(this.length=this.length||0,this._enumerate(e),0===this._remaining&&x(this.promise,this._result))):S(this.promise,function(){return new Error("Array Methods must be provided an Array")}())}return t.prototype._enumerate=function(t){for(var e=0;this._state===_&&e<t.length;e++)this._eachEntry(t[e],e)},t.prototype._eachEntry=function(t,e){var r=this._instanceConstructor,n=r.resolve;if(n===m){var i=void 0,o=void 0,s=!1;try{i=t.then}catch(t){s=!0,o=t}if(i===b&&t._state!==_)this._settledAt(t._state,e,t._result);else if("function"!=typeof i)this._remaining--,this._result[e]=t;else if(r===k){var a=new r(w);s?S(a,o):A(a,t,i),this._willSettleAt(a,e)}else this._willSettleAt(new r(function(e){return e(t)}),e)}else this._willSettleAt(n(t),e)},t.prototype._settledAt=function(t,e,r){var n=this.promise;n._state===_&&(this._remaining--,t===j?S(n,r):this._result[e]=r),0===this._remaining&&x(n,this._result)},t.prototype._willSettleAt=function(t,e){var r=this;P(t,void 0,function(t){return r._settledAt(E,e,t)},function(t){return r._settledAt(j,e,t)})},t}();var k=function(){function e(t){this[g]=function(){return D++}(),this._result=this._state=void 0,this._subscribers=[],w!==t&&("function"!=typeof t&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof e?function(t,e){try{e(function(e){O(t,e)},function(e){S(t,e)})}catch(e){S(t,e)}}(this,t):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return e.prototype.catch=function(t){return this.then(null,t)},e.prototype.finally=function(e){var r=this.constructor;return t(e)?this.then(function(t){return r.resolve(e()).then(function(){return t})},function(t){return r.resolve(e()).then(function(){throw t})}):this.then(e,e)},e}();return k.prototype.then=b,k.all=function(t){return new M(this,t).promise},k.race=function(t){var e=this;return n(t)?new e(function(r,n){for(var i=t.length,o=0;o<i;o++)e.resolve(t[o]).then(r,n)}):new e(function(t,e){return e(new TypeError("You must pass an array to race."))})},k.resolve=m,k.reject=function(t){var e=new this(w);return S(e,t),e},k._setScheduler=function(t){s=t},k._setAsap=function(t){a=t},k._asap=a,k.polyfill=function(){var t=void 0;if(void 0!==r.g)t=r.g;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var n=null;try{n=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===n&&!e.cast)return}t.Promise=k},k.Promise=k,k}()}()},7940:(t,e,r)=>{var n={"./desktop-le3/app":[8905,7,905],"./desktop-remote/app":[7237,7,237],"./desktop/app":[579,7,483,579],"./mobile-early/app":[4769,9,769],"./mobile/app":[2271,7,483,271],"./theme/app":[530,7,530],"./web/app":[3418,9,483,418]};function i(t){if(!r.o(n,t))return Promise.resolve().then(()=>{var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e});var e=n[t],i=e[0];return Promise.all(e.slice(2).map(r.e)).then(()=>r.t(i,16|e[1]))}i.keys=(()=>Object.keys(n)),i.id=7940,t.exports=i}},e={};function r(n){var i=e[n];if(void 0!==i)return i.exports;var o=e[n]={exports:{}};return t[n].call(o.exports,o,o.exports,r),o.exports}r.m=t,(()=>{r.n=(t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e})})(),(()=>{var t,e=Object.getPrototypeOf?t=>Object.getPrototypeOf(t):t=>t.__proto__;r.t=function(n,i){if(1&i&&(n=this(n)),8&i)return n;if("object"==typeof n&&n){if(4&i&&n.__esModule)return n;if(16&i&&"function"==typeof n.then)return n}var o=Object.create(null);r.r(o);var s={};t=t||[null,e({}),e([]),e(e)];for(var a=2&i&&n;"object"==typeof a&&!~t.indexOf(a);a=e(a))Object.getOwnPropertyNames(a).forEach(t=>s[t]=(()=>n[t]));return s.default=(()=>n),r.d(o,s),o}})(),(()=>{r.d=((t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})})})(),(()=>{r.f={},r.e=(t=>Promise.all(Object.keys(r.f).reduce((e,n)=>(r.f[n](t,e),e),[])))})(),(()=>{r.u=(t=>({234:"bdf7d6562c39f766908a",237:"ad9358d940fd3a98bfda",271:"2f56d82b9adcdfbea754",418:"13cca5933800cdbbf08b",483:"f95797a7afe43c533ded",530:"52ee18701c3dacae7fc5",579:"64f79e55324e5c3622d0",769:"e29ef7e9ab26776ccf80",905:"ee31e357ba0309811530"})[t]+".js")})(),(()=>{r.miniCssF=(t=>{})})(),(()=>{r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}()})(),(()=>{r.o=((t,e)=>Object.prototype.hasOwnProperty.call(t,e))})(),(()=>{var t={};r.l=((e,n,i,o)=>{if(t[e])t[e].push(n);else{var s,a;if(void 0!==i)for(var u=document.getElementsByTagName("script"),c=0;c<u.length;c++){var f=u[c];if(f.getAttribute("src")==e||f.getAttribute("data-webpack")=="@yunzhijia/qing:"+i){s=f;break}}s||(a=!0,(s=document.createElement("script")).charset="utf-8",s.timeout=120,r.nc&&s.setAttribute("nonce",r.nc),s.setAttribute("data-webpack","@yunzhijia/qing:"+i),s.src=e),t[e]=[n];var l=(r,n)=>{s.onerror=s.onload=null,clearTimeout(d);var i=t[e];if(delete t[e],s.parentNode&&s.parentNode.removeChild(s),i&&i.forEach(t=>t(n)),r)return r(n)},d=setTimeout(l.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=l.bind(null,s.onerror),s.onload=l.bind(null,s.onload),a&&document.head.appendChild(s)}})})(),(()=>{r.r=(t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})})})(),(()=>{r.p="https://static.yunzhijia.com/public/js/qing/1.0.1"})(),r.f.compat=((t,e)=>{switch(t){case 234:return require(["@yunzhijia/qing/bdf7d6562c39f766908a.js"]);case 237:return require(["@yunzhijia/qing/ad9358d940fd3a98bfda.js"]);case 271:return require(["@yunzhijia/qing/2f56d82b9adcdfbea754.js"]);case 418:return require(["@yunzhijia/qing/13cca5933800cdbbf08b.js"]);case 483:return require(["@yunzhijia/qing/f95797a7afe43c533ded.js"]);case 530:return require(["@yunzhijia/qing/52ee18701c3dacae7fc5.js"]);case 579:return require(["@yunzhijia/qing/64f79e55324e5c3622d0.js"]);case 769:return require(["@yunzhijia/qing/e29ef7e9ab26776ccf80.js"]);case 905:return require(["@yunzhijia/qing/ee31e357ba0309811530.js"])}}),(()=>{var t={114:0};r.f.j=((e,n)=>{var i=r.o(t,e)?t[e]:void 0;if(0!==i)if(i)n.push(i[2]);else{var o=new Promise((r,n)=>i=t[e]=[r,n]);n.push(i[2]=o);var s=r.p+r.u(e),a=new Error;r.l(s,n=>{if(r.o(t,e)&&(0!==(i=t[e])&&(t[e]=void 0),i)){var o=n&&("load"===n.type?"missing":n.type),s=n&&n.target&&n.target.src;a.message="Loading chunk "+e+" failed.\n("+o+": "+s+")",a.name="ChunkLoadError",a.type=o,a.request=s,i[1](a)}},"chunk-"+e,e)}});var e=(e,n)=>{var i,o,[s,a,u]=n,c=0;if(s.some(e=>0!==t[e])){for(i in a)r.o(a,i)&&(r.m[i]=a[i]);if(u)u(r)}for(e&&e(n);c<s.length;c++)o=s[c],r.o(t,o)&&t[o]&&t[o][0](),t[o]=0},n=self.qingJsonpFunction=self.qingJsonpFunction||[];n.forEach(e.bind(null,0)),n.push=e.bind(null,n.push.bind(n))})(),(()=>{!function(t){if(!t.qing||!t.qing.version){var e=t.qing||(t.qing={});e.version="1.0.1",e.isReady=!1,e.debug=!1,e.origin="",e.assertHost="https://static.yunzhijia.com",e._public?e.assertPath=e._public+process.env.CONTEXT_PATH:e.assertPath="https://static.yunzhijia.com";var n=navigator.userAgent.toLowerCase(),i=n.match(/Qing\/(\d+(?:\.\d+)*)/i)||n.match(/App\/cloudhub \d+\/(\d+(?:\.\d+)*)/i),o=i;o&&(e.nativeJsBridgeVersion=i[1]),e.isSupportNativeJsBridge=!!o,r(51).S(e),r(338).S(e),r(4283).S(e),setTimeout(function(){if(o)e.isMiniApp&&(e.assertPath="miniapp://common/js/qing",e.call("getMiniAppInfo",{success:function(t){if(!t.success)return!1;e.origin=t.data.origin}})),e.isDesktop?parseInt(e.nativeJsBridgeVersion.replace(/\./g,""))>3?e.use("desktop"):e.use("desktop-le3"):e.checkVersion("0.9.50")?e.use("mobile"):e.use("mobile-early");else if(e.isWeCom){var t=e.assertHost+"/infra/jsbridge/wecom.js?"+e.utils.today;e.use(t,{id:"wecom"})}else if(e.isWeiXin){var r=e.assertHost+"/infra/jsbridge/weixin.js?"+e.utils.today;e.use(r,{id:"weixin"})}else e.use("web")})}}(window)})()})();