define(["gpui-style-inject","react","mobx"],(function(e,t,n){"use strict";function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function o(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var i=r(e),a=r(t),s=o(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 u(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 c(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())}))}i.default("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 f="index-module_main__k3On4",l="index-module_header__cH-pq",d="index-module_row__bM-mx",p="index-module_body__3oIhw",h="index-module_list__8WcNA";if(i.default(".index-module_main__k3On4 {\n  display: flex;\n  flex-direction: column;\n  width: 100%;\n  height: 100%; }\n  .index-module_main__k3On4 .index-module_header__cH-pq > :nth-child(n), .index-module_main__k3On4 .index-module_row__bM-mx > :nth-child(n) {\n    padding: 2vh; }\n  .index-module_main__k3On4 .index-module_header__cH-pq > :first-child, .index-module_main__k3On4 .index-module_row__bM-mx > :first-child {\n    width: 30%; }\n  .index-module_main__k3On4 .index-module_header__cH-pq > :nth-child(2), .index-module_main__k3On4 .index-module_row__bM-mx > :nth-child(2) {\n    width: 25%; }\n  .index-module_main__k3On4 .index-module_header__cH-pq > :last-child, .index-module_main__k3On4 .index-module_row__bM-mx > :last-child {\n    width: 45%; }\n  .index-module_main__k3On4 .index-module_header__cH-pq {\n    display: flex;\n    font-size: 3.5vh;\n    font-weight: 600;\n    color: #40A6ED;\n    background: #28356F; }\n  .index-module_main__k3On4 .index-module_body__3oIhw {\n    flex: 1;\n    position: relative;\n    display: flex;\n    flex-direction: column;\n    overflow: hidden; }\n  .index-module_main__k3On4 .index-module_list__8WcNA {\n    position: absolute;\n    top: 0;\n    left: 0;\n    display: flex;\n    flex-direction: column;\n    width: 100%;\n    font-size: 3.5vh;\n    color: #CDE0FF; }\n    .index-module_main__k3On4 .index-module_list__8WcNA .index-module_row__bM-mx {\n      display: flex;\n      width: 100%;\n      border-bottom: 1px solid #2B3873; }\n      .index-module_main__k3On4 .index-module_list__8WcNA .index-module_row__bM-mx :last-child {\n        display: flex;\n        flex-direction: column; }\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},m.apply(this,arguments)}function v(){var e=t.useState(0)[1];return t.useCallback((function(){e((function(e){return e+1}))}),[])}function y(e){return n.getDependencyTree(e)}var b,g=1e4,x=new Set;function w(){void 0===b&&(b=setTimeout(_,1e4))}function _(){b=void 0;var e=Date.now();x.forEach((function(t){var n=t.current;n&&e>=n.cleanAt&&(n.reaction.dispose(),t.current=null,x.delete(t))})),x.size>0&&w()}var E={};function O(e){return"observer"+e}function R(e,t,r){void 0===t&&(t="observed"),void 0===r&&(r=E);var o,i=(r.useForceUpdate||v)(),s=a.default.useRef(null);if(!s.current){var u=new n.Reaction(O(t),(function(){c.mounted?i():(u.dispose(),s.current=null)})),c=function(e){return{cleanAt:Date.now()+g,reaction:e}}(u);s.current=c,o=s,x.add(o),w()}var f,l,d=s.current.reaction;if(a.default.useDebugValue(d,y),a.default.useEffect((function(){var e;return e=s,x.delete(e),s.current?s.current.mounted=!0:(s.current={reaction:new n.Reaction(O(t),(function(){i()})),cleanAt:1/0},i()),function(){s.current.reaction.dispose(),s.current=null}}),[]),d.track((function(){try{f=e()}catch(e){l=e}})),l)throw l;return f}function j(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){C[e]||Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(o,e))})),r.displayName=s,r}var C={$$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 k(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:k,render:k},S.displayName="Observer";var N=0;var T={};function A(e){return T[e]||(T[e]=function(e){if("function"==typeof Symbol)return Symbol(e);var t="__$mobx-react "+e+" ("+N+")";return N++,t}(e)),T[e]}function P(e,t){if(U(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])||!U(e[n[o]],t[n[o]]))return!1;return!0}function U(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function q(e,t,n){Object.hasOwnProperty.call(e,t)?e[t]=n:Object.defineProperty(e,t,{enumerable:!1,configurable:!0,writable:!0,value:n})}var D=A("patchMixins"),B=A("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 M(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 H(e,t,n){var r=function(e,t){var n=e[D]=e[D]||{},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[B]){var i=e[t],a=$(e,t,o?o.enumerable:void 0,r,i);Object.defineProperty(e,t,a)}}function $(e,t,n,r,o){var i,a=M(o,r);return(i={})[B]=!0,i.get=function(){return a},i.set=function(o){if(this===e)a=M(o,r);else{var i=$(this,t,n,r,o);Object.defineProperty(this,t,i)}},i.configurable=!0,i.enumerable=n,i}var F=n.$mobx||"$mobx",I=A("isUnmounted"),z=A("skipRender"),W=A("isForcingUpdate");function X(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!==J)throw new Error("It is not allowed to use shouldComponentUpdate in observer based components.")}else n.shouldComponentUpdate=J;G(n,"props"),G(n,"state");var r=n.render;return n.render=function(){return V.call(this,r)},H(n,"componentWillUnmount",(function(){this.render[F]&&this.render[F].dispose(),this[I]=!0})),e}function V(e){var r=this;q(this,z,!1),q(this,W,!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[I])){var e=!0;try{q(r,W,!0),r[z]||t.Component.prototype.forceUpdate.call(r),e=!1}finally{q(r,W,!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[F]=u,this.render=c,c.call(this)}function J(e,t){return this.state!==t||!P(this.props,e)}function G(e,t){var r=A("reactProp_"+t+"_valueHolder"),o=A("reactProp_"+t+"_atomHolder");function i(){return this[o]||q(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[W]||P(this[r],e)?q(this,r,e):(q(this,r,e),q(this,z,!0),i.call(this).reportChanged(),q(this,z,!1))}})}var K="function"==typeof Symbol&&Symbol.for,Y=K?Symbol.for("react.forward_ref"):"function"==typeof t.forwardRef&&t.forwardRef((function(e){return null})).$$typeof,Q=K?Symbol.for("react.memo"):"function"==typeof t.memo&&t.memo((function(e){return null})).$$typeof;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,ee,te=(Z=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,d=e.headers;r.isFormData(l)&&delete d["Content-Type"];var p=new XMLHttpRequest;if(e.auth){var h=e.auth.username||"",m=e.auth.password||"";d.Authorization="Basic "+btoa(h+":"+m)}var v=a(e.baseURL,e.url);if(p.open(e.method.toUpperCase(),i(v,e.params,e.paramsSerializer),!0),p.timeout=e.timeout,p.onreadystatechange=function(){if(p&&4===p.readyState&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in p?s(p.getAllResponseHeaders()):null,r={data:e.responseType&&"text"!==e.responseType?p.response:p.responseText,status:p.status,statusText:p.statusText,headers:n,config:e,request:p};o(t,f,r),p=null}},p.onabort=function(){p&&(f(c("Request aborted",e,"ECONNABORTED",p)),p=null)},p.onerror=function(){f(c("Network Error",e,null,p)),p=null},p.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),f(c(t,e,"ECONNABORTED",p)),p=null},r.isStandardBrowserEnv()){var y=n(21),b=(e.withCredentials||u(v))&&e.xsrfCookieName?y.read(e.xsrfCookieName):void 0;b&&(d[e.xsrfHeaderName]=b)}if("setRequestHeader"in p&&r.forEach(d,(function(e,t){void 0===l&&"content-type"===t.toLowerCase()?delete d[t]:p.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(p.withCredentials=!!e.withCredentials),e.responseType)try{p.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&p.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&p.upload&&p.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then((function(e){p&&(p.abort(),f(e),p=null)})),void 0===l&&(l=null),p.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()},Z(ee={exports:{}},ee.exports),ee.exports);let ne=class extends s.Component{constructor(e){super(e),this.ref=s.createRef(),this.dataRef=s.createRef(),this.data=[],this.padding="14vh 4vh 4vh",this.renderList=()=>c(this,void 0,void 0,(function*(){const{base_url:e,set_id:t,deviceToken:n}=this.props.gpui.params;if(e&&t&&n){this.timer&&(clearTimeout(this.timer),this.timer=null),this.autoplayTimer&&(clearInterval(this.autoplayTimer),this.autoplayTimer=null);try{const{data:r}=yield te.get(`${e}/set/data/${t}`,{headers:{"X-Gini-Token":n}});this.data=r[0].data.map((e=>{const t={name:e.group["仪器名称"],times:Math.floor(100*e.data["使用时长"]/3600)/100,datas:[]};return e.group["推荐设备一位置"]&&t.datas.push({position:e.group["推荐设备一位置"]}),e.group["推荐设备二位置"]&&t.datas.push({position:e.group["推荐设备二位置"]}),e.group["推荐设备三位置"]&&t.datas.push({position:e.group["推荐设备三位置"]}),t})),this.autoplay()}catch(e){console.error("@components:wall-iharbour/analysis-of-startup-use: 组件渲染时发生错误",e)}this.props.gpui.params.interval>0&&(this.timer=setTimeout(this.renderList,this.props.gpui.params.interval))}})),this.autoplay=()=>{for(this.autoplayTimer&&(clearInterval(this.autoplayTimer),this.autoplayTimer=null);this.ref.current.hasChildNodes();)this.ref.current.removeChild(this.ref.current.firstChild);const e=this.dataRef.current.cloneNode(!0);e.style.display="block",e.className=h;const t=e.cloneNode(!0);t.style.top="0px",this.ref.current.appendChild(t),setTimeout((()=>{if(this.ref.current.scrollHeight>=this.ref.current.clientHeight){const n=t.clientHeight,r=e.cloneNode(!0);r.style.top=`${n}px`,this.ref.current.appendChild(r);const o=e.cloneNode(!0);o.style.top=2*n+"px",this.ref.current.appendChild(o);const i=e=>{let t=parseFloat(e.style.top);t>-n?t-=1:t=3*n+t-1,e.style.top=`${t}px`};setInterval((()=>{i(t),i(r),i(o)}),this.props.gpui.params.speed||30)}}))},n.reaction((()=>e.gpui.params.padding),(e=>{this.padding=e||"14vh 4vh 4vh"}),{fireImmediately:!0})}componentDidMount(){n.reaction((()=>({baseURL:this.props.gpui.params.base_url,setId:this.props.gpui.params.set_id,deviceToken:this.props.gpui.params.deviceToken,interval:this.props.gpui.params.interval})),(()=>{this.renderList()}),{fireImmediately:!0})}render(){return s.createElement("div",{className:"g__index",style:{padding:this.padding}},s.createElement("div",{className:f},s.createElement("div",{className:l},s.createElement("div",null,"仪器名称"),s.createElement("div",null,"平均使用时长"),s.createElement("div",null,"推荐仪器位置")),s.createElement("div",{ref:this.ref,className:p}),s.createElement("div",{ref:this.dataRef,style:{display:"none"}},this.data.map(((e,t)=>s.createElement("div",{key:t,className:d},s.createElement("div",null,e.name),s.createElement("div",null,e.times),s.createElement("div",null,e.datas.length>0?e.datas.map((e=>s.createElement("div",null,e.position))):"-")))))))}};return u([n.observable],ne.prototype,"data",void 0),u([n.observable],ne.prototype,"padding",void 0),ne=u([function(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'"),Q&&e.$$typeof===Q)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(Y&&e.$$typeof===Y){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)?X(e):j(e)}],ne),ne}));
