kitchendDevice/unpackage/dist/build/mp-weixin/common/vendor.js

14 lines
377 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["common/vendor"],{"011a":function(e,t){function n(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(e.exports=n=function(){return!!t},e.exports.__esModule=!0,e.exports["default"]=e.exports)()}e.exports=n,e.exports.__esModule=!0,e.exports["default"]=e.exports},"069d":function(e,t,n){"use strict";(function(e){var r=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n("af34"));r(n("b3c9"));function o(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return a(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(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return a(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}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 o,s=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){c=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(c)throw o}}}}function a(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 s={msg:function(t){e.showToast({title:t,icon:"none"})},ab2hex:function(e,t){var n=Array.prototype.map.call(new Uint8Array(e),(function(e){return("00"+e.toString(16)).slice(-2)}));return n.join(t)},getTime:function(){var e=new Date,t=e.getFullYear(),n=e.getMonth()+1<10?"0"+(e.getMonth()+1):e.getMonth()+1,r=e.getDate()<10?"0"+e.getDate():e.getDate(),i=e.getHours()>9?e.getHours():"0"+e.getHours(),o=e.getMinutes()>9?e.getMinutes():"0"+e.getMinutes();return t+"/"+n+"/"+r+" "+i+":"+o},getDate:function(e){var t=new Date,n=t.getFullYear(),r=t.getMonth()+1,i=t.getDate();if(r=r>9?r:"0"+r,i=i>9?i:"0"+i,"start"===e)return n=n,"".concat(n,"-").concat(r,"-").concat(i);if("month"===e)return r+"月"+i+"日"},getMonth:function(e,t){var n=new Date(e.substring(0,10)),r=n.getFullYear(),i=n.getMonth()+1;Math.abs(t)>12&&(t%=12);0!=t&&(i+t>12?(r++,i=(i+t)%12):i+t<1?(r--,i=12+i+t):i+=t);i=i<10?"0"+i:i;n.getDate();return"01"==i||"03"==i||"05"==i||"07"==i||"08"==i||"10"==i||"12"==i?r+"-"+i+"-01~"+r+"-"+i+"-31":"02"==i?r%4==0&&r%100!=0||r%100==0&&r%400==0?r+"-"+i+"-01~"+r+"-"+i+"-29":r+"-"+i+"-01~"+r+"-"+i+"-28":r+"-"+i+"-01~"+r+"-"+i+"-30"},GetDateStr:function(e){var t=new Date;t.setDate(t.getDate()+e);t.getFullYear();var n=t.getMonth()+1<10?"0"+(t.getMonth()+1):t.getMonth()+1,r=t.getDate()<10?"0"+t.getDate():t.getDate();return n+"月"+r+"日"},mergeAndDeduplicate:function(e,t,n){var r,a=new Map,s=[].concat((0,i.default)(e),(0,i.default)(t)),c=o(s);try{for(c.s();!(r=c.n()).done;){var u=r.value;a.has(u[n])||a.set(u[n],u)}}catch(l){c.e(l)}finally{c.f()}return(0,i.default)(a.values())}};t.default=s}).call(this,n("df3c")["default"])},"0bdb":function(e,t,n){var r=n("d551");function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}e.exports=function(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports["default"]=e.exports},"0ee4":function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},"17f2":function(e,t,n){},"229b":function(e){e.exports=JSON.parse('{"fimages":[{"image":"../../static/img.jpg","title":"减脂一定要吃的生菜鸡丝卷01","head":"../../static/dan.png","name":"季总蛋先生01","iszan":false},{"image":"../../static/img2.jpg","title":"减脂一定要吃的生菜鸡丝卷02","head":"../../static/dan.png","name":"季总蛋先生02","iszan":false}],"footlist":[{"height":370,"image":"../static/img.jpg","title":"鸡蛋芝士烤吐司","head":"../static/dan.png","name":"ayamama","zan":2255,"iszan":false},{"height":370,"image":"../static/img2.jpg","title":"鸡蛋芝士烤吐司","head":"../static/dan.png","name":"ayamama","zan":2255,"iszan":false},{"height":370,"image":"../static/img.jpg","title":"减脂一定要吃的生菜鸡丝卷03","head":"../static/dan.png","name":"季总蛋先生03","iszan":true,"zan":1699},{"height":370,"image":"../static/img.jpg","title":"减脂一定要吃的生菜鸡丝卷03","head":"../static/dan.png","name":"季总蛋先生03","iszan":true,"zan":1699},{"height":370,"image":"../static/img2.jpg","title":"减脂一定要吃的生菜鸡丝卷03","head":"../static/dan.png","name":"季总蛋先生03","iszan":true,"zan":1699},{"height":370,"image":"../static/img2.jpg","title":"减脂一定要吃的生菜鸡丝卷03","head":"../static/dan.png","name":"季总蛋先生03","iszan":true,"zan":1699}],"menu":[{"name":"酒水饮料"},{"name":"健康饮食"},{"name":"家常菜谱"},{"name":"轻食沙拉"},{"name":"烘焙"}],"menulist":[{"name":"酒水","list":[{"image":"../../static/img2.jpg","name":"莫吉托"},{"image":"../../static/jiu.jpg","name":"威士忌"},{"image":"../../static/img2.jpg","name":"白兰地"},{"image":"../../static/jiu.jpg","name":"朗姆酒"}]},{"name":"饮品","list":[{"image":"../../static/jiu.jpg","name":"咖啡"},{"image":"../../static/img2.jpg","name":"豆浆"},{"image":"../../static/jiu.jpg","name":"果汁"},{"image":"../../static/jiu.jpg","name":"奶茶"}]}],"food":[{"name":"蔬菜豆品"},{"name":"水果鲜花"},{"name":"酒水饮料"},{"name":"乳品烘焙"},{"name":"肉蛋水产"},{"name":"蔬菜豆品"},{"name":"水果鲜花"},{"name":"酒水饮料"},{"name":"乳品烘焙"},{"name":"肉蛋水产"},{"name":"蔬菜豆品"},{"name":"水果鲜花"},{"name":"酒水饮料"},{"name":"乳品烘焙"},{"name":"肉蛋水产"}],"foodlist":[{"name":"土豆/根茎类","list":[{"id":1,"name":"土豆","unit":"g","weight":null},{"id":2,"name":"紫薯","unit":"g","weight":null},{"id":3,"name":"铁棍山药","unit":"g","weight":null},{"id":4,"name":"胡萝卜","unit":"g","weight":null}]},{"name":"叶菜类","list":[{"id":5,"name":"上海青","unit":"g","weight":null},{"id":6,"name":"本地生菜","unit":"g","weight":null},{"id":7,"name":"球生菜","unit":"g","weight":null},{"id":8,"name":"菠菜","unit":"g","weight":null}]}],"recordList":[{"time":"2323/03/25","kcal":"1235","status":1},{"time":"2323/03/25","kcal":"1236","status":2},{"time":"2323/03/25","kcal":"1237","status":1},{"time":"2323/03/25","kcal":"1238","status":1},{"time":"2323/03/25","kcal":"1239","status":-1},{"time":"2323/03/25","kcal":"1240","status":-1},{"time":"2323/03/25","kcal":"1241","status":2}],"menudetail":{"id":1,"FMimg":"../../static/1-2.jpg","content":"简单易操作,方便又美味","list":[{"id":1,"name":"牛肉","unit":"g","weight":"10"},{"id":2,"name":"芝麻","unit":"g","weight":"20"},{"id":3,"name":"面粉","unit":"g","weight":"30"}],"user":{"headimg":"../../static/dan.png","name":"季总蛋先生03","iszan":false,"zan":1699},"stepList":[{"content":"去面粉500g,加水100ml搅拌均匀取葱1根切葱花热锅放油放面饼翻面放葱花芝麻","image":"../../static/img2.jpg"},{"content":"去面粉500g,加水100ml搅拌均匀取葱1根切葱花热锅放油放面饼翻面放葱花芝麻","image":"../../static/img.jpg"}],"title":"葱油饼"}}')},3223:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=["qy","env","error","version","lanDebug","cloud","serviceMarket","router","worklet","__webpack_require_UNI_MP_PLUGIN__"],i=["lanDebug","router","worklet"],o="undefined"!==typeof globalThis?globalThis:function(){return this}(),a=["w","x"].join(""),s=o[a],c=s.getLaunchOptionsSync?s.getLaunchOptionsSync():null;function u(e){return(!c||1154!==c.scene||!i.includes(e))&&(r.indexOf(e)>-1||"function"===typeof s[e])}o[a]=function(){var e={};for(var t in s)u(t)&&(e[t]=s[t]);return e}(),o[a].canIUse("getAppBaseInfo")||(o[a].getAppBaseInfo=o[a].getSystemInfoSync),o[a].canIUse("getWindowInfo")||(o[a].getWindowInfo=o[a].getSystemInfoSync),o[a].canIUse("getDeviceInfo")||(o[a].getDeviceInfo=o[a].getSystemInfoSync);var l=o[a];t.default=l},3240:function(e,t,n){"use strict";n.r(t),function(e){
/*!
* Vue.js v2.6.11
* (c) 2014-2024 Evan You
* Released under the MIT License.
*/
var n=Object.freeze({});function r(e){return void 0===e||null===e}function i(e){return void 0!==e&&null!==e}function o(e){return!0===e}function a(e){return"string"===typeof e||"number"===typeof e||"symbol"===typeof e||"boolean"===typeof e}function s(e){return null!==e&&"object"===typeof e}var c=Object.prototype.toString;function u(e){return"[object Object]"===c.call(e)}function l(e){var t=parseFloat(String(e));return t>=0&&Math.floor(t)===t&&isFinite(e)}function f(e){return i(e)&&"function"===typeof e.then&&"function"===typeof e.catch}function d(e){return null==e?"":Array.isArray(e)||u(e)&&e.toString===c?JSON.stringify(e,null,2):String(e)}function h(e){var t=parseFloat(e);return isNaN(t)?e:t}function p(e,t){for(var n=Object.create(null),r=e.split(","),i=0;i<r.length;i++)n[r[i]]=!0;return t?function(e){return n[e.toLowerCase()]}:function(e){return n[e]}}p("slot,component",!0);var g=p("key,ref,slot,slot-scope,is");function v(e,t){if(e.length){var n=e.indexOf(t);if(n>-1)return e.splice(n,1)}}var y=Object.prototype.hasOwnProperty;function m(e,t){return y.call(e,t)}function x(e){var t=Object.create(null);return function(n){var r=t[n];return r||(t[n]=e(n))}}var _=/-(\w)/g,b=x((function(e){return e.replace(_,(function(e,t){return t?t.toUpperCase():""}))})),w=x((function(e){return e.charAt(0).toUpperCase()+e.slice(1)})),k=/\B([A-Z])/g,A=x((function(e){return e.replace(k,"-$1").toLowerCase()}));var S=Function.prototype.bind?function(e,t){return e.bind(t)}:function(e,t){function n(n){var r=arguments.length;return r?r>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n};function P(e,t){t=t||0;var n=e.length-t,r=new Array(n);while(n--)r[n]=e[n+t];return r}function T(e,t){for(var n in t)e[n]=t[n];return e}function O(e){for(var t={},n=0;n<e.length;n++)e[n]&&T(t,e[n]);return t}function C(e,t,n){}var L=function(e,t,n){return!1},I=function(e){return e};function E(e,t){if(e===t)return!0;var n=s(e),r=s(t);if(!n||!r)return!n&&!r&&String(e)===String(t);try{var i=Array.isArray(e),o=Array.isArray(t);if(i&&o)return e.length===t.length&&e.every((function(e,n){return E(e,t[n])}));if(e instanceof Date&&t instanceof Date)return e.getTime()===t.getTime();if(i||o)return!1;var a=Object.keys(e),c=Object.keys(t);return a.length===c.length&&a.every((function(n){return E(e[n],t[n])}))}catch(u){return!1}}function D(e,t){for(var n=0;n<e.length;n++)if(E(e[n],t))return n;return-1}function M(e){var t=!1;return function(){t||(t=!0,e.apply(this,arguments))}}var F=["component","directive","filter"],j=["beforeCreate","created","beforeMount","mounted","beforeUpdate","updated","beforeDestroy","destroyed","activated","deactivated","errorCaptured","serverPrefetch"],$={optionMergeStrategies:Object.create(null),silent:!1,productionTip:!1,devtools:!1,performance:!1,errorHandler:null,warnHandler:null,ignoredElements:[],keyCodes:Object.create(null),isReservedTag:L,isReservedAttr:L,isUnknownElement:L,getTagNamespace:C,parsePlatformTagName:I,mustUseProp:L,async:!0,_lifecycleHooks:j},R=/a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/;function N(e){var t=(e+"").charCodeAt(0);return 36===t||95===t}function U(e,t,n,r){Object.defineProperty(e,t,{value:n,enumerable:!!r,writable:!0,configurable:!0})}var B=new RegExp("[^"+R.source+".$_\\d]");var z,W="__proto__"in{},q="undefined"!==typeof window,H="undefined"!==typeof WXEnvironment&&!!WXEnvironment.platform,V=H&&WXEnvironment.platform.toLowerCase(),K=q&&window.navigator&&window.navigator.userAgent.toLowerCase(),G=K&&/msie|trident/.test(K),J=(K&&K.indexOf("msie 9.0"),K&&K.indexOf("edge/")>0),X=(K&&K.indexOf("android"),K&&/iphone|ipad|ipod|ios/.test(K)||"ios"===V),Y=(K&&/chrome\/\d+/.test(K),K&&/phantomjs/.test(K),K&&K.match(/firefox\/(\d+)/),{}.watch);if(q)try{var Q={};Object.defineProperty(Q,"passive",{get:function(){}}),window.addEventListener("test-passive",null,Q)}catch($n){}var Z=function(){return void 0===z&&(z=!q&&!H&&"undefined"!==typeof e&&(e["process"]&&"server"===e["process"].env.VUE_ENV)),z},ee=q&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function te(e){return"function"===typeof e&&/native code/.test(e.toString())}var ne,re="undefined"!==typeof Symbol&&te(Symbol)&&"undefined"!==typeof Reflect&&te(Reflect.ownKeys);ne="undefined"!==typeof Set&&te(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var ie=C,oe=0,ae=function(){this.id=oe++,this.subs=[]};function se(e){ae.SharedObject.targetStack.push(e),ae.SharedObject.target=e,ae.target=e}function ce(){ae.SharedObject.targetStack.pop(),ae.SharedObject.target=ae.SharedObject.targetStack[ae.SharedObject.targetStack.length-1],ae.target=ae.SharedObject.target}ae.prototype.addSub=function(e){this.subs.push(e)},ae.prototype.removeSub=function(e){v(this.subs,e)},ae.prototype.depend=function(){ae.SharedObject.target&&ae.SharedObject.target.addDep(this)},ae.prototype.notify=function(){var e=this.subs.slice();for(var t=0,n=e.length;t<n;t++)e[t].update()},ae.SharedObject={},ae.SharedObject.target=null,ae.SharedObject.targetStack=[];var ue=function(e,t,n,r,i,o,a,s){this.tag=e,this.data=t,this.children=n,this.text=r,this.elm=i,this.ns=void 0,this.context=o,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=t&&t.key,this.componentOptions=a,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=s,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1},le={child:{configurable:!0}};le.child.get=function(){return this.componentInstance},Object.defineProperties(ue.prototype,le);var fe=function(e){void 0===e&&(e="");var t=new ue;return t.text=e,t.isComment=!0,t};function de(e){return new ue(void 0,void 0,void 0,String(e))}var he=Array.prototype,pe=Object.create(he);["push","pop","shift","unshift","splice","sort","reverse"].forEach((function(e){var t=he[e];U(pe,e,(function(){var n=[],r=arguments.length;while(r--)n[r]=arguments[r];var i,o=t.apply(this,n),a=this.__ob__;switch(e){case"push":case"unshift":i=n;break;case"splice":i=n.slice(2);break}return i&&a.observeArray(i),a.dep.notify(),o}))}));var ge=Object.getOwnPropertyNames(pe),ve=!0;function ye(e){ve=e}var me=function(e){this.value=e,this.dep=new ae,this.vmCount=0,U(e,"__ob__",this),Array.isArray(e)?(W?e.push!==e.__proto__.push?xe(e,pe,ge):function(e,t){e.__proto__=t}(e,pe):xe(e,pe,ge),this.observeArray(e)):this.walk(e)};function xe(e,t,n){for(var r=0,i=n.length;r<i;r++){var o=n[r];U(e,o,t[o])}}function _e(e,t){var n;if(s(e)&&!(e instanceof ue))return m(e,"__ob__")&&e.__ob__ instanceof me?n=e.__ob__:!ve||Z()||!Array.isArray(e)&&!u(e)||!Object.isExtensible(e)||e._isVue||e.__v_isMPComponent||(n=new me(e)),t&&n&&n.vmCount++,n}function be(e,t,n,r,i){var o=new ae,a=Object.getOwnPropertyDescriptor(e,t);if(!a||!1!==a.configurable){var s=a&&a.get,c=a&&a.set;s&&!c||2!==arguments.length||(n=e[t]);var u=!i&&_e(n);Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get:function(){var t=s?s.call(e):n;return ae.SharedObject.target&&(o.depend(),u&&(u.dep.depend(),Array.isArray(t)&&Ae(t))),t},set:function(t){var r=s?s.call(e):n;t===r||t!==t&&r!==r||s&&!c||(c?c.call(e,t):n=t,u=!i&&_e(t),o.notify())}})}}function we(e,t,n){if(Array.isArray(e)&&l(t))return e.length=Math.max(e.length,t),e.splice(t,1,n),n;if(t in e&&!(t in Object.prototype))return e[t]=n,n;var r=e.__ob__;return e._isVue||r&&r.vmCount?n:r?(be(r.value,t,n),r.dep.notify(),n):(e[t]=n,n)}function ke(e,t){if(Array.isArray(e)&&l(t))e.splice(t,1);else{var n=e.__ob__;e._isVue||n&&n.vmCount||m(e,t)&&(delete e[t],n&&n.dep.notify())}}function Ae(e){for(var t=void 0,n=0,r=e.length;n<r;n++)t=e[n],t&&t.__ob__&&t.__ob__.dep.depend(),Array.isArray(t)&&Ae(t)}me.prototype.walk=function(e){for(var t=Object.keys(e),n=0;n<t.length;n++)be(e,t[n])},me.prototype.observeArray=function(e){for(var t=0,n=e.length;t<n;t++)_e(e[t])};var Se=$.optionMergeStrategies;function Pe(e,t){if(!t)return e;for(var n,r,i,o=re?Reflect.ownKeys(t):Object.keys(t),a=0;a<o.length;a++)n=o[a],"__ob__"!==n&&(r=e[n],i=t[n],m(e,n)?r!==i&&u(r)&&u(i)&&Pe(r,i):we(e,n,i));return e}function Te(e,t,n){return n?function(){var r="function"===typeof t?t.call(n,n):t,i="function"===typeof e?e.call(n,n):e;return r?Pe(r,i):i}:t?e?function(){return Pe("function"===typeof t?t.call(this,this):t,"function"===typeof e?e.call(this,this):e)}:t:e}function Oe(e,t){var n=t?e?e.concat(t):Array.isArray(t)?t:[t]:e;return n?function(e){for(var t=[],n=0;n<e.length;n++)-1===t.indexOf(e[n])&&t.push(e[n]);return t}(n):n}function Ce(e,t,n,r){var i=Object.create(e||null);return t?T(i,t):i}Se.data=function(e,t,n){return n?Te(e,t,n):t&&"function"!==typeof t?e:Te(e,t)},j.forEach((function(e){Se[e]=Oe})),F.forEach((function(e){Se[e+"s"]=Ce})),Se.watch=function(e,t,n,r){if(e===Y&&(e=void 0),t===Y&&(t=void 0),!t)return Object.create(e||null);if(!e)return t;var i={};for(var o in T(i,e),t){var a=i[o],s=t[o];a&&!Array.isArray(a)&&(a=[a]),i[o]=a?a.concat(s):Array.isArray(s)?s:[s]}return i},Se.props=Se.methods=Se.inject=Se.computed=function(e,t,n,r){if(!e)return t;var i=Object.create(null);return T(i,e),t&&T(i,t),i},Se.provide=Te;var Le=function(e,t){return void 0===t?e:t};function Ie(e,t,n){if("function"===typeof t&&(t=t.options),function(e,t){var n=e.props;if(n){var r,i,o,a={};if(Array.isArray(n)){r=n.length;while(r--)i=n[r],"string"===typeof i&&(o=b(i),a[o]={type:null})}else if(u(n))for(var s in n)i=n[s],o=b(s),a[o]=u(i)?i:{type:i};else 0;e.props=a}}(t),function(e,t){var n=e.inject;if(n){var r=e.inject={};if(Array.isArray(n))for(var i=0;i<n.length;i++)r[n[i]]={from:n[i]};else if(u(n))for(var o in n){var a=n[o];r[o]=u(a)?T({from:o},a):{from:a}}else 0}}(t),function(e){var t=e.directives;if(t)for(var n in t){var r=t[n];"function"===typeof r&&(t[n]={bind:r,update:r})}}(t),!t._base&&(t.extends&&(e=Ie(e,t.extends,n)),t.mixins))for(var r=0,i=t.mixins.length;r<i;r++)e=Ie(e,t.mixins[r],n);var o,a={};for(o in e)s(o);for(o in t)m(e,o)||s(o);function s(r){var i=Se[r]||Le;a[r]=i(e[r],t[r],n,r)}return a}function Ee(e,t,n,r){if("string"===typeof n){var i=e[t];if(m(i,n))return i[n];var o=b(n);if(m(i,o))return i[o];var a=w(o);if(m(i,a))return i[a];var s=i[n]||i[o]||i[a];return s}}function De(e,t,n,r){var i=t[e],o=!m(n,e),a=n[e],s=je(Boolean,i.type);if(s>-1)if(o&&!m(i,"default"))a=!1;else if(""===a||a===A(e)){var c=je(String,i.type);(c<0||s<c)&&(a=!0)}if(void 0===a){a=function(e,t,n){if(!m(t,"default"))return;var r=t.default;0;if(e&&e.$options.propsData&&void 0===e.$options.propsData[n]&&void 0!==e._props[n])return e._props[n];return"function"===typeof r&&"Function"!==Me(t.type)?r.call(e):r}(r,i,e);var u=ve;ye(!0),_e(a),ye(u)}return a}function Me(e){var t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function Fe(e,t){return Me(e)===Me(t)}function je(e,t){if(!Array.isArray(t))return Fe(t,e)?0:-1;for(var n=0,r=t.length;n<r;n++)if(Fe(t[n],e))return n;return-1}function $e(e,t,n){se();try{if(t){var r=t;while(r=r.$parent){var i=r.$options.errorCaptured;if(i)for(var o=0;o<i.length;o++)try{var a=!1===i[o].call(r,e,t,n);if(a)return}catch($n){Ne($n,r,"errorCaptured hook")}}}Ne(e,t,n)}finally{ce()}}function Re(e,t,n,r,i){var o;try{o=n?e.apply(t,n):e.call(t),o&&!o._isVue&&f(o)&&!o._handled&&(o.catch((function(e){return $e(e,r,i+" (Promise/async)")})),o._handled=!0)}catch($n){$e($n,r,i)}return o}function Ne(e,t,n){if($.errorHandler)try{return $.errorHandler.call(null,e,t,n)}catch($n){$n!==e&&Ue($n,null,"config.errorHandler")}Ue(e,t,n)}function Ue(e,t,n){if(!q&&!H||"undefined"===typeof console)throw e;console.error(e)}var Be,ze=[],We=!1;function qe(){We=!1;var e=ze.slice(0);ze.length=0;for(var t=0;t<e.length;t++)e[t]()}if("undefined"!==typeof Promise&&te(Promise)){var He=Promise.resolve();Be=function(){He.then(qe),X&&setTimeout(C)}}else if(G||"undefined"===typeof MutationObserver||!te(MutationObserver)&&"[object MutationObserverConstructor]"!==MutationObserver.toString())Be="undefined"!==typeof setImmediate&&te(setImmediate)?function(){setImmediate(qe)}:function(){setTimeout(qe,0)};else{var Ve=1,Ke=new MutationObserver(qe),Ge=document.createTextNode(String(Ve));Ke.observe(Ge,{characterData:!0}),Be=function(){Ve=(Ve+1)%2,Ge.data=String(Ve)}}function Je(e,t){var n;if(ze.push((function(){if(e)try{e.call(t)}catch($n){$e($n,t,"nextTick")}else n&&n(t)})),We||(We=!0,Be()),!e&&"undefined"!==typeof Promise)return new Promise((function(e){n=e}))}var Xe=new ne;function Ye(e){(function e(t,n){var r,i,o=Array.isArray(t);if(!o&&!s(t)||Object.isFrozen(t)||t instanceof ue)return;if(t.__ob__){var a=t.__ob__.dep.id;if(n.has(a))return;n.add(a)}if(o){r=t.length;while(r--)e(t[r],n)}else{i=Object.keys(t),r=i.length;while(r--)e(t[i[r]],n)}})(e,Xe),Xe.clear()}var Qe=x((function(e){var t="&"===e.charAt(0);e=t?e.slice(1):e;var n="~"===e.charAt(0);e=n?e.slice(1):e;var r="!"===e.charAt(0);return e=r?e.slice(1):e,{name:e,once:n,capture:r,passive:t}}));function Ze(e,t){function n(){var e=arguments,r=n.fns;if(!Array.isArray(r))return Re(r,null,arguments,t,"v-on handler");for(var i=r.slice(),o=0;o<i.length;o++)Re(i[o],null,e,t,"v-on handler")}return n.fns=e,n}function et(e,t,n,o){var a=t.options.mpOptions&&t.options.mpOptions.properties;if(r(a))return n;var s=t.options.mpOptions.externalClasses||[],c=e.attrs,u=e.props;if(i(c)||i(u))for(var l in a){var f=A(l),d=tt(n,u,l,f,!0)||tt(n,c,l,f,!1);d&&n[l]&&-1!==s.indexOf(f)&&o[b(n[l])]&&(n[l]=o[b(n[l])])}return n}function tt(e,t,n,r,o){if(i(t)){if(m(t,n))return e[n]=t[n],o||delete t[n],!0;if(m(t,r))return e[n]=t[r],o||delete t[r],!0}return!1}function nt(e){return a(e)?[de(e)]:Array.isArray(e)?function e(t,n){var s,c,u,l,f=[];for(s=0;s<t.length;s++)c=t[s],r(c)||"boolean"===typeof c||(u=f.length-1,l=f[u],Array.isArray(c)?c.length>0&&(c=e(c,(n||"")+"_"+s),rt(c[0])&&rt(l)&&(f[u]=de(l.text+c[0].text),c.shift()),f.push.apply(f,c)):a(c)?rt(l)?f[u]=de(l.text+c):""!==c&&f.push(de(c)):rt(c)&&rt(l)?f[u]=de(l.text+c.text):(o(t._isVList)&&i(c.tag)&&r(c.key)&&i(n)&&(c.key="__vlist"+n+"_"+s+"__"),f.push(c)));return f}(e):void 0}function rt(e){return i(e)&&i(e.text)&&function(e){return!1===e}(e.isComment)}function it(e){var t=e.$options.provide;t&&(e._provided="function"===typeof t?t.call(e):t)}function ot(e){var t=at(e.$options.inject,e);t&&(ye(!1),Object.keys(t).forEach((function(n){be(e,n,t[n])})),ye(!0))}function at(e,t){if(e){for(var n=Object.create(null),r=re?Reflect.ownKeys(e):Object.keys(e),i=0;i<r.length;i++){var o=r[i];if("__ob__"!==o){var a=e[o].from,s=t;while(s){if(s._provided&&m(s._provided,a)){n[o]=s._provided[a];break}s=s.$parent}if(!s)if("default"in e[o]){var c=e[o].default;n[o]="function"===typeof c?c.call(t):c}else 0}}return n}}function st(e,t){if(!e||!e.length)return{};for(var n={},r=0,i=e.length;r<i;r++){var o=e[r],a=o.data;if(a&&a.attrs&&a.attrs.slot&&delete a.attrs.slot,o.context!==t&&o.fnContext!==t||!a||null==a.slot)o.asyncMeta&&o.asyncMeta.data&&"page"===o.asyncMeta.data.slot?(n["page"]||(n["page"]=[])).push(o):(n.default||(n.default=[])).push(o);else{var s=a.slot,c=n[s]||(n[s]=[]);"template"===o.tag?c.push.apply(c,o.children||[]):c.push(o)}}for(var u in n)n[u].every(ct)&&delete n[u];return n}function ct(e){return e.isComment&&!e.asyncFactory||" "===e.text}function ut(e,t,r){var i,o=Object.keys(t).length>0,a=e?!!e.$stable:!o,s=e&&e.$key;if(e){if(e._normalized)return e._normalized;if(a&&r&&r!==n&&s===r.$key&&!o&&!r.$hasNormal)return r;for(var c in i={},e)e[c]&&"$"!==c[0]&&(i[c]=lt(t,c,e[c]))}else i={};for(var u in t)u in i||(i[u]=ft(t,u));return e&&Object.isExtensible(e)&&(e._normalized=i),U(i,"$stable",a),U(i,"$key",s),U(i,"$hasNormal",o),i}function lt(e,t,n){var r=function(){var e=arguments.length?n.apply(null,arguments):n({});return e=e&&"object"===typeof e&&!Array.isArray(e)?[e]:nt(e),e&&(0===e.length||1===e.length&&e[0].isComment)?void 0:e};return n.proxy&&Object.defineProperty(e,t,{get:r,enumerable:!0,configurable:!0}),r}function ft(e,t){return function(){return e[t]}}function dt(e,t){var n,r,o,a,c;if(Array.isArray(e)||"string"===typeof e)for(n=new Array(e.length),r=0,o=e.length;r<o;r++)n[r]=t(e[r],r,r,r);else if("number"===typeof e)for(n=new Array(e),r=0;r<e;r++)n[r]=t(r+1,r,r,r);else if(s(e))if(re&&e[Symbol.iterator]){n=[];var u=e[Symbol.iterator](),l=u.next();while(!l.done)n.push(t(l.value,n.length,r,r++)),l=u.next()}else for(a=Object.keys(e),n=new Array(a.length),r=0,o=a.length;r<o;r++)c=a[r],n[r]=t(e[c],c,r,r);return i(n)||(n=[]),n._isVList=!0,n}function ht(e,t,n,r){var i,o=this.$scopedSlots[e];o?(n=n||{},r&&(n=T(T({},r),n)),i=o(n,this,n._i)||t):i=this.$slots[e]||t;var a=n&&n.slot;return a?this.$createElement("template",{slot:a},i):i}function pt(e){return Ee(this.$options,"filters",e)||I}function gt(e,t){return Array.isArray(e)?-1===e.indexOf(t):e!==t}function vt(e,t,n,r,i){var o=$.keyCodes[t]||n;return i&&r&&!$.keyCodes[t]?gt(i,r):o?gt(o,e):r?A(r)!==t:void 0}function yt(e,t,n,r,i){if(n)if(s(n)){var o;Array.isArray(n)&&(n=O(n));var a=function(a){if("class"===a||"style"===a||g(a))o=e;else{var s=e.attrs&&e.attrs.type;o=r||$.mustUseProp(t,s,a)?e.domProps||(e.domProps={}):e.attrs||(e.attrs={})}var c=b(a),u=A(a);if(!(c in o)&&!(u in o)&&(o[a]=n[a],i)){var l=e.on||(e.on={});l["update:"+a]=function(e){n[a]=e}}};for(var c in n)a(c)}else;return e}function mt(e,t){var n=this._staticTrees||(this._staticTrees=[]),r=n[e];return r&&!t||(r=n[e]=this.$options.staticRenderFns[e].call(this._renderProxy,null,this),_t(r,"__static__"+e,!1)),r}function xt(e,t,n){return _t(e,"__once__"+t+(n?"_"+n:""),!0),e}function _t(e,t,n){if(Array.isArray(e))for(var r=0;r<e.length;r++)e[r]&&"string"!==typeof e[r]&&bt(e[r],t+"_"+r,n);else bt(e,t,n)}function bt(e,t,n){e.isStatic=!0,e.key=t,e.isOnce=n}function wt(e,t){if(t)if(u(t)){var n=e.on=e.on?T({},e.on):{};for(var r in t){var i=n[r],o=t[r];n[r]=i?[].concat(i,o):o}}else;return e}function kt(e,t,n,r){t=t||{$stable:!n};for(var i=0;i<e.length;i++){var o=e[i];Array.isArray(o)?kt(o,t,n):o&&(o.proxy&&(o.fn.proxy=!0),t[o.key]=o.fn)}return r&&(t.$key=r),t}function At(e,t){for(var n=0;n<t.length;n+=2){var r=t[n];"string"===typeof r&&r&&(e[t[n]]=t[n+1])}return e}function St(e,t){return"string"===typeof e?t+e:e}function Pt(e){e._o=xt,e._n=h,e._s=d,e._l=dt,e._t=ht,e._q=E,e._i=D,e._m=mt,e._f=pt,e._k=vt,e._b=yt,e._v=de,e._e=fe,e._u=kt,e._g=wt,e._d=At,e._p=St}function Tt(e,t,r,i,a){var s,c=this,u=a.options;m(i,"_uid")?(s=Object.create(i),s._original=i):(s=i,i=i._original);var l=o(u._compiled),f=!l;this.data=e,this.props=t,this.children=r,this.parent=i,this.listeners=e.on||n,this.injections=at(u.inject,i),this.slots=function(){return c.$slots||ut(e.scopedSlots,c.$slots=st(r,i)),c.$slots},Object.defineProperty(this,"scopedSlots",{enumerable:!0,get:function(){return ut(e.scopedSlots,this.slots())}}),l&&(this.$options=u,this.$slots=this.slots(),this.$scopedSlots=ut(e.scopedSlots,this.$slots)),u._scopeId?this._c=function(e,t,n,r){var o=Mt(s,e,t,n,r,f);return o&&!Array.isArray(o)&&(o.fnScopeId=u._scopeId,o.fnContext=i),o}:this._c=function(e,t,n,r){return Mt(s,e,t,n,r,f)}}function Ot(e,t,n,r,i){var o=function(e){var t=new ue(e.tag,e.data,e.children&&e.children.slice(),e.text,e.elm,e.context,e.componentOptions,e.asyncFactory);return t.ns=e.ns,t.isStatic=e.isStatic,t.key=e.key,t.isComment=e.isComment,t.fnContext=e.fnContext,t.fnOptions=e.fnOptions,t.fnScopeId=e.fnScopeId,t.asyncMeta=e.asyncMeta,t.isCloned=!0,t}(e);return o.fnContext=n,o.fnOptions=r,t.slot&&((o.data||(o.data={})).slot=t.slot),o}function Ct(e,t){for(var n in t)e[b(n)]=t[n]}Pt(Tt.prototype);var Lt={init:function(e,t){if(e.componentInstance&&!e.componentInstance._isDestroyed&&e.data.keepAlive){var n=e;Lt.prepatch(n,n)}else{var r=e.componentInstance=function(e,t){var n={_isComponent:!0,_parentVnode:e,parent:t},r=e.data.inlineTemplate;i(r)&&(n.render=r.render,n.staticRenderFns=r.staticRenderFns);return new e.componentOptions.Ctor(n)}(e,Wt);r.$mount(t?e.elm:void 0,t)}},prepatch:function(e,t){var r=t.componentOptions,i=t.componentInstance=e.componentInstance;(function(e,t,r,i,o){0;var a=i.data.scopedSlots,s=e.$scopedSlots,c=!!(a&&!a.$stable||s!==n&&!s.$stable||a&&e.$scopedSlots.$key!==a.$key),u=!!(o||e.$options._renderChildren||c);e.$options._parentVnode=i,e.$vnode=i,e._vnode&&(e._vnode.parent=i);if(e.$options._renderChildren=o,e.$attrs=i.data.attrs||n,e.$listeners=r||n,t&&e.$options.props){ye(!1);for(var l=e._props,f=e.$options._propKeys||[],d=0;d<f.length;d++){var h=f[d],p=e.$options.props;l[h]=De(h,p,t,e)}ye(!0),e.$options.propsData=t}e._$updateProperties&&e._$updateProperties(e),r=r||n;var g=e.$options._parentListeners;e.$options._parentListeners=r,zt(e,r,g),u&&(e.$slots=st(o,i.context),e.$forceUpdate());0})(i,r.propsData,r.listeners,t,r.children)},insert:function(e){var t=e.context,n=e.componentInstance;n._isMounted||(Vt(n,"onServiceCreated"),Vt(n,"onServiceAttached"),n._isMounted=!0,Vt(n,"mounted")),e.data.keepAlive&&(t._isMounted?function(e){e._inactive=!1,Gt.push(e)}(n):Ht(n,!0))},destroy:function(e){var t=e.componentInstance;t._isDestroyed||(e.data.keepAlive?function e(t,n){if(n&&(t._directInactive=!0,qt(t)))return;if(!t._inactive){t._inactive=!0;for(var r=0;r<t.$children.length;r++)e(t.$children[r]);Vt(t,"deactivated")}}(t,!0):t.$destroy())}},It=Object.keys(Lt);function Et(e,t,a,c,u){if(!r(e)){var l=a.$options._base;if(s(e)&&(e=l.extend(e)),"function"===typeof e){var d;if(r(e.cid)&&(d=e,e=function(e,t){if(o(e.error)&&i(e.errorComp))return e.errorComp;if(i(e.resolved))return e.resolved;var n=jt;n&&i(e.owners)&&-1===e.owners.indexOf(n)&&e.owners.push(n);if(o(e.loading)&&i(e.loadingComp))return e.loadingComp;if(n&&!i(e.owners)){var a=e.owners=[n],c=!0,u=null,l=null;n.$on("hook:destroyed",(function(){return v(a,n)}));var d=function(e){for(var t=0,n=a.length;t<n;t++)a[t].$forceUpdate();e&&(a.length=0,null!==u&&(clearTimeout(u),u=null),null!==l&&(clearTimeout(l),l=null))},h=M((function(n){e.resolved=$t(n,t),c?a.length=0:d(!0)})),p=M((function(t){i(e.errorComp)&&(e.error=!0,d(!0))})),g=e(h,p);return s(g)&&(f(g)?r(e.resolved)&&g.then(h,p):f(g.component)&&(g.component.then(h,p),i(g.error)&&(e.errorComp=$t(g.error,t)),i(g.loading)&&(e.loadingComp=$t(g.loading,t),0===g.delay?e.loading=!0:u=setTimeout((function(){u=null,r(e.resolved)&&r(e.error)&&(e.loading=!0,d(!1))}),g.delay||200)),i(g.timeout)&&(l=setTimeout((function(){l=null,r(e.resolved)&&p(null)}),g.timeout)))),c=!1,e.loading?e.loadingComp:e.resolved}}(d,l),void 0===e))return function(e,t,n,r,i){var o=fe();return o.asyncFactory=e,o.asyncMeta={data:t,context:n,children:r,tag:i},o}(d,t,a,c,u);t=t||{},pn(e),i(t.model)&&function(e,t){var n=e.model&&e.model.prop||"value",r=e.model&&e.model.event||"input";(t.attrs||(t.attrs={}))[n]=t.model.value;var o=t.on||(t.on={}),a=o[r],s=t.model.callback;i(a)?(Array.isArray(a)?-1===a.indexOf(s):a!==s)&&(o[r]=[s].concat(a)):o[r]=s}(e.options,t);var h=function(e,t,n,o){var a=t.options.props;if(r(a))return et(e,t,{},o);var s={},c=e.attrs,u=e.props;if(i(c)||i(u))for(var l in a){var f=A(l);tt(s,u,l,f,!0)||tt(s,c,l,f,!1)}return et(e,t,s,o)}(t,e,0,a);if(o(e.options.functional))return function(e,t,r,o,a){var s=e.options,c={},u=s.props;if(i(u))for(var l in u)c[l]=De(l,u,t||n);else i(r.attrs)&&Ct(c,r.attrs),i(r.props)&&Ct(c,r.props);var f=new Tt(r,c,a,o,e),d=s.render.call(null,f._c,f);if(d instanceof ue)return Ot(d,r,f.parent,s,f);if(Array.isArray(d)){for(var h=nt(d)||[],p=new Array(h.length),g=0;g<h.length;g++)p[g]=Ot(h[g],r,f.parent,s,f);return p}}(e,h,t,a,c);var p=t.on;if(t.on=t.nativeOn,o(e.options.abstract)){var g=t.slot;t={},g&&(t.slot=g)}(function(e){for(var t=e.hook||(e.hook={}),n=0;n<It.length;n++){var r=It[n],i=t[r],o=Lt[r];i===o||i&&i._merged||(t[r]=i?Dt(o,i):o)}})(t);var y=e.options.name||u,m=new ue("vue-component-"+e.cid+(y?"-"+y:""),t,void 0,void 0,void 0,a,{Ctor:e,propsData:h,listeners:p,tag:u,children:c},d);return m}}}function Dt(e,t){var n=function(n,r){e(n,r),t(n,r)};return n._merged=!0,n}function Mt(e,t,n,c,u,l){return(Array.isArray(n)||a(n))&&(u=c,c=n,n=void 0),o(l)&&(u=2),function(e,t,n,a,c){if(i(n)&&i(n.__ob__))return fe();i(n)&&i(n.is)&&(t=n.is);if(!t)return fe();0;Array.isArray(a)&&"function"===typeof a[0]&&(n=n||{},n.scopedSlots={default:a[0]},a.length=0);2===c?a=nt(a):1===c&&(a=function(e){for(var t=0;t<e.length;t++)if(Array.isArray(e[t]))return Array.prototype.concat.apply([],e);return e}(a));var u,l;if("string"===typeof t){var f;l=e.$vnode&&e.$vnode.ns||$.getTagNamespace(t),u=$.isReservedTag(t)?new ue($.parsePlatformTagName(t),n,a,void 0,void 0,e):n&&n.pre||!i(f=Ee(e.$options,"components",t))?new ue(t,n,a,void 0,void 0,e):Et(f,n,e,a,t)}else u=Et(t,n,e,a);return Array.isArray(u)?u:i(u)?(i(l)&&function e(t,n,a){t.ns=n,"foreignObject"===t.tag&&(n=void 0,a=!0);if(i(t.children))for(var s=0,c=t.children.length;s<c;s++){var u=t.children[s];i(u.tag)&&(r(u.ns)||o(a)&&"svg"!==u.tag)&&e(u,n,a)}}(u,l),i(n)&&function(e){s(e.style)&&Ye(e.style);s(e.class)&&Ye(e.class)}(n),u):fe()}(e,t,n,c,u)}var Ft,jt=null;function $t(e,t){return(e.__esModule||re&&"Module"===e[Symbol.toStringTag])&&(e=e.default),s(e)?t.extend(e):e}function Rt(e){return e.isComment&&e.asyncFactory}function Nt(e,t){Ft.$on(e,t)}function Ut(e,t){Ft.$off(e,t)}function Bt(e,t){var n=Ft;return function r(){var i=t.apply(null,arguments);null!==i&&n.$off(e,r)}}function zt(e,t,n){Ft=e,function(e,t,n,i,a,s){var c,u,l,f;for(c in e)u=e[c],l=t[c],f=Qe(c),r(u)||(r(l)?(r(u.fns)&&(u=e[c]=Ze(u,s)),o(f.once)&&(u=e[c]=a(f.name,u,f.capture)),n(f.name,u,f.capture,f.passive,f.params)):u!==l&&(l.fns=u,e[c]=l));for(c in t)r(e[c])&&(f=Qe(c),i(f.name,t[c],f.capture))}(t,n||{},Nt,Ut,Bt,e),Ft=void 0}var Wt=null;function qt(e){while(e&&(e=e.$parent))if(e._inactive)return!0;return!1}function Ht(e,t){if(t){if(e._directInactive=!1,qt(e))return}else if(e._directInactive)return;if(e._inactive||null===e._inactive){e._inactive=!1;for(var n=0;n<e.$children.length;n++)Ht(e.$children[n]);Vt(e,"activated")}}function Vt(e,t){se();var n=e.$options[t],r=t+" hook";if(n)for(var i=0,o=n.length;i<o;i++)Re(n[i],e,null,e,r);e._hasHookEvent&&e.$emit("hook:"+t),ce()}var Kt=[],Gt=[],Jt={},Xt=!1,Yt=!1,Qt=0;var Zt=Date.now;if(q&&!G){var en=window.performance;en&&"function"===typeof en.now&&Zt()>document.createEvent("Event").timeStamp&&(Zt=function(){return en.now()})}function tn(){var e,t;for(Zt(),Yt=!0,Kt.sort((function(e,t){return e.id-t.id})),Qt=0;Qt<Kt.length;Qt++)e=Kt[Qt],e.before&&e.before(),t=e.id,Jt[t]=null,e.run();var n=Gt.slice(),r=Kt.slice();(function(){Qt=Kt.length=Gt.length=0,Jt={},Xt=Yt=!1})(),function(e){for(var t=0;t<e.length;t++)e[t]._inactive=!0,Ht(e[t],!0)}(n),function(e){var t=e.length;while(t--){var n=e[t],r=n.vm;r._watcher===n&&r._isMounted&&!r._isDestroyed&&Vt(r,"updated")}}(r),ee&&$.devtools&&ee.emit("flush")}var nn=0,rn=function(e,t,n,r,i){this.vm=e,i&&(e._watcher=this),e._watchers.push(this),r?(this.deep=!!r.deep,this.user=!!r.user,this.lazy=!!r.lazy,this.sync=!!r.sync,this.before=r.before):this.deep=this.user=this.lazy=this.sync=!1,this.cb=n,this.id=++nn,this.active=!0,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new ne,this.newDepIds=new ne,this.expression="","function"===typeof t?this.getter=t:(this.getter=function(e){if(!B.test(e)){var t=e.split(".");return function(e){for(var n=0;n<t.length;n++){if(!e)return;e=e[t[n]]}return e}}}(t),this.getter||(this.getter=C)),this.value=this.lazy?void 0:this.get()};rn.prototype.get=function(){var e;se(this);var t=this.vm;try{e=this.getter.call(t,t)}catch($n){if(!this.user)throw $n;$e($n,t,'getter for watcher "'+this.expression+'"')}finally{this.deep&&Ye(e),ce(),this.cleanupDeps()}return e},rn.prototype.addDep=function(e){var t=e.id;this.newDepIds.has(t)||(this.newDepIds.add(t),this.newDeps.push(e),this.depIds.has(t)||e.addSub(this))},rn.prototype.cleanupDeps=function(){var e=this.deps.length;while(e--){var t=this.deps[e];this.newDepIds.has(t.id)||t.removeSub(this)}var n=this.depIds;this.depIds=this.newDepIds,this.newDepIds=n,this.newDepIds.clear(),n=this.deps,this.deps=this.newDeps,this.newDeps=n,this.newDeps.length=0},rn.prototype.update=function(){this.lazy?this.dirty=!0:this.sync?this.run():function(e){var t=e.id;if(null==Jt[t]){if(Jt[t]=!0,Yt){var n=Kt.length-1;while(n>Qt&&Kt[n].id>e.id)n--;Kt.splice(n+1,0,e)}else Kt.push(e);Xt||(Xt=!0,Je(tn))}}(this)},rn.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||s(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch($n){$e($n,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},rn.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},rn.prototype.depend=function(){var e=this.deps.length;while(e--)this.deps[e].depend()},rn.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||v(this.vm._watchers,this);var e=this.deps.length;while(e--)this.deps[e].removeSub(this);this.active=!1}};var on={enumerable:!0,configurable:!0,get:C,set:C};function an(e,t,n){on.get=function(){return this[t][n]},on.set=function(e){this[t][n]=e},Object.defineProperty(e,n,on)}function sn(e){e._watchers=[];var t=e.$options;t.props&&function(e,t){var n=e.$options.propsData||{},r=e._props={},i=e.$options._propKeys=[],o=!e.$parent;o||ye(!1);var a=function(o){i.push(o);var a=De(o,t,n,e);be(r,o,a),o in e||an(e,"_props",o)};for(var s in t)a(s);ye(!0)}(e,t.props),t.methods&&function(e,t){e.$options.props;for(var n in t)e[n]="function"!==typeof t[n]?C:S(t[n],e)}(e,t.methods),t.data?function(e){var t=e.$options.data;t=e._data="function"===typeof t?function(e,t){se();try{return e.call(t,t)}catch($n){return $e($n,t,"data()"),{}}finally{ce()}}(t,e):t||{},u(t)||(t={});var n=Object.keys(t),r=e.$options.props,i=(e.$options.methods,n.length);while(i--){var o=n[i];0,r&&m(r,o)||N(o)||an(e,"_data",o)}_e(t,!0)}(e):_e(e._data={},!0),t.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),r=Z();for(var i in t){var o=t[i],a="function"===typeof o?o:o.get;0,r||(n[i]=new rn(e,a||C,C,cn)),i in e||un(e,i,o)}}(e,t.computed),t.watch&&t.watch!==Y&&function(e,t){for(var n in t){var r=t[n];if(Array.isArray(r))for(var i=0;i<r.length;i++)dn(e,n,r[i]);else dn(e,n,r)}}(e,t.watch)}var cn={lazy:!0};function un(e,t,n){var r=!Z();"function"===typeof n?(on.get=r?ln(t):fn(n),on.set=C):(on.get=n.get?r&&!1!==n.cache?ln(t):fn(n.get):C,on.set=n.set||C),Object.defineProperty(e,t,on)}function ln(e){return function(){var t=this._computedWatchers&&this._computedWatchers[e];if(t)return t.dirty&&t.evaluate(),ae.SharedObject.target&&t.depend(),t.value}}function fn(e){return function(){return e.call(this,this)}}function dn(e,t,n,r){return u(n)&&(r=n,n=n.handler),"string"===typeof n&&(n=e[n]),e.$watch(t,n,r)}var hn=0;function pn(e){var t=e.options;if(e.super){var n=pn(e.super),r=e.superOptions;if(n!==r){e.superOptions=n;var i=function(e){var t,n=e.options,r=e.sealedOptions;for(var i in n)n[i]!==r[i]&&(t||(t={}),t[i]=n[i]);return t}(e);i&&T(e.extendOptions,i),t=e.options=Ie(n,e.extendOptions),t.name&&(t.components[t.name]=e)}}return t}function gn(e){this._init(e)}function vn(e){e.cid=0;var t=1;e.extend=function(e){e=e||{};var n=this,r=n.cid,i=e._Ctor||(e._Ctor={});if(i[r])return i[r];var o=e.name||n.options.name;var a=function(e){this._init(e)};return a.prototype=Object.create(n.prototype),a.prototype.constructor=a,a.cid=t++,a.options=Ie(n.options,e),a["super"]=n,a.options.props&&function(e){var t=e.options.props;for(var n in t)an(e.prototype,"_props",n)}(a),a.options.computed&&function(e){var t=e.options.computed;for(var n in t)un(e.prototype,n,t[n])}(a),a.extend=n.extend,a.mixin=n.mixin,a.use=n.use,F.forEach((function(e){a[e]=n[e]})),o&&(a.options.components[o]=a),a.superOptions=n.options,a.extendOptions=e,a.sealedOptions=T({},a.options),i[r]=a,a}}function yn(e){return e&&(e.Ctor.options.name||e.tag)}function mn(e,t){return Array.isArray(e)?e.indexOf(t)>-1:"string"===typeof e?e.split(",").indexOf(t)>-1:!!function(e){return"[object RegExp]"===c.call(e)}(e)&&e.test(t)}function xn(e,t){var n=e.cache,r=e.keys,i=e._vnode;for(var o in n){var a=n[o];if(a){var s=yn(a.componentOptions);s&&!t(s)&&_n(n,o,r,i)}}}function _n(e,t,n,r){var i=e[t];!i||r&&i.tag===r.tag||i.componentInstance.$destroy(),e[t]=null,v(n,t)}(function(e){e.prototype._init=function(e){var t=this;t._uid=hn++,t._isVue=!0,e&&e._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),r=t._parentVnode;n.parent=t.parent,n._parentVnode=r;var i=r.componentOptions;n.propsData=i.propsData,n._parentListeners=i.listeners,n._renderChildren=i.children,n._componentTag=i.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(t,e):t.$options=Ie(pn(t.constructor),e||{},t),t._renderProxy=t,t._self=t,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){while(n.$options.abstract&&n.$parent)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(t),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&zt(e,t)}(t),function(e){e._vnode=null,e._staticTrees=null;var t=e.$options,r=e.$vnode=t._parentVnode,i=r&&r.context;e.$slots=st(t._renderChildren,i),e.$scopedSlots=n,e._c=function(t,n,r,i){return Mt(e,t,n,r,i,!1)},e.$createElement=function(t,n,r,i){return Mt(e,t,n,r,i,!0)};var o=r&&r.data;be(e,"$attrs",o&&o.attrs||n,null,!0),be(e,"$listeners",t._parentListeners||n,null,!0)}(t),Vt(t,"beforeCreate"),!t._$fallback&&ot(t),sn(t),!t._$fallback&&it(t),!t._$fallback&&Vt(t,"created"),t.$options.el&&t.$mount(t.$options.el)}})(gn),function(e){var t={get:function(){return this._data}},n={get:function(){return this._props}};Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=we,e.prototype.$delete=ke,e.prototype.$watch=function(e,t,n){if(u(t))return dn(this,e,t,n);n=n||{},n.user=!0;var r=new rn(this,e,t,n);if(n.immediate)try{t.call(this,r.value)}catch(i){$e(i,this,'callback for immediate watcher "'+r.expression+'"')}return function(){r.teardown()}}}(gn),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var r=this;if(Array.isArray(e))for(var i=0,o=e.length;i<o;i++)r.$on(e[i],n);else(r._events[e]||(r._events[e]=[])).push(n),t.test(e)&&(r._hasHookEvent=!0);return r},e.prototype.$once=function(e,t){var n=this;function r(){n.$off(e,r),t.apply(n,arguments)}return r.fn=t,n.$on(e,r),n},e.prototype.$off=function(e,t){var n=this;if(!arguments.length)return n._events=Object.create(null),n;if(Array.isArray(e)){for(var r=0,i=e.length;r<i;r++)n.$off(e[r],t);return n}var o,a=n._events[e];if(!a)return n;if(!t)return n._events[e]=null,n;var s=a.length;while(s--)if(o=a[s],o===t||o.fn===t){a.splice(s,1);break}return n},e.prototype.$emit=function(e){var t=this,n=t._events[e];if(n){n=n.length>1?P(n):n;for(var r=P(arguments,1),i='event handler for "'+e+'"',o=0,a=n.length;o<a;o++)Re(n[o],t,r,t,i)}return t}}(gn),function(e){e.prototype._update=function(e,t){var n=this,r=n.$el,i=n._vnode,o=function(e){var t=Wt;return Wt=e,function(){Wt=t}}(n);n._vnode=e,n.$el=i?n.__patch__(i,e):n.__patch__(n.$el,e,t,!1),o(),r&&(r.__vue__=null),n.$el&&(n.$el.__vue__=n),n.$vnode&&n.$parent&&n.$vnode===n.$parent._vnode&&(n.$parent.$el=n.$el)},e.prototype.$forceUpdate=function(){this._watcher&&this._watcher.update()},e.prototype.$destroy=function(){var e=this;if(!e._isBeingDestroyed){Vt(e,"beforeDestroy"),e._isBeingDestroyed=!0;var t=e.$parent;!t||t._isBeingDestroyed||e.$options.abstract||v(t.$children,e),e._watcher&&e._watcher.teardown();var n=e._watchers.length;while(n--)e._watchers[n].teardown();e._data.__ob__&&e._data.__ob__.vmCount--,e._isDestroyed=!0,e.__patch__(e._vnode,null),Vt(e,"destroyed"),e.$off(),e.$el&&(e.$el.__vue__=null),e.$vnode&&(e.$vnode.parent=null)}}}(gn),function(e){Pt(e.prototype),e.prototype.$nextTick=function(e){return Je(e,this)},e.prototype._render=function(){var e,t=this,n=t.$options,r=n.render,i=n._parentVnode;i&&(t.$scopedSlots=ut(i.data.scopedSlots,t.$slots,t.$scopedSlots)),t.$vnode=i;try{jt=t,e=r.call(t._renderProxy,t.$createElement)}catch($n){$e($n,t,"render"),e=t._vnode}finally{jt=null}return Array.isArray(e)&&1===e.length&&(e=e[0]),e instanceof ue||(e=fe()),e.parent=i,e}}(gn);var bn=[String,RegExp,Array],wn={name:"keep-alive",abstract:!0,props:{include:bn,exclude:bn,max:[String,Number]},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){for(var e in this.cache)_n(this.cache,e,this.keys)},mounted:function(){var e=this;this.$watch("include",(function(t){xn(e,(function(e){return mn(t,e)}))})),this.$watch("exclude",(function(t){xn(e,(function(e){return!mn(t,e)}))}))},render:function(){var e=this.$slots.default,t=function(e){if(Array.isArray(e))for(var t=0;t<e.length;t++){var n=e[t];if(i(n)&&(i(n.componentOptions)||Rt(n)))return n}}(e),n=t&&t.componentOptions;if(n){var r=yn(n),o=this.include,a=this.exclude;if(o&&(!r||!mn(o,r))||a&&r&&mn(a,r))return t;var s=this.cache,c=this.keys,u=null==t.key?n.Ctor.cid+(n.tag?"::"+n.tag:""):t.key;s[u]?(t.componentInstance=s[u].componentInstance,v(c,u),c.push(u)):(s[u]=t,c.push(u),this.max&&c.length>parseInt(this.max)&&_n(s,c[0],c,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}},kn={KeepAlive:wn};(function(e){var t={get:function(){return $}};Object.defineProperty(e,"config",t),e.util={warn:ie,extend:T,mergeOptions:Ie,defineReactive:be},e.set=we,e.delete=ke,e.nextTick=Je,e.observable=function(e){return _e(e),e},e.options=Object.create(null),F.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,T(e.options.components,kn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=P(arguments,1);return n.unshift(this),"function"===typeof e.install?e.install.apply(e,n):"function"===typeof e&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=Ie(this.options,e),this}}(e),vn(e),function(e){F.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&u(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"===typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)})(gn),Object.defineProperty(gn.prototype,"$isServer",{get:Z}),Object.defineProperty(gn.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(gn,"FunctionalRenderContext",{value:Tt}),gn.version="2.6.11";var An="[object Array]",Sn="[object Object]";function Pn(e,t){var n={};return function e(t,n){if(t===n)return;var r=On(t),i=On(n);if(r==Sn&&i==Sn){if(Object.keys(t).length>=Object.keys(n).length)for(var o in n){var a=t[o];void 0===a?t[o]=null:e(a,n[o])}}else r==An&&i==An&&t.length>=n.length&&n.forEach((function(n,r){e(t[r],n)}))}(e,t),function e(t,n,r,i){if(t===n)return;var o=On(t),a=On(n);if(o==Sn)if(a!=Sn||Object.keys(t).length<Object.keys(n).length)Tn(i,r,t);else{var s=function(o){var a=t[o],s=n[o],c=On(a),u=On(s);if(c!=An&&c!=Sn)a!==n[o]&&function(e,t){if(("[object Null]"===e||"[object Undefined]"===e)&&("[object Null]"===t||"[object Undefined]"===t))return!1;return!0}(c,u)&&Tn(i,(""==r?"":r+".")+o,a);else if(c==An)u!=An||a.length<s.length?Tn(i,(""==r?"":r+".")+o,a):a.forEach((function(t,n){e(t,s[n],(""==r?"":r+".")+o+"["+n+"]",i)}));else if(c==Sn)if(u!=Sn||Object.keys(a).length<Object.keys(s).length)Tn(i,(""==r?"":r+".")+o,a);else for(var l in a)e(a[l],s[l],(""==r?"":r+".")+o+"."+l,i)};for(var c in t)s(c)}else o==An?a!=An||t.length<n.length?Tn(i,r,t):t.forEach((function(t,o){e(t,n[o],r+"["+o+"]",i)})):Tn(i,r,t)}(e,t,"",n),n}function Tn(e,t,n){e[t]=n}function On(e){return Object.prototype.toString.call(e)}function Cn(e){if(e.__next_tick_callbacks&&e.__next_tick_callbacks.length){if(Object({NODE_ENV:"production",VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"kitchendDevice",VUE_APP_PLATFORM:"mp-weixin",BASE_URL:"/"}).VUE_APP_DEBUG){var t=e.$scope;console.log("["+ +new Date+"]["+(t.is||t.route)+"]["+e._uid+"]:flushCallbacks["+e.__next_tick_callbacks.length+"]")}var n=e.__next_tick_callbacks.slice(0);e.__next_tick_callbacks.length=0;for(var r=0;r<n.length;r++)n[r]()}}function Ln(e,t){if(!e.__next_tick_pending&&!function(e){return Kt.find((function(t){return e._watcher===t}))}(e)){if(Object({NODE_ENV:"production",VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"kitchendDevice",VUE_APP_PLATFORM:"mp-weixin",BASE_URL:"/"}).VUE_APP_DEBUG){var n=e.$scope;console.log("["+ +new Date+"]["+(n.is||n.route)+"]["+e._uid+"]:nextVueTick")}return Je(t,e)}if(Object({NODE_ENV:"production",VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"kitchendDevice",VUE_APP_PLATFORM:"mp-weixin",BASE_URL:"/"}).VUE_APP_DEBUG){var r=e.$scope;console.log("["+ +new Date+"]["+(r.is||r.route)+"]["+e._uid+"]:nextMPTick")}var i;if(e.__next_tick_callbacks||(e.__next_tick_callbacks=[]),e.__next_tick_callbacks.push((function(){if(t)try{t.call(e)}catch($n){$e($n,e,"nextTick")}else i&&i(e)})),!t&&"undefined"!==typeof Promise)return new Promise((function(e){i=e}))}function In(e,t){return t&&(t._isVue||t.__v_isMPComponent)?{}:t}function En(){}function Dn(e){return Array.isArray(e)?function(e){for(var t,n="",r=0,o=e.length;r<o;r++)i(t=Dn(e[r]))&&""!==t&&(n&&(n+=" "),n+=t);return n}(e):s(e)?function(e){var t="";for(var n in e)e[n]&&(t&&(t+=" "),t+=n);return t}(e):"string"===typeof e?e:""}var Mn=x((function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach((function(e){if(e){var r=e.split(n);r.length>1&&(t[r[0].trim()]=r[1].trim())}})),t}));var Fn=["createSelectorQuery","createIntersectionObserver","selectAllComponents","selectComponent"];var jn=["onLaunch","onShow","onHide","onUniNViewMessage","onPageNotFound","onThemeChange","onError","onUnhandledRejection","onInit","onLoad","onReady","onUnload","onPullDownRefresh","onReachBottom","onTabItemTap","onAddToFavorites","onShareTimeline","onShareAppMessage","onResize","onPageScroll","onNavigationBarButtonTap","onBackPress","onNavigationBarSearchInputChanged","onNavigationBarSearchInputConfirmed","onNavigationBarSearchInputClicked","onUploadDouyinVideo","onNFCReadMessage","onPageShow","onPageHide","onPageResize"];gn.prototype.__patch__=function(e,t){var n=this;if(null!==t&&("page"===this.mpType||"component"===this.mpType)){var r=this.$scope,i=Object.create(null);try{i=function(e){var t=Object.create(null),n=[].concat(Object.keys(e._data||{}),Object.keys(e._computedWatchers||{}));n.reduce((function(t,n){return t[n]=e[n],t}),t);var r=e.__composition_api_state__||e.__secret_vfa_state__,i=r&&r.rawBindings;return i&&Object.keys(i).forEach((function(n){t[n]=e[n]})),Object.assign(t,e.$mp.data||{}),Array.isArray(e.$options.behaviors)&&-1!==e.$options.behaviors.indexOf("uni://form-field")&&(t["name"]=e.name,t["value"]=e.value),JSON.parse(JSON.stringify(t,In))}(this)}catch(s){console.error(s)}i.__webviewId__=r.data.__webviewId__;var o=Object.create(null);Object.keys(i).forEach((function(e){o[e]=r.data[e]}));var a=!1===this.$shouldDiffData?i:Pn(i,o);Object.keys(a).length?(Object({NODE_ENV:"production",VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"kitchendDevice",VUE_APP_PLATFORM:"mp-weixin",BASE_URL:"/"}).VUE_APP_DEBUG&&console.log("["+ +new Date+"]["+(r.is||r.route)+"]["+this._uid+"]差量更新",JSON.stringify(a)),this.__next_tick_pending=!0,r.setData(a,(function(){n.__next_tick_pending=!1,Cn(n)}))):Cn(this)}},gn.prototype.$mount=function(e,t){return function(e,t,n){return e.mpType?("app"===e.mpType&&(e.$options.render=En),e.$options.render||(e.$options.render=En),!e._$fallback&&Vt(e,"beforeMount"),new rn(e,(function(){e._update(e._render(),n)}),C,{before:function(){e._isMounted&&!e._isDestroyed&&Vt(e,"beforeUpdate")}},!0),n=!1,e):e}(this,0,t)},function(e){var t=e.extend;e.extend=function(e){e=e||{};var n=e.methods;return n&&Object.keys(n).forEach((function(t){-1!==jn.indexOf(t)&&(e[t]=n[t],delete n[t])})),t.call(this,e)};var n=e.config.optionMergeStrategies,r=n.created;jn.forEach((function(e){n[e]=r})),e.prototype.__lifecycle_hooks__=jn}(gn),function(e){e.config.errorHandler=function(t,n,r){e.util.warn("Error in "+r+': "'+t.toString()+'"',n),console.error(t);var i="function"===typeof getApp&&getApp();i&&i.onError&&i.onError(t)};var t=e.prototype.$emit;e.prototype.$emit=function(e){if(this.$scope&&e){var n=this.$scope["_triggerEvent"]||this.$scope["triggerEvent"];if(n)try{n.call(this.$scope,e,{__args__:P(arguments,1)})}catch(r){}}return t.apply(this,arguments)},e.prototype.$nextTick=function(e){return Ln(this,e)},Fn.forEach((function(t){e.prototype[t]=function(e){return this.$scope&&this.$scope[t]?this.$scope[t](e):"undefined"!==typeof my?"createSelectorQuery"===t?my.createSelectorQuery(e):"createIntersectionObserver"===t?my.createIntersectionObserver(e):void 0:void 0}})),e.prototype.__init_provide=it,e.prototype.__init_injections=ot,e.prototype.__call_hook=function(e,t){var n=this;se();var r,i=n.$options[e],o=e+" hook";if(i)for(var a=0,s=i.length;a<s;a++)r=Re(i[a],n,t?[t]:null,n,o);return n._hasHookEvent&&n.$emit("hook:"+e,t),ce(),r},e.prototype.__set_model=function(t,n,r,i){Array.isArray(i)&&(-1!==i.indexOf("trim")&&(r=r.trim()),-1!==i.indexOf("number")&&(r=this._n(r))),t||(t=this),e.set(t,n,r)},e.prototype.__set_sync=function(t,n,r){t||(t=this),e.set(t,n,r)},e.prototype.__get_orig=function(e){return u(e)&&e["$orig"]||e},e.prototype.__get_value=function(e,t){return function e(t,n){var r=n.split("."),i=r[0];return 0===i.indexOf("__$n")&&(i=parseInt(i.replace("__$n",""))),1===r.length?t[i]:e(t[i],r.slice(1).join("."))}(t||this,e)},e.prototype.__get_class=function(e,t){return function(e,t){return i(e)||i(t)?function(e,t){return e?t?e+" "+t:e:t||""}(e,Dn(t)):""}(t,e)},e.prototype.__get_style=function(e,t){if(!e&&!t)return"";var n=function(e){return Array.isArray(e)?O(e):"string"===typeof e?Mn(e):e}(e),r=t?T(t,n):n;return Object.keys(r).map((function(e){return A(e)+":"+r[e]})).join(";")},e.prototype.__map=function(e,t){var n,r,i,o,a;if(Array.isArray(e)){for(n=new Array(e.length),r=0,i=e.length;r<i;r++)n[r]=t(e[r],r);return n}if(s(e)){for(o=Object.keys(e),n=Object.create(null),r=0,i=o.length;r<i;r++)a=o[r],n[a]=t(e[a],a,r);return n}if("number"===typeof e){for(n=new Array(e),r=0,i=e;r<i;r++)n[r]=t(r,r);return n}return[]}}(gn),t["default"]=gn}.call(this,n("0ee4"))},3352:function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports["default"]=e.exports},"34cf":function(e,t,n){var r=n("ed45"),i=n("7172"),o=n("6382"),a=n("dd3e");e.exports=function(e,t){return r(e)||i(e,t)||o(e,t)||a()},e.exports.__esModule=!0,e.exports["default"]=e.exports},"38a5":function(e,t,n){},"3b2d":function(e,t){function n(t){return e.exports=n="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.__esModule=!0,e.exports["default"]=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports["default"]=e.exports},"3e50":function(e,t,n){(function(t,n){var r=t.getAccountInfoSync(),i=r.miniProgram.appId;n.setStorageSync("appid",i);var o={};console.log("生产环境"),o={host:"https://tc.pcxbc.com",envVersion:"develop"},e.exports={appid:i,configPro:o}}).call(this,n("3223")["default"],n("df3c")["default"])},"47a9":function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports["default"]=e.exports},4965:function(e,t){e.exports=function(e){try{return-1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"===typeof e}},e.exports.__esModule=!0,e.exports["default"]=e.exports},"4ffb":function(e,t,n){var r=n("3b2d")["default"],i=n("3352");e.exports=function(e,t){if(t&&("object"===r(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},"532d":function(e,t,n){"use strict";(function(e){var t=n("34cf"),r=n("3b2d"),i={version:"v2.1.5-20210517",yAxisWidth:15,yAxisSplit:5,xAxisHeight:22,xAxisLineHeight:22,legendHeight:15,yAxisTitleWidth:15,padding:[10,10,10,10],pixelRatio:1,rotate:!1,columePadding:3,fontSize:13,fontColor:"#666666",dataPointShape:["circle","circle","circle","circle"],color:["#1890FF","#91CB74","#FAC858","#EE6666","#73C0DE","#3CA272","#FC8452","#9A60B4","#ea7ccc"],linearColor:["#0EE2F8","#2BDCA8","#FA7D8D","#EB88E2","#2AE3A0","#0EE2F8","#EB88E2","#6773E3","#F78A85"],pieChartLinePadding:15,pieChartTextPadding:5,xAxisTextPadding:3,titleColor:"#333333",titleFontSize:20,subtitleColor:"#999999",subtitleFontSize:15,toolTipPadding:3,toolTipBackground:"#000000",toolTipOpacity:.7,toolTipLineHeight:20,radarLabelTextMargin:13,gaugeLabelTextMargin:13},o=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];if(null==e)throw new TypeError("[uCharts] Cannot convert undefined or null to object");if(!n||n.length<=0)return e;function i(e,t){for(var n in t)e[n]=e[n]&&"[object Object]"===e[n].toString()?i(e[n],t[n]):e[n]=t[n];return e}return n.forEach((function(t){e=i(e,t)})),e},a={toFixed:function(e,t){return t=t||2,this.isFloat(e)&&(e=e.toFixed(t)),e},isFloat:function(e){return e%1!==0},approximatelyEqual:function(e,t){return Math.abs(e-t)<1e-10},isSameSign:function(e,t){return Math.abs(e)===e&&Math.abs(t)===t||Math.abs(e)!==e&&Math.abs(t)!==t},isSameXCoordinateArea:function(e,t){return this.isSameSign(e.x,t.x)},isCollision:function(e,t){e.end={},e.end.x=e.start.x+e.width,e.end.y=e.start.y-e.height,t.end={},t.end.x=t.start.x+t.width,t.end.y=t.start.y-t.height;var n=t.start.x>e.end.x||t.end.x<e.start.x||t.end.y>e.start.y||t.start.y<e.end.y;return!n}};function s(e,t){var n=Array(2),r=20037508.34*e/180,i=Math.log(Math.tan((90+t)*Math.PI/360))/(Math.PI/180);return i=20037508.34*i/180,n[0]=r,n[1]=i,n}function c(e,t){var n=e.replace(/^#?([a-f\d])([a-f\d])([a-f\d])$/i,(function(e,t,n,r){return t+t+n+n+r+r})),r=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(n),i=parseInt(r[1],16),o=parseInt(r[2],16),a=parseInt(r[3],16);return"rgba("+i+","+o+","+a+","+t+")"}function u(e,t,n){if(isNaN(e))throw new Error("[uCharts] series数据需为Number格式");n=n||10,t=t||"upper";var r=1;while(n<1)n*=10,r*=10;e="upper"===t?Math.ceil(e*r):Math.floor(e*r);while(e%n!==0)"upper"===t?e++:e--;return e/r}function l(e,t,n){function r(e){while(e<0)e+=2*Math.PI;while(e>2*Math.PI)e-=2*Math.PI;return e}return e=r(e),t=r(t),n=r(n),t>n&&(n+=2*Math.PI,e<t&&(e+=2*Math.PI)),e>=t&&e<=n}function f(e,t){function n(e,t){return!(!e[t-1]||!e[t+1])&&(e[t].y>=Math.max(e[t-1].y,e[t+1].y)||e[t].y<=Math.min(e[t-1].y,e[t+1].y))}function r(e,t){return!(!e[t-1]||!e[t+1])&&(e[t].x>=Math.max(e[t-1].x,e[t+1].x)||e[t].x<=Math.min(e[t-1].x,e[t+1].x))}var i=.2,o=.2,a=null,s=null,c=null,u=null;if(t<1?(a=e[0].x+(e[1].x-e[0].x)*i,s=e[0].y+(e[1].y-e[0].y)*i):(a=e[t].x+(e[t+1].x-e[t-1].x)*i,s=e[t].y+(e[t+1].y-e[t-1].y)*i),t>e.length-3){var l=e.length-1;c=e[l].x-(e[l].x-e[l-1].x)*o,u=e[l].y-(e[l].y-e[l-1].y)*o}else c=e[t+1].x-(e[t+2].x-e[t].x)*o,u=e[t+1].y-(e[t+2].y-e[t].y)*o;return n(e,t+1)&&(u=e[t+1].y),n(e,t)&&(s=e[t].y),r(e,t+1)&&(c=e[t+1].x),r(e,t)&&(a=e[t].x),(s>=Math.max(e[t].y,e[t+1].y)||s<=Math.min(e[t].y,e[t+1].y))&&(s=e[t].y),(u>=Math.max(e[t].y,e[t+1].y)||u<=Math.min(e[t].y,e[t+1].y))&&(u=e[t+1].y),(a>=Math.max(e[t].x,e[t+1].x)||a<=Math.min(e[t].x,e[t+1].x))&&(a=e[t].x),(c>=Math.max(e[t].x,e[t+1].x)||c<=Math.min(e[t].x,e[t+1].x))&&(c=e[t+1].x),{ctrA:{x:a,y:s},ctrB:{x:c,y:u}}}function d(e,t,n){return{x:n.x+e,y:n.y-t}}function h(e,t){if(t)while(a.isCollision(e,t))e.start.x>0?e.start.y--:e.start.x<0||e.start.y>0?e.start.y++:e.start.y--;return e}function p(e,t,n){for(var r=0,i=0;i<e.length;i++){var o=e[i];if(o.color||(o.color=n.color[r],r=(r+1)%n.color.length),o.linearIndex||(o.linearIndex=i),o.index||(o.index=0),o.type||(o.type=t.type),"undefined"==typeof o.show&&(o.show=!0),o.type||(o.type=t.type),o.pointShape||(o.pointShape="circle"),!o.legendShape)switch(o.type){case"line":o.legendShape="line";break;case"column":o.legendShape="rect";break;case"area":o.legendShape="triangle";break;default:o.legendShape="circle"}}return e}function g(e,t,n,r){var i=t||[];if("custom"==e&&0==i.length&&(i=r.linearColor),"custom"==e&&i.length<n.length)for(var o=n.length-i.length,a=0;a<o;a++)i.push(r.linearColor[(a+1)%r.linearColor.length]);return i}function v(e,t){var n=0,r=t-e;return n=r>=1e4?1e3:r>=1e3?100:r>=100?10:r>=10?5:r>=1?1:r>=.1?.1:r>=.01?.01:r>=.001?.001:r>=1e-4?1e-4:r>=1e-5?1e-5:1e-6,{minRange:u(e,"lower",n),maxRange:u(t,"upper",n)}}function y(e,t,n){var r=0;if(e=String(e),!1!==n&&void 0!==n&&n.setFontSize&&n.measureText)return n.setFontSize(t),n.measureText(e).width;e=e.split("");for(var i=0;i<e.length;i++){var o=e[i];/[a-zA-Z]/.test(o)?r+=7:/[0-9]/.test(o)?r+=5.5:/\./.test(o)?r+=2.7:/-/.test(o)?r+=3.25:/:/.test(o)?r+=2.5:/[\u4e00-\u9fa5]/.test(o)?r+=10:/\(|\)/.test(o)?r+=3.73:/\s/.test(o)?r+=2.5:/%/.test(o)?r+=8:r+=10}return r*t/10}function m(e){return e.reduce((function(e,t){return(e.data?e.data:e).concat(t.data)}),[])}function x(e,t){for(var n=new Array(t),r=0;r<n.length;r++)n[r]=0;for(var i=0;i<e.length;i++)for(r=0;r<n.length;r++)n[r]+=e[i].data[r];return e.reduce((function(e,t){return(e.data?e.data:e).concat(t.data).concat(n)}),[])}function _(e,t,n){var r,i;return e.clientX?t.rotate?(i=t.height-e.clientX*t.pix,r=(e.pageY-n.currentTarget.offsetTop-t.height/t.pix/2*(t.pix-1))*t.pix):(r=e.clientX*t.pix,i=(e.pageY-n.currentTarget.offsetTop-t.height/t.pix/2*(t.pix-1))*t.pix):t.rotate?(i=t.height-e.x*t.pix,r=e.y*t.pix):(r=e.x*t.pix,i=e.y*t.pix),{x:r,y:i}}function b(e,t,n){var r=[],i=[],o=t.constructor.toString().indexOf("Array")>-1;if(o)for(var a=T(e),s=0;s<n.length;s++)i.push(a[n[s]]);else i=e;for(var c=0;c<i.length;c++){var u=i[c],l=-1;if(l=o?t[c]:t,null!==u.data[l]&&"undefined"!==typeof u.data[l]&&u.show){var f={};f.color=u.color,f.type=u.type,f.style=u.style,f.pointShape=u.pointShape,f.disableLegend=u.disableLegend,f.name=u.name,f.show=u.show,f.data=u.formatter?u.formatter(u.data[l]):u.data[l],r.push(f)}}return r}function w(e,t,n){var r=e.map((function(e){return y(e,t,n)}));return Math.max.apply(null,r)}function k(e){for(var t=2*Math.PI/e,n=[],r=0;r<e;r++)n.push(t*r);return n.map((function(e){return-1*e+Math.PI/2}))}function A(e,t,n,r,i){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=t.chartData.calPoints?t.chartData.calPoints:[],s={};if(r.length>0){for(var c=[],u=0;u<r.length;u++)c.push(a[r[u]]);s=c[0][n[0]]}else s=a[0][n];var l=e.map((function(e){var r=null;return t.categories&&t.categories.length>0&&(r=i[n]),{text:o.formatter?o.formatter(e,r,n,t):e.name+": "+e.data,color:e.color}})),f={x:Math.round(s.x),y:Math.round(s.y)};return{textList:l,offset:f}}function S(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},o=t.chartData.xAxisPoints[n]+t.chartData.eachSpacing/2,a=e.map((function(e){return{text:i.formatter?i.formatter(e,r[n],n,t):e.name+": "+e.data,color:e.color,disableLegend:!!e.disableLegend}}));a=a.filter((function(e){if(!0!==e.disableLegend)return e}));var s={x:Math.round(o),y:0};return{textList:a,offset:s}}function P(e,t,n,r,i,o){var a=n.chartData.calPoints,s=o.color.upFill,c=o.color.downFill,u=[s,s,c,s],l=[];t.map((function(t){0==r?t.data[1]-t.data[0]<0?u[1]=c:u[1]=s:(t.data[0]<e[r-1][1]&&(u[0]=c),t.data[1]<t.data[0]&&(u[1]=c),t.data[2]>e[r-1][1]&&(u[2]=s),t.data[3]<e[r-1][1]&&(u[3]=c));var n={text:"开盘:"+t.data[0],color:u[0]},i={text:"收盘:"+t.data[1],color:u[1]},o={text:"最低:"+t.data[2],color:u[2]},a={text:"最高:"+t.data[3],color:u[3]};l.push(n,i,o,a)}));for(var f=[],d={x:0,y:0},h=0;h<a.length;h++){var p=a[h];"undefined"!==typeof p[r]&&null!==p[r]&&f.push(p[r])}return d.x=Math.round(f[0][0].x),{textList:l,offset:d}}function T(e){for(var t=[],n=0;n<e.length;n++)1==e[n].show&&t.push(e[n]);return t}function O(e,t,n){return e.x<=t.width-t.area[1]+10&&e.x>=t.area[3]-10&&e.y>=t.area[0]&&e.y<=t.height-t.area[2]}function C(e,t,n){return Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)<=Math.pow(n,2)}function L(e,t){var n=[],r=[];return e.forEach((function(e,i){t.connectNulls?null!==e&&r.push(e):null!==e?r.push(e):(r.length&&n.push(r),r=[])})),r.length&&n.push(r),n}function I(e,t,n,r,i){var o={angle:0,xAxisHeight:n.xAxisHeight},a=e.map((function(e){return y(e,t.xAxis.fontSize*t.pix||n.fontSize,i)})),s=Math.max.apply(this,a);return 1==t.xAxis.rotateLabel&&s+2*n.xAxisTextPadding>r&&(o.angle=45*Math.PI/180,o.xAxisHeight=2*n.xAxisTextPadding+s*Math.sin(o.angle)),o}function E(e,t,n,i){var o={angle:0,xAxisHeight:n.xAxisHeight};o.ranges=function(e,t,n){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1,o=m(e),a=[];o=o.filter((function(e){return"object"===r(e)&&null!==e?e.constructor.toString().indexOf("Array")>-1?null!==e:null!==e.value:null!==e})),o.map((function(e){"object"===r(e)?e.constructor.toString().indexOf("Array")>-1?"candle"==t.type?e.map((function(e){a.push(e)})):a.push(e[0]):a.push(e.value):a.push(e)}));var s=0,c=0;if(a.length>0&&(s=Math.min.apply(this,a),c=Math.max.apply(this,a)),i>-1?("number"===typeof t.xAxis.data[i].min&&(s=Math.min(t.xAxis.data[i].min,s)),"number"===typeof t.xAxis.data[i].max&&(c=Math.max(t.xAxis.data[i].max,c))):("number"===typeof t.xAxis.min&&(s=Math.min(t.xAxis.min,s)),"number"===typeof t.xAxis.max&&(c=Math.max(t.xAxis.max,c))),s===c){var u=c||10;c+=u}for(var l=s,f=c,d=[],h=(f-l)/t.xAxis.splitNumber,p=0;p<=t.xAxis.splitNumber;p++)d.push(l+h*p);return d}(e,t,n),o.rangesFormat=o.ranges.map((function(e){return e=a.toFixed(e,2),e}));var s=o.ranges.map((function(e){return e=a.toFixed(e,2),e}));o=Object.assign(o,W(s,t,n));var c=o.eachSpacing,u=s.map((function(e){return y(e,t.xAxis.fontSize*t.pix||n.fontSize,i)})),l=Math.max.apply(this,u);return l+2*n.xAxisTextPadding>c&&(o.angle=45*Math.PI/180,o.xAxisHeight=2*n.xAxisTextPadding+l*Math.sin(o.angle)),!0===t.xAxis.disabled&&(o.xAxisHeight=0),o}function D(e,t,n,r,i){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,a=i.extra.radar||{};a.max=a.max||0;for(var s=Math.max(a.max,Math.max.apply(null,m(r))),c=[],u=function(i){var a=r[i],u={};u.color=a.color,u.legendShape=a.legendShape,u.pointShape=a.pointShape,u.data=[],a.data.forEach((function(r,i){var a={};a.angle=e[i],a.proportion=r/s,a.position=d(n*a.proportion*o*Math.cos(a.angle),n*a.proportion*o*Math.sin(a.angle),t),u.data.push(a)})),c.push(u)},l=0;l<r.length;l++)u(l);return c}function M(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=0,i=0,o=0;o<e.length;o++){var a=e[o];a.data=null===a.data?0:a.data,r+=a.data}for(var s=0;s<e.length;s++){var c=e[s];c.data=null===c.data?0:c.data,c._proportion_=0===r?1/e.length*n:c.data/r*n,c._radius_=t}for(var u=0;u<e.length;u++){var l=e[u];l._start_=i,i+=2*l._proportion_*Math.PI}return e}function F(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1;e=e.sort((function(e,t){return parseInt(t.data)-parseInt(e.data)}));for(var o=0;o<e.length;o++)e[o].radius="funnel"==n?e[o].data/e[0].data*t*i:r*(e.length-o)/(r*e.length)*t*i,e[o]._proportion_=e[o].data/e[0].data;return"pyramid"!==n&&e.reverse(),e}function j(e,t,n,r){for(var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,o=0,a=0,s=[],c=0;c<e.length;c++){var u=e[c];u.data=null===u.data?0:u.data,o+=u.data,s.push(u.data)}for(var l=Math.min.apply(null,s),f=Math.max.apply(null,s),d=r-n,h=0;h<e.length;h++){var p=e[h];p.data=null===p.data?0:p.data,0===o?(p._proportion_=1/e.length*i,p._rose_proportion_=1/e.length*i):(p._proportion_=p.data/o*i,p._rose_proportion_="area"==t?1/e.length*i:p.data/o*i),p._radius_=n+d*((p.data-l)/(f-l))||r}for(var g=0;g<e.length;g++){var v=e[g];v._start_=a,a+=2*v._rose_proportion_*Math.PI}return e}function $(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;1==n&&(n=.999999);for(var r=0;r<e.length;r++){var i=e[r];i.data=null===i.data?0:i.data;var o=void 0;o="circle"==t.type?2:t.endAngle<t.startAngle?2+t.endAngle-t.startAngle:t.startAngle-t.endAngle,i._proportion_=o*i.data*n+t.startAngle,i._proportion_>=2&&(i._proportion_=i._proportion_%2)}return e}function R(e,t,n){for(var r=t-n+1,i=t,o=0;o<e.length;o++)e[o].value=null===e[o].value?0:e[o].value,e[o]._startAngle_=i,e[o]._endAngle_=r*e[o].value+t,e[o]._endAngle_>=2&&(e[o]._endAngle_=e[o]._endAngle_%2),i=e[o]._endAngle_;return e}function N(e,t,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,i=0;i<e.length;i++){var o=e[i];if(o.data=null===o.data?0:o.data,"auto"==n.pointer.color){for(var a=0;a<t.length;a++)if(o.data<=t[a].value){o.color=t[a].color;break}}else o.color=n.pointer.color;var s=n.startAngle-n.endAngle+1;o._endAngle_=s*o.data+n.startAngle,o._oldAngle_=n.oldAngle,n.oldAngle<n.endAngle&&(o._oldAngle_+=2),o.data>=n.oldData?o._proportion_=(o._endAngle_-o._oldAngle_)*r+n.oldAngle:o._proportion_=o._oldAngle_-(o._oldAngle_-o._endAngle_)*r,o._proportion_>=2&&(o._proportion_=o._proportion_%2)}return e}function U(e,t,n,r,i,o){return e.map((function(e){if(null===e)return null;var i=0,a=0;return"mix"==o.type?(i=o.extra.mix.column.seriesGap*o.pix||0,a=o.extra.mix.column.categoryGap*o.pix||0):(i=o.extra.column.seriesGap*o.pix||0,a=o.extra.column.categoryGap*o.pix||0),i=Math.min(i,t/n),a=Math.min(a,t/n),e.width=Math.ceil((t-2*a-i*(n-1))/n),o.extra.mix&&o.extra.mix.column.width&&+o.extra.mix.column.width>0&&(e.width=Math.min(e.width,+o.extra.mix.column.width*o.pix)),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(e.width=Math.min(e.width,+o.extra.column.width*o.pix)),e.width<=0&&(e.width=1),e.x+=(r+.5-n/2)*(e.width+i),e}))}function B(e,t,n,r,i,o,a){var s=o.extra.column.categoryGap*o.pix||0;return e.map((function(e){return null===e?null:(e.width=Math.ceil(t-2*s),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(e.width=Math.min(e.width,+o.extra.column.width*o.pix)),r>0&&(e.width-=2*a),e)}))}function z(e,t,n,r,i,o,a){var s=o.extra.column.categoryGap*o.pix||0;return e.map((function(e,n){return null===e?null:(e.width=Math.ceil(t-2*s),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(e.width=Math.min(e.width,+o.extra.column.width*o.pix)),e.width<=0&&(e.width=1),e)}))}function W(e,t,n){var r=t.width-t.area[1]-t.area[3],i=t.enableScroll?Math.min(t.xAxis.itemCount,e.length):e.length;("line"==t.type||"area"==t.type||"scatter"==t.type||"bubble"==t.type)&&i>1&&"justify"==t.xAxis.boundaryGap&&(i-=1);var o=r/i,a=[],s=t.area[3],c=t.width-t.area[1];return e.forEach((function(e,t){a.push(s+t*o)})),"justify"!==t.xAxis.boundaryGap&&(!0===t.enableScroll?a.push(s+e.length*o):a.push(c)),{xAxisPoints:a,startX:s,endX:c,eachSpacing:o}}function q(e,t,n,r,i,o,a){var s=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1,c=[],u=o.height-o.area[0]-o.area[2];return e.forEach((function(e,a){if(null===e)c.push(null);else{var l=[];e.forEach((function(e,c){var f={};f.x=r[a]+Math.round(i/2);var d=e.value||e,h=u*(d-t)/(n-t);h*=s,f.y=o.height-Math.round(h)-o.area[2],l.push(f)})),c.push(l)}})),c}function H(e,t,n,i,o,a,s){var c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1,u="center";"line"!=a.type&&"area"!=a.type&&"scatter"!=a.type&&"bubble"!=a.type||(u=a.xAxis.boundaryGap);var l=[],f=a.height-a.area[0]-a.area[2],d=a.width-a.area[1]-a.area[3];return e.forEach((function(e,s){if(null===e)l.push(null);else{var h={};h.color=e.color,h.x=i[s];var p,g,v,y=e;if("object"===r(e)&&null!==e)if(e.constructor.toString().indexOf("Array")>-1)p=[].concat(a.chartData.xAxisData.ranges),g=p.shift(),v=p.pop(),y=e[1],h.x=a.area[3]+d*(e[0]-g)/(v-g),"bubble"==a.type&&(h.r=e[2],h.t=e[3]);else y=e.value;"center"==u&&(h.x+=Math.round(o/2));var m=f*(y-t)/(n-t);m*=c,h.y=a.height-Math.round(m)-a.area[2],l.push(h)}})),l}function V(e,t,n,r,i,o,a,s,c){var u=arguments.length>9&&void 0!==arguments[9]?arguments[9]:1,l=[],f=o.height-o.area[0]-o.area[2];return e.forEach((function(e,a){if(null===e)l.push(null);else{var d={};if(d.color=e.color,d.x=r[a]+Math.round(i/2),s>0){for(var h=0,p=0;p<=s;p++)h+=c[p].data[a];var g=h-e,v=f*(h-t)/(n-t),y=f*(g-t)/(n-t)}else h=e,v=f*(h-t)/(n-t),y=0;var m=y;v*=u,m*=u,d.y=o.height-Math.round(v)-o.area[2],d.y0=o.height-Math.round(m)-o.area[2],l.push(d)}})),l}function K(e,t,n,i,o){var a;a="stack"==i?x(e,t.categories.length):m(e);var s=[];a=a.filter((function(e){return"object"===r(e)&&null!==e?e.constructor.toString().indexOf("Array")>-1?null!==e:null!==e.value:null!==e})),a.map((function(e){"object"===r(e)?e.constructor.toString().indexOf("Array")>-1?"candle"==t.type?e.map((function(e){s.push(e)})):s.push(e[1]):s.push(e.value):s.push(e)}));var c=o.min||0,u=o.max||0;if(s.length>0&&(c=Math.min.apply(this,s),u=Math.max.apply(this,s)),c===u){var l=u||10;u+=l}for(var f=v(c,u),d=void 0===o.min?f.minRange:o.min,h=void 0===o.max?f.maxRange:o.max,p=[],g=(h-d)/t.yAxis.splitNumber,y=0;y<=t.yAxis.splitNumber;y++)p.push(d+g*y);return p.reverse()}function G(e,t,n,r){var i=o({},{type:""},t.extra.column),a=t.yAxis.data.length,s=new Array(a);if(a>0){for(var c=0;c<a;c++){s[c]=[];for(var u=0;u<e.length;u++)e[u].index==c&&s[c].push(e[u])}for(var l=new Array(a),f=new Array(a),d=new Array(a),h=function(e){var o=t.yAxis.data[e];1==t.yAxis.disabled&&(o.disabled=!0),o.formatter||(o.formatter=function(e){return e.toFixed(o.tofix)+(o.unit||"")}),l[e]=K(s[e],t,n,i.type,o,e);var a=o.fontSize*t.pix||n.fontSize;d[e]={position:o.position?o.position:"left",width:0},f[e]=l[e].map((function(t){return t=o.formatter(Number(t)),d[e].width=Math.max(d[e].width,y(t,a,r)+5),t}));var c=o.calibration?4*t.pix:0;d[e].width+=c+3*t.pix,!0===o.disabled&&(d[e].width=0)},p=0;p<a;p++)h(p)}else{l=new Array(1),f=new Array(1),d=new Array(1);t.yAxis.formatter||(t.yAxis.formatter=function(e){return e.toFixed(t.yAxis.tofix)+(t.yAxis.unit||"")}),l[0]=K(e,t,n,i.type,{}),d[0]={position:"left",width:0};var g=t.yAxis.fontSize*t.pix||n.fontSize;f[0]=l[0].map((function(e){return e=t.yAxis.formatter(Number(e)),d[0].width=Math.max(d[0].width,y(e,g,r)+5),e})),d[0].width+=3*t.pix,!0===t.yAxis.disabled?(d[0]={position:"left",width:0},t.yAxis.data[0]={disabled:!0}):t.yAxis.data[0]={disabled:!1,position:"left",max:t.yAxis.max,min:t.yAxis.min,formatter:t.yAxis.formatter}}return{rangesFormat:f,ranges:l,yAxisWidth:d}}function J(e,t){!0!==t.rotateLock?(e.translate(t.height,0),e.rotate(90*Math.PI/180)):!0!==t._rotate_&&(e.translate(t.height,0),e.rotate(90*Math.PI/180),t._rotate_=!0)}function X(e,t,n,r,i){if(r.beginPath(),"hollow"==i.dataPointShapeType?(r.setStrokeStyle(t),r.setFillStyle(i.background),r.setLineWidth(2*i.pix)):(r.setStrokeStyle("#ffffff"),r.setFillStyle(t),r.setLineWidth(1*i.pix)),"diamond"===n)e.forEach((function(e,t){null!==e&&(r.moveTo(e.x,e.y-4.5),r.lineTo(e.x-4.5,e.y),r.lineTo(e.x,e.y+4.5),r.lineTo(e.x+4.5,e.y),r.lineTo(e.x,e.y-4.5))}));else if("circle"===n)e.forEach((function(e,t){null!==e&&(r.moveTo(e.x+2.5*i.pix,e.y),r.arc(e.x,e.y,3*i.pix,0,2*Math.PI,!1))}));else if("square"===n)e.forEach((function(e,t){null!==e&&(r.moveTo(e.x-3.5,e.y-3.5),r.rect(e.x-3.5,e.y-3.5,7,7))}));else if("triangle"===n)e.forEach((function(e,t){null!==e&&(r.moveTo(e.x,e.y-4.5),r.lineTo(e.x-4.5,e.y+4.5),r.lineTo(e.x+4.5,e.y+4.5),r.lineTo(e.x,e.y-4.5))}));else if("triangle"===n)return;r.closePath(),r.fill(),r.stroke()}function Y(e,t,n,r){var i=e.title.fontSize||t.titleFontSize,o=e.subtitle.fontSize||t.subtitleFontSize,a=e.title.name||"",s=e.subtitle.name||"",c=e.title.color||e.fontColor,u=e.subtitle.color||e.fontColor,l=a?i:0,f=s?o:0;if(s){var d=y(s,o*e.pix,n),h=r.x-d/2+(e.subtitle.offsetX||0)*e.pix,p=r.y+o*e.pix/2+(e.subtitle.offsetY||0)*e.pix;a&&(p+=(l*e.pix+5)/2),n.beginPath(),n.setFontSize(o*e.pix),n.setFillStyle(u),n.fillText(s,h,p),n.closePath(),n.stroke()}if(a){var g=y(a,i*e.pix,n),v=r.x-g/2+(e.title.offsetX||0),m=r.y+i*e.pix/2+(e.title.offsetY||0)*e.pix;s&&(m-=(f*e.pix+5)/2),n.beginPath(),n.setFontSize(i*e.pix),n.setFillStyle(c),n.fillText(a,v,m),n.closePath(),n.stroke()}}function Q(e,t,n,i,o){var a=t.data,s=t.textOffset?t.textOffset:0;e.forEach((function(e,c){if(null!==e){i.beginPath();var u=t.textSize?t.textSize*o.pix:n.fontSize;i.setFontSize(u),i.setFillStyle(t.textColor||o.fontColor);var l=a[c];"object"===r(a[c])&&null!==a[c]&&(l=a[c].constructor.toString().indexOf("Array")>-1?a[c][1]:a[c].value);var f=t.formatter?t.formatter(l,c):l;i.setTextAlign("center"),i.fillText(String(f),e.x,e.y-4+s*o.pix),i.closePath(),i.stroke(),i.setTextAlign("left")}}))}function Z(e,t,n,r,i,o){t-=e.width/2+e.labelOffset*r.pix;for(var a=e.startAngle-e.endAngle+1,s=a/e.splitLine.splitNumber,c=e.endNumber-e.startNumber,u=c/e.splitLine.splitNumber,l=e.startAngle,f=e.startNumber,d=0;d<e.splitLine.splitNumber+1;d++){var h={x:t*Math.cos(l*Math.PI),y:t*Math.sin(l*Math.PI)},p=e.formatter?e.formatter(f):f;h.x+=n.x-y(p,i.fontSize,o)/2,h.y+=n.y;var g=h.x,v=h.y;o.beginPath(),o.setFontSize(i.fontSize),o.setFillStyle(e.labelColor||r.fontColor),o.fillText(p,g,v+i.fontSize/2),o.closePath(),o.stroke(),l+=s,l>=2&&(l%=2),f+=u}}function ee(e,t,n,r,i,o){var s=r.extra.radar||{};t+=i.radarLabelTextMargin*r.pix,e.forEach((function(e,c){var u={x:t*Math.cos(e),y:t*Math.sin(e)},l=d(u.x,u.y,n),f=l.x,h=l.y;a.approximatelyEqual(u.x,0)?f-=y(r.categories[c]||"",i.fontSize,o)/2:u.x<0&&(f-=y(r.categories[c]||"",i.fontSize,o)),o.beginPath(),o.setFontSize(i.fontSize),o.setFillStyle(s.labelColor||r.fontColor),o.fillText(r.categories[c]||"",f,h+i.fontSize/2),o.closePath(),o.stroke()}))}function te(e,t,n,r,i,o){for(var s=n.pieChartLinePadding,c=[],u=null,l=e.map((function(e,t,n){var r=e.formatter?e.formatter(e,t,n):a.toFixed(100*e._proportion_.toFixed(4))+"%",i=2*Math.PI-(e._start_+2*Math.PI*e._proportion_/2);e._rose_proportion_&&(i=2*Math.PI-(e._start_+2*Math.PI*e._rose_proportion_/2));var o=e.color,s=e._radius_;return{arc:i,text:r,color:o,radius:s,textColor:e.textColor,textSize:e.textSize}})),f=0;f<l.length;f++){var p=l[f],g=Math.cos(p.arc)*(p.radius+s),v=Math.sin(p.arc)*(p.radius+s),m=Math.cos(p.arc)*p.radius,x=Math.sin(p.arc)*p.radius,_=g>=0?g+n.pieChartTextPadding:g-n.pieChartTextPadding,b=v,w=y(p.text,p.textSize*t.pix||n.fontSize,r),k=b;u&&a.isSameXCoordinateArea(u.start,{x:_})&&(k=_>0?Math.min(b,u.start.y):g<0||b>0?Math.max(b,u.start.y):Math.min(b,u.start.y)),_<0&&(_-=w);var A={lineStart:{x:m,y:x},lineEnd:{x:g,y:v},start:{x:_,y:k},width:w,height:n.fontSize,text:p.text,color:p.color,textColor:p.textColor,textSize:p.textSize};u=h(A,u),c.push(u)}for(var S=0;S<c.length;S++){var P=c[S],T=d(P.lineStart.x,P.lineStart.y,o),O=d(P.lineEnd.x,P.lineEnd.y,o),C=d(P.start.x,P.start.y,o);r.setLineWidth(1*t.pix),r.setFontSize(P.textSize*t.pix||n.fontSize),r.beginPath(),r.setStrokeStyle(P.color),r.setFillStyle(P.color),r.moveTo(T.x,T.y);var L=P.start.x<0?C.x+P.width:C.x,I=P.start.x<0?C.x-5:C.x+5;r.quadraticCurveTo(O.x,O.y,L,C.y),r.moveTo(T.x,T.y),r.stroke(),r.closePath(),r.beginPath(),r.moveTo(C.x+P.width,C.y),r.arc(L,C.y,2,0,2*Math.PI),r.closePath(),r.fill(),r.beginPath(),r.setFontSize(P.textSize*t.pix||n.fontSize),r.setFillStyle(P.textColor||t.fontColor),r.fillText(P.text,I,C.y+3),r.closePath(),r.stroke(),r.closePath()}}function ne(e,t,n){for(var r=o({},{type:"solid",dashLength:4,data:[]},e.extra.markLine),i=e.area[3],a=e.width-e.area[1],s=function(e,t){for(var n,r,i=t.height-t.area[0]-t.area[2],o=0;o<e.length;o++){e[o].yAxisIndex=e[o].yAxisIndex?e[o].yAxisIndex:0;var a=[].concat(t.chartData.yAxisData.ranges[e[o].yAxisIndex]);n=a.pop(),r=a.shift();var s=i*(e[o].value-n)/(r-n);e[o].y=t.height-Math.round(s)-t.area[2]}return e}(r.data,e),u=0;u<s.length;u++){var l=o({},{lineColor:"#DE4A42",showLabel:!1,labelFontColor:"#666666",labelBgColor:"#DFE8FF",labelBgOpacity:.8,yAxisIndex:0},s[u]);if("dash"==r.type&&n.setLineDash([r.dashLength,r.dashLength]),n.setStrokeStyle(l.lineColor),n.setLineWidth(1*e.pix),n.beginPath(),n.moveTo(i,l.y),n.lineTo(a,l.y),n.stroke(),n.setLineDash([]),l.showLabel){var f=e.yAxis.formatter?e.yAxis.formatter(Number(l.value)):l.value;n.setFontSize(t.fontSize);var d=y(f,t.fontSize,n),h=(e.chartData.yAxisData.yAxisWidth[0].width,e.area[3]-d-2*t.toolTipPadding),p=e.area[3],g=p-h,v=p-t.toolTipPadding,m=l.y;n.setFillStyle(c(l.labelBgColor,l.labelBgOpacity)),n.setStrokeStyle(l.labelBgColor),n.setLineWidth(1*e.pix),n.beginPath(),n.rect(h,m-.5*t.fontSize-t.toolTipPadding,g,t.fontSize+2*t.toolTipPadding),n.closePath(),n.stroke(),n.fill(),n.setFontSize(t.fontSize),n.setTextAlign("right"),n.setFillStyle(l.labelFontColor),n.fillText(String(f),v,m+.5*t.fontSize),n.stroke(),n.setTextAlign("left")}}}function re(e,t,n,r,i){var a=o({},{gridType:"solid",dashLength:4},e.extra.tooltip),s=e.area[3],u=e.width-e.area[1];if("dash"==a.gridType&&n.setLineDash([a.dashLength,a.dashLength]),n.setStrokeStyle(a.gridColor||"#cccccc"),n.setLineWidth(1*e.pix),n.beginPath(),n.moveTo(s,e.tooltip.offset.y),n.lineTo(u,e.tooltip.offset.y),n.stroke(),n.setLineDash([]),a.yAxisLabel)for(var l=function(e,t,n,r,i){for(var o=[].concat(n.chartData.yAxisData.ranges),a=n.height-n.area[0]-n.area[2],s=n.area[0],c=[],u=0;u<o.length;u++){var l=o[u].shift(),f=o[u].pop(),d=l-(l-f)*(e-s)/a;d=n.yAxis.data[u].formatter?n.yAxis.data[u].formatter(Number(d)):d.toFixed(0),c.push(String(d))}return c}(e.tooltip.offset.y,e.series,e),f=e.chartData.yAxisData.yAxisWidth,d=e.area[3],h=e.width-e.area[1],p=0;p<l.length;p++){n.setFontSize(t.fontSize);var g,v=y(l[p],t.fontSize,n),m=void 0,x=void 0;"left"==f[p].position?(m=d-f[p].width,x=Math.max(m,m+v+2*t.toolTipPadding)):(m=h,x=Math.max(m+f[p].width,m+v+2*t.toolTipPadding)),g=x-m;var _=m+(g-v)/2,b=e.tooltip.offset.y;n.beginPath(),n.setFillStyle(c(a.labelBgColor||t.toolTipBackground,a.labelBgOpacity||t.toolTipOpacity)),n.setStrokeStyle(a.labelBgColor||t.toolTipBackground),n.setLineWidth(1*e.pix),n.rect(m,b-.5*t.fontSize-t.toolTipPadding,g,t.fontSize+2*t.toolTipPadding),n.closePath(),n.stroke(),n.fill(),n.beginPath(),n.setFontSize(t.fontSize),n.setFillStyle(a.labelFontColor||e.fontColor),n.fillText(l[p],_,b+.5*t.fontSize),n.closePath(),n.stroke(),"left"==f[p].position?d-=f[p].width+e.yAxis.padding*e.pix:h+=f[p].width+e.yAxis.padding*e.pix}}function ie(e,t,n,r,i){var a=o({},{activeBgColor:"#000000",activeBgOpacity:.08},t.extra.column),s=t.area[0],u=t.height-t.area[2];r.beginPath(),r.setFillStyle(c(a.activeBgColor,a.activeBgOpacity)),r.rect(e-i/2,s,i,u-s),r.closePath(),r.fill(),r.setFillStyle("#FFFFFF")}function oe(e,t,n,r,i,a,s){var u=o({},{showBox:!0,showArrow:!0,showCategory:!1,bgColor:"#000000",bgOpacity:.7,borderColor:"#000000",borderWidth:0,borderRadius:0,borderOpacity:.7,fontColor:"#FFFFFF",splitLine:!0},n.extra.tooltip);1==u.showCategory&&n.categories&&e.unshift({text:n.categories[n.tooltip.index],color:null});var l=4*n.pix,f=5*n.pix,d=u.showArrow?8*n.pix:0,h=!1;"line"!=n.type&&"area"!=n.type&&"candle"!=n.type&&"mix"!=n.type||1==u.splitLine&&function(e,t,n,r){var i=t.extra.tooltip||{};i.gridType=void 0==i.gridType?"solid":i.gridType,i.dashLength=void 0==i.dashLength?4:i.dashLength;var o=t.area[0],a=t.height-t.area[2];if("dash"==i.gridType&&r.setLineDash([i.dashLength,i.dashLength]),r.setStrokeStyle(i.gridColor||"#cccccc"),r.setLineWidth(1*t.pix),r.beginPath(),r.moveTo(e,o),r.lineTo(e,a),r.stroke(),r.setLineDash([]),i.xAxisLabel){var s=t.categories[t.tooltip.index];r.setFontSize(n.fontSize);var u=y(s,n.fontSize,r),l=e-.5*u,f=a;r.beginPath(),r.setFillStyle(c(i.labelBgColor||n.toolTipBackground,i.labelBgOpacity||n.toolTipOpacity)),r.setStrokeStyle(i.labelBgColor||n.toolTipBackground),r.setLineWidth(1*t.pix),r.rect(l-n.toolTipPadding,f,u+2*n.toolTipPadding,n.fontSize+2*n.toolTipPadding),r.closePath(),r.stroke(),r.fill(),r.beginPath(),r.setFontSize(n.fontSize),r.setFillStyle(i.labelFontColor||t.fontColor),r.fillText(String(s),l,f+n.toolTipPadding+n.fontSize),r.closePath(),r.stroke()}}(n.tooltip.offset.x,n,r,i),t=o({x:0,y:0},t),t.y-=8*n.pix;var p=e.map((function(e){return y(e.text,r.fontSize,i)})),g=l+f+4*r.toolTipPadding+Math.max.apply(null,p),v=2*r.toolTipPadding+e.length*r.toolTipLineHeight;if(0!=u.showBox){t.x-Math.abs(n._scrollDistance_||0)+d+g>n.width&&(h=!0),v+t.y>n.height&&(t.y=n.height-v),i.beginPath(),i.setFillStyle(c(u.bgColor||r.toolTipBackground,u.bgOpacity||r.toolTipOpacity)),i.setLineWidth(u.borderWidth*n.pix),i.setStrokeStyle(c(u.borderColor,u.borderOpacity));var m=u.borderRadius;h?(u.showArrow&&(i.moveTo(t.x,t.y+10*n.pix),i.lineTo(t.x-d,t.y+10*n.pix+5*n.pix)),i.arc(t.x-d-m,t.y+v-m,m,0,Math.PI/2,!1),i.arc(t.x-d-Math.round(g)+m,t.y+v-m,m,Math.PI/2,Math.PI,!1),i.arc(t.x-d-Math.round(g)+m,t.y+m,m,-Math.PI,-Math.PI/2,!1),i.arc(t.x-d-m,t.y+m,m,-Math.PI/2,0,!1),u.showArrow&&(i.lineTo(t.x-d,t.y+10*n.pix-5*n.pix),i.lineTo(t.x,t.y+10*n.pix))):(u.showArrow&&(i.moveTo(t.x,t.y+10*n.pix),i.lineTo(t.x+d,t.y+10*n.pix-5*n.pix)),i.arc(t.x+d+m,t.y+m,m,-Math.PI,-Math.PI/2,!1),i.arc(t.x+d+Math.round(g)-m,t.y+m,m,-Math.PI/2,0,!1),i.arc(t.x+d+Math.round(g)-m,t.y+v-m,m,0,Math.PI/2,!1),i.arc(t.x+d+m,t.y+v-m,m,Math.PI/2,Math.PI,!1),u.showArrow&&(i.lineTo(t.x+d,t.y+10*n.pix+5*n.pix),i.lineTo(t.x,t.y+10*n.pix))),i.closePath(),i.fill(),u.borderWidth>0&&i.stroke(),e.forEach((function(e,n){if(null!==e.color){i.beginPath(),i.setFillStyle(e.color);var o=t.x+d+2*r.toolTipPadding,a=t.y+(r.toolTipLineHeight-r.fontSize)/2+r.toolTipLineHeight*n+r.toolTipPadding+1;h&&(o=t.x-g-d+2*r.toolTipPadding),i.fillRect(o,a,l,r.fontSize),i.closePath()}})),e.forEach((function(e,n){var o=t.x+d+2*r.toolTipPadding+l+f;h&&(o=t.x-g-d+2*r.toolTipPadding+ +l+f);var a=t.y+(r.toolTipLineHeight-r.fontSize)/2+r.toolTipLineHeight*n+r.toolTipPadding;i.beginPath(),i.setFontSize(r.fontSize),i.setFillStyle(u.fontColor),i.fillText(e.text,o,a+r.fontSize),i.closePath(),i.stroke()}))}}function ae(e,t,n,r,i,o){var a=e.extra.tooltip||{};a.horizentalLine&&e.tooltip&&1===r&&("line"==e.type||"area"==e.type||"column"==e.type||"candle"==e.type||"mix"==e.type)&&re(e,t,n),n.save(),e._scrollDistance_&&0!==e._scrollDistance_&&!0===e.enableScroll&&n.translate(e._scrollDistance_,0),e.tooltip&&e.tooltip.textList&&e.tooltip.textList.length&&1===r&&oe(e.tooltip.textList,e.tooltip.offset,e,t,n),n.restore()}function se(e,t,n,r){var i=t.chartData.xAxisData,o=i.xAxisPoints,a=i.startX,s=i.endX,c=i.eachSpacing,u="center";"line"!=t.type&&"area"!=t.type&&"scatter"!=t.type&&"bubble"!=t.type||(u=t.xAxis.boundaryGap);var l=t.height-t.area[2],f=t.area[0];if(t.enableScroll&&t.xAxis.scrollShow){var d=t.height-t.area[2]+n.xAxisHeight,h=s-a,p=c*(o.length-1),g=h*h/p,v=0;t._scrollDistance_&&(v=-t._scrollDistance_*h/p),r.beginPath(),r.setLineCap("round"),r.setLineWidth(6*t.pix),r.setStrokeStyle(t.xAxis.scrollBackgroundColor||"#EFEBEF"),r.moveTo(a,d),r.lineTo(s,d),r.stroke(),r.closePath(),r.beginPath(),r.setLineCap("round"),r.setLineWidth(6*t.pix),r.setStrokeStyle(t.xAxis.scrollColor||"#A6A6A6"),r.moveTo(a+v,d),r.lineTo(a+v+g,d),r.stroke(),r.closePath(),r.setLineCap("butt")}if(r.save(),t._scrollDistance_&&0!==t._scrollDistance_&&r.translate(t._scrollDistance_,0),!0===t.xAxis.calibration&&(r.setStrokeStyle(t.xAxis.gridColor||"#cccccc"),r.setLineCap("butt"),r.setLineWidth(1*t.pix),o.forEach((function(e,n){n>0&&(r.beginPath(),r.moveTo(e-c/2,l),r.lineTo(e-c/2,l+3*t.pix),r.closePath(),r.stroke())}))),!0!==t.xAxis.disableGrid&&(r.setStrokeStyle(t.xAxis.gridColor||"#cccccc"),r.setLineCap("butt"),r.setLineWidth(1*t.pix),"dash"==t.xAxis.gridType&&r.setLineDash([t.xAxis.dashLength*t.pix,t.xAxis.dashLength*t.pix]),t.xAxis.gridEval=t.xAxis.gridEval||1,o.forEach((function(e,n){n%t.xAxis.gridEval==0&&(r.beginPath(),r.moveTo(e,l),r.lineTo(e,f),r.stroke())})),r.setLineDash([])),!0!==t.xAxis.disabled){var m=e.length;t.xAxis.labelCount&&(m=t.xAxis.itemCount?Math.ceil(e.length/t.xAxis.itemCount*t.xAxis.labelCount):t.xAxis.labelCount,m-=1);for(var x=Math.ceil(e.length/m),_=[],b=e.length,w=0;w<b;w++)w%x!==0?_.push(""):_.push(e[w]);_[b-1]=e[b-1];var k=t.xAxis.fontSize*t.pix||n.fontSize;0===n._xAxisTextAngle_?_.forEach((function(e,i){var a=t.xAxis.formatter?t.xAxis.formatter(e):e,s=-y(String(a),k,r)/2;"center"==u&&(s+=c/2);var f=0;t.xAxis.scrollShow&&(f=6*t.pix),r.beginPath(),r.setFontSize(k),r.setFillStyle(t.xAxis.fontColor||t.fontColor),r.fillText(String(a),o[i]+s,l+k+(n.xAxisHeight-f-k)/2),r.closePath(),r.stroke()})):_.forEach((function(e,i){var a=t.xAxis.formatter?t.xAxis.formatter(Number(e)):e;r.save(),r.beginPath(),r.setFontSize(k),r.setFillStyle(t.xAxis.fontColor||t.fontColor);var s=y(String(a),k,r),f=-s;"center"==u&&(f+=c/2);var d=function(e,t,n){var r=e,i=n-t,o=r+(n-i-r)/Math.sqrt(2);o*=-1;var a=(n-i)*(Math.sqrt(2)-1)-(n-i-r)/Math.sqrt(2);return{transX:o,transY:a}}(o[i]+c/2,l+k/2+5,t.height),h=d.transX,p=d.transY;r.rotate(-1*n._xAxisTextAngle_),r.translate(h,p),r.fillText(String(a),o[i]+f,l+k+5),r.closePath(),r.stroke(),r.restore()}))}r.restore(),t.xAxis.axisLine&&(r.beginPath(),r.setStrokeStyle(t.xAxis.axisLineColor),r.setLineWidth(1*t.pix),r.moveTo(a,t.height-t.area[2]),r.lineTo(s,t.height-t.area[2]),r.stroke())}function ce(e,t,n,r){if(!0!==t.yAxis.disableGrid){var i=t.height-t.area[0]-t.area[2],o=i/t.yAxis.splitNumber,a=t.area[3],s=t.chartData.xAxisData.xAxisPoints,c=t.chartData.xAxisData.eachSpacing,u=c*(s.length-1),l=a+u,f=[],d=1;!1===t.xAxis.axisLine&&(d=0);for(var h=d;h<t.yAxis.splitNumber+1;h++)f.push(t.height-t.area[2]-o*h);r.save(),t._scrollDistance_&&0!==t._scrollDistance_&&r.translate(t._scrollDistance_,0),"dash"==t.yAxis.gridType&&r.setLineDash([t.yAxis.dashLength*t.pix,t.yAxis.dashLength*t.pix]),r.setStrokeStyle(t.yAxis.gridColor),r.setLineWidth(1*t.pix),f.forEach((function(e,t){r.beginPath(),r.moveTo(a,e),r.lineTo(l,e),r.stroke()})),r.setLineDash([]),r.restore()}}function ue(e,t,n,r){if(!0!==t.yAxis.disabled){var i=t.height-t.area[0]-t.area[2],o=i/t.yAxis.splitNumber,a=t.area[3],s=t.width-t.area[1],c=t.height-t.area[2],u=c+n.xAxisHeight;t.xAxis.scrollShow&&(u-=3*t.pix),t.xAxis.rotateLabel&&(u=t.height-t.area[2]+t.fontSize*t.pix/2),r.beginPath(),r.setFillStyle(t.background),1==t.enableScroll&&t.xAxis.scrollPosition&&"left"!==t.xAxis.scrollPosition&&r.fillRect(0,0,a,u),1==t.enableScroll&&t.xAxis.scrollPosition&&"right"!==t.xAxis.scrollPosition&&r.fillRect(s,0,t.width,u),r.closePath(),r.stroke();for(var l=[],f=0;f<=t.yAxis.splitNumber;f++)l.push(t.area[0]+o*f);var d=t.area[3],h=t.width-t.area[1];if(t.yAxis.data)for(var p=function(e){var i=t.yAxis.data[e];if(!0!==i.disabled){var o=t.chartData.yAxisData.rangesFormat[e],a=i.fontSize?i.fontSize*t.pix:n.fontSize,s=t.chartData.yAxisData.yAxisWidth[e],u=i.textAlign||"right";if(o.forEach((function(e,n){var o=l[n]?l[n]:c;r.beginPath(),r.setFontSize(a),r.setLineWidth(1*t.pix),r.setStrokeStyle(i.axisLineColor||"#cccccc"),r.setFillStyle(i.fontColor||t.fontColor);var f=0,p=4*t.pix;if("left"==s.position){switch(1==i.calibration&&(r.moveTo(d,o),r.lineTo(d-3*t.pix,o),p+=3*t.pix),u){case"left":r.setTextAlign("left"),f=d-s.width;break;case"right":r.setTextAlign("right"),f=d-p;break;default:r.setTextAlign("center"),f=d-s.width/2}r.fillText(String(e),f,o+a/2-3*t.pix)}else{switch(1==i.calibration&&(r.moveTo(h,o),r.lineTo(h+3*t.pix,o),p+=3*t.pix),u){case"left":r.setTextAlign("left"),f=h+p;break;case"right":r.setTextAlign("right"),f=h+s.width;break;default:r.setTextAlign("center"),f=h+s.width/2}r.fillText(String(e),f,o+a/2-3*t.pix)}r.closePath(),r.stroke(),r.setTextAlign("left")})),!1!==i.axisLine&&(r.beginPath(),r.setStrokeStyle(i.axisLineColor||"#cccccc"),r.setLineWidth(1*t.pix),"left"==s.position?(r.moveTo(d,t.height-t.area[2]),r.lineTo(d,t.area[0])):(r.moveTo(h,t.height-t.area[2]),r.lineTo(h,t.area[0])),r.stroke()),t.yAxis.showTitle){var f=i.titleFontSize*t.pix||n.fontSize,p=i.title;r.beginPath(),r.setFontSize(f),r.setFillStyle(i.titleFontColor||t.fontColor),"left"==s.position?r.fillText(p,d-y(p,f,r)/2+(i.titleOffsetX||0),t.area[0]-(10-(i.titleOffsetY||0))*t.pix):r.fillText(p,h-y(p,f,r)/2+(i.titleOffsetX||0),t.area[0]-(10-(i.titleOffsetY||0))*t.pix),r.closePath(),r.stroke()}"left"==s.position?d-=s.width+t.yAxis.padding*t.pix:h+=s.width+t.yAxis.padding*t.pix}},g=0;g<t.yAxis.data.length;g++)p(g)}}function le(e,t,n,r,i){if(!1!==t.legend.show){var o=i.legendData,a=o.points,s=o.area,c=t.legend.padding*t.pix,u=t.legend.fontSize*t.pix,l=15*t.pix,f=5*t.pix,d=t.legend.itemGap*t.pix,h=Math.max(t.legend.lineHeight*t.pix,u);r.beginPath(),r.setLineWidth(t.legend.borderWidth*t.pix),r.setStrokeStyle(t.legend.borderColor),r.setFillStyle(t.legend.backgroundColor),r.moveTo(s.start.x,s.start.y),r.rect(s.start.x,s.start.y,s.width,s.height),r.closePath(),r.fill(),r.stroke(),a.forEach((function(e,i){var a,p=0;p=o.widthArr[i],a=o.heightArr[i];var g=0,v=0;if("top"==t.legend.position||"bottom"==t.legend.position){switch(t.legend.float){case"left":g=s.start.x+c;break;case"right":g=s.start.x+s.width-p;break;default:g=s.start.x+(s.width-p)/2}v=s.start.y+c+i*h}else p=0==i?0:o.widthArr[i-1],g=s.start.x+c+p,v=s.start.y+c+(s.height-a)/2;r.setFontSize(n.fontSize);for(var m=0;m<e.length;m++){var x=e[m];switch(x.area=[0,0,0,0],x.area[0]=g,x.area[1]=v,x.area[3]=v+h,r.beginPath(),r.setLineWidth(1*t.pix),r.setStrokeStyle(x.show?x.color:t.legend.hiddenColor),r.setFillStyle(x.show?x.color:t.legend.hiddenColor),x.legendShape){case"line":r.moveTo(g,v+.5*h-2*t.pix),r.fillRect(g,v+.5*h-2*t.pix,15*t.pix,4*t.pix);break;case"triangle":r.moveTo(g+7.5*t.pix,v+.5*h-5*t.pix),r.lineTo(g+2.5*t.pix,v+.5*h+5*t.pix),r.lineTo(g+12.5*t.pix,v+.5*h+5*t.pix),r.lineTo(g+7.5*t.pix,v+.5*h-5*t.pix);break;case"diamond":r.moveTo(g+7.5*t.pix,v+.5*h-5*t.pix),r.lineTo(g+2.5*t.pix,v+.5*h),r.lineTo(g+7.5*t.pix,v+.5*h+5*t.pix),r.lineTo(g+12.5*t.pix,v+.5*h),r.lineTo(g+7.5*t.pix,v+.5*h-5*t.pix);break;case"circle":r.moveTo(g+7.5*t.pix,v+.5*h),r.arc(g+7.5*t.pix,v+.5*h,5*t.pix,0,2*Math.PI);break;case"rect":r.moveTo(g,v+.5*h-5*t.pix),r.fillRect(g,v+.5*h-5*t.pix,15*t.pix,10*t.pix);break;case"square":r.moveTo(g+5*t.pix,v+.5*h-5*t.pix),r.fillRect(g+5*t.pix,v+.5*h-5*t.pix,10*t.pix,10*t.pix);break;case"none":break;default:r.moveTo(g,v+.5*h-5*t.pix),r.fillRect(g,v+.5*h-5*t.pix,15*t.pix,10*t.pix)}r.closePath(),r.fill(),r.stroke(),g+=l+f;var _=.5*h+.5*u-2;r.beginPath(),r.setFontSize(u),r.setFillStyle(x.show?t.legend.fontColor:t.legend.hiddenColor),r.fillText(x.name,g,v+_),r.closePath(),r.stroke(),"top"==t.legend.position||"bottom"==t.legend.position?(g+=y(x.name,u,r)+d,x.area[2]=g):(x.area[2]=g+y(x.name,u,r)+d,g-=l+f,v+=h)}}))}}function fe(e,t,n){n=0==n?1:n;for(var r=[],i=0;i<n;i++)r[i]=Math.random();return Math.floor(r.reduce((function(e,t){return e+t}))/n*(t-e))+e}function de(e,t,n,r){for(var i=!1,o=0;o<t.length;o++)if(t[o].area){if(!(e[3]<t[o].area[1]||e[0]>t[o].area[2]||e[1]>t[o].area[3]||e[2]<t[o].area[0])){i=!0;break}if(e[0]<0||e[1]<0||e[2]>n||e[3]>r){i=!0;break}i=!1}return i}function he(e,t,n,r,i,o){return{x:(t-n.xMin)*r+i,y:(n.yMax-e)*r+o}}function pe(e,t,n){if(t[1]==n[1])return!1;if(t[1]>e[1]&&n[1]>e[1])return!1;if(t[1]<e[1]&&n[1]<e[1])return!1;if(t[1]==e[1]&&n[1]>e[1])return!1;if(n[1]==e[1]&&t[1]>e[1])return!1;if(t[0]<e[0]&&n[1]<e[1])return!1;var r=n[0]-(n[0]-t[0])*(n[1]-e[1])/(n[1]-t[1]);return!(r<e[0])}function ge(e,t,n){for(var r=0,i=0;i<t.length;i++){var o=t[i][0];1==t.length&&(o=t[i][0]);for(var a=0;a<o.length-1;a++){var c=o[a],u=o[a+1];n&&(c=s(o[a][0],o[a][1]),u=s(o[a+1][0],o[a+1][1])),pe(e,c,u)&&(r+=1)}}return r%2==1}function ve(e,t,n){var r=e.series;switch(t){case"normal":for(var i=0;i<r.length;i++){var o=r[i].name,a=r[i].textSize*e.pix,s=y(o,a,n),c=void 0,u=void 0,l=void 0,f=0;while(1){f++,c=fe(-e.width/2,e.width/2,5)-s/2,u=fe(-e.height/2,e.height/2,5)+a/2,l=[c-5+e.width/2,u-5-a+e.height/2,c+s+5+e.width/2,u+5+e.height/2];var d=de(l,r,e.width,e.height);if(!d)break;if(1e3==f){l=[-100,-100,-100,-100];break}}r[i].area=l}break;case"vertical":for(var h=function(){return Math.random()>.7},p=0;p<r.length;p++){var g=r[p].name,v=r[p].textSize*e.pix,m=y(g,v,n),x=h(),_=void 0,b=void 0,w=void 0,k=void 0,A=0;while(1){A++;var S=void 0;if(x?(_=fe(-e.width/2,e.width/2,5)-m/2,b=fe(-e.height/2,e.height/2,5)+v/2,w=[b-5-m+e.width/2,-_-5+e.height/2,b+5+e.width/2,-_+v+5+e.height/2],k=[e.width-(e.width/2-e.height/2)-(-_+v+5+e.height/2)-5,e.height/2-e.width/2+(b-5-m+e.width/2)-5,e.width-(e.width/2-e.height/2)-(-_+v+5+e.height/2)+v,e.height/2-e.width/2+(b-5-m+e.width/2)+m+5],S=de(k,r,e.height,e.width)):(_=fe(-e.width/2,e.width/2,5)-m/2,b=fe(-e.height/2,e.height/2,5)+v/2,w=[_-5+e.width/2,b-5-v+e.height/2,_+m+5+e.width/2,b+5+e.height/2],S=de(w,r,e.width,e.height)),!S)break;if(1e3==A){w=[-1e3,-1e3,-1e3,-1e3];break}}x?(r[p].area=k,r[p].areav=w):r[p].area=w,r[p].rotate=x}break}return r}function ye(e,t,n,r,i,o,s){for(var c=0;c<e.length;c++){var u=e[c],l=void 0,f=void 0,d=void 0,h=void 0,p=u.formatter?u.formatter(u,c,e):a.toFixed(100*u._proportion_)+"%";"right"==i?(l="pyramid"===t.extra.funnel.type?c==e.length-1?(u.funnelArea[2]+s.x)/2:(u.funnelArea[2]+e[c+1].funnelArea[2])/2:0==c?(u.funnelArea[2]+s.x)/2:(u.funnelArea[2]+e[c-1].funnelArea[2])/2,f=l+2*o,d=u.funnelArea[1]+r/2,h=u.textSize*t.pix||t.fontSize*t.pix,n.setLineWidth(1*t.pix),n.setStrokeStyle(u.color),n.setFillStyle(u.color),n.beginPath(),n.moveTo(l,d),n.lineTo(f,d),n.stroke(),n.closePath(),n.beginPath(),n.moveTo(f,d),n.arc(f,d,2,0,2*Math.PI),n.closePath(),n.fill(),n.beginPath(),n.setFontSize(h),n.setFillStyle(u.textColor||t.fontColor),n.fillText(p,f+5,d+h/2-2),n.closePath(),n.stroke(),n.closePath()):(l="pyramid"===t.extra.funnel.type?c==e.length-1?(u.funnelArea[0]+s.x)/2:(u.funnelArea[0]+e[c+1].funnelArea[0])/2:0==c?(u.funnelArea[0]+s.x)/2:(u.funnelArea[0]+e[c-1].funnelArea[0])/2,f=l-2*o,d=u.funnelArea[1]+r/2,h=u.textSize*t.pix||t.fontSize*t.pix,n.setLineWidth(1*t.pix),n.setStrokeStyle(u.color),n.setFillStyle(u.color),n.beginPath(),n.moveTo(l,d),n.lineTo(f,d),n.stroke(),n.closePath(),n.beginPath(),n.moveTo(f,d),n.arc(f,d,2,0,2*Math.PI),n.closePath(),n.fill(),n.beginPath(),n.setFontSize(h),n.setFillStyle(u.textColor||t.fontColor),n.fillText(p,f-5-y(p,h,n),d+h/2-2),n.closePath(),n.stroke(),n.closePath())}}function me(e,t){t.draw()}var xe={easeIn:function(e){return Math.pow(e,3)},easeOut:function(e){return Math.pow(e-1,3)+1},easeInOut:function(e){return(e/=.5)<1?.5*Math.pow(e,3):.5*(Math.pow(e-2,3)+2)},linear:function(e){return e}};function _e(e){this.isStop=!1,e.duration="undefined"===typeof e.duration?1e3:e.duration,e.timing=e.timing||"easeInOut";var t=function(){return"undefined"!==typeof setTimeout?function(e,t){setTimeout((function(){var t=+new Date;e(t)}),t)}:"undefined"!==typeof requestAnimationFrame?requestAnimationFrame:function(e){e(null)}}(),n=null,r=function(i){if(null===i||!0===this.isStop)return e.onProcess&&e.onProcess(1),void(e.onAnimationFinish&&e.onAnimationFinish());if(null===n&&(n=i),i-n<e.duration){var o=(i-n)/e.duration,a=xe[e.timing];o=a(o),e.onProcess&&e.onProcess(o),t(r,17)}else e.onProcess&&e.onProcess(1),e.onAnimationFinish&&e.onAnimationFinish()};r=r.bind(this),t(r,17)}function be(e,n,r,i){var u=this,l=n.series;"pie"!==e&&"ring"!==e&&"rose"!==e&&"funnel"!==e||(l=function(e,t,n){var r=[];if(e.length>0&&e[0].data.constructor.toString().indexOf("Array")>-1){t._pieSeries_=e;for(var i=e[0].data,o=0;o<i.length;o++)i[o].formatter=e[0].formatter,i[o].data=i[o].value,r.push(i[o]);t.series=r}else r=e;return r}(l,n));var h=n.categories;l=p(l,n,r);var v=n.animation?n.duration:0;u.animationInstance&&u.animationInstance.stop();var m=null;if("candle"==e){var x=o({},n.extra.candle.average);x.show?(m=function(e,t,n,r){for(var i=[],o=0;o<e.length;o++){for(var a={data:[],name:t[o],color:n[o]},s=0,c=r.length;s<c;s++)if(s<e[o])a.data.push(null);else{for(var u=0,l=0;l<e[o];l++)u+=r[s-l][1];a.data.push(+(u/e[o]).toFixed(3))}i.push(a)}return i}(x.day,x.name,x.color,l[0].data),m=p(m,n,r),n.seriesMA=m):m=n.seriesMA?n.seriesMA=p(n.seriesMA,n,r):l}else m=l;n._series_=l=T(l),n.area=new Array(4);for(var _=0;_<4;_++)n.area[_]=n.padding[_]*n.pix;var b=function(e,t,n,r,i){var o={area:{start:{x:0,y:0},end:{x:0,y:0},width:0,height:0,wholeWidth:0,wholeHeight:0},points:[],widthArr:[],heightArr:[]};if(!1===t.legend.show)return r.legendData=o,o;var a=t.legend.padding*t.pix,s=t.legend.margin*t.pix,c=t.legend.fontSize?t.legend.fontSize*t.pix:n.fontSize,u=15*t.pix,l=5*t.pix,f=Math.max(t.legend.lineHeight*t.pix,c);if("top"==t.legend.position||"bottom"==t.legend.position){for(var d=[],h=0,p=[],g=[],v=0;v<e.length;v++){var m=e[v],x=u+l+y(m.name||"undefined",c,i)+t.legend.itemGap*t.pix;h+x>t.width-t.area[1]-t.area[3]?(d.push(g),p.push(h-t.legend.itemGap*t.pix),h=x,g=[m]):(h+=x,g.push(m))}if(g.length){d.push(g),p.push(h-t.legend.itemGap*t.pix),o.widthArr=p;var _=Math.max.apply(null,p);switch(t.legend.float){case"left":o.area.start.x=t.area[3],o.area.end.x=t.area[3]+_+2*a;break;case"right":o.area.start.x=t.width-t.area[1]-_-2*a,o.area.end.x=t.width-t.area[1];break;default:o.area.start.x=(t.width-_)/2-a,o.area.end.x=(t.width+_)/2+a}o.area.width=_+2*a,o.area.wholeWidth=_+2*a,o.area.height=d.length*f+2*a,o.area.wholeHeight=d.length*f+2*a+2*s,o.points=d}}else{var b=e.length,w=t.height-t.area[0]-t.area[2]-2*s-2*a,k=Math.min(Math.floor(w/f),b);switch(o.area.height=k*f+2*a,o.area.wholeHeight=k*f+2*a,t.legend.float){case"top":o.area.start.y=t.area[0]+s,o.area.end.y=t.area[0]+s+o.area.height;break;case"bottom":o.area.start.y=t.height-t.area[2]-s-o.area.height,o.area.end.y=t.height-t.area[2]-s;break;default:o.area.start.y=(t.height-o.area.height)/2,o.area.end.y=(t.height+o.area.height)/2}for(var A=b%k===0?b/k:Math.floor(b/k+1),S=[],P=0;P<A;P++){var T=e.slice(P*k,P*k+k);S.push(T)}if(o.points=S,S.length){for(var O=0;O<S.length;O++){for(var C=S[O],L=0,I=0;I<C.length;I++){var E=u+l+y(C[I].name||"undefined",c,i)+t.legend.itemGap*t.pix;E>L&&(L=E)}o.widthArr.push(L),o.heightArr.push(C.length*f+2*a)}for(var D=0,M=0;M<o.widthArr.length;M++)D+=o.widthArr[M];o.area.width=D-t.legend.itemGap*t.pix+2*a,o.area.wholeWidth=o.area.width+a}}switch(t.legend.position){case"top":o.area.start.y=t.area[0]+s,o.area.end.y=t.area[0]+s+o.area.height;break;case"bottom":o.area.start.y=t.height-t.area[2]-o.area.height-s,o.area.end.y=t.height-t.area[2]-s;break;case"left":o.area.start.x=t.area[3],o.area.end.x=t.area[3]+o.area.width;break;case"right":o.area.start.x=t.width-t.area[1]-o.area.width,o.area.end.x=t.width-t.area[1];break}return r.legendData=o,o}(m,n,r,n.chartData,i),A=b.area.wholeHeight,S=b.area.wholeWidth;switch(n.legend.position){case"top":n.area[0]+=A;break;case"bottom":n.area[2]+=A;break;case"left":n.area[3]+=S;break;case"right":n.area[1]+=S;break}var P={},O=0;if("line"===n.type||"column"===n.type||"area"===n.type||"mix"===n.type||"candle"===n.type||"scatter"===n.type||"bubble"===n.type){if(P=G(l,n,r,i),O=P.yAxisWidth,n.yAxis.showTitle){for(var C=0,K=0;K<n.yAxis.data.length;K++)C=Math.max(C,n.yAxis.data[K].titleFontSize?n.yAxis.data[K].titleFontSize*n.pix:r.fontSize);n.area[0]+=C}for(var re=0,oe=0,fe=0;fe<O.length;fe++)"left"==O[fe].position?(n.area[3]+=oe>0?O[fe].width+n.yAxis.padding*n.pix:O[fe].width,oe+=1):(n.area[1]+=re>0?O[fe].width+n.yAxis.padding*n.pix:O[fe].width,re+=1)}else r.yAxisWidth=O;if(n.chartData.yAxisData=P,n.categories&&n.categories.length&&"radar"!==n.type&&"gauge"!==n.type){n.chartData.xAxisData=W(n.categories,n);var de=I(n.categories,n,r,n.chartData.xAxisData.eachSpacing,i),pe=de.xAxisHeight,ge=de.angle;r.xAxisHeight=pe,r._xAxisTextAngle_=ge,n.area[2]+=pe,n.chartData.categoriesData=de}else if("line"===n.type||"area"===n.type||"scatter"===n.type||"bubble"===n.type){n.chartData.xAxisData=E(l,n,r,i),h=n.chartData.xAxisData.rangesFormat;var xe=I(h,n,r,n.chartData.xAxisData.eachSpacing,i),be=xe.xAxisHeight,we=xe.angle;r.xAxisHeight=be,r._xAxisTextAngle_=we,n.area[2]+=be,n.chartData.categoriesData=xe}else n.chartData.xAxisData={xAxisPoints:[]};if(n.enableScroll&&"right"==n.xAxis.scrollAlign&&void 0===n._scrollDistance_){var ke,Ae=n.chartData.xAxisData.xAxisPoints,Se=n.chartData.xAxisData.startX,Pe=n.chartData.xAxisData.endX,Te=n.chartData.xAxisData.eachSpacing,Oe=Te*(Ae.length-1),Ce=Pe-Se;ke=Ce-Oe,u.scrollOption={currentOffset:ke,startTouchX:ke,distance:0,lastMoveTime:0},n._scrollDistance_=ke}switch("pie"!==e&&"ring"!==e&&"rose"!==e||(r._pieTextMaxLength_=!1===n.dataLabel?0:function(e,t,n,r){e=M(e);for(var i=0,o=0;o<e.length;o++){var s=e[o],c=s.formatter?s.formatter(+s._proportion_.toFixed(2)):a.toFixed(100*s._proportion_)+"%";i=Math.max(i,y(c,s.textSize*r.pix||t.fontSize,n))}return i}(m,r,i,n)),e){case"word":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{type:"normal",autoColors:!0},t.extra.word);t.chartData.wordCloudData||(t.chartData.wordCloudData=ve(t,a.type,r)),r.beginPath(),r.setFillStyle(t.background),r.rect(0,0,t.width,t.height),r.fill(),r.save();var s=t.chartData.wordCloudData;r.translate(t.width/2,t.height/2);for(var c=0;c<s.length;c++){r.save(),s[c].rotate&&r.rotate(90*Math.PI/180);var u=s[c].name,l=s[c].textSize*t.pix,f=y(u,l,r);r.beginPath(),r.setStrokeStyle(s[c].color),r.setFillStyle(s[c].color),r.setFontSize(l),s[c].rotate?s[c].areav[0]>0&&(t.tooltip&&t.tooltip.index==c?r.strokeText(u,(s[c].areav[0]+5-t.width/2)*i-f*(1-i)/2,(s[c].areav[1]+5+l-t.height/2)*i):r.fillText(u,(s[c].areav[0]+5-t.width/2)*i-f*(1-i)/2,(s[c].areav[1]+5+l-t.height/2)*i)):s[c].area[0]>0&&(t.tooltip&&t.tooltip.index==c?r.strokeText(u,(s[c].area[0]+5-t.width/2)*i-f*(1-i)/2,(s[c].area[1]+5+l-t.height/2)*i):r.fillText(u,(s[c].area[0]+5-t.width/2)*i-f*(1-i)/2,(s[c].area[1]+5+l-t.height/2)*i)),r.stroke(),r.restore()}r.restore()}(l,n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"map":i.clearRect(0,0,n.width,n.height),function(e,t,n,r){var i,a,u=o({},{border:!0,mercator:!1,borderWidth:1,borderColor:"#666666",fillOpacity:.6,activeBorderColor:"#f04864",activeFillColor:"#facc14",activeFillOpacity:1},t.extra.map),l=e,f=function(e){for(var t,n={xMin:180,xMax:0,yMin:90,yMax:0},r=0;r<e.length;r++)for(var i=e[r].geometry.coordinates,o=0;o<i.length;o++){t=i[o],1==t.length&&(t=t[0]);for(var a=0;a<t.length;a++){var s=t[a][0],c=t[a][1],u={x:s,y:c};n.xMin=n.xMin<u.x?n.xMin:u.x,n.xMax=n.xMax>u.x?n.xMax:u.x,n.yMin=n.yMin<u.y?n.yMin:u.y,n.yMax=n.yMax>u.y?n.yMax:u.y}}return n}(l);if(u.mercator){var d=s(f.xMax,f.yMax),h=s(f.xMin,f.yMin);f.xMax=d[0],f.yMax=d[1],f.xMin=h[0],f.yMin=h[1]}for(var p=t.width/Math.abs(f.xMax-f.xMin),g=t.height/Math.abs(f.yMax-f.yMin),v=p<g?p:g,m=t.width/2-Math.abs(f.xMax-f.xMin)/2*v,x=t.height/2-Math.abs(f.yMax-f.yMin)/2*v,_=0;_<l.length;_++){r.beginPath(),r.setLineWidth(u.borderWidth*t.pix),r.setStrokeStyle(u.borderColor),r.setFillStyle(c(e[_].color,u.fillOpacity)),t.tooltip&&t.tooltip.index==_&&(r.setStrokeStyle(u.activeBorderColor),r.setFillStyle(c(u.activeFillColor,u.activeFillOpacity)));for(var b=l[_].geometry.coordinates,w=0;w<b.length;w++){i=b[w],1==i.length&&(i=i[0]);for(var k=0;k<i.length;k++){var A=Array(2);A=u.mercator?s(i[k][0],i[k][1]):i[k],a=he(A[1],A[0],f,v,m,x),0===k?(r.beginPath(),r.moveTo(a.x,a.y)):r.lineTo(a.x,a.y)}r.fill(),1==u.border&&r.stroke()}if(1==t.dataLabel){var S=l[_].properties.centroid;if(S){u.mercator&&(S=s(l[_].properties.centroid[0],l[_].properties.centroid[1])),a=he(S[1],S[0],f,v,m,x);var P=l[_].textSize*t.pix||n.fontSize,T=l[_].properties.name;r.beginPath(),r.setFontSize(P),r.setFillStyle(l[_].textColor||t.fontColor),r.fillText(T,a.x-y(T,P,r)/2,a.y+P/2),r.closePath(),r.stroke()}}}t.chartData.mapData={bounds:f,scale:v,xoffset:m,yoffset:x,mercator:u.mercator},ae(t,n,r,1),r.draw()}(l,n,r,i);break;case"funnel":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.funnelData=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{type:"funnel",activeWidth:10,activeOpacity:.3,border:!1,borderWidth:2,borderColor:"#FFFFFF",fillOpacity:1,labelAlign:"right",linearType:"none",customColor:[]},t.extra.funnel),s=(t.height-t.area[0]-t.area[2])/e.length,u={x:t.area[3]+(t.width-t.area[1]-t.area[3])/2,y:t.height-t.area[2]},l=a.activeWidth*t.pix,f=Math.min((t.width-t.area[1]-t.area[3])/2-l,(t.height-t.area[0]-t.area[2])/2-l);if(e=F(e,f,a.type,s,i),r.save(),r.translate(u.x,u.y),a.customColor=g(a.linearType,a.customColor,e,n),"pyramid"==a.type)for(var d=0;d<e.length;d++){if(d==e.length-1){t.tooltip&&t.tooltip.index==d&&(r.beginPath(),r.setFillStyle(c(e[d].color,a.activeOpacity)),r.moveTo(-l,-s),r.lineTo(-e[d].radius-l,0),r.lineTo(e[d].radius+l,0),r.lineTo(l,-s),r.lineTo(-l,-s),r.closePath(),r.fill()),e[d].funnelArea=[u.x-e[d].radius,u.y-s*(d+1),u.x+e[d].radius,u.y-s*d],r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.setStrokeStyle(a.borderColor);var h=c(e[d].color,a.fillOpacity);if("custom"==a.linearType){var p=r.createLinearGradient(e[d].radius,-s,-e[d].radius,-s);p.addColorStop(0,c(e[d].color,a.fillOpacity)),p.addColorStop(.5,c(a.customColor[e[d].linearIndex],a.fillOpacity)),p.addColorStop(1,c(e[d].color,a.fillOpacity)),h=p}r.setFillStyle(h),r.moveTo(0,-s),r.lineTo(-e[d].radius,0),r.lineTo(e[d].radius,0),r.lineTo(0,-s),r.closePath(),r.fill(),1==a.border&&r.stroke()}else{t.tooltip&&t.tooltip.index==d&&(r.beginPath(),r.setFillStyle(c(e[d].color,a.activeOpacity)),r.moveTo(0,0),r.lineTo(-e[d].radius-l,0),r.lineTo(-e[d+1].radius-l,-s),r.lineTo(e[d+1].radius+l,-s),r.lineTo(e[d].radius+l,0),r.lineTo(0,0),r.closePath(),r.fill()),e[d].funnelArea=[u.x-e[d].radius,u.y-s*(d+1),u.x+e[d].radius,u.y-s*d],r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.setStrokeStyle(a.borderColor);h=c(e[d].color,a.fillOpacity);if("custom"==a.linearType){p=r.createLinearGradient(e[d].radius,-s,-e[d].radius,-s);p.addColorStop(0,c(e[d].color,a.fillOpacity)),p.addColorStop(.5,c(a.customColor[e[d].linearIndex],a.fillOpacity)),p.addColorStop(1,c(e[d].color,a.fillOpacity)),h=p}r.setFillStyle(h),r.moveTo(0,0),r.lineTo(-e[d].radius,0),r.lineTo(-e[d+1].radius,-s),r.lineTo(e[d+1].radius,-s),r.lineTo(e[d].radius,0),r.lineTo(0,0),r.closePath(),r.fill(),1==a.border&&r.stroke()}r.translate(0,-s)}else for(var v=0;v<e.length;v++){if(0==v){t.tooltip&&t.tooltip.index==v&&(r.beginPath(),r.setFillStyle(c(e[v].color,a.activeOpacity)),r.moveTo(-l,0),r.lineTo(-e[v].radius-l,-s),r.lineTo(e[v].radius+l,-s),r.lineTo(l,0),r.lineTo(-l,0),r.closePath(),r.fill()),e[v].funnelArea=[u.x-e[v].radius,u.y-s,u.x+e[v].radius,u.y],r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.setStrokeStyle(a.borderColor);h=c(e[v].color,a.fillOpacity);if("custom"==a.linearType){p=r.createLinearGradient(e[v].radius,-s,-e[v].radius,-s);p.addColorStop(0,c(e[v].color,a.fillOpacity)),p.addColorStop(.5,c(a.customColor[e[v].linearIndex],a.fillOpacity)),p.addColorStop(1,c(e[v].color,a.fillOpacity)),h=p}r.setFillStyle(h),r.moveTo(0,0),r.lineTo(-e[v].radius,-s),r.lineTo(e[v].radius,-s),r.lineTo(0,0),r.closePath(),r.fill(),1==a.border&&r.stroke()}else{t.tooltip&&t.tooltip.index==v&&(r.beginPath(),r.setFillStyle(c(e[v].color,a.activeOpacity)),r.moveTo(0,0),r.lineTo(-e[v-1].radius-l,0),r.lineTo(-e[v].radius-l,-s),r.lineTo(e[v].radius+l,-s),r.lineTo(e[v-1].radius+l,0),r.lineTo(0,0),r.closePath(),r.fill()),e[v].funnelArea=[u.x-e[v].radius,u.y-s*(v+1),u.x+e[v].radius,u.y-s*v],r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.setStrokeStyle(a.borderColor);h=c(e[v].color,a.fillOpacity);if("custom"==a.linearType){p=r.createLinearGradient(e[v].radius,-s,-e[v].radius,-s);p.addColorStop(0,c(e[v].color,a.fillOpacity)),p.addColorStop(.5,c(a.customColor[e[v].linearIndex],a.fillOpacity)),p.addColorStop(1,c(e[v].color,a.fillOpacity)),h=p}r.setFillStyle(h),r.moveTo(0,0),r.lineTo(-e[v-1].radius,0),r.lineTo(-e[v].radius,-s),r.lineTo(e[v].radius,-s),r.lineTo(e[v-1].radius,0),r.lineTo(0,0),r.closePath(),r.fill(),1==a.border&&r.stroke()}r.translate(0,-s)}return r.restore(),!1!==t.dataLabel&&1===i&&ye(e,t,r,s,a.labelAlign,l,u),{center:u,radius:f,series:e}}(l,n,r,i,e),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"line":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var t=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{type:"straight",width:2},t.extra.line);a.width*=t.pix;var s=t.chartData.xAxisData,c=s.xAxisPoints,u=s.eachSpacing,l=[];r.save();var d=0,h=t.width+u;return t._scrollDistance_&&0!==t._scrollDistance_&&!0===t.enableScroll&&(r.translate(t._scrollDistance_,0),d=-t._scrollDistance_-2*u+t.area[3],h=d+(t.xAxis.itemCount+4)*u),e.forEach((function(e,o){var s,p,g;s=[].concat(t.chartData.yAxisData.ranges[e.index]),p=s.pop(),g=s.shift();var v=e.data,y=H(v,p,g,c,u,t,n,i);l.push(y);var m=L(y,e);if("dash"==e.lineType){var x=e.dashLength?e.dashLength:8;x*=t.pix,r.setLineDash([x,x])}r.beginPath(),r.setStrokeStyle(e.color),r.setLineWidth(a.width),m.forEach((function(e,t){if(1===e.length)r.moveTo(e[0].x,e[0].y),r.arc(e[0].x,e[0].y,1,0,2*Math.PI);else{r.moveTo(e[0].x,e[0].y);var n=0;if("curve"===a.type)for(var i=0;i<e.length;i++){var o=e[i];if(0==n&&o.x>d&&(r.moveTo(o.x,o.y),n=1),i>0&&o.x>d&&o.x<h){var s=f(e,i-1);r.bezierCurveTo(s.ctrA.x,s.ctrA.y,s.ctrB.x,s.ctrB.y,o.x,o.y)}}if("straight"===a.type)for(var c=0;c<e.length;c++){var u=e[c];0==n&&u.x>d&&(r.moveTo(u.x,u.y),n=1),c>0&&u.x>d&&u.x<h&&r.lineTo(u.x,u.y)}if("step"===a.type)for(var l=0;l<e.length;l++){var p=e[l];0==n&&p.x>d&&(r.moveTo(p.x,p.y),n=1),l>0&&p.x>d&&p.x<h&&(r.lineTo(p.x,e[l-1].y),r.lineTo(p.x,p.y))}r.moveTo(e[0].x,e[0].y)}})),r.stroke(),r.setLineDash([]),!1!==t.dataPointShape&&X(y,e.color,e.pointShape,r,t)})),!1!==t.dataLabel&&1===i&&e.forEach((function(e,o){var a,s,l;a=[].concat(t.chartData.yAxisData.ranges[e.index]),s=a.pop(),l=a.shift();var f=e.data,d=H(f,s,l,c,u,t,n,i);Q(d,e,n,r,t)})),r.restore(),{xAxisPoints:c,calPoints:l,eachSpacing:u}}(l,n,r,i,e),a=t.xAxisPoints,s=t.calPoints,c=t.eachSpacing;n.chartData.xAxisPoints=a,n.chartData.calPoints=s,n.chartData.eachSpacing=c,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"scatter":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var t=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=(o({},{type:"circle"},t.extra.scatter),t.chartData.xAxisData),s=a.xAxisPoints,c=a.eachSpacing,u=[];r.save();return t.width,t._scrollDistance_&&0!==t._scrollDistance_&&!0===t.enableScroll&&(r.translate(t._scrollDistance_,0),-t._scrollDistance_-2*c+t.area[3],t.xAxis.itemCount),e.forEach((function(e,o){var a,u,l;a=[].concat(t.chartData.yAxisData.ranges[e.index]),u=a.pop(),l=a.shift();var f=e.data,d=H(f,u,l,s,c,t,n,i);r.beginPath(),r.setStrokeStyle(e.color),r.setFillStyle(e.color),r.setLineWidth(1*t.pix);var h=e.pointShape;if("diamond"===h)d.forEach((function(e,t){null!==e&&(r.moveTo(e.x,e.y-4.5),r.lineTo(e.x-4.5,e.y),r.lineTo(e.x,e.y+4.5),r.lineTo(e.x+4.5,e.y),r.lineTo(e.x,e.y-4.5))}));else if("circle"===h)d.forEach((function(e,n){null!==e&&(r.moveTo(e.x+2.5*t.pix,e.y),r.arc(e.x,e.y,3*t.pix,0,2*Math.PI,!1))}));else if("square"===h)d.forEach((function(e,t){null!==e&&(r.moveTo(e.x-3.5,e.y-3.5),r.rect(e.x-3.5,e.y-3.5,7,7))}));else if("triangle"===h)d.forEach((function(e,t){null!==e&&(r.moveTo(e.x,e.y-4.5),r.lineTo(e.x-4.5,e.y+4.5),r.lineTo(e.x+4.5,e.y+4.5),r.lineTo(e.x,e.y-4.5))}));else if("triangle"===h)return;r.closePath(),r.fill(),r.stroke()})),!1!==t.dataLabel&&1===i&&e.forEach((function(e,o){var a,u,l;a=[].concat(t.chartData.yAxisData.ranges[e.index]),u=a.pop(),l=a.shift();var f=e.data,d=H(f,u,l,s,c,t,n,i);Q(d,e,n,r,t)})),r.restore(),{xAxisPoints:s,calPoints:u,eachSpacing:c}}(l,n,r,i,e),a=t.xAxisPoints,s=t.calPoints,c=t.eachSpacing;n.chartData.xAxisPoints=a,n.chartData.calPoints=s,n.chartData.eachSpacing=c,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"bubble":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var t=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{opacity:1,border:2},t.extra.bubble),s=t.chartData.xAxisData,u=s.xAxisPoints,l=s.eachSpacing,f=[];r.save();return t.width,t._scrollDistance_&&0!==t._scrollDistance_&&!0===t.enableScroll&&(r.translate(t._scrollDistance_,0),-t._scrollDistance_-2*l+t.area[3],t.xAxis.itemCount),e.forEach((function(o,s){var f,d,h;f=[].concat(t.chartData.yAxisData.ranges[o.index]),d=f.pop(),h=f.shift();var p=o.data,g=H(p,d,h,u,l,t,n,i);r.beginPath(),r.setStrokeStyle(o.color),r.setLineWidth(a.border*t.pix),r.setFillStyle(c(o.color,a.opacity)),g.forEach((function(e,n){r.moveTo(e.x+e.r,e.y),r.arc(e.x,e.y,e.r*t.pix,0,2*Math.PI,!1)})),r.closePath(),r.fill(),r.stroke(),!1!==t.dataLabel&&1===i&&g.forEach((function(i,o){r.beginPath();var a=e.textSize*t.pix||n.fontSize;r.setFontSize(a),r.setFillStyle(e.textColor||"#FFFFFF"),r.setTextAlign("center"),r.fillText(String(i.t),i.x,i.y+a/2),r.closePath(),r.stroke(),r.setTextAlign("left")}))})),r.restore(),{xAxisPoints:u,calPoints:f,eachSpacing:l}}(l,n,r,i,e),a=t.xAxisPoints,s=t.calPoints,u=t.eachSpacing;n.chartData.xAxisPoints=a,n.chartData.calPoints=s,n.chartData.eachSpacing=u,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"mix":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var a=function(e,n,r,i){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,s=o({},{width:d/2,barBorderCircle:!1,barBorderRadius:[],seriesGap:2,linearType:"none",linearOpacity:1,customColor:[],colorStop:0},n.extra.mix.column),u=n.chartData.xAxisData,l=u.xAxisPoints,d=u.eachSpacing,h=n.height-n.area[2],p=[],v=0,y=0;e.forEach((function(e,t){"column"==e.type&&(y+=1)})),i.save();var m=-2,x=l.length+2,_=0,b=n.width+d;if(n._scrollDistance_&&0!==n._scrollDistance_&&!0===n.enableScroll&&(i.translate(n._scrollDistance_,0),m=Math.floor(-n._scrollDistance_/d)-2,x=m+n.xAxis.itemCount+4,_=-n._scrollDistance_-2*d+n.area[3],b=_+(n.xAxis.itemCount+4)*d),s.customColor=g(s.linearType,s.customColor,e,r),e.forEach((function(e,o){var u,g,w;u=[].concat(n.chartData.yAxisData.ranges[e.index]),g=u.pop(),w=u.shift();var k=e.data,A=H(k,g,w,l,d,n,r,a);if(p.push(A),"column"==e.type){A=U(A,d,y,v,0,n);for(var S=0;S<A.length;S++){var P=A[S];if(null!==P&&S>m&&S<x){var T=P.x-P.width/2;n.height,P.y,n.area[2];i.beginPath();var O=P.color||e.color,C=P.color||e.color;if("none"!==s.linearType){var I=i.createLinearGradient(T,P.y,T,n.height-n.area[2]);"opacity"==s.linearType?(I.addColorStop(0,c(O,s.linearOpacity)),I.addColorStop(1,c(O,1))):(I.addColorStop(0,c(s.customColor[e.linearIndex],s.linearOpacity)),I.addColorStop(s.colorStop,c(s.customColor[e.linearIndex],s.linearOpacity)),I.addColorStop(1,c(O,1))),O=I}if(s.barBorderRadius&&4===s.barBorderRadius.length||s.barBorderCircle){var E=T,D=P.y,M=P.width,F=n.height-n.area[2]-P.y;s.barBorderCircle&&(s.barBorderRadius=[M/2,M/2,0,0]);var j=t(s.barBorderRadius,4),$=j[0],R=j[1],N=j[2],B=j[3];$+N>F&&($=F,N=0,R=F,B=0),$+N>M/2&&($=M/2,N=0,R=M/2,B=0),$=$<0?0:$,R=R<0?0:R,N=N<0?0:N,B=B<0?0:B,i.arc(E+$,D+$,$,-Math.PI,-Math.PI/2),i.arc(E+M-R,D+R,R,-Math.PI/2,0),i.arc(E+M-N,D+F-N,N,0,Math.PI/2),i.arc(E+B,D+F-B,B,Math.PI/2,Math.PI)}else i.moveTo(T,P.y),i.lineTo(T+P.width-2,P.y),i.lineTo(T+P.width-2,n.height-n.area[2]),i.lineTo(T,n.height-n.area[2]),i.lineTo(T,P.y),i.setLineWidth(1),i.setStrokeStyle(C);i.setFillStyle(O),i.closePath(),i.fill()}}v+=1}if("area"==e.type)for(var z=L(A,e),W=0;W<z.length;W++){var q=z[W];if(i.beginPath(),i.setStrokeStyle(e.color),i.setFillStyle(c(e.color,.2)),i.setLineWidth(2*n.pix),q.length>1){var V=q[0],K=q[q.length-1];i.moveTo(V.x,V.y);var G=0;if("curve"===e.style)for(var J=0;J<q.length;J++){var Y=q[J];if(0==G&&Y.x>_&&(i.moveTo(Y.x,Y.y),G=1),J>0&&Y.x>_&&Y.x<b){var Q=f(q,J-1);i.bezierCurveTo(Q.ctrA.x,Q.ctrA.y,Q.ctrB.x,Q.ctrB.y,Y.x,Y.y)}}else for(var Z=0;Z<q.length;Z++){var ee=q[Z];0==G&&ee.x>_&&(i.moveTo(ee.x,ee.y),G=1),Z>0&&ee.x>_&&ee.x<b&&i.lineTo(ee.x,ee.y)}i.lineTo(K.x,h),i.lineTo(V.x,h),i.lineTo(V.x,V.y)}else{var te=q[0];i.moveTo(te.x-d/2,te.y),i.lineTo(te.x+d/2,te.y),i.lineTo(te.x+d/2,h),i.lineTo(te.x-d/2,h),i.moveTo(te.x-d/2,te.y)}i.closePath(),i.fill()}if("line"==e.type){var ne=L(A,e);ne.forEach((function(t,r){if("dash"==e.lineType){var o=e.dashLength?e.dashLength:8;o*=n.pix,i.setLineDash([o,o])}if(i.beginPath(),i.setStrokeStyle(e.color),i.setLineWidth(2*n.pix),1===t.length)i.moveTo(t[0].x,t[0].y),i.arc(t[0].x,t[0].y,1,0,2*Math.PI);else{i.moveTo(t[0].x,t[0].y);var a=0;if("curve"==e.style)for(var s=0;s<t.length;s++){var c=t[s];if(0==a&&c.x>_&&(i.moveTo(c.x,c.y),a=1),s>0&&c.x>_&&c.x<b){var u=f(t,s-1);i.bezierCurveTo(u.ctrA.x,u.ctrA.y,u.ctrB.x,u.ctrB.y,c.x,c.y)}}else for(var l=0;l<t.length;l++){var d=t[l];0==a&&d.x>_&&(i.moveTo(d.x,d.y),a=1),l>0&&d.x>_&&d.x<b&&i.lineTo(d.x,d.y)}i.moveTo(t[0].x,t[0].y)}i.stroke(),i.setLineDash([])}))}"point"==e.type&&(e.addPoint=!0),1==e.addPoint&&"column"!==e.type&&X(A,e.color,e.pointShape,i,n)})),!1!==n.dataLabel&&1===a){v=0;e.forEach((function(e,t){var o,s,c;o=[].concat(n.chartData.yAxisData.ranges[e.index]),s=o.pop(),c=o.shift();var u=e.data,f=H(u,s,c,l,d,n,r,a);"column"!==e.type?Q(f,e,r,i,n):(f=U(f,d,y,v,0,n),Q(f,e,r,i,n),v+=1)}))}return i.restore(),{xAxisPoints:l,calPoints:p,eachSpacing:d}}(l,n,r,i,e),s=a.xAxisPoints,u=a.calPoints,d=a.eachSpacing;n.chartData.xAxisPoints=s,n.chartData.calPoints=u,n.chartData.eachSpacing=d,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"column":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var a=function(e,n,r,i){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,s=n.chartData.xAxisData,u=s.xAxisPoints,l=s.eachSpacing,f=o({},{type:"group",width:l/2,meterBorder:4,meterFillColor:"#FFFFFF",barBorderCircle:!1,barBorderRadius:[],seriesGap:2,linearType:"none",linearOpacity:1,customColor:[],colorStop:0},n.extra.column),d=[];i.save();var h=-2,p=u.length+2;return n._scrollDistance_&&0!==n._scrollDistance_&&!0===n.enableScroll&&(i.translate(n._scrollDistance_,0),h=Math.floor(-n._scrollDistance_/l)-2,p=h+n.xAxis.itemCount+4),n.tooltip&&n.tooltip.textList&&n.tooltip.textList.length&&1===a&&ie(n.tooltip.offset.x,n,0,i,l),f.customColor=g(f.linearType,f.customColor,e,r),e.forEach((function(o,s){var g,v,y;g=[].concat(n.chartData.yAxisData.ranges[o.index]),v=g.pop(),y=g.shift();var m=o.data;switch(f.type){case"group":var x=H(m,v,y,u,l,n,r,a),_=V(m,v,y,u,l,n,r,s,e,a);d.push(_),x=U(x,l,e.length,s,0,n);for(var b=0;b<x.length;b++){var w=x[b];if(null!==w&&b>h&&b<p){var k=w.x-w.width/2,A=n.height-w.y-n.area[2];i.beginPath();var S=w.color||o.color,P=w.color||o.color;if("none"!==f.linearType){var T=i.createLinearGradient(k,w.y,k,n.height-n.area[2]);"opacity"==f.linearType?(T.addColorStop(0,c(S,f.linearOpacity)),T.addColorStop(1,c(S,1))):(T.addColorStop(0,c(f.customColor[o.linearIndex],f.linearOpacity)),T.addColorStop(f.colorStop,c(f.customColor[o.linearIndex],f.linearOpacity)),T.addColorStop(1,c(S,1))),S=T}if(f.barBorderRadius&&4===f.barBorderRadius.length||!0===f.barBorderCircle){var O=k,C=w.y,L=w.width,I=n.height-n.area[2]-w.y;f.barBorderCircle&&(f.barBorderRadius=[L/2,L/2,0,0]);var E=t(f.barBorderRadius,4),D=E[0],M=E[1],F=E[2],j=E[3];D+F>I&&(D=I,F=0,M=I,j=0),D+F>L/2&&(D=L/2,F=0,M=L/2,j=0),D=D<0?0:D,M=M<0?0:M,F=F<0?0:F,j=j<0?0:j,i.arc(O+D,C+D,D,-Math.PI,-Math.PI/2),i.arc(O+L-M,C+M,M,-Math.PI/2,0),i.arc(O+L-F,C+I-F,F,0,Math.PI/2),i.arc(O+j,C+I-j,j,Math.PI/2,Math.PI)}else i.moveTo(k,w.y),i.lineTo(k+w.width-2,w.y),i.lineTo(k+w.width-2,n.height-n.area[2]),i.lineTo(k,n.height-n.area[2]),i.lineTo(k,w.y),i.setLineWidth(1),i.setStrokeStyle(P);i.setFillStyle(S),i.closePath(),i.fill()}}break;case"stack":x=V(m,v,y,u,l,n,r,s,e,a);d.push(x),x=z(x,l,e.length,0,0,n);for(var $=0;$<x.length;$++){var R=x[$];if(null!==R&&$>h&&$<p){i.beginPath();S=R.color||o.color,k=R.x-R.width/2+1,A=n.height-R.y-n.area[2];var N=n.height-R.y0-n.area[2];s>0&&(A-=N),i.setFillStyle(S),i.moveTo(k,R.y),i.fillRect(k,R.y,R.width-2,A),i.closePath(),i.fill()}}break;case"meter":x=H(m,v,y,u,l,n,r,a);if(d.push(x),x=B(x,l,e.length,s,0,n,f.meterBorder),0==s)for(var W=0;W<x.length;W++){var q=x[W];if(null!==q&&W>h&&W<p){i.beginPath(),i.setFillStyle(f.meterFillColor);k=q.x-q.width/2,A=n.height-q.y-n.area[2];i.moveTo(k,q.y),i.fillRect(k,q.y,q.width,A),i.closePath(),i.fill(),f.meterBorder>0&&(i.beginPath(),i.setStrokeStyle(o.color),i.setLineWidth(f.meterBorder*n.pix),i.moveTo(k+.5*f.meterBorder,q.y+A),i.lineTo(k+.5*f.meterBorder,q.y+.5*f.meterBorder),i.lineTo(k+q.width-.5*f.meterBorder,q.y+.5*f.meterBorder),i.lineTo(k+q.width-.5*f.meterBorder,q.y+A),i.stroke())}}else for(var K=0;K<x.length;K++){var G=x[K];if(null!==G&&K>h&&K<p){i.beginPath(),i.setFillStyle(G.color||o.color);k=G.x-G.width/2,A=n.height-G.y-n.area[2];i.moveTo(k,G.y),i.fillRect(k,G.y,G.width,A),i.closePath(),i.fill()}}break}})),!1!==n.dataLabel&&1===a&&e.forEach((function(t,o){var s,c,d;s=[].concat(n.chartData.yAxisData.ranges[t.index]),c=s.pop(),d=s.shift();var h=t.data;switch(f.type){case"group":var p=H(h,c,d,u,l,n,r,a);p=U(p,l,e.length,o,0,n),Q(p,t,r,i,n);break;case"stack":p=V(h,c,d,u,l,n,r,o,e,a);Q(p,t,r,i,n);break;case"meter":p=H(h,c,d,u,l,n,r,a);Q(p,t,r,i,n);break}})),i.restore(),{xAxisPoints:u,calPoints:d,eachSpacing:l}}(l,n,r,i,e),s=a.xAxisPoints,u=a.calPoints,f=a.eachSpacing;n.chartData.xAxisPoints=s,n.chartData.calPoints=u,n.chartData.eachSpacing=f,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"area":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var t=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{type:"straight",opacity:.2,addLine:!1,width:2,gradient:!1},t.extra.area),s=t.chartData.xAxisData,u=s.xAxisPoints,l=s.eachSpacing,d=t.height-t.area[2],h=[];r.save();var p=0,g=t.width+l;return t._scrollDistance_&&0!==t._scrollDistance_&&!0===t.enableScroll&&(r.translate(t._scrollDistance_,0),p=-t._scrollDistance_-2*l+t.area[3],g=p+(t.xAxis.itemCount+4)*l),e.forEach((function(e,o){var s,v,y;s=[].concat(t.chartData.yAxisData.ranges[e.index]),v=s.pop(),y=s.shift();var m=e.data,x=H(m,v,y,u,l,t,n,i);h.push(x);for(var _=L(x,e),b=0;b<_.length;b++){var w=_[b];if(r.beginPath(),r.setStrokeStyle(c(e.color,a.opacity)),a.gradient){var k=r.createLinearGradient(0,t.area[0],0,t.height-t.area[2]);k.addColorStop("0",c(e.color,a.opacity)),k.addColorStop("1.0",c("#FFFFFF",.1)),r.setFillStyle(k)}else r.setFillStyle(c(e.color,a.opacity));if(r.setLineWidth(a.width*t.pix),w.length>1){var A=w[0],S=w[w.length-1];r.moveTo(A.x,A.y);var P=0;if("curve"===a.type)for(var T=0;T<w.length;T++){var O=w[T];if(0==P&&O.x>p&&(r.moveTo(O.x,O.y),P=1),T>0&&O.x>p&&O.x<g){var C=f(w,T-1);r.bezierCurveTo(C.ctrA.x,C.ctrA.y,C.ctrB.x,C.ctrB.y,O.x,O.y)}}if("straight"===a.type)for(var I=0;I<w.length;I++){var E=w[I];0==P&&E.x>p&&(r.moveTo(E.x,E.y),P=1),I>0&&E.x>p&&E.x<g&&r.lineTo(E.x,E.y)}if("step"===a.type)for(var D=0;D<w.length;D++){var M=w[D];0==P&&M.x>p&&(r.moveTo(M.x,M.y),P=1),D>0&&M.x>p&&M.x<g&&(r.lineTo(M.x,w[D-1].y),r.lineTo(M.x,M.y))}r.lineTo(S.x,d),r.lineTo(A.x,d),r.lineTo(A.x,A.y)}else{var F=w[0];r.moveTo(F.x-l/2,F.y),r.lineTo(F.x+l/2,F.y),r.lineTo(F.x+l/2,d),r.lineTo(F.x-l/2,d),r.moveTo(F.x-l/2,F.y)}if(r.closePath(),r.fill(),a.addLine){if("dash"==e.lineType){var j=e.dashLength?e.dashLength:8;j*=t.pix,r.setLineDash([j,j])}if(r.beginPath(),r.setStrokeStyle(e.color),r.setLineWidth(a.width*t.pix),1===w.length)r.moveTo(w[0].x,w[0].y),r.arc(w[0].x,w[0].y,1,0,2*Math.PI);else{r.moveTo(w[0].x,w[0].y);var $=0;if("curve"===a.type)for(var R=0;R<w.length;R++){var N=w[R];if(0==$&&N.x>p&&(r.moveTo(N.x,N.y),$=1),R>0&&N.x>p&&N.x<g){var U=f(w,R-1);r.bezierCurveTo(U.ctrA.x,U.ctrA.y,U.ctrB.x,U.ctrB.y,N.x,N.y)}}if("straight"===a.type)for(var B=0;B<w.length;B++){var z=w[B];0==$&&z.x>p&&(r.moveTo(z.x,z.y),$=1),B>0&&z.x>p&&z.x<g&&r.lineTo(z.x,z.y)}if("step"===a.type)for(var W=0;W<w.length;W++){var q=w[W];0==$&&q.x>p&&(r.moveTo(q.x,q.y),$=1),W>0&&q.x>p&&q.x<g&&(r.lineTo(q.x,w[W-1].y),r.lineTo(q.x,q.y))}r.moveTo(w[0].x,w[0].y)}r.stroke(),r.setLineDash([])}}!1!==t.dataPointShape&&X(x,e.color,e.pointShape,r,t)})),!1!==t.dataLabel&&1===i&&e.forEach((function(e,o){var a,s,c;a=[].concat(t.chartData.yAxisData.ranges[e.index]),s=a.pop(),c=a.shift();var f=e.data,d=H(f,s,c,u,l,t,n,i);Q(d,e,n,r,t)})),r.restore(),{xAxisPoints:u,calPoints:h,eachSpacing:l}}(l,n,r,i,e),a=t.xAxisPoints,s=t.calPoints,u=t.eachSpacing;n.chartData.xAxisPoints=a,n.chartData.calPoints=s,n.chartData.eachSpacing=u,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"ring":case"pie":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.pieData=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{activeOpacity:.5,activeRadius:10,offsetAngle:0,labelWidth:15,ringWidth:30,customRadius:0,border:!1,borderWidth:2,borderColor:"#FFFFFF",centerColor:"#FFFFFF",linearType:"none",customColor:[]},"pie"==t.type?t.extra.pie:t.extra.ring),s={x:t.area[3]+(t.width-t.area[1]-t.area[3])/2,y:t.area[0]+(t.height-t.area[0]-t.area[2])/2};0==n.pieChartLinePadding&&(n.pieChartLinePadding=a.activeRadius*t.pix);var u=Math.min((t.width-t.area[1]-t.area[3])/2-n.pieChartLinePadding-n.pieChartTextPadding-n._pieTextMaxLength_,(t.height-t.area[0]-t.area[2])/2-n.pieChartLinePadding-n.pieChartTextPadding);a.customRadius>0&&(u=a.customRadius*t.pix),e=M(e,u,i);var l=a.activeRadius*t.pix;if(a.customColor=g(a.linearType,a.customColor,e,n),e=e.map((function(e){return e._start_+=a.offsetAngle*Math.PI/180,e})),e.forEach((function(e,n){t.tooltip&&t.tooltip.index==n&&(r.beginPath(),r.setFillStyle(c(e.color,a.activeOpacity||.5)),r.moveTo(s.x,s.y),r.arc(s.x,s.y,e._radius_+l,e._start_,e._start_+2*e._proportion_*Math.PI),r.closePath(),r.fill()),r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.lineJoin="round",r.setStrokeStyle(a.borderColor);var i,o=e.color;"custom"==a.linearType&&(i=r.createCircularGradient?r.createCircularGradient(s.x,s.y,e._radius_):r.createRadialGradient(s.x,s.y,0,s.x,s.y,e._radius_),i.addColorStop(0,c(a.customColor[e.linearIndex],1)),i.addColorStop(1,c(e.color,1)),o=i);r.setFillStyle(o),r.moveTo(s.x,s.y),r.arc(s.x,s.y,e._radius_,e._start_,e._start_+2*e._proportion_*Math.PI),r.closePath(),r.fill(),1==a.border&&r.stroke()})),"ring"===t.type){var f=.6*u;"number"===typeof a.ringWidth&&a.ringWidth>0&&(f=Math.max(0,u-a.ringWidth*t.pix)),r.beginPath(),r.setFillStyle(a.centerColor),r.moveTo(s.x,s.y),r.arc(s.x,s.y,f,0,2*Math.PI),r.closePath(),r.fill()}if(!1!==t.dataLabel&&1===i){for(var d=!1,h=0,p=e.length;h<p;h++)if(e[h].data>0){d=!0;break}d&&te(e,t,n,r,0,s)}return 1===i&&"ring"===t.type&&Y(t,n,r,s),{center:s,radius:u,series:e}}(l,n,r,i,e),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"rose":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.pieData=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{type:"area",activeOpacity:.5,activeRadius:10,offsetAngle:0,labelWidth:15,border:!1,borderWidth:2,borderColor:"#FFFFFF",linearType:"none",customColor:[]},t.extra.rose);0==n.pieChartLinePadding&&(n.pieChartLinePadding=a.activeRadius*t.pix);var s={x:t.area[3]+(t.width-t.area[1]-t.area[3])/2,y:t.area[0]+(t.height-t.area[0]-t.area[2])/2},u=Math.min((t.width-t.area[1]-t.area[3])/2-n.pieChartLinePadding-n.pieChartTextPadding-n._pieTextMaxLength_,(t.height-t.area[0]-t.area[2])/2-n.pieChartLinePadding-n.pieChartTextPadding),l=a.minRadius||.5*u;e=j(e,a.type,l,u,i);var f=a.activeRadius*t.pix;if(a.customColor=g(a.linearType,a.customColor,e,n),e=e.map((function(e){return e._start_+=(a.offsetAngle||0)*Math.PI/180,e})),e.forEach((function(e,n){t.tooltip&&t.tooltip.index==n&&(r.beginPath(),r.setFillStyle(c(e.color,a.activeOpacity||.5)),r.moveTo(s.x,s.y),r.arc(s.x,s.y,f+e._radius_,e._start_,e._start_+2*e._rose_proportion_*Math.PI),r.closePath(),r.fill()),r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.lineJoin="round",r.setStrokeStyle(a.borderColor);var i,o=e.color;"custom"==a.linearType&&(i=r.createCircularGradient?r.createCircularGradient(s.x,s.y,e._radius_):r.createRadialGradient(s.x,s.y,0,s.x,s.y,e._radius_),i.addColorStop(0,c(a.customColor[e.linearIndex],1)),i.addColorStop(1,c(e.color,1)),o=i);r.setFillStyle(o),r.moveTo(s.x,s.y),r.arc(s.x,s.y,e._radius_,e._start_,e._start_+2*e._rose_proportion_*Math.PI),r.closePath(),r.fill(),1==a.border&&r.stroke()})),!1!==t.dataLabel&&1===i){for(var d=!1,h=0,p=e.length;h<p;h++)if(e[h].data>0){d=!0;break}d&&te(e,t,n,r,0,s)}return{center:s,radius:u,series:e}}(l,n,r,i,e),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"radar":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.radarData=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,a=o({},{gridColor:"#cccccc",gridType:"radar",opacity:.2,gridCount:3,border:!1,borderWidth:2},t.extra.radar),s=k(t.categories.length),u={x:t.area[3]+(t.width-t.area[1]-t.area[3])/2,y:t.area[0]+(t.height-t.area[0]-t.area[2])/2},l=(t.width-t.area[1]-t.area[3])/2,f=(t.height-t.area[0]-t.area[2])/2,h=Math.min(l-(w(t.categories,n.fontSize,r)+n.radarLabelTextMargin),f-n.radarLabelTextMargin);h-=n.radarLabelTextMargin*t.pix,r.beginPath(),r.setLineWidth(1*t.pix),r.setStrokeStyle(a.gridColor),s.forEach((function(e){var t=d(h*Math.cos(e),h*Math.sin(e),u);r.moveTo(u.x,u.y),r.lineTo(t.x,t.y)})),r.stroke(),r.closePath();for(var p=function(e){var n={};if(r.beginPath(),r.setLineWidth(1*t.pix),r.setStrokeStyle(a.gridColor),"radar"==a.gridType)s.forEach((function(t,i){var o=d(h/a.gridCount*e*Math.cos(t),h/a.gridCount*e*Math.sin(t),u);0===i?(n=o,r.moveTo(o.x,o.y)):r.lineTo(o.x,o.y)})),r.lineTo(n.x,n.y);else{var i=d(h/a.gridCount*e*Math.cos(1.5),h/a.gridCount*e*Math.sin(1.5),u);r.arc(u.x,u.y,u.y-i.y,0,2*Math.PI,!1)}r.stroke(),r.closePath()},g=1;g<=a.gridCount;g++)p(g);var v=D(s,u,h,e,t,i);return v.forEach((function(e,n){if(r.beginPath(),r.setLineWidth(a.borderWidth*t.pix),r.setStrokeStyle(e.color),r.setFillStyle(c(e.color,a.opacity)),e.data.forEach((function(e,t){0===t?r.moveTo(e.position.x,e.position.y):r.lineTo(e.position.x,e.position.y)})),r.closePath(),r.fill(),!0===a.border&&r.stroke(),r.closePath(),!1!==t.dataPointShape){var i=e.data.map((function(e){return e.position}));X(i,e.color,e.pointShape,r,t)}})),ee(s,h,u,t,n,r),{center:u,radius:h,angleList:s}}(l,n,r,i,e),le(n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"arcbar":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.arcbarData=function(e,t,n,r){var i,a,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,u=o({},{startAngle:.75,endAngle:.25,type:"default",width:12,gap:2,linearType:"none",customColor:[]},t.extra.arcbar);e=$(e,u,s),i=u.centerX||u.centerY?{x:u.centerX?u.centerX:t.width/2,y:u.centerY?u.centerY:t.height/2}:{x:t.width/2,y:t.height/2},u.radius?a=u.radius:(a=Math.min(i.x,i.y),a-=5*t.pix,a-=u.width/2),u.customColor=g(u.linearType,u.customColor,e,n);for(var l=0;l<e.length;l++){var f=e[l];r.setLineWidth(u.width*t.pix),r.setStrokeStyle(u.backgroundColor||"#E9E9E9"),r.setLineCap("round"),r.beginPath(),"default"==u.type?r.arc(i.x,i.y,a-(u.width*t.pix+u.gap*t.pix)*l,u.startAngle*Math.PI,u.endAngle*Math.PI,!1):r.arc(i.x,i.y,a-(u.width*t.pix+u.gap*t.pix)*l,0,2*Math.PI,!1),r.stroke();var d=f.color;if("custom"==u.linearType){var h=r.createLinearGradient(i.x-a,i.y,i.x+a,i.y);h.addColorStop(1,c(u.customColor[f.linearIndex],1)),h.addColorStop(0,c(f.color,1)),d=h}r.setLineWidth(u.width*t.pix),r.setStrokeStyle(d),r.setLineCap("round"),r.beginPath(),r.arc(i.x,i.y,a-(u.width*t.pix+u.gap*t.pix)*l,u.startAngle*Math.PI,f._proportion_*Math.PI,!1),r.stroke()}return Y(t,n,r,i),{center:i,radius:a,series:e}}(l,n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"gauge":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),n.chartData.gaugeData=function(e,t,n,r,i){var a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,s=o({},{type:"default",startAngle:.75,endAngle:.25,width:15,labelOffset:13,splitLine:{fixRadius:0,splitNumber:10,width:15,color:"#FFFFFF",childNumber:5,childWidth:5},pointer:{width:15,color:"auto"}},n.extra.gauge);void 0==s.oldAngle&&(s.oldAngle=s.startAngle),void 0==s.oldData&&(s.oldData=0),e=R(e,s.startAngle,s.endAngle);var u={x:n.width/2,y:n.height/2},l=Math.min(u.x,u.y);l-=5*n.pix,l-=s.width/2;var f=l-s.width,d=0;if("progress"==s.type){var h=l-3*s.width;i.beginPath();var p=i.createLinearGradient(u.x,u.y-h,u.x,u.y+h);p.addColorStop("0",c(t[0].color,.3)),p.addColorStop("1.0",c("#FFFFFF",.1)),i.setFillStyle(p),i.arc(u.x,u.y,h,0,2*Math.PI,!1),i.fill(),i.setLineWidth(s.width),i.setStrokeStyle(c(t[0].color,.3)),i.setLineCap("round"),i.beginPath(),i.arc(u.x,u.y,f,s.startAngle*Math.PI,s.endAngle*Math.PI,!1),i.stroke(),d=s.startAngle-s.endAngle+1;s.splitLine.splitNumber;var g=d/s.splitLine.splitNumber/s.splitLine.childNumber,v=-l-.5*s.width-s.splitLine.fixRadius,y=-l-s.width-s.splitLine.fixRadius+s.splitLine.width;i.save(),i.translate(u.x,u.y),i.rotate((s.startAngle-1)*Math.PI);for(var m=s.splitLine.splitNumber*s.splitLine.childNumber+1,x=t[0].data*a,_=0;_<m;_++)i.beginPath(),x>_/m?i.setStrokeStyle(c(t[0].color,1)):i.setStrokeStyle(c(t[0].color,.3)),i.setLineWidth(3*n.pix),i.moveTo(v,0),i.lineTo(y,0),i.stroke(),i.rotate(g*Math.PI);i.restore(),t=$(t,s,a),i.setLineWidth(s.width),i.setStrokeStyle(t[0].color),i.setLineCap("round"),i.beginPath(),i.arc(u.x,u.y,f,s.startAngle*Math.PI,t[0]._proportion_*Math.PI,!1),i.stroke();var b=l-2.5*s.width;i.save(),i.translate(u.x,u.y),i.rotate((t[0]._proportion_-1)*Math.PI),i.beginPath(),i.setLineWidth(s.width/3);var w=i.createLinearGradient(0,.6*-b,0,.6*b);w.addColorStop("0",c("#FFFFFF",0)),w.addColorStop("0.5",c(t[0].color,1)),w.addColorStop("1.0",c("#FFFFFF",0)),i.setStrokeStyle(w),i.arc(0,0,b,.85*Math.PI,1.15*Math.PI,!1),i.stroke(),i.beginPath(),i.setLineWidth(1),i.setStrokeStyle(t[0].color),i.setFillStyle(t[0].color),i.moveTo(-b-s.width/3/2,-4),i.lineTo(-b-s.width/3/2-4,0),i.lineTo(-b-s.width/3/2,4),i.lineTo(-b-s.width/3/2,-4),i.stroke(),i.fill(),i.restore()}else{i.setLineWidth(s.width),i.setLineCap("butt");for(var k=0;k<e.length;k++){var A=e[k];i.beginPath(),i.setStrokeStyle(A.color),i.arc(u.x,u.y,l,A._startAngle_*Math.PI,A._endAngle_*Math.PI,!1),i.stroke()}i.save(),d=s.startAngle-s.endAngle+1;var S=d/s.splitLine.splitNumber,P=d/s.splitLine.splitNumber/s.splitLine.childNumber,T=-l-.5*s.width-s.splitLine.fixRadius,O=-l-.5*s.width-s.splitLine.fixRadius+s.splitLine.width,C=-l-.5*s.width-s.splitLine.fixRadius+s.splitLine.childWidth;i.translate(u.x,u.y),i.rotate((s.startAngle-1)*Math.PI);for(var L=0;L<s.splitLine.splitNumber+1;L++)i.beginPath(),i.setStrokeStyle(s.splitLine.color),i.setLineWidth(2*n.pix),i.moveTo(T,0),i.lineTo(O,0),i.stroke(),i.rotate(S*Math.PI);i.restore(),i.save(),i.translate(u.x,u.y),i.rotate((s.startAngle-1)*Math.PI);for(var I=0;I<s.splitLine.splitNumber*s.splitLine.childNumber+1;I++)i.beginPath(),i.setStrokeStyle(s.splitLine.color),i.setLineWidth(1*n.pix),i.moveTo(T,0),i.lineTo(C,0),i.stroke(),i.rotate(P*Math.PI);i.restore(),t=N(t,e,s,a);for(var E=0;E<t.length;E++){var D=t[E];i.save(),i.translate(u.x,u.y),i.rotate((D._proportion_-1)*Math.PI),i.beginPath(),i.setFillStyle(D.color),i.moveTo(s.pointer.width,0),i.lineTo(0,-s.pointer.width/2),i.lineTo(-f,0),i.lineTo(0,s.pointer.width/2),i.lineTo(s.pointer.width,0),i.closePath(),i.fill(),i.beginPath(),i.setFillStyle("#FFFFFF"),i.arc(0,0,s.pointer.width/6,0,2*Math.PI,!1),i.fill(),i.restore()}!1!==n.dataLabel&&Z(s,l,u,n,r,i)}return Y(n,r,i,u),1===a&&"gauge"===n.type&&(n.extra.gauge.oldAngle=t[0]._proportion_,n.extra.gauge.oldData=t[0].data),{center:u,radius:l,innerRadius:f,categories:e,totalAngle:d}}(h,l,n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break;case"candle":this.animationInstance=new _e({timing:n.timing,duration:v,onProcess:function(e){i.clearRect(0,0,n.width,n.height),n.rotate&&J(i,n),ce(0,n,0,i),se(h,n,r,i);var t=function(e,t,n,r,i){var a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,s=o({},{color:{},average:{}},n.extra.candle);s.color=o({},{upLine:"#f04864",upFill:"#f04864",downLine:"#2fc25b",downFill:"#2fc25b"},s.color),s.average=o({},{show:!1,name:[],day:[],color:r.color},s.average),n.extra.candle=s;var c=n.chartData.xAxisData,u=c.xAxisPoints,l=c.eachSpacing,d=[];i.save();var h=-2,p=u.length+2,g=0,v=n.width+l;return n._scrollDistance_&&0!==n._scrollDistance_&&!0===n.enableScroll&&(i.translate(n._scrollDistance_,0),h=Math.floor(-n._scrollDistance_/l)-2,p=h+n.xAxis.itemCount+4,g=-n._scrollDistance_-2*l+n.area[3],v=g+(n.xAxis.itemCount+4)*l),(s.average.show||t)&&t.forEach((function(e,t){var o,s,c;o=[].concat(n.chartData.yAxisData.ranges[e.index]),s=o.pop(),c=o.shift();for(var d=e.data,h=H(d,s,c,u,l,n,r,a),p=L(h,e),y=0;y<p.length;y++){var m=p[y];if(i.beginPath(),i.setStrokeStyle(e.color),i.setLineWidth(1),1===m.length)i.moveTo(m[0].x,m[0].y),i.arc(m[0].x,m[0].y,1,0,2*Math.PI);else{i.moveTo(m[0].x,m[0].y);for(var x=0,_=0;_<m.length;_++){var b=m[_];if(0==x&&b.x>g&&(i.moveTo(b.x,b.y),x=1),_>0&&b.x>g&&b.x<v){var w=f(m,_-1);i.bezierCurveTo(w.ctrA.x,w.ctrA.y,w.ctrB.x,w.ctrB.y,b.x,b.y)}}i.moveTo(m[0].x,m[0].y)}i.closePath(),i.stroke()}})),e.forEach((function(e,t){var o,c,f;o=[].concat(n.chartData.yAxisData.ranges[e.index]),c=o.pop(),f=o.shift();var g=e.data,v=q(g,c,f,u,l,n,r,a);d.push(v);for(var y=L(v,e),m=0;m<y[0].length;m++)if(m>h&&m<p){var x=y[0][m];i.beginPath(),g[m][1]-g[m][0]>0?(i.setStrokeStyle(s.color.upLine),i.setFillStyle(s.color.upFill),i.setLineWidth(1*n.pix),i.moveTo(x[3].x,x[3].y),i.lineTo(x[1].x,x[1].y),i.lineTo(x[1].x-l/4,x[1].y),i.lineTo(x[0].x-l/4,x[0].y),i.lineTo(x[0].x,x[0].y),i.lineTo(x[2].x,x[2].y),i.lineTo(x[0].x,x[0].y),i.lineTo(x[0].x+l/4,x[0].y),i.lineTo(x[1].x+l/4,x[1].y),i.lineTo(x[1].x,x[1].y),i.moveTo(x[3].x,x[3].y)):(i.setStrokeStyle(s.color.downLine),i.setFillStyle(s.color.downFill),i.setLineWidth(1*n.pix),i.moveTo(x[3].x,x[3].y),i.lineTo(x[0].x,x[0].y),i.lineTo(x[0].x-l/4,x[0].y),i.lineTo(x[1].x-l/4,x[1].y),i.lineTo(x[1].x,x[1].y),i.lineTo(x[2].x,x[2].y),i.lineTo(x[1].x,x[1].y),i.lineTo(x[1].x+l/4,x[1].y),i.lineTo(x[0].x+l/4,x[0].y),i.lineTo(x[0].x,x[0].y),i.moveTo(x[3].x,x[3].y)),i.closePath(),i.fill(),i.stroke()}})),i.restore(),{xAxisPoints:u,calPoints:d,eachSpacing:l}}(l,m,n,r,i,e),a=t.xAxisPoints,s=t.calPoints,c=t.eachSpacing;n.chartData.xAxisPoints=a,n.chartData.calPoints=s,n.chartData.eachSpacing=c,ue(0,n,r,i),!1!==n.enableMarkLine&&1===e&&ne(n,r,i),le(m?0:n.series,n,r,i,n.chartData),ae(n,r,i,e),me(0,i)},onAnimationFinish:function(){u.uevent.trigger("renderComplete")}});break}}function we(){this.events={}}_e.prototype.stop=function(){this.isStop=!0},we.prototype.addEventListener=function(e,t){this.events[e]=this.events[e]||[],this.events[e].push(t)},we.prototype.delEventListener=function(e){this.events[e]=[]},we.prototype.trigger=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],i=t.slice(1);this.events[r]&&this.events[r].forEach((function(e){try{e.apply(null,i)}catch(t){}}))};var ke=function(e){e.pix=e.pixelRatio?e.pixelRatio:1,e.fontSize=e.fontSize?e.fontSize:13,e.fontColor=e.fontColor?e.fontColor:i.fontColor,""!=e.background&&"none"!=e.background||(e.background="#FFFFFF"),e.title=o({},e.title),e.subtitle=o({},e.subtitle),e.duration=e.duration?e.duration:1e3,e.yAxis=o({},{data:[],showTitle:!1,disabled:!1,disableGrid:!1,splitNumber:5,gridType:"solid",dashLength:4*e.pix,gridColor:"#cccccc",padding:10,fontColor:"#666666"},e.yAxis),e.xAxis=o({},{rotateLabel:!1,disabled:!1,disableGrid:!1,splitNumber:5,calibration:!1,gridType:"solid",dashLength:4,scrollAlign:"left",boundaryGap:"center",axisLine:!0,axisLineColor:"#cccccc"},e.xAxis),e.xAxis.scrollPosition=e.xAxis.scrollAlign,e.legend=o({},{show:!0,position:"bottom",float:"center",backgroundColor:"rgba(0,0,0,0)",borderColor:"rgba(0,0,0,0)",borderWidth:0,padding:5,margin:5,itemGap:10,fontSize:e.fontSize,lineHeight:e.fontSize,fontColor:e.fontColor,formatter:{},hiddenColor:"#CECECE"},e.legend),e.extra=o({},e.extra),e.rotate=!!e.rotate,e.animation=!!e.animation,e.rotate=!!e.rotate,e.canvas2d=!!e.canvas2d;var t=JSON.parse(JSON.stringify(i));if(t.color=e.color?e.color:t.color,t.yAxisTitleWidth=!0!==e.yAxis.disabled&&e.yAxis.title?t.yAxisTitleWidth:0,"pie"==e.type&&(t.pieChartLinePadding=!1===e.dataLabel?0:e.extra.pie.labelWidth*e.pix||t.pieChartLinePadding*e.pix),"ring"==e.type&&(t.pieChartLinePadding=!1===e.dataLabel?0:e.extra.ring.labelWidth*e.pix||t.pieChartLinePadding*e.pix),"rose"==e.type&&(t.pieChartLinePadding=!1===e.dataLabel?0:e.extra.rose.labelWidth*e.pix||t.pieChartLinePadding*e.pix),t.pieChartTextPadding=!1===e.dataLabel?0:t.pieChartTextPadding*e.pix,t.yAxisSplit=e.yAxis.splitNumber?e.yAxis.splitNumber:i.yAxisSplit,t.rotate=e.rotate,e.rotate){var n=e.width,r=e.height;e.width=r,e.height=n}if(e.padding=e.padding?e.padding:t.padding,t.yAxisWidth=i.yAxisWidth*e.pix,t.xAxisHeight=i.xAxisHeight*e.pix,e.enableScroll&&e.xAxis.scrollShow&&(t.xAxisHeight+=6*e.pix),t.xAxisLineHeight=i.xAxisLineHeight*e.pix,t.fontSize=e.fontSize*e.pix,t.titleFontSize=i.titleFontSize*e.pix,t.subtitleFontSize=i.subtitleFontSize*e.pix,t.toolTipPadding=i.toolTipPadding*e.pix,t.toolTipLineHeight=i.toolTipLineHeight*e.pix,t.columePadding=i.columePadding*e.pix,!e.context)throw new Error("[uCharts] 未获取到context注意v2.0版本后需要自行获取canvas的绘图上下文并传入opts.context");this.context=e.context,this.context.setTextAlign||(this.context.setStrokeStyle=function(e){return this.strokeStyle=e},this.context.setLineWidth=function(e){return this.lineWidth=e},this.context.setLineCap=function(e){return this.lineCap=e},this.context.setFontSize=function(e){return this.font=e+"px sans-serif"},this.context.setFillStyle=function(e){return this.fillStyle=e},this.context.setTextAlign=function(e){return this.textAlign=e},this.context.draw=function(){}),e.chartData={},this.uevent=new we,this.scrollOption={currentOffset:0,startTouchX:0,distance:0,lastMoveTime:0},this.opts=e,this.config=t,be.call(this,e.type,e,t,this.context)};ke.prototype.updateData=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.opts=o({},this.opts,e),this.opts.updateData=!0;var t=e.scrollPosition||"current";switch(t){case"current":break;case"left":this.opts._scrollDistance_=0,this.scrollOption={currentOffset:0,startTouchX:0,distance:0,lastMoveTime:0};break;case"right":var n=G(this.opts.series,this.opts,this.config,this.context),r=n.yAxisWidth;this.config.yAxisWidth=r;var i=0,a=W(this.opts.categories,this.opts,this.config),s=a.xAxisPoints,c=a.startX,u=a.endX,l=a.eachSpacing,f=l*(s.length-1),d=u-c;i=d-f,this.scrollOption={currentOffset:i,startTouchX:i,distance:0,lastMoveTime:0},this.opts._scrollDistance_=i;break}be.call(this,this.opts.type,this.opts,this.config,this.context)},ke.prototype.zoom=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.opts.xAxis.itemCount;if(!0===this.opts.enableScroll){var t=Math.round(Math.abs(this.scrollOption.currentOffset)/this.opts.chartData.eachSpacing)+Math.round(this.opts.xAxis.itemCount/2);this.opts.animation=!1,this.opts.xAxis.itemCount=e.itemCount;var n=G(this.opts.series,this.opts,this.config,this.context),r=n.yAxisWidth;this.config.yAxisWidth=r;var i=0,o=W(this.opts.categories,this.opts,this.config),a=o.xAxisPoints,s=o.startX,c=o.endX,u=o.eachSpacing,l=u*t,f=c-s,d=f-u*(a.length-1);i=f/2-l,i>0&&(i=0),i<d&&(i=d),this.scrollOption={currentOffset:i,startTouchX:i,distance:0,lastMoveTime:0},this.opts._scrollDistance_=i,be.call(this,this.opts.type,this.opts,this.config,this.context)}else console.log("[uCharts] 请启用滚动条后使用")},ke.prototype.stopAnimation=function(){this.animationInstance&&this.animationInstance.stop()},ke.prototype.addEventListener=function(e,t){this.uevent.addEventListener(e,t)},ke.prototype.delEventListener=function(e){this.uevent.delEventListener(e)},ke.prototype.getCurrentDataIndex=function(e){var t=null;if(t=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0],t){var n=_(t,this.opts,e);return"pie"===this.opts.type||"ring"===this.opts.type?function(e,t){var n=-1,r=M(t.series);if(t&&t.center&&C(e,t.center,t.radius)){var i=Math.atan2(t.center.y-e.y,e.x-t.center.x);i=-i;for(var o=0,a=r.length;o<a;o++)if(l(i,r[o]._start_,r[o]._start_+2*r[o]._proportion_*Math.PI)){n=o;break}}return n}({x:n.x,y:n.y},this.opts.chartData.pieData):"rose"===this.opts.type?function(e,t,n){var r=-1,i=j(n._series_,n.extra.rose.type,t.radius,t.radius);if(t&&t.center&&C(e,t.center,t.radius)){var o=Math.atan2(t.center.y-e.y,e.x-t.center.x);o=-o;for(var a=0,s=i.length;a<s;a++)if(l(o,i[a]._start_,i[a]._start_+2*i[a]._rose_proportion_*Math.PI)){r=a;break}}return r}({x:n.x,y:n.y},this.opts.chartData.pieData,this.opts):"radar"===this.opts.type?function(e,t,n){var r=2*Math.PI/n,i=-1;if(C(e,t.center,t.radius)){var o=function(e){return e<0&&(e+=2*Math.PI),e>2*Math.PI&&(e-=2*Math.PI),e},a=Math.atan2(t.center.y-e.y,e.x-t.center.x);a*=-1,a<0&&(a+=2*Math.PI);var s=t.angleList.map((function(e){return e=o(-1*e),e}));s.forEach((function(e,t){var n=o(e-r/2),s=o(e+r/2);s<n&&(s+=2*Math.PI),(a>=n&&a<=s||a+2*Math.PI>=n&&a+2*Math.PI<=s)&&(i=t)}))}return i}({x:n.x,y:n.y},this.opts.chartData.radarData,this.opts.categories.length):"funnel"===this.opts.type?function(e,t){for(var n=-1,r=0,i=t.series.length;r<i;r++){var o=t.series[r];if(e.x>o.funnelArea[0]&&e.x<o.funnelArea[2]&&e.y>o.funnelArea[1]&&e.y<o.funnelArea[3]){n=r;break}}return n}({x:n.x,y:n.y},this.opts.chartData.funnelData):"map"===this.opts.type?function(e,t){for(var n=-1,r=t.chartData.mapData,i=t.series,o=function(e,t,n,r,i,o){return{x:(t-i)/r+n.xMin,y:n.yMax-(e-o)/r}}(e.y,e.x,r.bounds,r.scale,r.xoffset,r.yoffset),a=[o.x,o.y],s=0,c=i.length;s<c;s++){var u=i[s].geometry.coordinates;if(ge(a,u,t.chartData.mapData.mercator)){n=s;break}}return n}({x:n.x,y:n.y},this.opts):"word"===this.opts.type?function(e,t){for(var n=-1,r=0,i=t.length;r<i;r++){var o=t[r];if(e.x>o.area[0]&&e.x<o.area[2]&&e.y>o.area[1]&&e.y<o.area[3]){n=r;break}}return n}({x:n.x,y:n.y},this.opts.chartData.wordCloudData):function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o={index:-1,group:[]},a=n.chartData.eachSpacing/2,s=[];if(t&&t.length>0){if(n.categories){for(var c=1;c<n.chartData.xAxisPoints.length;c++)s.push(n.chartData.xAxisPoints[c]-a);"line"!=n.type&&"area"!=n.type||"justify"!=n.xAxis.boundaryGap||(s=n.chartData.xAxisPoints)}else a=0;if(O(e,n,r))if(n.categories)s.forEach((function(t,n){e.x+i+a>t&&(o.index=n)}));else{for(var u=Array(t.length),l=0;l<t.length;l++){u[l]=Array(t[l].length);for(var f=0;f<t[l].length;f++)u[l][f]=Math.abs(t[l][f].x-e.x)}for(var d=Array(u.length),h=Array(u.length),p=0;p<u.length;p++)d[p]=Math.min.apply(null,u[p]),h[p]=u[p].indexOf(d[p]);var g=Math.min.apply(null,d);o.index=[];for(var v=0;v<d.length;v++)d[v]==g&&(o.group.push(v),o.index.push(h[v]))}}return o}({x:n.x,y:n.y},this.opts.chartData.calPoints,this.opts,this.config,Math.abs(this.scrollOption.currentOffset))}return-1},ke.prototype.getLegendDataIndex=function(e){var t=null;if(t=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0],t){var n=_(t,this.opts,e);return function(e,t,n){var r=-1;if(function(e,t){return e.x>t.start.x&&e.x<t.end.x&&e.y>t.start.y&&e.y<t.end.y}(e,t.area)){for(var i=t.points,o=-1,a=0,s=i.length;a<s;a++)for(var c=i[a],u=0;u<c.length;u++){o+=1;var l=c[u]["area"];if(l&&e.x>l[0]-0&&e.x<l[2]+0&&e.y>l[1]-0&&e.y<l[3]+0){r=o;break}}return r}return r}({x:n.x,y:n.y},this.opts.chartData.legendData)}return-1},ke.prototype.touchLegend=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null;if(n=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0],n){_(n,this.opts,e);var r=this.getLegendDataIndex(e);r>=0&&("candle"==this.opts.type?this.opts.seriesMA[r].show=!this.opts.seriesMA[r].show:this.opts.series[r].show=!this.opts.series[r].show,this.opts.animation=!!t.animation,this.opts._scrollDistance_=this.scrollOption.currentOffset,be.call(this,this.opts.type,this.opts,this.config,this.context))}},ke.prototype.showToolTip=function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null;r=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0],r||console.log("[uCharts] 未获取到event坐标信息");var i=_(r,this.opts,e),a=this.scrollOption.currentOffset,s=o({},this.opts,{_scrollDistance_:a,animation:!1});if("line"===this.opts.type||"area"===this.opts.type||"column"===this.opts.type||"scatter"===this.opts.type||"bubble"===this.opts.type){var c=this.getCurrentDataIndex(e),u=void 0==n.index?c.index:n.index;if(u>-1||u.length>0){var l=b(this.opts.series,u,c.group);if(0!==l.length){var f=A(l,this.opts,u,c.group,this.opts.categories,n),d=f.textList,h=f.offset;h.y=i.y,s.tooltip={textList:void 0!==n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}}be.call(this,s.type,s,this.config,this.context)}if("mix"===this.opts.type){c=this.getCurrentDataIndex(e),u=void 0==n.index?c.index:n.index;if(u>-1){a=this.scrollOption.currentOffset,s=o({},this.opts,{_scrollDistance_:a,animation:!1}),l=b(this.opts.series,u);if(0!==l.length){var p=S(l,this.opts,u,this.opts.categories,n);d=p.textList,h=p.offset;h.y=i.y,s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}}be.call(this,s.type,s,this.config,this.context)}if("candle"===this.opts.type){c=this.getCurrentDataIndex(e),u=void 0==n.index?c.index:n.index;if(u>-1){a=this.scrollOption.currentOffset,s=o({},this.opts,{_scrollDistance_:a,animation:!1}),l=b(this.opts.series,u);if(0!==l.length){f=P(this.opts.series[0].data,l,this.opts,u,this.opts.categories,this.opts.extra.candle,n),d=f.textList,h=f.offset;h.y=i.y,s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}}be.call(this,s.type,s,this.config,this.context)}if("pie"===this.opts.type||"ring"===this.opts.type||"rose"===this.opts.type||"funnel"===this.opts.type){u=void 0==n.index?this.getCurrentDataIndex(e):n.index;if(u>-1){s=o({},this.opts,{animation:!1}),l=o({},s._series_[u]),d=[{text:n.formatter?n.formatter(l,void 0,u,s):l.name+": "+l.data,color:l.color}],h={x:i.x,y:i.y};s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}be.call(this,s.type,s,this.config,this.context)}if("map"===this.opts.type){u=void 0==n.index?this.getCurrentDataIndex(e):n.index;if(u>-1){s=o({},this.opts,{animation:!1}),l=o({},this.opts.series[u]);l.name=l.properties.name;d=[{text:n.formatter?n.formatter(l,void 0,u,this.opts):l.name,color:l.color}],h={x:i.x,y:i.y};s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}s.updateData=!1,be.call(this,s.type,s,this.config,this.context)}if("word"===this.opts.type){u=void 0==n.index?this.getCurrentDataIndex(e):n.index;if(u>-1){s=o({},this.opts,{animation:!1}),l=o({},this.opts.series[u]),d=[{text:n.formatter?n.formatter(l,void 0,u,this.opts):l.name,color:l.color}],h={x:i.x,y:i.y};s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}s.updateData=!1,be.call(this,s.type,s,this.config,this.context)}if("radar"===this.opts.type){u=void 0==n.index?this.getCurrentDataIndex(e):n.index;if(u>-1){s=o({},this.opts,{animation:!1}),l=b(this.opts.series,u);if(0!==l.length){d=l.map((function(e){return{text:n.formatter?n.formatter(e,t.opts.categories[u],u,t.opts):e.name+": "+e.data,color:e.color}})),h={x:i.x,y:i.y};s.tooltip={textList:n.textList?n.textList:d,offset:void 0!==n.offset?n.offset:h,option:n,index:u}}}be.call(this,s.type,s,this.config,this.context)}},ke.prototype.translate=function(e){this.scrollOption={currentOffset:e,startTouchX:e,distance:0,lastMoveTime:0};var t=o({},this.opts,{_scrollDistance_:e,animation:!1});be.call(this,this.opts.type,t,this.config,this.context)},ke.prototype.scrollStart=function(e){var t=null;t=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0];var n=_(t,this.opts,e);t&&!0===this.opts.enableScroll&&(this.scrollOption.startTouchX=n.x)},ke.prototype.scroll=function(e){0===this.scrollOption.lastMoveTime&&(this.scrollOption.lastMoveTime=Date.now());var t=this.opts.touchMoveLimit||60,n=Date.now(),r=n-this.scrollOption.lastMoveTime;if(!(r<Math.floor(1e3/t))){this.scrollOption.lastMoveTime=n;var i=null;if(i=e.changedTouches?e.changedTouches[0]:e.mp.changedTouches[0],i&&!0===this.opts.enableScroll){var a,s=_(i,this.opts,e);a=s.x-this.scrollOption.startTouchX;var c=this.scrollOption.currentOffset,u=function(e,t,n,r,i){var o=i.width-i.area[1]-i.area[3],a=n.eachSpacing*(i.chartData.xAxisData.xAxisPoints.length-1),s=t;return t>=0?(s=0,e.uevent.trigger("scrollLeft"),e.scrollOption.position="left",i.xAxis.scrollPosition="left"):Math.abs(t)>=a-o?(s=o-a,e.uevent.trigger("scrollRight"),e.scrollOption.position="right",i.xAxis.scrollPosition="right"):(e.scrollOption.position=t,i.xAxis.scrollPosition=t),s}(this,c+a,this.opts.chartData,this.config,this.opts);this.scrollOption.distance=a=u-c;var l=o({},this.opts,{_scrollDistance_:c+a,animation:!1});return this.opts=l,be.call(this,l.type,l,this.config,this.context),c+a}}},ke.prototype.scrollEnd=function(e){if(!0===this.opts.enableScroll){var t=this.scrollOption,n=t.currentOffset,r=t.distance;this.scrollOption.currentOffset=n+r,this.scrollOption.distance=0}},"object"===r(e)&&"object"===r(e.exports)&&(e.exports=ke)}).call(this,n("dc84")(e))},5339:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={appid:"__UNI__9A0614A"}},"60a4":function(e,t,n){},6382:function(e,t,n){var r=n("6454");e.exports=function(e,t){if(e){if("string"===typeof e)return r(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(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports["default"]=e.exports},6454:function(e,t){e.exports=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},e.exports.__esModule=!0,e.exports["default"]=e.exports},"67ad":function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports["default"]=e.exports},"6caf":function(e,t){},7172:function(e,t){e.exports=function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],c=!0,u=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=n["return"]&&(a=n["return"](),Object(a)!==a))return}finally{if(u)throw i}}return s}},e.exports.__esModule=!0,e.exports["default"]=e.exports},"749e":function(e,t,n){"use strict";(function(e){var r=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n("069d")),o=(r(n("b3c9")),r(n("3e50"))),a="https://tc.pcxbc.com",s=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"get",r=arguments.length>2?arguments[2]:void 0,o={url:a+t,data:r,method:n,header:{"X-Requested-With":"XMLHttpRequest","content-type":"application/json;charset=UTF-8"}},s=new Promise((function(t,n){e.request(o).then((function(n){if(e.hideLoading(),20001==n[1].data.code)return e.clearStorageSync(),e.setStorageSync("token",null),void setTimeout((function(){e.reLaunch({url:"/pageTwo/login/login"})}),2e3);200==n[1].statusCode?t(n[1].data):i.default.msg(n[1].data.msg)})).catch((function(t){e.hideLoading(),n(t)}))}));return s};var c={baseUrl:a,get:function(t,n){return n.token=e.getStorageSync("token")?e.getStorageSync("token"):"",s(t,"get",n)},post:function(t,n){return n.token=e.getStorageSync("token")?e.getStorageSync("token"):"",s(t,"post",n)},upload:function(t,n){return function(t,n){o.default.log;var r=new Promise((function(r,o){e.uploadFile({url:a+t,filePath:n.uploadpath.tempFilePath,name:"image",formData:{token:e.getStorageSync("token")}}).then((function(e){if(200==e[1].statusCode){var t=JSON.parse(e[1].data);if(0!=t.code)return void i.default.msg(t.message);r(t)}}))}));return r}(t,n)}};t.default=c}).call(this,n("df3c")["default"])},"74c4":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={id:"2852637",name:"uniui图标库",font_family:"uniicons",css_prefix_text:"uniui-",description:"",glyphs:[{icon_id:"25027049",name:"yanse",font_class:"color",unicode:"e6cf",unicode_decimal:59087},{icon_id:"25027048",name:"wallet",font_class:"wallet",unicode:"e6b1",unicode_decimal:59057},{icon_id:"25015720",name:"settings-filled",font_class:"settings-filled",unicode:"e6ce",unicode_decimal:59086},{icon_id:"25015434",name:"shimingrenzheng-filled",font_class:"auth-filled",unicode:"e6cc",unicode_decimal:59084},{icon_id:"24934246",name:"shop-filled",font_class:"shop-filled",unicode:"e6cd",unicode_decimal:59085},{icon_id:"24934159",name:"staff-filled-01",font_class:"staff-filled",unicode:"e6cb",unicode_decimal:59083},{icon_id:"24932461",name:"VIP-filled",font_class:"vip-filled",unicode:"e6c6",unicode_decimal:59078},{icon_id:"24932462",name:"plus_circle_fill",font_class:"plus-filled",unicode:"e6c7",unicode_decimal:59079},{icon_id:"24932463",name:"folder_add-filled",font_class:"folder-add-filled",unicode:"e6c8",unicode_decimal:59080},{icon_id:"24932464",name:"yanse-filled",font_class:"color-filled",unicode:"e6c9",unicode_decimal:59081},{icon_id:"24932465",name:"tune-filled",font_class:"tune-filled",unicode:"e6ca",unicode_decimal:59082},{icon_id:"24932455",name:"a-rilidaka-filled",font_class:"calendar-filled",unicode:"e6c0",unicode_decimal:59072},{icon_id:"24932456",name:"notification-filled",font_class:"notification-filled",unicode:"e6c1",unicode_decimal:59073},{icon_id:"24932457",name:"wallet-filled",font_class:"wallet-filled",unicode:"e6c2",unicode_decimal:59074},{icon_id:"24932458",name:"paihangbang-filled",font_class:"medal-filled",unicode:"e6c3",unicode_decimal:59075},{icon_id:"24932459",name:"gift-filled",font_class:"gift-filled",unicode:"e6c4",unicode_decimal:59076},{icon_id:"24932460",name:"fire-filled",font_class:"fire-filled",unicode:"e6c5",unicode_decimal:59077},{icon_id:"24928001",name:"refreshempty",font_class:"refreshempty",unicode:"e6bf",unicode_decimal:59071},{icon_id:"24926853",name:"location-ellipse",font_class:"location-filled",unicode:"e6af",unicode_decimal:59055},{icon_id:"24926735",name:"person-filled",font_class:"person-filled",unicode:"e69d",unicode_decimal:59037},{icon_id:"24926703",name:"personadd-filled",font_class:"personadd-filled",unicode:"e698",unicode_decimal:59032},{icon_id:"24923351",name:"back",font_class:"back",unicode:"e6b9",unicode_decimal:59065},{icon_id:"24923352",name:"forward",font_class:"forward",unicode:"e6ba",unicode_decimal:59066},{icon_id:"24923353",name:"arrowthinright",font_class:"arrow-right",unicode:"e6bb",unicode_decimal:59067},{icon_id:"24923353",name:"arrowthinright",font_class:"arrowthinright",unicode:"e6bb",unicode_decimal:59067},{icon_id:"24923354",name:"arrowthinleft",font_class:"arrow-left",unicode:"e6bc",unicode_decimal:59068},{icon_id:"24923354",name:"arrowthinleft",font_class:"arrowthinleft",unicode:"e6bc",unicode_decimal:59068},{icon_id:"24923355",name:"arrowthinup",font_class:"arrow-up",unicode:"e6bd",unicode_decimal:59069},{icon_id:"24923355",name:"arrowthinup",font_class:"arrowthinup",unicode:"e6bd",unicode_decimal:59069},{icon_id:"24923356",name:"arrowthindown",font_class:"arrow-down",unicode:"e6be",unicode_decimal:59070},{icon_id:"24923356",name:"arrowthindown",font_class:"arrowthindown",unicode:"e6be",unicode_decimal:59070},{icon_id:"24923349",name:"arrowdown",font_class:"bottom",unicode:"e6b8",unicode_decimal:59064},{icon_id:"24923349",name:"arrowdown",font_class:"arrowdown",unicode:"e6b8",unicode_decimal:59064},{icon_id:"24923346",name:"arrowright",font_class:"right",unicode:"e6b5",unicode_decimal:59061},{icon_id:"24923346",name:"arrowright",font_class:"arrowright",unicode:"e6b5",unicode_decimal:59061},{icon_id:"24923347",name:"arrowup",font_class:"top",unicode:"e6b6",unicode_decimal:59062},{icon_id:"24923347",name:"arrowup",font_class:"arrowup",unicode:"e6b6",unicode_decimal:59062},{icon_id:"24923348",name:"arrowleft",font_class:"left",unicode:"e6b7",unicode_decimal:59063},{icon_id:"24923348",name:"arrowleft",font_class:"arrowleft",unicode:"e6b7",unicode_decimal:59063},{icon_id:"24923334",name:"eye",font_class:"eye",unicode:"e651",unicode_decimal:58961},{icon_id:"24923335",name:"eye-filled",font_class:"eye-filled",unicode:"e66a",unicode_decimal:58986},{icon_id:"24923336",name:"eye-slash",font_class:"eye-slash",unicode:"e6b3",unicode_decimal:59059},{icon_id:"24923337",name:"eye-slash-filled",font_class:"eye-slash-filled",unicode:"e6b4",unicode_decimal:59060},{icon_id:"24923305",name:"info-filled",font_class:"info-filled",unicode:"e649",unicode_decimal:58953},{icon_id:"24923299",name:"reload-01",font_class:"reload",unicode:"e6b2",unicode_decimal:59058},{icon_id:"24923195",name:"mic_slash_fill",font_class:"micoff-filled",unicode:"e6b0",unicode_decimal:59056},{icon_id:"24923165",name:"map-pin-ellipse",font_class:"map-pin-ellipse",unicode:"e6ac",unicode_decimal:59052},{icon_id:"24923166",name:"map-pin",font_class:"map-pin",unicode:"e6ad",unicode_decimal:59053},{icon_id:"24923167",name:"location",font_class:"location",unicode:"e6ae",unicode_decimal:59054},{icon_id:"24923064",name:"starhalf",font_class:"starhalf",unicode:"e683",unicode_decimal:59011},{icon_id:"24923065",name:"star",font_class:"star",unicode:"e688",unicode_decimal:59016},{icon_id:"24923066",name:"star-filled",font_class:"star-filled",unicode:"e68f",unicode_decimal:59023},{icon_id:"24899646",name:"a-rilidaka",font_class:"calendar",unicode:"e6a0",unicode_decimal:59040},{icon_id:"24899647",name:"fire",font_class:"fire",unicode:"e6a1",unicode_decimal:59041},{icon_id:"24899648",name:"paihangbang",font_class:"medal",unicode:"e6a2",unicode_decimal:59042},{icon_id:"24899649",name:"font",font_class:"font",unicode:"e6a3",unicode_decimal:59043},{icon_id:"24899650",name:"gift",font_class:"gift",unicode:"e6a4",unicode_decimal:59044},{icon_id:"24899651",name:"link",font_class:"link",unicode:"e6a5",unicode_decimal:59045},{icon_id:"24899652",name:"notification",font_class:"notification",unicode:"e6a6",unicode_decimal:59046},{icon_id:"24899653",name:"staff",font_class:"staff",unicode:"e6a7",unicode_decimal:59047},{icon_id:"24899654",name:"VIP",font_class:"vip",unicode:"e6a8",unicode_decimal:59048},{icon_id:"24899655",name:"folder_add",font_class:"folder-add",unicode:"e6a9",unicode_decimal:59049},{icon_id:"24899656",name:"tune",font_class:"tune",unicode:"e6aa",unicode_decimal:59050},{icon_id:"24899657",name:"shimingrenzheng",font_class:"auth",unicode:"e6ab",unicode_decimal:59051},{icon_id:"24899565",name:"person",font_class:"person",unicode:"e699",unicode_decimal:59033},{icon_id:"24899566",name:"email-filled",font_class:"email-filled",unicode:"e69a",unicode_decimal:59034},{icon_id:"24899567",name:"phone-filled",font_class:"phone-filled",unicode:"e69b",unicode_decimal:59035},{icon_id:"24899568",name:"phone",font_class:"phone",unicode:"e69c",unicode_decimal:59036},{icon_id:"24899570",name:"email",font_class:"email",unicode:"e69e",unicode_decimal:59038},{icon_id:"24899571",name:"personadd",font_class:"personadd",unicode:"e69f",unicode_decimal:59039},{icon_id:"24899558",name:"chatboxes-filled",font_class:"chatboxes-filled",unicode:"e692",unicode_decimal:59026},{icon_id:"24899559",name:"contact",font_class:"contact",unicode:"e693",unicode_decimal:59027},{icon_id:"24899560",name:"chatbubble-filled",font_class:"chatbubble-filled",unicode:"e694",unicode_decimal:59028},{icon_id:"24899561",name:"contact-filled",font_class:"contact-filled",unicode:"e695",unicode_decimal:59029},{icon_id:"24899562",name:"chatboxes",font_class:"chatboxes",unicode:"e696",unicode_decimal:59030},{icon_id:"24899563",name:"chatbubble",font_class:"chatbubble",unicode:"e697",unicode_decimal:59031},{icon_id:"24881290",name:"upload-filled",font_class:"upload-filled",unicode:"e68e",unicode_decimal:59022},{icon_id:"24881292",name:"upload",font_class:"upload",unicode:"e690",unicode_decimal:59024},{icon_id:"24881293",name:"weixin",font_class:"weixin",unicode:"e691",unicode_decimal:59025},{icon_id:"24881274",name:"compose",font_class:"compose",unicode:"e67f",unicode_decimal:59007},{icon_id:"24881275",name:"qq",font_class:"qq",unicode:"e680",unicode_decimal:59008},{icon_id:"24881276",name:"download-filled",font_class:"download-filled",unicode:"e681",unicode_decimal:59009},{icon_id:"24881277",name:"pengyouquan",font_class:"pyq",unicode:"e682",unicode_decimal:59010},{icon_id:"24881279",name:"sound",font_class:"sound",unicode:"e684",unicode_decimal:59012},{icon_id:"24881280",name:"trash-filled",font_class:"trash-filled",unicode:"e685",unicode_decimal:59013},{icon_id:"24881281",name:"sound-filled",font_class:"sound-filled",unicode:"e686",unicode_decimal:59014},{icon_id:"24881282",name:"trash",font_class:"trash",unicode:"e687",unicode_decimal:59015},{icon_id:"24881284",name:"videocam-filled",font_class:"videocam-filled",unicode:"e689",unicode_decimal:59017},{icon_id:"24881285",name:"spinner-cycle",font_class:"spinner-cycle",unicode:"e68a",unicode_decimal:59018},{icon_id:"24881286",name:"weibo",font_class:"weibo",unicode:"e68b",unicode_decimal:59019},{icon_id:"24881288",name:"videocam",font_class:"videocam",unicode:"e68c",unicode_decimal:59020},{icon_id:"24881289",name:"download",font_class:"download",unicode:"e68d",unicode_decimal:59021},{icon_id:"24879601",name:"help",font_class:"help",unicode:"e679",unicode_decimal:59001},{icon_id:"24879602",name:"navigate-filled",font_class:"navigate-filled",unicode:"e67a",unicode_decimal:59002},{icon_id:"24879603",name:"plusempty",font_class:"plusempty",unicode:"e67b",unicode_decimal:59003},{icon_id:"24879604",name:"smallcircle",font_class:"smallcircle",unicode:"e67c",unicode_decimal:59004},{icon_id:"24879605",name:"minus-filled",font_class:"minus-filled",unicode:"e67d",unicode_decimal:59005},{icon_id:"24879606",name:"micoff",font_class:"micoff",unicode:"e67e",unicode_decimal:59006},{icon_id:"24879588",name:"closeempty",font_class:"closeempty",unicode:"e66c",unicode_decimal:58988},{icon_id:"24879589",name:"clear",font_class:"clear",unicode:"e66d",unicode_decimal:58989},{icon_id:"24879590",name:"navigate",font_class:"navigate",unicode:"e66e",unicode_decimal:58990},{icon_id:"24879591",name:"minus",font_class:"minus",unicode:"e66f",unicode_decimal:58991},{icon_id:"24879592",name:"image",font_class:"image",unicode:"e670",unicode_decimal:58992},{icon_id:"24879593",name:"mic",font_class:"mic",unicode:"e671",unicode_decimal:58993},{icon_id:"24879594",name:"paperplane",font_class:"paperplane",unicode:"e672",unicode_decimal:58994},{icon_id:"24879595",name:"close",font_class:"close",unicode:"e673",unicode_decimal:58995},{icon_id:"24879596",name:"help-filled",font_class:"help-filled",unicode:"e674",unicode_decimal:58996},{icon_id:"24879597",name:"plus-filled",font_class:"paperplane-filled",unicode:"e675",unicode_decimal:58997},{icon_id:"24879598",name:"plus",font_class:"plus",unicode:"e676",unicode_decimal:58998},{icon_id:"24879599",name:"mic-filled",font_class:"mic-filled",unicode:"e677",unicode_decimal:58999},{icon_id:"24879600",name:"image-filled",font_class:"image-filled",unicode:"e678",unicode_decimal:59e3},{icon_id:"24855900",name:"locked-filled",font_class:"locked-filled",unicode:"e668",unicode_decimal:58984},{icon_id:"24855901",name:"info",font_class:"info",unicode:"e669",unicode_decimal:58985},{icon_id:"24855903",name:"locked",font_class:"locked",unicode:"e66b",unicode_decimal:58987},{icon_id:"24855884",name:"camera-filled",font_class:"camera-filled",unicode:"e658",unicode_decimal:58968},{icon_id:"24855885",name:"chat-filled",font_class:"chat-filled",unicode:"e659",unicode_decimal:58969},{icon_id:"24855886",name:"camera",font_class:"camera",unicode:"e65a",unicode_decimal:58970},{icon_id:"24855887",name:"circle",font_class:"circle",unicode:"e65b",unicode_decimal:58971},{icon_id:"24855888",name:"checkmarkempty",font_class:"checkmarkempty",unicode:"e65c",unicode_decimal:58972},{icon_id:"24855889",name:"chat",font_class:"chat",unicode:"e65d",unicode_decimal:58973},{icon_id:"24855890",name:"circle-filled",font_class:"circle-filled",unicode:"e65e",unicode_decimal:58974},{icon_id:"24855891",name:"flag",font_class:"flag",unicode:"e65f",unicode_decimal:58975},{icon_id:"24855892",name:"flag-filled",font_class:"flag-filled",unicode:"e660",unicode_decimal:58976},{icon_id:"24855893",name:"gear-filled",font_class:"gear-filled",unicode:"e661",unicode_decimal:58977},{icon_id:"24855894",name:"home",font_class:"home",unicode:"e662",unicode_decimal:58978},{icon_id:"24855895",name:"home-filled",font_class:"home-filled",unicode:"e663",unicode_decimal:58979},{icon_id:"24855896",name:"gear",font_class:"gear",unicode:"e664",unicode_decimal:58980},{icon_id:"24855897",name:"smallcircle-filled",font_class:"smallcircle-filled",unicode:"e665",unicode_decimal:58981},{icon_id:"24855898",name:"map-filled",font_class:"map-filled",unicode:"e666",unicode_decimal:58982},{icon_id:"24855899",name:"map",font_class:"map",unicode:"e667",unicode_decimal:58983},{icon_id:"24855825",name:"refresh-filled",font_class:"refresh-filled",unicode:"e656",unicode_decimal:58966},{icon_id:"24855826",name:"refresh",font_class:"refresh",unicode:"e657",unicode_decimal:58967},{icon_id:"24855808",name:"cloud-upload",font_class:"cloud-upload",unicode:"e645",unicode_decimal:58949},{icon_id:"24855809",name:"cloud-download-filled",font_class:"cloud-download-filled",unicode:"e646",unicode_decimal:58950},{icon_id:"24855810",name:"cloud-download",font_class:"cloud-download",unicode:"e647",unicode_decimal:58951},{icon_id:"24855811",name:"cloud-upload-filled",font_class:"cloud-upload-filled",unicode:"e648",unicode_decimal:58952},{icon_id:"24855813",name:"redo",font_class:"redo",unicode:"e64a",unicode_decimal:58954},{icon_id:"24855814",name:"images-filled",font_class:"images-filled",unicode:"e64b",unicode_decimal:58955},{icon_id:"24855815",name:"undo-filled",font_class:"undo-filled",unicode:"e64c",unicode_decimal:58956},{icon_id:"24855816",name:"more",font_class:"more",unicode:"e64d",unicode_decimal:58957},{icon_id:"24855817",name:"more-filled",font_class:"more-filled",unicode:"e64e",unicode_decimal:58958},{icon_id:"24855818",name:"undo",font_class:"undo",unicode:"e64f",unicode_decimal:58959},{icon_id:"24855819",name:"images",font_class:"images",unicode:"e650",unicode_decimal:58960},{icon_id:"24855821",name:"paperclip",font_class:"paperclip",unicode:"e652",unicode_decimal:58962},{icon_id:"24855822",name:"settings",font_class:"settings",unicode:"e653",unicode_decimal:58963},{icon_id:"24855823",name:"search",font_class:"search",unicode:"e654",unicode_decimal:58964},{icon_id:"24855824",name:"redo-filled",font_class:"redo-filled",unicode:"e655",unicode_decimal:58965},{icon_id:"24841702",name:"list",font_class:"list",unicode:"e644",unicode_decimal:58948},{icon_id:"24841489",name:"mail-open-filled",font_class:"mail-open-filled",unicode:"e63a",unicode_decimal:58938},{icon_id:"24841491",name:"hand-thumbsdown-filled",font_class:"hand-down-filled",unicode:"e63c",unicode_decimal:58940},{icon_id:"24841492",name:"hand-thumbsdown",font_class:"hand-down",unicode:"e63d",unicode_decimal:58941},{icon_id:"24841493",name:"hand-thumbsup-filled",font_class:"hand-up-filled",unicode:"e63e",unicode_decimal:58942},{icon_id:"24841494",name:"hand-thumbsup",font_class:"hand-up",unicode:"e63f",unicode_decimal:58943},{icon_id:"24841496",name:"heart-filled",font_class:"heart-filled",unicode:"e641",unicode_decimal:58945},{icon_id:"24841498",name:"mail-open",font_class:"mail-open",unicode:"e643",unicode_decimal:58947},{icon_id:"24841488",name:"heart",font_class:"heart",unicode:"e639",unicode_decimal:58937},{icon_id:"24839963",name:"loop",font_class:"loop",unicode:"e633",unicode_decimal:58931},{icon_id:"24839866",name:"pulldown",font_class:"pulldown",unicode:"e632",unicode_decimal:58930},{icon_id:"24813798",name:"scan",font_class:"scan",unicode:"e62a",unicode_decimal:58922},{icon_id:"24813786",name:"bars",font_class:"bars",unicode:"e627",unicode_decimal:58919},{icon_id:"24813788",name:"cart-filled",font_class:"cart-filled",unicode:"e629",unicode_decimal:58921},{icon_id:"24813790",name:"checkbox",font_class:"checkbox",unicode:"e62b",unicode_decimal:58923},{icon_id:"24813791",name:"checkbox-filled",font_class:"checkbox-filled",unicode:"e62c",unicode_decimal:58924},{icon_id:"24813794",name:"shop",font_class:"shop",unicode:"e62f",unicode_decimal:58927},{icon_id:"24813795",name:"headphones",font_class:"headphones",unicode:"e630",unicode_decimal:58928},{icon_id:"24813796",name:"cart",font_class:"cart",unicode:"e631",unicode_decimal:58929}]}},7647:function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports["default"]=e.exports,n(t,r)}e.exports=n,e.exports.__esModule=!0,e.exports["default"]=e.exports},"7ca3":function(e,t,n){var r=n("d551");e.exports=function(e,t,n){return t=r(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports["default"]=e.exports},"7ce1":function(e,t,n){var r=n("b4d2"),i=n("7647"),o=n("4965"),a=n("931d");function s(t){var n="function"===typeof Map?new Map:void 0;return e.exports=s=function(e){if(null===e||!o(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof n){if(n.has(e))return n.get(e);n.set(e,t)}function t(){return a(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},e.exports.__esModule=!0,e.exports["default"]=e.exports,s(t)}e.exports=s,e.exports.__esModule=!0,e.exports["default"]=e.exports},"7eb4":function(e,t,n){var r=n("9fc1")();e.exports=r},"828b":function(e,t,n){"use strict";function r(e,t,n,r,i,o,a,s,c,u){var l,f="function"===typeof e?e.options:e;if(c){f.components||(f.components={});var d=Object.prototype.hasOwnProperty;for(var h in c)d.call(c,h)&&!d.call(f.components,h)&&(f.components[h]=c[h])}if(u&&("function"===typeof u.beforeCreate&&(u.beforeCreate=[u.beforeCreate]),(u.beforeCreate||(u.beforeCreate=[])).unshift((function(){this[u.__module]=this})),(f.mixins||(f.mixins=[])).push(u)),t&&(f.render=t,f.staticRenderFns=n,f._compiled=!0),r&&(f.functional=!0),o&&(f._scopeId="data-v-"+o),a?(l=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"===typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},f._ssrRegister=l):i&&(l=s?function(){i.call(this,this.$root.$options.shadowRoot)}:i),l)if(f.functional){f._injectStyles=l;var p=f.render;f.render=function(e,t){return l.call(t),p(e,t)}}else{var g=f.beforeCreate;f.beforeCreate=g?[].concat(g,l):[l]}return{exports:e,options:f}}n.d(t,"a",(function(){return r}))},8419:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={pages:[{path:"pages/index/index",style:{navigationBarTitleText:"首页",enablePullDownRefresh:!0}},{path:"pages/menu/menu",style:{navigationBarTitleText:"菜谱",enablePullDownRefresh:!0}},{path:"pages/add/add",style:{navigationBarTitleText:"添加食谱",enablePullDownRefresh:!1}},{path:"pages/count/count",style:{navigationBarTitleText:"计食器",enablePullDownRefresh:!1}},{path:"pages/me/me",style:{navigationBarTitleText:"个人中心",enablePullDownRefresh:!1}},{path:"pages/add/Preview",style:{navigationBarTitleText:""}},{path:"pages/search/search",style:{navigationBarTitleText:"搜索"}}],subPackages:[{root:"pageTwo",pages:[{path:"login/forgetPassword",style:{navigationBarTitleText:"密码",enablePullDownRefresh:!1}},{path:"login/login",style:{navigationBarTitleText:"登录",enablePullDownRefresh:!1,navigationStyle:"custom"}},{path:"me/feedBack",style:{navigationBarTitleText:"意见反馈",navigationBarBackgroundColor:"#F9FAFC"}},{path:"me/userEdit",style:{navigationBarTitleText:"个人资料",navigationBarBackgroundColor:"#F9FAFC"}},{path:"me/record",style:{navigationBarTitleText:"饮食记录",enablePullDownRefresh:!1}},{path:"me/mymenu",style:{navigationBarTitleText:"",enablePullDownRefresh:!1}},{path:"me/menudetail",style:{navigationBarTitleText:"详情",enablePullDownRefresh:!1}},{path:"me/foodlist",style:{navigationBarTitleText:"食材库",enablePullDownRefresh:!0}},{path:"count/setting",style:{navigationBarTitleText:"设置",enablePullDownRefresh:!1}},{path:"count/KcalEdit",style:{navigationBarTitleText:"自定义卡路里",enablePullDownRefresh:!1}},{path:"count/food",style:{navigationBarTitleText:"食材库",enablePullDownRefresh:!1}},{path:"webview/webview",style:{navigationBarTitleText:"",enablePullDownRefresh:!1}},{path:"setting/setting",style:{navigationBarTitleText:"设置",enablePullDownRefresh:!1}},{path:"setting/password",style:{navigationBarTitleText:"修改密码",enablePullDownRefresh:!1}},{path:"setting/email",style:{navigationBarTitleText:"绑定邮箱",enablePullDownRefresh:!1}},{path:"setting/phone",style:{navigationBarTitleText:"绑定手机号",enablePullDownRefresh:!1}},{path:"me/menuEdit",style:{navigationBarTitleText:""}}]}],globalStyle:{navigationBarTextStyle:"black",navigationBarTitleText:"uni-app",navigationBarBackgroundColor:"#efefef",backgroundColor:"#efefef"},tabBar:{color:"#333",selectedColor:"#ff4c4f",backgroundColor:"#fff",list:[{pagePath:"pages/index/index",iconPath:"static/home.png",selectedIconPath:"static/home01.png",text:"首页"},{pagePath:"pages/menu/menu",iconPath:"static/cai.png",selectedIconPath:"static/cai01.png",text:"菜谱"},{pagePath:"pages/add/add",iconPath:"static/add.png",selectedIconPath:"static/add.png",text:""},{pagePath:"pages/count/count",iconPath:"static/ji.png",selectedIconPath:"static/ji01.png",text:"计食器"},{pagePath:"pages/me/me",iconPath:"static/me.png",selectedIconPath:"static/me01.png",text:"我的"}]},uniIdRouter:{}}},"861b":function(e,t,n){"use strict";(function(e,r,i){var o=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.uniCloud=t.default=t.UniCloudError=void 0;var a=o(n("7eb4")),s=o(n("3352")),c=o(n("34cf")),u=o(n("3b2d")),l=o(n("af34")),f=o(n("ee10")),d=o(n("7ca3")),h=o(n("8ffa")),p=o(n("4ffb")),g=o(n("b4d2")),v=o(n("7ce1")),y=o(n("67ad")),m=o(n("0bdb")),x=o(n("8419"));function _(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return b(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(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return b(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}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 o,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function b(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}function w(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 k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){(0,d.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function A(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,g.default)(e);if(t){var i=(0,g.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,p.default)(this,n)}}function S(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&n.path)}},n.exports),n.exports}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof e||"undefined"!=typeof self&&self;var P=S((function(e,t){var n;e.exports=(n=n||function(e,t){var n=Object.create||function(){function e(){}return function(t){var n;return e.prototype=t,n=new e,e.prototype=null,n}}(),r={},i=r.lib={},o=i.Base={extend:function(e){var t=n(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},a=i.WordArray=o.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=void 0!=t?t:4*e.length},toString:function(e){return(e||c).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;if(this.clamp(),r%4)for(var o=0;o<i;o++){var a=n[o>>>2]>>>24-o%4*8&255;t[r+o>>>2]|=a<<24-(r+o)%4*8}else for(o=0;o<i;o+=4)t[r+o>>>2]=n[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n,r=[],i=function(t){var n=987654321,r=4294967295;return function(){var i=((n=36969*(65535&n)+(n>>16)&r)<<16)+(t=18e3*(65535&t)+(t>>16)&r)&r;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o<t;o+=4){var s=i(4294967296*(n||e.random()));n=987654071*s(),r.push(4294967296*s()|0)}return new a.init(r,t)}}),s=r.enc={},c=s.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push((o>>>4).toString(16)),r.push((15&o).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new a.init(n,t/2)}},u=s.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(o))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new a.init(n,t)}},l=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(u.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return u.parse(unescape(encodeURIComponent(e)))}},f=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=l.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,i=n.sigBytes,o=this.blockSize,s=i/(4*o),c=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,u=e.min(4*c,i);if(c){for(var l=0;l<c;l+=o)this._doProcessBlock(r,l);var f=r.splice(0,c);n.sigBytes-=u}return new a.init(f,u)},clone:function(){var e=o.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});i.Hasher=f.extend({cfg:o.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){f.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new d.HMAC.init(e,n).finalize(t)}}});var d=r.algo={};return r}(Math),n)})),T=P,O=(S((function(e,t){var n;e.exports=(n=T,function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[];!function(){for(var t=0;t<64;t++)s[t]=4294967296*e.abs(e.sin(t+1))|0}();var c=a.MD5=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var r=t+n,i=e[r];e[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,a=e[t+0],c=e[t+1],h=e[t+2],p=e[t+3],g=e[t+4],v=e[t+5],y=e[t+6],m=e[t+7],x=e[t+8],_=e[t+9],b=e[t+10],w=e[t+11],k=e[t+12],A=e[t+13],S=e[t+14],P=e[t+15],T=o[0],O=o[1],C=o[2],L=o[3];T=u(T,O,C,L,a,7,s[0]),L=u(L,T,O,C,c,12,s[1]),C=u(C,L,T,O,h,17,s[2]),O=u(O,C,L,T,p,22,s[3]),T=u(T,O,C,L,g,7,s[4]),L=u(L,T,O,C,v,12,s[5]),C=u(C,L,T,O,y,17,s[6]),O=u(O,C,L,T,m,22,s[7]),T=u(T,O,C,L,x,7,s[8]),L=u(L,T,O,C,_,12,s[9]),C=u(C,L,T,O,b,17,s[10]),O=u(O,C,L,T,w,22,s[11]),T=u(T,O,C,L,k,7,s[12]),L=u(L,T,O,C,A,12,s[13]),C=u(C,L,T,O,S,17,s[14]),T=l(T,O=u(O,C,L,T,P,22,s[15]),C,L,c,5,s[16]),L=l(L,T,O,C,y,9,s[17]),C=l(C,L,T,O,w,14,s[18]),O=l(O,C,L,T,a,20,s[19]),T=l(T,O,C,L,v,5,s[20]),L=l(L,T,O,C,b,9,s[21]),C=l(C,L,T,O,P,14,s[22]),O=l(O,C,L,T,g,20,s[23]),T=l(T,O,C,L,_,5,s[24]),L=l(L,T,O,C,S,9,s[25]),C=l(C,L,T,O,p,14,s[26]),O=l(O,C,L,T,x,20,s[27]),T=l(T,O,C,L,A,5,s[28]),L=l(L,T,O,C,h,9,s[29]),C=l(C,L,T,O,m,14,s[30]),T=f(T,O=l(O,C,L,T,k,20,s[31]),C,L,v,4,s[32]),L=f(L,T,O,C,x,11,s[33]),C=f(C,L,T,O,w,16,s[34]),O=f(O,C,L,T,S,23,s[35]),T=f(T,O,C,L,c,4,s[36]),L=f(L,T,O,C,g,11,s[37]),C=f(C,L,T,O,m,16,s[38]),O=f(O,C,L,T,b,23,s[39]),T=f(T,O,C,L,A,4,s[40]),L=f(L,T,O,C,a,11,s[41]),C=f(C,L,T,O,p,16,s[42]),O=f(O,C,L,T,y,23,s[43]),T=f(T,O,C,L,_,4,s[44]),L=f(L,T,O,C,k,11,s[45]),C=f(C,L,T,O,P,16,s[46]),T=d(T,O=f(O,C,L,T,h,23,s[47]),C,L,a,6,s[48]),L=d(L,T,O,C,m,10,s[49]),C=d(C,L,T,O,S,15,s[50]),O=d(O,C,L,T,v,21,s[51]),T=d(T,O,C,L,k,6,s[52]),L=d(L,T,O,C,p,10,s[53]),C=d(C,L,T,O,b,15,s[54]),O=d(O,C,L,T,c,21,s[55]),T=d(T,O,C,L,x,6,s[56]),L=d(L,T,O,C,P,10,s[57]),C=d(C,L,T,O,y,15,s[58]),O=d(O,C,L,T,A,21,s[59]),T=d(T,O,C,L,g,6,s[60]),L=d(L,T,O,C,w,10,s[61]),C=d(C,L,T,O,h,15,s[62]),O=d(O,C,L,T,_,21,s[63]),o[0]=o[0]+T|0,o[1]=o[1]+O|0,o[2]=o[2]+C|0,o[3]=o[3]+L|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,i=8*t.sigBytes;n[i>>>5]|=128<<24-i%32;var o=e.floor(r/4294967296),a=r;n[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),n[14+(i+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),t.sigBytes=4*(n.length+1),this._process();for(var s=this._hash,c=s.words,u=0;u<4;u++){var l=c[u];c[u]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return s},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function u(e,t,n,r,i,o,a){var s=e+(t&n|~t&r)+i+a;return(s<<o|s>>>32-o)+t}function l(e,t,n,r,i,o,a){var s=e+(t&r|n&~r)+i+a;return(s<<o|s>>>32-o)+t}function f(e,t,n,r,i,o,a){var s=e+(t^n^r)+i+a;return(s<<o|s>>>32-o)+t}function d(e,t,n,r,i,o,a){var s=e+(n^(t|~r))+i+a;return(s<<o|s>>>32-o)+t}t.MD5=o._createHelper(c),t.HmacMD5=o._createHmacHelper(c)}(Math),n.MD5)})),S((function(e,t){var n;e.exports=(n=T,void function(){var e=n,t=e.lib.Base,r=e.enc.Utf8;e.algo.HMAC=t.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=r.parse(t));var n=e.blockSize,i=4*n;t.sigBytes>i&&(t=e.finalize(t)),t.clamp();for(var o=this._oKey=t.clone(),a=this._iKey=t.clone(),s=o.words,c=a.words,u=0;u<n;u++)s[u]^=1549556828,c[u]^=909522486;o.sigBytes=a.sigBytes=i,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,n=t.finalize(e);return t.reset(),t.finalize(this._oKey.clone().concat(n))}})}())})),S((function(e,t){e.exports=T.HmacMD5}))),C=S((function(e,t){e.exports=T.enc.Utf8})),L=S((function(e,t){var n;e.exports=(n=T,function(){var e=n,t=e.lib.WordArray;function r(e,n,r){for(var i=[],o=0,a=0;a<n;a++)if(a%4){var s=r[e.charCodeAt(a-1)]<<a%4*2,c=r[e.charCodeAt(a)]>>>6-a%4*2;i[o>>>2]|=(s|c)<<24-o%4*8,o++}return t.create(i,o)}e.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var i=[],o=0;o<n;o+=3)for(var a=(t[o>>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s<n;s++)i.push(r.charAt(a>>>6*(3-s)&63));var c=r.charAt(64);if(c)for(;i.length%4;)i.push(c);return i.join("")},parse:function(e){var t=e.length,n=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o<n.length;o++)i[n.charCodeAt(o)]=o}var a=n.charAt(64);if(a){var s=e.indexOf(a);-1!==s&&(t=s)}return r(e,t,i)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),n.enc.Base64)})),I="uni_id_token",E="uni_id_token_expired",D={DEFAULT:"FUNCTION",FUNCTION:"FUNCTION",OBJECT:"OBJECT",CLIENT_DB:"CLIENT_DB"},M="pending",F="fulfilled",j="rejected";function $(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function R(e){return"object"===$(e)}function N(e){return"function"==typeof e}function U(e){return function(){try{return e.apply(e,arguments)}catch(e){console.error(e)}}}var B="REJECTED",z="NOT_PENDING",W=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.createPromise,r=t.retryRule,i=void 0===r?B:r;(0,y.default)(this,e),this.createPromise=n,this.status=null,this.promise=null,this.retryRule=i}return(0,m.default)(e,[{key:"needRetry",get:function(){if(!this.status)return!0;switch(this.retryRule){case B:return this.status===j;case z:return this.status!==M}}},{key:"exec",value:function(){var e=this;return this.needRetry?(this.status=M,this.promise=this.createPromise().then((function(t){return e.status=F,Promise.resolve(t)}),(function(t){return e.status=j,Promise.reject(t)})),this.promise):this.promise}}]),e}(),q=function(){function e(){(0,y.default)(this,e),this._callback={}}return(0,m.default)(e,[{key:"addListener",value:function(e,t){this._callback[e]||(this._callback[e]=[]),this._callback[e].push(t)}},{key:"on",value:function(e,t){return this.addListener(e,t)}},{key:"removeListener",value:function(e,t){if(!t)throw new Error('The "listener" argument must be of type function. Received undefined');var n=this._callback[e];if(n){var r=function(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return n;return-1}(n,t);n.splice(r,1)}}},{key:"off",value:function(e,t){return this.removeListener(e,t)}},{key:"removeAllListener",value:function(e){delete this._callback[e]}},{key:"emit",value:function(e){for(var t=this._callback[e],n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(t)for(var o=0;o<t.length;o++)t[o].apply(t,r)}}]),e}();function H(e){return e&&"string"==typeof e?JSON.parse(e):e}var V="mp-weixin",K=H([]),G=V,J=(H(void 0),H([])||[]);try{(n("5339").default||n("5339")).appid}catch(Tr){}var X,Y={};function Q(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t=Y,n=e,Object.prototype.hasOwnProperty.call(t,n)||(Y[e]=r),Y[e]}"app"===G&&(Y=r._globalUniCloudObj?r._globalUniCloudObj:r._globalUniCloudObj={});var Z=["invoke","success","fail","complete"],ee=Q("_globalUniCloudInterceptor");function te(e,t){ee[e]||(ee[e]={}),R(t)&&Object.keys(t).forEach((function(n){Z.indexOf(n)>-1&&function(e,t,n){var r=ee[e][t];r||(r=ee[e][t]=[]),-1===r.indexOf(n)&&N(n)&&r.push(n)}(e,n,t[n])}))}function ne(e,t){ee[e]||(ee[e]={}),R(t)?Object.keys(t).forEach((function(n){Z.indexOf(n)>-1&&function(e,t,n){var r=ee[e][t];if(r){var i=r.indexOf(n);i>-1&&r.splice(i,1)}}(e,n,t[n])})):delete ee[e]}function re(e,t){return e&&0!==e.length?e.reduce((function(e,n){return e.then((function(){return n(t)}))}),Promise.resolve()):Promise.resolve()}function ie(e,t){return ee[e]&&ee[e][t]||[]}function oe(e){te("callObject",e)}var ae=Q("_globalUniCloudListener"),se={RESPONSE:"response",NEED_LOGIN:"needLogin",REFRESH_TOKEN:"refreshToken"},ce={CLIENT_DB:"clientdb",CLOUD_FUNCTION:"cloudfunction",CLOUD_OBJECT:"cloudobject"};function ue(e){return ae[e]||(ae[e]=[]),ae[e]}function le(e,t){var n=ue(e);n.includes(t)||n.push(t)}function fe(e,t){var n=ue(e),r=n.indexOf(t);-1!==r&&n.splice(r,1)}function de(e,t){for(var n=ue(e),r=0;r<n.length;r++)(0,n[r])(t)}var he,pe=!1;function ge(){return he||(he=new Promise((function(e){pe&&e(),function t(){if("function"==typeof getCurrentPages){var n=getCurrentPages();n&&n[0]&&(pe=!0,e())}pe||setTimeout((function(){t()}),30)}()})),he)}function ve(e){var t={};for(var n in e){var r=e[n];N(r)&&(t[n]=U(r))}return t}var ye=function(e){(0,h.default)(n,e);var t=A(n);function n(e){var r;(0,y.default)(this,n);var i=e.message||e.errMsg||"unknown system error";return r=t.call(this,i),r.errMsg=i,r.code=r.errCode=e.code||e.errCode||"SYSTEM_ERROR",r.errSubject=r.subject=e.subject||e.errSubject,r.cause=e.cause,r.requestId=e.requestId,r}return(0,m.default)(n,[{key:"toJson",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(!(e>=10))return e++,{errCode:this.errCode,errMsg:this.errMsg,errSubject:this.errSubject,cause:this.cause&&this.cause.toJson?this.cause.toJson(e):this.cause}}}]),n}((0,v.default)(Error));t.UniCloudError=ye;var me,xe,_e={request:function(e){return r.request(e)},uploadFile:function(e){return r.uploadFile(e)},setStorageSync:function(e,t){return r.setStorageSync(e,t)},getStorageSync:function(e){return r.getStorageSync(e)},removeStorageSync:function(e){return r.removeStorageSync(e)},clearStorageSync:function(){return r.clearStorageSync()},connectSocket:function(e){return r.connectSocket(e)}};function be(){return{token:_e.getStorageSync(I)||_e.getStorageSync("uniIdToken"),tokenExpired:_e.getStorageSync(E)}}function we(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.token,n=e.tokenExpired;t&&_e.setStorageSync(I,t),n&&_e.setStorageSync(E,n)}function ke(){return me||(me="mp-weixin"===G&&i.canIUse("getAppBaseInfo")&&i.canIUse("getDeviceInfo")?k(k({},r.getAppBaseInfo()),r.getDeviceInfo()):r.getSystemInfoSync()),me}var Ae={};function Se(){var e=r.getLocale&&r.getLocale()||"en";if(xe)return k(k(k({},Ae),xe),{},{locale:e,LOCALE:e});var t=ke(),n=t.deviceId,i=t.osName,o=t.uniPlatform,a=t.appId,s=["appId","appLanguage","appName","appVersion","appVersionCode","appWgtVersion","browserName","browserVersion","deviceBrand","deviceId","deviceModel","deviceType","osName","osVersion","romName","romVersion","ua","hostName","hostVersion","uniPlatform","uniRuntimeVersion","uniRuntimeVersionCode","uniCompilerVersion","uniCompilerVersionCode"];for(var c in t)Object.hasOwnProperty.call(t,c)&&-1===s.indexOf(c)&&delete t[c];return xe=k(k({PLATFORM:o,OS:i,APPID:a,DEVICEID:n},function(){var e,t;try{if(r.getLaunchOptionsSync){if(r.getLaunchOptionsSync.toString().indexOf("not yet implemented")>-1)return;var n=r.getLaunchOptionsSync(),i=n.scene,o=n.channel;e=o,t=i}}catch(e){}return{channel:e,scene:t}}()),t),k(k(k({},Ae),xe),{},{locale:e,LOCALE:e})}var Pe,Te={sign:function(e,t){var n="";return Object.keys(e).sort().forEach((function(t){e[t]&&(n=n+"&"+t+"="+e[t])})),n=n.slice(1),O(n,t).toString()},wrappedRequest:function(e,t){return new Promise((function(n,r){t(Object.assign(e,{complete:function(e){e||(e={});var t=e.data&&e.data.header&&e.data.header["x-serverless-request-id"]||e.header&&e.header["request-id"];if(!e.statusCode||e.statusCode>=400){var i=e.data&&e.data.error&&e.data.error.code||"SYS_ERR",o=e.data&&e.data.error&&e.data.error.message||e.errMsg||"request:fail";return r(new ye({code:i,message:o,requestId:t}))}var a=e.data;if(a.error)return r(new ye({code:a.error.code,message:a.error.message,requestId:t}));a.result=a.data,a.requestId=t,delete a.data,n(a)}}))}))},toBase64:function(e){return L.stringify(C.parse(e))}},Oe=function(){function e(t){var n=this;(0,y.default)(this,e),["spaceId","clientSecret"].forEach((function(e){if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error("".concat(e," required"))})),this.config=Object.assign({},{endpoint:0===t.spaceId.indexOf("mp-")?"https://api.next.bspapp.com":"https://api.bspapp.com"},t),this.config.provider="aliyun",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.config.accessTokenKey="access_token_"+this.config.spaceId,this.adapter=_e,this._getAccessTokenPromiseHub=new W({createPromise:function(){return n.requestAuth(n.setupRequest({method:"serverless.auth.user.anonymousAuthorize",params:"{}"},"auth")).then((function(e){if(!e.result||!e.result.accessToken)throw new ye({code:"AUTH_FAILED",message:"获取accessToken失败"});n.setAccessToken(e.result.accessToken)}))},retryRule:z})}return(0,m.default)(e,[{key:"hasAccessToken",get:function(){return!!this.accessToken}},{key:"setAccessToken",value:function(e){this.accessToken=e}},{key:"requestWrapped",value:function(e){return Te.wrappedRequest(e,this.adapter.request)}},{key:"requestAuth",value:function(e){return this.requestWrapped(e)}},{key:"request",value:function(e,t){var n=this;return Promise.resolve().then((function(){return n.hasAccessToken?t?n.requestWrapped(e):n.requestWrapped(e).catch((function(t){return new Promise((function(e,n){!t||"GATEWAY_INVALID_TOKEN"!==t.code&&"InvalidParameter.InvalidToken"!==t.code?n(t):e()})).then((function(){return n.getAccessToken()})).then((function(){var t=n.rebuildRequest(e);return n.request(t,!0)}))})):n.getAccessToken().then((function(){var t=n.rebuildRequest(e);return n.request(t,!0)}))}))}},{key:"rebuildRequest",value:function(e){var t=Object.assign({},e);return t.data.token=this.accessToken,t.header["x-basement-token"]=this.accessToken,t.header["x-serverless-sign"]=Te.sign(t.data,this.config.clientSecret),t}},{key:"setupRequest",value:function(e,t){var n=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),r={"Content-Type":"application/json"};return"auth"!==t&&(n.token=this.accessToken,r["x-basement-token"]=this.accessToken),r["x-serverless-sign"]=Te.sign(n,this.config.clientSecret),{url:this.config.requestUrl,method:"POST",data:n,dataType:"json",header:r}}},{key:"getAccessToken",value:function(){return this._getAccessTokenPromiseHub.exec()}},{key:"authorize",value:function(){var e=(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.getAccessToken();case 2:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"callFunction",value:function(e){var t={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:e.name,functionArgs:e.data||{}})};return this.request(k(k({},this.setupRequest(t)),{},{timeout:e.timeout}))}},{key:"getOSSUploadOptionsFromPath",value:function(e){var t={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}},{key:"uploadFileToOSS",value:function(e){var t=this,n=e.url,r=e.formData,i=e.name,o=e.filePath,a=e.fileType,s=e.onUploadProgress;return new Promise((function(e,c){var u=t.adapter.uploadFile({url:n,formData:r,name:i,filePath:o,fileType:a,header:{"X-OSS-server-side-encrpytion":"AES256"},success:function(t){t&&t.statusCode<400?e(t):c(new ye({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){c(new ye({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof s&&u&&"function"==typeof u.onProgressUpdate&&u.onProgressUpdate((function(e){s({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}},{key:"reportOSSUpload",value:function(e){var t={method:"serverless.file.resource.report",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}},{key:"uploadFile",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s,c,u,l,f,d,h,p,g,v,y,m,x,_,b,w,k,A;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.filePath,r=t.cloudPath,i=t.fileType,o=void 0===i?"image":i,s=t.cloudPathAsRealPath,c=void 0!==s&&s,u=t.onUploadProgress,l=t.config,"string"===$(r)){e.next=3;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});case 3:if(r=r.trim()){e.next=5;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath不可为空"});case 5:if(!/:\/\//.test(r)){e.next=7;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath不合法"});case 7:if(f=l&&l.envType||this.config.envType,!(c&&("/"!==r[0]&&(r="/"+r),r.indexOf("\\")>-1))){e.next=10;break}throw new ye({code:"INVALID_PARAM",message:"使用cloudPath作为路径时cloudPath不可包含“\\”"});case 10:return e.next=12,this.getOSSUploadOptionsFromPath({env:f,filename:c?r.split("/").pop():r,fileId:c?r:void 0});case 12:return d=e.sent.result,h="https://"+d.cdnDomain+"/"+d.ossPath,p=d.securityToken,g=d.accessKeyId,v=d.signature,y=d.host,m=d.ossPath,x=d.id,_=d.policy,b=d.ossCallbackUrl,w={"Cache-Control":"max-age=2592000","Content-Disposition":"attachment",OSSAccessKeyId:g,Signature:v,host:y,id:x,key:m,policy:_,success_action_status:200},p&&(w["x-oss-security-token"]=p),b&&(k=JSON.stringify({callbackUrl:b,callbackBody:JSON.stringify({fileId:x,spaceId:this.config.spaceId}),callbackBodyType:"application/json"}),w.callback=Te.toBase64(k)),A={url:"https://"+d.host,formData:w,fileName:"file",name:"file",filePath:n,fileType:o},e.next=27,this.uploadFileToOSS(Object.assign({},A,{onUploadProgress:u}));case 27:if(!b){e.next=29;break}return e.abrupt("return",{success:!0,filePath:n,fileID:h});case 29:return e.next=31,this.reportOSSUpload({id:x});case 31:if(!e.sent.success){e.next=33;break}return e.abrupt("return",{success:!0,filePath:n,fileID:h});case 33:throw new ye({code:"UPLOAD_FAILED",message:"文件上传失败"});case 34:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTempFileURL",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.fileList;return new Promise((function(t,r){Array.isArray(n)&&0!==n.length||r(new ye({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"})),e.getFileInfo({fileList:n}).then((function(e){t({fileList:n.map((function(t,n){var r=e.fileList[n];return{fileID:t,tempFileURL:r&&r.url||t}}))})}))}))}},{key:"getFileInfo",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=i.length>0&&void 0!==i[0]?i[0]:{},n=t.fileList,Array.isArray(n)&&0!==n.length){e.next=3;break}throw new ye({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});case 3:return r={method:"serverless.file.resource.info",params:JSON.stringify({id:n.map((function(e){return e.split("?")[0]})).join(",")})},e.next=6,this.request(this.setupRequest(r));case 6:return e.t0=e.sent.result,e.abrupt("return",{fileList:e.t0});case 8:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()}]),e}(),Ce={init:function(e){var t=new Oe(e),n={signInAnonymously:function(){return t.authorize()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return n},t.customAuth=t.auth,t}},Le="undefined"!=typeof location&&"http:"===location.protocol?"http:":"https:";!function(e){e.local="local",e.none="none",e.session="session"}(Pe||(Pe={}));var Ie,Ee=function(){},De=S((function(e,t){var n;e.exports=(n=T,function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[],c=[];!function(){function t(t){for(var n=e.sqrt(t),r=2;r<=n;r++)if(!(t%r))return!1;return!0}function n(e){return 4294967296*(e-(0|e))|0}for(var r=2,i=0;i<64;)t(r)&&(i<8&&(s[i]=n(e.pow(r,.5))),c[i]=n(e.pow(r,1/3)),i++),r++}();var u=[],l=a.SHA256=o.extend({_doReset:function(){this._hash=new i.init(s.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],o=n[2],a=n[3],s=n[4],l=n[5],f=n[6],d=n[7],h=0;h<64;h++){if(h<16)u[h]=0|e[t+h];else{var p=u[h-15],g=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,v=u[h-2],y=(v<<15|v>>>17)^(v<<13|v>>>19)^v>>>10;u[h]=g+u[h-7]+y+u[h-16]}var m=r&i^r&o^i&o,x=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),_=d+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&l^~s&f)+c[h]+u[h];d=f,f=l,l=s,s=a+_|0,a=o,o=i,i=r,r=_+(x+m)|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+o|0,n[3]=n[3]+a|0,n[4]=n[4]+s|0,n[5]=n[5]+l|0,n[6]=n[6]+f|0,n[7]=n[7]+d|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,i=8*t.sigBytes;return n[i>>>5]|=128<<24-i%32,n[14+(i+64>>>9<<4)]=e.floor(r/4294967296),n[15+(i+64>>>9<<4)]=r,t.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(l),t.HmacSHA256=o._createHmacHelper(l)}(Math),n.SHA256)})),Me=De,Fe=S((function(e,t){e.exports=T.HmacSHA256})),je=function(){var e;if(!Promise){e=function(){},e.promise={};var t=function(){throw new ye({message:'Your Node runtime does support ES6 Promises. Set "global.Promise" to your preferred implementation of promises.'})};return Object.defineProperty(e.promise,"then",{get:t}),Object.defineProperty(e.promise,"catch",{get:t}),e}var n=new Promise((function(t,n){e=function(e,r){return e?n(e):t(r)}}));return e.promise=n,e};function $e(e){return void 0===e}function Re(e){return"[object Null]"===Object.prototype.toString.call(e)}function Ne(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e.replace(/([\s\S]+)\s+(请前往云开发AI小助手查看问题.*)/,"$1")}function Ue(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:32,t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n="",r=0;r<e;r++)n+=t.charAt(Math.floor(62*Math.random()));return n}!function(e){e.WEB="web",e.WX_MP="wx_mp"}(Ie||(Ie={}));var Be={adapter:null,runtime:void 0},ze=["anonymousUuidKey"],We=function(e){(0,h.default)(n,e);var t=A(n);function n(){var e;return(0,y.default)(this,n),e=t.call(this),Be.adapter.root.tcbObject||(Be.adapter.root.tcbObject={}),e}return(0,m.default)(n,[{key:"setItem",value:function(e,t){Be.adapter.root.tcbObject[e]=t}},{key:"getItem",value:function(e){return Be.adapter.root.tcbObject[e]}},{key:"removeItem",value:function(e){delete Be.adapter.root.tcbObject[e]}},{key:"clear",value:function(){delete Be.adapter.root.tcbObject}}]),n}(Ee);function qe(e,t){switch(e){case"local":return t.localStorage||new We;case"none":return new We;default:return t.sessionStorage||new We}}var He=function(){function e(t){if((0,y.default)(this,e),!this._storage){this._persistence=Be.adapter.primaryStorage||t.persistence,this._storage=qe(this._persistence,Be.adapter);var n="access_token_".concat(t.env),r="access_token_expire_".concat(t.env),i="refresh_token_".concat(t.env),o="anonymous_uuid_".concat(t.env),a="login_type_".concat(t.env),s="token_type_".concat(t.env),c="user_info_".concat(t.env);this.keys={accessTokenKey:n,accessTokenExpireKey:r,refreshTokenKey:i,anonymousUuidKey:o,loginTypeKey:a,userInfoKey:c,deviceIdKey:"device_id",tokenTypeKey:s}}}return(0,m.default)(e,[{key:"updatePersistence",value:function(e){if(e!==this._persistence){var t="local"===this._persistence;this._persistence=e;var n=qe(e,Be.adapter);for(var r in this.keys){var i=this.keys[r];if(!t||!ze.includes(r)){var o=this._storage.getItem(i);$e(o)||Re(o)||(n.setItem(i,o),this._storage.removeItem(i))}}this._storage=n}}},{key:"setStore",value:function(e,t,n){if(this._storage){var r={version:n||"localCachev1",content:t},i=JSON.stringify(r);try{this._storage.setItem(e,i)}catch(e){throw e}}}},{key:"getStore",value:function(e,t){try{if(!this._storage)return}catch(e){return""}t=t||"localCachev1";var n=this._storage.getItem(e);return n&&n.indexOf(t)>=0?JSON.parse(n).content:""}},{key:"removeStore",value:function(e){this._storage.removeItem(e)}}]),e}(),Ve={},Ke={};function Ge(e){return Ve[e]}var Je=(0,m.default)((function e(t,n){(0,y.default)(this,e),this.data=n||null,this.name=t})),Xe=function(e){(0,h.default)(n,e);var t=A(n);function n(e,r){var i;return(0,y.default)(this,n),i=t.call(this,"error",{error:e,data:r}),i.error=e,i}return(0,m.default)(n)}(Je),Ye=new(function(){function e(){(0,y.default)(this,e),this._listeners={}}return(0,m.default)(e,[{key:"on",value:function(e,t){return function(e,t,n){n[e]=n[e]||[],n[e].push(t)}(e,t,this._listeners),this}},{key:"off",value:function(e,t){return function(e,t,n){if(n&&n[e]){var r=n[e].indexOf(t);-1!==r&&n[e].splice(r,1)}}(e,t,this._listeners),this}},{key:"fire",value:function(e,t){if(e instanceof Xe)return console.error(e.error),this;var n="string"==typeof e?new Je(e,t||{}):e,r=n.name;if(this._listens(r)){n.target=this;var i,o=this._listeners[r]?(0,l.default)(this._listeners[r]):[],a=_(o);try{for(a.s();!(i=a.n()).done;){var s=i.value;s.call(this,n)}}catch(c){a.e(c)}finally{a.f()}}return this}},{key:"_listens",value:function(e){return this._listeners[e]&&this._listeners[e].length>0}}]),e}());function Qe(e,t){Ye.on(e,t)}function Ze(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Ye.fire(e,t)}function et(e,t){Ye.off(e,t)}var tt,nt="loginStateChanged",rt="loginStateExpire",it="loginTypeChanged",ot="anonymousConverted",at="refreshAccessToken";!function(e){e.ANONYMOUS="ANONYMOUS",e.WECHAT="WECHAT",e.WECHAT_PUBLIC="WECHAT-PUBLIC",e.WECHAT_OPEN="WECHAT-OPEN",e.CUSTOM="CUSTOM",e.EMAIL="EMAIL",e.USERNAME="USERNAME",e.NULL="NULL"}(tt||(tt={}));var st=function(){function e(){(0,y.default)(this,e),this._fnPromiseMap=new Map}return(0,m.default)(e,[{key:"run",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r,i=this;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=this._fnPromiseMap.get(t),e.abrupt("return",(r||(r=new Promise(function(){var e=(0,f.default)(a.default.mark((function e(r,o){var s;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,i._runIdlePromise();case 3:return s=n(),e.t0=r,e.next=7,s;case 7:e.t1=e.sent,(0,e.t0)(e.t1),e.next=14;break;case 11:e.prev=11,e.t2=e["catch"](0),o(e.t2);case 14:return e.prev=14,i._fnPromiseMap.delete(t),e.finish(14);case 17:case"end":return e.stop()}}),e,null,[[0,11,14,17]])})));return function(t,n){return e.apply(this,arguments)}}()),this._fnPromiseMap.set(t,r)),r));case 2:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"_runIdlePromise",value:function(){return Promise.resolve()}}]),e}(),ct=function(){function e(t){(0,y.default)(this,e),this._singlePromise=new st,this._cache=Ge(t.env),this._baseURL="https://".concat(t.env,".ap-shanghai.tcb-api.tencentcloudapi.com"),this._reqClass=new Be.adapter.reqClass({timeout:t.timeout,timeoutMsg:"请求在".concat(t.timeout/1e3,"s内未完成已中断"),restrictedMethods:["post"]})}return(0,m.default)(e,[{key:"_getDeviceId",value:function(){if(this._deviceID)return this._deviceID;var e=this._cache.keys.deviceIdKey,t=this._cache.getStore(e);return"string"==typeof t&&t.length>=16&&t.length<=48||(t=Ue(),this._cache.setStore(e,t)),this._deviceID=t,t}},{key:"_request",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r,i,o,s,c,u=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(r=u.length>2&&void 0!==u[2]?u[2]:{},i={"x-request-id":Ue(),"x-device-id":this._getDeviceId()},!r.withAccessToken){e.next=9;break}return o=this._cache.keys.tokenTypeKey,e.next=6,this.getAccessToken();case 6:s=e.sent,c=this._cache.getStore(o),i.authorization="".concat(c," ").concat(s);case 9:return e.abrupt("return",this._reqClass["get"===r.method?"get":"post"]({url:"".concat(this._baseURL).concat(t),data:n,headers:i}));case 10:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"_fetchAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i,o,s,c,u,l,d,h=this;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this._cache.keys,n=t.loginTypeKey,r=t.accessTokenKey,i=t.accessTokenExpireKey,o=t.tokenTypeKey,s=this._cache.getStore(n),!s||s===tt.ANONYMOUS){e.next=3;break}throw new ye({code:"INVALID_OPERATION",message:"非匿名登录不支持刷新 access token"});case 3:return e.next=5,this._singlePromise.run("fetchAccessToken",(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,h._request("/auth/v1/signin/anonymously",{},{method:"post"});case 2:return e.abrupt("return",e.sent.data);case 3:case"end":return e.stop()}}),e)}))));case 5:return c=e.sent,u=c.access_token,l=c.expires_in,d=c.token_type,e.abrupt("return",(this._cache.setStore(o,d),this._cache.setStore(r,u),this._cache.setStore(i,Date.now()+1e3*l),u));case 10:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"isAccessTokenExpired",value:function(e,t){var n=!0;return e&&t&&(n=t<Date.now()),n}},{key:"getAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i,o;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=this._cache.getStore(n),o=this._cache.getStore(r),e.abrupt("return",this.isAccessTokenExpired(i,o)?this._fetchAccessToken():i);case 2:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"refreshAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=t.loginTypeKey,e.abrupt("return",(this._cache.removeStore(n),this._cache.removeStore(r),this._cache.setStore(i,tt.ANONYMOUS),this.getAccessToken()));case 2:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getUserInfo",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t=this;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._singlePromise.run("getUserInfo",(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,t._request("/auth/v1/user/me",{},{withAccessToken:!0,method:"get"});case 2:return e.abrupt("return",e.sent.data);case 3:case"end":return e.stop()}}),e)})))));case 1:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()}]),e}(),ut=["auth.getJwt","auth.logout","auth.signInWithTicket","auth.signInAnonymously","auth.signIn","auth.fetchAccessTokenWithRefreshToken","auth.signUpWithEmailAndPassword","auth.activateEndUserMail","auth.sendPasswordResetEmail","auth.resetPasswordWithToken","auth.isUsernameRegistered"],lt={"X-SDK-Version":"1.3.5"};function ft(e,t,n){var r=e[t];e[t]=function(t){var i={},o={};n.forEach((function(n){var r=n.call(e,t),a=r.data,s=r.headers;Object.assign(i,a),Object.assign(o,s)}));var a=t.data;return a&&function(){var e;if(e=a,"[object FormData]"!==Object.prototype.toString.call(e))t.data=k(k({},a),i);else for(var n in i)a.append(n,i[n])}(),t.headers=k(k({},t.headers||{}),o),r.call(e,t)}}function dt(){var e=Math.random().toString(16).slice(2);return{data:{seqId:e},headers:k(k({},lt),{},{"x-seqid":e})}}var ht=function(){function e(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,y.default)(this,e),this.config=n,this._reqClass=new Be.adapter.reqClass({timeout:this.config.timeout,timeoutMsg:"请求在".concat(this.config.timeout/1e3,"s内未完成已中断"),restrictedMethods:["post"]}),this._cache=Ge(this.config.env),this._localCache=(t=this.config.env,Ke[t]),this.oauth=new ct(this.config),ft(this._reqClass,"post",[dt]),ft(this._reqClass,"upload",[dt]),ft(this._reqClass,"download",[dt])}return(0,m.default)(e,[{key:"post",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.post(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"upload",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.upload(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"download",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.download(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"refreshAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._refreshAccessTokenPromise||(this._refreshAccessTokenPromise=this._refreshAccessToken()),e.prev=1,e.next=4,this._refreshAccessTokenPromise;case 4:t=e.sent,e.next=10;break;case 7:e.prev=7,e.t0=e["catch"](1),n=e.t0;case 10:if(this._refreshAccessTokenPromise=null,this._shouldRefreshAccessTokenHook=null,!n){e.next=12;break}throw n;case 12:return e.abrupt("return",t);case 13:case"end":return e.stop()}}),e,this,[[1,7]])})));return function(){return e.apply(this,arguments)}}()},{key:"_refreshAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i,o,s,c,u,l,f,d,h,p;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=t.refreshTokenKey,o=t.loginTypeKey,s=t.anonymousUuidKey,this._cache.removeStore(n),this._cache.removeStore(r),c=this._cache.getStore(i),c){e.next=5;break}throw new ye({message:"未登录CloudBase"});case 5:return u={refresh_token:c},e.next=8,this.request("auth.fetchAccessTokenWithRefreshToken",u);case 8:if(l=e.sent,!l.data.code){e.next=21;break}if(f=l.data.code,"SIGN_PARAM_INVALID"!==f&&"REFRESH_TOKEN_EXPIRED"!==f&&"INVALID_REFRESH_TOKEN"!==f){e.next=20;break}if(this._cache.getStore(o)!==tt.ANONYMOUS||"INVALID_REFRESH_TOKEN"!==f){e.next=19;break}return d=this._cache.getStore(s),h=this._cache.getStore(i),e.next=17,this.send("auth.signInAnonymously",{anonymous_uuid:d,refresh_token:h});case 17:return p=e.sent,e.abrupt("return",(this.setRefreshToken(p.refresh_token),this._refreshAccessToken()));case 19:Ze(rt),this._cache.removeStore(i);case 20:throw new ye({code:l.data.code,message:"刷新access token失败".concat(l.data.code)});case 21:if(!l.data.access_token){e.next=23;break}return e.abrupt("return",(Ze(at),this._cache.setStore(n,l.data.access_token),this._cache.setStore(r,l.data.access_token_expire+Date.now()),{accessToken:l.data.access_token,accessTokenExpire:l.data.access_token_expire}));case 23:l.data.refresh_token&&(this._cache.removeStore(i),this._cache.setStore(i,l.data.refresh_token),this._refreshAccessToken());case 24:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i,o,s,c;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=t.refreshTokenKey,this._cache.getStore(i)){e.next=3;break}throw new ye({message:"refresh token不存在登录状态异常"});case 3:if(o=this._cache.getStore(n),s=this._cache.getStore(r),c=!0,e.t0=this._shouldRefreshAccessTokenHook,!e.t0){e.next=9;break}return e.next=8,this._shouldRefreshAccessTokenHook(o,s);case 8:e.t0=!e.sent;case 9:if(e.t1=e.t0,!e.t1){e.next=12;break}c=!1;case 12:return e.abrupt("return",(!o||!s||s<Date.now())&&c?this.refreshAccessToken():{accessToken:o,accessTokenExpire:s});case 13:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"request",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n,r){var i,o,s,c,u,l,f,d,h,p,g,v,y,m,x;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(i="x-tcb-trace_".concat(this.config.env),o="application/x-www-form-urlencoded",s=k({action:t,env:this.config.env,dataVersion:"2019-08-16"},n),e.t0=-1===ut.indexOf(t),!e.t0){e.next=9;break}return this._cache.keys,e.next=8,this.oauth.getAccessToken();case 8:s.access_token=e.sent;case 9:if("storage.uploadFile"!==t){e.next=15;break}for(u in c=new FormData,c)c.hasOwnProperty(u)&&void 0!==c[u]&&c.append(u,s[u]);o="multipart/form-data",e.next=17;break;case 15:for(l in o="application/json",c={},s)void 0!==s[l]&&(c[l]=s[l]);case 17:return f={headers:{"content-type":o}},r&&r.timeout&&(f.timeout=r.timeout),r&&r.onUploadProgress&&(f.onUploadProgress=r.onUploadProgress),d=this._localCache.getStore(i),d&&(f.headers["X-TCB-Trace"]=d),h=n.parse,p=n.inQuery,g=n.search,v={env:this.config.env},h&&(v.parse=!0),p&&(v=k(k({},p),v)),y=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=/\?/.test(t),i="";for(var o in n)""===i?!r&&(t+="?"):i+="&",i+="".concat(o,"=").concat(encodeURIComponent(n[o]));return/^http(s)?\:\/\//.test(t+=i)?t:"".concat(e).concat(t)}(Le,"//tcb-api.tencentcloudapi.com/web",v),g&&(y+=g),e.next=28,this.post(k({url:y,data:c},f));case 28:if(m=e.sent,x=m.header&&m.header["x-tcb-trace"],x&&this._localCache.setStore(i,x),(200===Number(m.status)||200===Number(m.statusCode))&&m.data){e.next=32;break}throw new ye({code:"NETWORK_ERROR",message:"network request error"});case 32:return e.abrupt("return",m);case 33:case"end":return e.stop()}}),e,this)})));return function(t,n,r){return e.apply(this,arguments)}}()},{key:"send",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=s.length>1&&void 0!==s[1]?s[1]:{},r=s.length>2&&void 0!==s[2]?s[2]:{},e.next=4,this.request(t,n,k(k({},r),{},{onUploadProgress:n.onUploadProgress}));case 4:if(i=e.sent,"ACCESS_TOKEN_DISABLED"!==i.data.code&&"ACCESS_TOKEN_EXPIRED"!==i.data.code||-1!==ut.indexOf(t)){e.next=14;break}return e.next=8,this.oauth.refreshAccessToken();case 8:return e.next=10,this.request(t,n,k(k({},r),{},{onUploadProgress:n.onUploadProgress}));case 10:if(o=e.sent,!o.data.code){e.next=13;break}throw new ye({code:o.data.code,message:Ne(o.data.message)});case 13:return e.abrupt("return",o.data);case 14:if(!i.data.code){e.next=16;break}throw new ye({code:i.data.code,message:Ne(i.data.message)});case 16:return e.abrupt("return",i.data);case 17:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"setRefreshToken",value:function(e){var t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=t.refreshTokenKey;this._cache.removeStore(n),this._cache.removeStore(r),this._cache.setStore(i,e)}}]),e}(),pt={};function gt(e){return pt[e]}var vt=function(){function e(t){(0,y.default)(this,e),this.config=t,this._cache=Ge(t.env),this._request=gt(t.env)}return(0,m.default)(e,[{key:"setRefreshToken",value:function(e){var t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,i=t.refreshTokenKey;this._cache.removeStore(n),this._cache.removeStore(r),this._cache.setStore(i,e)}},{key:"setAccessToken",value:function(e,t){var n=this._cache.keys,r=n.accessTokenKey,i=n.accessTokenExpireKey;this._cache.setStore(r,e),this._cache.setStore(i,t)}},{key:"refreshUserInfo",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.send("auth.getUserInfo",{});case 2:return t=e.sent,n=t.data,e.abrupt("return",(this.setLocalUserInfo(n),n));case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setLocalUserInfo",value:function(e){var t=this._cache.keys.userInfoKey;this._cache.setStore(t,e)}}]),e}(),yt=function(){function e(t){if((0,y.default)(this,e),!t)throw new ye({code:"PARAM_ERROR",message:"envId is not defined"});this._envId=t,this._cache=Ge(this._envId),this._request=gt(this._envId),this.setUserInfo()}return(0,m.default)(e,[{key:"linkWithTicket",value:function(e){if("string"!=typeof e)throw new ye({code:"PARAM_ERROR",message:"ticket must be string"});return this._request.send("auth.linkWithTicket",{ticket:e})}},{key:"linkWithRedirect",value:function(e){e.signInWithRedirect()}},{key:"updatePassword",value:function(e,t){return this._request.send("auth.updatePassword",{oldPassword:t,newPassword:e})}},{key:"updateEmail",value:function(e){return this._request.send("auth.updateEmail",{newEmail:e})}},{key:"updateUsername",value:function(e){if("string"!=typeof e)throw new ye({code:"PARAM_ERROR",message:"username must be a string"});return this._request.send("auth.updateUsername",{username:e})}},{key:"getLinkedUidList",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.send("auth.getLinkedUidList",{});case 2:return t=e.sent,n=t.data,r=!1,i=n.users,e.abrupt("return",(i.forEach((function(e){e.wxOpenId&&e.wxPublicId&&(r=!0)})),{users:i,hasPrimaryUid:r}));case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setPrimaryUid",value:function(e){return this._request.send("auth.setPrimaryUid",{uid:e})}},{key:"unlink",value:function(e){return this._request.send("auth.unlink",{platform:e})}},{key:"update",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s,c,u,l;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.nickName,r=t.gender,i=t.avatarUrl,o=t.province,s=t.country,c=t.city,e.next=8,this._request.send("auth.updateUserInfo",{nickName:n,gender:r,avatarUrl:i,province:o,country:s,city:c});case 8:u=e.sent,l=u.data,this.setLocalUserInfo(l);case 11:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"refresh",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.oauth.getUserInfo();case 2:return t=e.sent,e.abrupt("return",(this.setLocalUserInfo(t),t));case 4:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setUserInfo",value:function(){var e=this,t=this._cache.keys.userInfoKey,n=this._cache.getStore(t);["uid","loginType","openid","wxOpenId","wxPublicId","unionId","qqMiniOpenId","email","hasPassword","customUserId","nickName","gender","avatarUrl"].forEach((function(t){e[t]=n[t]})),this.location={country:n.country,province:n.province,city:n.city}}},{key:"setLocalUserInfo",value:function(e){var t=this._cache.keys.userInfoKey;this._cache.setStore(t,e),this.setUserInfo()}}]),e}(),mt=function(){function e(t){if((0,y.default)(this,e),!t)throw new ye({code:"PARAM_ERROR",message:"envId is not defined"});this._cache=Ge(t);var n=this._cache.keys,r=n.refreshTokenKey,i=n.accessTokenKey,o=n.accessTokenExpireKey,a=this._cache.getStore(r),s=this._cache.getStore(i),c=this._cache.getStore(o);this.credential={refreshToken:a,accessToken:s,accessTokenExpire:c},this.user=new yt(t)}return(0,m.default)(e,[{key:"isAnonymousAuth",get:function(){return this.loginType===tt.ANONYMOUS}},{key:"isCustomAuth",get:function(){return this.loginType===tt.CUSTOM}},{key:"isWeixinAuth",get:function(){return this.loginType===tt.WECHAT||this.loginType===tt.WECHAT_OPEN||this.loginType===tt.WECHAT_PUBLIC}},{key:"loginType",get:function(){return this._cache.getStore(this._cache.keys.loginTypeKey)}}]),e}(),xt=function(e){(0,h.default)(n,e);var t=A(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,m.default)(n,[{key:"signIn",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._cache.updatePersistence("local"),e.next=3,this._request.oauth.getAccessToken();case 3:return Ze(nt),Ze(it,{env:this.config.env,loginType:tt.ANONYMOUS,persistence:"local"}),t=new mt(this.config.env),e.next=8,t.user.refresh();case 8:return e.abrupt("return",t);case 9:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"linkAndRetrieveDataWithTicket",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s,c;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=this._cache.keys,r=n.anonymousUuidKey,i=n.refreshTokenKey,o=this._cache.getStore(r),s=this._cache.getStore(i),e.next=7,this._request.send("auth.linkAndRetrieveDataWithTicket",{anonymous_uuid:o,refresh_token:s,ticket:t});case 7:if(c=e.sent,!c.refresh_token){e.next=16;break}return this._clearAnonymousUUID(),this.setRefreshToken(c.refresh_token),e.next=13,this._request.refreshAccessToken();case 13:return Ze(ot,{env:this.config.env}),Ze(it,{loginType:tt.CUSTOM,persistence:"local"}),e.abrupt("return",{credential:{refreshToken:c.refresh_token}});case 16:throw new ye({message:"匿名转化失败"});case 17:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_setAnonymousUUID",value:function(e){var t=this._cache.keys,n=t.anonymousUuidKey,r=t.loginTypeKey;this._cache.removeStore(n),this._cache.setStore(n,e),this._cache.setStore(r,tt.ANONYMOUS)}},{key:"_clearAnonymousUUID",value:function(){this._cache.removeStore(this._cache.keys.anonymousUuidKey)}}]),n}(vt),_t=function(e){(0,h.default)(n,e);var t=A(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,m.default)(n,[{key:"signIn",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new ye({code:"PARAM_ERROR",message:"ticket must be a string"});case 2:return n=this._cache.keys.refreshTokenKey,e.next=5,this._request.send("auth.signInWithTicket",{ticket:t,refresh_token:this._cache.getStore(n)||""});case 5:if(r=e.sent,!r.refresh_token){e.next=15;break}return this.setRefreshToken(r.refresh_token),e.next=10,this._request.refreshAccessToken();case 10:return Ze(nt),Ze(it,{env:this.config.env,loginType:tt.CUSTOM,persistence:this.config.persistence}),e.next=14,this.refreshUserInfo();case 14:return e.abrupt("return",new mt(this.config.env));case 15:throw new ye({message:"自定义登录失败"});case 16:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}]),n}(vt),bt=function(e){(0,h.default)(n,e);var t=A(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,m.default)(n,[{key:"signIn",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r,i,o,s,c;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new ye({code:"PARAM_ERROR",message:"email must be a string"});case 2:return r=this._cache.keys.refreshTokenKey,e.next=5,this._request.send("auth.signIn",{loginType:"EMAIL",email:t,password:n,refresh_token:this._cache.getStore(r)||""});case 5:if(i=e.sent,o=i.refresh_token,s=i.access_token,c=i.access_token_expire,!o){e.next=22;break}if(this.setRefreshToken(o),!s||!c){e.next=15;break}this.setAccessToken(s,c),e.next=17;break;case 15:return e.next=17,this._request.refreshAccessToken();case 17:return e.next=19,this.refreshUserInfo();case 19:return Ze(nt),Ze(it,{env:this.config.env,loginType:tt.EMAIL,persistence:this.config.persistence}),e.abrupt("return",new mt(this.config.env));case 22:throw i.code?new ye({code:i.code,message:"邮箱登录失败: ".concat(i.message)}):new ye({message:"邮箱登录失败"});case 23:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"activate",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.activateEndUserMail",{token:t}));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"resetPasswordWithToken",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.resetPasswordWithToken",{token:t,newPassword:n}));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()}]),n}(vt),wt=function(e){(0,h.default)(n,e);var t=A(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,m.default)(n,[{key:"signIn",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r,i,o,s,c;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new ye({code:"PARAM_ERROR",message:"username must be a string"});case 2:return"string"!=typeof n&&(n="",console.warn("password is empty")),r=this._cache.keys.refreshTokenKey,e.next=6,this._request.send("auth.signIn",{loginType:tt.USERNAME,username:t,password:n,refresh_token:this._cache.getStore(r)||""});case 6:if(i=e.sent,o=i.refresh_token,s=i.access_token_expire,c=i.access_token,!o){e.next=23;break}if(this.setRefreshToken(o),!c||!s){e.next=16;break}this.setAccessToken(c,s),e.next=18;break;case 16:return e.next=18,this._request.refreshAccessToken();case 18:return e.next=20,this.refreshUserInfo();case 20:return Ze(nt),Ze(it,{env:this.config.env,loginType:tt.USERNAME,persistence:this.config.persistence}),e.abrupt("return",new mt(this.config.env));case 23:throw i.code?new ye({code:i.code,message:"用户名密码登录失败: ".concat(i.message)}):new ye({message:"用户名密码登录失败"});case 24:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()}]),n}(vt),kt=function(){function e(t){(0,y.default)(this,e),this.config=t,this._cache=Ge(t.env),this._request=gt(t.env),this._onAnonymousConverted=this._onAnonymousConverted.bind(this),this._onLoginTypeChanged=this._onLoginTypeChanged.bind(this),Qe(it,this._onLoginTypeChanged)}return(0,m.default)(e,[{key:"currentUser",get:function(){var e=this.hasLoginState();return e&&e.user||null}},{key:"loginType",get:function(){return this._cache.getStore(this._cache.keys.loginTypeKey)}},{key:"anonymousAuthProvider",value:function(){return new xt(this.config)}},{key:"customAuthProvider",value:function(){return new _t(this.config)}},{key:"emailAuthProvider",value:function(){return new bt(this.config)}},{key:"usernameAuthProvider",value:function(){return new wt(this.config)}},{key:"signInAnonymously",value:function(){var e=(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new xt(this.config).signIn());case 1:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"signInWithEmailAndPassword",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new bt(this.config).signIn(t,n));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"signInWithUsernameAndPassword",value:function(e,t){return new wt(this.config).signIn(e,t)}},{key:"linkAndRetrieveDataWithTicket",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._anonymousAuthProvider||(this._anonymousAuthProvider=new xt(this.config)),Qe(ot,this._onAnonymousConverted),e.next=3,this._anonymousAuthProvider.linkAndRetrieveDataWithTicket(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"signOut",value:function(){var e=(0,f.default)(a.default.mark((function e(){var t,n,r,i,o,s;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.loginType!==tt.ANONYMOUS){e.next=2;break}throw new ye({message:"匿名用户不支持登出操作"});case 2:if(t=this._cache.keys,n=t.refreshTokenKey,r=t.accessTokenKey,i=t.accessTokenExpireKey,o=this._cache.getStore(n),o){e.next=5;break}return e.abrupt("return");case 5:return e.next=7,this._request.send("auth.logout",{refresh_token:o});case 7:return s=e.sent,e.abrupt("return",(this._cache.removeStore(n),this._cache.removeStore(r),this._cache.removeStore(i),Ze(nt),Ze(it,{env:this.config.env,loginType:tt.NULL,persistence:this.config.persistence}),s));case 9:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"signUpWithEmailAndPassword",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.signUpWithEmailAndPassword",{email:t,password:n}));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"sendPasswordResetEmail",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.sendPasswordResetEmail",{email:t}));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"onLoginStateChanged",value:function(e){var t=this;Qe(nt,(function(){var n=t.hasLoginState();e.call(t,n)}));var n=this.hasLoginState();e.call(this,n)}},{key:"onLoginStateExpired",value:function(e){Qe(rt,e.bind(this))}},{key:"onAccessTokenRefreshed",value:function(e){Qe(at,e.bind(this))}},{key:"onAnonymousConverted",value:function(e){Qe(ot,e.bind(this))}},{key:"onLoginTypeChanged",value:function(e){var t=this;Qe(it,(function(){var n=t.hasLoginState();e.call(t,n)}))}},{key:"getAccessToken",value:function(){var e=(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.getAccessToken();case 2:return e.t0=e.sent.accessToken,e.t1=this.config.env,e.abrupt("return",{accessToken:e.t0,env:e.t1});case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"hasLoginState",value:function(){var e=this._cache.keys,t=e.accessTokenKey,n=e.accessTokenExpireKey,r=this._cache.getStore(t),i=this._cache.getStore(n);return this._request.oauth.isAccessTokenExpired(r,i)?null:new mt(this.config.env)}},{key:"isUsernameRegistered",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new ye({code:"PARAM_ERROR",message:"username must be a string"});case 2:return e.next=4,this._request.send("auth.isUsernameRegistered",{username:t});case 4:return n=e.sent,r=n.data,e.abrupt("return",r&&r.isRegistered);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getLoginState",value:function(){return Promise.resolve(this.hasLoginState())}},{key:"signInWithTicket",value:function(){var e=(0,f.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new _t(this.config).signIn(t));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"shouldRefreshAccessToken",value:function(e){this._request._shouldRefreshAccessTokenHook=e.bind(this)}},{key:"getUserInfo",value:function(){return this._request.send("auth.getUserInfo",{}).then((function(e){return e.code?e:k(k({},e.data),{},{requestId:e.seqId})}))}},{key:"getAuthHeader",value:function(){var e=this._cache.keys,t=e.refreshTokenKey,n=e.accessTokenKey,r=this._cache.getStore(t);return{"x-cloudbase-credentials":this._cache.getStore(n)+"/@@/"+r}}},{key:"_onAnonymousConverted",value:function(e){var t=e.data.env;t===this.config.env&&this._cache.updatePersistence(this.config.persistence)}},{key:"_onLoginTypeChanged",value:function(e){var t=e.data,n=t.loginType,r=t.persistence,i=t.env;i===this.config.env&&(this._cache.updatePersistence(r),this._cache.setStore(this._cache.keys.loginTypeKey,n))}}]),e}(),At=function(e,t){t=t||je();var n=gt(this.config.env),r=e.cloudPath,i=e.filePath,o=e.onUploadProgress,a=e.fileType,s=void 0===a?"image":a;return n.send("storage.getUploadMetadata",{path:r}).then((function(e){var a=e.data,c=a.url,u=a.authorization,l=a.token,f=a.fileId,d=a.cosFileId,h=e.requestId,p={key:r,signature:u,"x-cos-meta-fileid":d,success_action_status:"201","x-cos-security-token":l};n.upload({url:c,data:p,file:i,name:r,fileType:s,onUploadProgress:o}).then((function(e){201===e.statusCode?t(null,{fileID:f,requestId:h}):t(new ye({code:"STORAGE_REQUEST_FAIL",message:"STORAGE_REQUEST_FAIL: ".concat(e.data)}))})).catch((function(e){t(e)}))})).catch((function(e){t(e)})),t.promise},St=function(e,t){t=t||je();var n=gt(this.config.env),r=e.cloudPath;return n.send("storage.getUploadMetadata",{path:r}).then((function(e){t(null,e)})).catch((function(e){t(e)})),t.promise},Pt=function(e,t){var n=e.fileList;if(t=t||je(),!n||!Array.isArray(n))return{code:"INVALID_PARAM",message:"fileList必须是非空的数组"};var r,i=_(n);try{for(i.s();!(r=i.n()).done;){var o=r.value;if(!o||"string"!=typeof o)return{code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"}}}catch(s){i.e(s)}finally{i.f()}var a={fileid_list:n};return gt(this.config.env).send("storage.batchDeleteFile",a).then((function(e){e.code?t(null,e):t(null,{fileList:e.data.delete_list,requestId:e.requestId})})).catch((function(e){t(e)})),t.promise},Tt=function(e,t){var n=e.fileList;t=t||je(),n&&Array.isArray(n)||t(null,{code:"INVALID_PARAM",message:"fileList必须是非空的数组"});var r,i=[],o=_(n);try{for(o.s();!(r=o.n()).done;){var a=r.value;"object"==(0,u.default)(a)?(a.hasOwnProperty("fileID")&&a.hasOwnProperty("maxAge")||t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是包含fileID和maxAge的对象"}),i.push({fileid:a.fileID,max_age:a.maxAge})):"string"==typeof a?i.push({fileid:a}):t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是字符串"})}}catch(c){o.e(c)}finally{o.f()}var s={file_list:i};return gt(this.config.env).send("storage.batchGetDownloadUrl",s).then((function(e){e.code?t(null,e):t(null,{fileList:e.data.download_list,requestId:e.requestId})})).catch((function(e){t(e)})),t.promise},Ot=function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r,i,o,s;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.fileID,e.next=3,Tt.call(this,{fileList:[{fileID:r,maxAge:600}]});case 3:if(i=e.sent.fileList[0],"SUCCESS"===i.code){e.next=6;break}return e.abrupt("return",n?n(i):new Promise((function(e){e(i)})));case 6:if(o=gt(this.config.env),s=i.download_url,s=encodeURI(s),n){e.next=10;break}return e.abrupt("return",o.download({url:s}));case 10:return e.t0=n,e.next=13,o.download({url:s});case 13:e.t1=e.sent,(0,e.t0)(e.t1);case 15:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}(),Ct=function(e,t){var n,r=e.name,i=e.data,o=e.query,a=e.parse,s=e.search,c=e.timeout,u=t||je();try{n=i?JSON.stringify(i):""}catch(r){return Promise.reject(r)}if(!r)return Promise.reject(new ye({code:"PARAM_ERROR",message:"函数名不能为空"}));var l={inQuery:o,parse:a,search:s,function_name:r,request_data:n};return gt(this.config.env).send("functions.invokeFunction",l,{timeout:c}).then((function(e){if(e.code)u(null,e);else{var t=e.data.response_data;if(a)u(null,{result:t,requestId:e.requestId});else try{t=JSON.parse(e.data.response_data),u(null,{result:t,requestId:e.requestId})}catch(e){u(new ye({message:"response data must be json"}))}}return u.promise})).catch((function(e){u(e)})),u.promise},Lt={timeout:15e3,persistence:"session"},It={},Et=function(){function e(t){(0,y.default)(this,e),this.config=t||this.config,this.authObj=void 0}return(0,m.default)(e,[{key:"init",value:function(t){switch(Be.adapter||(this.requestClient=new Be.adapter.reqClass({timeout:t.timeout||5e3,timeoutMsg:"请求在".concat((t.timeout||5e3)/1e3,"s内未完成已中断")})),this.config=k(k({},Lt),t),!0){case this.config.timeout>6e5:console.warn("timeout大于可配置上限[10分钟],已重置为上限数值"),this.config.timeout=6e5;break;case this.config.timeout<100:console.warn("timeout小于可配置下限[100ms],已重置为下限数值"),this.config.timeout=100}return new e(this.config)}},{key:"auth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.persistence;if(this.authObj)return this.authObj;var n,r=t||Be.adapter.primaryStorage||Lt.persistence;return r!==this.config.persistence&&(this.config.persistence=r),function(e){var t=e.env;Ve[t]=new He(e),Ke[t]=new He(k(k({},e),{},{persistence:"local"}))}(this.config),n=this.config,pt[n.env]=new ht(n),this.authObj=new kt(this.config),this.authObj}},{key:"on",value:function(e,t){return Qe.apply(this,[e,t])}},{key:"off",value:function(e,t){return et.apply(this,[e,t])}},{key:"callFunction",value:function(e,t){return Ct.apply(this,[e,t])}},{key:"deleteFile",value:function(e,t){return Pt.apply(this,[e,t])}},{key:"getTempFileURL",value:function(e,t){return Tt.apply(this,[e,t])}},{key:"downloadFile",value:function(e,t){return Ot.apply(this,[e,t])}},{key:"uploadFile",value:function(e,t){return At.apply(this,[e,t])}},{key:"getUploadMetadata",value:function(e,t){return St.apply(this,[e,t])}},{key:"registerExtension",value:function(e){It[e.name]=e}},{key:"invokeExtension",value:function(){var e=(0,f.default)(a.default.mark((function e(t,n){var r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(r=It[t],r){e.next=3;break}throw new ye({message:"扩展".concat(t," 必须先注册")});case 3:return e.next=5,r.invoke(n,this);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"useAdapters",value:function(e){var t=function(e){var t,n,r=(t=e,"[object Array]"===Object.prototype.toString.call(t)?e:[e]),i=_(r);try{for(i.s();!(n=i.n()).done;){var o=n.value,a=o.isMatch,s=o.genAdapter,c=o.runtime;if(a())return{adapter:s(),runtime:c}}}catch(u){i.e(u)}finally{i.f()}}(e)||{},n=t.adapter,r=t.runtime;n&&(Be.adapter=n),r&&(Be.runtime=r)}}]),e}(),Dt=new Et;function Mt(e,t,n){void 0===n&&(n={});var r=/\?/.test(t),i="";for(var o in n)""===i?!r&&(t+="?"):i+="&",i+=o+"="+encodeURIComponent(n[o]);return/^http(s)?:\/\//.test(t+=i)?t:""+e+t}var Ft=function(){function e(){(0,y.default)(this,e)}return(0,m.default)(e,[{key:"get",value:function(e){var t=e.url,n=e.data,r=e.headers,i=e.timeout;return new Promise((function(e,o){_e.request({url:Mt("https:",t),data:n,method:"GET",header:r,timeout:i,success:function(t){e(t)},fail:function(e){o(e)}})}))}},{key:"post",value:function(e){var t=e.url,n=e.data,r=e.headers,i=e.timeout;return new Promise((function(e,o){_e.request({url:Mt("https:",t),data:n,method:"POST",header:r,timeout:i,success:function(t){e(t)},fail:function(e){o(e)}})}))}},{key:"upload",value:function(e){return new Promise((function(t,n){var r=e.url,i=e.file,o=e.data,a=e.headers,s=e.fileType,c=_e.uploadFile({url:Mt("https:",r),name:"file",formData:Object.assign({},o),filePath:i,fileType:s,header:a,success:function(e){var n={statusCode:e.statusCode,data:e.data||{}};200===e.statusCode&&o.success_action_status&&(n.statusCode=parseInt(o.success_action_status,10)),t(n)},fail:function(e){n(new Error(e.errMsg||"uploadFile:fail"))}});"function"==typeof e.onUploadProgress&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((function(t){e.onUploadProgress({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))}}]),e}(),jt={setItem:function(e,t){_e.setStorageSync(e,t)},getItem:function(e){return _e.getStorageSync(e)},removeItem:function(e){_e.removeStorageSync(e)},clear:function(){_e.clearStorageSync()}},$t={genAdapter:function(){return{root:{},reqClass:Ft,localStorage:jt,primaryStorage:"local"}},isMatch:function(){return!0},runtime:"uni_app"};Dt.useAdapters($t);var Rt=Dt,Nt=Rt.init;Rt.init=function(e){e.env=e.spaceId;var t=Nt.call(this,e);t.config.provider="tencent",t.config.spaceId=e.spaceId;var n=t.auth;return t.auth=function(e){var t=n.call(this,e);return["linkAndRetrieveDataWithTicket","signInAnonymously","signOut","getAccessToken","getLoginState","signInWithTicket","getUserInfo"].forEach((function(e){var n;t[e]=(n=t[e],function(e){e=e||{};var t=ve(e),r=t.success,i=t.fail,o=t.complete;if(!(r||i||o))return n.call(this,e);n.call(this,e).then((function(e){r&&r(e),o&&o(e)}),(function(e){i&&i(e),o&&o(e)}))}).bind(t)})),t},t.customAuth=t.auth,t};var Ut=Rt;function Bt(e,t){return zt.apply(this,arguments)}function zt(){return zt=(0,f.default)(a.default.mark((function e(t,n){var r,i,o;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r="http://".concat(t,":").concat(n,"/system/ping"),e.prev=1,e.next=4,o={url:r,timeout:500},new Promise((function(e,t){_e.request(k(k({},o),{},{success:function(t){e(t)},fail:function(e){t(e)}}))}));case 4:return i=e.sent,e.abrupt("return",!(!i.data||0!==i.data.code));case 8:return e.prev=8,e.t0=e["catch"](1),e.abrupt("return",!1);case 11:case"end":return e.stop()}}),e,null,[[1,8]])}))),zt.apply(this,arguments)}function Wt(e,t){return qt.apply(this,arguments)}function qt(){return qt=(0,f.default)(a.default.mark((function e(t,n){var r,i,o;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:i=0;case 1:if(!(i<t.length)){e.next=11;break}return o=t[i],e.next=5,Bt(o,n);case 5:if(!e.sent){e.next=8;break}return r=o,e.abrupt("break",11);case 8:i++,e.next=1;break;case 11:return e.abrupt("return",{address:r,port:n});case 12:case"end":return e.stop()}}),e)}))),qt.apply(this,arguments)}var Ht={"serverless.file.resource.generateProximalSign":"storage/generate-proximal-sign","serverless.file.resource.report":"storage/report","serverless.file.resource.delete":"storage/delete","serverless.file.resource.getTempFileURL":"storage/get-temp-file-url"},Vt=function(){function e(t){if((0,y.default)(this,e),["spaceId","clientSecret"].forEach((function(e){if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error("".concat(e," required"))})),!t.endpoint)throw new Error("集群空间未配置ApiEndpoint配置后需要重新关联服务空间后生效");this.config=Object.assign({},t),this.config.provider="dcloud",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.adapter=_e}return(0,m.default)(e,[{key:"request",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r=this,i=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!(i.length>1&&void 0!==i[1])||i[1],n=!1,!n){e.next=8;break}return e.next=5,this.setupLocalRequest(t);case 5:e.t0=e.sent,e.next=9;break;case 8:e.t0=this.setupRequest(t);case 9:return t=e.t0,e.abrupt("return",Promise.resolve().then((function(){return n?r.requestLocal(t):Te.wrappedRequest(t,r.adapter.request)})));case 11:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"requestLocal",value:function(e){var t=this;return new Promise((function(n,r){t.adapter.request(Object.assign(e,{complete:function(e){if(e||(e={}),!e.statusCode||e.statusCode>=400){var t=e.data&&e.data.code||"SYS_ERR",i=e.data&&e.data.message||"request:fail";return r(new ye({code:t,message:i}))}n({success:!0,result:e.data})}}))}))}},{key:"setupRequest",value:function(e){var t=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),n={"Content-Type":"application/json"};n["x-serverless-sign"]=Te.sign(t,this.config.clientSecret);var r=Se();n["x-client-info"]=encodeURIComponent(JSON.stringify(r));var i=be(),o=i.token;return n["x-client-token"]=o,{url:this.config.requestUrl,method:"POST",data:t,dataType:"json",header:JSON.parse(JSON.stringify(n))}}},{key:"setupLocalRequest",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s,c,u,l,f;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=Se(),r=be(),i=r.token,o=Object.assign({},t,{spaceId:this.config.spaceId,timestamp:Date.now(),clientInfo:n,token:i}),s=this.__dev__&&this.__dev__.debugInfo||{},c=s.address,u=s.servePort,e.next=9,Wt(c,u);case 9:return l=e.sent,f=l.address,e.abrupt("return",{url:"http://".concat(f,":").concat(u,"/").concat(Ht[t.method]),method:"POST",data:o,dataType:"json",header:JSON.parse(JSON.stringify({"Content-Type":"application/json"}))});case 12:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"callFunction",value:function(e){var t={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:e.name,functionArgs:e.data||{}})};return this.request(t,!1)}},{key:"getUploadFileOptions",value:function(e){var t={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(e)};return this.request(t)}},{key:"reportUploadFile",value:function(e){var t={method:"serverless.file.resource.report",params:JSON.stringify(e)};return this.request(t)}},{key:"uploadFile",value:function(e){var t,n=this,r=e.filePath,i=e.cloudPath,o=e.fileType,a=void 0===o?"image":o,s=e.onUploadProgress;if(!i)throw new ye({code:"CLOUDPATH_REQUIRED",message:"cloudPath不可为空"});return this.getUploadFileOptions({cloudPath:i}).then((function(e){var i=e.result,o=i.url,c=i.formData,u=i.name;return t=e.result.fileUrl,new Promise((function(e,t){var i=n.adapter.uploadFile({url:o,formData:c,name:u,filePath:r,fileType:a,success:function(n){n&&n.statusCode<400?e(n):t(new ye({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){t(new ye({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof s&&i&&"function"==typeof i.onProgressUpdate&&i.onProgressUpdate((function(e){s({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))})).then((function(){return n.reportUploadFile({cloudPath:i})})).then((function(e){return new Promise((function(n,i){e.success?n({success:!0,filePath:r,fileID:t}):i(new ye({code:"UPLOAD_FAILED",message:"文件上传失败"}))}))}))}},{key:"deleteFile",value:function(e){var t=e.fileList,n={method:"serverless.file.resource.delete",params:JSON.stringify({fileList:t})};return this.request(n).then((function(e){if(e.success)return e.result;throw new ye({code:"DELETE_FILE_FAILED",message:"删除文件失败"})}))}},{key:"getTempFileURL",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.fileList,n=e.maxAge;if(!Array.isArray(t)||0===t.length)throw new ye({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});var r={method:"serverless.file.resource.getTempFileURL",params:JSON.stringify({fileList:t,maxAge:n})};return this.request(r).then((function(e){if(e.success)return{fileList:e.result.fileList.map((function(e){return{fileID:e.fileID,tempFileURL:e.tempFileURL}}))};throw new ye({code:"GET_TEMP_FILE_URL_FAILED",message:"获取临时文件链接失败"})}))}}]),e}(),Kt={init:function(e){var t=new Vt(e),n={signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return n},t.customAuth=t.auth,t}},Gt=S((function(e,t){e.exports=T.enc.Hex}));function Jt(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function Xt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.data,r=t.functionName,i=t.method,o=t.headers,a=t.signHeaderKeys,s=void 0===a?[]:a,u=t.config,l=String(Date.now()),f=Jt(),d=Object.assign({},o,{"x-from-app-id":u.spaceAppId,"x-from-env-id":u.spaceId,"x-to-env-id":u.spaceId,"x-from-instance-id":l,"x-from-function-name":r,"x-client-timestamp":l,"x-alipay-source":"client","x-request-id":f,"x-alipay-callid":f,"x-trace-id":f}),h=["x-from-app-id","x-from-env-id","x-to-env-id","x-from-instance-id","x-from-function-name","x-client-timestamp"].concat(s),p=e.split("?")||[],g=(0,c.default)(p,2),v=g[0],y=void 0===v?"":v,m=g[1],x=void 0===m?"":m,_=function(e){var t="HMAC-SHA256",n=e.signedHeaders.join(";"),r=e.signedHeaders.map((function(t){return"".concat(t.toLowerCase(),":").concat(e.headers[t],"\n")})).join(""),i=Me(e.body).toString(Gt),o="".concat(e.method.toUpperCase(),"\n").concat(e.path,"\n").concat(e.query,"\n").concat(r,"\n").concat(n,"\n").concat(i,"\n"),a=Me(o).toString(Gt),s="".concat(t,"\n").concat(e.timestamp,"\n").concat(a,"\n"),c=Fe(s,e.secretKey).toString(Gt);return"".concat(t," Credential=").concat(e.secretId,", SignedHeaders=").concat(n,", Signature=").concat(c)}({path:y,query:x,method:i,headers:d,timestamp:l,body:JSON.stringify(n),secretId:u.accessKey,secretKey:u.secretKey,signedHeaders:h.sort()});return{url:"".concat(u.endpoint).concat(e),headers:Object.assign({},d,{Authorization:_})}}function Yt(e){var t=e.url,n=e.data,r=e.method,i=void 0===r?"POST":r,o=e.headers,a=void 0===o?{}:o,s=e.timeout;return new Promise((function(e,r){_e.request({url:t,method:i,data:"object"==(0,u.default)(n)?JSON.stringify(n):n,header:a,dataType:"json",timeout:s,complete:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=a["x-trace-id"]||"";if(!t.statusCode||t.statusCode>=400){var i=t.data||{},o=i.message,s=i.errMsg,c=i.trace_id;return r(new ye({code:"SYS_ERR",message:o||s||"request:fail",requestId:c||n}))}e({status:t.statusCode,data:t.data,headers:t.header,requestId:n})}})}))}function Qt(e,t){var n=e.path,r=e.data,i=e.method,o=void 0===i?"GET":i,a=Xt(n,{functionName:"",data:r,method:o,headers:{"x-alipay-cloud-mode":"oss","x-data-api-type":"oss","x-expire-timestamp":Date.now()+6e4},signHeaderKeys:["x-data-api-type","x-expire-timestamp"],config:t}),s=a.url,c=a.headers;return Yt({url:s,data:r,method:o,headers:c}).then((function(e){var t=e.data||{};if(!t.success)throw new ye({code:e.errCode,message:e.errMsg,requestId:e.requestId});return t.data||{}})).catch((function(e){throw new ye({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}function Zt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=e.trim().replace(/^cloud:\/\//,""),n=t.indexOf("/");if(n<=0)throw new ye({code:"INVALID_PARAM",message:"fileID不合法"});var r=t.substring(0,n),i=t.substring(n+1);return r!==this.config.spaceId&&console.warn("file ".concat(e," does not belong to env ").concat(this.config.spaceId)),i}function en(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return"cloud://".concat(this.config.spaceId,"/").concat(e.replace(/^\/+/,""))}var tn=function(){function e(t){(0,y.default)(this,e),this.config=t}return(0,m.default)(e,[{key:"signedURL",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n="/ws/function/".concat(e),r=this.config.wsEndpoint.replace(/^ws(s)?:\/\//,""),i=Object.assign({},t,{accessKeyId:this.config.accessKey,signatureNonce:Jt(),timestamp:""+Date.now()}),o=[n,["accessKeyId","authorization","signatureNonce","timestamp"].sort().map((function(e){return i[e]?"".concat(e,"=").concat(i[e]):null})).filter(Boolean).join("&"),"host:".concat(r)].join("\n"),a=["HMAC-SHA256",Me(o).toString(Gt)].join("\n"),s=Fe(a,this.config.secretKey).toString(Gt),c=Object.keys(i).map((function(e){return"".concat(e,"=").concat(encodeURIComponent(i[e]))})).join("&");return"".concat(this.config.wsEndpoint).concat(n,"?").concat(c,"&signature=").concat(s)}}]),e}(),nn=function(){function e(t){if((0,y.default)(this,e),["spaceId","spaceAppId","accessKey","secretKey"].forEach((function(e){if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error("".concat(e," required"))})),t.endpoint){if("string"!=typeof t.endpoint)throw new Error("endpoint must be string");if(!/^https:\/\//.test(t.endpoint))throw new Error("endpoint must start with https://");t.endpoint=t.endpoint.replace(/\/$/,"")}this.config=Object.assign({},t,{endpoint:t.endpoint||"https://".concat(t.spaceId,".api-hz.cloudbasefunction.cn"),wsEndpoint:t.wsEndpoint||"wss://".concat(t.spaceId,".api-hz.cloudbasefunction.cn")}),this._websocket=new tn(this.config)}return(0,m.default)(e,[{key:"callFunction",value:function(e){return function(e,t){var n=e.name,r=e.data,i=e.async,o=void 0!==i&&i,a=e.timeout,s="POST",c={"x-to-function-name":n};o&&(c["x-function-invoke-type"]="async");var u=Xt("/functions/invokeFunction",{functionName:n,data:r,method:s,headers:c,signHeaderKeys:["x-to-function-name"],config:t}),l=u.url,f=u.headers;return Yt({url:l,data:r,method:s,headers:f,timeout:a}).then((function(e){var t=0;if(o){var n=e.data||{};t="200"===n.errCode?0:n.errCode,e.data=n.data||{},e.errMsg=n.errMsg}if(0!==t)throw new ye({code:t,message:e.errMsg,requestId:e.requestId});return{errCode:t,success:0===t,requestId:e.requestId,result:e.data}})).catch((function(e){throw new ye({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}(e,this.config)}},{key:"uploadFileToOSS",value:function(e){var t=e.url,n=e.filePath,r=e.fileType,i=e.formData,o=e.onUploadProgress;return new Promise((function(e,a){var s=_e.uploadFile({url:t,filePath:n,fileType:r,formData:i,name:"file",success:function(t){t&&t.statusCode<400?e(t):a(new ye({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){a(new ye({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof o&&s&&"function"==typeof s.onProgressUpdate&&s.onProgressUpdate((function(e){o({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}},{key:"uploadFile",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r,i,o,s,c,u,l,f,d,h;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.filePath,r=t.cloudPath,i=void 0===r?"":r,o=t.fileType,s=void 0===o?"image":o,c=t.onUploadProgress,"string"===$(i)){e.next=3;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});case 3:if(i=i.trim()){e.next=5;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath不可为空"});case 5:if(!/:\/\//.test(i)){e.next=7;break}throw new ye({code:"INVALID_PARAM",message:"cloudPath不合法"});case 7:return e.next=9,Qt({path:"/".concat(i.replace(/^\//,""),"?post_url")},this.config);case 9:return u=e.sent,l=u.file_id,f=u.upload_url,d=u.form_data,h=d&&d.reduce((function(e,t){return e[t.key]=t.value,e}),{}),e.abrupt("return",this.uploadFileToOSS({url:f,filePath:n,fileType:s,formData:h,onUploadProgress:c}).then((function(){return{fileID:l}})));case 15:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTempFileURL",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r=this;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.fileList,e.abrupt("return",new Promise((function(e,t){(!n||n.length<0)&&e({code:"INVALID_PARAM",message:"fileList不能为空数组"}),n.length>50&&e({code:"INVALID_PARAM",message:"fileList数组长度不能超过50"});var i,o=[],a=_(n);try{for(a.s();!(i=a.n()).done;){var s=i.value,c=void 0;"string"!==$(s)&&e({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});try{c=Zt.call(r,s)}catch(e){console.warn(e.errCode,e.errMsg),c=s}o.push({file_id:c,expire:600})}}catch(u){a.e(u)}finally{a.f()}Qt({path:"/?download_url",data:{file_list:o},method:"POST"},r.config).then((function(t){var n=t.file_list,i=void 0===n?[]:n;e({fileList:i.map((function(e){return{fileID:en.call(r,e.file_id),tempFileURL:e.download_url}}))})})).catch((function(e){return t(e)}))})));case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()},{key:"connectWebSocket",value:function(){var e=(0,f.default)(a.default.mark((function e(t){var n,r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.name,r=t.query,e.abrupt("return",_e.connectSocket({url:this._websocket.signedURL(n,r),complete:function(){}}));case 2:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}]),e}(),rn={init:function(e){e.provider="alipay";var t=new nn(e);return t.auth=function(){return{signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!0)}}},t}};function on(e){var t,n=e.data;t=Se();var r=JSON.parse(JSON.stringify(n||{}));if(Object.assign(r,{clientInfo:t}),!r.uniIdToken){var i=be(),o=i.token;o&&(r.uniIdToken=o)}return r}var an=[{rule:/fc_function_not_found|FUNCTION_NOT_FOUND/,content:",云函数[{functionName}]在云端不存在,请检查此云函数名称是否正确以及该云函数是否已上传到服务空间",mode:"append"}],sn=/[\\^$.*+?()[\]{}|]/g,cn=RegExp(sn.source);function un(e,t,n){return e.replace(new RegExp((r=t)&&cn.test(r)?r.replace(sn,"\\$&"):r,"g"),n);var r}var ln={NONE:"none",REQUEST:"request",RESPONSE:"response",BOTH:"both"},fn="_globalUniCloudStatus",dn="_globalUniCloudSecureNetworkCache__{spaceId}",hn="uni-secure-network",pn={SYSTEM_ERROR:{code:2e4,message:"System error"},APP_INFO_INVALID:{code:20101,message:"Invalid client"},GET_ENCRYPT_KEY_FAILED:{code:20102,message:"Get encrypt key failed"}};function gn(e){var t=e||{},n=t.errSubject,r=t.subject,i=t.errCode,o=t.errMsg,a=t.code,s=t.message,c=t.cause;return new ye({subject:n||r||hn,code:i||a||pn.SYSTEM_ERROR.code,message:o||s,cause:c})}var vn;vn="0123456789abcdef";var yn;function mn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.secretType;return t===ln.REQUEST||t===ln.RESPONSE||t===ln.BOTH}function xn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=e.data,r=void 0===n?{}:n;return"app"===G&&"DCloud-clientDB"===t&&"encryption"===r.redirectTo&&"getAppClientKey"===r.action}function _n(e){e.functionName,e.result,e.logPvd}function bn(e){var t=e.callFunction,n=function(n){var r=this,i=n.name;n.data=on.call(e,{data:n.data});var o={aliyun:"aliyun",tencent:"tcb",tcb:"tcb",alipay:"alipay",dcloud:"dcloud"}[this.config.provider],a=mn(n),s=xn(n),c=a||s;return t.call(this,n).then((function(e){return e.errCode=0,!c&&_n.call(r,{functionName:i,result:e,logPvd:o}),Promise.resolve(e)}),(function(e){return!c&&_n.call(r,{functionName:i,result:e,logPvd:o}),e&&e.message&&(e.message=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.message,n=void 0===t?"":t,r=e.extraInfo,i=void 0===r?{}:r,o=e.formatter,a=void 0===o?[]:o,s=0;s<a.length;s++){var c=a[s],u=c.rule,l=c.content,f=c.mode,d=n.match(u);if(d){for(var h=l,p=1;p<d.length;p++)h=un(h,"{$".concat(p,"}"),d[p]);for(var g in i)h=un(h,"{".concat(g,"}"),i[g]);return"replace"===f?h:n+h}}return n}({message:"[".concat(n.name,"]: ").concat(e.message),formatter:an,extraInfo:{functionName:i}})),Promise.reject(e)}))};e.callFunction=function(t){var r,i,o=e.config,a=o.provider,s=o.spaceId,c=t.name;return t.data=t.data||{},r=n,r=r.bind(e),i=xn(t)?n.call(e,t):function(e){var t=e.name,n=e.data,r=void 0===n?{}:n;return"mp-weixin"===G&&"uni-id-co"===t&&"secureNetworkHandshakeByWeixin"===r.method}(t)?r.call(e,t):mn(t)?new yn({secretType:t.secretType,uniCloudIns:e}).wrapEncryptDataCallFunction(n.bind(e))(t):function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.provider,n=e.spaceId,r=e.functionName,i=ke(),o=i.appId,a=i.uniPlatform,s=i.osName,c=a;"app"===a&&(c=s);var u=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.provider,n=e.spaceId,r=K;if(!r)return{};t=function(e){return"tencent"===e?"tcb":e}(t);var i=r.find((function(e){return e.provider===t&&e.spaceId===n}));return i&&i.config}({provider:t,spaceId:n});if(!u||!u.accessControl||!u.accessControl.enable)return!1;var l=u.accessControl.function||{},f=Object.keys(l);if(0===f.length)return!0;var d=function(e,t){for(var n,r,i,o=0;o<e.length;o++){var a=e[o];a!==t?"*"!==a?a.split(",").map((function(e){return e.trim()})).indexOf(t)>-1&&(r=a):i=a:n=a}return n||r||i}(f,r);if(!d)return!1;if((l[d]||[]).find((function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e.appId===o&&(e.platform||"").toLowerCase()===c.toLowerCase()})))return!0;throw console.error("此应用[appId: ".concat(o,", platform: ").concat(c,"]不在云端配置的允许访问的应用列表内参考https://uniapp.dcloud.net.cn/uniCloud/secure-network.html#verify-client")),gn(pn.APP_INFO_INVALID)}({provider:a,spaceId:s,functionName:c})?new yn({secretType:t.secretType,uniCloudIns:e}).wrapVerifyClientCallFunction(n.bind(e))(t):r(t),Object.defineProperty(i,"result",{get:function(){return console.warn("当前返回结果为Promise类型不可直接访问其result属性详情请参考https://uniapp.dcloud.net.cn/uniCloud/faq?id=promise"),{}}}),i.then((function(e){return e}))}}yn="mp-weixin"!==G&&"app"!==G?function(){return(0,m.default)((function e(){throw(0,y.default)(this,e),gn({message:"Platform ".concat(G," is not supported by secure network")})}))}():function(){return(0,m.default)((function e(){throw(0,y.default)(this,e),gn({message:"Platform ".concat(G," is not enabled, please check whether secure network module is enabled in your manifest.json")})}))}();var wn=Symbol("CLIENT_DB_INTERNAL");function kn(e,t){return e.then="DoNotReturnProxyWithAFunctionNamedThen",e._internalType=wn,e.inspect=null,e.__ob__=void 0,new Proxy(e,{get:function(e,n,r){if("_uniClient"===n)return null;if("symbol"==(0,u.default)(n))return e[n];if(n in e||"string"!=typeof n){var i=e[n];return"function"==typeof i?i.bind(e):i}return t.get(e,n,r)}})}function An(e){return{on:function(t,n){e[t]=e[t]||[],e[t].indexOf(n)>-1||e[t].push(n)},off:function(t,n){e[t]=e[t]||[];var r=e[t].indexOf(n);-1!==r&&e[t].splice(r,1)}}}var Sn=["db.Geo","db.command","command.aggregate"];function Pn(e,t){return Sn.indexOf("".concat(e,".").concat(t))>-1}function Tn(e){switch($(e)){case"array":return e.map((function(e){return Tn(e)}));case"object":return e._internalType===wn||Object.keys(e).forEach((function(t){e[t]=Tn(e[t])})),e;case"regexp":return{$regexp:{source:e.source,flags:e.flags}};case"date":return{$date:e.toISOString()};default:return e}}function On(e){return e&&e.content&&e.content.$method}var Cn=function(){function e(t,n,r){(0,y.default)(this,e),this.content=t,this.prevStage=n||null,this.udb=null,this._database=r}return(0,m.default)(e,[{key:"toJSON",value:function(){for(var e=this,t=[e.content];e.prevStage;)e=e.prevStage,t.push(e.content);return{$db:t.reverse().map((function(e){return{$method:e.$method,$param:Tn(e.$param)}}))}}},{key:"toString",value:function(){return JSON.stringify(this.toJSON())}},{key:"getAction",value:function(){var e=this.toJSON().$db.find((function(e){return"action"===e.$method}));return e&&e.$param&&e.$param[0]}},{key:"getCommand",value:function(){return{$db:this.toJSON().$db.filter((function(e){return"action"!==e.$method}))}}},{key:"isAggregate",get:function(){for(var e=this;e;){var t=On(e),n=On(e.prevStage);if("aggregate"===t&&"collection"===n||"pipeline"===t)return!0;e=e.prevStage}return!1}},{key:"isCommand",get:function(){for(var e=this;e;){if("command"===On(e))return!0;e=e.prevStage}return!1}},{key:"isAggregateCommand",get:function(){for(var e=this;e;){var t=On(e),n=On(e.prevStage);if("aggregate"===t&&"command"===n)return!0;e=e.prevStage}return!1}},{key:"getNextStageFn",value:function(e){var t=this;return function(){return Ln({$method:e,$param:Tn(Array.from(arguments))},t,t._database)}}},{key:"count",get:function(){return this.isAggregate?this.getNextStageFn("count"):function(){return this._send("count",Array.from(arguments))}}},{key:"remove",get:function(){return this.isCommand?this.getNextStageFn("remove"):function(){return this._send("remove",Array.from(arguments))}}},{key:"get",value:function(){return this._send("get",Array.from(arguments))}},{key:"add",get:function(){return this.isCommand?this.getNextStageFn("add"):function(){return this._send("add",Array.from(arguments))}}},{key:"update",value:function(){return this._send("update",Array.from(arguments))}},{key:"end",value:function(){return this._send("end",Array.from(arguments))}},{key:"set",get:function(){return this.isCommand?this.getNextStageFn("set"):function(){throw new Error("JQL禁止使用set方法")}}},{key:"_send",value:function(e,t){var n=this.getAction(),r=this.getCommand();return r.$db.push({$method:e,$param:Tn(t)}),this._database._callCloudFunction({action:n,command:r})}}]),e}();function Ln(e,t,n){return kn(new Cn(e,t,n),{get:function(e,t){var r="db";return e&&e.content&&(r=e.content.$method),Pn(r,t)?Ln({$method:t},e,n):function(){return Ln({$method:t,$param:Tn(Array.from(arguments))},e,n)}}})}function In(e){var t=e.path,n=e.method;return function(){function e(){(0,y.default)(this,e),this.param=Array.from(arguments)}return(0,m.default)(e,[{key:"toJSON",value:function(){return{$newDb:[].concat((0,l.default)(t.map((function(e){return{$method:e}}))),[{$method:n,$param:this.param}])}}},{key:"toString",value:function(){return JSON.stringify(this.toJSON())}}]),e}()}var En=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.uniClient,r=void 0===n?{}:n,i=t.isJQL,o=void 0!==i&&i;(0,y.default)(this,e),this._uniClient=r,this._authCallBacks={},this._dbCallBacks={},r._isDefault&&(this._dbCallBacks=Q("_globalUniCloudDatabaseCallback")),o||(this.auth=An(this._authCallBacks)),this._isJQL=o,Object.assign(this,An(this._dbCallBacks)),this.env=kn({},{get:function(e,t){return{$env:t}}}),this.Geo=kn({},{get:function(e,t){return In({path:["Geo"],method:t})}}),this.serverDate=In({path:[],method:"serverDate"}),this.RegExp=In({path:[],method:"RegExp"})}return(0,m.default)(e,[{key:"getCloudEnv",value:function(e){if("string"!=typeof e||!e.trim())throw new Error("getCloudEnv参数错误");return{$env:e.replace("$cloudEnv_","")}}},{key:"_callback",value:function(e,t){var n=this._dbCallBacks;n[e]&&n[e].forEach((function(e){e.apply(void 0,(0,l.default)(t))}))}},{key:"_callbackAuth",value:function(e,t){var n=this._authCallBacks;n[e]&&n[e].forEach((function(e){e.apply(void 0,(0,l.default)(t))}))}},{key:"multiSend",value:function(){var e=Array.from(arguments),t=e.map((function(e){var t=e.getAction(),n=e.getCommand();if("getTemp"!==n.$db[n.$db.length-1].$method)throw new Error("multiSend只支持子命令内使用getTemp");return{action:t,command:n}}));return this._callCloudFunction({multiCommand:t,queryList:e})}}]),e}();function Dn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return kn(new e(t),{get:function(e,t){return Pn("db",t)?Ln({$method:t},null,e):function(){return Ln({$method:t,$param:Tn(Array.from(arguments))},null,e)}}})}var Mn=function(e){(0,h.default)(n,e);var t=A(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,m.default)(n,[{key:"_parseResult",value:function(e){return this._isJQL?e.result:e}},{key:"_callCloudFunction",value:function(e){var t=this,n=e.action,r=e.command,i=e.multiCommand,o=e.queryList;function a(e,t){if(i&&o)for(var n=0;n<o.length;n++){var r=o[n];r.udb&&"function"==typeof r.udb.setResult&&(t?r.udb.setResult(t):r.udb.setResult(e.result.dataList[n]))}}var s=this,c=this._isJQL?"databaseForJQL":"database";function u(e){return s._callback("error",[e]),re(ie(c,"fail"),e).then((function(){return re(ie(c,"complete"),e)})).then((function(){return a(null,e),de(se.RESPONSE,{type:ce.CLIENT_DB,content:e}),Promise.reject(e)}))}var l=re(ie(c,"invoke")),f=this._uniClient;return l.then((function(){return f.callFunction({name:"DCloud-clientDB",type:D.CLIENT_DB,data:{action:n,command:r,multiCommand:i}})})).then((function(e){var n=e.result,r=n.code,i=n.message,o=n.token,l=n.tokenExpired,f=n.systemInfo,d=void 0===f?[]:f;if(d)for(var h=0;h<d.length;h++){var p=d[h],g=p.level,v=p.message,y=p.detail,m="[System Info]"+v;y&&(m="".concat(m,"\n详细信息").concat(y)),(console["app"===G&&"warn"===g?"error":g]||console.log)(m)}if(r)return u(new ye({code:r,message:i,requestId:e.requestId}));e.result.errCode=e.result.errCode||e.result.code,e.result.errMsg=e.result.errMsg||e.result.message,o&&l&&(we({token:o,tokenExpired:l}),t._callbackAuth("refreshToken",[{token:o,tokenExpired:l}]),t._callback("refreshToken",[{token:o,tokenExpired:l}]),de(se.REFRESH_TOKEN,{token:o,tokenExpired:l}));for(var x=[{prop:"affectedDocs",tips:"affectedDocs不再推荐使用请使用inserted/deleted/updated/data.length替代"},{prop:"code",tips:"code不再推荐使用请使用errCode替代"},{prop:"message",tips:"message不再推荐使用请使用errMsg替代"}],_=function(t){var n=x[t],r=n.prop,i=n.tips;if(r in e.result){var o=e.result[r];Object.defineProperty(e.result,r,{get:function(){return console.warn(i),o}})}},b=0;b<x.length;b++)_(b);return function(e){return re(ie(c,"success"),e).then((function(){return re(ie(c,"complete"),e)})).then((function(){a(e,null);var t=s._parseResult(e);return de(se.RESPONSE,{type:ce.CLIENT_DB,content:t}),Promise.resolve(t)}))}(e)}),(function(e){return/fc_function_not_found|FUNCTION_NOT_FOUND/g.test(e.message)&&console.warn("clientDB未初始化请在web控制台保存一次schema以开启clientDB"),u(new ye({code:e.code||"SYSTEM_ERROR",message:e.message,requestId:e.requestId}))}))}}]),n}(En),Fn="token无效跳转登录页面",jn="token过期跳转登录页面",$n={TOKEN_INVALID_TOKEN_EXPIRED:jn,TOKEN_INVALID_INVALID_CLIENTID:Fn,TOKEN_INVALID:Fn,TOKEN_INVALID_WRONG_TOKEN:Fn,TOKEN_INVALID_ANONYMOUS_USER:Fn},Rn={"uni-id-token-expired":jn,"uni-id-check-token-failed":Fn,"uni-id-token-not-exist":Fn,"uni-id-check-device-feature-failed":Fn},Nn=k(k(k({},$n),Rn),{},{default:"用户未登录或登录状态过期,自动跳转登录页面"});function Un(e,t){var n="";return n=e?"".concat(e,"/").concat(t):t,n.replace(/^\//,"")}function Bn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=[],r=[];return e.forEach((function(e){!0===e.needLogin?n.push(Un(t,e.path)):!1===e.needLogin&&r.push(Un(t,e.path))})),{needLoginPage:n,notNeedLoginPage:r}}function zn(e){return e.split("?")[0].replace(/^\//,"")}function Wn(){return function(e){var t=e&&e.$page&&e.$page.fullPath;return t?("/"!==t.charAt(0)&&(t="/"+t),t):""}(function(){var e=getCurrentPages();return e[e.length-1]}())}function qn(){return zn(Wn())}function Hn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return!1;if(!(t&&t.list&&t.list.length))return!1;var n=t.list,r=zn(e);return n.some((function(e){return e.pagePath===r}))}var Vn,Kn=!!x.default.uniIdRouter,Gn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:x.default,t=e.pages,n=void 0===t?[]:t,r=e.subPackages,i=void 0===r?[]:r,o=e.uniIdRouter,a=void 0===o?{}:o,s=e.tabBar,c=void 0===s?{}:s,u=a.loginPage,f=a.needLogin,d=void 0===f?[]:f,h=a.resToLogin,p=void 0===h||h,g=Bn(n),v=g.needLoginPage,y=g.notNeedLoginPage,m=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=[],n=[];return e.forEach((function(e){var r=e.root,i=e.pages,o=void 0===i?[]:i,a=Bn(o,r),s=a.needLoginPage,c=a.notNeedLoginPage;t.push.apply(t,(0,l.default)(s)),n.push.apply(n,(0,l.default)(c))})),{needLoginPage:t,notNeedLoginPage:n}}(i),_=m.needLoginPage,b=m.notNeedLoginPage;return{loginPage:u,routerNeedLogin:d,resToLogin:p,needLoginPage:[].concat((0,l.default)(v),(0,l.default)(_)),notNeedLoginPage:[].concat((0,l.default)(y),(0,l.default)(b)),loginPageInTabBar:Hn(u,c)}}(),Jn=Gn.loginPage,Xn=Gn.routerNeedLogin,Yn=Gn.resToLogin,Qn=Gn.needLoginPage,Zn=Gn.notNeedLoginPage,er=Gn.loginPageInTabBar;if(Qn.indexOf(Jn)>-1)throw new Error("Login page [".concat(Jn,'] should not be "needLogin", please check your pages.json'));function tr(e){var t=qn();if("/"===e.charAt(0))return e;var n=e.split("?"),r=(0,c.default)(n,2),i=r[0],o=r[1],a=i.replace(/^\//,"").split("/"),s=t.split("/");s.pop();for(var u=0;u<a.length;u++){var l=a[u];".."===l?s.pop():"."!==l&&s.push(l)}return""===s[0]&&s.shift(),"/"+s.join("/")+(o?"?"+o:"")}function nr(e){var t=zn(tr(e));return!(Zn.indexOf(t)>-1)&&(Qn.indexOf(t)>-1||Xn.some((function(t){return function(e,t){return new RegExp(t).test(e)}(e,t)})))}function rr(e){var t=e.redirect,n=zn(t),r=zn(Jn);return qn()!==r&&n!==r}function ir(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.api,n=e.redirect;if(n&&rr({redirect:n})){var i=function(e,t){return"/"!==e.charAt(0)&&(e="/"+e),t?e.indexOf("?")>-1?e+"&uniIdRedirectUrl=".concat(encodeURIComponent(t)):e+"?uniIdRedirectUrl=".concat(encodeURIComponent(t)):e}(Jn,n);er?"navigateTo"!==t&&"redirectTo"!==t||(t="switchTab"):"switchTab"===t&&(t="navigateTo");var o={navigateTo:r.navigateTo,redirectTo:r.redirectTo,switchTab:r.switchTab,reLaunch:r.reLaunch};setTimeout((function(){o[t]({url:i})}),0)}}function or(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.url,n={abortLoginPageJump:!1,autoToLoginPage:!1},r=function(){var e,t=be(),n=t.token,r=t.tokenExpired;if(n){if(r<Date.now()){var i="uni-id-token-expired";e={errCode:i,errMsg:Nn[i]}}}else{var o="uni-id-check-token-failed";e={errCode:o,errMsg:Nn[o]}}return e}();if(nr(t)&&r){if(r.uniIdRedirectUrl=t,ue(se.NEED_LOGIN).length>0)return setTimeout((function(){de(se.NEED_LOGIN,r)}),0),n.abortLoginPageJump=!0,n;n.autoToLoginPage=!0}return n}function ar(){!function(){var e=Wn(),t=or({url:e}),n=t.abortLoginPageJump,r=t.autoToLoginPage;n||r&&ir({api:"redirectTo",redirect:e})}();for(var e=["navigateTo","redirectTo","reLaunch","switchTab"],t=function(t){var n=e[t];r.addInterceptor(n,{invoke:function(e){var t=or({url:e.url}),r=t.abortLoginPageJump,i=t.autoToLoginPage;return r?e:i?(ir({api:n,redirect:tr(e.url)}),!1):e}})},n=0;n<e.length;n++)t(n)}function sr(){this.onResponse((function(e){var t=e.type,n=e.content,r=!1;switch(t){case"cloudobject":r=function(e){if("object"!=(0,u.default)(e))return!1;var t=e||{},n=t.errCode;return n in Nn}(n);break;case"clientdb":r=function(e){if("object"!=(0,u.default)(e))return!1;var t=e||{},n=t.errCode;return n in $n}(n)}r&&function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ue(se.NEED_LOGIN);ge().then((function(){var n=Wn();if(n&&rr({redirect:n}))return t.length>0?de(se.NEED_LOGIN,Object.assign({uniIdRedirectUrl:n},e)):void(Jn&&ir({api:"navigateTo",redirect:n}))}))}(n)}))}function cr(e){!function(e){e.onResponse=function(e){le(se.RESPONSE,e)},e.offResponse=function(e){fe(se.RESPONSE,e)}}(e),function(e){e.onNeedLogin=function(e){le(se.NEED_LOGIN,e)},e.offNeedLogin=function(e){fe(se.NEED_LOGIN,e)},Kn&&(Q(fn).needLoginInit||(Q(fn).needLoginInit=!0,ge().then((function(){ar.call(e)})),Yn&&sr.call(e)))}(e),function(e){e.onRefreshToken=function(e){le(se.REFRESH_TOKEN,e)},e.offRefreshToken=function(e){fe(se.REFRESH_TOKEN,e)}}(e)}var ur="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",lr=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function fr(){var e,t,n=be().token||"",r=n.split(".");if(!n||3!==r.length)return{uid:null,role:[],permission:[],tokenExpired:0};try{e=JSON.parse((t=r[1],decodeURIComponent(Vn(t).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))))}catch(n){throw new Error("获取当前用户信息出错,详细错误信息为:"+n.message)}return e.tokenExpired=1e3*e.exp,delete e.exp,delete e.iat,e}Vn="function"!=typeof atob?function(e){if(e=String(e).replace(/[\t\n\f\r ]+/g,""),!lr.test(e))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var t;e+="==".slice(2-(3&e.length));for(var n,r,i="",o=0;o<e.length;)t=ur.indexOf(e.charAt(o++))<<18|ur.indexOf(e.charAt(o++))<<12|(n=ur.indexOf(e.charAt(o++)))<<6|(r=ur.indexOf(e.charAt(o++))),i+=64===n?String.fromCharCode(t>>16&255):64===r?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,255&t);return i}:atob;var dr=S((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n="chooseAndUploadFile:ok",o="chooseAndUploadFile:fail";function a(e,t){return e.tempFiles.forEach((function(e,n){e.name||(e.name=e.path.substring(e.path.lastIndexOf("/")+1)),t&&(e.fileType=t),e.cloudPath=Date.now()+"_"+n+e.name.substring(e.name.lastIndexOf("."))})),e.tempFilePaths||(e.tempFilePaths=e.tempFiles.map((function(e){return e.path}))),e}function s(e,t,r){var i=r.onChooseFile,o=r.onUploadProgress;return t.then((function(e){if(i){var t=i(e);if(void 0!==t)return Promise.resolve(t).then((function(t){return void 0===t?e:t}))}return e})).then((function(t){return!1===t?{errMsg:n,tempFilePaths:[],tempFiles:[]}:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,i=arguments.length>3?arguments[3]:void 0;(t=Object.assign({},t)).errMsg=n;var o=t.tempFiles,a=o.length,s=0;return new Promise((function(n){for(;s<r;)c();function c(){var r=s++;if(r>=a)!o.find((function(e){return!e.url&&!e.errMsg}))&&n(t);else{var u=o[r];e.uploadFile({provider:u.provider,filePath:u.path,cloudPath:u.cloudPath,fileType:u.fileType,cloudPathAsRealPath:u.cloudPathAsRealPath,onUploadProgress:function(e){e.index=r,e.tempFile=u,e.tempFilePath=u.path,i&&i(e)}}).then((function(e){u.url=e.fileID,r<a&&c()})).catch((function(e){u.errMsg=e.errMsg||e.message,r<a&&c()}))}}}))}(e,t,5,o)}))}t.initChooseAndUploadFile=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{type:"all"};return"image"===t.type?s(e,function(e){var t=e.count,n=e.sizeType,i=e.sourceType,s=void 0===i?["album","camera"]:i,c=e.extension;return new Promise((function(e,i){r.chooseImage({count:t,sizeType:n,sourceType:s,extension:c,success:function(t){e(a(t,"image"))},fail:function(e){i({errMsg:e.errMsg.replace("chooseImage:fail",o)})}})}))}(t),t):"video"===t.type?s(e,function(e){var t=e.camera,n=e.compressed,i=e.maxDuration,s=e.sourceType,c=void 0===s?["album","camera"]:s,u=e.extension;return new Promise((function(e,s){r.chooseVideo({camera:t,compressed:n,maxDuration:i,sourceType:c,extension:u,success:function(t){var n=t.tempFilePath,r=t.duration,i=t.size,o=t.height,s=t.width;e(a({errMsg:"chooseVideo:ok",tempFilePaths:[n],tempFiles:[{name:t.tempFile&&t.tempFile.name||"",path:n,size:i,type:t.tempFile&&t.tempFile.type||"",width:s,height:o,duration:r,fileType:"video",cloudPath:""}]},"video"))},fail:function(e){s({errMsg:e.errMsg.replace("chooseVideo:fail",o)})}})}))}(t),t):s(e,function(e){var t=e.count,n=e.extension;return new Promise((function(e,s){var c=r.chooseFile;if("undefined"!=typeof i&&"function"==typeof i.chooseMessageFile&&(c=i.chooseMessageFile),"function"!=typeof c)return s({errMsg:o+" 请指定 type 类型,该平台仅支持选择 image 或 video。"});c({type:"all",count:t,extension:n,success:function(t){e(a(t))},fail:function(e){s({errMsg:e.errMsg.replace("chooseFile:fail",o)})}})}))}(t),t)}}})),hr=function(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}(dr),pr={auto:"auto",onready:"onready",manual:"manual"};function gr(e){return{props:{localdata:{type:Array,default:function(){return[]}},options:{type:[Object,Array],default:function(){return{}}},spaceInfo:{type:Object,default:function(){return{}}},collection:{type:[String,Array],default:""},action:{type:String,default:""},field:{type:String,default:""},orderby:{type:String,default:""},where:{type:[String,Object],default:""},pageData:{type:String,default:"add"},pageCurrent:{type:Number,default:1},pageSize:{type:Number,default:20},getcount:{type:[Boolean,String],default:!1},gettree:{type:[Boolean,String],default:!1},gettreepath:{type:[Boolean,String],default:!1},startwith:{type:String,default:""},limitlevel:{type:Number,default:10},groupby:{type:String,default:""},groupField:{type:String,default:""},distinct:{type:[Boolean,String],default:!1},foreignKey:{type:String,default:""},loadtime:{type:String,default:"auto"},manual:{type:Boolean,default:!1}},data:function(){return{mixinDatacomLoading:!1,mixinDatacomHasMore:!1,mixinDatacomResData:[],mixinDatacomErrorMessage:"",mixinDatacomPage:{},mixinDatacomError:null}},created:function(){var e=this;this.mixinDatacomPage={current:this.pageCurrent,size:this.pageSize,count:0},this.$watch((function(){var t=[];return["pageCurrent","pageSize","localdata","collection","action","field","orderby","where","getont","getcount","gettree","groupby","groupField","distinct"].forEach((function(n){t.push(e[n])})),t}),(function(t,n){if(e.loadtime!==pr.manual){for(var r=!1,i=[],o=2;o<t.length;o++)t[o]!==n[o]&&(i.push(t[o]),r=!0);t[0]!==n[0]&&(e.mixinDatacomPage.current=e.pageCurrent),e.mixinDatacomPage.size=e.pageSize,e.onMixinDatacomPropsChange(r,i)}}))},methods:{onMixinDatacomPropsChange:function(e,t){},mixinDatacomEasyGet:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.getone,r=void 0!==n&&n,i=t.success,o=t.fail;this.mixinDatacomLoading||(this.mixinDatacomLoading=!0,this.mixinDatacomErrorMessage="",this.mixinDatacomError=null,this.mixinDatacomGet().then((function(t){e.mixinDatacomLoading=!1;var n=t.result,o=n.data,a=n.count;e.getcount&&(e.mixinDatacomPage.count=a),e.mixinDatacomHasMore=o.length<e.pageSize;var s=r?o.length?o[0]:void 0:o;e.mixinDatacomResData=s,i&&i(s)})).catch((function(t){e.mixinDatacomLoading=!1,e.mixinDatacomErrorMessage=t,e.mixinDatacomError=t,o&&o(t)})))},mixinDatacomGet:function(){var t,n,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r=r||{},n="undefined"!=typeof __uniX&&__uniX?e.databaseForJQL(this.spaceInfo):e.database(this.spaceInfo);var i=r.action||this.action;i&&(n=n.action(i));var o=r.collection||this.collection;n=Array.isArray(o)?(t=n).collection.apply(t,(0,l.default)(o)):n.collection(o);var a=r.where||this.where;a&&Object.keys(a).length&&(n=n.where(a));var s=r.field||this.field;s&&(n=n.field(s));var c=r.foreignKey||this.foreignKey;c&&(n=n.foreignKey(c));var u=r.groupby||this.groupby;u&&(n=n.groupBy(u));var f=r.groupField||this.groupField;f&&(n=n.groupField(f)),!0===(void 0!==r.distinct?r.distinct:this.distinct)&&(n=n.distinct());var d=r.orderby||this.orderby;d&&(n=n.orderBy(d));var h=void 0!==r.pageCurrent?r.pageCurrent:this.mixinDatacomPage.current,p=void 0!==r.pageSize?r.pageSize:this.mixinDatacomPage.size,g=void 0!==r.getcount?r.getcount:this.getcount,v=void 0!==r.gettree?r.gettree:this.gettree,y=void 0!==r.gettreepath?r.gettreepath:this.gettreepath,m={getCount:g},x={limitLevel:void 0!==r.limitlevel?r.limitlevel:this.limitlevel,startWith:void 0!==r.startwith?r.startwith:this.startwith};return v&&(m.getTree=x),y&&(m.getTreePath=x),n=n.skip(p*(h-1)).limit(p).get(m),n}}}}function vr(e){return Q(dn.replace("{spaceId}",e.config.spaceId))}function yr(){return mr.apply(this,arguments)}function mr(){return mr=(0,f.default)(a.default.mark((function e(){var t,n,i,o,s,c,u,l=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=l.length>0&&void 0!==l[0]?l[0]:{},n=t.openid,i=t.callLoginByWeixin,o=void 0!==i&&i,s=vr(this),"mp-weixin"===G){e.next=4;break}throw new Error("[SecureNetwork] API `initSecureNetworkByWeixin` is not supported on platform `".concat(G,"`"));case 4:if(!n||!o){e.next=6;break}throw new Error("[SecureNetwork] openid and callLoginByWeixin cannot be passed at the same time");case 6:if(!n){e.next=8;break}return e.abrupt("return",(s.mpWeixinOpenid=n,{}));case 8:return e.next=10,new Promise((function(e,t){r.login({success:function(t){e(t.code)},fail:function(e){t(new Error(e.errMsg))}})}));case 10:return c=e.sent,u=this.importObject("uni-id-co",{customUI:!0}),e.next=14,u.secureNetworkHandshakeByWeixin({code:c,callLoginByWeixin:o});case 14:return s.mpWeixinCode=c,e.abrupt("return",{code:c});case 16:case"end":return e.stop()}}),e,this)}))),mr.apply(this,arguments)}function xr(e){return _r.apply(this,arguments)}function _r(){return _r=(0,f.default)(a.default.mark((function e(t){var n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=vr(this),e.abrupt("return",(n.initPromise||(n.initPromise=yr.call(this,t).then((function(e){return e})).catch((function(e){throw delete n.initPromise,e}))),n.initPromise));case 2:case"end":return e.stop()}}),e,this)}))),_r.apply(this,arguments)}function br(e){!function(e){Ae=e}(e)}function wr(e){var t="mp-weixin"===G&&i.canIUse("getAppBaseInfo"),n={getAppBaseInfo:t?r.getAppBaseInfo:r.getSystemInfo,getPushClientId:r.getPushClientId};return function(r){return new Promise((function(i,o){t&&"getAppBaseInfo"===e?i(n[e]()):n[e](k(k({},r),{},{success:function(e){i(e)},fail:function(e){o(e)}}))}))}}var kr=function(e){(0,h.default)(n,e);var t=A(n);function n(){var e;return(0,y.default)(this,n),e=t.call(this),e._uniPushMessageCallback=e._receivePushMessage.bind((0,s.default)(e)),e._currentMessageId=-1,e._payloadQueue=[],e}return(0,m.default)(n,[{key:"init",value:function(){var e=this;return Promise.all([wr("getAppBaseInfo")(),wr("getPushClientId")()]).then((function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=(0,c.default)(t,2),r=n[0];r=void 0===r?{}:r;var i=r.appId,o=n[1];o=void 0===o?{}:o;var a=o.cid;if(!i)throw new Error("Invalid appId, please check the manifest.json file");if(!a)throw new Error("Invalid push client id");e._appId=i,e._pushClientId=a,e._seqId=Date.now()+"-"+Math.floor(9e5*Math.random()+1e5),e.emit("open"),e._initMessageListener()}),(function(t){throw e.emit("error",t),e.close(),t}))}},{key:"open",value:function(){var e=(0,f.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this.init());case 1:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"_isUniCloudSSE",value:function(e){if("receive"!==e.type)return!1;var t=e&&e.data&&e.data.payload;return!(!t||"UNI_CLOUD_SSE"!==t.channel||t.seqId!==this._seqId)}},{key:"_receivePushMessage",value:function(e){if(this._isUniCloudSSE(e)){var t=e&&e.data&&e.data.payload,n=t.action,r=t.messageId,i=t.message;this._payloadQueue.push({action:n,messageId:r,message:i}),this._consumMessage()}}},{key:"_consumMessage",value:function(){for(var e=this;;){var t=this._payloadQueue.find((function(t){return t.messageId===e._currentMessageId+1}));if(!t)break;this._currentMessageId++,this._parseMessagePayload(t)}}},{key:"_parseMessagePayload",value:function(e){var t=e.action,n=e.messageId,r=e.message;"end"===t?this._end({messageId:n,message:r}):"message"===t&&this._appendMessage({messageId:n,message:r})}},{key:"_appendMessage",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(e.messageId,e.message);this.emit("message",t)}},{key:"_end",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(e.messageId,e.message);this.emit("end",t),this.close()}},{key:"_initMessageListener",value:function(){r.onPushMessage(this._uniPushMessageCallback)}},{key:"_destroy",value:function(){r.offPushMessage(this._uniPushMessageCallback)}},{key:"toJSON",value:function(){return{appId:this._appId,pushClientId:this._pushClientId,seqId:this._seqId}}},{key:"close",value:function(){this._destroy(),this.emit("close")}}]),n}(q);var Ar={tcb:Ut,tencent:Ut,aliyun:Ce,private:Kt,dcloud:Kt,alipay:rn},Sr=new(function(){function e(){(0,y.default)(this,e)}return(0,m.default)(e,[{key:"init",value:function(e){var t={},n=Ar[e.provider];if(!n)throw new Error("未提供正确的provider参数");return t=n.init(e),function(e){e._initPromiseHub||(e._initPromiseHub=new W({createPromise:function(){var t=Promise.resolve();t=new Promise((function(e){setTimeout((function(){e()}),1)}));var n=e.auth();return t.then((function(){return n.getLoginState()})).then((function(e){return e?Promise.resolve():n.signInAnonymously()}))}}))}(t),bn(t),function(e){var t=e.uploadFile;e.uploadFile=function(e){return t.call(this,e)}}(t),function(e){e.database=function(t){if(t&&Object.keys(t).length>0)return e.init(t).database();if(this._database)return this._database;var n=Dn(Mn,{uniClient:e});return this._database=n,n},e.databaseForJQL=function(t){if(t&&Object.keys(t).length>0)return e.init(t).databaseForJQL();if(this._databaseForJQL)return this._databaseForJQL;var n=Dn(Mn,{uniClient:e,isJQL:!0});return this._databaseForJQL=n,n}}(t),function(e){e.getCurrentUserInfo=fr,e.chooseAndUploadFile=hr.initChooseAndUploadFile(e),Object.assign(e,{get mixinDatacom(){return gr(e)}}),e.SSEChannel=kr,e.initSecureNetworkByWeixin=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.openid,r=t.callLoginByWeixin,i=void 0!==r&&r;return xr.call(e,{openid:n,callLoginByWeixin:i})}}(e),e.setCustomClientInfo=br,e.importObject=function(e){return function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.customUI=t.customUI||e.customUI,e.parseSystemError=t.parseSystemError||e.parseSystemError,Object.assign(e.loadingOptions,t.loadingOptions),Object.assign(e.errorOptions,t.errorOptions),"object"==(0,u.default)(t.secretMethods)&&(e.secretMethods=t.secretMethods),e}({customUI:!1,loadingOptions:{title:"加载中...",mask:!0},errorOptions:{type:"modal",retry:!1}},n);var i=n,o=i.customUI,s=i.loadingOptions,c=i.errorOptions,l=i.parseSystemError,d=!o;return new Proxy({},{get:function(i,o){switch(o){case"toString":return"[object UniCloudObject]";case"toJSON":return{}}return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.fn,n=e.interceptorName,r=e.getCallbackArgs;return(0,f.default)(a.default.mark((function e(){var i,o,s,c,u,l,f=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(i=f.length,o=new Array(i),s=0;s<i;s++)o[s]=f[s];return c=r?r({params:o}):{},e.prev=2,e.next=5,re(ie(n,"invoke"),k({},c));case 5:return e.next=7,t.apply(void 0,o);case 7:return u=e.sent,e.next=10,re(ie(n,"success"),k(k({},c),{},{result:u}));case 10:return e.abrupt("return",u);case 13:return e.prev=13,e.t0=e["catch"](2),l=e.t0,e.next=18,re(ie(n,"fail"),k(k({},c),{},{error:l}));case 18:throw l;case 19:return e.prev=19,e.next=22,re(ie(n,"complete"),k(k({},c),{},l?{error:l}:{result:u}));case 22:return e.finish(19);case 23:case"end":return e.stop()}}),e,null,[[2,13,19,23]])})))}({fn:function(){var i=(0,f.default)(a.default.mark((function i(){var p,g,v,y,m,x,_,b,w,A,S,P,T,O,C,L=arguments;return a.default.wrap((function(i){while(1)switch(i.prev=i.next){case 0:for(d&&r.showLoading({title:s.title,mask:s.mask}),g=L.length,v=new Array(g),y=0;y<g;y++)v[y]=L[y];return m={name:t,type:D.OBJECT,data:{method:o,params:v}},"object"==(0,u.default)(n.secretMethods)&&function(e,t){var n=t.data.method,r=e.secretMethods||{},i=r[n]||r["*"];i&&(t.secretType=i)}(n,m),x=!1,i.prev=5,i.next=8,e.callFunction(m);case 8:p=i.sent,i.next=14;break;case 11:i.prev=11,i.t0=i["catch"](5),x=!0,p={result:new ye(i.t0)};case 14:if(_=p.result||{},b=_.errSubject,w=_.errCode,A=_.errMsg,S=_.newToken,d&&r.hideLoading(),S&&S.token&&S.tokenExpired&&(we(S),de(se.REFRESH_TOKEN,k({},S))),!w){i.next=39;break}if(P=A,!x||!l){i.next=24;break}return i.next=20,l({objectName:t,methodName:o,params:v,errSubject:b,errCode:w,errMsg:A});case 20:if(i.t1=i.sent.errMsg,i.t1){i.next=23;break}i.t1=A;case 23:P=i.t1;case 24:if(!d){i.next=37;break}if("toast"!==c.type){i.next=29;break}r.showToast({title:P,icon:"none"}),i.next=37;break;case 29:if("modal"===c.type){i.next=31;break}throw new Error("Invalid errorOptions.type: ".concat(c.type));case 31:return i.next=33,(0,f.default)(a.default.mark((function e(){var t,n,i,o,s,c,u=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=u.length>0&&void 0!==u[0]?u[0]:{},n=t.title,i=t.content,o=t.showCancel,s=t.cancelText,c=t.confirmText,e.abrupt("return",new Promise((function(e,t){r.showModal({title:n,content:i,showCancel:o,cancelText:s,confirmText:c,success:function(t){e(t)},fail:function(){e({confirm:!1,cancel:!0})}})})));case 2:case"end":return e.stop()}}),e)})))({title:"提示",content:P,showCancel:c.retry,cancelText:"取消",confirmText:c.retry?"重试":"确定"});case 33:if(T=i.sent,O=T.confirm,!c.retry||!O){i.next=37;break}return i.abrupt("return",h.apply(void 0,v));case 37:throw C=new ye({subject:b,code:w,message:A,requestId:p.requestId}),C.detail=p.result,de(se.RESPONSE,{type:ce.CLOUD_OBJECT,content:C}),C;case 39:return i.abrupt("return",(de(se.RESPONSE,{type:ce.CLOUD_OBJECT,content:p.result}),p.result));case 40:case"end":return i.stop()}}),i,null,[[5,11]])})));function h(){return i.apply(this,arguments)}return h}(),interceptorName:"callObject",getCallbackArgs:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.params;return{objectName:t,methodName:o,params:n}}})}})}}(e)}(t),["callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","chooseAndUploadFile"].forEach((function(e){if(t[e]){var n=t[e];t[e]=function(){return n.apply(t,Array.from(arguments))},t[e]=function(e,t){return function(n){var r=this,i=!1;if("callFunction"===t){var o=n&&n.type||D.DEFAULT;i=o!==D.DEFAULT}var a="callFunction"===t&&!i,s=this._initPromiseHub.exec();n=n||{};var c=ve(n),u=c.success,l=c.fail,f=c.complete,d=s.then((function(){return i?Promise.resolve():re(ie(t,"invoke"),n)})).then((function(){return e.call(r,n)})).then((function(e){return i?Promise.resolve(e):re(ie(t,"success"),e).then((function(){return re(ie(t,"complete"),e)})).then((function(){return a&&de(se.RESPONSE,{type:ce.CLOUD_FUNCTION,content:e}),Promise.resolve(e)}))}),(function(e){return i?Promise.reject(e):re(ie(t,"fail"),e).then((function(){return re(ie(t,"complete"),e)})).then((function(){return de(se.RESPONSE,{type:ce.CLOUD_FUNCTION,content:e}),Promise.reject(e)}))}));if(!(u||l||f))return d;d.then((function(e){u&&u(e),f&&f(e),a&&de(se.RESPONSE,{type:ce.CLOUD_FUNCTION,content:e})}),(function(e){l&&l(e),f&&f(e),a&&de(se.RESPONSE,{type:ce.CLOUD_FUNCTION,content:e})}))}}(t[e],e).bind(t)}})),t.init=this.init,t}}]),e}());t.uniCloud=Sr,function(){var e=J,n={};if(e&&1===e.length)n=e[0],t.uniCloud=Sr=Sr.init(n),Sr._isDefault=!0;else{var i,o=["database","getCurrentUserInfo","importObject"];i=e&&e.length>0?"应用有多个服务空间请通过uniCloud.init方法指定要使用的服务空间":"应用未关联服务空间请在uniCloud目录右键关联服务空间",[].concat(["auth","callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile"],o).forEach((function(e){Sr[e]=function(){if(console.error(i),-1===o.indexOf(e))return Promise.reject(new ye({code:"SYS_ERR",message:i}));console.error(i)}}))}if(Object.assign(Sr,{get mixinDatacom(){return gr(Sr)}}),cr(Sr),Sr.addInterceptor=te,Sr.removeInterceptor=ne,Sr.interceptObject=oe,"app"===G&&(r.__uniCloud=Sr),"app"===G||"web"===G){var a=function(){return X||(X=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;function e(){return this}return void 0!==e()?e():new Function("return this")()}(),X)}();a.uniCloud=Sr,a.UniCloudError=ye}}();var Pr=Sr;t.default=Pr}).call(this,n("0ee4"),n("df3c")["default"],n("3223")["default"])},"8f59":function(e,t,n){"use strict";(function(t){var n="undefined"!==typeof window?window:"undefined"!==typeof t?t:{},r=n.__VUE_DEVTOOLS_GLOBAL_HOOK__;function i(e,t){if(void 0===t&&(t=[]),null===e||"object"!==typeof e)return e;var n=function(e,t){return e.filter(t)[0]}(t,(function(t){return t.original===e}));if(n)return n.copy;var r=Array.isArray(e)?[]:{};return t.push({original:e,copy:r}),Object.keys(e).forEach((function(n){r[n]=i(e[n],t)})),r}function o(e,t){Object.keys(e).forEach((function(n){return t(e[n],n)}))}function a(e){return null!==e&&"object"===typeof e}var s=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var n=e.state;this.state=("function"===typeof n?n():n)||{}},c={namespaced:{configurable:!0}};c.namespaced.get=function(){return!!this._rawModule.namespaced},s.prototype.addChild=function(e,t){this._children[e]=t},s.prototype.removeChild=function(e){delete this._children[e]},s.prototype.getChild=function(e){return this._children[e]},s.prototype.hasChild=function(e){return e in this._children},s.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)},s.prototype.forEachChild=function(e){o(this._children,e)},s.prototype.forEachGetter=function(e){this._rawModule.getters&&o(this._rawModule.getters,e)},s.prototype.forEachAction=function(e){this._rawModule.actions&&o(this._rawModule.actions,e)},s.prototype.forEachMutation=function(e){this._rawModule.mutations&&o(this._rawModule.mutations,e)},Object.defineProperties(s.prototype,c);var u=function(e){this.register([],e,!1)};u.prototype.get=function(e){return e.reduce((function(e,t){return e.getChild(t)}),this.root)},u.prototype.getNamespace=function(e){var t=this.root;return e.reduce((function(e,n){return t=t.getChild(n),e+(t.namespaced?n+"/":"")}),"")},u.prototype.update=function(e){(function e(t,n,r){0;if(n.update(r),r.modules)for(var i in r.modules){if(!n.getChild(i))return void 0;e(t.concat(i),n.getChild(i),r.modules[i])}})([],this.root,e)},u.prototype.register=function(e,t,n){var r=this;void 0===n&&(n=!0);var i=new s(t,n);if(0===e.length)this.root=i;else{var a=this.get(e.slice(0,-1));a.addChild(e[e.length-1],i)}t.modules&&o(t.modules,(function(t,i){r.register(e.concat(i),t,n)}))},u.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1],r=t.getChild(n);r&&r.runtime&&t.removeChild(n)},u.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1];return!!t&&t.hasChild(n)};var l;var f=function(e){var t=this;void 0===e&&(e={}),!l&&"undefined"!==typeof window&&window.Vue&&x(window.Vue);var n=e.plugins;void 0===n&&(n=[]);var i=e.strict;void 0===i&&(i=!1),this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new u(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._watcherVM=new l,this._makeLocalGettersCache=Object.create(null);var o=this,a=this.dispatch,s=this.commit;this.dispatch=function(e,t){return a.call(o,e,t)},this.commit=function(e,t,n){return s.call(o,e,t,n)},this.strict=i;var c=this._modules.root.state;v(this,c,[],this._modules.root),g(this,c),n.forEach((function(e){return e(t)}));var f=void 0!==e.devtools?e.devtools:l.config.devtools;f&&function(e){r&&(e._devtoolHook=r,r.emit("vuex:init",e),r.on("vuex:travel-to-state",(function(t){e.replaceState(t)})),e.subscribe((function(e,t){r.emit("vuex:mutation",e,t)}),{prepend:!0}),e.subscribeAction((function(e,t){r.emit("vuex:action",e,t)}),{prepend:!0}))}(this)},d={state:{configurable:!0}};function h(e,t,n){return t.indexOf(e)<0&&(n&&n.prepend?t.unshift(e):t.push(e)),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function p(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var n=e.state;v(e,n,[],e._modules.root,!0),g(e,n,t)}function g(e,t,n){var r=e._vm;e.getters={},e._makeLocalGettersCache=Object.create(null);var i=e._wrappedGetters,a={};o(i,(function(t,n){a[n]=function(e,t){return function(){return e(t)}}(t,e),Object.defineProperty(e.getters,n,{get:function(){return e._vm[n]},enumerable:!0})}));var s=l.config.silent;l.config.silent=!0,e._vm=new l({data:{$$state:t},computed:a}),l.config.silent=s,e.strict&&function(e){e._vm.$watch((function(){return this._data.$$state}),(function(){0}),{deep:!0,sync:!0})}(e),r&&(n&&e._withCommit((function(){r._data.$$state=null})),l.nextTick((function(){return r.$destroy()})))}function v(e,t,n,r,i){var o=!n.length,a=e._modules.getNamespace(n);if(r.namespaced&&(e._modulesNamespaceMap[a],e._modulesNamespaceMap[a]=r),!o&&!i){var s=y(t,n.slice(0,-1)),c=n[n.length-1];e._withCommit((function(){l.set(s,c,r.state)}))}var u=r.context=function(e,t,n){var r=""===t,i={dispatch:r?e.dispatch:function(n,r,i){var o=m(n,r,i),a=o.payload,s=o.options,c=o.type;return s&&s.root||(c=t+c),e.dispatch(c,a)},commit:r?e.commit:function(n,r,i){var o=m(n,r,i),a=o.payload,s=o.options,c=o.type;s&&s.root||(c=t+c),e.commit(c,a,s)}};return Object.defineProperties(i,{getters:{get:r?function(){return e.getters}:function(){return function(e,t){if(!e._makeLocalGettersCache[t]){var n={},r=t.length;Object.keys(e.getters).forEach((function(i){if(i.slice(0,r)===t){var o=i.slice(r);Object.defineProperty(n,o,{get:function(){return e.getters[i]},enumerable:!0})}})),e._makeLocalGettersCache[t]=n}return e._makeLocalGettersCache[t]}(e,t)}},state:{get:function(){return y(e.state,n)}}}),i}(e,a,n);r.forEachMutation((function(t,n){var r=a+n;(function(e,t,n,r){var i=e._mutations[t]||(e._mutations[t]=[]);i.push((function(t){n.call(e,r.state,t)}))})(e,r,t,u)})),r.forEachAction((function(t,n){var r=t.root?n:a+n,i=t.handler||t;(function(e,t,n,r){var i=e._actions[t]||(e._actions[t]=[]);i.push((function(t){var i=n.call(e,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:e.getters,rootState:e.state},t);return function(e){return e&&"function"===typeof e.then}(i)||(i=Promise.resolve(i)),e._devtoolHook?i.catch((function(t){throw e._devtoolHook.emit("vuex:error",t),t})):i}))})(e,r,i,u)})),r.forEachGetter((function(t,n){var r=a+n;(function(e,t,n,r){if(e._wrappedGetters[t])return void 0;e._wrappedGetters[t]=function(e){return n(r.state,r.getters,e.state,e.getters)}})(e,r,t,u)})),r.forEachChild((function(r,o){v(e,t,n.concat(o),r,i)}))}function y(e,t){return t.reduce((function(e,t){return e[t]}),e)}function m(e,t,n){return a(e)&&e.type&&(n=t,t=e,e=e.type),{type:e,payload:t,options:n}}function x(e){l&&e===l||(l=e,
/*!
* vuex v3.6.2
* (c) 2021 Evan You
* @license MIT
*/
function(e){var t=Number(e.version.split(".")[0]);if(t>=2)e.mixin({beforeCreate:r});else{var n=e.prototype._init;e.prototype._init=function(e){void 0===e&&(e={}),e.init=e.init?[r].concat(e.init):r,n.call(this,e)}}function r(){var e=this.$options;e.store?this.$store="function"===typeof e.store?e.store():e.store:e.parent&&e.parent.$store&&(this.$store=e.parent.$store)}}(l))}d.state.get=function(){return this._vm._data.$$state},d.state.set=function(e){0},f.prototype.commit=function(e,t,n){var r=this,i=m(e,t,n),o=i.type,a=i.payload,s=(i.options,{type:o,payload:a}),c=this._mutations[o];c&&(this._withCommit((function(){c.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,r.state)})))},f.prototype.dispatch=function(e,t){var n=this,r=m(e,t),i=r.type,o=r.payload,a={type:i,payload:o},s=this._actions[i];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,n.state)}))}catch(u){0}var c=s.length>1?Promise.all(s.map((function(e){return e(o)}))):s[0](o);return new Promise((function(e,t){c.then((function(t){try{n._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,n.state)}))}catch(u){0}e(t)}),(function(e){try{n._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,n.state,e)}))}catch(u){0}t(e)}))}))}},f.prototype.subscribe=function(e,t){return h(e,this._subscribers,t)},f.prototype.subscribeAction=function(e,t){var n="function"===typeof e?{before:e}:e;return h(n,this._actionSubscribers,t)},f.prototype.watch=function(e,t,n){var r=this;return this._watcherVM.$watch((function(){return e(r.state,r.getters)}),t,n)},f.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._vm._data.$$state=e}))},f.prototype.registerModule=function(e,t,n){void 0===n&&(n={}),"string"===typeof e&&(e=[e]),this._modules.register(e,t),v(this,this.state,e,this._modules.get(e),n.preserveState),g(this,this.state)},f.prototype.unregisterModule=function(e){var t=this;"string"===typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var n=y(t.state,e.slice(0,-1));l.delete(n,e[e.length-1])})),p(this)},f.prototype.hasModule=function(e){return"string"===typeof e&&(e=[e]),this._modules.isRegistered(e)},f.prototype[[104,111,116,85,112,100,97,116,101].map((function(e){return String.fromCharCode(e)})).join("")]=function(e){this._modules.update(e),p(this,!0)},f.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(f.prototype,d);var _=S((function(e,t){var n={};return A(t).forEach((function(t){var r=t.key,i=t.val;n[r]=function(){var t=this.$store.state,n=this.$store.getters;if(e){var r=P(this.$store,"mapState",e);if(!r)return;t=r.context.state,n=r.context.getters}return"function"===typeof i?i.call(this,t,n):t[i]},n[r].vuex=!0})),n})),b=S((function(e,t){var n={};return A(t).forEach((function(t){var r=t.key,i=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.commit;if(e){var o=P(this.$store,"mapMutations",e);if(!o)return;r=o.context.commit}return"function"===typeof i?i.apply(this,[r].concat(t)):r.apply(this.$store,[i].concat(t))}})),n})),w=S((function(e,t){var n={};return A(t).forEach((function(t){var r=t.key,i=t.val;i=e+i,n[r]=function(){if(!e||P(this.$store,"mapGetters",e))return this.$store.getters[i]},n[r].vuex=!0})),n})),k=S((function(e,t){var n={};return A(t).forEach((function(t){var r=t.key,i=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.dispatch;if(e){var o=P(this.$store,"mapActions",e);if(!o)return;r=o.context.dispatch}return"function"===typeof i?i.apply(this,[r].concat(t)):r.apply(this.$store,[i].concat(t))}})),n}));function A(e){return function(e){return Array.isArray(e)||a(e)}(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function S(e){return function(t,n){return"string"!==typeof t?(n=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,n)}}function P(e,t,n){var r=e._modulesNamespaceMap[n];return r}function T(e,t,n){var r=n?e.groupCollapsed:e.group;try{r.call(e,t)}catch(i){e.log(t)}}function O(e){try{e.groupEnd()}catch(t){e.log("—— log end ——")}}function C(){var e=new Date;return" @ "+L(e.getHours(),2)+":"+L(e.getMinutes(),2)+":"+L(e.getSeconds(),2)+"."+L(e.getMilliseconds(),3)}function L(e,t){return function(e,t){return new Array(t+1).join(e)}("0",t-e.toString().length)+e}var I={Store:f,install:x,version:"3.6.2",mapState:_,mapMutations:b,mapGetters:w,mapActions:k,createNamespacedHelpers:function(e){return{mapState:_.bind(null,e),mapGetters:w.bind(null,e),mapMutations:b.bind(null,e),mapActions:k.bind(null,e)}},createLogger:function(e){void 0===e&&(e={});var t=e.collapsed;void 0===t&&(t=!0);var n=e.filter;void 0===n&&(n=function(e,t,n){return!0});var r=e.transformer;void 0===r&&(r=function(e){return e});var o=e.mutationTransformer;void 0===o&&(o=function(e){return e});var a=e.actionFilter;void 0===a&&(a=function(e,t){return!0});var s=e.actionTransformer;void 0===s&&(s=function(e){return e});var c=e.logMutations;void 0===c&&(c=!0);var u=e.logActions;void 0===u&&(u=!0);var l=e.logger;return void 0===l&&(l=console),function(e){var f=i(e.state);"undefined"!==typeof l&&(c&&e.subscribe((function(e,a){var s=i(a);if(n(e,f,s)){var c=C(),u=o(e),d="mutation "+e.type+c;T(l,d,t),l.log("%c prev state","color: #9E9E9E; font-weight: bold",r(f)),l.log("%c mutation","color: #03A9F4; font-weight: bold",u),l.log("%c next state","color: #4CAF50; font-weight: bold",r(s)),O(l)}f=s})),u&&e.subscribeAction((function(e,n){if(a(e,n)){var r=C(),i=s(e),o="action "+e.type+r;T(l,o,t),l.log("%c action","color: #03A9F4; font-weight: bold",i),O(l)}})))}}};e.exports=I}).call(this,n("0ee4"))},"8ffa":function(e,t,n){var r=n("7647");e.exports=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}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports["default"]=e.exports},9008:function(e,t){e.exports=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.")},e.exports.__esModule=!0,e.exports["default"]=e.exports},"931d":function(e,t,n){var r=n("7647"),i=n("011a");e.exports=function(e,t,n){if(i())return Reflect.construct.apply(null,arguments);var o=[null];o.push.apply(o,t);var a=new(e.bind.apply(e,o));return n&&r(a,n.prototype),a},e.exports.__esModule=!0,e.exports["default"]=e.exports},"9fc1":function(e,t,n){var r=n("3b2d")["default"];function i(){"use strict";
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */e.exports=i=function(){return n},e.exports.__esModule=!0,e.exports["default"]=e.exports;var t,n={},o=Object.prototype,a=o.hasOwnProperty,s=Object.defineProperty||function(e,t,n){e[t]=n.value},c="function"==typeof Symbol?Symbol:{},u=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function d(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{d({},"")}catch(t){d=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof x?t:x,o=Object.create(i.prototype),a=new E(r||[]);return s(o,"_invoke",{value:O(e,n,a)}),o}function p(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}n.wrap=h;var g="suspendedStart",v="executing",y="completed",m={};function x(){}function _(){}function b(){}var w={};d(w,u,(function(){return this}));var k=Object.getPrototypeOf,A=k&&k(k(D([])));A&&A!==o&&a.call(A,u)&&(w=A);var S=b.prototype=x.prototype=Object.create(w);function P(e){["next","throw","return"].forEach((function(t){d(e,t,(function(e){return this._invoke(t,e)}))}))}function T(e,t){function n(i,o,s,c){var u=p(e[i],e,o);if("throw"!==u.type){var l=u.arg,f=l.value;return f&&"object"==r(f)&&a.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,c)}),(function(e){n("throw",e,s,c)})):t.resolve(f).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,c)}))}c(u.arg)}var i;s(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,i){n(e,r,t,i)}))}return i=i?i.then(o,o):o()}})}function O(e,n,r){var i=g;return function(o,a){if(i===v)throw Error("Generator is already running");if(i===y){if("throw"===o)throw a;return{value:t,done:!0}}for(r.method=o,r.arg=a;;){var s=r.delegate;if(s){var c=C(s,r);if(c){if(c===m)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===g)throw i=y,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=v;var u=p(e,n,r);if("normal"===u.type){if(i=r.done?y:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(i=y,r.method="throw",r.arg=u.arg)}}}function C(e,n){var r=n.method,i=e.iterator[r];if(i===t)return n.delegate=null,"throw"===r&&e.iterator["return"]&&(n.method="return",n.arg=t,C(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var o=p(i,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,m;var a=o.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,m):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function L(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 I(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(L,this),this.reset(!0)}function D(e){if(e||""===e){var n=e[u];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var i=-1,o=function n(){for(;++i<e.length;)if(a.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return o.next=o}}throw new TypeError(r(e)+" is not iterable")}return _.prototype=b,s(S,"constructor",{value:b,configurable:!0}),s(b,"constructor",{value:_,configurable:!0}),_.displayName=d(b,f,"GeneratorFunction"),n.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===_||"GeneratorFunction"===(t.displayName||t.name))},n.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,d(e,f,"GeneratorFunction")),e.prototype=Object.create(S),e},n.awrap=function(e){return{__await:e}},P(T.prototype),d(T.prototype,l,(function(){return this})),n.AsyncIterator=T,n.async=function(e,t,r,i,o){void 0===o&&(o=Promise);var a=new T(h(e,t,r,i),o);return n.isGeneratorFunction(t)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},P(S),d(S,f,"Generator"),d(S,u,(function(){return this})),d(S,"toString",(function(){return"[object Generator]"})),n.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},n.values=D,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(I),!e)for(var n in this)"t"===n.charAt(0)&&a.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},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 n=this;function r(r,i){return s.type="throw",s.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var c=a.call(o,"catchLoc"),u=a.call(o,"finallyLoc");if(c&&u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var i=r;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var o=i?i.completion:{};return o.type=e,o.arg=t,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(o)},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),m},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),I(n),m}},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 i=r.arg;I(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:D(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),m}},n}e.exports=i,e.exports.__esModule=!0,e.exports["default"]=e.exports},a5bf:function(e,t,n){},a708:function(e,t,n){var r=n("6454");e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},af34:function(e,t,n){var r=n("a708"),i=n("b893"),o=n("6382"),a=n("9008");e.exports=function(e){return r(e)||i(e)||o(e)||a()},e.exports.__esModule=!0,e.exports["default"]=e.exports},b33a:function(e,t,n){"use strict";(function(e){var r=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n("d3d2")),o=(r(n("069d")),r(n("3e50"))),a={getsessionId:function(t){t.commit;return e.login({success:function(t){t.code&&(t.errMsg="login:ok")&&i.default.onlogin({code:t.code}).then((function(t){return e.setStorageSync("sessionid",t.data.sessionid),t}))}})},getPetInfo:function(t,n){var r=t.commit;return i.default.getPetInfo(n).then((function(t){t.code,e.setStorageSync("petid",t.data.id),r("changePetInfo",t.data),r("changeInfoConf",t.data.conf)}))},gethistoryList:function(e,t){var n=e.commit;return i.default.getList(t).then((function(e){return e.data&&e.data.items?n("changehistoryList",e.data.items):n("changehistoryList",null),e}))},getPetList:function(e){var t=e.commit;return i.default.getPetList({pagenum:20,pagesize:1}).then((function(e){return e.data?t("changePetList",e.data):t("changePetList",null),e}))},getAlertList:function(e,t){var n=e.commit;return i.default.getAlertList(t).then((function(e){return e.data&&e.data.rows?n("changeAlertList",e.data.rows):n("changeAlertList",null),e}))},getNoticelist:function(e){var t=e.commit;return i.default.getnoticelist({}).then((function(e){return e.data?t("changeNoticelist",e.data):t("changeNoticelist",null),e}))},getConfig:function(e){var t=e.commit;return i.default.getConfig({appid:o.default.appid}).then((function(e){0==e.code&&t("changeConfig",e.data)}))},getnumdata:function(e){var t=e.commit;return i.default.getnumdata({appid:o.default.appid}).then((function(e){0==e.code&&t("changenumdata",e.data)}))}};t.default=a}).call(this,n("df3c")["default"])},b3c9:function(e,t,n){"use strict";var r=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n("3240")),o=r(n("8f59")),a=r(n("b33a"));i.default.use(o.default);var s=new o.default.Store({state:{user:{age:"",aud_id:"",email:"",gender:"",head_pic:"",height:"",is_use_set_kcal:"",nickname:"",set_kcal:"",tel:"",token:"",weight:""},menu_search_value:"",foodList:[],menuList:[],isConnected:!1,isBluetoothTyle:!1},mutations:{changeUserInfo:function(e,t){e.user=t},changeBluetooth:function(e,t){e.isBluetoothTyle=t},changeConnected:function(e,t){e.isConnected=t},changeMenuList:function(e,t){e.menuList=t},changeFoodList:function(e,t){e.foodList=t}},modules:{},actions:a.default});t.default=s},b4d2:function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports["default"]=e.exports},b893:function(e,t){e.exports=function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},c2d4:function(e,t){var n=["#1890FF","#91CB74","#FAC858","#EE6666","#73C0DE","#3CA272","#FC8452","#9A60B4","#ea7ccc"];e.exports={type:["pie","ring","rose","word","funnel","map","arcbar","line","column","area","radar","gauge","candle","mix","tline","tarea","scatter","bubble","demotype"],range:["饼状图","圆环图","玫瑰图","词云图","漏斗图","地图","圆弧进度条","折线图","柱状图","区域图","雷达图","仪表盘","K线图","混合图","时间轴折线","时间轴区域","散点图","气泡图","自定义类型"],categories:["line","column","area","radar","gauge","candle","mix","demotype"],instance:{},option:{},formatter:{yAxisDemo1:function(e){return e+"元"},yAxisDemo2:function(e){return e.toFixed(2)},xAxisDemo1:function(e){return e+"年"},xAxisDemo2:function(e){return function(e,t){var n=new Date;n.setTime(1e3*e);var r=n.getFullYear(),i=n.getMonth()+1;i=i<10?"0"+i:i;var o=n.getDate();o=o<10?"0"+o:o;var a=n.getHours();a=a<10?"0"+a:a;var s=n.getMinutes(),c=n.getSeconds();return s=s<10?"0"+s:s,c=c<10?"0"+c:c,"full"==t?r+"-"+i+"-"+o+" "+a+":"+s+":"+c:"y-m-d"==t?r+"-"+i+"-"+o:"h:m"==t?a+":"+s:"h:m:s"==t?a+":"+s+":"+c:[r,i,o,a,s,c]}(e,"h:m")},seriesDemo1:function(e){return e+"元"},tooltipDemo1:function(e,t,n,r){return 0==n?"随便用"+e.data+"年":"其他我没改"+e.data+"天"},pieDemo:function(e,t,n){if(void 0!==t)return n[t].name+""+n[t].data+"元"}},demotype:{type:"line",color:n,padding:[15,10,0,15],xAxis:{disableGrid:!0},yAxis:{gridType:"dash",dashLength:2},legend:{},extra:{line:{type:"curve",width:2}}},pie:{type:"pie",color:n,padding:[5,5,5,5],extra:{pie:{activeOpacity:.5,activeRadius:10,offsetAngle:0,labelWidth:15,border:!0,borderWidth:3,borderColor:"#FFFFFF"}}},ring:{type:"ring",color:n,padding:[5,5,5,5],rotate:!1,dataLabel:!0,legend:{show:!0,position:"right",lineHeight:25},title:{name:"收益率",fontSize:15,color:"#666666"},subtitle:{name:"70%",fontSize:25,color:"#7cb5ec"},extra:{ring:{ringWidth:30,activeOpacity:.5,activeRadius:10,offsetAngle:0,labelWidth:15,border:!0,borderWidth:3,borderColor:"#FFFFFF"}}},rose:{type:"rose",color:n,padding:[5,5,5,5],legend:{show:!0,position:"left",lineHeight:25},extra:{rose:{type:"area",minRadius:50,activeOpacity:.5,activeRadius:10,offsetAngle:0,labelWidth:15,border:!1,borderWidth:2,borderColor:"#FFFFFF"}}},word:{type:"word",color:n,extra:{word:{type:"normal",autoColors:!1}}},funnel:{type:"funnel",color:n,padding:[15,15,0,15],extra:{funnel:{activeOpacity:.3,activeWidth:10,border:!0,borderWidth:2,borderColor:"#FFFFFF",fillOpacity:1,labelAlign:"right"}}},map:{type:"map",color:n,padding:[0,0,0,0],dataLabel:!0,extra:{map:{border:!0,borderWidth:1,borderColor:"#666666",fillOpacity:.6,activeBorderColor:"#F04864",activeFillColor:"#FACC14",activeFillOpacity:1}}},arcbar:{type:"arcbar",color:n,title:{name:"",fontSize:25,color:"#00FF00"},subtitle:{name:"",fontSize:15,color:"#666666"},extra:{arcbar:{type:"default",width:12,backgroundColor:"#E9E9E9",startAngle:.75,endAngle:.25,gap:2}}},line:{type:"line",color:n,padding:[15,10,0,15],xAxis:{disableGrid:!0},yAxis:{gridType:"dash",dashLength:2},legend:{},extra:{line:{type:"straight",width:2}}},tline:{type:"line",color:n,padding:[15,10,0,15],xAxis:{disableGrid:!1,boundaryGap:"justify"},yAxis:{gridType:"dash",dashLength:2,data:[{min:0,max:80}]},legend:{},extra:{line:{type:"curve",width:2}}},tarea:{type:"area",color:n,padding:[0,15,15,5],xAxis:{disableGrid:!0,boundaryGap:"justify"},yAxis:{gridType:"dash",dashLength:2,data:[{min:0,max:80}]},legend:{},extra:{area:{type:"curve",opacity:.2,addLine:!0,width:2,gradient:!0}}},column:{type:"column",color:n,padding:[15,15,0,5],xAxis:{disableGrid:!0},yAxis:{gridType:"dash",disableGrid:!0,gridColor:"#ffffff",data:[{tofix:1,min:0}]},legend:{},extra:{column:{type:"group",width:20,seriesGap:5,meterFillColor:"#FFFFFF",activeBgColor:"#000000",activeBgOpacity:.5,barBorderCircle:!0,linearType:"opacity",linearOpacity:1}}},area:{type:"area",color:n,padding:[20,15,5,10],xAxis:{disableGrid:!0},yAxis:{gridType:"dash",disableGrid:!0,gridColor:"#ffffff",data:[{tofix:1,min:0}]},legend:{show:!1},extra:{area:{type:"curve",opacity:.2,addLine:!0,width:1,gradient:!0}}},radar:{type:"radar",color:n,padding:[5,5,5,5],legend:{show:!0,position:"right",lineHeight:25},extra:{radar:{gridType:"radar",gridColor:"#CCCCCC",gridCount:3,opacity:.2,max:200}}},gauge:{type:"gauge",color:n,title:{name:"66Km/H",fontSize:25,color:"#2fc25b",offsetY:50},subtitle:{name:"实时速度",fontSize:15,color:"#1890ff",offsetY:-50},extra:{gauge:{type:"default",width:30,labelColor:"#666666",startAngle:.75,endAngle:.25,startNumber:0,endNumber:100,labelFormat:"",splitLine:{fixRadius:0,splitNumber:10,width:30,color:"#FFFFFF",childNumber:5,childWidth:12},pointer:{width:24,color:"auto"}}}},candle:{type:"candle",color:n,padding:[15,15,0,15],enableScroll:!0,enableMarkLine:!0,dataLabel:!1,xAxis:{labelCount:4,itemCount:40,disableGrid:!0,gridColor:"#CCCCCC",gridType:"solid",dashLength:4,scrollShow:!0,scrollAlign:"left",scrollColor:"#A6A6A6",scrollBackgroundColor:"#EFEBEF"},yAxis:{},legend:{},extra:{candle:{color:{upLine:"#f04864",upFill:"#f04864",downLine:"#2fc25b",downFill:"#2fc25b"},average:{show:!0,name:["MA5","MA10","MA30"],day:[5,10,20],color:["#1890ff","#2fc25b","#facc14"]}},markLine:{type:"dash",dashLength:5,data:[{value:2150,lineColor:"#f04864",showLabel:!0},{value:2350,lineColor:"#f04864",showLabel:!0}]}}},mix:{type:"mix",color:n,padding:[15,15,0,15],xAxis:{disableGrid:!0},yAxis:{disabled:!1,disableGrid:!1,splitNumber:5,gridType:"dash",dashLength:4,gridColor:"#CCCCCC",padding:10,showTitle:!0,data:[]},legend:{},extra:{mix:{column:{width:20}}}},scatter:{type:"scatter",color:n,padding:[15,15,0,15],dataLabel:!1,xAxis:{disableGrid:!1,gridType:"dash",splitNumber:5,boundaryGap:"justify",min:0},yAxis:{disableGrid:!1,gridType:"dash"},legend:{},extra:{scatter:{}}},bubble:{type:"bubble",color:n,padding:[15,15,0,15],xAxis:{disableGrid:!1,gridType:"dash",splitNumber:5,boundaryGap:"justify",min:0,max:250},yAxis:{disableGrid:!1,gridType:"dash",data:[{min:0,max:150}]},legend:{},extra:{bubble:{border:2,opacity:.5}}}}},d3b4:function(e,t,n){"use strict";(function(e,r){var i=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.LOCALE_ZH_HANT=t.LOCALE_ZH_HANS=t.LOCALE_FR=t.LOCALE_ES=t.LOCALE_EN=t.I18n=t.Formatter=void 0,t.compileI18nJsonStr=function(e,t){var n=t.locale,r=t.locales,i=t.delimiters;if(!S(e,i))return e;k||(k=new f);var o=[];Object.keys(r).forEach((function(e){e!==n&&o.push({locale:e,values:r[e]})})),o.unshift({locale:n,values:r[n]});try{return JSON.stringify(T(JSON.parse(e),o,i),null,2)}catch(a){}return e},t.hasI18nJson=function e(t,n){k||(k=new f);return O(t,(function(t,r){var i=t[r];return A(i)?!!S(i,n)||void 0:e(i,n)}))},t.initVueI18n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if("string"!==typeof e){var i=[t,e];e=i[0],t=i[1]}"string"!==typeof e&&(e=w());"string"!==typeof n&&(n="undefined"!==typeof __uniConfig&&__uniConfig.fallbackLocale||"en");var o=new _({locale:e,fallbackLocale:n,messages:t,watcher:r}),a=function(e,t){if("function"!==typeof getApp)a=function(e,t){return o.t(e,t)};else{var n=!1;a=function(e,t){var r=getApp().$vm;return r&&(r.$locale,n||(n=!0,b(r,o))),o.t(e,t)}}return a(e,t)};return{i18n:o,f:function(e,t,n){return o.f(e,t,n)},t:function(e,t){return a(e,t)},add:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return o.add(e,t,n)},watch:function(e){return o.watchLocale(e)},getLocale:function(){return o.getLocale()},setLocale:function(e){return o.setLocale(e)}}},t.isI18nStr=S,t.isString=void 0,t.normalizeLocale=x,t.parseI18nJson=function e(t,n,r){k||(k=new f);return O(t,(function(t,i){var o=t[i];A(o)?S(o,r)&&(t[i]=P(o,n,r)):e(o,n,r)})),t},t.resolveLocale=function(e){return function(t){return t?(t=x(t)||t,function(e){var t=[],n=e.split("-");while(n.length)t.push(n.join("-")),n.pop();return t}(t).find((function(t){return e.indexOf(t)>-1}))):t}};var o=i(n("34cf")),a=i(n("67ad")),s=i(n("0bdb")),c=i(n("3b2d")),u=function(e){return null!==e&&"object"===(0,c.default)(e)},l=["{","}"],f=function(){function e(){(0,a.default)(this,e),this._caches=Object.create(null)}return(0,s.default)(e,[{key:"interpolate",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l;if(!t)return[e];var r=this._caches[e];return r||(r=p(e,n),this._caches[e]=r),g(r,t)}}]),e}();t.Formatter=f;var d=/^(?:\d)+/,h=/^(?:\w)+/;function p(e,t){var n=(0,o.default)(t,2),r=n[0],i=n[1],a=[],s=0,c="";while(s<e.length){var u=e[s++];if(u===r){c&&a.push({type:"text",value:c}),c="";var l="";u=e[s++];while(void 0!==u&&u!==i)l+=u,u=e[s++];var f=u===i,p=d.test(l)?"list":f&&h.test(l)?"named":"unknown";a.push({value:l,type:p})}else c+=u}return c&&a.push({type:"text",value:c}),a}function g(e,t){var n=[],r=0,i=Array.isArray(t)?"list":u(t)?"named":"unknown";if("unknown"===i)return n;while(r<e.length){var o=e[r];switch(o.type){case"text":n.push(o.value);break;case"list":n.push(t[parseInt(o.value,10)]);break;case"named":"named"===i&&n.push(t[o.value]);break;case"unknown":0;break}r++}return n}t.LOCALE_ZH_HANS="zh-Hans";t.LOCALE_ZH_HANT="zh-Hant";t.LOCALE_EN="en";t.LOCALE_FR="fr";t.LOCALE_ES="es";var v=Object.prototype.hasOwnProperty,y=function(e,t){return v.call(e,t)},m=new f;function x(e,t){if(e){if(e=e.trim().replace(/_/g,"-"),t&&t[e])return e;if(e=e.toLowerCase(),"chinese"===e)return"zh-Hans";if(0===e.indexOf("zh"))return e.indexOf("-hans")>-1?"zh-Hans":e.indexOf("-hant")>-1||function(e,t){return!!t.find((function(t){return-1!==e.indexOf(t)}))}(e,["-tw","-hk","-mo","-cht"])?"zh-Hant":"zh-Hans";var n=["en","fr","es"];t&&Object.keys(t).length>0&&(n=Object.keys(t));var r=function(e,t){return t.find((function(t){return 0===e.indexOf(t)}))}(e,n);return r||void 0}}var _=function(){function e(t){var n=t.locale,r=t.fallbackLocale,i=t.messages,o=t.watcher,s=t.formater;(0,a.default)(this,e),this.locale="en",this.fallbackLocale="en",this.message={},this.messages={},this.watchers=[],r&&(this.fallbackLocale=r),this.formater=s||m,this.messages=i||{},this.setLocale(n||"en"),o&&this.watchLocale(o)}return(0,s.default)(e,[{key:"setLocale",value:function(e){var t=this,n=this.locale;this.locale=x(e,this.messages)||this.fallbackLocale,this.messages[this.locale]||(this.messages[this.locale]={}),this.message=this.messages[this.locale],n!==this.locale&&this.watchers.forEach((function(e){e(t.locale,n)}))}},{key:"getLocale",value:function(){return this.locale}},{key:"watchLocale",value:function(e){var t=this,n=this.watchers.push(e)-1;return function(){t.watchers.splice(n,1)}}},{key:"add",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=this.messages[e];r?n?Object.assign(r,t):Object.keys(t).forEach((function(e){y(r,e)||(r[e]=t[e])})):this.messages[e]=t}},{key:"f",value:function(e,t,n){return this.formater.interpolate(e,t,n).join("")}},{key:"t",value:function(e,t,n){var r=this.message;return"string"===typeof t?(t=x(t,this.messages),t&&(r=this.messages[t])):n=t,y(r,e)?this.formater.interpolate(r[e],n).join(""):(console.warn("Cannot translate the value of keypath ".concat(e,". Use the value of keypath as default.")),e)}}]),e}();function b(e,t){e.$watchLocale?e.$watchLocale((function(e){t.setLocale(e)})):e.$watch((function(){return e.$locale}),(function(e){t.setLocale(e)}))}function w(){return"undefined"!==typeof e&&e.getLocale?e.getLocale():"undefined"!==typeof r&&r.getLocale?r.getLocale():"en"}t.I18n=_;var k,A=function(e){return"string"===typeof e};function S(e,t){return e.indexOf(t[0])>-1}function P(e,t,n){return k.interpolate(e,t,n).join("")}function T(e,t,n){return O(e,(function(e,r){(function(e,t,n,r){var i=e[t];if(A(i)){if(S(i,r)&&(e[t]=P(i,n[0].values,r),n.length>1)){var o=e[t+"Locales"]={};n.forEach((function(e){o[e.locale]=P(i,e.values,r)}))}}else T(i,n,r)})(e,r,t,n)})),e}function O(e,t){if(Array.isArray(e)){for(var n=0;n<e.length;n++)if(t(e,n))return!0}else if(u(e))for(var r in e)if(t(e,r))return!0;return!1}t.isString=A}).call(this,n("df3c")["default"],n("0ee4"))},d3d2:function(e,t,n){"use strict";var r=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,o=r(n("7ca3")),a=r(n("749e")),s=(r(n("069d")),r(n("b3c9")),i={getonlogin:function(e){return a.default.post("/login_action",e).then((function(e){return e}))},getSendCode:function(e){return a.default.post("/send_phone_email_code",e).then((function(e){return e}))},getregister:function(e){return a.default.post("/register_action",e).then((function(e){return e}))},getRegisterPhone:function(e){return a.default.post("/kitchenscale/wechat_quick_login",e).then((function(e){return e}))},getloginOut:function(e){return a.default.post("/user_quit_account",e).then((function(e){return e}))},getResetPassword:function(e){return a.default.post("/reset_password",e).then((function(e){return e}))},getAccountPassword:function(e){return a.default.post("/update_my_password",e).then((function(e){return e}))},getAccountMsg:function(e){return a.default.post("/update_my_account_msg",e).then((function(e){return e}))},getHomeInfo:function(e){return a.default.post("/kitchenscale/get_homepage_information",e).then((function(e){return e}))},getHomeUserInfo:function(e){return a.default.post("/kitchenscale/get_user_msg",e).then((function(e){return e}))},getHomeConfig:function(e){return a.default.post("/kitchenscale/get_default_config",e).then((function(e){return e}))},getHomeSearch:function(e){return a.default.post("/kitchenscale/search_column",e).then((function(e){return e}))},getUserInfoEdit:function(e){return a.default.post("/kitchenscale/update_user_msg",e).then((function(e){return e}))},getSearchPopularFood:function(e){return a.default.post("/kitchenscale/get_search_food_page_list",e).then((function(e){return e}))},getFoodSearch:function(e){return a.default.post("/kitchenscale/find_food",e).then((function(e){return e}))},getMenuSearch:function(e){return a.default.post("/kitchenscale/find_by_food",e).then((function(e){return e}))},getPhotoSearch:function(e){return a.default.post("/kitchenscale/baidu_identify_food",e).then((function(e){return e}))},getUploadImg:function(e){return a.default.upload("/kitchenscale/pic_upload_one_action",e).then((function(e){return e}))},getAddCookbook:function(e){return a.default.post("/kitchenscale/add_cookbook",e).then((function(e){return e}))},getEditCookbook:function(e){return a.default.post("/kitchenscale/update_cookbook",e).then((function(e){return e}))},getCookListLabel:function(e){return a.default.post("/kitchenscale/find_by_cook_label",e).then((function(e){return e}))},getCookListFood:function(e){return a.default.post("/kitchenscale/find_by_food",e).then((function(e){return e}))},getCookListDetails:function(e){return a.default.post("/kitchenscale/cookbook_details",e).then((function(e){return e}))},getCookFollow:function(e){return a.default.post("/kitchenscale/cookbook_follow",e).then((function(e){return e}))},getCookLike:function(e){return a.default.post("/kitchenscale/cookbook_like",e).then((function(e){return e}))},getCookKcal:function(e){return a.default.post("/kitchenscale/food_count_kcal",e).then((function(e){return e}))},getCookFoodList:function(e){return a.default.post("/kitchenscale/get_food_list",e).then((function(e){return e}))},getCookListSave:function(e){return a.default.post("/kitchenscale/save_food_list",e).then((function(e){return e}))},getAddIntakeFood:function(e){return a.default.post("/kitchenscale/add_intake_food",e).then((function(e){return e}))},getCountfootCon:function(e){return a.default.post("/kitchenscale/get_countfoot_content",e).then((function(e){return e}))},getLogList:function(e){return a.default.post("/kitchenscale/get_log_list",e).then((function(e){return e}))},getSetUpContent:function(e){return a.default.post("/kitchenscale/set_up_content",e).then((function(e){return e}))},getSetUserKcal:function(e){return a.default.post("/kitchenscale/set_user_kcal",e).then((function(e){return e}))},getUserCollectList:function(e){return a.default.post("/kitchenscale/get_user_collect_list",e).then((function(e){return e}))},getMyCookbook:function(e){return a.default.post("/kitchenscale/get_my_cookbook",e).then((function(e){return e}))},getMyCookbookDel:function(e){return a.default.post("/kitchenscale/del_my_cookbook",e).then((function(e){return e}))},getMyLogList:function(e){return a.default.post("/kitchenscale/get_log_list",e).then((function(e){var t={list:[],Dlist:[]};if(0==e.code)for(var n=0;n<e.data.content_list.length;n++)t.list.push(e.data.content_list[n]),t.Dlist.includes(e.data.content_list[n].time)||t.Dlist.push(e.data.content_list[n].time);return e.data.pkList=t,e.data}))}},(0,o.default)(i,"getAddIntakeFood",(function(e){return a.default.post("/kitchenscale/add_intake_food",e).then((function(e){return e}))})),(0,o.default)(i,"getCountFoodInfo",(function(e){return a.default.post("/kitchenscale/get_countfoot_content",e).then((function(e){return e}))})),(0,o.default)(i,"getCountSetKcal",(function(e){return a.default.post("/kitchenscale/set_up_content",e).then((function(e){return e}))})),(0,o.default)(i,"getCountSetUserKcal",(function(e){return a.default.post("/kitchenscale/set_user_kcal",e).then((function(e){return e}))})),i);t.default=s},d551:function(e,t,n){var r=n("3b2d")["default"],i=n("e6db");e.exports=function(e){var t=i(e,"string");return"symbol"==r(t)?t:t+""},e.exports.__esModule=!0,e.exports["default"]=e.exports},dc84:function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},dd3e:function(e,t){e.exports=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.")},e.exports.__esModule=!0,e.exports["default"]=e.exports},df3c:function(e,t,n){"use strict";(function(e,r){var i=n("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.createApp=Mt,t.createComponent=qt,t.createPage=Wt,t.createPlugin=Vt,t.createSubpackageApp=Ht,t.default=void 0;var o,a=i(n("34cf")),s=i(n("7ca3")),c=i(n("931d")),u=i(n("af34")),l=i(n("3b2d")),f=n("d3b4"),d=i(n("3240"));function h(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?h(Object(n),!0).forEach((function(t){(0,s.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",v=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function y(){var t,n=e.getStorageSync("uni_id_token")||"",r=n.split(".");if(!n||3!==r.length)return{uid:null,role:[],permission:[],tokenExpired:0};try{t=JSON.parse(function(e){return decodeURIComponent(o(e).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))}(r[1]))}catch(i){throw new Error("获取当前用户信息出错,详细错误信息为:"+i.message)}return t.tokenExpired=1e3*t.exp,delete t.exp,delete t.iat,t}o="function"!==typeof atob?function(e){if(e=String(e).replace(/[\t\n\f\r ]+/g,""),!v.test(e))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var t;e+="==".slice(2-(3&e.length));for(var n,r,i="",o=0;o<e.length;)t=g.indexOf(e.charAt(o++))<<18|g.indexOf(e.charAt(o++))<<12|(n=g.indexOf(e.charAt(o++)))<<6|(r=g.indexOf(e.charAt(o++))),i+=64===n?String.fromCharCode(t>>16&255):64===r?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,255&t);return i}:atob;var m=Object.prototype.toString,x=Object.prototype.hasOwnProperty;function _(e){return"function"===typeof e}function b(e){return"string"===typeof e}function w(e){return"[object Object]"===m.call(e)}function k(e,t){return x.call(e,t)}function A(){}function S(e){var t=Object.create(null);return function(n){var r=t[n];return r||(t[n]=e(n))}}var P=/-(\w)/g,T=S((function(e){return e.replace(P,(function(e,t){return t?t.toUpperCase():""}))}));function O(e){var t={};return w(e)&&Object.keys(e).sort().forEach((function(n){t[n]=e[n]})),Object.keys(t)?t:e}var C=["invoke","success","fail","complete","returnValue"],L={},I={};function E(e,t){Object.keys(t).forEach((function(n){-1!==C.indexOf(n)&&_(t[n])&&(e[n]=function(e,t){var n=t?e?e.concat(t):Array.isArray(t)?t:[t]:e;return n?function(e){for(var t=[],n=0;n<e.length;n++)-1===t.indexOf(e[n])&&t.push(e[n]);return t}(n):n}(e[n],t[n]))}))}function D(e,t){e&&t&&Object.keys(t).forEach((function(n){-1!==C.indexOf(n)&&_(t[n])&&function(e,t){var n=e.indexOf(t);-1!==n&&e.splice(n,1)}(e[n],t[n])}))}function M(e,t){return function(n){return e(n,t)||n}}function F(e){return!!e&&("object"===(0,l.default)(e)||"function"===typeof e)&&"function"===typeof e.then}function j(e,t,n){for(var r=!1,i=0;i<e.length;i++){var o=e[i];if(r)r=Promise.resolve(M(o,n));else{var a=o(t,n);if(F(a)&&(r=Promise.resolve(a)),!1===a)return{then:function(){}}}}return r||{then:function(e){return e(t)}}}function $(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return["success","fail","complete"].forEach((function(n){if(Array.isArray(e[n])){var r=t[n];t[n]=function(i){j(e[n],i,t).then((function(e){return _(r)&&r(e)||e}))}}})),t}function R(e,t){var n=[];Array.isArray(L.returnValue)&&n.push.apply(n,(0,u.default)(L.returnValue));var r=I[e];return r&&Array.isArray(r.returnValue)&&n.push.apply(n,(0,u.default)(r.returnValue)),n.forEach((function(e){t=e(t)||t})),t}function N(e){var t=Object.create(null);Object.keys(L).forEach((function(e){"returnValue"!==e&&(t[e]=L[e].slice())}));var n=I[e];return n&&Object.keys(n).forEach((function(e){"returnValue"!==e&&(t[e]=(t[e]||[]).concat(n[e]))})),t}function U(e,t,n){for(var r=arguments.length,i=new Array(r>3?r-3:0),o=3;o<r;o++)i[o-3]=arguments[o];var a=N(e);if(a&&Object.keys(a).length){if(Array.isArray(a.invoke)){var s=j(a.invoke,n);return s.then((function(n){return t.apply(void 0,[$(N(e),n)].concat(i))}))}return t.apply(void 0,[$(a,n)].concat(i))}return t.apply(void 0,[n].concat(i))}var B={returnValue:function(e){return F(e)?new Promise((function(t,n){e.then((function(e){e?e[0]?n(e[0]):t(e[1]):t(e)}))})):e}},z=/^\$|__f__|Window$|WindowStyle$|sendHostEvent|sendNativeEvent|restoreGlobal|requireGlobal|getCurrentSubNVue|getMenuButtonBoundingClientRect|^report|interceptors|Interceptor$|getSubNVueById|requireNativePlugin|rpx2px|upx2px|hideKeyboard|canIUse|^create|Sync$|Manager$|base64ToArrayBuffer|arrayBufferToBase64|getLocale|setLocale|invokePushCallback|getWindowInfo|getDeviceInfo|getAppBaseInfo|getSystemSetting|getAppAuthorizeSetting|initUTS|requireUTS|registerUTS/,W=/^create|Manager$/,q=["createBLEConnection"],H=["createBLEConnection","createPushMessage"],V=/^on|^off/;function K(e){return W.test(e)&&-1===q.indexOf(e)}function G(e){return z.test(e)&&-1===H.indexOf(e)}function J(e){return e.then((function(e){return[null,e]})).catch((function(e){return[e]}))}function X(e){return!(K(e)||G(e)||function(e){return V.test(e)&&"onPush"!==e}(e))}function Y(e,t){return X(e)&&_(t)?function(){for(var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return _(n.success)||_(n.fail)||_(n.complete)?R(e,U.apply(void 0,[e,t,Object.assign({},n)].concat(i))):R(e,J(new Promise((function(r,o){U.apply(void 0,[e,t,Object.assign({},n,{success:r,fail:o})].concat(i))}))))}:t}Promise.prototype.finally||(Promise.prototype.finally=function(e){var t=this.constructor;return this.then((function(n){return t.resolve(e()).then((function(){return n}))}),(function(n){return t.resolve(e()).then((function(){throw n}))}))});var Q=!1,Z=0,ee=0;function te(t,n){if(0===Z&&function(){var t,n,r,i="function"===typeof e.getWindowInfo&&e.getWindowInfo()?e.getWindowInfo():e.getSystemInfoSync(),o="function"===typeof e.getDeviceInfo&&e.getDeviceInfo()?e.getDeviceInfo():e.getSystemInfoSync();t=i.windowWidth,n=i.pixelRatio,r=o.platform,Z=t,ee=n,Q="ios"===r}(),t=Number(t),0===t)return 0;var r=t/750*(n||Z);return r<0&&(r=-r),r=Math.floor(r+1e-4),0===r&&(r=1!==ee&&Q?.5:1),t<0?-r:r}var ne,re={};function ie(){var t,n="function"===typeof e.getAppBaseInfo&&e.getAppBaseInfo()?e.getAppBaseInfo():e.getSystemInfoSync(),r=n&&n.language?n.language:"en";return t=se(r)||"en",t}ne=ie(),function(){if(function(){return"undefined"!==typeof __uniConfig&&__uniConfig.locales&&!!Object.keys(__uniConfig.locales).length}()){var e=Object.keys(__uniConfig.locales);e.length&&e.forEach((function(e){var t=re[e],n=__uniConfig.locales[e];t?Object.assign(t,n):re[e]=n}))}}();var oe=(0,f.initVueI18n)(ne,{}),ae=oe.t;oe.mixin={beforeCreate:function(){var e=this,t=oe.i18n.watchLocale((function(){e.$forceUpdate()}));this.$once("hook:beforeDestroy",(function(){t()}))},methods:{$$t:function(e,t){return ae(e,t)}}},oe.setLocale,oe.getLocale;function se(e,t){if(e){if(e=e.trim().replace(/_/g,"-"),t&&t[e])return e;if(e=e.toLowerCase(),"chinese"===e)return"zh-Hans";if(0===e.indexOf("zh"))return e.indexOf("-hans")>-1?"zh-Hans":e.indexOf("-hant")>-1||function(e,t){return!!t.find((function(t){return-1!==e.indexOf(t)}))}(e,["-tw","-hk","-mo","-cht"])?"zh-Hant":"zh-Hans";var n=function(e,t){return t.find((function(t){return 0===e.indexOf(t)}))}(e,["en","fr","es"]);return n||void 0}}function ce(){if(_(getApp)){var e=getApp({allowDefault:!0});if(e&&e.$vm)return e.$vm.$locale}return ie()}var ue=[];"undefined"!==typeof r&&(r.getLocale=ce);var le={promiseInterceptor:B},fe=Object.freeze({__proto__:null,upx2px:te,rpx2px:te,getLocale:ce,setLocale:function(e){var t=!!_(getApp)&&getApp();if(!t)return!1;var n=t.$vm.$locale;return n!==e&&(t.$vm.$locale=e,ue.forEach((function(t){return t({locale:e})})),!0)},onLocaleChange:function(e){-1===ue.indexOf(e)&&ue.push(e)},addInterceptor:function(e,t){"string"===typeof e&&w(t)?E(I[e]||(I[e]={}),t):w(e)&&E(L,e)},removeInterceptor:function(e,t){"string"===typeof e?w(t)?D(I[e],t):delete I[e]:w(e)&&D(L,e)},interceptors:le});var de,he={name:function(e){return"back"===e.exists&&e.delta?"navigateBack":"redirectTo"},args:function(e){if("back"===e.exists&&e.url){var t=function(e){var t=getCurrentPages(),n=t.length;while(n--){var r=t[n];if(r.$page&&r.$page.fullPath===e)return n}return-1}(e.url);if(-1!==t){var n=getCurrentPages().length-1-t;n>0&&(e.delta=n)}}}},pe={args:function(e){var t=parseInt(e.current);if(!isNaN(t)){var n=e.urls;if(Array.isArray(n)){var r=n.length;if(r)return t<0?t=0:t>=r&&(t=r-1),t>0?(e.current=n[t],e.urls=n.filter((function(e,r){return!(r<t)||e!==n[t]}))):e.current=n[0],{indicator:!1,loop:!1}}}}};function ge(t){de=de||e.getStorageSync("__DC_STAT_UUID"),de||(de=Date.now()+""+Math.floor(1e7*Math.random()),e.setStorage({key:"__DC_STAT_UUID",data:de})),t.deviceId=de}function ve(e){if(e.safeArea){var t=e.safeArea;e.safeAreaInsets={top:t.top,left:t.left,right:e.windowWidth-t.right,bottom:e.screenHeight-t.bottom}}}function ye(e,t){var n="",r="";switch(n=e.split(" ")[0]||t,r=e.split(" ")[1]||"",n=n.toLocaleLowerCase(),n){case"harmony":case"ohos":case"openharmony":n="harmonyos";break;case"iphone os":n="ios";break;case"mac":case"darwin":n="macos";break;case"windows_nt":n="windows";break}return{osName:n,osVersion:r}}function me(e,t){for(var n=e.deviceType||"phone",r={ipad:"pad",windows:"pc",mac:"pc"},i=Object.keys(r),o=t.toLocaleLowerCase(),a=0;a<i.length;a++){var s=i[a];if(-1!==o.indexOf(s)){n=r[s];break}}return n}function xe(e){var t=e;return t&&(t=e.toLocaleLowerCase()),t}function _e(e){return ce?ce():e}function be(e){var t=e.hostName||"WeChat";return e.environment?t=e.environment:e.host&&e.host.env&&(t=e.host.env),t}var we={returnValue:function(e){ge(e),ve(e),function(e){var t=e.brand,n=void 0===t?"":t,r=e.model,i=void 0===r?"":r,o=e.system,a=void 0===o?"":o,s=e.language,c=void 0===s?"":s,u=e.theme,l=e.version,f=e.platform,d=e.fontSizeSetting,h=e.SDKVersion,p=e.pixelRatio,g=e.deviceOrientation,v=ye(a,f),y=v.osName,m=v.osVersion,x=l,_=me(e,i),b=xe(n),w=be(e),k=g,A=p,S=h,P=(c||"").replace(/_/g,"-"),T={appId:"__UNI__9A0614A",appName:"kitchendDevice",appVersion:"1.0.0",appVersionCode:"100",appLanguage:_e(P),uniCompileVersion:"4.75",uniCompilerVersion:"4.75",uniRuntimeVersion:"4.75",uniPlatform:"mp-weixin",deviceBrand:b,deviceModel:i,deviceType:_,devicePixelRatio:A,deviceOrientation:k,osName:y.toLocaleLowerCase(),osVersion:m,hostTheme:u,hostVersion:x,hostLanguage:P,hostName:w,hostSDKVersion:S,hostFontSizeSetting:d,windowTop:0,windowBottom:0,osLanguage:void 0,osTheme:void 0,ua:void 0,hostPackageName:void 0,browserName:void 0,browserVersion:void 0,isUniAppX:!1};Object.assign(e,T,{})}(e)}},ke={args:function(e){"object"===(0,l.default)(e)&&(e.alertText=e.title)}},Ae={returnValue:function(e){var t=e,n=t.version,r=t.language,i=t.SDKVersion,o=t.theme,a=be(e),s=(r||"").replace("_","-");e=O(Object.assign(e,{appId:"__UNI__9A0614A",appName:"kitchendDevice",appVersion:"1.0.0",appVersionCode:"100",appLanguage:_e(s),hostVersion:n,hostLanguage:s,hostName:a,hostSDKVersion:i,hostTheme:o,isUniAppX:!1,uniPlatform:"mp-weixin",uniCompileVersion:"4.75",uniCompilerVersion:"4.75",uniRuntimeVersion:"4.75"}))}},Se={returnValue:function(e){var t=e,n=t.brand,r=t.model,i=t.system,o=void 0===i?"":i,a=t.platform,s=void 0===a?"":a,c=me(e,r),u=xe(n);ge(e);var l=ye(o,s),f=l.osName,d=l.osVersion;e=O(Object.assign(e,{deviceType:c,deviceBrand:u,deviceModel:r,osName:f,osVersion:d}))}},Pe={returnValue:function(e){ve(e),e=O(Object.assign(e,{windowTop:0,windowBottom:0}))}},Te={redirectTo:he,previewImage:pe,getSystemInfo:we,getSystemInfoSync:we,showActionSheet:ke,getAppBaseInfo:Ae,getDeviceInfo:Se,getWindowInfo:Pe,getAppAuthorizeSetting:{returnValue:function(e){var t=e.locationReducedAccuracy;e.locationAccuracy="unsupported",!0===t?e.locationAccuracy="reduced":!1===t&&(e.locationAccuracy="full")}},compressImage:{args:function(e){e.compressedHeight&&!e.compressHeight&&(e.compressHeight=e.compressedHeight),e.compressedWidth&&!e.compressWidth&&(e.compressWidth=e.compressedWidth)}}},Oe=["success","fail","cancel","complete"];function Ce(e,t,n){return function(r){return t(Ie(e,r,n))}}function Le(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(w(t)){var o=!0===i?t:{};for(var a in _(n)&&(n=n(t,o)||{}),t)if(k(n,a)){var s=n[a];_(s)&&(s=s(t[a],t,o)),s?b(s)?o[s]=t[a]:w(s)&&(o[s.name?s.name:a]=s.value):console.warn("The '".concat(e,"' method of platform '微信小程序' does not support option '").concat(a,"'"))}else-1!==Oe.indexOf(a)?_(t[a])&&(o[a]=Ce(e,t[a],r)):i||(o[a]=t[a]);return o}return _(t)&&(t=Ce(e,t,r)),t}function Ie(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return _(Te.returnValue)&&(t=Te.returnValue(e,t)),Le(e,t,n,{},r)}function Ee(t,n){if(k(Te,t)){var r=Te[t];return r?function(n,i){var o=r;_(r)&&(o=r(n)),n=Le(t,n,o.args,o.returnValue);var a=[n];"undefined"!==typeof i&&a.push(i),_(o.name)?t=o.name(n):b(o.name)&&(t=o.name);var s=e[t].apply(e,a);return G(t)?Ie(t,s,o.returnValue,K(t)):s}:function(){console.error("Platform '微信小程序' does not support '".concat(t,"'."))}}return n}var De=Object.create(null);["onTabBarMidButtonTap","subscribePush","unsubscribePush","onPush","offPush","share"].forEach((function(e){De[e]=function(e){return function(t){var n=t.fail,r=t.complete,i={errMsg:"".concat(e,":fail method '").concat(e,"' not supported")};_(n)&&n(i),_(r)&&r(i)}}(e)}));var Me={oauth:["weixin"],share:["weixin"],payment:["wxpay"],push:["weixin"]};var Fe=Object.freeze({__proto__:null,getProvider:function(e){var t=e.service,n=e.success,r=e.fail,i=e.complete,o=!1;Me[t]?(o={errMsg:"getProvider:ok",service:t,provider:Me[t]},_(n)&&n(o)):(o={errMsg:"getProvider:fail service not found"},_(r)&&r(o)),_(i)&&i(o)}}),je=function(){var e;return function(){return e||(e=new d.default),e}}();function $e(e,t,n){return e[t].apply(e,n)}var Re,Ne,Ue,Be=Object.freeze({__proto__:null,$on:function(){return $e(je(),"$on",Array.prototype.slice.call(arguments))},$off:function(){return $e(je(),"$off",Array.prototype.slice.call(arguments))},$once:function(){return $e(je(),"$once",Array.prototype.slice.call(arguments))},$emit:function(){return $e(je(),"$emit",Array.prototype.slice.call(arguments))}});function ze(e){return function(){try{return e.apply(e,arguments)}catch(t){console.error(t)}}}function We(e){try{return JSON.parse(e)}catch(t){}return e}var qe=[];function He(e,t){qe.forEach((function(n){n(e,t)})),qe.length=0}var Ve=[];var Ke=e.getAppBaseInfo&&e.getAppBaseInfo();Ke||(Ke=e.getSystemInfoSync());var Ge=Ke?Ke.host:null,Je=Ge&&"SAAASDK"===Ge.env?e.miniapp.shareVideoMessage:e.shareVideoMessage,Xe=Object.freeze({__proto__:null,shareVideoMessage:Je,getPushClientId:function(e){w(e)||(e={});var t=function(e){var t={};for(var n in e){var r=e[n];_(r)&&(t[n]=ze(r),delete e[n])}return t}(e),n=t.success,r=t.fail,i=t.complete,o=_(n),a=_(r),s=_(i);Promise.resolve().then((function(){"undefined"===typeof Ue&&(Ue=!1,Re="",Ne="uniPush is not enabled"),qe.push((function(e,t){var c;e?(c={errMsg:"getPushClientId:ok",cid:e},o&&n(c)):(c={errMsg:"getPushClientId:fail"+(t?" "+t:"")},a&&r(c)),s&&i(c)})),"undefined"!==typeof Re&&He(Re,Ne)}))},onPushMessage:function(e){-1===Ve.indexOf(e)&&Ve.push(e)},offPushMessage:function(e){if(e){var t=Ve.indexOf(e);t>-1&&Ve.splice(t,1)}else Ve.length=0},invokePushCallback:function(e){if("enabled"===e.type)Ue=!0;else if("clientId"===e.type)Re=e.cid,Ne=e.errMsg,He(Re,e.errMsg);else if("pushMsg"===e.type)for(var t={type:"receive",data:We(e.message)},n=0;n<Ve.length;n++){var r=Ve[n];if(r(t),t.stopped)break}else"click"===e.type&&Ve.forEach((function(t){t({type:"click",data:We(e.message)})}))},__f__: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];console[e].apply(console,n)}}),Ye=["__route__","__wxExparserNodeId__","__wxWebviewId__"];function Qe(e){return Behavior(e)}function Ze(){return!!this.route}function et(e){this.triggerEvent("__l",e)}function tt(e){var t=e.$scope,n={};Object.defineProperty(e,"$refs",{get:function(){var e={};(function e(t,n,r){var i=t.selectAllComponents(n)||[];i.forEach((function(t){var i=t.dataset.ref;r[i]=t.$vm||it(t),"scoped"===t.dataset.vueGeneric&&t.selectAllComponents(".scoped-ref").forEach((function(t){e(t,n,r)}))}))})(t,".vue-ref",e);var r=t.selectAllComponents(".vue-ref-in-for")||[];return r.forEach((function(t){var n=t.dataset.ref;e[n]||(e[n]=[]),e[n].push(t.$vm||it(t))})),function(e,t){var n=(0,c.default)(Set,(0,u.default)(Object.keys(e))),r=Object.keys(t);return r.forEach((function(r){var i=e[r],o=t[r];Array.isArray(i)&&Array.isArray(o)&&i.length===o.length&&o.every((function(e){return i.includes(e)}))||(e[r]=o,n.delete(r))})),n.forEach((function(t){delete e[t]})),e}(n,e)}})}function nt(e){var t,n=e.detail||e.value,r=n.vuePid,i=n.vueOptions;r&&(t=function e(t,n){for(var r,i=t.$children,o=i.length-1;o>=0;o--){var a=i[o];if(a.$scope._$vueId===n)return a}for(var s=i.length-1;s>=0;s--)if(r=e(i[s],n),r)return r}(this.$vm,r)),t||(t=this.$vm),i.parent=t}function rt(e){return Object.defineProperty(e,"__v_isMPComponent",{configurable:!0,enumerable:!1,value:!0}),e}function it(e){return function(e){return null!==e&&"object"===(0,l.default)(e)}(e)&&Object.isExtensible(e)&&Object.defineProperty(e,"__ob__",{configurable:!0,enumerable:!1,value:(0,s.default)({},"__v_skip",!0)}),e}var ot=/_(.*)_worklet_factory_/;var at=Page,st=Component,ct=/:/g,ut=S((function(e){return T(e.replace(ct,"-"))}));function lt(e){var t=e.triggerEvent,n=function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(this.$vm||this.dataset&&this.dataset.comType)e=ut(e);else{var o=ut(e);o!==e&&t.apply(this,[o].concat(r))}return t.apply(this,[e].concat(r))};try{e.triggerEvent=n}catch(r){e._triggerEvent=n}}function ft(e,t,n){var r=t[e];t[e]=function(){if(rt(this),lt(this),r){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.apply(this,t)}}}at.__$wrappered||(at.__$wrappered=!0,Page=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return ft("onLoad",e),at(e)},Page.after=at.after,Component=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return ft("created",e),st(e)});function dt(e,t,n){t.forEach((function(t){(function e(t,n){if(!n)return!0;if(d.default.options&&Array.isArray(d.default.options[t]))return!0;if(n=n.default||n,_(n))return!!_(n.extendOptions[t])||!!(n.super&&n.super.options&&Array.isArray(n.super.options[t]));if(_(n[t])||Array.isArray(n[t]))return!0;var r=n.mixins;return Array.isArray(r)?!!r.find((function(n){return e(t,n)})):void 0})(t,n)&&(e[t]=function(e){return this.$vm&&this.$vm.__call_hook(t,e)})}))}function ht(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];pt(t).forEach((function(t){return gt(e,t,n)}))}function pt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return e&&Object.keys(e).forEach((function(n){0===n.indexOf("on")&&_(e[n])&&t.push(n)})),t}function gt(e,t,n){-1!==n.indexOf(t)||k(e,t)||(e[t]=function(e){return this.$vm&&this.$vm.__call_hook(t,e)})}function vt(e,t){var n;return t=t.default||t,n=_(t)?t:e.extend(t),t=n.options,[n,t]}function yt(e,t){if(Array.isArray(t)&&t.length){var n=Object.create(null);t.forEach((function(e){n[e]=!0})),e.$scopedSlots=e.$slots=n}}function mt(e,t){e=(e||"").split(",");var n=e.length;1===n?t._$vueId=e[0]:2===n&&(t._$vueId=e[0],t._$vuePid=e[1])}function xt(e,t){var n=e.data||{},r=e.methods||{};if("function"===typeof n)try{n=n.call(t)}catch(i){Object({NODE_ENV:"production",VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"kitchendDevice",VUE_APP_PLATFORM:"mp-weixin",BASE_URL:"/"}).VUE_APP_DEBUG&&console.warn("根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。",n)}else try{n=JSON.parse(JSON.stringify(n))}catch(i){}return w(n)||(n={}),Object.keys(r).forEach((function(e){-1!==t.__lifecycle_hooks__.indexOf(e)||k(n,e)||(n[e]=r[e])})),n}var _t=[String,Number,Boolean,Object,Array,null];function bt(e){return function(t,n){this.$vm&&(this.$vm[e]=t)}}function wt(e,t){var n=e.behaviors,r=e.extends,i=e.mixins,o=e.props;o||(e.props=o=[]);var a=[];return Array.isArray(n)&&n.forEach((function(e){a.push(e.replace("uni://","wx".concat("://"))),"uni://form-field"===e&&(Array.isArray(o)?(o.push("name"),o.push("value")):(o.name={type:String,default:""},o.value={type:[String,Number,Boolean,Array,Object,Date],default:""}))})),w(r)&&r.props&&a.push(t({properties:At(r.props,!0)})),Array.isArray(i)&&i.forEach((function(e){w(e)&&e.props&&a.push(t({properties:At(e.props,!0)}))})),a}function kt(e,t,n,r){return Array.isArray(t)&&1===t.length?t[0]:t}function At(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>3?arguments[3]:void 0,r={};return t||(r.vueId={type:String,value:""},n.virtualHost&&(r.virtualHostStyle={type:null,value:""},r.virtualHostClass={type:null,value:""}),r.scopedSlotsCompiler={type:String,value:""},r.vueSlots={type:null,value:[],observer:function(e,t){var n=Object.create(null);e.forEach((function(e){n[e]=!0})),this.setData({$slots:n})}}),Array.isArray(e)?e.forEach((function(e){r[e]={type:null,observer:bt(e)}})):w(e)&&Object.keys(e).forEach((function(t){var n=e[t];if(w(n)){var i=n.default;_(i)&&(i=i()),n.type=kt(0,n.type),r[t]={type:-1!==_t.indexOf(n.type)?n.type:null,value:i,observer:bt(t)}}else{var o=kt(0,n);r[t]={type:-1!==_t.indexOf(o)?o:null,observer:bt(t)}}})),r}function St(e,t,n,r){var i={};return Array.isArray(t)&&t.length&&t.forEach((function(t,o){"string"===typeof t?t?"$event"===t?i["$"+o]=n:"arguments"===t?i["$"+o]=n.detail&&n.detail.__args__||r:0===t.indexOf("$event.")?i["$"+o]=e.__get_value(t.replace("$event.",""),n):i["$"+o]=e.__get_value(t):i["$"+o]=e:i["$"+o]=function(e,t){var n=e;return t.forEach((function(t){var r=t[0],i=t[2];if(r||"undefined"!==typeof i){var o,a=t[1],s=t[3];Number.isInteger(r)?o=r:r?"string"===typeof r&&r&&(o=0===r.indexOf("#s#")?r.substr(3):e.__get_value(r,n)):o=n,Number.isInteger(o)?n=i:a?Array.isArray(o)?n=o.find((function(t){return e.__get_value(a,t)===i})):w(o)?n=Object.keys(o).find((function(t){return e.__get_value(a,o[t])===i})):console.error("v-for 暂不支持循环数据:",o):n=o[i],s&&(n=e.__get_value(s,n))}})),n}(e,t)})),i}function Pt(e){for(var t={},n=1;n<e.length;n++){var r=e[n];t[r[0]]=r[1]}return t}function Tt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],i=arguments.length>4?arguments[4]:void 0,o=arguments.length>5?arguments[5]:void 0,a=!1,s=w(t.detail)&&t.detail.__args__||[t.detail];if(i&&(a=t.currentTarget&&t.currentTarget.dataset&&"wx"===t.currentTarget.dataset.comType,!n.length))return a?[t]:s;var c=St(e,r,t,s),u=[];return n.forEach((function(e){"$event"===e?"__set_model"!==o||i?i&&!a?u.push(s[0]):u.push(t):u.push(t.target.value):Array.isArray(e)&&"o"===e[0]?u.push(Pt(e)):"string"===typeof e&&k(c,e)?u.push(c[e]):u.push(e)})),u}function Ot(e){var t=this;e=function(e){try{e.mp=JSON.parse(JSON.stringify(e))}catch(t){}return e.stopPropagation=A,e.preventDefault=A,e.target=e.target||{},k(e,"detail")||(e.detail={}),k(e,"markerId")&&(e.detail="object"===(0,l.default)(e.detail)?e.detail:{},e.detail.markerId=e.markerId),w(e.detail)&&(e.target=Object.assign({},e.target,e.detail)),e}(e);var n=(e.currentTarget||e.target).dataset;if(!n)return console.warn("事件信息不存在");var r=n.eventOpts||n["event-opts"];if(!r)return console.warn("事件信息不存在");var i=e.type,o=[];return r.forEach((function(n){var r=n[0],a=n[1],s="^"===r.charAt(0);r=s?r.slice(1):r;var c="~"===r.charAt(0);r=c?r.slice(1):r,a&&function(e,t){return e===t||"regionchange"===t&&("begin"===e||"end"===e)}(i,r)&&a.forEach((function(n){var r=n[0];if(r){var i=t.$vm;if(i.$options.generic&&(i=function(e){var t=e.$parent;while(t&&t.$parent&&(t.$options.generic||t.$parent.$options.generic||t.$scope._$vuePid))t=t.$parent;return t&&t.$parent}(i)||i),"$emit"===r)return void i.$emit.apply(i,Tt(t.$vm,e,n[1],n[2],s,r));var a=i[r];if(!_(a)){var u="page"===t.$vm.mpType?"Page":"Component",l=t.route||t.is;throw new Error("".concat(u,' "').concat(l,'" does not have a method "').concat(r,'"'))}if(c){if(a.once)return;a.once=!0}var f=Tt(t.$vm,e,n[1],n[2],s,r);f=Array.isArray(f)?f:[],/=\s*\S+\.eventParams\s*\|\|\s*\S+\[['"]event-params['"]\]/.test(a.toString())&&(f=f.concat([,,,,,,,,,,e])),o.push(a.apply(i,f))}}))})),"input"===i&&1===o.length&&"undefined"!==typeof o[0]?o[0]:void 0}var Ct={};var Lt=["onShow","onHide","onError","onPageNotFound","onThemeChange","onUnhandledRejection"];function It(){d.default.prototype.getOpenerEventChannel=function(){return this.$scope.getOpenerEventChannel()};var e=d.default.prototype.__call_hook;d.default.prototype.__call_hook=function(t,n){return"onLoad"===t&&n&&n.__id__&&(this.__eventChannel__=function(e){var t=Ct[e];return delete Ct[e],t}(n.__id__),delete n.__id__),e.call(this,t,n)}}function Et(t,n){var r=n.mocks,i=n.initRefs;It(),function(){var e={},t={};function n(e){var t=this.$options.propsData.vueId;if(t){var n=t.split(",")[0];e(n)}}d.default.prototype.$hasSSP=function(n){var r=e[n];return r||(t[n]=this,this.$on("hook:destroyed",(function(){delete t[n]}))),r},d.default.prototype.$getSSP=function(t,n,r){var i=e[t];if(i){var o=i[n]||[];return r?o:o[0]}},d.default.prototype.$setSSP=function(t,r){var i=0;return n.call(this,(function(n){var o=e[n],a=o[t]=o[t]||[];a.push(r),i=a.length-1})),i},d.default.prototype.$initSSP=function(){n.call(this,(function(t){e[t]={}}))},d.default.prototype.$callSSP=function(){n.call(this,(function(e){t[e]&&t[e].$forceUpdate()}))},d.default.mixin({destroyed:function(){var n=this.$options.propsData,r=n&&n.vueId;r&&(delete e[r],delete t[r])}})}(),t.$options.store&&(d.default.prototype.$store=t.$options.store),function(e){e.prototype.uniIDHasRole=function(e){var t=y(),n=t.role;return n.indexOf(e)>-1},e.prototype.uniIDHasPermission=function(e){var t=y(),n=t.permission;return this.uniIDHasRole("admin")||n.indexOf(e)>-1},e.prototype.uniIDTokenValid=function(){var e=y(),t=e.tokenExpired;return t>Date.now()}}(d.default),d.default.prototype.mpHost="mp-weixin",d.default.mixin({beforeCreate:function(){if(this.$options.mpType){if(this.mpType=this.$options.mpType,this.$mp=(0,s.default)({data:{}},this.mpType,this.$options.mpInstance),this.$scope=this.$options.mpInstance,delete this.$options.mpType,delete this.$options.mpInstance,"page"===this.mpType&&"function"===typeof getApp){var e=getApp();e.$vm&&e.$vm.$i18n&&(this._i18n=e.$vm.$i18n)}"app"!==this.mpType&&(i(this),function(e,t){var n=e.$mp[e.mpType];t.forEach((function(t){k(n,t)&&(e[t]=n[t])}))}(this,r))}}});var o={onLaunch:function(n){this.$vm||(e.canIUse&&!e.canIUse("nextTick")&&console.error("当前微信基础库版本过低,请将 微信开发者工具-详情-项目设置-调试基础库版本 更换为`2.3.0`以上"),this.$vm=t,this.$vm.$mp={app:this},this.$vm.$scope=this,this.$vm.globalData=this.globalData,this.$vm._isMounted=!0,this.$vm.__call_hook("mounted",n),this.$vm.__call_hook("onLaunch",n))}};o.globalData=t.$options.globalData||{};var a=t.$options.methods;return a&&Object.keys(a).forEach((function(e){o[e]=a[e]})),function(e,t,n){var r=e.observable({locale:n||oe.getLocale()}),i=[];t.$watchLocale=function(e){i.push(e)},Object.defineProperty(t,"$locale",{get:function(){return r.locale},set:function(e){r.locale=e,i.forEach((function(t){return t(e)}))}})}(d.default,t,function(){var t,n=e.getAppBaseInfo(),r=n&&n.language?n.language:"en";return t=se(r)||"en",t}()),dt(o,Lt),ht(o,t.$options),o}function Dt(e){return Et(e,{mocks:Ye,initRefs:tt})}function Mt(e){return App(Dt(e)),e}var Ft=/[!'()*]/g,jt=function(e){return"%"+e.charCodeAt(0).toString(16)},$t=/%2C/g,Rt=function(e){return encodeURIComponent(e).replace(Ft,jt).replace($t,",")};function Nt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Rt,n=e?Object.keys(e).map((function(n){var r=e[n];if(void 0===r)return"";if(null===r)return t(n);if(Array.isArray(r)){var i=[];return r.forEach((function(e){void 0!==e&&(null===e?i.push(t(n)):i.push(t(n)+"="+t(e)))})),i.join("&")}return t(n)+"="+t(r)})).filter((function(e){return e.length>0})).join("&"):null;return n?"?".concat(n):""}function Ut(e,t){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isPage,r=t.initRelation,i=arguments.length>2?arguments[2]:void 0,o=vt(d.default,e),s=(0,a.default)(o,2),c=s[0],u=s[1],l=p({multipleSlots:!0,addGlobalClass:!0},u.options||{});u["mp-weixin"]&&u["mp-weixin"].options&&Object.assign(l,u["mp-weixin"].options);var f={options:l,data:xt(u,d.default.prototype),behaviors:wt(u,Qe),properties:At(u.props,!1,u.__file,l),lifetimes:{attached:function(){var e=this.properties,t={mpType:n.call(this)?"page":"component",mpInstance:this,propsData:e};mt(e.vueId,this),r.call(this,{vuePid:this._$vuePid,vueOptions:t}),this.$vm=new c(t),yt(this.$vm,e.vueSlots),this.$vm.$mount()},ready:function(){this.$vm&&(this.$vm._isMounted=!0,this.$vm.__call_hook("mounted"),this.$vm.__call_hook("onReady"))},detached:function(){this.$vm&&this.$vm.$destroy()}},pageLifetimes:{show:function(e){this.$vm&&this.$vm.__call_hook("onPageShow",e)},hide:function(){this.$vm&&this.$vm.__call_hook("onPageHide")},resize:function(e){this.$vm&&this.$vm.__call_hook("onPageResize",e)}},methods:{__l:nt,__e:Ot}};return u.externalClasses&&(f.externalClasses=u.externalClasses),Array.isArray(u.wxsCallMethods)&&u.wxsCallMethods.forEach((function(e){f.methods[e]=function(t){return this.$vm[e](t)}})),i?[f,u,c]:n?f:[f,c]}(e,{isPage:Ze,initRelation:et},t)}var Bt=["onShow","onHide","onUnload"];function zt(e){var t=Ut(e,!0),n=(0,a.default)(t,2),r=n[0],i=n[1];return dt(r.methods,Bt,i),r.methods.onLoad=function(e){this.options=e;var t=Object.assign({},e);delete t.__id__,this.$page={fullPath:"/"+(this.route||this.is)+Nt(t)},this.$vm.$mp.query=e,this.$vm.__call_hook("onLoad",e)},ht(r.methods,e,["onReady"]),function(e,t){t&&Object.keys(t).forEach((function(n){var r=n.match(ot);if(r){var i=r[1];e[n]=t[n],e[i]=t[i]}}))}(r.methods,i.methods),r}function Wt(e){return Component(function(e){return zt(e)}(e))}function qt(e){return Component(Ut(e))}function Ht(t){var n=Dt(t),r=getApp({allowDefault:!0});t.$scope=r;var i=r.globalData;if(i&&Object.keys(n.globalData).forEach((function(e){k(i,e)||(i[e]=n.globalData[e])})),Object.keys(n).forEach((function(e){k(r,e)||(r[e]=n[e])})),_(n.onShow)&&e.onAppShow&&e.onAppShow((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.__call_hook("onShow",n)})),_(n.onHide)&&e.onAppHide&&e.onAppHide((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.__call_hook("onHide",n)})),_(n.onLaunch)){var o=e.getLaunchOptionsSync&&e.getLaunchOptionsSync();t.__call_hook("onLaunch",o)}return t}function Vt(t){var n=Dt(t);if(_(n.onShow)&&e.onAppShow&&e.onAppShow((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.__call_hook("onShow",n)})),_(n.onHide)&&e.onAppHide&&e.onAppHide((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.__call_hook("onHide",n)})),_(n.onLaunch)){var r=e.getLaunchOptionsSync&&e.getLaunchOptionsSync();t.__call_hook("onLaunch",r)}return t}Bt.push.apply(Bt,["onPullDownRefresh","onReachBottom","onAddToFavorites","onShareTimeline","onShareAppMessage","onPageScroll","onResize","onTabItemTap"]),["vibrate","preloadPage","unPreloadPage","loadSubPackage"].forEach((function(e){Te[e]=!1})),[].forEach((function(t){var n=Te[t]&&Te[t].name?Te[t].name:t;e.canIUse(n)||(Te[t]=!1)}));var Kt={};"undefined"!==typeof Proxy?Kt=new Proxy({},{get:function(t,n){return k(t,n)?t[n]:fe[n]?fe[n]:Xe[n]?Y(n,Xe[n]):Fe[n]?Y(n,Fe[n]):De[n]?Y(n,De[n]):Be[n]?Be[n]:Y(n,Ee(n,e[n]))},set:function(e,t,n){return e[t]=n,!0}}):(Object.keys(fe).forEach((function(e){Kt[e]=fe[e]})),Object.keys(De).forEach((function(e){Kt[e]=Y(e,De[e])})),Object.keys(Fe).forEach((function(e){Kt[e]=Y(e,Fe[e])})),Object.keys(Be).forEach((function(e){Kt[e]=Be[e]})),Object.keys(Xe).forEach((function(e){Kt[e]=Y(e,Xe[e])})),Object.keys(e).forEach((function(t){(k(e,t)||k(Te,t))&&(Kt[t]=Y(t,Ee(t,e[t])))}))),e.createApp=Mt,e.createPage=Wt,e.createComponent=qt,e.createSubpackageApp=Ht,e.createPlugin=Vt;var Gt=Kt,Jt=Gt;t.default=Jt}).call(this,n("3223")["default"],n("0ee4"))},e6db:function(e,t,n){var r=n("3b2d")["default"];e.exports=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},ed45:function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports["default"]=e.exports},ee10:function(e,t){function n(e,t,n,r,i,o,a){try{var s=e[o](a),c=s.value}catch(u){return void n(u)}s.done?t(c):Promise.resolve(c).then(r,i)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise((function(i,o){var a=e.apply(t,r);function s(e){n(a,i,o,s,c,"next",e)}function c(e){n(a,i,o,s,c,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports["default"]=e.exports}}]);