define(["gpui-style-inject","react","mobx"],(function(e,t,n){"use strict";e=e&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e;var r="default"in t?t.default:t,o=function(e,t){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};
/*! *****************************************************************************
    Copyright (c) Microsoft Corporation.

    Permission to use, copy, modify, and/or distribute this software for any
    purpose with or without fee is hereby granted.

    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
    REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
    AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
    INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
    LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
    OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
    PERFORMANCE OF THIS SOFTWARE.
    ***************************************************************************** */function i(e,t,n,r){var o,i=arguments.length,a=i<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function a(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))}function s(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}}e("html, body, #root {\n  width: 100%;\n  height: 100%;\n  margin: 0;\n  padding: 0;\n  overflow: hidden; }\n\n.g__index {\n  position: relative;\n  box-sizing: border-box;\n  width: 100%;\n  height: 100%; }\n");var u="index-module_board__21yi_",c="index-module_ring__291t3",f="index-module_ring__border__3mJyI",l="index-module_ring__content__2CYt4",p="index-module_data__17DmN",d="index-module_unit__3UrZa",h="index-module_name__w8JQd";if(e(".index-module_board__21yi_ {\n  display: flex;\n  flex-direction: column;\n  align-items: center;\n  width: 100%;\n  height: 100%; }\n  .index-module_board__21yi_ .index-module_ring__291t3 {\n    cursor: pointer;\n    position: relative;\n    width: 80vw;\n    height: 80vw;\n    border-radius: 50%;\n    overflow: hidden; }\n    .index-module_board__21yi_ .index-module_ring__border__3mJyI {\n      position: absolute;\n      top: 0;\n      left: 0;\n      width: 100%;\n      height: 100%; }\n    .index-module_board__21yi_ .index-module_ring__content__2CYt4 {\n      display: flex;\n      flex-direction: column;\n      justify-content: center;\n      align-items: center;\n      width: 100%;\n      height: 100%;\n      border-radius: 50%; }\n      .index-module_board__21yi_ .index-module_ring__content__2CYt4 .index-module_data__17DmN {\n        position: relative;\n        line-height: 12vh;\n        font-size: 12vh; }\n        .index-module_board__21yi_ .index-module_ring__content__2CYt4 .index-module_data__17DmN .index-module_unit__3UrZa {\n          padding-left: 2vh;\n          font-size: 6.5vh; }\n  .index-module_board__21yi_ .index-module_name__w8JQd {\n    margin-top: 8vh;\n    line-height: 8vh;\n    font-size: 8vh;\n    color: #cde0ff; }\n"),!t.useState)throw new Error("mobx-react-lite requires React with Hooks support");if(!n.spy)throw new Error("mobx-react-lite requires mobx at least version 4 to be available");function m(){return(m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function y(){var e=t.useState(0)[1];return t.useCallback((function(){e((function(e){return e+1}))}),[])}function v(e){return n.getDependencyTree(e)}var g,b=1e4,w=new Set;function _(){void 0===g&&(g=setTimeout(x,1e4))}function x(){g=void 0;var e=Date.now();w.forEach((function(t){var n=t.current;n&&e>=n.cleanAt&&(n.reaction.dispose(),t.current=null,w.delete(t))})),w.size>0&&_()}var C={};function E(e){return"observer"+e}function R(e,t,o){void 0===t&&(t="observed"),void 0===o&&(o=C);var i,a=(o.useForceUpdate||y)(),s=r.useRef(null);if(!s.current){var u=new n.Reaction(E(t),(function(){c.mounted?a():(u.dispose(),s.current=null)})),c=function(e){return{cleanAt:Date.now()+b,reaction:e}}(u);s.current=c,i=s,w.add(i),_()}var f,l,p=s.current.reaction;if(r.useDebugValue(p,v),r.useEffect((function(){var e;return e=s,w.delete(e),s.current?s.current.mounted=!0:(s.current={reaction:new n.Reaction(E(t),(function(){a()})),cleanAt:1/0},a()),function(){s.current.reaction.dispose(),s.current=null}}),[]),p.track((function(){try{f=e()}catch(e){l=e}})),l)throw l;return f}function O(e,n){var r,o,i,a=m({forwardRef:!1},n),s=e.displayName||e.name,u=function(t,n){return R((function(){return e(t,n)}),s)};return u.displayName=s,r=a.forwardRef?t.memo(t.forwardRef(u)):t.memo(u),o=e,i=r,Object.keys(o).forEach((function(e){j[e]||Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(o,e))})),r.displayName=s,r}var j={$$typeof:!0,render:!0,compare:!0,type:!0};function S(e){var t=e.children,n=e.render,r=t||n;return"function"!=typeof r?null:R(r)}function N(e,t,n,r,o){var i="children"===t?"render":"children",a="function"==typeof e[t],s="function"==typeof e[i];return a&&s?new Error("MobX Observer: Do not use children and render in the same time in`"+n):a||s?null:new Error("Invalid prop `"+o+"` of type `"+typeof e[t]+"` supplied to `"+n+"`, expected `function`.")}S.propTypes={children:N,render:N},S.displayName="Observer";var k=0;var T={};function P(e){return T[e]||(T[e]=function(e){if("function"==typeof Symbol)return Symbol(e);var t="__$mobx-react "+e+" ("+k+")";return k++,t}(e)),T[e]}function D(e,t){if(A(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=0;o<n.length;o++)if(!Object.hasOwnProperty.call(t,n[o])||!A(e[n[o]],t[n[o]]))return!1;return!0}function A(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function U(e,t,n){Object.hasOwnProperty.call(e,t)?e[t]=n:Object.defineProperty(e,t,{enumerable:!1,configurable:!0,writable:!0,value:n})}var B=P("patchMixins"),q=P("patchedDefinition");function L(e,t){for(var n=this,r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];t.locks++;try{var a;return null!=e&&(a=e.apply(this,o)),a}finally{t.locks--,0===t.locks&&t.methods.forEach((function(e){e.apply(n,o)}))}}function $(e,t){return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];L.call.apply(L,[this,e,t].concat(r))}}function F(e,t,n){var r=function(e,t){var n=e[B]=e[B]||{},r=n[t]=n[t]||{};return r.locks=r.locks||0,r.methods=r.methods||[],r}(e,t);r.methods.indexOf(n)<0&&r.methods.push(n);var o=Object.getOwnPropertyDescriptor(e,t);if(!o||!o[q]){var i=e[t],a=function e(t,n,r,o,i){var a,s=$(i,o);return(a={})[q]=!0,a.get=function(){return s},a.set=function(i){if(this===t)s=$(i,o);else{var a=e(this,n,r,o,i);Object.defineProperty(this,n,a)}},a.configurable=!0,a.enumerable=r,a}(e,t,o?o.enumerable:void 0,r,i);Object.defineProperty(e,t,a)}}var I=n.$mobx||"$mobx",M=P("isUnmounted"),z=P("skipRender"),H=P("isForcingUpdate");function J(e){var n=e.prototype;if(n.componentWillReact)throw new Error("The componentWillReact life-cycle event is no longer supported");if(e.__proto__!==t.PureComponent)if(n.shouldComponentUpdate){if(n.shouldComponentUpdate!==W)throw new Error("It is not allowed to use shouldComponentUpdate in observer based components.")}else n.shouldComponentUpdate=W;Y(n,"props"),Y(n,"state");var r=n.render;return n.render=function(){return X.call(this,r)},F(n,"componentWillUnmount",(function(){this.render[I]&&this.render[I].dispose(),this[M]=!0})),e}function X(e){var r=this;U(this,z,!1),U(this,H,!1);var o,i=(o=this).displayName||o.name||o.constructor&&(o.constructor.displayName||o.constructor.name)||"<component>",a=e.bind(this),s=!1,u=new n.Reaction(i+".render()",(function(){if(!s&&(s=!0,!0!==r[M])){var e=!0;try{U(r,H,!0),r[z]||t.Component.prototype.forceUpdate.call(r),e=!1}finally{U(r,H,!1),e&&u.dispose()}}}));function c(){s=!1;var e=void 0,t=void 0;if(u.track((function(){try{t=n._allowStateChanges(!1,a)}catch(t){e=t}})),e)throw e;return t}return u.reactComponent=this,c[I]=u,this.render=c,c.call(this)}function W(e,t){return this.state!==t||!D(this.props,e)}function Y(e,t){var r=P("reactProp_"+t+"_valueHolder"),o=P("reactProp_"+t+"_atomHolder");function i(){return this[o]||U(this,o,n.createAtom("reactive "+t)),this[o]}Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){var e=!1;return n._allowStateReadsStart&&n._allowStateReadsEnd&&(e=n._allowStateReadsStart(!0)),i.call(this).reportObserved(),n._allowStateReadsStart&&n._allowStateReadsEnd&&n._allowStateReadsEnd(e),this[r]},set:function(e){this[H]||D(this[r],e)?U(this,r,e):(U(this,r,e),U(this,z,!0),i.call(this).reportChanged(),U(this,z,!1))}})}var V="function"==typeof Symbol&&Symbol.for,G=V?Symbol.for("react.forward_ref"):"function"==typeof t.forwardRef&&t.forwardRef((function(e){return null})).$$typeof,K=V?Symbol.for("react.memo"):"function"==typeof t.memo&&t.memo((function(e){return null})).$$typeof;function Q(e){if(!0===e.isMobxInjector&&console.warn("Mobx observer: You are trying to use 'observer' on a component that already has 'inject'. Please apply 'observer' before applying 'inject'"),K&&e.$$typeof===K)throw new Error("Mobx observer: You are trying to use 'observer' on a function component wrapped in either another observer or 'React.memo'. The observer already applies 'React.memo' for you.");if(G&&e.$$typeof===G){var n=e.render;if("function"!=typeof n)throw new Error("render property of ForwardRef was not a function");return t.forwardRef((function(){var e=arguments;return t.createElement(S,null,(function(){return n.apply(void 0,e)}))}))}return"function"!=typeof e||e.prototype&&e.prototype.render||e.isReactClass||Object.prototype.isPrototypeOf.call(t.Component,e)?J(e):O(e)}if(!t.Component)throw new Error("mobx-react requires React to be available");if(!n.observable)throw new Error("mobx-react requires mobx to be available");"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var Z=function(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}((function(e,t){var n;n=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){var r=n(2),o=n(3),i=n(4),a=n(22);function s(e){var t=new i(e),n=o(i.prototype.request,t);return r.extend(n,i.prototype,t),r.extend(n,t),n}var u=s(n(10));u.Axios=i,u.create=function(e){return s(a(u.defaults,e))},u.Cancel=n(23),u.CancelToken=n(24),u.isCancel=n(9),u.all=function(e){return Promise.all(e)},u.spread=n(25),e.exports=u,e.exports.default=u},function(e,t,n){var r=n(3),o=Object.prototype.toString;function i(e){return"[object Array]"===o.call(e)}function a(e){return void 0===e}function s(e){return null!==e&&"object"==typeof e}function u(e){return"[object Function]"===o.call(e)}function c(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),i(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.call(null,e[o],o,e)}e.exports={isArray:i,isArrayBuffer:function(e){return"[object ArrayBuffer]"===o.call(e)},isBuffer:function(e){return null!==e&&!a(e)&&null!==e.constructor&&!a(e.constructor)&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)},isFormData:function(e){return"undefined"!=typeof FormData&&e instanceof FormData},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer},isString:function(e){return"string"==typeof e},isNumber:function(e){return"number"==typeof e},isObject:s,isUndefined:a,isDate:function(e){return"[object Date]"===o.call(e)},isFile:function(e){return"[object File]"===o.call(e)},isBlob:function(e){return"[object Blob]"===o.call(e)},isFunction:u,isStream:function(e){return s(e)&&u(e.pipe)},isURLSearchParams:function(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:c,merge:function e(){var t={};function n(n,r){"object"==typeof t[r]&&"object"==typeof n?t[r]=e(t[r],n):t[r]=n}for(var r=0,o=arguments.length;r<o;r++)c(arguments[r],n);return t},deepMerge:function e(){var t={};function n(n,r){"object"==typeof t[r]&&"object"==typeof n?t[r]=e(t[r],n):t[r]="object"==typeof n?e({},n):n}for(var r=0,o=arguments.length;r<o;r++)c(arguments[r],n);return t},extend:function(e,t,n){return c(t,(function(t,o){e[o]=n&&"function"==typeof t?r(t,n):t})),e},trim:function(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}}},function(e,t){e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}}},function(e,t,n){var r=n(2),o=n(5),i=n(6),a=n(7),s=n(22);function u(e){this.defaults=e,this.interceptors={request:new i,response:new i}}u.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=s(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var t=[a,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach((function(e){t.unshift(e.fulfilled,e.rejected)})),this.interceptors.response.forEach((function(e){t.push(e.fulfilled,e.rejected)}));t.length;)n=n.then(t.shift(),t.shift());return n},u.prototype.getUri=function(e){return e=s(this.defaults,e),o(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(e){u.prototype[e]=function(t,n){return this.request(r.merge(n||{},{method:e,url:t}))}})),r.forEach(["post","put","patch"],(function(e){u.prototype[e]=function(t,n,o){return this.request(r.merge(o||{},{method:e,url:t,data:n}))}})),e.exports=u},function(e,t,n){var r=n(2);function o(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,n){if(!t)return e;var i;if(n)i=n(t);else if(r.isURLSearchParams(t))i=t.toString();else{var a=[];r.forEach(t,(function(e,t){null!=e&&(r.isArray(e)?t+="[]":e=[e],r.forEach(e,(function(e){r.isDate(e)?e=e.toISOString():r.isObject(e)&&(e=JSON.stringify(e)),a.push(o(t)+"="+o(e))})))})),i=a.join("&")}if(i){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}},function(e,t,n){var r=n(2);function o(){this.handlers=[]}o.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},o.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},o.prototype.forEach=function(e){r.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=o},function(e,t,n){var r=n(2),o=n(8),i=n(9),a=n(10);function s(e){e.cancelToken&&e.cancelToken.throwIfRequested()}e.exports=function(e){return s(e),e.headers=e.headers||{},e.data=o(e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||a.adapter)(e).then((function(t){return s(e),t.data=o(t.data,t.headers,e.transformResponse),t}),(function(t){return i(t)||(s(e),t&&t.response&&(t.response.data=o(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},function(e,t,n){var r=n(2);e.exports=function(e,t,n){return r.forEach(n,(function(n){e=n(e,t)})),e}},function(e,t){e.exports=function(e){return!(!e||!e.__CANCEL__)}},function(e,t,n){var r=n(2),o=n(11),i={"Content-Type":"application/x-www-form-urlencoded"};function a(e,t){!r.isUndefined(e)&&r.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var s,u={adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(s=n(12)),s),transformRequest:[function(e,t){return o(t,"Accept"),o(t,"Content-Type"),r.isFormData(e)||r.isArrayBuffer(e)||r.isBuffer(e)||r.isStream(e)||r.isFile(e)||r.isBlob(e)?e:r.isArrayBufferView(e)?e.buffer:r.isURLSearchParams(e)?(a(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):r.isObject(e)?(a(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(e){u.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){u.headers[e]=r.merge(i)})),e.exports=u},function(e,t,n){var r=n(2);e.exports=function(e,t){r.forEach(e,(function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])}))}},function(e,t,n){var r=n(2),o=n(13),i=n(5),a=n(16),s=n(19),u=n(20),c=n(14);e.exports=function(e){return new Promise((function(t,f){var l=e.data,p=e.headers;r.isFormData(l)&&delete p["Content-Type"];var d=new XMLHttpRequest;if(e.auth){var h=e.auth.username||"",m=e.auth.password||"";p.Authorization="Basic "+btoa(h+":"+m)}var y=a(e.baseURL,e.url);if(d.open(e.method.toUpperCase(),i(y,e.params,e.paramsSerializer),!0),d.timeout=e.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in d?s(d.getAllResponseHeaders()):null,r={data:e.responseType&&"text"!==e.responseType?d.response:d.responseText,status:d.status,statusText:d.statusText,headers:n,config:e,request:d};o(t,f,r),d=null}},d.onabort=function(){d&&(f(c("Request aborted",e,"ECONNABORTED",d)),d=null)},d.onerror=function(){f(c("Network Error",e,null,d)),d=null},d.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),f(c(t,e,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var v=n(21),g=(e.withCredentials||u(y))&&e.xsrfCookieName?v.read(e.xsrfCookieName):void 0;g&&(p[e.xsrfHeaderName]=g)}if("setRequestHeader"in d&&r.forEach(p,(function(e,t){void 0===l&&"content-type"===t.toLowerCase()?delete p[t]:d.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(d.withCredentials=!!e.withCredentials),e.responseType)try{d.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&d.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then((function(e){d&&(d.abort(),f(e),d=null)})),void 0===l&&(l=null),d.send(l)}))}},function(e,t,n){var r=n(14);e.exports=function(e,t,n){var o=n.config.validateStatus;!o||o(n.status)?e(n):t(r("Request failed with status code "+n.status,n.config,null,n.request,n))}},function(e,t,n){var r=n(15);e.exports=function(e,t,n,o,i){var a=new Error(e);return r(a,t,n,o,i)}},function(e,t){e.exports=function(e,t,n,r,o){return e.config=t,n&&(e.code=n),e.request=r,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}},function(e,t,n){var r=n(17),o=n(18);e.exports=function(e,t){return e&&!r(t)?o(e,t):t}},function(e,t){e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t){e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e,t,n){var r=n(2),o=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,i,a={};return e?(r.forEach(e.split("\n"),(function(e){if(i=e.indexOf(":"),t=r.trim(e.substr(0,i)).toLowerCase(),n=r.trim(e.substr(i+1)),t){if(a[t]&&o.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([n]):a[t]?a[t]+", "+n:n}})),a):a}},function(e,t,n){var r=n(2);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=o(window.location.href),function(t){var n=r.isString(t)?o(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0}},function(e,t,n){var r=n(2);e.exports=r.isStandardBrowserEnv()?{write:function(e,t,n,o,i,a){var s=[];s.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),r.isString(o)&&s.push("path="+o),r.isString(i)&&s.push("domain="+i),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(e,t,n){var r=n(2);e.exports=function(e,t){t=t||{};var n={},o=["url","method","params","data"],i=["headers","auth","proxy"],a=["baseURL","url","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"];r.forEach(o,(function(e){void 0!==t[e]&&(n[e]=t[e])})),r.forEach(i,(function(o){r.isObject(t[o])?n[o]=r.deepMerge(e[o],t[o]):void 0!==t[o]?n[o]=t[o]:r.isObject(e[o])?n[o]=r.deepMerge(e[o]):void 0!==e[o]&&(n[o]=e[o])})),r.forEach(a,(function(r){void 0!==t[r]?n[r]=t[r]:void 0!==e[r]&&(n[r]=e[r])}));var s=o.concat(i).concat(a),u=Object.keys(t).filter((function(e){return-1===s.indexOf(e)}));return r.forEach(u,(function(r){void 0!==t[r]?n[r]=t[r]:void 0!==e[r]&&(n[r]=e[r])})),n}},function(e,t){function n(e){this.message=e}n.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},n.prototype.__CANCEL__=!0,e.exports=n},function(e,t,n){var r=n(23);function o(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var e;return{token:new o((function(t){e=t})),cancel:e}},e.exports=o},function(e,t){e.exports=function(e){return function(t){return e.apply(null,t)}}}])},e.exports=n()}));return function(e){function r(t){var r=e.call(this,t)||this;return r.padding="7vh 2vh 2vh",r.startColor="#0096ff",r.endColor="#00d8ff",r.data={count:0,amount:0},r.getData=function(){return a(r,void 0,void 0,(function(){var e,t,n,r,o,i,a,u;return s(this,(function(s){switch(s.label){case 0:if(e=this.props.gpui.params,t=e.base_url,n=e.set_id,r=e.deviceToken,!t||!n||!r)return[2];this.timer&&(clearTimeout(this.timer),this.timer=null),s.label=1;case 1:return s.trys.push([1,3,,4]),[4,Z.get(t+"/set/data/"+n,{headers:{"X-Gini-Token":r}})];case 2:return o=s.sent().data,i=o[0].data[0].data["台数"],a=o[0].data[0].data["价格"],this.data={count:i,amount:Math.round(100*a/1e4)/100},[3,4];case 3:return u=s.sent(),console.error("@components:wall-iharbour/data-display-board: 组件渲染时发生错误",u),[3,4];case 4:return this.props.gpui.params.interval>0&&(this.timer=setTimeout(this.getData,this.props.gpui.params.interval)),[2]}}))}))},r.gotoDetail=function(e){var t=r.props.gpui.params;r.props.gpui.root.navigate("@component:godiva/set",{base_url:t.base_url,set_id:t.page.set_id,share_id:t.page.share_id,"@theme":"normal",showSearchBar:!0,criteria:[{id:"__1",alias:"设备分区",key:t.page.filter_key,type:"string",level:!1,filter:{name:"",show:!1,type:"select",params:{isMultiple:!1,searchMode:"contain",default:e}}}],defaultTextColor:"#D4D4D4",padding:t.page.padding},{styles:{"@theme":"page"},mode:"replace"})},n.reaction((function(){return t.gpui.params.padding}),(function(e){r.padding=e||"7vh 2vh 2vh"}),{fireImmediately:!0}),n.reaction((function(){return{startColor:t.gpui.params.startColor,endColor:t.gpui.params.endColor}}),(function(e){var t=e.startColor,n=e.endColor;r.startColor=t||"#0096ff",r.endColor=n||"#00d8ff"}),{fireImmediately:!0}),n.reaction((function(){return{baseURL:r.props.gpui.params.base_url,setId:r.props.gpui.params.set_id,deviceToken:r.props.gpui.params.deviceToken,interval:r.props.gpui.params.interval}}),(function(){r.getData()}),{fireImmediately:!0}),r}return function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}(r,e),Object.defineProperty(r.prototype,"fontColor",{get:function(){return{backgroundImage:"linear-gradient(to bottom, "+this.startColor+", "+this.endColor+")",WebkitTextFillColor:"transparent",WebkitBackgroundClip:"text"}},enumerable:!1,configurable:!0}),r.prototype.render=function(){var e=this;return t.createElement("div",{className:"g__index",style:{padding:this.padding}},t.createElement("div",{className:u},t.createElement("div",{className:c,onClick:function(){return e.gotoDetail(e.props.gpui.params.name)}},t.createElement("div",{className:f},t.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",version:"1.1",viewBox:"0 0 100 100"},t.createElement("defs",null,t.createElement("linearGradient",{id:"grad1",x1:"0%",y1:"0%",x2:"100%",y2:"100%"},t.createElement("stop",{offset:"0%",style:{stopColor:this.startColor,stopOpacity:1}}),t.createElement("stop",{offset:"100%",style:{stopColor:this.endColor,stopOpacity:1}}))),t.createElement("circle",{cx:"50",cy:"50",r:"50",stroke:"url(#grad1)",strokeWidth:"4",fill:"transparent"}))),t.createElement("div",{className:l},t.createElement("div",{className:p},t.createElement("span",{style:this.fontColor},this.data.count),t.createElement("span",{className:d,style:this.fontColor},this.props.gpui.params.topDataUnit)),t.createElement("div",{className:p},t.createElement("span",{style:this.fontColor},this.data.amount),t.createElement("span",{className:d,style:this.fontColor},this.props.gpui.params.bottomDataUnit)))),t.createElement("div",{className:h},this.props.gpui.params.name)))},i([n.observable],r.prototype,"padding",void 0),i([n.observable],r.prototype,"startColor",void 0),i([n.observable],r.prototype,"endColor",void 0),i([n.observable],r.prototype,"data",void 0),i([n.computed],r.prototype,"fontColor",null),r=i([Q],r)}(t.Component)}));
