@deephaven/code-studio 0.8.2-beta.0 → 0.8.2-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +0,0 @@
1
- (this["webpackJsonp@deephaven/code-studio"]=this["webpackJsonp@deephaven/code-studio"]||[]).push([[2],{1118:function(e,t,n){},1119:function(e,t,n){},1120:function(e,t,n){},1121:function(e,t,n){},1160:function(e,t,n){},1161:function(e,t,n){},1162:function(e,t,n){},1163:function(e,t,n){},1164:function(e,t,n){},1165:function(e,t,n){},1166:function(e,t,n){},1167:function(e,t,n){},1168:function(e,t,n){},1169:function(e,t,n){},1170:function(e,t,n){},1171:function(e,t,n){},1172:function(e,t,n){},1173:function(e,t,n){},1226:function(e,t){},1228:function(e,t){},1259:function(e,t,n){},1260:function(e,t,n){},1261:function(e,t,n){},1262:function(e,t,n){},1263:function(e,t,n){},1264:function(e,t,n){},1268:function(e,t,n){},1269:function(e,t,n){},1270:function(e,t,n){},1271:function(e,t,n){},1272:function(e,t,n){},1273:function(e,t,n){},1274:function(e,t,n){},1275:function(e,t,n){},1276:function(e,t,n){},1277:function(e,t,n){},1278:function(e,t,n){},1279:function(e,t,n){},1280:function(e,t,n){},1281:function(e,t,n){},1282:function(e,t,n){},1283:function(e,t,n){},1284:function(e,t,n){},1285:function(e,t,n){},1286:function(e,t,n){},1287:function(e,t,n){},1288:function(e,t,n){},1289:function(e,t,n){},1290:function(e,t,n){},1291:function(e,t,n){},1292:function(e,t,n){},1293:function(e,t,n){},1294:function(e,t,n){},1295:function(e,t,n){},1296:function(e,t,n){},1297:function(e,t,n){},1298:function(e,t,n){},1299:function(e,t,n){},1300:function(e,t,n){},1301:function(e,t,n){},1302:function(e,t,n){},1303:function(e,t,n){},1304:function(e,t,n){},1305:function(e,t,n){},1306:function(e,t,n){},1408:function(e,t,n){},1409:function(e,t,n){},1410:function(e,t,n){},1411:function(e,t,n){},1412:function(e,t,n){},1413:function(e,t,n){},1415:function(e,t,n){},1416:function(e,t,n){},1417:function(e,t,n){},1418:function(e,t,n){},1419:function(e,t,n){},1442:function(e,t,n){var i={"./ExampleAppPlugin":[739,0],"./ExampleAppPlugin.jsx":[739,0],"./ExamplePlugin":[740,1],"./ExamplePlugin.jsx":[740,1]};function a(e){if(!n.o(i,e))return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}));var t=i[e],a=t[0];return n.e(t[1]).then((function(){return n(a)}))}a.keys=function(){return Object.keys(i)},a.id=1442,e.exports=a},1443:function(e,t){},1449:function(e,t){},1455:function(e,t,n){},1456:function(e,t,n){},1457:function(e,t,n){},1458:function(e,t,n){},1459:function(e,t,n){},1460:function(e,t,n){},1461:function(e,t,n){},1462:function(e,t,n){},1464:function(e,t,n){"use strict";n.r(t);var i=n(0),a=n.n(i),s=n(115),r=n.n(s),o=n(56),l=(n(751),n(752),n(72)),c=(n(1174),n(1176),n(1178),n(1472),n(1180),n(1181),n(1468),n(1185),n(1470),n(1197),n(130),n(1198),n(1473),n(1200),n(348),n(1465),n(1204),n(1205),n(405),n(1474),n(485),n(481),n(484),n(1206),n(1475),n(1208),n(229),n(1209),n(1210),n(1466),n(1212),n(1476),n(1214),n(1469),n(1467),n(1477),n(1471),n(1216),n(1478),n(1479),n(257),n(305),n(1218),n(399),n(1219),n(1220),n(1221),n(1222),n(304),n(1223),Object.freeze({SILENT:-1,ERROR:0,WARN:1,INFO:2,DEBUG:3,DEBUG2:4})),h=()=>{};var d=class{constructor(e,t){this.name=e,this.prefix=e?"[".concat(e,"]"):"",this.setLogLevel(t)}setLogLevel(e){this.level=e,this.error=0<=e?console.error.bind(console,this.prefix):h,this.warn=1<=e?console.warn.bind(console,this.prefix):h,this.log=2<=e?console.log.bind(console,this.prefix):h,this.info=this.log,this.debug=3<=e?console.debug.bind(console,this.prefix):h,this.debug2=4<=e?console.debug.bind(console,this.prefix):h}};var u,m=class extends d{constructor(){super(null,arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){var e,t="";try{t=Object({NODE_ENV:"production",PUBLIC_URL:".",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0,FAST_REFRESH:!0,REACT_APP_CORE_API_URL:"/jsapi",REACT_APP_CORE_API_NAME:"dh-core.js",REACT_APP_OPEN_API_NAME:"dh-internal.js",REACT_APP_ROUTER_BASE_NAME:"/ide/",REACT_APP_VERSION:"0.8.1",REACT_APP_NAME:"@deephaven/code-studio",REACT_APP_PLUGIN_URL:"/ide/plugins/",REACT_APP_NOTEBOOKS_URL:"/notebooks",REACT_APP_LAYOUTS_URL:"/layouts",REACT_APP_INTERNAL_PLUGINS:"",REACT_APP_ENABLE_LOG_PROXY:"true",REACT_APP_SUPPORT_LINK:"https://github.com/deephaven/web-client-ui/",REACT_APP_DOCS_LINK:"https://deephaven.io/core/docs/",REACT_APP_SESSION_LANGUAGES:"python=Python,groovy=Groovy,scala=Scala"}).DEEPHAVEN_LOG_LEVEL}catch(i){}if(t&&c[t])return c[t];var n=parseInt(null!==(e=t)&&void 0!==e?e:"",10);if(!Number.isNaN(n))return n;return 2}()),this.modules={}}module(e){return this.modules[e]||(this.modules[e]=new d(e,this.level)),this.modules[e]}setLogLevel(e){if(super.setLogLevel(e),this.modules)for(var t=Object.keys(this.modules),n=0;n<t.length;n+=1)this.modules[t[n]].setLogLevel(e)}},p=new m,g=n(392);function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f(e,t){return new CustomEvent(e,{detail:t})}!function(e){e.DEBUG="D",e.LOG="L",e.WARN="W",e.ERROR="E",e.UNCAUGHT_ERROR="U"}(u||(u={}));var b=class{constructor(){v(this,"isEnabled",!1),v(this,"debug",void 0),v(this,"log",void 0),v(this,"warn",void 0),v(this,"error",void 0),v(this,"eventTarget",void 0),v(this,"handleUncaughtError",(e=>{var t=[];e.error&&t.push(e.error),e.message&&t.push(e.message),this.eventTarget.dispatchEvent(f(u.UNCAUGHT_ERROR,t))})),this.debug=console.debug,this.log=console.log,this.warn=console.warn,this.error=console.error,this.eventTarget=new g.EventTarget}enable(){var e=this;this.isEnabled||(console.debug=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];e.eventTarget.dispatchEvent(f(u.DEBUG,n)),e.debug.apply(console,n)},console.log=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];e.eventTarget.dispatchEvent(f(u.LOG,n)),e.log.apply(console,n)},console.warn=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];e.eventTarget.dispatchEvent(f(u.WARN,n)),e.warn.apply(console,n)},console.error=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];e.eventTarget.dispatchEvent(f(u.ERROR,n)),e.error.apply(console,n)},window.addEventListener("error",this.handleUncaughtError),p.setLogLevel(p.level),this.isEnabled=!0)}disable(){this.isEnabled&&(console.debug=this.debug,console.log=this.log,console.warn=this.warn,console.error=this.error,window.removeEventListener("error",this.handleUncaughtError),p.setLogLevel(p.level),this.isEnabled=!1)}addEventListener(e,t){this.eventTarget.addEventListener(e,t)}removeEventListener(e,t){this.eventTarget.removeEventListener(e,t)}};function C(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class S{static formatMessages(e){return e.map((e=>{if("string"===typeof e)return e;var t="";try{t=JSON.stringify(e)}catch(n){t=e.toString()}return"{}"===t?e.toString():t})).join("\t")}static formatStack(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;if(""===e)return"";var n=e.split("\n").map((e=>e.trim()));switch(t){case u.ERROR:n=n.splice("Error"===e[0]?4:3);break;case u.UNCAUGHT_ERROR:n=n.splice("Error"===e[0]?3:2)}return n?"\t".concat(n.join("\n\t")):""}constructor(e){C(this,"history",void 0),C(this,"offset",void 0),C(this,"limit",void 0),C(this,"isEnabled",void 0),C(this,"proxy",void 0),this.history=[],this.offset=0,this.limit=1e4,this.isEnabled=!1,this.proxy=e,this.addHistory=this.addHistory.bind(this)}enable(){this.isEnabled||(this.proxy.addEventListener(u.DEBUG,this.addHistory),this.proxy.addEventListener(u.LOG,this.addHistory),this.proxy.addEventListener(u.WARN,this.addHistory),this.proxy.addEventListener(u.ERROR,this.addHistory),this.proxy.addEventListener(u.UNCAUGHT_ERROR,this.addHistory),this.isEnabled=!0)}disable(){this.isEnabled&&(this.proxy.removeEventListener(u.DEBUG,this.addHistory),this.proxy.removeEventListener(u.LOG,this.addHistory),this.proxy.removeEventListener(u.WARN,this.addHistory),this.proxy.removeEventListener(u.ERROR,this.addHistory),this.proxy.removeEventListener(u.UNCAUGHT_ERROR,this.addHistory),this.isEnabled=!1)}addHistory(e){var{type:t,detail:n}=e,i={type:t,messages:n,time:new Date};switch(t){case u.ERROR:case u.UNCAUGHT_ERROR:i.stack=Error().stack}this.history[this.offset%this.limit]=i,this.offset+=1}getHistory(){if(this.offset>this.limit){var e=this.offset%this.limit;this.history=this.history.slice(e).concat(this.history.slice(0,e)),this.offset=this.limit}return this.history}getFormattedHistory(){return this.getHistory().map((e=>"".concat(e.time.toISOString()," ").concat(e.type,"\t")+"".concat(S.formatMessages(e.messages))+(e.stack?"\n".concat(S.formatStack(e.stack,e.type)):""))).join("\n")}}var E=S,w=n(59),y=n.n(w),T={id:"python",conf:{comments:{lineComment:"#",blockComment:["'''","'''"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp("^\\s*(?:def|class|for|if|elif|else|while|try|with|finally|except|async).*?:\\s*$"),action:{indentAction:1}}],folding:{offSide:!0,markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},language:{keywords:["and","del","from","not","while","as","elif","global","or","with","assert","else","if","pass","yield","break","except","import","print","exec","in","raise","continue","finally","is","return","for","try",":","=","isinstance","__debug__"],storage:["class","def","async","lambda"],operators:["+","-","*","**","/","//","%","<<",">>","&","|","^","~","<",">","<=",">=","==","!=","<>","+=","-=","*=","/","//=","%=","&=","|=","^=",">>=","<<=","**="],brackets:[["(",")","delimiter.parenthesis"],["{","}","delimiter.curly"],["[","]","delimiter.square"]],symbols:/[=><!~&|+\-*/^%]+/,delimiters:/[;=.@:,`]/,escapes:/\\(?:[abfnrtv\\"'\n\r]|x[0-9A-Fa-f]{2}|[0-7]{3}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8}|N\{\w+\})/,rawpre:/(?:[rR]|ur|Ur|uR|UR|br|Br|bR|BR)/,strpre:/(?:[buBU])/,tokenizer:{root:[[/@strpre?("""|''')/,{token:"string.delim",bracket:"@open",next:"@mstring.$1"}],[/@strpre?"([^"\\]|\\.)*$/,"string.invalid"],[/@strpre?'([^'\\]|\\.)*$/,"string.invalid"],[/@strpre?(["])/,{token:"string.delim",bracket:"@open",next:"@sstring.$1",nextEmbedded:"deephavenDb"}],[/@strpre?(["'])/,{token:"string.delim",bracket:"@open",next:"@string.$1"}],[/@rawpre("""|''')/,{token:"string.delim",bracket:"@open",next:"@mrawstring.$1"}],[/@rawpre"([^"\\]|\\.)*$/,"string.invalid"],[/@rawpre'([^'\\]|\\.)*$/,"string.invalid"],[/@rawpre(["'])/,{token:"string.delim",bracket:"@open",next:"@rawstring.$1"}],[/__[\w$]*/,"predefined"],[/[a-z_$][\w$]*/,{cases:{"@keywords":"keyword","@storage":"storage","@default":"identifier"}}],[/[A-Z][\w]*/,{cases:{"~[A-Z0-9_]+":"constructor.identifier","@default":"namespace.identifier"}}],{include:"@whitespace"},[/[{}()[\]]/,"@brackets"],[/@symbols/,{cases:{"@keywords":"keyword","@operators":"operator","@default":""}}],[/\d*\.\d+([eE][-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+[lL]?/,"number.hex"],[/0[bB][0-1]+[lL]?/,"number.binary"],[/(0[oO][0-7]+|0[0-7]+)[lL]?/,"number.octal"],[/(0|[1-9]\d*)[lL]?/,"number"],[":",{token:"keyword",bracket:"@open"}],[/@delimiters/,{cases:{"@keywords":"keyword","@default":"delimiter"}}]],comment:[[/[^/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[/*]/,"comment"]],mstring:[{include:"@strcontent"},[/"""|'''/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["']/,"string"],[/./,"string.invalid"]],sstring:[{include:"@strcontent"},[/["]/,{token:"string.delim",bracket:"@close",next:"@pop",nextEmbedded:"@pop"}],[/./,"string.invalid"]],string:[{include:"@strcontent"},[/[']/,{token:"string.delim",bracket:"@close",next:"@pop"}],[/./,"string.invalid"]],strcontent:[[/[^\\"']+/,"string"],[/\\$/,"string.escape"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"]],mrawstring:[{include:"@rawstrcontent"},[/"""|'''/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["']/,"string"],[/./,"string.invalid"]],rawstring:[{include:"@rawstrcontent"},[/["']/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/./,"string.invalid"]],rawstrcontent:[[/[^\\"']+/,"string"],[/\\["']/,"string"],[/\\u[0-9A-Fa-f]{4}/,"string.escape"],[/\\/,"string"]],whitespace:[[/\s+/,"white"],[/(^#.*$)/,"comment"],[/'''/,"string","@endDocString"],[/"""/,"string","@endDblDocString"]],endDocString:[[/[^']+/,"string"],[/\\'/,"string"],[/'''/,"string","@popall"],[/'/,"string"]],endDblDocString:[[/[^"]+/,"string"],[/\\"/,"string"],[/"""/,"string","@popall"],[/"/,"string"]]}}},O={id:"groovy",conf:{comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp("^\\s*(?:def|class|for|if|elif|else|while|try|with|finally|except|async).*?:\\s*$"),action:{indentAction:1}}],folding:{offSide:!0,markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},language:{keywords:["and","del","from","not","while","as","elif","global","or","with","assert","else","if","pass","yield","break","except","import","print","println","class","exec","in","raise","continue","finally","is","return","def","for","lambda","try",":","=","isinstance","__debug__"],operators:["+","-","*","**","/","//","%","<<",">>","&","|","^","~","<",">","<=",">=","==","!=","<>","+=","-=","*=","/","//=","%=","&=","|=","^=",">>=","<<=","**="],brackets:[["(",")","delimiter.parenthesis"],["{","}","delimiter.curly"],["[","]","delimiter.square"]],symbols:/[=><!~&|+\-*/^%]+/,delimiters:/[;=.@:,`]/,escapes:/\\(?:[abfnrtv\\"'\n\r]|x[0-9A-Fa-f]{2}|[0-7]{3}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8}|N\{\w+\})/,rawpre:/(?:[rR]|ur|Ur|uR|UR|br|Br|bR|BR)/,strpre:/(?:[buBU])/,tokenizer:{root:[[/@strpre?("""|''')/,{token:"string.delim",bracket:"@open",next:"@mstring.$1"}],[/@strpre?"([^"\\]|\\.)*$/,"string.invalid"],[/@strpre?'([^'\\]|\\.)*$/,"string.invalid"],[/@strpre?(["])/,{token:"string.delim",bracket:"@open",next:"@sstring.$1",nextEmbedded:"deephavenDb"}],[/@strpre?(["'])/,{token:"string.delim",bracket:"@open",next:"@string.$1"}],[/@rawpre("""|''')/,{token:"string.delim",bracket:"@open",next:"@mrawstring.$1"}],[/@rawpre"([^"\\]|\\.)*$/,"string.invalid"],[/@rawpre'([^'\\]|\\.)*$/,"string.invalid"],[/@rawpre(["'])/,{token:"string.delim",bracket:"@open",next:"@rawstring.$1"}],[/__[\w$]*/,"predefined"],[/[a-z_$][\w$]*/,{cases:{"@keywords":"keyword","@default":"identifier"}}],[/[A-Z][\w]*/,{cases:{"~[A-Z0-9_]+":"constructor.identifier","@default":"namespace.identifier"}}],{include:"@whitespace"},[/[{}()[\]]/,"@brackets"],[/@symbols/,{cases:{"@keywords":"keyword","@operators":"operator","@default":""}}],[/\d*\.\d+([eE][-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+[lL]?/,"number.hex"],[/0[bB][0-1]+[lL]?/,"number.binary"],[/(0[oO][0-7]+|0[0-7]+)[lL]?/,"number.octal"],[/(0|[1-9]\d*)[lL]?/,"number"],[":",{token:"keyword",bracket:"@open"}],[/@delimiters/,{cases:{"@keywords":"keyword","@default":"delimiter"}}]],mstring:[{include:"@strcontent"},[/"""|'''/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["']/,"string"],[/./,"string.invalid"]],sstring:[{include:"@strcontent"},[/["]/,{token:"string.delim",bracket:"@close",next:"@pop",nextEmbedded:"@pop"}],[/./,"string.invalid"]],string:[{include:"@strcontent"},[/[']/,{token:"string.delim",bracket:"@close",next:"@pop"}],[/./,"string.invalid"]],strcontent:[[/[^\\"']+/,"string"],[/\\$/,"string.escape"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"]],mrawstring:[{include:"@rawstrcontent"},[/"""|'''/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["']/,"string"],[/./,"string.invalid"]],rawstring:[{include:"@rawstrcontent"},[/["']/,{cases:{"$#==$S2":{token:"string.delim",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/./,"string.invalid"]],rawstrcontent:[[/[^\\"']+/,"string"],[/\\["']/,"string"],[/\\u[0-9A-Fa-f]{4}/,"string.escape"],[/\\/,"string"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[/*]/,"comment"]],doccomment:[[/[^/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[/*]/,"comment.doc"]]}}},M={id:"scala",conf:{wordPattern:/(unary_[@~!#%^&*()\-=+\\|:<>/?]+)|([a-zA-Z_$][\w$]*?_=)|(`[^`]+`)|([a-zA-Z_$][\w$]*)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:<editor-fold\\b))"),end:new RegExp("^\\s*//\\s*(?:(?:#?endregion\\b)|(?:</editor-fold>))")}}},language:{keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],softKeywords:["as","export","extension","end","derives","on"],constants:["true","false","null","this","super"],modifiers:["abstract","final","implicit","lazy","override","private","protected","sealed"],softModifiers:["inline","opaque","open","transparent","using"],name:/(?:[a-z_$][\w$]*|`[^`]+`)/,type:/(?:[A-Z][\w$]*)/,symbols:/[=><!~?:&|+\-*/^\\%@#]+/,digits:/\d+(_+\d+)*/,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,escapes:/\\(?:[btnfr\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,fstring_conv:/[bBhHsScCdoxXeEfgGaAt]|[Tn](?:[HIklMSLNpzZsQ]|[BbhAaCYyjmde]|[RTrDFC])/,tokenizer:{root:[[/\braw"""/,{token:"string.quote",bracket:"@open",next:"@rawstringt"}],[/\braw"/,{token:"string.quote",bracket:"@open",next:"@rawstring"}],[/\bs"""/,{token:"string.quote",bracket:"@open",next:"@sstringt"}],[/\bs"/,{token:"string.quote",bracket:"@open",next:"@sstring"}],[/\bf""""/,{token:"string.quote",bracket:"@open",next:"@fstringt"}],[/\bf"/,{token:"string.quote",bracket:"@open",next:"@fstring"}],[/"""/,{token:"string.quote",bracket:"@open",next:"@stringt"}],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],[/(@digits)[eE]([-+]?(@digits))?[fFdD]?/,"number.float","@allowMethod"],[/(@digits)\.(@digits)([eE][-+]?(@digits))?[fFdD]?/,"number.float","@allowMethod"],[/0[xX](@hexdigits)[Ll]?/,"number.hex","@allowMethod"],[/(@digits)[fFdD]/,"number.float","@allowMethod"],[/(@digits)[lL]?/,"number","@allowMethod"],[/\b_\*/,"key"],[/\b(_)\b/,"keyword","@allowMethod"],[/\bimport\b/,"keyword","@import"],[/\b(case)([ \t]+)(class)\b/,["keyword.modifier","white","keyword"]],[/\bcase\b/,"keyword","@case"],[/\bva[lr]\b/,"keyword","@vardef"],[/\b(def)([ \t]+)((?:unary_)?@symbols|@name(?:_=)|@name)/,["keyword","white","identifier"]],[/@name(?=[ \t]*:(?!:))/,"variable"],[/(\.)(@name|@symbols)/,["operator",{token:"@rematch",next:"@allowMethod"}]],[/([{(])(\s*)(@name(?=\s*=>))/,["@brackets","white","variable"]],[/@name/,{cases:{"@keywords":"keyword","@softKeywords":"keyword","@modifiers":"keyword.modifier","@softModifiers":"keyword.modifier","@constants":{token:"constant",next:"@allowMethod"},"@default":{token:"identifier",next:"@allowMethod"}}}],[/@type/,"type","@allowMethod"],{include:"@whitespace"},[/@[a-zA-Z_$][\w$]*(?:\.[a-zA-Z_$][\w$]*)*/,"annotation"],[/[{(]/,"@brackets"],[/[})]/,"@brackets","@allowMethod"],[/\[/,"operator.square"],[/](?!\s*(?:va[rl]|def|type)\b)/,"operator.square","@allowMethod"],[/]/,"operator.square"],[/([=-]>|<-|>:|<:|:>|<%)(?=[\s\w()[\]{},."'`])/,"keyword"],[/@symbols/,"operator"],[/[;,.]/,"delimiter"],[/'[a-zA-Z$][\w$]*(?!')/,"attribute.name"],[/'[^\\']'/,"string","@allowMethod"],[/(')(@escapes)(')/,["string","string.escape",{token:"string",next:"@allowMethod"}]],[/'/,"string.invalid"]],import:[[/;/,"delimiter","@pop"],[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/@name|@type/,"type"],[/[(){}]/,"@brackets"],[/[[\]]/,"operator.square"],[/[.,]/,"delimiter"]],allowMethod:[[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/(?==>[\s\w([{])/,"keyword","@pop"],[/(@name|@symbols)(?=[ \t]*[[({"'`]|[ \t]+(?:[+-]?\.?\d|\w))/,{cases:{"@keywords":{token:"keyword",next:"@pop"},"->|<-|>:|<:|<%":{token:"keyword",next:"@pop"},"@default":{token:"@rematch",next:"@pop"}}}],["","","@pop"]],comment:[[/[^/*]+/,"comment"],[/\/\*/,"comment","@push"],[/\*\//,"comment","@pop"],[/[/*]/,"comment"]],case:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword","@allowMethod"],[/\bif\b|=>/,"keyword","@pop"],[/`[^`]+`/,"identifier","@allowMethod"],[/@name/,"variable","@allowMethod"],[/:::?|\||@(?![a-z_$])/,"keyword"],{include:"@root"}],vardef:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword"],[/@name/,"variable"],[/:::?|\||@(?![a-z_$])/,"keyword"],[/=|:(?!:)/,"operator","@pop"],[/$/,"white","@pop"],{include:"@root"}],string:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],stringt:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],fstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],fstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],sstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],sstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],interp:[[/{/,"operator","@push"],[/}/,"operator","@pop"],{include:"@root"}],rawstring:[[/[^"]/,"string"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],rawstringt:[[/[^"]/,"string"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}},N={id:"deephavenDb",conf:{comments:{lineComment:"#",blockComment:["'''","'''"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp("^\\s*(?:def|class|for|if|elif|else|while|try|with|finally|except|async).*?:\\s*$"),action:{indentAction:1}}],folding:{offSide:!0,markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},language:{tokenPostfix:".js",keywords:["boolean","break","byte","case","catch","char","class","const","continue","debugger","default","delete","do","double","else","enum","export","extends","false","final","finally","float","for","function","goto","if","implements","import","in","instanceof","int","interface","long","native","new","null","package","private","protected","public","return","short","static","super","switch","synchronized","this","throw","throws","transient","true","try","typeof","var","void","volatile","while","with"],builtins:["define","require","window","document","undefined"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],brackets:[["(",")","bracket.parenthesis"],["{","}","bracket.curly"],["[","]","bracket.square"]],symbols:/[~!@#%\^&*-+=|\\:`<>.?\/]+/,escapes:/\\(?:[btnfr\\"']|[0-7][0-7]?|[0-3][0-7]{2})/,exponent:/[eE][\-+]?[0-9]+/,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,tokenizer:{root:[[/([a-zA-Z_\$][\w\$]*)(\s*)(:?)/,{cases:{"$1@keywords":["keyword","white","delimiter"],$3:["key.identifier","white","delimiter"],"$1@builtins":["predefined.identifier","white","delimiter"],"@default":["identifier","white","delimiter"]}}],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/)/,{token:"regexp.slash",bracket:"@open",next:"@regexp"}],[/[{}()\[\]]/,"@brackets"],[/[;,.]/,"delimiter"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}],[/\d+\.\d*(@exponent)?/,"number.float"],[/\.\d+(@exponent)?/,"number.float"],[/\d+@exponent/,"number.float"],[/0[xX][\da-fA-F]+/,"number.hex"],[/0[0-7]+/,"number.octal"],[/\d+/,"number"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string",'@string."'],[/'/,"string","@string.'"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment.invalid"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/["']/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["@brackets.regexp.escape.control","regexp.escape.control","@brackets.regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["@brackets.regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["@brackets.regexp.escape.control","regexp.escape.control"]],[/[()]/,"@brackets.regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],["/",{token:"regexp.slash",bracket:"@close"},"@pop"]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,"@brackets.regexp.escape.control","@pop"]]}}},D={id:"log",conf:{},language:{tokenizer:{root:[[/ FATAL[\s\S]*/,{token:"error",next:"@error"}],[/ ERROR[\s\S]*/,{token:"error",next:"@error"}],[/ STDERR[\s\S]*/,{token:"error",next:"@error"}],[/ STDOUT.*/,{token:"stdout",next:"@stdout"}],[/ INFO[\s\S]*/,{token:"info",next:"@info"}],[/ WARN.*/,{token:"warn",next:"@warn"}],[/ TRACE[\s\S]*/,{token:"trace",next:"@trace"}],[/ DEBUG[.\s\S]*/,{token:"debug",next:"@debug"}],[/^\d{2}:\d{2}:\d{2}.\d{3}/,"date"]],error:[{include:"@body"}],info:[{include:"@body"}],warn:[{include:"@body"}],stdout:[{include:"@body"}],trace:[{include:"@body"}],debug:[{include:"@body"}],body:[[/^\d{2}:\d{2}:\d{2}.\d{3}/,{token:"date",next:"@pop"}],[/[\s\S]*/,{token:"$S0"}]]}}},x=p.module("MonacoUtils");class R{static init(){x.debug("Initializing Monaco...");var{registerLanguages:e,removeHashtag:t}=R,n=[{token:"",foreground:t(y.a.foreground)},{token:"string",foreground:t(y.a.string)},{token:"string.delim",foreground:t(y.a["string-delim"])},{token:"keyword",foreground:t(y.a.keyword)},{token:"identifier.js",foreground:t(y.a["identifier-js"])},{token:"delimiter",foreground:t(y.a.delimiter)},{token:"comment",foreground:t(y.a.comment)},{token:"number",foreground:t(y.a.number)},{token:"storage",foreground:t(y.a.storage)},{token:"identifier",foreground:t(y.a.identifier)},{token:"namespace.identifier",foreground:t(y.a["namespace-identifier"])},{token:"operator",foreground:t(y.a.operator)},{token:"predefined",foreground:t(y.a.predefined)},{token:"error.log",foreground:y.a["log-error"].substring(1)},{token:"warn.log",foreground:t(y.a["log-warn"])},{token:"info.log",foreground:t(y.a["log-info"])},{token:"stdout.log",foreground:t(y.a["log-stdout"])},{token:"trace.log",foreground:t(y.a["log-trace"])},{token:"debug.log",foreground:t(y.a["log-debug"])},{token:"date.log",foreground:t(y.a["log-date"])}],i={errorForeground:y.a["error-foreground"],"inputOption.activeBorder":y.a["input-option-active-border"],"editor.background":y.a.background,"editor.foreground":y.a.foreground,"editor.lineHighlightBackground":y.a["editor-line-highlight-bg"],"editorLineNumber.foreground":y.a["editor-line-number-foreground"],"editor.selectionBackground":y.a["editor-selection-background"],"editor.findMatchBackground":y.a["editor-find-match-background"],"editor.findMatchHighlightBackground":y.a["editor-find-match-highlight-background"],"editorSuggestWidget.background":y.a["editor-suggest-widget-background"],"editorSuggestWidget.border":y.a["editor-suggest-widget-border"],"editorSuggestWidget.foreground":y.a["editor-suggest-widget-foreground"],"editorSuggestWidget.selectedBackground":y.a["editor-suggest-widget-selected-background"],"editorSuggestWidget.highlightForeground":y.a["editor-suggest-widget-highlightForeground"],"list.hoverBackground":y.a["list-hover-background"],"dropdown.background":y.a["context-menu-background"],"dropdown.foreground":y.a["context-menu-foreground"],"menu.selectionBackground":y.a["menu-selection-background"],"list.focusBackground":y.a["menu-selection-background"],"editorWidget.background":y.a["editor-widget-background"],"inputOption.activeBackground":y.a["input-option-active-background"],"inputOption.activeForeground":y.a["input-option-active-foreground"],focusBorder:y.a["focus-border"],"input.background":y.a["input-background"],"input.foreground":y.a["input-foreground"],"input.border":y.a["input-border"]};l.c.defineTheme("dh-dark",{base:"vs-dark",inherit:!0,rules:n,colors:i}),x.debug2("monaco theme: ",y.a),l.c.setTheme("dh-dark"),e([N,T,O,D,M]),x.debug("Monaco initialized.")}static removeHashtag(e){return e.substring(1)}static registerLanguages(e){var t=e.map((e=>{var{id:t}=e;return t}));l.d.getLanguages().filter((e=>{var{id:n}=e;return t.includes(n)})).forEach((e=>{var t=e;x.debug2("Overriding default language loader:",t.id),t.loader=()=>({then:()=>{}})})),e.forEach((e=>{R.registerLanguage(e)}))}static registerLanguage(e){x.debug2("Registering language: ",e.id),l.d.register(e),l.d.onLanguage(e.id,(()=>{l.d.setLanguageConfiguration(e.id,e.conf),l.d.setMonarchTokensProvider(e.id,e.language)}))}static setEOL(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.c.EndOfLineSequence.LF;e.getModel().setEOL(t)}static openDocument(e,t){var n=e.getModel(),i={textDocument:{uri:"".concat(n.uri),languageId:n.getModeId(),version:n.getVersionId(),text:n.getValue()}};return x.debug2("didOpenDocumentParams: ",i),t.openDocument(i),e.onDidChangeModelContent((e=>{for(var{changes:i,versionId:a}=e,s=[],r=0;r<i.length;r+=1){var o=i[r],{range:l,rangeLength:c,text:h}=o,d={range:{start:{line:l.startLineNumber-1,character:l.startColumn-1},end:{line:l.endLineNumber-1,character:l.endColumn-1}},rangeLength:c,text:h};s.push(d)}if(s.length>0){var u={textDocument:{version:a,uri:"".concat(n.uri)},contentChanges:s};x.debug2("didChangeDocumentParams",u),t.changeDocument(u)}}))}static closeDocument(e,t){var n=e.getModel(),i={textDocument:{uri:"".concat(n.uri)}};t.closeDocument(i)}static registerPasteHandler(e){e.onDidPaste((t=>{var n=/\u201c|\u201d/g,i=/\u200b/g,a=e.getModel(),s=a.getValueInRange(t.range);(n.test(s)||i.test(s))&&a.applyEdits([{range:t.range,text:s.replace(n,'"').replace(i,"")}])}))}static isMacPlatform(){var{platform:e}=window.navigator;return e.startsWith("Mac")}static removeConflictingKeybindings(e){try{[{windows:"ctrl+D",mac:"meta+D"},{windows:"ctrl+H"}].forEach((t=>R.removeKeybinding(e,R.isMacPlatform()?t.mac:t.windows)))}catch(t){x.error(t)}}static removeKeybinding(e,t){if(t){var n=e._standaloneKeybindingService._getResolver()._map.get(t);n?n.forEach((n=>{x.debug2("Removing Monaco keybinding ".concat(t," for ").concat(n.command)),e._standaloneKeybindingService.addDynamicKeybinding("-".concat(n.command),null,(()=>{}))})):x.warn("Did not find any keybindings to remove for ".concat(t))}}}var I=R,L=e=>e.user,F=e=>e.storage,k=e=>F(e).commandHistoryStorage,A=e=>F(e).fileStorage,P=e=>e.workspace,_=e=>P(e).data.settings,H=e=>_(e).defaultDateTimeFormat,j=e=>_(e).timeZone,V=e=>_(e).showTimeZone,z=e=>_(e).showTSeparator,U=e=>e.activeTool,B="SET_ACTIVE_TOOL",W="SET_COMMAND_HISTORY_STORAGE",G="SET_FILE_STORAGE",q="SET_USER",K="SET_WORKSPACE",Y="SET_WORKSPACE_STORAGE";function X(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?X(Object(n),!0).forEach((function(t){$(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):X(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function $(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Q=e=>({type:K,payload:e}),J=e=>(t,n)=>{var{workspace:i}=n(),{data:a}=i;return t((e=>(t,n)=>{t(Q(e));var{storage:i}=n(),{workspaceStorage:a}=i;return a.save(e)})(Z(Z({},i),{},{data:Z(Z({},a),e)})))},ee=e=>t=>t(J({settings:e})),te=e=>({type:B,payload:e});function ne(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function ie(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ne(Object(n),!0).forEach((function(t){ae(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ne(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ae(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function se(e,t){return function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t,i=arguments.length>1?arguments[1]:void 0;if(i.type===e){var a=i.payload;return null==a?null:ie(null!=n?ie({},n):{},a)}return n}}var re=n(120),oe=n.n(re);function le(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?le(Object(n),!0).forEach((function(t){he(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):le(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function he(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function de(e,t){return function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t,i=arguments.length>1?arguments[1]:void 0;return i.type===e?i.payload:n}}var ue=de(B,null),me=n(190),pe=de(W,null),ge=de(G,null),ve=de(Y,null),fe={activeTool:ue,storage:Object(me.c)({commandHistoryStorage:pe,fileStorage:ge,workspaceStorage:ve}),user:se(q,null),workspace:se(K,null)};function be(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?be(Object(n),!0).forEach((function(t){Se(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):be(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Se(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ee=new class{constructor(){Se(this,"reducers",{}),Se(this,"listener",null)}register(e,t){var n;this.reducers=Ce(Ce({},this.reducers),{},{[e]:t}),null===(n=this.listener)||void 0===n||n.call(this,this.reducers)}setListener(e){this.listener=e}},we=n(716),ye=p.module("redux-logger"),Te=e=>t=>n=>{ye.debug("dispatching",n);var i=t(n);return ye.debug("next state",e.getState()),i},Oe=p.module("redux-crashReporter"),Me=[Te,e=>t=>n=>{try{return t(n)}catch(i){throw Oe.error("Error executing",n," with state ",e.getState(),":",i),i}},we.a];Object.entries(fe).map((e=>{var[t,n]=e;return Ee.register(t,n)}));var Ne=window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__||me.d,De=Object(me.e)(Object(me.c)(Ee.reducers),Ne(Object(me.a)(...Me)));Ee.setListener((e=>{De.replaceReducer(Object(me.c)(e))}));var xe,Re,Ie,Le=De,Fe=n(735),ke=n(134);function Ae(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}class Pe{static disableAllActions(){Pe.actionsDisabled=!0}static enableAllActions(){Pe.actionsDisabled=!1}static isContextActionEvent(e){return Array.isArray(e.contextActions)}static compareActions(e,t){return e.group!==t.group?(e.group||0)>(t.group||0)?1:-1:e.order!==t.order?(e.order||0)>(t.order||0)?1:-1:e.title!==t.title?(e.title||"")>(t.title||"")?1:-1:e!==t?e>t?1:-1:0}static sortActions(e){if(!e||!Array.isArray(e))return[];var t=e.slice();return t.sort(Pe.compareActions),t}static isMacPlatform(){var{platform:e}=window.navigator;return e.startsWith("Mac")}static getModifierKey(){return Pe.isMacPlatform()?"metaKey":"ctrlKey"}static isModifierKeyDown(e){return e[Pe.getModifierKey()]}static copyToClipboard(e){return(t=function*(){try{var t=yield navigator.permissions.query({name:"clipboard-write"});if("granted"!==t.state&&"prompt"!==t.state)throw new Error("Invalid permissions for clipboard-write")}catch(n){return void Pe.copyToClipboardExecCommand(e)}yield navigator.clipboard.writeText(e)},function(){var e=this,n=arguments;return new Promise((function(i,a){var s=t.apply(e,n);function r(e){Ae(s,i,a,r,o,"next",e)}function o(e){Ae(s,i,a,r,o,"throw",e)}r(void 0)}))})();var t}static copyToClipboardExecCommand(e){var t=document.activeElement,n=document.createElement("textarea");if(n.value=e,document.body.appendChild(n),n.focus(),n.select(),!document.execCommand("copy"))throw new Error("Unable to execute copy command");document.body.removeChild(n),t instanceof HTMLElement&&t.focus()}static getMenuItems(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=[],i=e;Array.isArray(i)||(i=[i]);for(var a=0;a<i.length;a+=1){var s=i[a],r=void 0;null!=(r="function"===typeof s?s():s)&&(r instanceof Promise?t&&n.push(r):Array.isArray(r)?n=n.concat(r):n.push(r))}return n=n.filter((e=>e.title||e.then||e.menuElement))}static getNextMenuItem(e,t,n){var i=e;i<0&&t<0&&(i=n.length);for(var a=1;a<n.length+1;a+=1){var s=(i+t*a+n.length)%n.length,r=n[s];if(!(r instanceof Promise)&&!0!==r.disabled)return s}return e}}Ie=!1,(Re="actionsDisabled")in(xe=Pe)?Object.defineProperty(xe,Re,{value:Ie,enumerable:!0,configurable:!0,writable:!0}):xe[Re]=Ie;var _e,He,je=Pe;function Ve(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.CTRL="MODIFIER_CTRL",e.CMD="MODIFIER_CMD",e.ALT="MODIFIER_ALT",e.OPTION="MODIFIER_OPTION",e.SHIFT="MODIFIER_SHIFT"}(_e||(_e={})),function(e){e.A="A",e.B="B",e.C="C",e.D="D",e.E="E",e.F="F",e.G="G",e.H="H",e.I="I",e.J="J",e.K="K",e.L="L",e.M="M",e.N="N",e.O="O",e.P="P",e.Q="Q",e.R="R",e.S="S",e.T="T",e.U="U",e.V="V",e.W="W",e.X="X",e.Y="Y",e.Z="Z",e.ZERO="0",e.ONE="1",e.TWO="2",e.THREE="3",e.FOUR="4",e.FIVE="5",e.SIX="6",e.SEVEN="7",e.EIGHT="8",e.NINE="9",e.BACKSPACE="Backspace",e.ESCAPE="Escape",e.ENTER="Enter",e.DELETE="Delete",e.SLASH="/",e.QUESTION_MARK="?",e.BACKSLASH="\\",e.PIPE="|",e.MINUS="-",e.UNDERSCORE="_",e.EQUALS="=",e.PLUS="+",e.BACKTICK="`",e.TILDE="~",e.COMMA=",",e.LEFT_CHEVRON="<",e.PERIOD=".",e.RIGHT_CHEVRON=">",e.SEMICOLON=";",e.COLON=":",e.SINGLE_QUOTE="'",e.DOUBLE_QUOTE='"',e.LEFT_BRACKET="[",e.RIGHT_BRACKET="]",e.LEFT_CURLY="{",e.RIGHT_CURLY="}",e.F1="F1",e.F2="F2",e.F3="F3",e.F4="F4",e.F5="F5",e.F6="F6",e.F7="F7",e.F8="F8",e.F9="F9",e.F10="F10",e.F11="F11",e.F12="F12"}(He||(He={}));class ze{static isAllowedKey(e){return Object.values(He).includes(e)}static isValidKeyState(e){return null===e.keyValue||ze.isAllowedKey(e.keyValue)&&(ze.isMacPlatform||!e.metaKey)&&(e.altKey||e.ctrlKey||e.metaKey||e.shiftKey||e.keyValue===He.ENTER||e.keyValue===He.DELETE)}static createKeyState(e){var t={altKey:!1,ctrlKey:!1,metaKey:!1,shiftKey:!1,keyValue:e[e.length-1]};return e.forEach((e=>{switch(e){case _e.CTRL:t.ctrlKey=!0;break;case _e.ALT:case _e.OPTION:t.altKey=!0;break;case _e.CMD:t.metaKey=!0;break;case _e.SHIFT:t.shiftKey=!0}})),t}static getKeyStateFromEvent(e){var{key:t,keyCode:n}=e;return{keyValue:"Shift"===t||"Meta"===t||"Control"===t||"Alt"===t?"":!ze.isAllowedKey(t)&&ze.isAllowedKey(String.fromCharCode(n))?String.fromCharCode(n):t,altKey:e.altKey,ctrlKey:e.ctrlKey,metaKey:e.metaKey,shiftKey:e.shiftKey}}static getWindowsDisplayText(e){var t="";return e.ctrlKey&&(t+="Ctrl+"),e.altKey&&(t+="Alt+"),e.shiftKey&&(t+="Shift+"),e.keyValue===He.ESCAPE?t+="Esc":null!==e.keyValue&&(t+=e.keyValue),t}static getMacDisplayText(e){var t="";switch(e.ctrlKey&&(t+="\u2303"),e.altKey&&(t+="\u2325"),e.shiftKey&&(t+="\u21e7"),e.metaKey&&(t+="\u2318"),e.keyValue){case He.ENTER:t+="\u23ce";break;case He.ESCAPE:t+="\u238b";break;case He.BACKSPACE:t+="\u232b";break;case He.DELETE:t+="\u2326";break;case null:break;default:t+=e.keyValue}return t}static doKeyStatesMatch(e,t){var n,i;return(null===(n=e.keyValue)||void 0===n?void 0:n.toUpperCase())===(null===(i=t.keyValue)||void 0===i?void 0:i.toUpperCase())&&e.altKey===t.altKey&&e.ctrlKey===t.ctrlKey&&e.metaKey===t.metaKey&&e.shiftKey===t.shiftKey}static getDisplayText(e){return null===e.keyValue?"":ze.isMacPlatform?ze.getMacDisplayText(e):ze.getWindowsDisplayText(e)}constructor(e){var{id:t,shortcut:n,macShortcut:i,isEditable:a=!0,name:s,tooltip:r}=e;Ve(this,"id",void 0),Ve(this,"name",void 0),Ve(this,"tooltip",void 0),Ve(this,"isEditable",void 0),Ve(this,"defaultKeyState",void 0),Ve(this,"keyState",void 0),this.id=t,this.name=s,this.tooltip=r,this.isEditable=a;var o=ze.isMacPlatform?i:n;this.defaultKeyState=ze.createKeyState(o),this.keyState=this.defaultKeyState}getDisplayText(){return ze.getDisplayText(this.keyState)}getKeyState(){return this.keyState}setKeyState(e){ze.isValidKeyState(e)&&(this.keyState=e)}getDefaultKeyState(){return this.defaultKeyState}isDefault(){return ze.doKeyStatesMatch(this.getDefaultKeyState(),this.getKeyState())}setToNull(){this.setKeyState(ze.NULL_KEY_STATE)}isNull(){return ze.doKeyStatesMatch(this.keyState,ze.NULL_KEY_STATE)}setToDefault(){this.setKeyState(this.defaultKeyState)}matchesKeyState(e){return ze.doKeyStatesMatch(e,this.keyState)}matchesEvent(e){return this.matchesKeyState(ze.getKeyStateFromEvent(e))}}function Ue(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Ve(ze,"NULL_KEY_STATE",{metaKey:!1,shiftKey:!1,altKey:!1,ctrlKey:!1,keyValue:null}),Ve(ze,"isMacPlatform",je.isMacPlatform());class Be{static createAndAdd(e){var t=new ze(e);return Be.add(t),t}static add(e){if(Be.shortcutMap.has(e.id))throw new Error("Skipping attempt to add duplicate shortcut ID to registry: ".concat(e.id));var t,n=e.id.split(".")[0];(Be.shortcutMap.set(e.id,e),Be.shortcutsByCategory.has(n))?null===(t=Be.shortcutsByCategory.get(n))||void 0===t||t.push(e):Be.shortcutsByCategory.set(n,[e])}static get(e){return Be.shortcutMap.get(e)}static getConflictingShortcuts(e){return Array.from(Be.shortcutMap.values()).filter((t=>!t.isNull()&&t.matchesKeyState(e)))}}Ue(Be,"shortcutMap",new Map),Ue(Be,"shortcutsByCategory",new Map);var We=n(87),Ge=n(10),qe=n.n(Ge),Ke=n(21),Ye={prefix:"vs",iconName:"arrow-left",icon:[512,512,[],"f000","M224 98.976l-160 160V281.6l160 160 22.624 -22.624 -132.672 -132.704H448v-32H113.92L246.656 121.6 224 98.976z"]},Xe={prefix:"vs",iconName:"arrow-small-down",icon:[512,512,[],"f000","M342.4 276.48l-80 80h-22.4L160 276.48l22.4 -22.72 52.8 52.48V128h32v178.24L320 253.44l22.4 23.04z"]},Ze={prefix:"vs",iconName:"arrow-small-up",icon:[512,512,[],"f000","M160 208L240 128h22.4l80 80 -22.4 22.72 -52.8 -52.48v178.24h-32V178.24L182.4 231.04 160 208z"]},$e={prefix:"vs",iconName:"arrow-up",icon:[512,512,[],"f000","M443.328 224l-160 -160h-22.624l-160 160 22.624 22.624L256 113.952V448h32V113.92l132.672 132.704 22.656 -22.624z"]},Qe={prefix:"vs",iconName:"bell",icon:[512,512,[],"f000","M428.064 338.336a244.16 244.16 0 0 1 -12.256 -76.16V198.24a163.68 163.68 0 0 0 -40.576 -110.272 164.416 164.416 0 0 0 -103.744 -55.104c-22.208 -2.304 -44.8 0 -66.24 7.264 -21.44 6.88 -40.96 18.368 -57.408 33.696a157.536 157.536 0 0 0 -38.656 53.6 162.144 162.144 0 0 0 -13.792 64.704v70.4a243.52 243.52 0 0 1 -12.256 75.84L64 394.976l15.328 21.056h112.16c0 16.832 6.88 33.28 18.752 45.184 11.84 11.84 28.32 18.752 45.184 18.752 16.832 0 33.28 -6.88 45.152 -18.752s18.784 -28.352 18.784 -45.184h112.16l15.296 -21.056 -18.752 -56.64zm-150.08 100.704a31.904 31.904 0 0 1 -22.56 9.568 31.904 31.904 0 0 1 -22.592 -9.6 31.904 31.904 0 0 1 -9.6 -22.56h63.968a30.048 30.048 0 0 1 -9.184 22.592zm-176.48 -54.72l11.872 -35.648a276.256 276.256 0 0 0 14.176 -86.112V192.128c0 -18.016 3.84 -35.616 11.104 -51.712 7.264 -16.448 17.6 -31.008 31.008 -42.88 13.408 -12.224 29.12 -21.44 45.952 -26.784 17.216 -5.76 35.2 -7.68 52.8 -5.76a132.704 132.704 0 0 1 83.104 44.8 132.256 132.256 0 0 1 32.128 88.832v64.32c0 29.088 4.608 58.176 14.176 86.112l11.872 35.616h-308.16v-0.384z"]},Je={prefix:"vs",iconName:"check",icon:[512,512,[],"f000","M461.792 106.336l-271.04 320 -25.28 -1.152 -107.2 -152.64 26.176 -18.368 95.296 135.68 257.632 -304.192 24.448 20.672z"]},et={prefix:"vs",iconName:"chevron-down",icon:[512,512,[],"f000","M255.232 322.304l139.424 -139.424 19.84 19.776L265.088 352h-19.776L96 202.656l19.808 -19.776 139.424 139.424z"]},tt={prefix:"vs",iconName:"chevron-left",icon:[512,512,[],"f000","M189.696 255.232l139.424 139.424 -19.776 19.84L160 265.088v-19.776L309.344 96l19.776 19.808 -139.424 139.424z"]},nt={prefix:"vs",iconName:"chevron-right",icon:[512,512,[],"f000","M322.304 256.768L182.88 117.344l19.776 -19.84L352 246.912v19.776L202.656 416l-19.776 -19.808 139.424 -139.424z"]},it={prefix:"vs",iconName:"chevron-up",icon:[512,512,[],"f000","M256.768 189.696l-139.424 139.424 -19.84 -19.776L246.912 160h19.776L416 309.344l-19.808 19.776 -139.424 -139.424z"]},at={prefix:"vs",iconName:"circle-large-filled",icon:[512,512,[],"f000","M256 32a217.6 217.6 0 0 1 59.52 8.096 220.768 220.768 0 0 1 98.656 57.76 220.896 220.896 0 0 1 57.728 98.656C477.312 215.616 480 235.424 480 256s-2.688 40.384 -8.096 59.52a220.8 220.8 0 0 1 -22.528 53.568 229.024 229.024 0 0 1 -80.512 80.288 222.912 222.912 0 0 1 -53.376 22.72A223.488 223.488 0 0 1 256 480a223.488 223.488 0 0 1 -59.52 -7.872 227.136 227.136 0 0 1 -53.568 -22.752 233.6 233.6 0 0 1 -45.28 -35.008 233.44 233.44 0 0 1 -35.008 -45.28 227.136 227.136 0 0 1 -22.72 -53.6A223.52 223.52 0 0 1 32 256c0 -20.576 2.624 -40.384 7.872 -59.52a222.976 222.976 0 0 1 22.752 -53.344 228.992 228.992 0 0 1 80.288 -80.512 220.64 220.64 0 0 1 53.6 -22.528A217.856 217.856 0 0 1 256 32z"]},st={prefix:"vs",iconName:"circle-large-outline",icon:[512,512,[],"f000","M306.816 70.88A185.856 185.856 0 0 0 256 64c-17.728 0 -34.624 2.336 -50.816 6.88l-0.192 0.064c-16.448 4.512 -31.68 10.944 -45.824 19.232A196.992 196.992 0 0 0 90.24 159.36l-0.064 0.128A190.944 190.944 0 0 0 70.72 205.12 191.552 191.552 0 0 0 64 256c0 17.76 2.24 34.72 6.72 50.912a193.6 193.6 0 0 0 49.536 84.832c11.84 11.68 24.768 21.664 38.912 30.08a195.2 195.2 0 0 0 45.92 19.488A192.64 192.64 0 0 0 256 448c17.76 0 34.72 -2.24 50.912 -6.72 16.48 -4.64 31.68 -11.136 45.632 -19.424l0.128 -0.064a197.12 197.12 0 0 0 69.152 -68.96 187.2 187.2 0 0 0 19.2 -45.824l0.096 -0.192A185.824 185.824 0 0 0 448 256c0 -17.728 -2.304 -34.624 -6.88 -50.816l-0.064 -0.192a184.704 184.704 0 0 0 -19.2 -45.536l-0.064 -0.128a188.8 188.8 0 0 0 -30.144 -38.72l-0.256 -0.256a188.864 188.864 0 0 0 -38.72 -30.144l-0.128 -0.064a184.704 184.704 0 0 0 -45.536 -19.2l-0.192 -0.064zm142.56 298.24a229.024 229.024 0 0 1 -80.512 80.256 222.912 222.912 0 0 1 -53.376 22.72A223.488 223.488 0 0 1 256 480a223.488 223.488 0 0 1 -59.52 -7.872 227.136 227.136 0 0 1 -53.568 -22.752 233.6 233.6 0 0 1 -45.28 -35.008 233.44 233.44 0 0 1 -35.008 -45.28 227.136 227.136 0 0 1 -22.72 -53.6A223.52 223.52 0 0 1 32 256c0 -20.576 2.624 -40.384 7.872 -59.52a222.976 222.976 0 0 1 22.752 -53.344 228.992 228.992 0 0 1 80.288 -80.512 220.64 220.64 0 0 1 53.6 -22.528A217.856 217.856 0 0 1 256 32a217.6 217.6 0 0 1 59.52 8.096 220.768 220.768 0 0 1 98.656 57.76 220.896 220.896 0 0 1 57.728 98.656C477.312 215.616 480 235.424 480 256s-2.688 40.384 -8.096 59.52a220.8 220.8 0 0 1 -22.528 53.568z"]},rt={prefix:"vs",iconName:"circle-slash",icon:[512,512,[],"f000","M256 32a224 224 0 1 1 -224 224 224.256 224.256 0 0 1 224 -224zM64 256c0 45.376 16.128 89.28 45.536 123.84l270.304 -270.304A191.776 191.776 0 0 0 64 256zm384 0c0 -45.376 -16.128 -89.28 -45.536 -123.84L132.16 402.464A191.776 191.776 0 0 0 448 256z"]},ot={prefix:"vs",iconName:"clippy",icon:[512,512,[],"f000","M224 447.744H128v-288h256v64h32v-80l-16 -16H352v-32h-32a64 64 0 0 0 -128 0H158.08v32H112l-16 16v320l16 16H224v-32zm0 -358.4a32 32 0 0 1 25.6 -25.6 32 32 0 0 1 18.56 1.92 30.08 30.08 0 0 1 14.4 11.52 32 32 0 1 1 -56 30.08 32 32 0 0 1 -2.56 -17.92zm226.56 302.72L416 426.944v-171.2h-32v170.88l-34.56 -34.56 -22.72 22.72 62.08 61.76h22.72l61.76 -61.76 -22.72 -22.72zm-189.44 -133.12h22.72l61.76 61.76 -22.72 22.72 -34.56 -34.56v170.88h-32v-171.2l-34.56 34.88 -22.72 -22.72 62.08 -61.76z"]},lt={prefix:"vs",iconName:"close",icon:[512,512,[],"f000","M256 278.624l116.672 116.704 22.656 -22.624L278.624 256l116.704 -116.672 -22.624 -22.656L256 233.376 139.328 116.672l-22.624 22.656L233.376 256l-116.672 116.672 22.624 22.656L256 278.624z"]},ct={prefix:"vs",iconName:"cloud-download",icon:[512,512,[],"f000","M382.624 192h1.6a95.68 95.68 0 0 1 67.712 28.128 96.096 96.096 0 0 1 0 135.744 95.68 95.68 0 0 1 -67.744 28.128v-32a64.064 64.064 0 0 0 0 -128h-29.248l-3.936 -27.424a79.68 79.68 0 0 0 -68.032 -67.904A79.296 79.296 0 0 0 199.392 176l-10.656 24.384 -25.888 -6.048A79.68 79.68 0 0 0 144.736 192c-21.184 0 -41.504 8.416 -56.448 23.424A80.096 80.096 0 0 0 144.736 352h15.936v32h-15.936a111.552 111.552 0 0 1 -84.096 -37.12 112.064 112.064 0 0 1 62.656 -184.96 110.784 110.784 0 0 1 46.976 1.28 111.552 111.552 0 0 1 117.024 -65.92A111.328 111.328 0 0 1 382.624 192zm-168 163.872l42.048 42.048V224h31.808v172.8l40.896 -40.928 22.624 22.624 -68.672 68.704h-22.656L192 378.528l22.624 -22.656z"]},ht={prefix:"vs",iconName:"code",icon:[512,512,[],"f000","M150.656 178.496L65.952 263.168l84.704 84.672 -22.656 22.656 -96 -96V251.84l96 -96 22.656 22.656zm224 -22.656L352 178.496l84.704 84.672L352 347.84l22.656 22.656 96 -96V251.84l-96 -96zM157.056 416l28.608 14.336 160 -320L317.056 96l-160 320z"]},dt={prefix:"vs",iconName:"copy",icon:[512,512,[],"f000","M128 128l32 -32h173.248L448 210.752V448l-32 32H160l-32 -32V128zm288 96l-96 -96H160v320h256V224zM96 32L64 64v320l32 32V64h205.248l-32 -32H96z"]},ut={prefix:"vs",iconName:"device-camera",icon:[512,512,[],"f000","M342.624 96H464l16 16v288l-16 16h-416l-16 -16v-288l16 -16h121.376l27.296 -27.328L208 64h96l11.328 4.672 27.296 27.328zM64 384h384V128h-112l-11.328 -4.672L297.376 96H214.624l-27.296 27.328L176 128H64v256zm48 -224a16 16 0 1 0 0 32 16 16 0 0 0 0 -32zM256 192a64 64 0 1 1 0 128 64 64 0 0 1 0 -128zm0 -32a96 96 0 1 0 0 192 96 96 0 0 0 0 -192z"]},mt={prefix:"vs",iconName:"edit",icon:[512,512,[],"f000","M423.36 32h-46.72L112.64 296l-5.12 7.04L32 434.88 77.12 480l131.84 -75.52 7.04 -5.12L480 135.36V88.64L423.36 32zM77.12 434.88l48.32 -96 46.4 46.4 -94.72 49.6zm122.56 -65.92L143.04 312.32l256 -256 56.64 56.64 -256 256z"]},pt={prefix:"vs",iconName:"file-code",icon:[512,512,[],"f000","M338.24 36.48l104.96 105.6 4.8 11.52v310.4l-16 16h-352l-16 -16v-416l16 -16h247.04l11.2 4.48zM320 160h96l-96 -96v96zM96 64v384h320V192H304L288 176V64H96zm65.984 241.056l58.144 -58.496L197.44 224 128 293.728v22.624l69.472 69.568 22.624 -22.624 -58.112 -58.24zM281.6 246.848l22.4 -22.688 70.048 69.6v22.688L304 385.984l-22.56 -22.688 58.592 -58.24L281.6 246.848z"]},gt={prefix:"vs",iconName:"file-zip",icon:[512,512,[],"f000","M80 32h352l16 16v160l-4.8 11.2 -27.2 27.52v217.28l-16 16h-320l-16 -16v-416l16 -16zM192 64H160v64h32V64zm0 384h128V245.76l-27.2 -27.2L288 207.04V64H224v80l-16 16H192v32H160V160h-16L128 144V64H96v384h64v-32h32v32zm0 -64v32h32v-32H192zm0 -32v32H160v-32h32zm0 -32h32v32H192v-32zm0 -32v32H160V288h32zm0 -32h32v32H192V256zm0 -32v32H160V224h32zm0 0h32V192H192v32zm196.8 4.8l27.2 -27.52V64h-96v136.64l27.2 27.2 4.8 11.2V448h32V240l4.8 -11.2z"]},vt={prefix:"vs",iconName:"file",icon:[512,512,[],"f000","M438.72 137.28l-96 -96L320 32H128L96 64v384l32 32h288l32 -32V160l-9.28 -22.72zM416 448H128V64h160v128h128v256zm-96 -288V64l96 96h-96z"]},ft={prefix:"vs",iconName:"files",icon:[512,512,[],"f000","M373.333 0h-192L149.333 32V128H53.333L21.333 160v321.493L53.333 512h257.493L341.333 481.493V384h100.267l27.733 -30.507V96L373.333 0zm0 45.227l50.773 50.773H373.333V45.227zm-64 434.773h-256v-320H149.333v193.493L181.333 384h128v96zm128 -128h-256v-320H341.333V128h96v224z"]},bt={prefix:"vs",iconName:"filter",icon:[512,512,[],"f000","M480 64v53.44l-160 152.288V448H192V269.728l-160 -152.32V64h448zM224 256v160h64V256l160 -152.32V96H64v7.68L224 256z"]},Ct={prefix:"vs",iconName:"folder-opened",icon:[512,512,[],"f000","M48 448h352l15.36 -11.84 84.16 -224 -15.36 -20.16H448V112l-16 -16H246.72l-27.52 -27.2L208 64h-160l-16 16v352l16 16zM64 96h137.28l27.52 27.2 11.2 4.8H416v64H272l-11.2 4.8 -27.52 27.2H112l-15.04 10.88 -32 98.56L64 96zm324.16 320H70.08l53.44 -160H240l11.2 -4.8 27.52 -27.2h185.28l-75.84 192z"]},St={prefix:"vs",iconName:"folder",icon:[512,512,[],"f000","M464 96H246.72l-27.2 -27.2L208.32 64h-160l-16 16v352l16 16h416l16 -16v-320L464 96zm-16.32 271.68V416h-384V224h143.68l11.2 -4.8 27.52 -27.52H448v48l-0.32 128zm0 -207.68h-208l-11.2 4.8 -27.52 27.52H64v-96h137.28l27.2 27.2 11.52 4.8H448l-0.32 31.68z"]},Et={prefix:"vs",iconName:"gear",icon:[512,512,[],"f000","M291.2 140.8L275.2 64H236.8l-16 76.8 -22.4 9.6 -64 -41.6 -28.8 25.6 41.6 64 -6.4 22.4 -76.8 16v38.4l76.8 16 9.6 25.6 -41.6 64 25.6 25.6 64 -41.6 25.6 9.6 12.8 73.6h38.4l16 -76.8 25.6 -9.6 64 41.6 25.6 -25.6 -41.6 -64 9.6 -25.6 73.6 -12.8V236.8l-76.8 -16 -9.6 -25.6 41.6 -64 -25.6 -25.6 -64 41.6 -22.4 -6.4zM300.8 32l16 76.8L384 67.2l64 64 -44.8 67.2 76.8 12.8v89.6l-76.8 16L448 384l-64 64 -67.2 -44.8 -16 76.8H211.2l-16 -76.8L128 444.8l-64 -64 44.8 -67.2L32 300.8V211.2l76.8 -16L67.2 128l64 -64 67.2 44.8 12.8 -76.8h89.6zm19.2 224c0 35.2 -28.8 64 -64 64s-64 -28.8 -64 -64 28.8 -64 64 -64 64 28.8 64 64zM256 288c19.2 0 32 -12.8 32 -32s-12.8 -32 -32 -32 -32 12.8 -32 32 12.8 32 32 32z"]},wt={prefix:"vs",iconName:"graph",icon:[512,512,[],"f000","M48 448H480v-32H64V0H32v432l16 16zM96 368v-256l16 -16h64l16 16v256l-16 16h-64l-16 -16zm64 -16V128H128v224h32zm192 -304v320l16 16h64l16 -16v-320l-16 -16h-64l-16 16zm64 16v288h-32V64h32zm-192 304v-192l16 -16h64l16 16v192l-16 16h-64l-16 -16zm64 -16V192H256v160h32z"]},yt={prefix:"vs",iconName:"gripper",icon:[512,512,[],"f000","M160 96h64v64H160zm0 128h64v64H160zm0 128h64v64H160zm128 -256h64v64H288zm0 128h64v64H288zm0 128h64v64H288z"]},Tt={prefix:"vs",iconName:"issues",icon:[512,512,[],"f000","M240 32a208 208 0 1 0 0 416 208 208 0 0 0 0 -416zm0 384a176 176 0 1 1 0 -352 176 176 0 0 1 0 352z"]},Ot={prefix:"vs",iconName:"kebab-vertical",icon:[512,512,[],"f000","M238.208 442.624a32 32 0 1 0 35.552 -53.216 32 32 0 0 0 -35.52 53.184zM256 288a32 32 0 1 1 0 -64 32 32 0 0 1 0 64zm0 -160a32 32 0 1 1 0 -64 32 32 0 0 1 0 64z"]},Mt={prefix:"vs",iconName:"law",icon:[512,512,[],"f000","M468.16 224L416 96h32V64H288V32H256v32H96v32h32L76.16 224H64v32h4.8c4.992 15.936 15.136 29.76 28.8 39.36a79.04 79.04 0 0 0 92.8 0A78.08 78.08 0 0 0 219.52 256H224V224h-14.4L156.16 96H256v256H192l-12.48 5.76 -64 80.32 12.48 25.92h288l12.48 -25.92 -64 -80.32L352 352H288V96h100.16l-53.44 128H320v32h4.8a79.36 79.36 0 0 0 150.72 0H480V224h-11.84zM167.04 272.32a48.64 48.64 0 0 1 -23.04 6.08 46.4 46.4 0 0 1 -22.72 -6.08A47.04 47.04 0 0 1 104 256h80a48.64 48.64 0 0 1 -16.96 16.32zM175.04 224h-64l32 -76.8 32 76.8zm169.28 160L384 432H160L199.68 384h144.64zm56.96 -236.16l32 76.8h-64l32 -76.8zm21.76 125.12a45.12 45.12 0 0 1 -23.04 6.08 43.2 43.2 0 0 1 -22.72 -6.08 49.6 49.6 0 0 1 -17.28 -16.96h80a43.84 43.84 0 0 1 -16.96 16.96z"]},Nt={prefix:"vs",iconName:"link",icon:[512,512,[],"f000","M140.8 96h98.72a108.8 108.8 0 0 1 108.8 108.8v6.56A108.8 108.8 0 0 1 239.52 320H224V288h15.52A76.8 76.8 0 0 0 316.16 211.52V204.8A76.8 76.8 0 0 0 239.68 128H140.8A76.8 76.8 0 0 0 64 204.8v6.56A76.608 76.608 0 0 0 128 286.72v32a108.8 108.8 0 0 1 -96 -107.2V204.8A108.96 108.96 0 0 1 140.8 96zM384 225.28v-32a108.8 108.8 0 0 1 96 107.52v6.56A108.96 108.96 0 0 1 371.36 416h-98.88A108.8 108.8 0 0 1 163.84 307.52V300.8A108.8 108.8 0 0 1 272.48 192H288v32h-15.52A76.8 76.8 0 0 0 195.84 300.8v6.56A76.8 76.8 0 0 0 272.48 384h98.88A76.8 76.8 0 0 0 448 307.52V300.8a76.608 76.608 0 0 0 -64 -75.52z"]},Dt={prefix:"vs",iconName:"list-unordered",icon:[512,512,[],"f000","M64 96H32v32h32V96zm0 96H32v32h32V192zM32 288h32v32H32V288zm32 96H32v32h32v-32zm64 -288h352v32H128V96zm352 96H128v32h352V192zM128 288h352v32H128V288zm352 96H128v32h352v-32z"]},xt={prefix:"vs",iconName:"loading",icon:[512,512,[],"f000","M445.344 224A192.064 192.064 0 0 0 66.656 224H34.272a224.064 224.064 0 0 1 443.456 0h-32.384z"]},Rt={prefix:"vs",iconName:"lock",icon:[512,512,[],"f000","M416 224h-32V160a128 128 0 1 0 -256 0v64H96L64 256v192l32 32h320l32 -32V256l-32 -32zM160 160a96 96 0 1 1 192 0v64H160V160zm256 288H96V256h320v192z"]},It={prefix:"vs",iconName:"markdown",icon:[512,512,[],"f000","M203.04 160h67.2v209.056H223.776l1.76 -169.92 -56.768 169.92H130.304l-57.76 -169.92c1.28 20.608 1.92 169.92 1.92 169.92H32V160h68.992s48.896 143.776 50.464 153.824L203.04 160zm214.72 115.744v-112H355.52v112H293.312l93.344 93.312L480 275.744h-62.24z"]},Lt={prefix:"vs",iconName:"menu",icon:[512,512,[],"f000","M512 160H0V128h512v32zm0 256H0v-32h512v32zm0 -128.256H0V256h512v31.744z"]},Ft={prefix:"vs",iconName:"new-file",icon:[512,512,[],"f000","M304 35.2l108.8 112 3.2 12.8v64h-32V192H256V64H96v352h128v32H80l-16 -16v-384l16 -16h214.4l9.6 3.2zM288 64v96h92.8L288 64zm128 448h-32v-96H288v-32h96V288h32v96h96v32h-96v96z"]},kt={prefix:"vs",iconName:"new-folder",icon:[512,512,[],"f000","M464 64H246.72l-27.2 -27.2L208.32 32h-160l-16 16v352l16 16H224v-32H63.68V192h143.68l11.2 -4.8 27.52 -27.52H448v48l-0.032 16.32h32.352V80L464 64zm-16.32 64h-208l-11.2 4.8 -27.52 27.52H64v-96h137.28l27.2 27.2 11.52 4.8H448l-0.32 31.68zM416 512h-32v-96H288v-32h96V288h32v96h96v32h-96v96z"]},At={prefix:"vs",iconName:"pass-filled",icon:[512,512,[],"f000","M256 480A224 224 0 1 0 256 32a224 224 0 0 0 0 448zm-32.64 -132.16h-22.72L128 275.2l22.72 -22.72 61.44 61.44 134.4 -134.72 22.72 22.72 -145.92 145.92z"]},Pt={prefix:"vs",iconName:"pass",icon:[512,512,[],"f000","M200.64 347.84h22.72l145.92 -145.92 -22.72 -22.72 -134.4 134.72 -61.44 -61.44L128 275.2l72.64 72.64zM275.2 32c51.2 3.2 99.2 28.8 134.4 64 41.6 44.8 64 99.2 64 163.2 0 51.2 -19.2 99.2 -51.2 140.8 -32 38.4 -76.8 67.2 -128 76.8 -51.2 9.6 -102.4 3.2 -147.2 -22.4 -44.8 -25.6 -80 -64 -99.2 -112C28.8 294.4 25.6 240 41.6 192c16 -51.2 44.8 -92.8 89.6 -121.6C172.8 41.6 224 28.8 275.2 32zm16 412.8c41.6 -9.6 80 -32 108.8 -67.2 25.6 -35.2 41.6 -76.8 38.4 -121.6 0 -51.2 -19.2 -102.4 -54.4 -137.6 -32 -32 -70.4 -51.2 -115.2 -54.4 -41.6 -3.2 -86.4 6.4 -121.6 32 -35.2 25.6 -60.8 60.8 -73.6 105.6 -12.8 41.6 -12.8 86.4 6.4 128 19.2 41.6 48 73.6 86.4 96 38.4 22.4 83.2 28.8 124.8 19.2z"]},_t={prefix:"vs",iconName:"play",icon:[512,512,[],"f000","M120.96 64L96 77.12v384l24.96 13.44 288 -192V256l-288 -192zM128 431.36V107.2l243.2 162.24L128 431.36z"]},Ht={prefix:"vs",iconName:"preview",icon:[512,512,[],"f000","M64 64h384l32 32v320l-32 32H64l-32 -32V96l32 -32zm0 352h384V96H64v320zm352 -288H96v96h320V128zm-32 64H128V160h256v32zm-96 192h128V256H288v128zm32 -96h64v64h-64V288zM224 256H96v32h128V256zm-128 96h128v32H96v-32z"]},jt={prefix:"vs",iconName:"question",icon:[512,512,[],"f000","M240 32a208 208 0 1 0 0 416 208 208 0 0 0 0 -416zm0 384a176 176 0 1 1 0 -352 176 176 0 0 1 0 352zm49.6 -269.44a58.88 58.88 0 0 0 -19.52 -13.44A72 72 0 0 0 240.96 128a69.12 69.12 0 0 0 -28.16 5.44c-7.648 3.2 -14.4 8.128 -19.84 14.4a60.48 60.48 0 0 0 -12.16 19.84 96 96 0 0 0 -4.8 23.04h39.36a26.88 26.88 0 0 1 16.192 -23.712 23.04 23.04 0 0 1 9.728 -1.568 27.52 27.52 0 0 1 8.64 0 20.48 20.48 0 0 1 7.04 4.48 19.2 19.2 0 0 1 5.12 7.04 23.36 23.36 0 0 1 1.92 9.6c0 5.536 -1.184 10.976 -3.52 16a76.8 76.8 0 0 1 -8.64 14.72l-11.2 13.44c-3.84 4.16 -7.68 8.64 -11.2 13.12a74.56 74.56 0 0 0 -8.64 14.4 37.76 37.76 0 0 0 -3.2 16v21.12H256v-15.68a30.08 30.08 0 0 1 3.52 -13.44 98.88 98.88 0 0 1 8.96 -13.12l11.52 -14.08a137.28 137.28 0 0 0 11.52 -15.36 82.88 82.88 0 0 0 8.96 -17.6 61.12 61.12 0 0 0 3.52 -20.48 69.76 69.76 0 0 0 -3.2 -21.44 48.64 48.64 0 0 0 -11.2 -17.6zM217.6 314.56h37.44V352H217.6V314.56z"]},Vt={prefix:"vs",iconName:"record-keys",icon:[512,512,[],"f000","M448 96H96a32 32 0 0 0 -32 32v224a32 32 0 0 0 32 32h352a32 32 0 0 0 32 -32V128a32 32 0 0 0 -32 -32zm0 256H96V128h352v224zm-96 -192h-32v32h32V160zm-32 64H288v32h32V224zm64 -64h32v32h-32V160zm32 128h-32v32h32V288zM192 288h160v32H192V288zm224 -64h-64v32h64V224zM256 160h32v32H256V160zm0 64H224v32h32V224zM128 288h32v32H128V288zm0 -128h32v32H128V160zm96 0H192v32h32V160zM128 224h64v32H128V224z"]},zt={prefix:"vs",iconName:"refresh",icon:[512,512,[],"f000","M149.792 96H64V64h112l16 16V192H160V128a160 160 0 1 0 144.96 -24.352l9.664 -30.528A192 192 0 1 1 149.792 96z"]},Ut={prefix:"vs",iconName:"remove",icon:[512,512,[],"f000","M480 256H32V224h448v32z"]},Bt={prefix:"vs",iconName:"ruby",icon:[512,512,[],"f000","M32 230.08l212.48 212.48h23.04L480 230.08v-23.04l-106.24 -106.24 -11.52 -4.8H149.76l-11.52 4.8L32 207.04v23.04zm224 177.92L66.56 218.56 156.48 128h199.04l89.92 90.56L256 408zm0 -247.36h86.08l57.92 57.92 -144 140.8V160.64z"]},Wt={prefix:"vs",iconName:"run-all",icon:[512,512,[],"f000","M88.96 64L64 77.12v384l24.96 13.44 288 -192V256l-288 -192zM96 431.36V107.2l243.2 162.24L96 431.36zm96 38.496l280.96 -187.296V256L192 68.704V107.2l243.2 162.24L192 431.36v38.496z"]},Gt={prefix:"vs",iconName:"save",icon:[512,512,[],"f000","M427.296 36.672l48 48L480 96v368l-16 16h-416l-16 -16v-416l16 -16H416l11.296 4.672zM64 64v384h384V102.656L409.376 64H352v128H128V64H64zm192 0v96h64V64H256z"]},qt={prefix:"vs",iconName:"search",icon:[512,512,[],"f000","M325.333 0a176 176 0 0 0 -131.84 292.693L21.333 488.107l23.893 21.333 171.733 -194.56A176.021 176.021 0 1 0 325.333 0.213V0zm0 320a144 144 0 1 1 0 -288 144 144 0 0 1 0 288z"]},Kt={prefix:"vs",iconName:"split-horizontal",icon:[512,512,[],"f000","M448 32H96L64 64v352l32 32h352l32 -32V64l-32 -32zM256 416H96V64h160v352zm192 0H288V64h160v352z"]},Yt={prefix:"vs",iconName:"symbol-operator",icon:[512,512,[],"f000","M91.936 35.2c10.72 4.352 19.264 12.736 23.84 23.36 2.304 5.44 3.488 11.264 3.424 17.184a42.88 42.88 0 0 1 -19.52 36.32 43.488 43.488 0 0 1 -24.096 7.136A43.36 43.36 0 0 1 32 75.584a43.36 43.36 0 0 1 26.56 -40.192A43.84 43.84 0 0 1 91.936 35.2zm-9.536 56.48a17.632 17.632 0 0 0 10.624 -16 17.536 17.536 0 1 0 -10.624 16zM205.76 35.488L35.52 205.76l21.952 21.984 170.24 -170.24 -21.952 -21.984zM368 288h32v80H480v32h-80V480h-32v-80H288v-32h80V288zm-183.424 16.8l22.624 22.624L150.624 384l56.576 56.576 -22.624 22.624L128 406.624l-56.576 56.576 -22.624 -22.624L105.376 384l-56.576 -56.576 22.624 -22.624L128 361.376l56.576 -56.576zm43.2 -134.24a43.296 43.296 0 0 0 -40.192 -26.56 43.36 43.36 0 0 0 -40.192 26.56 43.584 43.584 0 0 0 40.224 60.64A43.456 43.456 0 0 0 227.776 170.56zm-24.096 23.84a17.696 17.696 0 0 1 -9.248 9.28 17.504 17.504 0 0 1 -19.168 -3.744 16.928 16.928 0 0 1 -3.744 -5.536 17.408 17.408 0 0 1 22.912 -22.88 18.08 18.08 0 0 1 5.536 3.712 17.568 17.568 0 0 1 3.712 19.168zM448 96h-128v32h128V96z"]},Xt={prefix:"vs",iconName:"terminal",icon:[512,512,[],"f000","M64 32L32 64v384L64 480h384l32 -32V64L448 32H64zM64 448V64h384v384H64zm120.661 -85.547l22.144 22.635 112.213 -111.851v-19.456l-112.213 -112.213 -22.08 22.613 97.92 100.309 -97.984 97.963z"]},Zt={prefix:"vs",iconName:"tools",icon:[512,512,[],"f000","M472.736 111.52l-24.96 -5.888 -67.456 67.072 -38.208 -38.912 65.792 -69.024 -5.76 -25.344a141.44 141.44 0 0 0 -43.104 -7.296 116.48 116.48 0 0 0 -46.624 8.96 122.368 122.368 0 0 0 -37.952 26.88 119.552 119.552 0 0 0 -28 40.48 126.016 126.016 0 0 0 0 94.912 10730.912 10730.912 0 0 0 -197.536 199.488c-6.72 8.8 -9.92 19.776 -9.088 30.816a44.896 44.896 0 0 0 14.848 30.944c3.968 4.32 8.704 7.904 13.984 10.496 5.44 2.4 11.296 3.776 17.216 4.064 10.112 -0.192 19.808 -4.032 27.328 -10.784 49.536 -46.624 144.448 -142.4 198.368 -198.528 14.624 6.208 30.336 9.408 46.208 9.376a119.552 119.552 0 0 0 85.664 -36.256 124.32 124.32 0 0 0 35.552 -87.36 134.752 134.752 0 0 0 -6.272 -44.096zM93.856 445.696a9.92 9.92 0 0 1 -4.32 2.24 13.984 13.984 0 0 1 -4.768 0 11.072 11.072 0 0 1 -4.608 -1.824 10.752 10.752 0 0 1 -3.648 -3.52c-4.48 -4.576 -8.672 -13.28 -4.48 -18.176 43.84 -46.624 134.112 -137.76 190.56 -193.472 3.2 4.224 6.72 8.256 10.496 12.032 3.776 3.936 7.84 7.584 12.16 10.912 -54.592 56 -143.616 146.048 -191.36 191.808zm355.776 -290.08c0.064 24.48 -9.472 48 -26.624 65.536a91.552 91.552 0 0 1 -128.224 0 95.744 95.744 0 0 1 -20.32 -100.384A87.936 87.936 0 0 1 324.48 69.76a88.32 88.32 0 0 1 34.304 -6.848h8.128L308.768 122.848v22.272l60.64 60.352h21.12l59.104 -58.112v8.256zM103.68 214.016h48.992l22.56 22.944 21.696 -21.568 -21.28 -21.696V192.32l1.824 -52.768 -7.04 -13.984 -91.52 -60.224 -18.912 2.112 -26.592 27.168 -2.112 19.168 58.816 93.376 13.568 6.88zm-30.24 -116.224L147.488 146.56 146.24 182.496H111.808L64.064 106.912l9.376 -9.12zm227.36 222.72l21.568 -21.536 99.392 101.92a47.328 47.328 0 0 1 0 65.248 44.928 44.928 0 0 1 -49.568 10.08 41.92 41.92 0 0 1 -13.984 -10.08l-100.544 -102.496 21.728 -21.696 100.224 102.208a12.864 12.864 0 0 0 4.896 3.36 15.264 15.264 0 0 0 11.488 0 12.896 12.896 0 0 0 4.896 -3.36 13.952 13.952 0 0 0 3.2 -4.896 16.8 16.8 0 0 0 1.152 -5.888 17.504 17.504 0 0 0 -1.12 -5.888 13.952 13.952 0 0 0 -3.2 -4.896L300.8 320.512z"]},$t={prefix:"vs",iconName:"trash",icon:[512,512,[],"f000","M320 96h96v32h-32v288l-32 32H128l-32 -32V128H64V96h96V64a32 32 0 0 1 32 -32h96a32 32 0 0 1 32 32v32zM288 64H192v32h96V64zM128 416h224V128H128v288zm64 -256H160v224h32V160zm32 0h32v224H224V160zm64 0h32v224H288V160z"]},Qt={prefix:"vs",iconName:"triangle-down",icon:[512,512,[],"f000","M64 177.92L77.216 160h358.208l12.576 17.28L267.936 352h-26.464L64 177.92z"]},Jt={prefix:"vs",iconName:"triangle-right",icon:[512,512,[],"f000","M177.92 448L160 434.784V76.576L177.28 64 352 244.064v26.464L177.92 448z"]},en={prefix:"vs",iconName:"warning",icon:[512,512,[],"f000","M241.92 32h28.16l209.28 392.32 -14.08 23.68H46.08L32 424.32 241.92 32zM256 72.96L72.96 416H438.4L256 72.96zM276 384v-32h-40v32h40zm-40 -64V192h40v128h-40z"]},tn={prefix:"vs",iconName:"watch",icon:[512,512,[],"f000","M240 288h64V256H256V176H224v96l16 16zm-64 -170.592A159.936 159.936 0 0 0 96 256a159.936 159.936 0 0 0 80 138.592V464l16 16h128l16 -16v-69.408A159.936 159.936 0 0 0 416 256a159.936 159.936 0 0 0 -80 -138.592V48L320 32H192l-16 16v69.408zM384 256a128 128 0 1 1 -256 0 128 128 0 0 1 256 0z"]},nn={prefix:"dh",iconName:"arrow-to-bottom",icon:[512,512,[],"f000","M99.2 224l160 160h22.4l160 -160 -22.4 -22.4L288 332.8V64H256v268.8L124.8 201.6l-25.6 22.4zM96 416h352v32H96z"]},an={prefix:"dh",iconName:"arrow-to-top",icon:[512,512,[],"f000","M444.8 288l-160 -160h-22.4l-160 160 22.4 22.4L256 179.2V448h32V179.2l131.2 131.2 25.6 -22.4zm3.2 -192H96V64h352v32z"]},sn={prefix:"dh",iconName:"check-square",icon:[512,512,[],"f000","M425.6 64H86.4l-22.4 22.4v342.4l22.4 19.2h342.4l22.4 -22.4V86.4l-25.6 -22.4zm-188.8 284.8h-22.4L144 278.4l22.4 -22.4 60.8 60.8 134.4 -134.4 22.4 22.4 -147.2 144z"]},rn={prefix:"dh",iconName:"exclamation",icon:[512,512,[],"f000","M275.2 384v-32H236.8v32h38.4zm-38.4 -64V128h38.4v192H236.8z"]},on={prefix:"dh",iconName:"eye-slash",icon:[512,512,[],"f000","M480 256c0 -32 -99.2 -160 -224 -160 -32 0 -64 9.6 -92.8 22.4L70.4 25.6 25.6 70.4 435.2 480l44.8 -44.8 -76.8 -76.8C451.2 320 480 272 480 256zM256 131.2c96 0 176 92.8 188.8 124.8 -6.4 16 -32 48 -67.2 76.8L316.8 272c3.2 -6.4 3.2 -9.6 3.2 -16 0 -35.2 -28.8 -64 -64 -64 -6.4 0 -9.6 0 -16 3.2L192 147.2c19.2 -9.6 41.6 -16 64 -16zm0 249.6C160 380.8 80 288 67.2 256c6.4 -9.6 19.2 -32 41.6 -54.4l-25.6 -25.6C51.2 208 32 243.2 32 256c0 32 99.2 160 224 160 19.2 0 38.4 -3.2 57.6 -9.6l-28.8 -28.8c-9.6 3.2 -19.2 3.2 -28.8 3.2z"]},ln={prefix:"dh",iconName:"eye",icon:[512,512,[],"f000","M256 96C131.2 96 32 224 32 256s99.2 160 224 160 224 -128 224 -160 -99.2 -160 -224 -160zm0 284.8C160 380.8 80 288 67.2 256 80 227.2 160 131.2 256 131.2S432 224 444.8 256c-12.8 28.8 -92.8 124.8 -188.8 124.8zM256 192c-35.2 0 -64 28.8 -64 64s28.8 64 64 64 64 -28.8 64 -64 -28.8 -64 -64 -64zm0 92.8c-16 0 -28.8 -12.8 -28.8 -28.8s12.8 -28.8 28.8 -28.8 28.8 12.8 28.8 28.8 -12.8 28.8 -28.8 28.8z"]},cn={prefix:"dh",iconName:"file-csv",icon:[512,512,[],"f000","M444.8 140.8l-105.6 -105.6 -12.8 -3.2H80l-16 16V224h32V64h192v112l16 16H416v32h32V153.6l-3.2 -12.8zM320 160V64l96 96h-96zM80 256l-16 16v192l16 16h352l16 -16v-192l-16 -16h-352zM416 416v32H96V288h320v128zm-217.6 -3.2c-6.4 3.2 -16 3.2 -25.6 3.2 -16 0 -25.6 -3.2 -35.2 -12.8 -9.6 -6.4 -12.8 -19.2 -12.8 -32 0 -16 3.2 -28.8 12.8 -38.4 9.6 -9.6 22.4 -12.8 38.4 -12.8 9.6 0 16 0 22.4 3.2v19.2c-6.4 -3.2 -12.8 -6.4 -22.4 -6.4 -9.6 0 -16 3.2 -22.4 9.6 -6.4 6.4 -9.6 12.8 -9.6 22.4 0 9.6 3.2 16 6.4 22.4 6.4 6.4 12.8 9.6 22.4 9.6 9.6 0 16 -3.2 22.4 -6.4v19.2zm19.2 0v-22.4c3.2 3.2 9.6 6.4 12.8 6.4 3.2 3.2 9.6 3.2 12.8 3.2h6.4c3.2 0 3.2 0 6.4 -3.2l3.2 -3.2v-3.2c0 -3.2 0 -3.2 -3.2 -6.4 3.2 0 0 0 0 -3.2 -3.2 0 -3.2 -3.2 -6.4 -3.2s-6.4 -3.2 -9.6 -3.2c-6.4 -3.2 -12.8 -6.4 -16 -12.8 -3.2 -3.2 -6.4 -9.6 -6.4 -16s0 -9.6 3.2 -12.8c3.2 -3.2 3.2 -6.4 9.6 -9.6 3.2 0 6.4 -3.2 12.8 -3.2h25.6c3.2 0 6.4 0 9.6 3.2v19.2s-3.2 -3.2 -6.4 -3.2 -3.2 0 -6.4 -3.2h-19.2c-3.2 0 -3.2 0 -6.4 3.2l-3.2 3.2v6.4l3.2 3.2s3.2 3.2 6.4 3.2 3.2 3.2 6.4 3.2c3.2 3.2 6.4 3.2 9.6 6.4 3.2 3.2 6.4 3.2 6.4 6.4 3.2 3.2 3.2 6.4 6.4 6.4 0 3.2 3.2 6.4 3.2 9.6 0 6.4 0 9.6 -3.2 12.8 -3.2 3.2 -3.2 6.4 -9.6 9.6 3.2 3.2 0 6.4 -3.2 6.4h-32c-3.2 0 -6.4 -3.2 -12.8 -3.2zm169.6 -92.8l-32 96h-25.6l-32 -96h22.4l19.2 67.2c0 3.2 3.2 6.4 3.2 9.6 0 -3.2 0 -6.4 3.2 -9.6l19.2 -67.2h22.4z"]},hn={prefix:"dh",iconName:"file-download",icon:[512,512,[],"f000","M438.4 137.6l-96 -96L320 32H128L96 64v384l32 32h288l32 -32V160l-9.6 -22.4zM416 448H128V64h160v128h128v256zm-96 -288V64l96 96h-96zm-134.4 182.4l76.8 76.8h22.4l76.8 -76.8 -25.6 -22.4L288 368V227.2H256v140.8L208 320l-22.4 22.4z"]},dn={prefix:"dh",iconName:"file-print",icon:[512,512,[],"f000","M444.8 140.8l-105.6 -105.6 -12.8 -3.2H80l-16 16V224h32V64h192v112l16 16H416v32h32V153.6l-3.2 -12.8zM320 160V64l96 96h-96zM16 256l-16 16v192l16 16h480l16 -16v-192l-16 -16H16zM480 416v32H32V288h448m-32 80c0 19.2 -12.8 32 -32 32s-32 -12.8 -32 -32 12.8 -32 32 -32 32 12.8 32 32zm-96 -16H96v32h256v-32z"]},un={prefix:"dh",iconName:"file-search",icon:[512,512,[],"f000","M412.8 147.2L304 35.2 294.4 32H80l-16 16v384l16 16H224v-32H96V64h160v128h128v32h32V160l-3.2 -12.8zM288 160V64l92.8 96H288zm224 329.6l-92.8 -92.8c9.6 -16 16 -32 16 -51.2 0 -51.2 -41.6 -89.6 -89.6 -89.6C297.6 256 256 297.6 256 345.6s41.6 89.6 89.6 89.6c19.2 0 38.4 -6.4 51.2 -16l92.8 92.8 22.4 -22.4zm-224 -144c0 -32 25.6 -57.6 57.6 -57.6s57.6 25.6 57.6 57.6 -25.6 57.6 -57.6 57.6S288 377.6 288 345.6z"]},mn={prefix:"dh",iconName:"file-spreadsheet",icon:[512,512,[],"f000","M438.4 137.6l-96 -96L320 32H128L96 64v384l32 32h288l32 -32V160l-9.6 -22.4zM416 448H128V64h160v128h128v256zm-96 -288V64l96 96h-96zm64 99.2l-19.2 -19.2H179.2l-19.2 19.2v137.6l19.2 19.2h185.6l19.2 -19.2V259.2zm-150.4 134.4H182.4v-48h51.2v48zm0 -115.2v48H182.4V278.4m115.2 115.2H246.4v-48h48v48zm0 -64H246.4V278.4h48v51.2zm64 64H310.4v-48h48v48zm-51.2 -64V278.4h48v48H310.4z"]},pn={prefix:"dh",iconName:"filter-filled",icon:[512,512,[],"f000","M480 64v54.4l-160 153.6V448H192V268.8L32 118.4V64h448z"]},gn={prefix:"dh",iconName:"filter-slash",icon:[512,512,[],"f000","M480 118.4V64H108.8L70.4 25.6 25.6 70.4l406.4 406.4 44.8 -44.8L320 275.2v-6.4l160 -150.4zM288 416H224v-86.4l-32 -32V448h128v-22.4l-32 -32v22.4zM140.8 96H448v6.4L294.4 249.6 140.8 96z"]},vn={prefix:"dh",iconName:"freeze",icon:[512,512,[],"f000","M438.4 300.8l-19.2 -28.8 -60.8 35.2L272 256l86.4 -51.2 60.8 35.2 19.2 -28.8 -44.8 -25.6 48 -28.8 -16 -25.6 -48 28.8V108.8h-35.2v67.2L256 227.2V128l60.8 -35.2 -16 -28.8 -44.8 25.6V32H224v57.6L179.2 64l-16 28.8L224 128v99.2L137.6 176V108.8H102.4V160l-48 -28.8 -16 25.6 48 28.8 -44.8 25.6 19.2 28.8 60.8 -35.2L208 256 121.6 307.2 60.8 272l-19.2 28.8 44.8 25.6 -48 28.8 16 25.6 48 -28.8v51.2h35.2v-67.2L224 284.8V384l-60.8 35.2 16 28.8 44.8 -25.6V480h32v-57.6l44.8 25.6 16 -28.8L256 384V284.8l86.4 51.2v67.2h35.2V352l48 28.8 16 -25.6 -48 -28.8z"]},fn={prefix:"dh",iconName:"gear-filled",icon:[512,512,[],"f000","M480 211.2l-76.8 -12.8L448 131.2l-64 -64 -67.2 41.6L300.8 32H211.2l-12.8 76.8L131.2 64l-64 64 41.6 67.2 -76.8 16v89.6l76.8 12.8L64 380.8l64 64 67.2 -41.6 16 76.8h89.6l16 -76.8L384 448l64 -64 -44.8 -67.2 76.8 -16V211.2zM256 320c-38.4 0 -64 -25.6 -64 -64s25.6 -64 64 -64 64 25.6 64 64 -25.6 64 -64 64z"]},bn={prefix:"dh",iconName:"graph-line-down",icon:[512,512,[],"f000","M64 416V0H32v432l16 16H480v-32zm67.2 -291.2l-22.4 22.4 108.8 112 70.4 -64 108.8 124.8H320v32h112l16 -16V224h-32v70.4L288 150.4l-70.4 64z"]},Cn={prefix:"dh",iconName:"graph-line-up",icon:[512,512,[],"f000","M64 416V0H32v432l16 16H480v-32zm153.6 -150.4l70.4 64 128 -144V256h32V144l-16 -16H320v32h76.8L288 284.8l-70.4 -64 -108.8 112 22.4 22.4z"]},Sn={prefix:"dh",iconName:"i-cursor",icon:[512,512,[],"f000","M384 48v-32c-73.6 0 -108.8 19.2 -128 38.4C236.8 35.2 201.6 16 128 16v32c70.4 0 112 19.2 112 48v144H192v32h48V416c0 38.4 -83.2 48 -112 48v32c3.2 0 92.8 0 128 -38.4 35.2 38.4 124.8 38.4 128 38.4v-32c-28.8 0 -112 -9.6 -112 -48V272H320v-32H272V96c0 -28.8 41.6 -48 112 -48z"]},En={prefix:"dh",iconName:"input",icon:[512,512,[],"f000","M464 448h-416l-16 -16v-352l16 -16h416l16 16v352l-16 16zM64 416h384V96H64v320zm96 -224h32v128H160zm64 -32v32H128V160l48 16zm0 160v32l-48 -16L128 352v-32z"]},wn={prefix:"dh",iconName:"new-circle-large-filled",icon:[512,512,[],"f000","M240 0C108.8 0 0 108.8 0 240S108.8 480 240 480 480 371.2 480 240 371.2 0 240 0zM352 256H256v96H224V256H128V224h96V128h32v96h96v32z"]},yn={prefix:"dh",iconName:"panels",icon:[512,512,[],"f000","M496 288l16 16v160l-16 16h-192l-16 -16v-160l16 -16h192zm0 -256h-192l-16 16v160l16 16h192l16 -16v-160l-16 -16zM16 32l-16 16v160l16 16h192l16 -16v-160L208 32h-192zm0 256l-16 16v160l16 16h192l16 -16v-160L208 288h-192z"]},Tn={prefix:"dh",iconName:"python",icon:[512,512,[],"f000","M198.4 249.6h99.2s57.6 0 57.6 -54.4V102.4s9.6 -54.4 -99.2 -54.4c-105.6 0 -99.2 44.8 -99.2 44.8v48H256v12.8H115.2s-67.2 -6.4 -67.2 99.2c0 105.6 57.6 102.4 57.6 102.4h35.2V307.2s-3.2 -57.6 57.6 -57.6zm3.2 -131.2c-9.6 0 -19.2 -9.6 -19.2 -19.2s6.4 -19.2 19.2 -19.2c9.6 0 19.2 9.6 19.2 19.2s-9.6 19.2 -19.2 19.2zm208 35.2h-35.2v48s3.2 57.6 -57.6 57.6H217.6S160 259.2 160 313.6v92.8s-12.8 54.4 99.2 54.4c105.6 0 99.2 -44.8 99.2 -44.8v-48H259.2v-12.8h140.8s67.2 6.4 67.2 -99.2 -57.6 -102.4 -57.6 -102.4zm-96 236.8c9.6 0 19.2 9.6 19.2 19.2s-9.6 19.2 -19.2 19.2 -19.2 -9.6 -19.2 -19.2 9.6 -19.2 19.2 -19.2z"]},On={prefix:"dh",iconName:"refresh",icon:[512,512,[],"f000","M313.6 73.6l-9.6 32c83.2 25.6 131.2 118.4 102.4 201.6 -19.2 64 -80 108.8 -150.4 108.8 -89.6 0 -160 -70.4 -160 -160 0 -51.2 22.4 -96 64 -128v64h32V80L176 64H64v32h86.4c-76.8 51.2 -108.8 150.4 -70.4 236.8C112 403.2 179.2 448 256 448c105.6 0 192 -86.4 192 -192 0 -83.2 -54.4 -156.8 -134.4 -182.4z"]},Mn={prefix:"dh",iconName:"remove-square-filled",icon:[512,512,[],"f000","M432 32h-384l-16 16v384l16 16h384l16 -16v-384l-16 -16zM352 256H128V224h224v32z"]},Nn={prefix:"dh",iconName:"shapes",icon:[512,512,[],"f000","M195.2 320L160 256 128 313.6 105.6 352 32 480h256l-73.6 -128 -19.2 -32zm112 -76.8c51.2 -35.2 121.6 -22.4 156.8 28.8s22.4 121.6 -28.8 156.8c0 0 -3.2 0 -3.2 3.2 -51.2 32 -121.6 19.2 -153.6 -32 -35.2 -54.4 -22.4 -121.6 28.8 -156.8zM96 32v192h192V32H96z"]},Dn={prefix:"dh",iconName:"sort-alpha-down",icon:[512,512,[],"f000","M236.8 368L156.8 448h-22.4l-80 -80 22.4 -22.4L128 396.8V64h32v332.8l51.2 -51.2 25.6 22.4zM371.2 224l-6.4 -28.8H316.8l-9.6 28.8H256l54.4 -160h60.8l51.2 160h-51.2zm-32 -124.8c0 3.2 -3.2 3.2 -3.2 9.6s-3.2 19.2 -12.8 51.2h32l-9.6 -44.8c-3.2 -6.4 -6.4 -9.6 -6.4 -16zm-6.4 310.4h73.6V448H272v-32l73.6 -89.6H275.2V288h128v32l-70.4 89.6z"]},xn={prefix:"dh",iconName:"sort-alpha-up",icon:[512,512,[],"f000","M51.2 144L131.2 64h22.4l80 80 -22.4 22.4L160 115.2V448H128V115.2L76.8 166.4l-25.6 -22.4zm320 304l-6.4 -28.8H316.8l-9.6 28.8H256l54.4 -160h60.8l51.2 160h-51.2zm-32 -124.8c0 3.2 -3.2 3.2 -3.2 9.6 0 6.4 -3.2 19.2 -12.8 51.2h32l-9.6 -44.8c-3.2 -6.4 -6.4 -9.6 -6.4 -16zm-6.4 -137.6h73.6V224H272V192l73.6 -89.6H275.2V64h128v32l-70.4 89.6z"]},Rn={prefix:"dh",iconName:"sort-amount-down",icon:[512,512,[],"f000","M204.8 368L124.8 448h-22.4L22.4 368l22.4 -22.4L96 396.8V64h32v332.8l51.2 -51.2 25.6 22.4zM256 64h256v64H256zm0 105.6h192v64H256zm0 108.8h128v64H256zM256 384h64v64H256z"]},In={prefix:"dh",iconName:"sort-down",icon:[512,512,[],"f000","M128 288l-12.8 25.6 128 118.4h25.6l128 -118.4L384 288H128z"]},Ln={prefix:"dh",iconName:"sort-up",icon:[512,512,[],"f000","M128 224l-12.8 -25.6 128 -118.4h25.6l128 118.4 -12.8 25.6H128z"]},Fn={prefix:"dh",iconName:"sort",icon:[512,512,[],"f000","M128 224l-12.8 -25.6 128 -118.4h25.6l128 118.4 -12.8 25.6H128zm0 64l-12.8 25.6 128 118.4h25.6l128 -118.4L384 288H128z"]},kn={prefix:"dh",iconName:"square-filled",icon:[512,512,[],"f000","M432 32h-384l-16 16v384l16 16h384l16 -16v-384l-16 -16z"]},An={prefix:"dh",iconName:"table",icon:[512,512,[],"f000","M432 64h-384l-16 16v352l16 16h384l16 -16v-352l-16 -16zM160 416H64v-64h96v64zm0 -96H64V256h96v64zm0 -96H64V160h96v64zm128 192H192v-64h96v64zm0 -96H192V256h96v64zm0 -96H192V160h96v64zm128 192h-96v-64h96v64zm0 -96h-96V256h96v64zm0 -96h-96V160h96v64z"]},Pn={prefix:"dh",iconName:"trash-undo",icon:[512,512,[],"f000","M320 96h96v32h-32v288l-32 32H128l-32 -32V128H64V96h96V64c0 -19.2 12.8 -32 32 -32h96c19.2 0 32 12.8 32 32v32zM288 64H192v32h96V64zM128 416h224V128H128v288zm112 -64L160 272v-22.4l80 -80 22.4 22.4 -51.2 54.4H320v32H211.2l51.2 51.2 -22.4 22.4z"]},_n={prefix:"dh",iconName:"triangle-down-square",icon:[512,512,[],"f000","M425.6 64H86.4l-22.4 22.4v342.4l22.4 19.2h342.4l22.4 -22.4V86.4l-25.6 -22.4zm-160 288h-22.4L99.2 208l9.6 -16h291.2l9.6 12.8L265.6 352z"]},Hn={prefix:"dh",iconName:"truck",icon:[512,512,[],"f000","M480 384V256l-64 -64 -64 -64h-32V64H32v352h35.2c6.4 35.2 38.4 64 76.8 64s70.4 -28.8 76.8 -64H320c6.4 35.2 38.4 64 76.8 64s70.4 -28.8 76.8 -64H512v-32h-32zm-291.2 32c-6.4 19.2 -25.6 32 -44.8 32s-38.4 -12.8 -44.8 -32c-3.2 -6.4 -3.2 -9.6 -3.2 -16 0 -25.6 22.4 -48 48 -48s48 22.4 48 48c0 6.4 0 9.6 -3.2 16zm147.2 -140.8l-12.8 -12.8v-96l22.4 -6.4 96 96 -9.6 19.2h-96zm108.8 140.8c-6.4 19.2 -25.6 32 -44.8 32s-38.4 -12.8 -44.8 -32c-3.2 -6.4 -3.2 -9.6 -3.2 -16 0 -25.6 22.4 -48 48 -48s48 22.4 48 48c0 6.4 0 9.6 -3.2 16z"]},jn={prefix:"dh",iconName:"unlink",icon:[512,512,[],"f000","M32 211.2v-6.4C32 144 80 96 140.8 96h99.2c12.8 0 25.6 3.2 38.4 6.4l-25.6 25.6H140.8C99.2 128 64 163.2 64 204.8v6.4c0 28.8 16 54.4 38.4 67.2l-22.4 22.4C51.2 281.6 32 249.6 32 211.2zM403.2 6.4l-38.4 38.4 -67.2 67.2 -22.4 25.6 -150.4 147.2 -25.6 25.6 -54.4 54.4 -38.4 38.4L51.2 448 448 51.2 403.2 6.4zM384 192v32c38.4 6.4 64 38.4 64 76.8v6.4c0 41.6 -35.2 76.8 -76.8 76.8H272c-32 0 -60.8 -22.4 -73.6 -51.2l-25.6 25.6c19.2 35.2 54.4 60.8 96 60.8h99.2c60.8 0 108.8 -48 108.8 -108.8v-9.6C480 246.4 438.4 198.4 384 192zM246.4 288l-22.4 19.2v12.8h16c60.8 0 108.8 -48 108.8 -108.8v-6.4c0 -6.4 0 -12.8 -3.2 -19.2l-32 32c0 38.4 -32 67.2 -67.2 70.4z"]},Vn={prefix:"dh",iconName:"warning-circle-filled",icon:[512,512,[],"f000","M470.4 195.2c-9.6 -38.4 -28.8 -70.4 -57.6 -99.2 -25.6 -25.6 -60.8 -44.8 -96 -54.4C297.6 35.2 275.2 32 256 32c-19.2 0 -41.6 3.2 -60.8 9.6 -16 3.2 -35.2 9.6 -51.2 22.4 -35.2 19.2 -60.8 44.8 -80 80 -12.8 16 -19.2 35.2 -25.6 51.2C35.2 214.4 32 236.8 32 256c0 19.2 3.2 41.6 6.4 60.8 6.4 16 12.8 35.2 25.6 51.2 9.6 16 22.4 32 35.2 44.8 12.8 16 28.8 25.6 44.8 35.2 16 9.6 35.2 16 54.4 22.4 16 6.4 38.4 9.6 57.6 9.6 19.2 0 41.6 -3.2 60.8 -6.4 19.2 -6.4 35.2 -12.8 54.4 -22.4 32 -19.2 60.8 -48 80 -80 9.6 -16 16 -35.2 22.4 -54.4 3.2 -19.2 6.4 -41.6 6.4 -60.8s-3.2 -41.6 -9.6 -60.8zM275.2 352H236.8v-32h38.4v32zm0 -64H236.8V160h38.4v128z"]},zn={prefix:"dh",iconName:"warning-filled",icon:[512,512,[],"f000","M268.8 32h-25.6L32 425.6l12.8 22.4h419.2l12.8 -22.4L268.8 32zm6.4 352H236.8v-32h38.4v32zm0 -64H236.8V192h38.4v128z"]},Un={vsAccount:{prefix:"vs",iconName:"account",icon:[512,512,[],"f000","M512 255.744C512 114.56 397.312 0 256 0S0 114.56 0 255.744c0 77.76 35.328 147.84 90.624 194.88 0.512 0.512 1.024 0.512 1.024 1.024 4.608 3.584 9.216 7.168 14.336 10.752 2.56 1.536 4.608 3.552 7.168 5.6A255.36 255.36 0 0 0 256.512 512a255.36 255.36 0 0 0 143.36 -44c2.56 -1.536 4.608 -3.552 7.168 -5.12 4.608 -3.552 9.728 -7.136 14.336 -10.72 0.512 -0.512 1.024 -0.512 1.024 -1.024 54.272 -47.584 89.6 -117.632 89.6 -195.392zm-256 224.032c-48.128 0 -92.16 -15.36 -128.512 -40.928 0.512 -4.096 1.536 -8.16 2.56 -12.256a133.44 133.44 0 0 1 13.312 -31.712c5.632 -9.728 12.288 -18.432 20.48 -26.112 7.68 -7.68 16.896 -14.816 26.112 -20.448 9.728 -5.632 19.968 -9.728 31.232 -12.8A132.8 132.8 0 0 1 256 330.944a133.92 133.92 0 0 1 93.696 37.312c11.776 11.776 20.992 25.6 27.648 41.44 3.584 9.216 6.144 18.944 7.68 29.152A224.96 224.96 0 0 1 256 479.776zm-78.336 -236.8a79.68 79.68 0 0 1 -6.656 -32.768c0 -11.232 2.048 -22.496 6.656 -32.736 4.608 -10.24 10.752 -19.424 18.432 -27.104 7.68 -7.68 16.896 -13.792 27.136 -18.4 10.24 -4.608 21.504 -6.656 32.768 -6.656 11.776 0 22.528 2.048 32.768 6.656 10.24 4.608 19.456 10.752 27.136 18.4 7.68 7.68 13.824 16.896 18.432 27.104 4.608 10.24 6.656 21.504 6.656 32.736 0 11.776 -2.048 22.528 -6.656 32.736a90.88 90.88 0 0 1 -18.432 27.136 90.88 90.88 0 0 1 -27.136 18.4 86.88 86.88 0 0 1 -66.048 0 90.88 90.88 0 0 1 -27.136 -18.4 80.832 80.832 0 0 1 -17.92 -27.136zm237.568 169.792c0 -1.024 -0.512 -1.536 -0.512 -2.56a167.04 167.04 0 0 0 -22.016 -44.992 156.256 156.256 0 0 0 -34.816 -36.32 166.624 166.624 0 0 0 -33.28 -19.456 90.24 90.24 0 0 0 14.848 -12.256 134.4 134.4 0 0 0 19.968 -25.088 115.968 115.968 0 0 0 16.896 -61.888 118.72 118.72 0 0 0 -9.216 -47.04 121.568 121.568 0 0 0 -26.112 -38.368 123.04 123.04 0 0 0 -38.4 -25.6 119.04 119.04 0 0 0 -47.104 -9.184 119.04 119.04 0 0 0 -47.104 9.216 116.192 116.192 0 0 0 -38.4 26.08 122.88 122.88 0 0 0 -25.6 38.368 118.72 118.72 0 0 0 -9.216 47.04c0 11.264 1.536 22.016 4.608 32.224 3.072 10.752 7.168 20.48 12.8 29.664 5.12 9.216 12.288 17.408 19.968 25.088 4.608 4.608 9.728 8.672 15.36 12.256a163.84 163.84 0 0 0 -33.28 19.968c-13.312 10.24 -25.088 22.496 -34.816 35.808a159.968 159.968 0 0 0 -22.016 44.992c-0.512 1.024 -0.512 2.048 -0.512 2.56C56.832 372.352 31.744 317.12 31.744 255.744 31.744 132.48 132.608 31.712 256 31.712s224.256 100.768 224.256 224.032a222.72 222.72 0 0 1 -65.024 157.024z"]},vsActivateBreakpoints:{prefix:"vs",iconName:"activate-breakpoints",icon:[512,512,[],"f000","M480 176a140.608 140.608 0 0 1 -128 144 94.56 94.56 0 0 0 -6.4 -32A114.08 114.08 0 0 0 448 176a112.224 112.224 0 0 0 -224 -9.6A113.664 113.664 0 0 0 192 160a147.904 147.904 0 0 1 144 -128A143.392 143.392 0 0 1 480 176zM176 192a144 144 0 1 0 0 288.032 144 144 0 0 0 0 -288z"]},vsAdd:{prefix:"vs",iconName:"add",icon:[512,512,[],"f000","M448 224v32H256v192H224V256H32V224h192V32h32v192h192z"]},vsArchive:{prefix:"vs",iconName:"archive",icon:[512,512,[],"f000","M464 32h-416l-16 16v96l16 16H64v272l16 16h352l16 -16V160h16l16 -16v-96l-16 -16zm-32 96H64V64h384v64h-16zM96 416V160h320v256H96zm256 -192H160v32h192V224z"]},vsArrowBoth:{prefix:"vs",iconName:"arrow-both",icon:[512,512,[],"f000","M96 288l68.672 68.672 -22.624 22.656 -96 -96v-22.656l96 -96 22.624 22.656L96 256h320l-68.672 -68.672 22.624 -22.656 96 96v22.656l-96 96 -22.624 -22.624L416 288H96z"]},vsArrowDown:{prefix:"vs",iconName:"arrow-down",icon:[512,512,[],"f000","M100.704 288l160 160h22.624l160 -160 -22.624 -22.624L288 398.048V64H256v334.08L123.328 265.344 100.704 288z"]},vsArrowLeft:Ye,vsArrowRight:{prefix:"vs",iconName:"arrow-right",icon:[512,512,[],"f000","M288 444.384l160 -160V261.76l-160 -160 -22.624 22.624 132.672 132.704H64v32h334.08L265.344 421.76l22.624 22.624z"]},vsArrowSmallDown:Xe,vsArrowSmallLeft:{prefix:"vs",iconName:"arrow-small-left",icon:[512,512,[],"f000","M208 342.4L128 262.4v-22.4L208 160l22.72 22.4 -52.48 52.8h178.24v32H178.24L231.04 320l-23.04 22.4z"]},vsArrowSmallRight:{prefix:"vs",iconName:"arrow-small-right",icon:[512,512,[],"f000","M276.48 160l80 80v22.4l-80 80 -22.72 -22.4 52.48 -52.8H128v-32h178.24L253.44 182.4l23.04 -22.4z"]},vsArrowSmallUp:Ze,vsArrowSwap:{prefix:"vs",iconName:"arrow-swap",icon:[512,512,[],"f000","M134.624 481.952L32 379.328v-22.624L134.624 254.08l22.624 22.624 -75.296 75.328H480v32H81.92l75.328 75.296 -22.624 22.624zm242.752 -224L480 155.328v-22.624L377.376 30.08l-22.624 22.624L430.048 128H32v32h398.08l-75.328 75.328 22.624 22.624z"]},vsArrowUp:$e,vsAzure:{prefix:"vs",iconName:"azure",icon:[512,512,[],"f000","M491.84 437.76l-128 -384a32 32 0 0 0 -32 -21.76H180.16a32 32 0 0 0 -30.4 21.76l-129.6 384a32 32 0 0 0 32 42.24h93.76a32 32 0 0 0 30.08 -21.76l19.52 -56.96 96 72.64a32 32 0 0 0 19.2 6.08h149.76a32 32 0 0 0 31.36 -42.24zm-179.84 21.12a10.24 10.24 0 0 1 -6.4 -2.24L124.8 322.56l-2.88 -2.24h96l2.56 -6.72 32 -80.96 71.68 212.16a10.88 10.88 0 0 1 -12.16 14.08zm149.44 0H342.4a32 32 0 0 0 0 -21.12l-129.6 -384h119.04a10.88 10.88 0 0 1 10.24 7.36l129.6 384a10.88 10.88 0 0 1 -10.24 13.76z"]},vsBeakerStop:{prefix:"vs",iconName:"beaker-stop",icon:[512,512,[],"f000","M96 480.192h160.224a160.96 160.96 0 0 1 -31.936 -31.776L96 448.544l49.344 -96.352H192V352c0 -10.88 1.088 -21.536 3.168 -31.808h-33.6l59.008 -115.136L224 198.176V65.152l64 -0.768v135.584l2.24 4.384c9.92 -4.16 20.352 -7.36 31.168 -9.44L320 192.192v-128h32v-32H319.808V32l-14.592 0.16H160V64h32v126.464l-124.608 243.488A32 32 0 0 0 96 480.192zm184.896 -234.624a128 128 0 1 1 142.208 212.864 128 128 0 0 1 -142.208 -212.864zm3.2 174.304A96 96 0 0 0 352 448a96 96 0 0 0 55.68 -17.6L273.6 296.32A96 96 0 0 0 256 352a96 96 0 0 0 28.128 67.872zm12.224 -146.24l134.08 134.048A96 96 0 0 0 448 352a96 96 0 0 0 -96 -96 96 96 0 0 0 -55.68 17.6z"]},vsBeaker:{prefix:"vs",iconName:"beaker",icon:[512,512,[],"f000","M444.576 433.856L320 192.192v-128h32v-32H319.808V32l-14.592 0.16H160V64h32v126.464l-124.608 243.488A32 32 0 0 0 96 480.192h320a32 32 0 0 0 28.576 -46.336zm-224 -228.8L224 198.176V65.152l64 -0.768v135.584l3.52 6.88 58.464 113.344H161.568l59.008 -115.136zM96 448.544l49.28 -96.352h221.312l49.504 96L96 448.544z"]},vsBellDot:{prefix:"vs",iconName:"bell-dot",icon:[512,512,[],"f000","M416 284.8c3.2 19.2 6.4 35.2 12.8 54.4l19.2 54.4 -16 22.4H320c0 16 -6.4 32 -19.2 44.8 -12.8 12.8 -28.8 19.2 -44.8 19.2 -16 0 -35.2 -6.4 -44.8 -19.2 -12.8 -12.8 -19.2 -28.8 -19.2 -44.8H80l-16 -22.4 19.2 -54.4c6.4 -25.6 12.8 -51.2 12.8 -76.8V192c0 -22.4 3.2 -44.8 12.8 -64 9.6 -22.4 22.4 -38.4 38.4 -54.4s35.2 -25.6 57.6 -32C220.8 35.2 240 32 256 32c-6.4 9.6 -12.8 22.4 -19.2 35.2 -6.4 0 -12.8 0 -22.4 6.4 -16 3.2 -32 12.8 -44.8 25.6 -12.8 9.6 -25.6 25.6 -32 41.6 -6.4 16 -9.6 32 -9.6 51.2v70.4c0 28.8 -6.4 57.6 -12.8 86.4L102.4 384h307.2l-12.8 -35.2c-5.6 -16.832 -8.768 -36.16 -11.616 -53.568L384 288c12.8 0 22.4 0 32 -3.2zM256 448c6.4 0 16 -3.2 22.4 -9.6 6.4 -6.4 9.6 -12.8 9.6 -22.4H224c0 9.6 3.2 16 9.6 22.4 6.4 6.4 16 9.6 22.4 9.6zm224 -320a96 96 0 1 1 -192 0 96 96 0 0 1 192 0z"]},vsBell:Qe,vsBold:{prefix:"vs",iconName:"bold",icon:[512,512,[],"f000","M160 416V96h107.584c35.712 0 62.528 7.168 80.48 21.536 18.08 14.368 27.136 35.616 27.136 63.744 0 14.944 -4.384 28.192 -13.12 39.776 -8.736 11.424 -20.64 20.288 -35.712 26.592 17.792 4.832 31.776 14.08 42.048 27.68 10.4 13.504 15.584 29.6 15.584 48.352 0 28.736 -9.568 51.296 -28.704 67.712 -19.136 16.416 -46.176 24.608 -81.152 24.608H160zm43.392 -149.664v115.168h71.68c20.16 0 36.064 -5.056 47.68 -15.168 11.744 -10.24 17.6 -24.32 17.6 -42.208 0 -38.528 -21.536 -57.792 -64.64 -57.792h-72.32zm0 -33.856h65.568c18.976 0 34.112 -4.608 45.44 -13.856 11.424 -9.216 17.152 -21.76 17.152 -37.568 0 -17.6 -5.28 -30.336 -15.808 -38.24 -10.56 -8.064 -26.592 -12.096 -48.16 -12.096H203.392v101.76z"]},vsBook:{prefix:"vs",iconName:"book",icon:[512,512,[],"f000","M464 64H288l-11.2 4.8 -20.8 20.48 -20.8 -20.48L224 64H48l-16 16v320l16 16h169.28l27.52 27.2h22.4l27.52 -27.2h169.28l16 -16v-320l-16 -16zm-224 330.24l-5.76 -5.44L224 384H64V96h153.28l23.68 23.68 -0.96 274.56zM448 384H288l-11.2 4.8 -4.48 4.16V118.4l22.4 -22.4H448v288zM192 160H96v32h96V160zm0 128H96v32h96V288zM96 224h96v32H96V224zm320 -64h-96v32h96V160zm-96 64h96v32h-96V224zm0 64h96v32h-96V288z"]},vsBookmark:{prefix:"vs",iconName:"bookmark",icon:[512,512,[],"f000","M400 32h-288l-16 16v416l27.904 10.72L256 327.904l132.096 146.816L416 464v-416l-16 -16zM384 422.4L267.904 293.28h-23.808L128 422.4V64h256v358.4z"]},vsBracketDot:{prefix:"vs",iconName:"bracket-dot",icon:[512,512,[],"f000","M192 95.104v0.384h-2.88c-6.368 0 -12.352 1.28 -17.984 3.872a46.976 46.976 0 0 0 -14.624 10.24 47.04 47.04 0 0 0 -13.44 33.12c0 7.264 0.128 14.496 0.384 21.664 0.256 7.168 0.256 14.272 0 21.28a152.032 152.032 0 0 1 -1.76 20.48c-1.056 6.72 -2.848 13.12 -5.376 19.296A73.088 73.088 0 0 1 112.704 256a73.088 73.088 0 0 1 23.616 30.56c2.56 6.176 4.32 12.64 5.376 19.456 1.056 6.592 1.632 13.44 1.76 20.48 0.256 6.912 0.256 14.016 0 21.312 -0.256 7.04 -0.384 14.208 -0.384 21.504 0 6.496 1.184 12.608 3.552 18.336 2.528 5.664 5.824 10.656 9.888 14.976 4.16 4.16 9.056 7.584 14.624 10.208 5.6 2.464 11.616 3.68 18.016 3.68H192V448h-2.88c-10.016 0 -19.712 -1.984 -29.088 -5.92a74.56 74.56 0 0 1 -24.8 -16.96 71.36 71.36 0 0 1 -15.776 -24.096v-0.032a113.28 113.28 0 0 1 -6.336 -26.368v-0.064a197.952 197.952 0 0 1 -0.768 -27.84c0.384 -9.248 0.576 -18.496 0.576 -27.776 0 -6.336 -1.28 -12.384 -3.744 -18.112V300.8a45.248 45.248 0 0 0 -9.856 -14.88l-0.064 -0.064a44.064 44.064 0 0 0 -14.56 -10.176h-0.032a42.112 42.112 0 0 0 -17.824 -3.904H64v-31.488h2.88c6.24 0 12.16 -1.216 17.824 -3.68a48.128 48.128 0 0 0 24.48 -25.152v-0.064c2.496 -5.76 3.744 -11.84 3.744 -18.304 0 -9.28 -0.192 -18.56 -0.576 -27.808a194.56 194.56 0 0 1 0.768 -27.616V137.6c1.056 -9.184 3.168 -18.048 6.304 -26.56v-0.032a71.36 71.36 0 0 1 15.808 -24.096A74.56 74.56 0 0 1 160 69.92c9.376 -3.936 19.072 -5.92 29.12 -5.92H192v31.104zm253.536 176.64H448v-31.488h-2.88c-6.24 0 -12.16 -1.28 -17.792 -3.872l-0.032 -0.032a44.032 44.032 0 0 1 -14.56 -10.176l-0.064 -0.064a45.248 45.248 0 0 1 -9.824 -14.88l-0.032 -0.064a44.96 44.96 0 0 1 -3.744 -18.112c0 -9.28 0.192 -18.56 0.576 -27.808a198.08 198.08 0 0 0 -0.768 -27.84v-0.032a113.344 113.344 0 0 0 -6.304 -26.368v-0.032a71.36 71.36 0 0 0 -15.808 -24.096 74.56 74.56 0 0 0 -24.8 -16.96 74.4 74.4 0 0 0 -29.12 -5.92H320v31.488h2.88c6.4 0 12.352 1.216 17.984 3.68 5.568 2.624 10.432 6.016 14.624 10.24 4.064 4.288 7.36 9.28 9.888 14.944 2.368 5.76 3.52 11.84 3.52 18.336 0 7.296 -0.096 14.464 -0.352 21.504 -0.256 7.296 -0.256 14.4 0 21.28 0.128 7.104 0.704 13.92 1.76 20.48 1.056 6.848 2.848 13.312 5.376 19.488a73.024 73.024 0 0 0 23.616 30.56l-1.024 0.8c16.96 1.856 32.96 7.072 47.264 14.944zM384 288a96 96 0 1 0 0 192 96 96 0 0 0 0 -192z"]},vsBracketError:{prefix:"vs",iconName:"bracket-error",icon:[512,512,[],"f000","M192 95.104v0.384h-2.88c-6.368 0 -12.352 1.28 -17.984 3.872a46.976 46.976 0 0 0 -14.624 10.24 47.04 47.04 0 0 0 -13.44 33.12c0 7.264 0.128 14.496 0.384 21.664 0.256 7.168 0.256 14.272 0 21.28a152.032 152.032 0 0 1 -1.76 20.48c-1.056 6.72 -2.848 13.12 -5.376 19.296A73.088 73.088 0 0 1 112.704 256a73.088 73.088 0 0 1 23.616 30.56c2.56 6.176 4.32 12.64 5.376 19.456 1.056 6.592 1.632 13.44 1.76 20.48 0.256 6.912 0.256 14.016 0 21.312 -0.256 7.04 -0.384 14.208 -0.384 21.504 0 6.496 1.184 12.608 3.552 18.336 2.528 5.664 5.824 10.656 9.888 14.976 4.16 4.16 9.056 7.584 14.624 10.208 5.6 2.464 11.616 3.68 18.016 3.68H192V448h-2.88c-10.016 0 -19.712 -1.984 -29.088 -5.92a74.56 74.56 0 0 1 -24.8 -16.96 71.36 71.36 0 0 1 -15.776 -24.096v-0.032a113.28 113.28 0 0 1 -6.336 -26.368v-0.064a197.952 197.952 0 0 1 -0.768 -27.84c0.384 -9.248 0.576 -18.496 0.576 -27.776 0 -6.336 -1.28 -12.384 -3.744 -18.112V300.8a45.248 45.248 0 0 0 -9.856 -14.88l-0.064 -0.064a44.064 44.064 0 0 0 -14.56 -10.176h-0.032a42.112 42.112 0 0 0 -17.824 -3.904H64v-31.488h2.88c6.24 0 12.16 -1.216 17.824 -3.68a48.128 48.128 0 0 0 24.48 -25.152v-0.064c2.496 -5.76 3.744 -11.84 3.744 -18.304 0 -9.28 -0.192 -18.56 -0.576 -27.808a194.56 194.56 0 0 1 0.768 -27.616V137.6c1.056 -9.184 3.168 -18.048 6.304 -26.56v-0.032a71.36 71.36 0 0 1 15.808 -24.096A74.56 74.56 0 0 1 160 69.92c9.376 -3.936 19.072 -5.92 29.12 -5.92H192v31.104zm253.536 176.64H448v-31.488h-2.88c-6.24 0 -12.16 -1.28 -17.792 -3.872l-0.032 -0.032a44.032 44.032 0 0 1 -14.56 -10.176l-0.064 -0.064a45.248 45.248 0 0 1 -9.824 -14.88l-0.032 -0.064a44.96 44.96 0 0 1 -3.744 -18.112c0 -9.28 0.192 -18.56 0.576 -27.808a198.08 198.08 0 0 0 -0.768 -27.84v-0.032a113.344 113.344 0 0 0 -6.304 -26.368v-0.032a71.36 71.36 0 0 0 -15.808 -24.096 74.56 74.56 0 0 0 -24.8 -16.96 74.4 74.4 0 0 0 -29.12 -5.92H320v31.488h2.88c6.4 0 12.352 1.216 17.984 3.68 5.568 2.624 10.432 6.016 14.624 10.24 4.064 4.288 7.36 9.28 9.888 14.944 2.368 5.76 3.52 11.84 3.52 18.336 0 7.296 -0.096 14.464 -0.352 21.504 -0.256 7.296 -0.256 14.4 0 21.28 0.128 7.104 0.704 13.92 1.76 20.48 1.056 6.848 2.848 13.312 5.376 19.488a73.024 73.024 0 0 0 23.616 30.56l-1.024 0.8c16.96 1.856 32.96 7.072 47.264 14.944zm-114.88 32.448a96 96 0 1 1 106.688 159.616 96 96 0 0 1 -106.688 -159.616zm90.016 20.48L384 361.376l-36.672 -36.704 -22.624 22.624L361.376 384l-36.704 36.672 22.656 22.656L384 406.624l36.672 36.672 22.656 -22.624L406.624 384l36.704 -36.672 -22.656 -22.656z"]},vsBriefcase:{prefix:"vs",iconName:"briefcase",icon:[512,512,[],"f000","M464 128H352V80l-16 -16h-160l-16 16V128H48l-16 16v256l16 16h416l16 -16v-256l-16 -16zM192 96h128v32H192V96zm256 64v24.32L320 256v-16L304.32 224h-96L192 240V256L64 182.72V160h384zM288 256v32H224V256h64zm-224 128V219.52l128 73.28v11.2l16 16h96l16 -16v-9.92l128 -72.96V384H64z"]},vsBroadcast:{prefix:"vs",iconName:"broadcast",icon:[512,512,[],"f000","M149.344 64.352A192 192 0 0 1 256 32a192.224 192.224 0 0 1 192 192 192 192 0 0 1 -127.872 180.96v-1.408c0.512 -0.448 0.992 -0.96 1.472 -1.44a47.36 47.36 0 0 0 13.888 -33.472v-4.384A161.344 161.344 0 0 0 390.08 134.4a161.28 161.28 0 1 0 -214.08 229.632v4.608a47.36 47.36 0 0 0 15.36 34.88v1.28A191.968 191.968 0 0 1 149.344 64.32zm149.632 315.168a15.36 15.36 0 0 1 -10.88 4.48v80.64a15.36 15.36 0 0 1 -15.36 15.36H238.72c0.352 0 -0.128 -0.128 -1.088 -0.384 -2.4 -0.64 -7.712 -2.048 -9.76 -4.128a15.36 15.36 0 0 1 -4.512 -10.88V384a15.36 15.36 0 0 1 -15.36 -15.36V304a32 32 0 0 1 32 -32h31.488a32 32 0 0 1 32 32v64.64a15.36 15.36 0 0 1 -4.384 10.72l-0.128 0.128zM340.48 224c0 16.8 -5.024 33.088 -14.24 46.88 5.856 9.664 9.248 20.992 9.248 33.12v3.392a115.072 115.072 0 0 0 1.92 -164.8A115.2 115.2 0 1 0 176 306.88V304c0 -12.288 3.456 -23.776 9.472 -33.504A84.48 84.48 0 1 1 340.48 224zM288 224a32 32 0 1 1 -64 0 32 32 0 0 1 64 0z"]},vsBrowser:{prefix:"vs",iconName:"browser",icon:[512,512,[],"f000","M48 32h416l16 16v384l-16 16h-416l-16 -16v-384l16 -16zM64 160v256h384V160H64zm0 -32h384V64H64v64z"]},vsBug:{prefix:"vs",iconName:"bug",icon:[512,512,[],"f000","M348.064 144v-18.624a93.376 93.376 0 1 0 -186.752 0V144h-26.656L81.44 90.528l-18.976 18.88 51.552 51.808 -0.608 1.568a256.96 256.96 0 0 0 -16.096 90.592c0 6.272 0.224 12.48 0.64 18.56l0.096 1.44H32v26.752h69.408l0.192 1.088c5.504 30.112 16.128 57.664 30.528 80.992l1.088 1.76L70.4 446.784l18.944 18.944 59.872 -59.904 1.856 2.112c27.776 31.744 64.064 50.848 103.616 50.848 38.976 0 74.752 -18.528 102.368 -49.408l1.824 -2.048 61.12 61.44 18.976 -18.912 -63.872 -64.192 1.12 -1.792c14.944 -23.68 25.92 -51.808 31.552 -82.656l0.192 -1.088h69.472v-26.752h-66.08l0.096 -1.408a269.76 269.76 0 0 0 0.64 -18.56 256.64 256.64 0 0 0 -16.544 -91.712l-0.608 -1.6 50.24 -50.24 -18.944 -18.88L373.184 144h-25.12zm-160 0v-18.624a66.624 66.624 0 1 1 133.248 0V144H188.096zm182.304 26.784l0.64 1.696c9.056 24.096 14.304 51.52 14.304 80.896 0 51.52 -16.096 97.088 -40.768 129.184 -24.64 32.032 -56.672 49.44 -89.856 49.44 -33.152 0 -65.184 -17.408 -89.824 -49.44 -24.704 -32.096 -40.8 -77.664 -40.8 -129.184 0 -29.376 5.248 -56.8 14.336 -80.896l0.64 -1.696h231.328z"]},vsCalendar:{prefix:"vs",iconName:"calendar",icon:[512,512,[],"f000","M464 64H416V32h-32v32H128V32H96v32H48l-16 16v384l16 16h416l16 -16v-384l-16 -16zM448 448H64V160h384v288zm0 -320H64V96h384v32zM128 256H96v32h32V256zm-32 64h32v32H96v-32zm32 64H96v32h32v-32zm64 -128h32v32H192V256zm32 64H192v32h32v-32zm-32 64h32v32H192v-32zm32 -192H192v32h32V192zm64 64h32v32H288V256zm32 64H288v32h32v-32zm-32 64h32v32H288v-32zm32 -192H288v32h32V192zm64 64h32v32h-32V256zm32 64h-32v32h32v-32zm-32 -128h32v32h-32V192z"]},vsCallIncoming:{prefix:"vs",iconName:"call-incoming",icon:[512,512,[],"f000","M401.504 298.496a50.144 50.144 0 0 0 -19.008 -3.744 38.464 38.464 0 0 0 -17.76 3.232 88.384 88.384 0 0 0 -13.76 8.256 69.312 69.312 0 0 0 -11.488 10.496c-3.328 3.84 -6.56 7.36 -9.728 10.528a77.088 77.088 0 0 1 -9.28 8 17.088 17.088 0 0 1 -22.24 -2.016 1029.44 1029.44 0 0 1 -10.496 -9.984c-4.48 -4.352 -9.984 -9.6 -16.48 -15.776A1976.832 1976.832 0 0 1 251.008 288l-21.76 -21.248a827.104 827.104 0 0 1 -38.72 -40.512 169.984 169.984 0 0 1 -12.512 -15.488c-3.008 -4.32 -4.512 -7.488 -4.512 -9.504a14.72 14.72 0 0 1 3.232 -9.984c2.336 -3.008 5.12 -6.08 8.256 -9.28 3.2 -3.136 6.688 -6.496 10.496 -9.984 3.84 -3.52 7.36 -7.264 10.528 -11.264 3.136 -4 5.824 -8.576 8 -13.76 2.144 -5.12 3.232 -10.976 3.232 -17.472a50.144 50.144 0 0 0 -14.496 -35.264 243.328 243.328 0 0 1 -16.992 -18.496 207.584 207.584 0 0 0 -19.744 -20.48 134.624 134.624 0 0 0 -22.272 -16.512A46.72 46.72 0 0 0 119.744 32a50.144 50.144 0 0 0 -35.232 14.496c-8.672 8.672 -16.256 16.416 -22.752 23.264a128.192 128.192 0 0 0 -16.512 21.248 84.16 84.16 0 0 0 -9.984 24.48A140.48 140.48 0 0 0 32 148c0 17.664 2.848 36 8.512 55.008 5.664 18.976 13.312 37.92 22.976 56.736 9.664 18.848 21.44 37.344 35.264 55.52 13.824 18.144 28.832 35.392 44.992 51.744 16.16 16.32 33.344 31.424 51.52 45.248 18.144 13.824 36.736 25.76 55.744 35.744 18.976 10.016 38.08 17.824 57.248 23.488a197.024 197.024 0 0 0 56 8.512 150.272 150.272 0 0 0 32.256 -3.52 82.88 82.88 0 0 0 24.736 -9.984c7.36 -4.48 14.4 -9.984 21.248 -16.48 6.848 -6.528 14.496 -14.016 23.008 -22.528A50.176 50.176 0 0 0 480 392.224a64.288 64.288 0 0 0 -3.264 -16.48 53.568 53.568 0 0 0 -8.224 -15.488 231.68 231.68 0 0 0 -11.776 -14.24 172.192 172.192 0 0 0 -13.472 -13.504 2929.568 2929.568 0 0 0 -13.76 -12.256 264.864 264.864 0 0 1 -11.744 -11.008 48.512 48.512 0 0 0 -16.256 -10.752zm-11.744 146.752a100.16 100.16 0 0 1 -25.504 2.752 176.832 176.832 0 0 1 -48.512 -7.744 267.584 267.584 0 0 1 -50.752 -21.248 422.56 422.56 0 0 1 -97.504 -73.504 548.8 548.8 0 0 1 -41.248 -46.752 336.064 336.064 0 0 1 -32.96 -50.496 291.84 291.84 0 0 1 -21.536 -51.52A169.856 169.856 0 0 1 64 147.264a106.88 106.88 0 0 1 3.008 -25.28c1.824 -6.976 4.576 -13.248 8.256 -18.72 3.648 -5.504 8.16 -10.848 13.472 -16 5.344 -5.184 11.424 -11.2 18.24 -18.016a17.344 17.344 0 0 1 12.8 -5.248c1.984 -0.16 5.056 1.152 9.216 4 4.16 2.848 8.672 6.24 13.504 10.24a225.856 225.856 0 0 1 28.768 28.768c4 4.8 7.328 9.248 9.984 13.248 2.656 4 4 7.072 4 9.248a13.728 13.728 0 0 1 -3.232 9.984c-2.336 2.688 -5.12 5.76 -8.256 9.28 -3.2 3.488 -6.688 6.816 -10.496 9.984 -3.84 3.168 -7.36 6.912 -10.528 11.232a72.512 72.512 0 0 0 -8 14.016 43.04 43.04 0 0 0 -3.232 17.28c0.16 6.816 1.504 13.216 4 19.2 2.496 6.016 6.08 11.36 10.752 16l119.232 119.264a48.864 48.864 0 0 0 35.264 14.72 38.4 38.4 0 0 0 17.504 -3.2 77.248 77.248 0 0 0 25.248 -18.752c3.52 -3.84 6.72 -7.36 9.76 -10.528 2.976 -3.136 6.08 -5.824 9.248 -8a17.44 17.44 0 0 1 9.984 -3.232c2.336 0 5.504 1.344 9.504 4 4 2.656 8.416 6.08 13.248 10.24 4.832 4.16 9.824 8.768 15.008 13.76 5.152 4.992 9.76 9.984 13.76 15.008 3.968 4.992 7.328 9.504 9.984 13.504 2.656 4 4 7.04 4 9.248a17.056 17.056 0 0 1 -5.248 12.48c-7.168 7.008 -13.248 13.12 -18.24 18.24a101.088 101.088 0 0 1 -16 13.504 61.76 61.76 0 0 1 -18.752 8.512zM480 54.528l-148.48 148.736h105.216v32h-160v-160h32V180.48L457.504 32l22.496 22.496z"]},vsCallOutgoing:{prefix:"vs",iconName:"call-outgoing",icon:[512,512,[],"f000","M276.736 212.736L425.28 64H320V32h160v160h-32V86.72L299.264 235.296l-22.528 -22.528zm105.76 82.016a50.144 50.144 0 0 1 35.264 14.496c3.52 3.52 7.424 7.168 11.744 11.008l13.76 12.256c4.8 4.32 9.312 8.832 13.472 13.472 4.16 4.672 8.096 9.44 11.776 14.272 3.648 4.8 6.4 9.984 8.224 15.488 1.856 5.504 2.944 11.008 3.264 16.512a50.176 50.176 0 0 1 -14.496 35.232c-8.512 8.512 -16.16 16 -23.008 22.528a128.192 128.192 0 0 1 -21.248 16.48c-7.36 4.48 -15.584 7.84 -24.736 10.016a150.272 150.272 0 0 1 -32.256 3.488 197.024 197.024 0 0 1 -56 -8.512A314.208 314.208 0 0 1 250.976 448a398.24 398.24 0 0 1 -55.712 -35.744 490.528 490.528 0 0 1 -51.52 -45.248c-16.16 -16.32 -31.168 -33.6 -44.992 -51.744a372.48 372.48 0 0 1 -35.264 -55.52 332.16 332.16 0 0 1 -22.976 -56.736A192.16 192.16 0 0 1 32 148c0 -12.672 1.088 -23.488 3.264 -32.512a84.16 84.16 0 0 1 9.984 -24.48c4.48 -7.36 10.016 -14.4 16.512 -21.248 6.496 -6.848 14.08 -14.592 22.72 -23.264A50.144 50.144 0 0 1 119.776 32c8.32 0 16.32 2.24 24 6.72 7.68 4.544 15.104 10.016 22.272 16.544 7.136 6.496 13.76 13.312 19.744 20.48 5.984 7.168 11.648 13.344 16.96 18.496a50.144 50.144 0 0 1 14.496 35.264 44.8 44.8 0 0 1 -3.2 17.504 58.368 58.368 0 0 1 -8 13.76 95.456 95.456 0 0 1 -10.528 11.232c-3.84 3.52 -7.328 6.848 -10.496 10.016a100.096 100.096 0 0 0 -8.256 9.248 14.72 14.72 0 0 0 -3.232 9.984c0 2.016 1.504 5.184 4.48 9.504a169.6 169.6 0 0 0 12.512 15.488 780.352 780.352 0 0 0 38.752 40.512c7.488 7.36 14.752 14.4 21.76 21.248 6.976 6.848 13.76 13.344 20.256 19.52 6.496 6.144 12 11.392 16.48 15.744 4.48 4.32 8 7.68 10.496 9.984a17.088 17.088 0 0 0 22.272 2.016c2.976 -2.176 6.08 -4.864 9.248 -8 3.168 -3.2 6.4 -6.688 9.728 -10.528 3.328 -3.84 7.168 -7.328 11.52 -10.496 4.32 -3.168 8.896 -5.92 13.76 -8.256a38.72 38.72 0 0 1 17.728 -3.232zM364.256 448c10.176 0 18.656 -0.928 25.504 -2.752a61.76 61.76 0 0 0 18.752 -8.512c5.664 -3.84 10.976 -8.32 16 -13.472 4.992 -5.184 11.072 -11.264 18.24 -18.24 3.52 -3.52 5.248 -7.68 5.248 -12.512 0 -2.176 -1.344 -5.248 -4 -9.28a195.904 195.904 0 0 0 -10.016 -13.472 160.32 160.32 0 0 0 -13.76 -15.04c-5.12 -4.96 -10.144 -9.568 -14.976 -13.728a138.304 138.304 0 0 0 -13.248 -10.24c-4 -2.656 -7.168 -4 -9.504 -4a17.44 17.44 0 0 0 -9.984 3.232 57.632 57.632 0 0 0 -9.28 8c-2.976 3.2 -6.24 6.688 -9.728 10.528 -3.52 3.84 -7.36 7.328 -11.52 10.496 -4.16 3.168 -8.736 5.92 -13.76 8.256a38.656 38.656 0 0 1 -17.472 3.232 48.864 48.864 0 0 1 -35.264 -14.72L156.256 236.48a49.184 49.184 0 0 1 -10.752 -16 52.96 52.96 0 0 1 -4 -19.264c0 -6.496 1.088 -12.256 3.232 -17.248 2.176 -4.992 4.832 -9.664 8 -14.016 3.2 -4.32 6.688 -8.064 10.528 -11.232 3.84 -3.168 7.328 -6.496 10.496 -10.016 3.168 -3.488 5.92 -6.56 8.256 -9.248a13.728 13.728 0 0 0 3.232 -9.984c0 -2.176 -1.344 -5.248 -4 -9.28a162.72 162.72 0 0 0 -9.984 -13.216 217.312 217.312 0 0 0 -13.76 -15.008 217.184 217.184 0 0 0 -15.008 -13.76 181.568 181.568 0 0 0 -13.504 -10.24c-4.16 -2.848 -7.232 -4.16 -9.248 -4a17.344 17.344 0 0 0 -12.736 5.248 2087.68 2087.68 0 0 1 -18.24 18.016 98.336 98.336 0 0 0 -13.504 16 60.8 60.8 0 0 0 -8.256 18.752A108.064 108.064 0 0 0 64 147.232c0 16 2.56 32.48 7.744 49.472a291.84 291.84 0 0 0 21.504 51.52c9.184 17.312 20.16 34.176 32.992 50.496 12.832 16.32 26.592 31.904 41.28 46.72a422.56 422.56 0 0 0 97.472 73.536 267.84 267.84 0 0 0 50.752 21.248 176.832 176.832 0 0 0 48.512 7.744z"]},vsCaseSensitive:{prefix:"vs",iconName:"case-sensitive",icon:[512,512,[],"f000","M239.84 289.664l28.512 75.2h34.912L199.584 96h-32.64L64 364.864h35.04l26.816 -75.2h113.984zM185.952 142.496l1.408 4.32 42.176 114.368H136.16l41.824 -114.368 1.408 -4.32 1.216 -4.992 1.024 -4.864 0.672 -4.032h0.736l0.768 4.032 0.928 4.864 1.216 4.992zm255.488 192.352v29.952h30.72V239.936c0 -23.008 -5.76 -40.704 -17.248 -53.152 -11.488 -12.448 -28.448 -18.656 -50.816 -18.656 -6.368 0 -12.832 0.608 -19.392 1.792a156 156 0 0 0 -34.496 10.432 66.592 66.592 0 0 0 -10.976 6.016v31.488c8.512 -7.36 18.112 -13.152 28.928 -17.28a93.664 93.664 0 0 1 33.664 -6.176c6.016 0 11.456 0.896 16.416 2.72a31.36 31.36 0 0 1 12.672 8.544c3.488 3.872 6.176 8.928 8.064 15.104 1.888 6.176 2.816 13.664 2.816 22.4l-57.952 8.064c-11.008 1.504 -20.48 4.032 -28.416 7.584a62.304 62.304 0 0 0 -19.68 13.408 51.2 51.2 0 0 0 -11.52 18.56 68.288 68.288 0 0 0 -3.744 23.072c0 7.872 1.344 15.2 3.968 22.016 2.624 6.816 6.496 12.704 11.616 17.632 5.12 4.928 11.52 8.832 19.136 11.712 7.616 2.88 16.416 4.32 26.432 4.32 12.864 0 24.32 -2.944 34.4 -8.896 10.08 -5.952 18.304 -14.528 24.672 -25.792h0.736zm-68.096 -55.776c5.632 -2.048 12.832 -3.648 21.568 -4.768l46.88 -6.56v19.488c0 7.872 -1.312 15.2 -3.936 22.016a55.264 55.264 0 0 1 -10.976 17.824 50.336 50.336 0 0 1 -16.768 11.904 52.16 52.16 0 0 1 -21.376 4.32c-5.984 0 -11.296 -0.8 -15.84 -2.432a32.96 32.96 0 0 1 -11.424 -6.752 28.672 28.672 0 0 1 -7.04 -10.112A32.16 32.16 0 0 1 352 311.424a51.2 51.2 0 0 1 1.76 -14.08 23.648 23.648 0 0 1 6.464 -10.688 37.12 37.12 0 0 1 13.12 -7.584z"]},vsCheckAll:{prefix:"vs",iconName:"check-all",icon:[512,512,[],"f000","M499.84 115.072L250.08 409.92l-23.296 -1.056L128 268.224l24.128 -16.96 87.808 125.024L477.344 96l22.496 19.072zM231.488 280.768l140.352 -165.696L349.344 96l-135.36 159.808 17.504 24.96zm-49.6 12.896l17.536 24.96 -17.504 -24.96zm-51.744 61.12l17.504 24.96 -25.568 30.176 -23.296 -1.056L0 268.224l24.128 -16.96 87.808 125.024 18.24 -21.504z"]},vsCheck:Je,vsChecklist:{prefix:"vs",iconName:"checklist",icon:[512,512,[],"f000","M120 143.36h-22.72L64 109.76l22.72 -22.4 22.08 21.76L153.92 64l22.72 22.72 -56.64 56.64zM223.68 96h256v32h-256V96zm0 96h256v32h-256V192zm256 96h-256v32h256V288zm-256 96h256v32h-256v-32zM97.28 239.36h22.72l56.64 -56.64 -22.72 -22.4L108.8 205.44l-22.08 -22.08 -22.72 22.72 33.28 33.28zm22.72 96.32h-22.72L64 302.4l22.72 -22.72 22.08 22.08 45.12 -45.44 22.72 22.72 -56.64 56.64zm-22.72 96.32h22.72l56.64 -56.64 -22.72 -22.72 -45.12 45.44 -22.08 -22.08 -22.72 22.4 33.28 33.6z"]},vsChevronDown:et,vsChevronLeft:tt,vsChevronRight:nt,vsChevronUp:it,vsChromeClose:{prefix:"vs",iconName:"chrome-close",icon:[512,512,[],"f000","M227.712 256l-145.856 145.856 28.288 28.288L256 284.288l145.856 145.856 28.288 -28.288L284.288 256l145.856 -145.856 -28.288 -28.288L256 227.712 110.144 81.856l-28.288 28.288L227.712 256z"]},vsChromeMaximize:{prefix:"vs",iconName:"chrome-maximize",icon:[512,512,[],"f000","M96 96v320h320V96H96zm288 288H128V128h256v256z"]},vsChromeMinimize:{prefix:"vs",iconName:"chrome-minimize",icon:[512,512,[],"f000","M448 256v32H96V256h352z"]},vsChromeRestore:{prefix:"vs",iconName:"chrome-restore",icon:[512,512,[],"f000","M96 160v288h288V160H96zm256 256H128V192h224v224zM160 160h32V128h224v224h-32v32h64V96H160v64z"]},vsCircleFilled:{prefix:"vs",iconName:"circle-filled",icon:[512,512,[],"f000","M256 128c11.744 0 23.072 1.536 34.016 4.64a126.176 126.176 0 0 1 56.384 32.992 126.208 126.208 0 0 1 32.96 56.384c3.104 10.88 4.64 22.24 4.64 33.984 0 11.744 -1.536 23.072 -4.64 34.016a126.08 126.08 0 0 1 -32.96 56.48 128.544 128.544 0 0 1 -56.384 32.992C279.04 382.496 267.744 384 256 384s-23.072 -1.504 -34.016 -4.48a129.792 129.792 0 0 1 -56.48 -33.024A129.76 129.76 0 0 1 132.48 289.984 127.744 127.744 0 0 1 128 256c0 -11.744 1.504 -23.072 4.48 -34.016a128.64 128.64 0 0 1 13.024 -30.496A130.848 130.848 0 0 1 191.36 145.472a126.08 126.08 0 0 1 30.624 -12.832A124.48 124.48 0 0 1 256 128z"]},vsCircleLargeFilled:at,vsCircleLargeOutline:st,vsCircleOutline:{prefix:"vs",iconName:"circle-outline",icon:[512,512,[],"f000","M256 384a128 128 0 1 0 0 -256 128 128 0 0 0 0 256zm83.52 -128a83.52 83.52 0 1 1 -167.04 0 83.52 83.52 0 0 1 167.04 0zM256 167.872z"]},vsCircleSlash:rt,vsCircuitBoard:{prefix:"vs",iconName:"circuit-board",icon:[512,512,[],"f000","M464 32h-416l-16 16v416l16 16h416l16 -16v-416l-16 -16zM448 448H160v-64h73.6c9.6 19.2 32 32 54.4 32 35.2 0 64 -28.8 64 -64s-28.8 -64 -64 -64 -64 28.8 -64 64H128v96H64V64h64v73.6c-19.2 9.6 -32 32 -32 54.4 0 35.2 28.8 64 64 64s64 -28.8 64 -64h64c0 35.2 28.8 64 64 64s64 -28.8 64 -64 -28.8 -64 -64 -64c-22.4 0 -44.8 12.8 -54.4 32H214.4c-9.6 -19.2 -32 -32 -54.4 -32V64h288v384zm-192 -96c0 -19.2 12.8 -32 32 -32s32 12.8 32 32 -12.8 32 -32 32 -32 -12.8 -32 -32zM160 160c19.2 0 32 12.8 32 32s-12.8 32 -32 32 -32 -12.8 -32 -32 12.8 -32 32 -32zm192 0c19.2 0 32 12.8 32 32s-12.8 32 -32 32 -32 -12.8 -32 -32 12.8 -32 32 -32z"]},vsClearAll:{prefix:"vs",iconName:"clear-all",icon:[512,512,[],"f000","M320 403.2l22.4 22.4 51.2 -51.2 51.2 51.2 25.6 -22.4L416 352l54.4 -51.2 -25.6 -25.6 -51.2 54.4 -51.2 -54.4 -22.4 25.6 51.2 51.2 -51.2 51.2zM32 128h448V96H32v32zm0 96h448V192H32v32zm256 80V288H32v32h256v-16zM288 416v-32H32v32h256z"]},vsClippy:ot,vsCloseAll:{prefix:"vs",iconName:"close-all",icon:[512,512,[],"f000","M275.872 258.752l-22.624 -22.624L208 281.376 162.752 236.128l-22.624 22.624L185.376 304l-45.248 45.248 22.624 22.624L208 326.624l45.248 45.248 22.624 -22.624L230.624 304l45.248 -45.248zM160 96l32 -32h224l32 32v224l-32 32h-64v64l-32 32H96l-32 -32V192l32 -32h64V96zm32 64h128l32 32v128h64V96H192v64zm128 32H96v224h224V192z"]},vsClose:lt,vsCloudDownload:ct,vsCloudUpload:{prefix:"vs",iconName:"cloud-upload",icon:[512,512,[],"f000","M382.592 192h1.6a95.68 95.68 0 0 1 67.744 28.128 96.096 96.096 0 0 1 0 135.744 95.68 95.68 0 0 1 -67.744 28.128h-63.84v-32h63.84a64.064 64.064 0 0 0 0 -128h-29.248l-3.936 -27.424a79.68 79.68 0 0 0 -68.032 -67.904A79.296 79.296 0 0 0 199.36 176l-10.656 24.384 -25.888 -6.048A79.68 79.68 0 0 0 144.736 192c-21.184 0 -41.504 8.416 -56.448 23.424A80.096 80.096 0 0 0 144.736 352h79.808v32H144.736a111.552 111.552 0 0 1 -84.096 -37.12 112.064 112.064 0 0 1 -12.8 -132.384A111.904 111.904 0 0 1 123.296 161.92c15.552 -2.88 31.584 -2.464 46.976 1.312a111.552 111.552 0 0 1 117.024 -65.92A111.328 111.328 0 0 1 382.592 192zm-53.216 123.296L287.328 273.28v173.952h-31.808v-172.8L214.624 315.328 192 292.672 260.672 224h22.656L352 292.672l-22.624 22.624z"]},vsCloud:{prefix:"vs",iconName:"cloud",icon:[512,512,[],"f000","M382.624 192h1.6a95.68 95.68 0 0 1 67.712 28.128 96.096 96.096 0 0 1 0 135.744 95.68 95.68 0 0 1 -67.744 28.128v-0.416L384 384H144.736a111.552 111.552 0 0 1 -84.096 -37.12 112.064 112.064 0 0 1 62.656 -184.96 110.784 110.784 0 0 1 46.976 1.28 111.552 111.552 0 0 1 117.024 -65.92A111.328 111.328 0 0 1 382.624 192zM160 352h224.32a63.808 63.808 0 0 0 63.744 -64 64.064 64.064 0 0 0 -63.872 -64h-29.248l-3.936 -27.424a79.68 79.68 0 0 0 -68.032 -67.904A79.296 79.296 0 0 0 199.392 176l-10.656 24.384 -25.888 -6.048A79.68 79.68 0 0 0 144.736 192c-21.184 0 -41.504 8.416 -56.448 23.424A80.096 80.096 0 0 0 144.736 352H160z"]},vsCode:ht,vsCollapseAll:{prefix:"vs",iconName:"collapse-all",icon:[512,512,[],"f000","M288 288H128v32h160V288zM160 96l32 -32h224l32 32v224l-32 32h-64v64l-32 32H96l-32 -32V192l32 -32h64V96zm32 64h128l32 32v128h64V96H192v64zm128 32H96v224h224V192z"]},vsColorMode:{prefix:"vs",iconName:"color-mode",icon:[512,512,[],"f000","M256 32a224 224 0 1 0 0 448A224 224 0 0 0 256 32zm0 416V64a192 192 0 1 1 0 384z"]},vsCombine:{prefix:"vs",iconName:"combine",icon:[512,512,[],"f000","M48 32l-16 16v96l16 16h96l16 -16v-96L144 32h-96zM64 128V64h64v64H64zm-16 64l-16 16v96l16 16h96l16 -16v-96L144 192h-96zM64 288V224h64v64H64zm-32 80l16 -16h96l16 16v96l-16 16h-96l-16 -16v-96zm32 16v64h64v-64H64zm336 -224l-16 16v192l16 16h96l16 -16v-192l-16 -16h-96zM480 256h-64V192h64v64zm0 96h-64V288h64v64zM291.2 256H192v32h99.2l-32 32 22.4 19.2 57.6 -57.6v-22.4L281.6 201.6l-22.4 22.4 32 32z"]},vsCommentDiscussion:{prefix:"vs",iconName:"comment-discussion",icon:[512,512,[],"f000","M128 361.28l32 -32v45.44l-36.8 36.48L96 400V320H48L32 304v-256l16 -16h384l16 16V192h-32V64H64v224h48l16 16v57.28zM329.28 416l59.52 59.2 27.2 -11.2V416h48l16 -16v-160l-16 -16h-256l-16 16v160l16 16h121.28zm6.72 -32H224V256h224v128h-48l-16 16v25.28l-36.8 -36.48 -11.2 -4.8z"]},vsComment:{prefix:"vs",iconName:"comment",icon:[512,512,[],"f000","M464 64h-416l-16 16v288l16 16H128v80l27.328 11.328L246.624 384H464l16 -16v-288l-16 -16zm-16 288H240l-11.328 4.672L160 425.376V368l-16 -16H64V96h384v256z"]},vsCompassActive:{prefix:"vs",iconName:"compass-active",icon:[512,512,[],"f000","M291.232 444.8a192.128 192.128 0 0 1 -19.232 2.56V416h-32v31.36a192.032 192.032 0 0 1 -175.424 -176.576H96v-32h-31.232A192.032 192.032 0 0 1 240 64.64V96h32v-31.36a192.032 192.032 0 0 1 175.36 175.36H416v32h31.36a192.128 192.128 0 0 1 -2.56 19.232c10.688 2.464 20.864 6.272 30.4 11.232a224 224 0 1 0 -172.704 172.704 127.136 127.136 0 0 1 -11.264 -30.4zm25.696 -109.856L223.68 288.32 158.944 158.944 288.288 223.68l46.688 93.216a128.64 128.64 0 0 0 -18.048 18.016zm-15.008 -33.024L271.392 240.64l-61.312 -30.56 30.528 61.344 61.312 30.528zm60.736 34.272a96 96 0 1 1 106.656 159.584 96 96 0 0 1 -106.656 -159.584zm54.336 122.144l57.28 -76.384 -25.6 -19.2 -47.36 63.168 -28.032 -22.4 -19.968 24.96 40.896 32.736 22.784 -2.88z"]},vsCompassDot:{prefix:"vs",iconName:"compass-dot",icon:[512,512,[],"f000","M291.232 444.8a192.128 192.128 0 0 1 -19.232 2.56V416h-32v31.36a192.032 192.032 0 0 1 -175.424 -176.576H96v-32h-31.232A192.032 192.032 0 0 1 240 64.64V96h32v-31.36a192.032 192.032 0 0 1 175.36 175.36H416v32h31.36a192.128 192.128 0 0 1 -2.56 19.232c10.688 2.464 20.864 6.272 30.4 11.232a224 224 0 1 0 -172.704 172.704 127.136 127.136 0 0 1 -11.264 -30.4zm25.696 -109.856L223.68 288.32 158.944 158.944 288.288 223.68l46.688 93.216a128.64 128.64 0 0 0 -18.048 18.016zm-15.008 -33.024L271.392 240.64l-61.312 -30.56 30.528 61.344 61.312 30.528z"]},vsCompass:{prefix:"vs",iconName:"compass",icon:[512,512,[],"f000","M288.288 223.712l64.768 129.344L223.712 288.32 158.944 158.944 288.288 223.68zm13.632 78.208L271.392 240.64l-61.312 -30.56 30.528 61.344 61.312 30.528zM447.36 272a192.064 192.064 0 0 1 -175.36 175.36V416h-32v31.36a192.032 192.032 0 0 1 -175.424 -176.576H96v-32h-31.232A192.032 192.032 0 0 1 240 64.64V96h32v-31.36a192.032 192.032 0 0 1 175.36 175.36H416v32h31.36zM256 480A224 224 0 1 0 256 32a224 224 0 0 0 0 448z"]},vsCopy:dt,vsCreditCard:{prefix:"vs",iconName:"credit-card",icon:[512,512,[],"f000","M448 160v32H64V160h384zM64 224h384v160H64V224zm384 -96H64a32 32 0 0 0 -32 32v224a32 32 0 0 0 32 32h384a32 32 0 0 0 32 -32V160a32 32 0 0 0 -32 -32zm-96 192h64v32h-64v-32z"]},vsDash:{prefix:"vs",iconName:"dash",icon:[512,512,[],"f000","M160 256h192v32H160z"]},vsDashboard:{prefix:"vs",iconName:"dashboard",icon:[512,512,[],"f000","M124.448 67.04a208 208 0 1 1 231.104 345.92A208 208 0 0 1 124.48 67.008zm17.76 319.296A176 176 0 0 0 240 416 176.192 176.192 0 0 0 416 240a176 176 0 1 0 -273.792 146.336zM329.408 128l22.592 22.624 -68.8 68.8a48.448 48.448 0 1 1 -22.624 -22.624L329.376 128zM231.072 253.312a16 16 0 1 0 17.792 -26.624 16 16 0 0 0 -17.792 26.624zm137.152 -78.368l-24.416 24.416c5.312 12.896 8.096 26.688 8.16 40.64a110.816 110.816 0 0 1 -16 56.864l23.52 23.52a143.264 143.264 0 0 0 8.768 -145.44h-0.032zM279.456 135.744A107.936 107.936 0 0 0 240 128 112 112 0 0 0 128 240a110.72 110.72 0 0 0 16 56.864l-23.488 23.52A144 144 0 0 1 304 111.136l-24.544 24.608z"]},vsDatabase:{prefix:"vs",iconName:"database",icon:[512,512,[],"f000","M416 112C416 67.808 344.352 32 256 32S96 67.808 96 112c0 1.28 0.64 2.464 0.768 3.744H96v283.904l1.792 11.424C106.752 449.792 173.728 480 256 480c82.272 0 149.248 -30.208 158.208 -68.928l1.792 -11.424V115.744h-0.768c0.128 -1.28 0.768 -2.464 0.768 -3.744zM256 65.024c78.144 0 128 30.848 128 46.976s-49.856 46.976 -128 46.976S128 128 128 112s49.856 -46.976 128 -46.976zm128 334.656l-0.96 4.192C379.36 419.712 333.792 448 256 448s-123.36 -28.288 -127.04 -44.128L128 399.68v-240A237.248 237.248 0 0 0 256 192a237.248 237.248 0 0 0 128 -32.448v240.128z"]},vsDebugAll:{prefix:"vs",iconName:"debug-all",icon:[512,512,[],"f000","M233.376 288.192l-28.16 28.16A79.488 79.488 0 0 0 128 256a79.616 79.616 0 0 0 -77.216 60.352l-28.16 -28.16L0 310.784l36.704 36.672 -4.704 4.672v32H0v31.968h32v1.696c1.632 10.432 4.576 20.576 8.736 30.272L0 489.408 22.624 512l35.2 -35.168A91.936 91.936 0 0 0 128 512a92 92 0 0 0 70.176 -35.168L233.376 512 256 489.408l-40.736 -41.344A125.44 125.44 0 0 0 224 417.152v-2.144h32v-30.88H224v-32l-4.704 -4.672L256 310.784l-22.624 -22.592zM128 288.192a48 48 0 0 1 48 47.968h-96A47.936 47.936 0 0 1 128 288.192zm64 127.904A70.944 70.944 0 0 1 128 480a71.04 71.04 0 0 1 -64 -63.936v-47.968h128v47.968zM120.96 64L96 77.12V224h32V107.2l243.2 162.24L288 324.8v38.4l120.96 -80.64V256l-288 -192zM288 427.2v-38.464l179.2 -119.296L224 107.2V68.704L504.96 256v26.56L288 427.2z"]},vsDebugAltSmall:{prefix:"vs",iconName:"debug-alt-small",icon:[512,512,[],"f000","M233.376 288.192l-28.16 28.16A79.488 79.488 0 0 0 128 256a79.616 79.616 0 0 0 -77.216 60.352l-28.16 -28.16L0 310.784l36.704 36.672 -4.704 4.672v32H0v31.968h32v1.696c1.632 10.432 4.576 20.576 8.736 30.272L0 489.408 22.624 512l35.2 -35.168A91.936 91.936 0 0 0 128 512a92 92 0 0 0 70.176 -35.168L233.376 512 256 489.408l-40.736 -41.344A125.44 125.44 0 0 0 224 417.152v-2.144h32v-30.88H224v-32l-4.704 -4.672L256 310.784l-22.624 -22.592zM128 288.192a48 48 0 0 1 48 47.968h-96A47.936 47.936 0 0 1 128 288.192zm64 127.904A70.944 70.944 0 0 1 128 480a71.04 71.04 0 0 1 -64 -63.936v-47.968h128v47.968zM160 77.12L184.96 64l288 192v26.56L288 405.856v-38.4l147.2 -98.016L192 107.2V224H160V77.12z"]},vsDebugAlt:{prefix:"vs",iconName:"debug-alt",icon:[512,512,[],"f000","M233.387 288l-28.16 28.16a79.573 79.573 0 0 0 -154.453 0L22.613 288 0 310.613l36.693 36.693 -4.693 4.693V384H0v32h32v1.707c1.643 10.432 4.565 20.608 8.747 30.293L0 489.387 22.613 512l35.2 -35.2A91.904 91.904 0 0 0 128 512a91.947 91.947 0 0 0 70.187 -35.2L233.387 512 256 489.387 215.253 448c4.224 -9.899 7.168 -20.288 8.747 -30.933v-2.133H256V384h-32v-32l-4.693 -4.693L256 310.613l-22.613 -22.613zM128 288a48 48 0 0 1 48 48h-96A48 48 0 0 1 128 288zm64 128a71.04 71.04 0 0 1 -64 64 71.04 71.04 0 0 1 -64 -64v-48h128v48zm314.88 -211.2v26.88L288 370.56V332.8l181.333 -114.56L192 42.667v201.813a108.16 108.16 0 0 0 -32 -15.36V13.44L184.32 0l322.56 204.8z"]},vsDebugBreakpointConditionalUnverified:{prefix:"vs",iconName:"debug-breakpoint-conditional-unverified",icon:[512,512,[],"f000","M184.896 149.568a128 128 0 1 1 142.208 212.864 128 128 0 0 1 -142.208 -212.864zm22.208 179.584a88 88 0 1 0 97.792 -146.304 88 88 0 0 0 -97.792 146.304zM304 208h-96v32h96v-32zm0 64h-96v32h96v-32z"]},vsDebugBreakpointConditional:{prefix:"vs",iconName:"debug-breakpoint-conditional",icon:[512,512,[],"f000","M256 128a128 128 0 1 0 0 256 128 128 0 0 0 0 -256zm64 160v32H192V288h128zm0 -96v32H192V192h128z"]},vsDebugBreakpointDataUnverified:{prefix:"vs",iconName:"debug-breakpoint-data-unverified",icon:[512,512,[],"f000","M317.792 128h-147.84l-73.92 128 73.92 128h147.84l73.92 -128 -73.92 -128zm-24 214.4h-99.84L144.032 256l49.92 -86.4h99.84l49.92 86.4 -49.92 86.4z"]},vsDebugBreakpointData:{prefix:"vs",iconName:"debug-breakpoint-data",icon:[512,512,[],"f000","M391.616 256l-73.92 128H169.92L96 256l73.92 -128h147.776l73.92 128z"]},vsDebugBreakpointFunctionUnverified:{prefix:"vs",iconName:"debug-breakpoint-function-unverified",icon:[512,512,[],"f000","M128 352h256L256 128l-128 224zm68.928 -40h118.144L256 208.64 196.928 312z"]},vsDebugBreakpointFunction:{prefix:"vs",iconName:"debug-breakpoint-function",icon:[512,512,[],"f000","M256 128l128 220.96H128L256 128z"]},vsDebugBreakpointLogUnverified:{prefix:"vs",iconName:"debug-breakpoint-log-unverified",icon:[512,512,[],"f000","M96.64 255.36L256 96l159.36 159.36L256 414.72 96.64 255.36zM256 344.64l89.28 -89.28L256 166.08 166.72 255.36 256 344.64z"]},vsDebugBreakpointLog:{prefix:"vs",iconName:"debug-breakpoint-log",icon:[512,512,[],"f000","M256 96l160 160 -160 160 -160 -160 160 -160z"]},vsDebugBreakpointUnsupported:{prefix:"vs",iconName:"debug-breakpoint-unsupported",icon:[512,512,[],"f000","M362.432 327.104a128 128 0 1 0 -212.896 -142.208 128 128 0 0 0 212.896 142.208zM276.8 320H236.8v32h40v-32zM236.8 288V160h40v128H236.8z"]},vsDebugConsole:{prefix:"vs",iconName:"debug-console",icon:[512,512,[],"f000","M150.187 29.035l2.965 -1.216H454.827l2.987 1.216 25.131 25.152 1.216 2.965V358.827l-1.216 2.987 -25.152 25.131 -2.965 1.216H298.667V384a42.453 42.453 0 0 0 -11.691 -29.333h163.691V61.333H157.333v155.349a122.24 122.24 0 0 0 -33.515 -3.499V57.152l1.216 -2.987L150.187 29.056zm203.328 201.643l-59.925 59.733a42.667 42.667 0 0 0 -7.424 -9.963l-8.939 -8.96 47.701 -47.68 -76.928 -78.805 17.344 -17.771 88.171 88.171v15.275zM205.227 316.16l28.16 -28.16L256 310.613l-36.693 36.693 4.693 4.693V384H256v30.933h-32v2.133a125.611 125.611 0 0 1 -8.747 30.933L256 489.387 233.387 512l-35.2 -35.2A91.904 91.904 0 0 1 128 512a91.947 91.947 0 0 1 -70.187 -35.2L22.613 512 0 489.387 40.747 448a125.632 125.632 0 0 1 -8.747 -30.293v-1.707H0V384h32v-32l4.693 -4.693L0 310.613l22.613 -22.613 28.16 28.16a79.573 79.573 0 0 1 154.453 0zm-43.285 -14.101A48 48 0 0 0 80 336h96a48 48 0 0 0 -14.059 -33.941zm9.579 157.44A71.04 71.04 0 0 0 192 416v-48H64v48a71.04 71.04 0 0 0 64 64 71.04 71.04 0 0 0 43.52 -20.48z"]},vsDebugContinueSmall:{prefix:"vs",iconName:"debug-continue-small",icon:[512,512,[],"f000","M128 64H96v384h32V64zm105.28 18.976L208 96v320l25.28 13.024 224 -160v-26.048l-224 -160zM420.48 256L240 384.896V127.104L420.48 256z"]},vsDebugContinue:{prefix:"vs",iconName:"debug-continue",icon:[512,512,[],"f000","M80 64H128v384H80V64zm157.952 12.48L200 96v320l37.952 19.52 224 -160V236.48l-224 -160zM406.72 256l-158.72 113.376V142.624L406.72 256z"]},vsDebugCoverage:{prefix:"vs",iconName:"debug-coverage",icon:[512,512,[],"f000","M160 77.12L184.96 64l288 192v26.56L288 405.856v-38.4l147.2 -98.016L192 107.2V224H160V77.12zm36.16 310.848c-5.824 5.76 -10.304 12.128 -13.44 19.2a55.808 55.808 0 0 0 -4.64 22.88v27.584a21.92 21.92 0 0 1 -6.56 15.84 22.496 22.496 0 0 1 -15.872 6.528h-27.68a22.112 22.112 0 0 1 -15.904 -6.528 22.432 22.432 0 0 1 -6.56 -15.84v-27.584c0 -8.256 -1.568 -15.872 -4.704 -22.912a61.216 61.216 0 0 0 -13.376 -19.2 80.8 80.8 0 0 1 -17.344 -24.736 72.16 72.16 0 0 1 -6.08 -29.664A76.352 76.352 0 0 1 74.624 294.4a76.928 76.928 0 0 1 27.84 -27.84A79.136 79.136 0 0 1 141.824 256a77.12 77.12 0 0 1 39.2 10.56 77.12 77.12 0 0 1 38.56 66.976c0 10.624 -2.016 20.512 -6.08 29.664a80.8 80.8 0 0 1 -17.344 24.768zm-35.296 31.712H122.72v37.952c0 1.376 0.512 2.56 1.568 3.648 1.056 1.056 2.24 1.536 3.68 1.536h27.68a4.992 4.992 0 0 0 3.648 -1.536 4.928 4.928 0 0 0 1.568 -3.648v-37.952z"]},vsDebugDisconnect:{prefix:"vs",iconName:"debug-disconnect",icon:[512,512,[],"f000","M435.744 123.008a91.84 91.84 0 0 0 -14.432 -27.776l43.328 -43.52L444.928 32l-43.52 43.328a92.064 92.064 0 0 0 -27.776 -14.464 98.336 98.336 0 0 0 -68.48 2.4 96.96 96.96 0 0 0 -31.712 21.248L224 134.144l138.464 138.496 49.664 -49.44c9.184 -9.184 16.256 -19.776 21.216 -31.744a98.368 98.368 0 0 0 2.4 -68.48zm-28.448 57.728a68.8 68.8 0 0 1 -15.072 22.56l-29.76 29.76 -98.88 -98.88 29.76 -29.76a68.8 68.8 0 0 1 22.528 -15.104 68.288 68.288 0 0 1 54.048 0.224c8.448 3.648 15.808 8.672 22.08 15.104 6.4 6.24 11.456 13.632 15.104 22.08a68.288 68.288 0 0 1 0.224 54.016zm-154.368 159.808l47.488 -49.44 -19.712 -19.904 -47.68 49.632 -59.52 -59.488 47.712 -49.664L201.312 192 153.856 241.44l-19.712 -19.68 -49.632 49.44a96 96 0 0 0 -21.216 31.936 96.736 96.736 0 0 0 -7.456 37.408c0 10.624 1.6 20.992 4.8 31.04 3.36 9.92 8.256 19.104 14.688 27.584L32 442.688l19.68 19.68 43.52 -43.296c8.48 6.4 17.664 11.296 27.584 14.656 10.048 3.2 20.416 4.8 31.04 4.8 12.992 0 25.472 -2.464 37.44 -7.424 12.096 -4.96 22.72 -12.032 31.936 -21.216l49.44 -49.664 -19.712 -19.68zm-72.384 64.736a69.12 69.12 0 0 1 -26.688 5.248c-9.632 0 -18.752 -1.824 -27.36 -5.44a72.896 72.896 0 0 1 -22.304 -14.912 72.96 72.96 0 0 1 -14.88 -22.304 69.344 69.344 0 0 1 -5.44 -27.328 69.12 69.12 0 0 1 20.544 -49.44l29.76 -29.76 98.88 98.88 -29.76 29.76a71.04 71.04 0 0 1 -22.752 15.296z"]},vsDebugLineByLine:{prefix:"vs",iconName:"debug-line-by-line",icon:[512,512,[],"f000","M192 320V288h288v32H192zm128 -128h160v32h-160V192zm160 -96v32H192V96h288zm-288 288v32h288v-32H192zM32 89.44l25.056 -13.408 171.872 114.592v26.816l-171.872 114.592L32 318.624V89.44zm32.224 30.08v168.992l126.72 -84.48 -126.72 -84.48z"]},vsDebugPause:{prefix:"vs",iconName:"debug-pause",icon:[512,512,[],"f000","M144 96H192v320H144V96zm224 0v320H320V96h48z"]},vsDebugRerun:{prefix:"vs",iconName:"debug-rerun",icon:[512,512,[],"f000","M229.344 384a96 96 0 0 1 -183.68 39.136l-29.696 12.032A128.032 128.032 0 1 0 32 305.792V266.656H0V352l16 16h74.656v-32H50.176A96 96 0 0 1 229.344 384zM160 77.12L184.96 64l288 192v26.56L320 384.544v-38.4l115.2 -76.704L192 107.2V224H160V77.12z"]},vsDebugRestartFrame:{prefix:"vs",iconName:"debug-restart-frame",icon:[512,512,[],"f000","M32 320V288h166.624a175.36 175.36 0 0 0 -5.92 32H32zm200.224 -96a177.28 177.28 0 0 1 34.56 -32H32v32h200.224zM211.2 416a174.88 174.88 0 0 1 -12.576 -32H32v32h179.2zM480 96v32H32V96h448zm-107.52 320.992a80.992 80.992 0 1 0 -70.144 -121.504h34.176v27.008h-63.04l-13.472 -13.504v-72h27.008v33.024a108 108 0 1 1 -13.536 109.184l25.024 -10.176a81.024 81.024 0 0 0 74.016 48z"]},vsDebugRestart:{prefix:"vs",iconName:"debug-restart",icon:[512,512,[],"f000","M408 256a144 144 0 0 1 -275.52 58.688l-44.512 18.08A192.032 192.032 0 0 0 456 256 192 192 0 0 0 112 138.688V80H64v128l24 24h112v-48H139.264A144 144 0 0 1 408 256z"]},vsDebugReverseContinue:{prefix:"vs",iconName:"debug-reverse-continue",icon:[512,512,[],"f000","M432 64H384v384h48V64zm-157.952 12.48L312 96v320l-37.952 19.52 -224 -160V236.48l224 -160zM105.28 256l158.72 113.376V142.624L105.28 256z"]},vsDebugStackframeActive:{prefix:"vs",iconName:"debug-stackframe-active",icon:[512,512,[],"f000","M320 256a64 64 0 1 1 -128 0 64 64 0 0 1 128 0zm144 -27.2l-136.32 -151.68L297.92 64H136L96 104v303.36l40 40h161.92l29.76 -13.44 136.32 -151.68V228.8zm-166.08 178.56H136V104h161.92l136.32 151.36 -136.32 152z"]},vsDebugStackframeDot:{prefix:"vs",iconName:"debug-stackframe-dot",icon:[512,512,[],"f000","M320 256a64 64 0 1 1 -128 0 64 64 0 0 1 128 0z"]},vsDebugStackframe:{prefix:"vs",iconName:"debug-stackframe",icon:[512,512,[],"f000","M464 228.8l-136.32 -151.68L297.92 64H136L96 104v303.36l40 40h161.92l29.76 -13.44 136.32 -151.68V228.8zm-166.08 178.56H136V104h161.92l136.32 151.36 -136.32 152z"]},vsDebugStart:{prefix:"vs",iconName:"debug-start",icon:[512,512,[],"f000","M136 96l37.312 -19.968 256 170.656v39.936l-256 170.688 -37.312 -19.968V96zm48 44.832v251.648l188.736 -125.824L184 140.832z"]},vsDebugStepBack:{prefix:"vs",iconName:"debug-step-back",icon:[512,512,[],"f000","M56 184v-128h48v81.344c36.64 -43.488 93.152 -70.688 154.88 -70.688 101.664 0 189.44 73.824 197.12 172.736l0.64 8.608h-48l-0.704 -7.232c-6.784 -70.24 -70.464 -126.08 -148.992 -126.08 -55.552 0 -103.808 28 -129.6 69.312h90.56v48H86.624l-30.752 -31.2V184h0.096zM256 448a64 64 0 1 1 0 -128 64 64 0 0 1 0 128z"]},vsDebugStepInto:{prefix:"vs",iconName:"debug-step-into",icon:[512,512,[],"f000","M256 305.024h17.344l124.96 -124.96 -33.952 -33.92 -84.384 83.52V32H232.032v197.664l-84.384 -83.52 -33.952 33.92 124.96 124.96H256zm62.592 111.392a64 64 0 1 1 -128 0 64 64 0 0 1 128 0z"]},vsDebugStepOut:{prefix:"vs",iconName:"debug-step-out",icon:[512,512,[],"f000","M256 32h-17.344L113.696 156.96l33.952 33.92 84.384 -83.52v197.664h47.936V107.36l84.384 83.52 33.952 -33.92L273.344 32H256zm62.592 384.416a64 64 0 1 1 -128 0 64 64 0 0 1 128 0z"]},vsDebugStepOver:{prefix:"vs",iconName:"debug-step-over",icon:[512,512,[],"f000","M456 184v-128h-48v81.344c-36.64 -43.488 -93.152 -70.688 -154.88 -70.688 -101.664 0 -189.44 73.824 -197.12 172.736l-0.64 8.608h48.032l0.704 -7.232c6.784 -70.24 70.464 -126.08 148.992 -126.08 55.552 0 103.808 28 129.6 69.312h-90.56v48h133.216l30.784 -31.2V184h-0.128zM256 448a64 64 0 1 0 0 -128 64 64 0 0 0 0 128z"]},vsDebugStop:{prefix:"vs",iconName:"debug-stop",icon:[512,512,[],"f000","M64 64v384h384V64H64zm344 344h-304v-304h304v304z"]},vsDebug:{prefix:"vs",iconName:"debug",icon:[512,512,[],"f000","M73.877 274.347l-0.107 -1.493 0.107 1.493zm154.965 14.72l-64.725 -65.045 21.632 -21.632 68.459 68.8 67.477 -67.477 21.632 21.632 -64.725 64.725 64.725 65.067 -21.632 21.632 -68.459 -68.8L185.749 375.467l-21.632 -21.632 64.725 -64.725zm132.395 -182.336V128h28.693l60.651 -60.629 21.632 21.632 -57.429 57.408 0.704 1.813a293.333 293.333 0 0 1 18.88 104.789c0 7.147 -0.235 14.229 -0.725 21.227l-0.107 1.6h75.52v30.592h-79.36l-0.213 1.237c-6.464 35.264 -19.008 67.413 -36.096 94.485l-1.28 2.005 73.024 73.387 -21.696 21.589 -69.845 -70.187 -2.112 2.347c-31.552 35.285 -72.427 56.448 -116.971 56.448 -45.227 0 -86.677 -21.824 -118.443 -58.091l-2.091 -2.411 -68.459 68.437 -21.632 -21.632 71.808 -71.787 -1.259 -2.027c-16.469 -26.667 -28.587 -58.133 -34.901 -92.587l-0.213 -1.216H0V275.84h75.477l-0.107 -1.6a303.573 303.573 0 0 1 -0.725 -21.227c0 -37.184 6.613 -72.32 18.411 -103.552l0.683 -1.792 -58.923 -59.221L56.533 66.88 117.333 128h30.443v-21.269a106.731 106.731 0 0 1 213.461 0zm-182.869 0V128H330.667v-21.269a76.139 76.139 0 0 0 -152.277 0zm209.067 53.803l-0.725 -1.92H122.304l-0.725 1.92a262.997 262.997 0 0 0 -16.341 92.48c0 58.88 18.389 110.955 46.592 147.627 28.16 36.608 64.768 56.512 102.677 56.512 37.909 0 74.496 -19.904 102.677 -56.533 28.203 -36.651 46.592 -88.747 46.592 -147.605 0 -33.579 -5.973 -64.939 -16.341 -92.48z"]},vsDesktopDownload:{prefix:"vs",iconName:"desktop-download",icon:[512,512,[],"f000","M128 480v-32c64 0 64 -19.2 64 -32H48l-16 -16v-320l16 -16h416l16 16v295.68l-32 -32V96H64v288h183.36l-16 16 80 80H128zm251.52 0l80 -80 -22.72 -22.4L384 430.4V224h-32v206.08l-52.48 -52.8 -22.72 22.72 80 80h22.72z"]},vsDeviceCameraVideo:{prefix:"vs",iconName:"device-camera-video",icon:[512,512,[],"f000","M456 151.68L352 211.84V144l-16 -16h-288l-16 16v224l16 16h288l16 -16v-64l104 59.84 24 -15.04V165.76l-24 -14.08zM320 352H64V160h256v192zm128 -32l-96 -54.4v-16.64L448 192v128z"]},vsDeviceCamera:ut,vsDeviceMobile:{prefix:"vs",iconName:"device-mobile",icon:[512,512,[],"f000","M144 32h256l16 16v416l-16 16h-256l-16 -16v-416l16 -16zM160 448h224V64H160v384zm80 -64h64v32h-64v-32z"]},vsDiffAdded:{prefix:"vs",iconName:"diff-added",icon:[512,512,[],"f000","M48 32h384l16 16v384l-16 16h-384l-16 -16v-384l16 -16zM64 416h352V64H64v352zm192 -288H224v96H128v32h96v96h32V256h96V224H256V128z"]},vsDiffIgnored:{prefix:"vs",iconName:"diff-ignored",icon:[512,512,[],"f000","M48 32h416l16 16v416l-16 16h-416l-16 -16v-416l16 -16zM64 448h384V64H64v384zm256 -320h64v64l-192 192H128v-64l192 -192z"]},vsDiffModified:{prefix:"vs",iconName:"diff-modified",icon:[512,512,[],"f000","M48 32h416l16 16v416l-16 16h-416l-16 -16v-416l16 -16zM64 64v384h384V64H64zm192 288a96 96 0 1 0 0 -192 96 96 0 0 0 0 192z"]},vsDiffRemoved:{prefix:"vs",iconName:"diff-removed",icon:[512,512,[],"f000","M320 224v32H160V224h160zM48 32h384l16 16v384l-16 16h-384l-16 -16v-384l16 -16zM64 416h352V64H64v352z"]},vsDiffRenamed:{prefix:"vs",iconName:"diff-renamed",icon:[512,512,[],"f000","M48 32h416l16 16v416l-16 16h-416l-16 -16v-416l16 -16zM64 448h384V64H64v384zm64 -160h96v96l160 -128 -160 -128v96H128v64z"]},vsDiff:{prefix:"vs",iconName:"diff",icon:[512,512,[],"f000","M64 112l16 -16h160l16 16v288l-16 16h-160l-16 -16v-288zM96 384h128V192H96v192zm0 -224h128V128H96v32zm208 -64h160l16 16v288l-16 16h-160l-16 -16v-288l16 -16zm16 288h128v-64h-128v64zm0 -128h128V128h-128v128z"]},vsDiscard:{prefix:"vs",iconName:"discard",icon:[512,512,[],"f000","M112 64v112L128 192h112V160H159.328l30.112 -30.112a113.664 113.664 0 1 1 160.736 160.736L183.872 456.96l23.04 23.04 166.336 -166.336A146.24 146.24 0 0 0 166.4 106.848l-22.4 22.4V64h-32z"]},vsEdit:mt,vsEditorLayout:{prefix:"vs",iconName:"editor-layout",icon:[512,512,[],"f000","M480 208l-15.04 -16H224V47.04L208.96 32H47.04L32 47.04v257.92l15.04 15.04H128v144.96l15.04 15.04h321.92l15.04 -15.04V208zM64 288V96h128v192H64zm384 160H160v-128h48.96L224 304.96V256.416h224V448z"]},vsEllipsis:{prefix:"vs",iconName:"ellipsis",icon:[512,512,[],"f000","M128 256a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zm160 0a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zm160 0a32 32 0 1 1 -64 0 32 32 0 0 1 64 0z"]},vsEmptyWindow:{prefix:"vs",iconName:"empty-window",icon:[512,512,[],"f000","M128 128h96v32H128v96H96V160H0V128h96V32h32v96zM32 464V288h32v160h384V224H256V192h192V128H256V96h208l16 16v352l-16 16h-416l-16 -16z"]},vsError:{prefix:"vs",iconName:"error",icon:[512,512,[],"f000","M275.2 32c51.2 3.2 99.2 28.8 134.4 64 41.6 44.8 64 99.2 64 163.2 0 51.2 -19.2 99.2 -51.2 140.8 -32 38.4 -76.8 67.2 -128 76.8 -51.2 9.6 -102.4 3.2 -147.2 -22.4 -44.8 -25.6 -80 -64 -99.2 -112C28.8 294.4 25.6 240 41.6 192c16 -51.2 44.8 -92.8 89.6 -121.6C172.8 41.6 224 28.8 275.2 32zm16 412.8c41.6 -9.6 80 -32 108.8 -67.2 25.6 -35.2 41.6 -76.8 38.4 -121.6 0 -51.2 -19.2 -102.4 -54.4 -137.6 -32 -32 -70.4 -51.2 -115.2 -54.4 -41.6 -3.2 -86.4 6.4 -121.6 32 -35.2 25.6 -60.8 60.8 -73.6 105.6 -12.8 41.6 -12.8 86.4 6.4 128 19.2 41.6 48 73.6 86.4 96 38.4 22.4 83.2 28.8 124.8 19.2zM252.8 240L329.6 160l22.4 22.4 -76.8 80 76.8 80 -22.4 22.4 -76.8 -80 -76.8 80 -22.4 -22.4 76.8 -80 -76.8 -80 22.4 -22.4 76.8 80z"]},vsExclude:{prefix:"vs",iconName:"exclude",icon:[512,512,[],"f000","M301.184 32H210.816l-15.488 77.536 -65.792 -43.84 -63.872 63.84 43.84 65.792L32 210.816v90.368l77.536 15.488 -43.84 65.792 63.84 63.872 65.792 -43.84L210.816 480h66.656a144.832 144.832 0 0 1 -29.344 -32.16h-10.944l-9.216 -46.112a143.136 143.136 0 0 1 -2.144 -10.688l-3.712 -18.656 -24.448 -10.112 -64 42.688 -26.624 -26.592L149.76 314.336l-10.112 -24.448 -75.456 -15.072V237.184l75.456 -15.072 10.112 -24.448 -42.688 -64 26.592 -26.624 64 42.72 24.448 -10.112 15.072 -75.456h37.632l15.072 75.456 24.448 10.112 64 -42.688 26.624 26.592 -42.688 64.032 10.112 24.448 18.624 3.712c3.616 0.576 7.2 1.28 10.72 2.144l46.112 9.216v10.944c12.16 8.128 23.008 18.016 32.16 29.344V210.816l-77.504 -15.488 43.84 -65.792 -63.872 -63.872 -65.792 43.84L301.184 32zM256 192a64 64 0 0 1 60 41.664 142.72 142.72 0 0 0 -28.8 15.136 32 32 0 1 0 -38.4 38.4 142.72 142.72 0 0 0 -15.136 28.8A64 64 0 0 1 256 192zm40.96 89.44a112 112 0 1 1 142.08 173.12 112 112 0 0 1 -142.08 -173.12zM288 352v32h160v-32H288z"]},vsExpandAll:{prefix:"vs",iconName:"expand-all",icon:[512,512,[],"f000","M288 288H128v32h160V288zm-64 96V224H192v160h32zM160 96l32 -32h224l32 32v224l-32 32h-64v64l-32 32H96l-32 -32V192l32 -32h64V96zm32 64h128l32 32v128h64V96H192v64zm128 32H96v224h224V192z"]},vsExport:{prefix:"vs",iconName:"export",icon:[512,512,[],"f000","M418.752 224l-76.48 -76.736 22.464 -22.528L480 240l-115.264 115.264 -22.496 -22.528 76.256 -76.224V256H96V224h322.752zM32 128h32v224H32V128z"]},vsExtensions:{prefix:"vs",iconName:"extensions",icon:[512,512,[],"f000","M288 32L320 0h160L512 32V192l-32 32H320L288 192V32zm32 0V192h160V32H320zM0 320V128l32 -32H192L224 128v160H384l32 32v160L384 512H32L0 480V320zm192 -32V128H32v160H192zM192 320H32v160H192V320zm32 160H384V320h-160v160z"]},vsEyeClosed:{prefix:"vs",iconName:"eye-closed",icon:[512,512,[],"f000","M256 64c-48 0 -89.6 12.8 -124.8 38.4l25.6 22.4C185.6 105.6 217.6 96 256 96c105.6 0 192 86.4 192 192h32c0 -124.8 -99.2 -224 -224 -224zM32 96l51.2 48C51.2 182.4 32 233.6 32 288h32c0 -48 16 -89.6 44.8 -121.6l70.4 64C166.4 246.4 160 265.6 160 288c0 54.4 41.6 96 96 96 25.6 0 48 -9.6 64 -25.6l96 89.6 22.4 -22.4 -384 -352L32 96zm169.6 156.8l92.8 86.4c-9.6 6.4 -22.4 12.8 -38.4 12.8 -35.2 0 -64 -28.8 -64 -64 0 -12.8 3.2 -25.6 9.6 -35.2zM352 304l-32 -28.8c-6.4 -25.6 -28.8 -48 -57.6 -51.2l-32 -28.8c9.6 -3.2 16 -3.2 25.6 -3.2 54.4 0 96 41.6 96 96v16z"]},vsEye:{prefix:"vs",iconName:"eye",icon:[512,512,[],"f000","M32 320c0 -124.8 99.2 -224 224 -224s224 99.2 224 224h-32c0 -105.6 -86.4 -192 -192 -192s-192 86.4 -192 192H32zm128 0c0 -54.4 41.6 -96 96 -96s96 41.6 96 96 -41.6 96 -96 96 -96 -41.6 -96 -96zm32 0c0 35.2 28.8 64 64 64s64 -28.8 64 -64 -28.8 -64 -64 -64 -64 28.8 -64 64z"]},vsFeedback:{prefix:"vs",iconName:"feedback",icon:[512,512,[],"f000","M241.568 322.496c14.72 5.824 28.16 13.568 40.256 23.2 12.096 9.6 22.432 20.8 31.04 33.472a154.528 154.528 0 0 1 27.136 86.848V480H312v-14.016a124.608 124.608 0 0 0 -36.96 -89.024 129.728 129.728 0 0 0 -40.032 -26.88 124.736 124.736 0 0 0 -49.024 -10.08A124.608 124.608 0 0 0 96.96 376.96a129.92 129.92 0 0 0 -26.88 40.032c-6.592 15.168 -9.92 31.52 -10.08 48.992V480H32v-14.016a151.168 151.168 0 0 1 27.136 -86.816 157.376 157.376 0 0 1 71.328 -56.64 95.808 95.808 0 0 1 -17.76 -15.776 100.992 100.992 0 0 1 -13.344 -19.264 94.144 94.144 0 0 1 -8.32 -21.856 107.04 107.04 0 0 1 -3.04 -23.648c0 -13.536 2.56 -26.24 7.68 -38.048a99.04 99.04 0 0 1 52.032 -52.064 98.144 98.144 0 0 1 76.352 -0.224 99.04 99.04 0 0 1 52.064 52.064 98.144 98.144 0 0 1 5.024 61.696c-1.92 7.584 -4.736 14.88 -8.512 21.888a112.192 112.192 0 0 1 -13.344 19.456c-5.12 5.984 -11.04 11.2 -17.728 15.744zM185.984 312c9.632 0 18.688 -1.824 27.136 -5.44a70.208 70.208 0 0 0 37.184 -37.216c3.808 -8.608 5.696 -17.728 5.696 -27.328a68.416 68.416 0 0 0 -20.576 -49.216 76.256 76.256 0 0 0 -22.304 -15.104 65.536 65.536 0 0 0 -27.136 -5.696c-9.6 0 -18.656 1.824 -27.104 5.44a70.976 70.976 0 0 0 -37.44 37.44c-3.616 8.448 -5.44 17.504 -5.44 27.136 0 9.6 1.824 18.656 5.44 27.104 3.68 8.448 8.64 15.904 14.912 22.304a69.376 69.376 0 0 0 49.664 20.576zM480 32v224h-56l-84 84V256H312v-28h56v44.416l44.416 -44.416h39.584v-168h-280v50.304a232.16 232.16 0 0 0 -14.016 2.208 83.84 83.84 0 0 0 -13.984 3.936V32H480z"]},vsFileBinary:{prefix:"vs",iconName:"file-binary",icon:[512,512,[],"f000","M338.24 36.48l104.96 105.6 4.8 11.52v310.4l-16 16h-352l-16 -16v-416l16 -16h247.04l11.2 4.48zM96 64v384h320V160l-96 -96H96zm46.72 129.664c0 41.184 14.656 61.76 43.968 61.76 14.624 0 25.824 -5.536 33.6 -16.64 7.872 -11.136 11.776 -27.104 11.776 -47.968C232.064 148.928 217.76 128 189.12 128c-15.072 0 -26.592 5.6 -34.56 16.832 -7.904 11.2 -11.84 27.456 -11.84 48.832zm27.584 -0.704c0 -29.504 5.856 -44.256 17.6 -44.256 11.008 0 16.512 14.336 16.512 42.976s-5.632 42.976 -16.864 42.976c-11.52 0 -17.28 -13.888 -17.28 -41.696zm101.984 60.352h77.92v-21.504h-25.344V128l-53.28 10.752v21.984l26.24 -5.664v76.736h-25.536v21.504zm-42.784 160H151.552v-21.504h25.536V315.072l-26.24 5.664v-21.984L204.16 288v103.808h25.344v21.472zm33.12 -61.792c0 41.184 14.656 61.76 44 61.76 14.624 0 25.824 -5.536 33.6 -16.64 7.84 -11.136 11.776 -27.104 11.776 -47.968 0 -41.888 -14.336 -62.816 -42.976 -62.816 -15.04 0 -26.56 5.6 -34.56 16.832 -7.872 11.2 -11.84 27.456 -11.84 48.832zm27.584 -0.704c0 -29.504 5.888 -44.256 17.6 -44.256 11.008 0 16.512 14.336 16.512 42.976s-5.6 42.976 -16.832 42.976c-11.52 0 -17.28 -13.888 -17.28 -41.696z"]},vsFileCode:pt,vsFileMedia:{prefix:"vs",iconName:"file-media",icon:[512,512,[],"f000","M64 64h192v112l16 16H384v32h32V153.6l-4.8 -11.52 -104.96 -105.6L295.04 32H48l-16 16v416l16 16H160v-32H64V64zm224 0l96 96H288V64zm176 192h-256l-16 16v192l16 16h256l16 -16v-192l-16 -16zM448 288v128l-52.16 -51.2h-22.72l-37.12 37.44 -68.16 -68.16h-22.72L224 355.2V288h224zm-89.6 136.64l25.92 -25.92L433.6 448h-51.84l-23.36 -23.36zM224 448v-47.68l32 -32L336.64 448H224zm176 -112a16 16 0 1 0 0 -32 16 16 0 0 0 0 32z"]},vsFilePdf:{prefix:"vs",iconName:"file-pdf",icon:[512,512,[],"f000","M443.2 142.08l-104.96 -105.6 -11.2 -4.48H80l-16 16V224h32V64h192v112l16 16H416v32h32V153.6l-4.8 -11.52zM320 160V64l96 96h-96zM80 256l-16 16v192l16 16h352l16 -16v-192l-16 -16h-352zM416 416v32H96V288h320v128zm-256 -32h-10.24v32H128v-96h33.92c24 0 36.16 11.52 36.16 32a30.08 30.08 0 0 1 -10.24 23.04A42.56 42.56 0 0 1 160 384zm-1.92 -46.4h-8.32v29.76h8.32c11.52 0 17.28 -5.12 17.28 -15.04 0 -9.92 -5.76 -14.72 -17.28 -14.72zM288 402.56a47.36 47.36 0 0 0 14.08 -35.84c0 -32 -16.96 -46.72 -51.2 -46.72H216.96v96h33.92A51.2 51.2 0 0 0 288 402.56zm-49.6 -4.16v-60.8h10.56a30.08 30.08 0 0 1 22.4 8 29.12 29.12 0 0 1 8 21.44 32 32 0 0 1 -8 23.04 30.08 30.08 0 0 1 -22.08 8.32h-10.88zm142.4 -19.52h-31.04V416h-21.76v-96h55.68v17.6h-33.92v23.68h31.04v17.6z"]},vsFileSubmodule:{prefix:"vs",iconName:"file-submodule",icon:[512,512,[],"f000","M64 352h32V223.68H64V352zm32 -160.32V176l16 -16h141.76l13.76 8 13.76 24h182.72l16 16v256l-16 16h-352l-16 -16V384H48l-16 -16v-288l16 -16h141.44l14.08 8 13.76 24h182.72l16 16V192l-32 -0.96V128H208l-13.76 -8L180.48 96H64v95.68h32zm162.24 24.32L244.48 192H128v96h100.8l13.12 -23.68L256 256h192V224H272l-13.76 -8zM238.4 320H128v128h320V288H265.6l-13.12 23.68 -14.08 8.32z"]},vsFileSymlinkDirectory:{prefix:"vs",iconName:"file-symlink-directory",icon:[512,512,[],"f000","M246.72 96h217.28l16.32 16v320l-16 16h-416l-16 -16v-352l16 -16h160l11.2 4.8 27.2 27.2zm200.96 320v-48.32l0.32 -128v-48H246.4l-27.52 27.52 -11.2 4.8H64v192h383.68zm-208 -256h208l0.32 -31.68H240l-11.52 -4.8 -27.2 -27.2H64v96h136.96l27.52 -27.52 11.2 -4.8zm73.28 130.24L269.44 246.4l23.68 -22.08 71.04 71.04v22.72l-73.28 70.72 -22.4 -23.04 44.8 -43.2H269.44a64 64 0 0 0 -43.2 19.52A57.6 57.6 0 0 0 209.28 384h-32a88.32 88.32 0 0 1 25.92 -64 96 96 0 0 1 64 -29.76h45.76z"]},vsFileSymlinkFile:{prefix:"vs",iconName:"file-symlink-file",icon:[512,512,[],"f000","M338.24 36.48l104.96 105.6 4.8 11.52v310.4l-16 16H320v-32h96V192H304L288 176V64H96v128H64V48l16 -16h247.04l11.2 4.48zM320 160h96l-96 -96v96zM272 224h-224l-16 16v224l16 16h224l16 -16v-224L272 224zM256 448H64V256h192v192zM224 304v96H192v-57.376l-84.672 84.704 -22.656 -22.656L169.376 320H112.96V288H208l16 16z"]},vsFileZip:gt,vsFile:vt,vsFiles:ft,vsFilterFilled:{prefix:"vs",iconName:"filter-filled",icon:[512,512,[],"f000","M480 64v53.44l-160 152.288V448H192V269.728l-160 -152.32V64h448z"]},vsFilter:bt,vsFlame:{prefix:"vs",iconName:"flame",icon:[512,512,[],"f000","M292.16 480l-16.96 -24.64a59.2 59.2 0 0 0 -8.96 -81.28 112.32 112.32 0 0 1 -38.08 -64c-49.92 71.36 -24 110.72 0 145.6l-17.6 24.32A140.8 140.8 0 0 1 96 334.72S89.28 265.6 168.96 198.08c0 0 90.24 -83.52 58.88 -145.28L250.56 32a210.24 210.24 0 0 1 83.52 222.08 82.24 82.24 0 0 0 17.92 -25.92l27.84 -2.24c2.24 3.84 58.88 93.76 28.48 169.6A151.04 151.04 0 0 1 292.16 480zm-64 -222.4l27.84 12.48a96 96 0 0 0 29.44 79.36 84.48 84.48 0 0 1 32 89.6A103.712 103.712 0 0 0 377.6 384a155.84 155.84 0 0 0 -13.12 -116.16 59.2 59.2 0 0 1 -58.88 27.52l-11.2 -21.76a169.92 169.92 0 0 0 -28.48 -185.6C261.44 155.84 192 218.56 189.76 222.08 123.52 278.4 128 330.56 128 332.8a111.04 111.04 0 0 0 50.88 100.48C160 388.48 160 334.72 229.12 257.6h-0.96z"]},vsFoldDown:{prefix:"vs",iconName:"fold-down",icon:[512,512,[],"f000","M454.624 54.624L432 32l-192 192 -192 -192 -22.624 22.624 203.296 203.328h22.656l203.296 -203.328zm0 192L432 224l-192 192 -192 -192 -22.624 22.624 203.296 203.328h22.656l203.296 -203.328z"]},vsFoldUp:{prefix:"vs",iconName:"fold-up",icon:[512,512,[],"f000","M32 236.8l22.4 22.4 192 -192 192 192 22.4 -22.4L259.2 32h-22.4L32 236.8zm0 192l22.4 22.4 192 -192 192 192 22.4 -22.4L259.2 224h-22.4L32 428.8z"]},vsFold:{prefix:"vs",iconName:"fold",icon:[512,512,[],"f000","M382.464 76.192L255.232 203.424 128 76.192 108.16 96l137.152 137.12h19.808L402.24 96l-19.776 -19.808zM124.928 448l130.304 -130.304L385.504 448l19.84 -19.808L265.088 288h-19.808l-140.192 140.192 19.808 19.808z"]},vsFolderActive:{prefix:"vs",iconName:"folder-active",icon:[512,512,[],"f000","M246.72 96h217.28l16.32 16v144.224A159.904 159.904 0 0 0 448 237.312V191.68H246.08l-27.52 27.52 -11.2 4.8H63.68v192H227.2c2.24 11.136 5.664 21.824 10.112 32H48.32l-16 -16v-352l16 -16h160l11.2 4.8 27.2 27.2zm-7.04 64h208l0.32 -31.68H240l-11.52 -4.8 -27.2 -27.2H64v96h136.96l27.52 -27.52 11.2 -4.8zm73.216 117.568a128 128 0 1 1 142.208 212.864 128 128 0 0 1 -142.208 -212.864zm68.16 159.68l76.384 -101.824 -25.6 -19.2 -66.464 88.608 -41.632 -33.312 -20 24.96 54.528 43.648 22.816 -2.88z"]},vsFolderLibrary:{prefix:"vs",iconName:"folder-library",icon:[512,512,[],"f000","M246.72 96h217.28l16.32 16V224H448V191.68H246.08l-27.52 27.52 -11.2 4.8H63.68v192H224v32H48.32l-16 -16v-352l16 -16h160l11.2 4.8 27.2 27.2zm-7.04 64h208l0.32 -31.68H240l-11.52 -4.8 -27.2 -27.2H64v96h136.96l27.52 -27.52 11.2 -4.8zM256 256h32v192H256zm64 0h32v192h-32zm64.128 11.264l30.08 -10.944 65.664 180.416 -30.08 10.944z"]},vsFolderOpened:Ct,vsFolder:St,vsGear:Et,vsGift:{prefix:"vs",iconName:"gift",icon:[512,512,[],"f000","M432 128h-51.2c3.2 -12.8 3.2 -25.6 3.2 -38.4 -3.2 -9.6 -6.4 -19.2 -12.8 -28.8 -6.4 -9.6 -12.8 -16 -22.4 -19.2 -9.6 -3.2 -19.2 -9.6 -28.8 -9.6 -9.6 0 -19.2 0 -28.8 6.4 -22.4 6.4 -38.4 22.4 -51.2 41.6 -12.8 -19.2 -28.8 -35.2 -51.2 -41.6 -9.6 -3.2 -19.2 -6.4 -28.8 -6.4 -9.6 0 -19.2 3.2 -28.8 9.6 -9.6 3.2 -16 9.6 -22.4 19.2 -6.4 6.4 -9.6 19.2 -12.8 28.8 0 12.8 0 25.6 3.2 38.4H48l-16 16v288l16 16h384l16 -16v-288l-16 -16zM224 416H64V160h160v256zm0 -288H128v-6.4c-3.2 -9.6 -3.2 -16 -3.2 -25.6 3.2 -6.4 3.2 -12.8 9.6 -16 3.2 -6.4 9.6 -9.6 16 -12.8 3.2 -3.2 9.6 -3.2 16 -3.2s12.8 0 19.2 3.2c9.6 3.2 19.2 9.6 25.6 19.2 6.4 9.6 12.8 19.2 12.8 32V128zm32 -9.6c0 -12.8 6.4 -22.4 12.8 -32 6.4 -9.6 16 -16 25.6 -19.2 6.4 -3.2 12.8 -3.2 19.2 -3.2 6.4 0 12.8 0 19.2 3.2 6.4 3.2 9.6 6.4 16 12.8 3.2 3.2 3.2 9.6 6.4 16 0 9.6 0 16 -3.2 25.6 0 3.2 0 3.2 -3.2 6.4H256v-9.6zm160 297.6H256V160h160v256z"]},vsGistSecret:{prefix:"vs",iconName:"gist-secret",icon:[512,512,[],"f000","M96 448h128v29.12l2.88 2.88H80l-16 -16v-416l16 -16h247.04l11.2 4.48 104.96 105.6 4.8 11.52v81.28a99.2 99.2 0 0 0 -32 -30.08V192H304L288 176V64H96v384zm320 -288l-96 -96v96h96zm16 128v32h32l16 16v128l-16 16h-192l-16 -16v-128l16 -16h32V288a64 64 0 0 1 128 0zm-86.624 -22.624A32 32 0 0 0 336 288v32h64V288a32 32 0 0 0 -54.624 -22.624zM288 352v96h160v-96H288z"]},vsGist:{prefix:"vs",iconName:"gist",icon:[512,512,[],"f000","M338.24 36.48l104.96 105.6 4.8 11.52v310.4l-16 16h-352l-16 -16v-416l16 -16h247.04l11.2 4.48zM320 160h96l-96 -96v96zM96 64v384h320V192H304L288 176V64H96zm65.984 241.056l58.144 -58.496L197.44 224 128 293.728v22.624l69.472 69.568 22.624 -22.624 -58.112 -58.24zM281.6 246.848l22.4 -22.688 70.048 69.6v22.688L304 385.984l-22.56 -22.688 58.592 -58.24L281.6 246.848z"]},vsGitCommit:{prefix:"vs",iconName:"git-commit",icon:[512,512,[],"f000","M351.328 160a109.44 109.44 0 0 0 -64 -32V0h-32v128a112 112 0 0 0 -5.76 220.48h5.76v128h32v-128a98.56 98.56 0 0 0 26.88 -7.36 109.44 109.44 0 0 0 50.24 -41.28 110.72 110.72 0 0 0 -13.12 -139.84zm-22.4 135.68a80.32 80.32 0 0 1 -101.088 9.92 80 80 0 0 1 -29.44 -35.84 79.68 79.68 0 0 1 58.24 -109.12 87.04 87.04 0 0 1 15.68 0 80 80 0 0 1 81.28 80 80.32 80.32 0 0 1 -25.6 56l0.96 -0.96z"]},vsGitCompare:{prefix:"vs",iconName:"git-compare",icon:[512,512,[],"f000","M236.448 415.68l-40.64 -40.64 21.44 -22.4 68.16 68.16v22.4l-68.16 68.16 -22.72 -22.72L235.168 448h-59.2a79.68 79.68 0 0 1 -80 -80V190.4a82.88 82.88 0 0 1 -40.64 -21.76 80.64 80.64 0 0 1 -17.28 -87.36A80 80 0 0 1 111.968 32a78.4 78.4 0 0 1 32 6.08 79.36 79.36 0 0 1 43.2 43.2c4.256 10.144 6.304 21.056 6.08 32a80 80 0 0 1 -64 78.4v176a48 48 0 0 0 48 48h59.2zm-149.76 -264a48 48 0 0 0 66.56 -66.56 49.6 49.6 0 0 0 -21.76 -17.92 47.68 47.68 0 0 0 -27.52 -2.56 47.68 47.68 0 0 0 -37.76 37.76 47.68 47.68 0 0 0 2.56 27.52c3.744 8.864 9.952 16.416 17.92 21.76zm330.56 201.6c15.36 3.136 29.504 10.72 40.64 21.76a80.32 80.32 0 0 1 9.92 101.088 80 80 0 1 1 -111.04 -110.976c8.608 -5.824 18.272 -9.856 28.48 -11.84V175.68a48 48 0 0 0 -48 -48h-59.2l40.64 40.64 -22.72 22.72 -68.16 -68.16v-22.4l68.16 -68.16 22.72 22.72 -40.64 40.64h59.2a79.68 79.68 0 0 1 80 80v177.6zm-11.232 126.176a48 48 0 0 0 35.2 -74.304 49.6 49.6 0 0 0 -21.76 -17.92 47.68 47.68 0 0 0 -27.488 -2.56 47.68 47.68 0 0 0 -37.76 37.76 47.68 47.68 0 0 0 2.56 27.52 48 48 0 0 0 49.248 29.504z"]},vsGitMerge:{prefix:"vs",iconName:"git-merge",icon:[512,512,[],"f000","M424.736 247.36a80.32 80.32 0 0 0 -101.088 -9.92 80 80 0 0 0 -29.472 35.84 71.36 71.36 0 0 0 -4.16 14.08 144.64 144.64 0 0 1 -128 -128 71.36 71.36 0 0 0 14.08 -4.16 80 80 0 0 0 49.28 -73.92 78.4 78.4 0 0 0 -6.08 -32A79.36 79.36 0 0 0 176.096 6.08a78.4 78.4 0 0 0 -32 -6.08 80 80 0 0 0 -73.92 49.28 80.64 80.64 0 0 0 17.28 87.36c11.2 10.976 25.28 18.528 40.64 21.76v163.2a77.152 77.152 0 0 0 -28.48 11.84 80 80 0 1 0 111.04 110.976 80 80 0 0 0 13.44 -44.384 78.4 78.4 0 0 0 -6.08 -32 79.36 79.36 0 0 0 -57.92 -47.68v-76.8a176.64 176.64 0 0 0 64 55.36 180.8 180.8 0 0 0 66.88 19.2 80 80 0 0 0 158.4 -15.68 80.32 80.32 0 0 0 -24.64 -55.04zm-262.4 108.16c8.832 3.744 16.384 9.984 21.76 17.92a48 48 0 0 1 -66.56 66.56 49.6 49.6 0 0 1 -17.92 -21.76 47.68 47.68 0 0 1 -2.56 -27.52 47.68 47.68 0 0 1 37.76 -37.76 47.68 47.68 0 0 1 27.52 2.56zM144.096 128a48 48 0 0 1 -44.48 -29.76 47.68 47.68 0 0 1 -2.56 -27.52 47.68 47.68 0 0 1 37.76 -37.76 47.68 47.68 0 0 1 27.52 2.56A48 48 0 0 1 144.096 128zm257.92 209.92a48 48 0 0 1 -78.4 -15.68 47.68 47.68 0 0 1 -2.56 -27.52 47.68 47.68 0 0 1 37.76 -37.76 47.68 47.68 0 0 1 27.52 2.56 47.968 47.968 0 0 1 15.68 78.4z"]},vsGitPullRequestClosed:{prefix:"vs",iconName:"git-pull-request-closed",icon:[512,512,[],"f000","M179.712 157.696a79.584 79.584 0 0 1 -35.808 29.504c-4.736 1.92 -14.656 4.416 -14.656 4.416v160.256a80.32 80.32 0 0 1 50.528 33.984c8.736 13.184 13.408 28.64 13.408 44.416 0.256 10.976 -1.824 21.888 -6.08 32A79.52 79.52 0 0 1 112 511.488a79.36 79.36 0 0 1 -44.416 -13.44A79.552 79.552 0 0 1 33.6 416c3.04 -15.552 10.592 -29.824 21.76 -41.056 11.168 -10.976 25.28 -18.528 40.608 -21.76V190.368a83.2 83.2 0 0 1 -40.608 -21.76 80.096 80.096 0 0 1 -21.76 -41.056 79.584 79.584 0 0 1 33.92 -82.08A79.68 79.68 0 0 1 112 32a80.128 80.128 0 0 1 57.824 23.328 79.776 79.776 0 0 1 23.328 57.92c0.064 15.808 -4.608 31.264 -13.44 44.448zm-24.192 251.552a48 48 0 0 0 -17.664 -18.528 46.4 46.4 0 0 0 -24.64 -6.72 47.84 47.84 0 0 0 -47.04 57.28 47.776 47.776 0 0 0 37.76 37.728c9.216 1.856 18.752 0.96 27.52 -2.56 8.832 -3.744 16.384 -9.984 21.76 -17.92 4.8 -7.232 7.52 -15.68 7.968 -24.32a48.32 48.32 0 0 0 -5.664 -24.96zM86.656 151.712c7.904 5.152 17.152 8 26.56 8 8.672 0 17.216 -2.4 24.64 -6.752a48.448 48.448 0 0 0 23.328 -43.52 48.416 48.416 0 0 0 -8 -24.32 49.632 49.632 0 0 0 -21.76 -17.888 47.68 47.68 0 0 0 -27.52 -2.56 47.808 47.808 0 0 0 -37.728 37.76c-1.856 9.216 -0.96 18.752 2.56 27.52 3.744 8.832 9.984 16.384 17.92 21.76zm330.528 201.472c15.36 3.104 29.504 10.72 40.608 21.76 14.912 15.04 23.328 35.424 23.2 56.512 0.064 15.776 -4.608 31.264 -13.44 44.416a80 80 0 0 1 -123.136 12.288 80 80 0 0 1 12.224 -123.136 76.48 76.48 0 0 1 28.48 -11.84V239.648h32.064v113.536zm17.824 112.256a47.776 47.776 0 0 0 6.112 -60.416 49.632 49.632 0 0 0 -21.76 -17.92 47.68 47.68 0 0 0 -27.52 -2.56 47.776 47.776 0 0 0 -37.728 37.76 47.68 47.68 0 0 0 2.56 27.52 47.904 47.904 0 0 0 78.336 15.68zM374.016 108.8L320 162.816l22.624 22.624 54.016 -54.016 53.984 54.016 22.624 -22.624L419.296 108.8l54.016 -53.984 -22.656 -22.624 -53.984 53.984 -54.016 -53.984 -22.624 22.624L374.016 108.8z"]},vsGitPullRequestCreate:{prefix:"vs",iconName:"git-pull-request-create",icon:[512,512,[],"f000","M179.712 157.696a79.584 79.584 0 0 1 -35.808 29.504c-4.736 1.92 -14.656 4.416 -14.656 4.416v160.256a80.32 80.32 0 0 1 50.528 33.984c8.736 13.184 13.408 28.64 13.408 44.416 0.256 10.976 -1.824 21.888 -6.08 32A79.52 79.52 0 0 1 112 511.488a79.424 79.424 0 0 1 -44.416 -13.408A79.584 79.584 0 0 1 33.6 416c3.04 -15.552 10.592 -29.824 21.76 -41.056 11.168 -10.976 25.28 -18.528 40.608 -21.76V190.368a83.2 83.2 0 0 1 -40.608 -21.76 80.096 80.096 0 0 1 -21.76 -41.056 79.584 79.584 0 0 1 33.92 -82.08A79.68 79.68 0 0 1 112 32a80.128 80.128 0 0 1 57.824 23.328 79.776 79.776 0 0 1 23.328 57.92c0.064 15.808 -4.608 31.296 -13.44 44.448zm-24.192 251.552a48 48 0 0 0 -17.664 -18.528 46.4 46.4 0 0 0 -24.64 -6.72 47.84 47.84 0 0 0 -47.04 57.28 47.776 47.776 0 0 0 37.76 37.728c9.216 1.856 18.752 0.96 27.52 -2.56 8.832 -3.744 16.384 -9.984 21.76 -17.92 4.8 -7.232 7.52 -15.68 7.968 -24.32a48.32 48.32 0 0 0 -5.664 -24.96zM86.656 151.712c7.904 5.152 17.152 8 26.56 8 8.672 0 17.216 -2.4 24.64 -6.752a48.448 48.448 0 0 0 23.328 -43.488 48.416 48.416 0 0 0 -8 -24.32 49.632 49.632 0 0 0 -21.76 -17.92 47.68 47.68 0 0 0 -27.52 -2.56 47.808 47.808 0 0 0 -37.728 37.76c-1.856 9.216 -0.96 18.752 2.56 27.52 3.744 8.832 9.984 16.384 17.92 21.76zM417.184 224h-32.064V175.68a48 48 0 0 0 -48 -48H277.984l40.608 40.64 -22.72 22.688L227.744 122.88v-22.4l68.16 -68.16 22.72 22.752 -40.608 40.64h59.2a79.488 79.488 0 0 1 73.984 49.312c4 9.664 6.048 20.096 5.984 30.624V224zM416 512h-32v-96H288v-32h96V288h32v96h96v32h-96v96z"]},vsGitPullRequestDraft:{prefix:"vs",iconName:"git-pull-request-draft",icon:[512,512,[],"f000","M143.904 187.2a79.872 79.872 0 0 0 49.216 -73.92 79.776 79.776 0 0 0 -49.216 -75.2A80.128 80.128 0 0 0 111.968 32a79.68 79.68 0 0 0 -44.416 13.44A79.584 79.584 0 0 0 33.6 127.584c3.04 15.552 10.592 29.824 21.76 41.056a83.2 83.2 0 0 0 40.608 21.76v162.816c-15.36 3.232 -29.44 10.784 -40.608 21.76 -11.168 11.2 -18.72 25.504 -21.76 41.056a79.552 79.552 0 0 0 33.984 82.08 79.36 79.36 0 0 0 44.416 13.408 78.08 78.08 0 0 0 32 -6.08 79.52 79.52 0 0 0 49.216 -75.168 80.32 80.32 0 0 0 -63.936 -78.4V191.648s9.92 -2.496 14.656 -4.416zm-6.048 203.52a48 48 0 0 1 15.36 67.84 49.632 49.632 0 0 1 -21.76 17.888 47.744 47.744 0 0 1 -27.52 2.56 47.584 47.584 0 0 1 -37.76 -37.76 47.68 47.68 0 0 1 2.56 -27.52c3.744 -8.832 9.984 -16.384 17.92 -21.76a47.68 47.68 0 0 1 26.56 -8c8.672 -0.096 17.216 2.24 24.64 6.752zm-24.64 -231.04a48.64 48.64 0 0 1 -26.56 -8 49.632 49.632 0 0 1 -17.92 -21.76 47.712 47.712 0 0 1 -2.56 -27.52 47.552 47.552 0 0 1 37.76 -37.728 47.68 47.68 0 0 1 27.52 2.56c8.832 3.744 16.384 9.984 21.76 17.92A47.68 47.68 0 0 1 155.52 134.4a48.64 48.64 0 0 1 -17.664 18.528c-7.424 4.352 -15.968 6.72 -24.64 6.72zm368.512 272.32a80 80 0 1 1 -160 0 80 80 0 0 1 160 0zm-80 48a48 48 0 1 0 0 -96 48 48 0 0 0 0 96z"]},vsGitPullRequest:{prefix:"vs",iconName:"git-pull-request",icon:[512,512,[],"f000","M179.712 157.696a79.584 79.584 0 0 1 -35.808 29.504c-4.736 1.92 -14.656 4.416 -14.656 4.416v160.256a80.32 80.32 0 0 1 50.528 33.984c8.736 13.184 13.408 28.64 13.408 44.416 0.256 10.976 -1.824 21.888 -6.08 32A79.52 79.52 0 0 1 112 511.488a79.424 79.424 0 0 1 -44.416 -13.408A79.584 79.584 0 0 1 33.6 416c3.04 -15.552 10.592 -29.824 21.76 -41.056 11.168 -10.976 25.28 -18.528 40.608 -21.76V190.368a83.2 83.2 0 0 1 -40.608 -21.76 80.096 80.096 0 0 1 -21.76 -41.056 79.584 79.584 0 0 1 33.92 -82.08A79.68 79.68 0 0 1 112 32a80.128 80.128 0 0 1 57.824 23.328 79.776 79.776 0 0 1 23.328 57.92c0.064 15.808 -4.608 31.296 -13.44 44.448zm-24.192 251.552a48 48 0 0 0 -17.664 -18.528 46.4 46.4 0 0 0 -24.64 -6.72 47.84 47.84 0 0 0 -47.04 57.28 47.776 47.776 0 0 0 37.76 37.728c9.216 1.856 18.752 0.96 27.52 -2.56 8.832 -3.744 16.384 -9.984 21.76 -17.92 4.8 -7.232 7.52 -15.68 7.968 -24.32a48.32 48.32 0 0 0 -5.664 -24.96zM86.656 151.712c7.904 5.152 17.152 8 26.56 8 8.672 0 17.216 -2.4 24.64 -6.752a48.448 48.448 0 0 0 23.328 -43.488 48.416 48.416 0 0 0 -8 -24.32 49.632 49.632 0 0 0 -21.76 -17.92 47.68 47.68 0 0 0 -27.52 -2.56 47.808 47.808 0 0 0 -37.728 37.76c-1.856 9.216 -0.96 18.752 2.56 27.52 3.744 8.832 9.984 16.384 17.92 21.76zm330.528 201.472c15.36 3.104 29.504 10.72 40.608 21.76 14.912 15.04 23.328 35.424 23.2 56.512 0.064 15.776 -4.608 31.264 -13.44 44.416a79.968 79.968 0 0 1 -145.024 -28.768 80 80 0 0 1 34.144 -82.08c8.544 -5.856 18.272 -9.856 28.448 -11.84V175.648a48 48 0 0 0 -48 -47.968H277.984l40.608 40.64 -22.72 22.688L227.744 122.88v-22.4l68.16 -68.16 22.72 22.752 -40.608 40.64h59.2a79.488 79.488 0 0 1 73.984 49.312c4 9.664 6.048 20.096 5.984 30.624v177.536zm17.824 112.288a47.776 47.776 0 0 0 6.112 -60.48 49.664 49.664 0 0 0 -21.76 -17.888 47.68 47.68 0 0 0 -27.52 -2.56 47.776 47.776 0 0 0 -37.728 37.76 47.68 47.68 0 0 0 2.56 27.52 47.872 47.872 0 0 0 78.336 15.68z"]},vsGithubAction:{prefix:"vs",iconName:"github-action",icon:[512,512,[],"f000","M97.28 320h82.56l20.8 32H81.28l-16 -16v-288l16 -16h384l16 16v152.64l-32 -56V64h-352v256zm177.28 32l-45.12 111.04h70.4L480 278.4 456.64 224h-52.16l26.24 -46.72L404.16 128H312.32l-29.44 18.88 -72.96 160L239.04 352h35.52zm37.76 -192h91.84l-59.84 96h112.32l-184.32 186.88L326.4 320H239.04l73.28 -160zM222.4 224H129.28V192H236.8l-14.4 32zm-28.8 64H129.28V256H208l-14.4 32z"]},vsGithubAlt:{prefix:"vs",iconName:"github-alt",icon:[512,512,[],"f000","M448.747 112.149c19.413 23.296 29.099 50.475 29.099 81.536 0 112.576 -64.043 145.579 -124.224 155.285 7.765 13.589 9.707 29.12 9.707 44.651v79.573c0 9.707 -5.824 15.531 -13.589 15.531a15.317 15.317 0 0 1 -15.531 -15.531v-79.573a53.269 53.269 0 0 0 -15.531 -44.651l9.707 -25.237c60.181 -7.765 122.304 -27.179 122.304 -131.989 0 -25.237 -9.707 -48.533 -27.179 -67.947l-3.883 -15.509a86.187 86.187 0 0 0 1.92 -58.24c-9.685 1.92 -29.099 5.824 -62.08 29.12l-11.669 1.92a283.883 283.883 0 0 0 -139.733 0l-11.669 -1.92C161.493 57.813 142.08 51.989 132.352 51.989c-5.824 19.413 -5.824 40.747 1.92 58.24l-3.861 15.509c-19.413 19.413 -29.12 44.651 -29.12 67.947 0 102.869 58.24 124.224 122.283 131.989l7.765 25.237c-11.648 11.648 -17.472 27.179 -15.531 42.709v81.515a15.317 15.317 0 0 1 -15.531 15.531 15.317 15.317 0 0 1 -15.531 -15.531V430.507c-64.043 13.589 -89.28 -19.413 -108.693 -44.629 -9.707 -11.648 -17.472 -21.355 -27.179 -23.296 -1.92 -1.941 -7.765 -9.707 -5.824 -17.472 1.941 -7.765 9.707 -13.589 17.493 -9.707 19.413 3.883 31.04 19.413 42.667 33.003 17.493 23.296 34.965 44.629 87.36 33.003v-7.765c-1.92 -15.531 1.941 -31.061 9.707 -44.651 -58.24 -11.648 -126.165 -44.651 -126.165 -155.285 0 -31.061 9.707 -58.24 29.12 -81.536 -5.824 -27.157 -3.883 -56.277 5.824 -79.573l9.707 -7.765C122.645 22.891 149.824 17.067 206.08 51.989a291.691 291.691 0 0 1 141.696 0C402.155 15.104 431.275 20.907 435.157 22.869l9.707 7.765c9.707 27.179 11.648 54.357 3.883 81.515z"]},vsGithubInverted:{prefix:"vs",iconName:"github-inverted",icon:[512,512,[],"f000","M255.232 0A255.264 255.264 0 0 0 0 255.232c0 112.704 73.6 208.224 173.792 242.688 12.544 1.568 17.216 -6.272 17.216 -12.544v-43.84c-70.432 15.68 -86.08 -34.432 -86.08 -34.432 -10.976 -29.76 -28.192 -37.6 -28.192 -37.6 -23.488 -15.648 1.536 -15.648 1.536 -15.648 25.056 1.568 39.168 26.624 39.168 26.624 23.488 39.136 59.488 28.16 73.6 21.92 1.536 -17.216 9.376 -28.16 15.648 -34.432 -56.384 -6.272 -115.872 -28.192 -115.872 -126.848 0 -28.16 9.376 -50.112 26.624 -68.896 -1.6 -4.704 -10.976 -31.296 3.136 -65.76 0 0 21.92 -6.272 70.432 26.624 20.352 -6.272 42.304 -7.84 64.224 -7.84s43.84 3.136 64.192 7.84c48.544 -32.864 70.464 -26.624 70.464 -26.624 14.08 34.464 4.672 61.056 3.104 67.328a101.12 101.12 0 0 1 26.624 68.896c0 98.656 -59.52 119.008 -115.84 125.28 9.376 7.808 17.216 23.456 17.216 46.944v70.464c0 6.272 4.672 14.08 17.216 12.544A255.488 255.488 0 0 0 512 255.232C510.432 114.304 396.16 0 255.232 0z"]},vsGithub:{prefix:"vs",iconName:"github",icon:[512,512,[],"f000","M256 0a256 256 0 1 0 0 512 256 256 0 0 0 0 -512zm67.477 464.704h-1.984a10.944 10.944 0 0 1 -8.149 -2.987 10.944 10.944 0 0 1 -2.987 -7.936v-29.995c0.128 -9.963 0.213 -20.053 0.213 -30.208a78.784 78.784 0 0 0 -3.221 -21.931 39.083 39.083 0 0 0 -11.563 -18.667 170.965 170.965 0 0 0 43.477 -10.048 86.421 86.421 0 0 0 31.275 -20.565c8.683 -9.109 15.147 -20.117 18.88 -32.128a144.427 144.427 0 0 0 6.4 -45.44 88.277 88.277 0 0 0 -5.547 -31.488 83.029 83.029 0 0 0 -16.96 -27.392 59.947 59.947 0 0 0 3.456 -12.416c0.704 -4.267 1.067 -8.576 1.067 -12.885 0 -5.547 -0.64 -11.093 -1.92 -16.491a113.259 113.259 0 0 0 -4.715 -16.277 6.251 6.251 0 0 0 -2.368 -0.427h-2.347c-4.907 0.043 -9.728 0.853 -14.379 2.368a113.92 113.92 0 0 0 -14.997 5.547 138.731 138.731 0 0 0 -14.101 7.317c-4.587 2.709 -8.64 5.312 -12.224 7.723a204.331 204.331 0 0 0 -109.717 0 288.149 288.149 0 0 0 -12.203 -7.723 128.469 128.469 0 0 0 -14.336 -7.296 96.341 96.341 0 0 0 -15.04 -5.568 46.997 46.997 0 0 0 -14.123 -2.368h-2.347a6.187 6.187 0 0 0 -2.347 0.427 124.672 124.672 0 0 0 -4.907 16.277c-1.152 5.419 -1.707 10.944 -1.728 16.491 0 4.309 0.363 8.619 1.088 12.885 0.704 4.245 1.835 8.405 3.413 12.416A82.944 82.944 0 0 0 121.643 213.333a88.363 88.363 0 0 0 -5.611 31.488 146.581 146.581 0 0 0 6.229 45.227c3.861 12.011 10.304 23.04 18.859 32.341 8.853 9.003 19.52 16 31.275 20.565 13.931 5.333 28.523 8.747 43.371 10.155a38.997 38.997 0 0 0 -9.643 13.504 63.787 63.787 0 0 0 -4.267 15.872 58.752 58.752 0 0 1 -25.067 5.76 38.144 38.144 0 0 1 -22.72 -6.4 61.952 61.952 0 0 1 -16.043 -17.579 66.133 66.133 0 0 0 -6.229 -8.149 57.451 57.451 0 0 0 -7.936 -7.317 39.275 39.275 0 0 0 -9.216 -5.12 25.6 25.6 0 0 0 -10.261 -2.155c-0.853 0.021 -1.707 0.107 -2.56 0.213a13.845 13.845 0 0 0 -3.456 0.427 8.704 8.704 0 0 0 -2.773 1.28 2.475 2.475 0 0 0 -1.28 2.133 7.04 7.04 0 0 0 2.987 5.163c1.984 1.579 3.627 2.795 4.949 3.648l0.64 0.448c2.837 2.197 5.568 4.565 8.149 7.104 2.389 2.091 4.544 4.459 6.4 7.04 1.92 2.539 3.584 5.248 4.928 8.128 1.557 2.859 3.2 6.144 4.928 9.877 4.011 10.112 11.136 18.667 20.352 24.427 9.664 5.184 20.501 7.765 31.488 7.488 3.712 0 7.445 -0.213 11.136 -0.64 3.669 -0.597 7.317 -1.216 10.987 -1.941v37.184a10.667 10.667 0 0 1 -11.371 11.115h-1.323a219.435 219.435 0 1 1 134.912 0v0.107z"]},vsGlobe:{prefix:"vs",iconName:"globe",icon:[512,512,[],"f000","M272 32a208 208 0 1 1 0 416 208 208 0 0 1 0 -416zm156.608 128a176.864 176.864 0 0 0 -97.696 -85.632c14.208 26.88 24.48 55.68 30.496 85.632h67.2zm18.624 95.84A163.52 163.52 0 0 0 448 240a174.848 174.848 0 0 0 -6.816 -48h-74.944c1.024 10.592 1.76 21.248 1.76 32a323.648 323.648 0 0 1 -6.592 64h79.776c3.04 -10.528 5.056 -21.28 6.08 -32.16zm-113.12 0l0.192 -1.632A289.28 289.28 0 0 0 336 224a287.808 287.808 0 0 0 -2.432 -32H210.432A282.24 282.24 0 0 0 208 224a287.36 287.36 0 0 0 7.456 64h113.088c2.464 -10.624 4.32 -21.344 5.568 -32.16zM327.968 160a287.168 287.168 0 0 0 -40.16 -95.04C282.56 64.512 277.312 64 272 64a115.84 115.84 0 0 0 -9.984 0.48l-5.824 0.48L256 65.28A287.04 287.04 0 0 0 216.032 160h111.936zM182.592 160a318.688 318.688 0 0 1 30.912 -85.792A176.864 176.864 0 0 0 115.392 160h67.2zM102.816 192A175.36 175.36 0 0 0 96 240 175.36 175.36 0 0 0 102.816 288h79.776A320.512 320.512 0 0 1 176 224c0 -10.752 0.736 -21.408 1.76 -32H102.816zm88.128 128h-75.52a176.48 176.48 0 0 0 122.208 92.576A320.736 320.736 0 0 1 190.944 320zM272 404.608A286.144 286.144 0 0 0 319.296 320H224.704A286.176 286.176 0 0 0 272 404.608zM353.056 320a320.768 320.768 0 0 1 -46.688 92.576A176.544 176.544 0 0 0 428.576 320h-75.52z"]},vsGoToFile:{prefix:"vs",iconName:"go-to-file",icon:[512,512,[],"f000","M192 189.248l65.92 -65.92v-22.656L189.28 32l-22.624 22.624 1.376 1.376 8 8 32 32h-96a80 80 0 0 0 0 160H128V224h-16a48 48 0 1 1 0 -96h96L166.624 169.376 189.248 192 192 189.248zM352 64H266.496l-32 -32H384l22.72 9.28 96 96L512 160v288l-32 32H192l-32 -32V208l32 27.104V448h288V192h-128V64zm32 0v96h96l-96 -96z"]},vsGrabber:{prefix:"vs",iconName:"grabber",icon:[512,512,[],"f000","M480 192H32v32h448V192zm0 96H32v32h448V288z"]},vsGraphLeft:{prefix:"vs",iconName:"graph-left",icon:[512,512,[],"f000","M67.808 128L96 156.192l-19.808 19.808L22.88 122.656v-19.776L76.16 49.536l19.84 19.808L69.344 96H480v32H67.808zM128 465.472V174.56L144 160h64l16 14.56v290.88L208 480h-64l-16 -14.528zm64 -14.56V189.088H160v261.824h32zm64 -49.12V174.208L272 160h64l16 14.208v227.584l-16 14.208h-64l-16 -14.208zm64 -14.24V188.48H288v199.104h32zm64 -213.824v164.576l16 13.696h64l16 -13.696V173.728L464 160h-64l-16 13.728zm64 13.696v137.152h-32V187.424h32z"]},vsGraphLine:{prefix:"vs",iconName:"graph-line",icon:[512,512,[],"f000","M480 416v32H48l-16 -16V0h32v416h416zm-64 -313.376L251.328 267.328h-22.656L176 214.624l-116.672 116.704 -22.656 -22.656 128 -128h22.656L240 233.376l164.672 -164.704h22.624l64 64 -22.624 22.656L416 102.624z"]},vsGraphScatter:{prefix:"vs",iconName:"graph-scatter",icon:[512,512,[],"f000","M480 416v32H48l-16 -16V0h32v416h416zM160 64h64v64H160zm224 -32h64v64h-64zM256 160h64v64H256zM160 288h64v64H160zm224 -32h64v64h-64z"]},vsGraph:wt,vsGripper:yt,vsGroupByRefType:{prefix:"vs",iconName:"group-by-ref-type",icon:[512,512,[],"f000","M48 32h64v32H64v384h48v32h-64l-16 -16v-416l16 -16zm192 192h-64L160 208v-64l16 -16h64l16 16v64l-16 16zM192 192h32V160H192v32zm240 32h-96l-16 -16v-96l16 -16h96l16 16v96l-16 16zM352 192h64V128h-64v64zm-112 192h-64l-16 -16v-64l16 -16h64l16 16v64l-16 16zM192 352h32v-32H192v32zm240 64h-96l-16 -16v-96l16 -16h96l16 16v96l-16 16zM352 384h64v-64h-64v64zm-32 -64H256v32h64v-32zm0 -160H256v32h64V160z"]},vsHeart:{prefix:"vs",iconName:"heart",icon:[512,512,[],"f000","M476.16 152.96a111.648 111.648 0 0 0 -11.84 -28.8 103.68 103.68 0 0 0 -19.2 -25.28 120.96 120.96 0 0 0 -38.72 -25.92 119.68 119.68 0 0 0 -90.88 0 128 128 0 0 0 -37.12 24l-1.6 1.92 -20.8 20.8 -20.8 -20.8 -1.6 -1.92a128 128 0 0 0 -37.12 -24 119.68 119.68 0 0 0 -90.88 0 120.96 120.96 0 0 0 -38.72 25.92 113.6 113.6 0 0 0 -31.04 54.08 120 120 0 0 0 -3.84 32c0 10.144 1.28 20.256 3.84 30.08a128 128 0 0 0 11.52 28.48 121.6 121.6 0 0 0 19.52 25.28L256 457.92l189.12 -189.12c7.584 -7.456 14.08 -16 19.2 -25.28A114.496 114.496 0 0 0 480 184.96a119.904 119.904 0 0 0 -3.84 -32zm-32 52.16a86.08 86.08 0 0 1 -22.08 38.72l-166.72 166.4 -166.72 -166.4a92.8 92.8 0 0 1 -14.08 -18.24 96 96 0 0 1 -8.64 -20.8 104 104 0 0 1 -2.56 -22.08A107.52 107.52 0 0 1 65.92 160a89.6 89.6 0 0 1 8.64 -20.8c3.84 -6.72 8.576 -12.8 14.08 -18.24a93.12 93.12 0 0 1 28.48 -19.2 89.6 89.6 0 0 1 66.56 0c10.56 4.384 20.096 10.816 28.16 18.88l43.52 43.84 43.52 -43.84a87.04 87.04 0 0 1 28.16 -18.88 89.6 89.6 0 0 1 66.56 0c10.592 4.576 20.256 11.104 28.48 19.2 5.568 5.28 10.24 11.424 13.76 18.24a86.08 86.08 0 0 1 11.2 42.88 83.2 83.2 0 0 1 -1.92 23.04h-0.96z"]},vsHistory:{prefix:"vs",iconName:"history",icon:[512,512,[],"f000","M432.224 394.368a224 224 0 0 0 2.08 -273.92A224 224 0 0 0 64 140.576V64H32v112l16 16H160V160H89.952a192.256 192.256 0 1 1 -4.32 184.64l-28.384 14.784a224 224 0 0 0 374.976 34.944zm-107.552 -31.04l22.656 -22.624L256 249.344V128H224v128l4.672 11.328 96 96z"]},vsHome:{prefix:"vs",iconName:"home",icon:[512,512,[],"f000","M267.52 43.84l203.52 185.6 -22.72 22.72L416 222.848v208.832l-16 16h-96l-16 -16v-112H224v112l-16 16h-96l-16 -16V223.104L64 252.16l-22.72 -22.72 203.2 -185.6h23.04zM128 194.016v221.664h64v-112l16 -16h96l16 16v112h64V193.824L256 77.76 128 194.016z"]},vsHorizontalRule:{prefix:"vs",iconName:"horizontal-rule",icon:[512,512,[],"f000","M205.824 320h26.336V128h-26.336v83.52h-83.52V128H96v192h26.336V236.608h83.52V320zm181.376 0h28.8l-40.96 -84.16c4.192 -1.856 8.32 -4.288 12.448 -7.36a53.312 53.312 0 0 0 18.72 -25.504c2.048 -5.472 3.072 -11.648 3.072 -18.56a56.64 56.64 0 0 0 -2.624 -17.824 52.608 52.608 0 0 0 -7.04 -14.272 48.128 48.128 0 0 0 -9.92 -10.912 59.648 59.648 0 0 0 -23.584 -11.936A46.272 46.272 0 0 0 355.2 128H276.48v192h26.368V240.576h46.944L387.2 320zm-21.792 -106.24a27.968 27.968 0 0 1 -9.376 1.76H302.816V153.184h53.216a27.84 27.84 0 0 1 18.432 7.68 30.592 30.592 0 0 1 9.792 23.584c0 5.376 -0.928 10.048 -2.784 13.984a29.12 29.12 0 0 1 -16.096 15.328zM416 384H96v32h320v-32z"]},vsHubot:{prefix:"vs",iconName:"hubot",icon:[512,512,[],"f000","M271.36 128h128l16 16v64.96h16.64l16 16V256l-16 16h-16.64v96l-16 16H299.52l-80 88.32L192 460.8V384H112l-16 -20.48V272h-16L64 256v-31.04l16 -16H96V139.52L112.96 128h128V91.52A32 32 0 0 1 224 64a32 32 0 0 1 64 0 32 32 0 0 1 -16.64 26.56V128zM384 256V160H128v187.52l80 4.48H224v70.08l57.6 -65.28 11.2 -4.8H384V256zm-67.84 16.32a86.72 86.72 0 0 1 -43.84 23.68v-0.32a86.72 86.72 0 0 1 -77.44 -23.68l-22.4 22.72c10.88 10.88 23.84 19.456 38.08 25.28 14.4 6.016 29.824 9.152 45.44 9.28a118.4 118.4 0 0 0 82.56 -34.24l-22.4 -22.72zM207.68 208h-32v32h32v-32zm96 0h32v32h-32v-32z"]},vsInbox:{prefix:"vs",iconName:"inbox",icon:[512,512,[],"f000","M48 448h416l16 -16V288l-88.64 -245.12 -15.04 -10.88H136.64l-15.04 10.56L32 279.68v152.32l16 16zM448 416H64v-95.36h81.6l23.68 40 13.76 7.68h146.24l14.08 -8.32 22.08 -39.36H448V416zm-0.704 -127.36H355.84l-13.76 8.32 -22.08 39.36H192.32l-24 -40 -13.76 -7.68H64V288l83.84 -224h216.96l82.496 224.64z"]},vsInfo:{prefix:"vs",iconName:"info",icon:[512,512,[],"f000","M274.176 32.992A217.6 217.6 0 0 1 408.32 97.6a225.92 225.92 0 0 1 14.72 300.48 219.2 219.2 0 0 1 -274.56 55.68 224 224 0 0 1 -99.84 -112 227.84 227.84 0 0 1 -7.36 -150.72 224 224 0 0 1 88.64 -121.28 217.6 217.6 0 0 1 144.256 -36.768zM289.28 444.16a188.48 188.48 0 0 0 109.12 -66.24 194.24 194.24 0 0 0 -12.8 -257.92 186.24 186.24 0 0 0 -237.76 -23.68 193.92 193.92 0 0 0 16 329.28 185.92 185.92 0 0 0 125.44 18.56zM236 192h40V160h-40v32zm40 32v128h-40V224h40z"]},vsInspect:{prefix:"vs",iconName:"inspect",icon:[512,512,[],"f000","M32 96l32 -32h384l32 32v192h-32V96H64v256h160v32H64l-32 -32V96zm470.624 310.624L288 192v301.248l86.624 -86.624h128zM320 416V269.248l105.376 105.376h-64L320 416z"]},vsIssueDraft:{prefix:"vs",iconName:"issue-draft",icon:[512,512,[],"f000","undefined"]},vsIssueReopened:{prefix:"vs",iconName:"issue-reopened",icon:[512,512,[],"f000","M168.96 180.992L64 224.192l-21.12 -8.32L0 112.192l29.44 -12.16 25.92 62.4a207.36 207.36 0 0 1 399.36 61.76h-32a175.36 175.36 0 0 0 -340.48 -40.96l74.24 -32 12.48 29.76zm283.52 85.76l42.88 103.36 -29.44 14.08 -26.24 -64a207.68 207.68 0 0 1 -400 -64h32v-16a175.68 175.68 0 0 0 340.48 60.48l-72 29.76 -12.48 -29.44 104 -43.2 20.8 8.96z"]},vsIssues:Tt,vsItalic:{prefix:"vs",iconName:"italic",icon:[512,512,[],"f000","M288.032 434.976l-3.104 10.4H128l3.936 -10.4c15.744 -0.384 26.144 -1.696 31.232 -3.936 8.224 -3.2 14.336 -7.616 18.24 -13.216 6.208 -8.832 12.608 -24.576 19.168 -47.264l66.368 -230.08c5.632 -19.104 8.416 -33.536 8.416 -43.296a20.576 20.576 0 0 0 -3.648 -12.384 21.856 21.856 0 0 0 -11.232 -7.584c-4.896 -1.888 -14.528 -2.816 -28.992 -2.816L234.88 64h147.36l-3.072 10.4c-12 -0.192 -20.928 1.12 -26.72 3.936a43.456 43.456 0 0 0 -19.424 16.032c-4.288 6.944 -9.92 22.304 -16.864 46.144l-66.112 230.08c-5.984 21.152 -8.96 34.656 -8.96 40.48 0 4.672 1.088 8.704 3.36 12.096 2.432 3.2 6.176 5.696 11.232 7.584 5.248 1.696 16.032 3.104 32.352 4.224z"]},vsJersey:{prefix:"vs",iconName:"jersey",icon:[512,512,[],"f000","M381.12 455.04H129.92l-16 -16V225.92H68.8l-15.36 -12.16L32 128l10.56 -19.2L178.88 64l20.48 10.24a86.4 86.4 0 0 0 6.72 14.08c2.272 3.296 4.864 6.4 7.68 9.28 5.376 5.408 11.808 9.664 18.88 12.48a58.24 58.24 0 0 0 45.76 0 55.68 55.68 0 0 0 18.88 -12.48c2.88 -3.04 5.536 -6.24 8 -9.6l4.8 -9.28a38.72 38.72 0 0 0 1.6 -4.48l20.48 -10.24 136.32 45.44L480 128l-21.12 85.12 -15.68 12.16h-46.08v213.12l-16 16.64zm-235.2 -32h219.2V209.92l16 -16h48.64l14.72 -58.56 -108.8 -36.48a36.224 36.224 0 0 1 -3.84 6.72c-3.52 5.152 -7.456 9.984 -11.84 14.4a88 88 0 0 1 -29.12 19.52 91.2 91.2 0 0 1 -71.04 0A93.44 93.44 0 0 1 192 120a69.44 69.44 0 0 1 -11.52 -14.08l-4.16 -7.04 -109.76 36.48 14.72 58.56h48.64l16 16v213.12z"]},vsJson:{prefix:"vs",iconName:"json",icon:[512,512,[],"f000","M192 95.488V64h-2.88c-10.016 0 -19.712 1.984 -29.088 5.92a74.56 74.56 0 0 0 -24.8 16.96 71.36 71.36 0 0 0 -15.776 24.096v0.032a113.344 113.344 0 0 0 -6.336 26.56v0.064a194.56 194.56 0 0 0 -0.768 27.616c0.384 9.28 0.576 18.56 0.576 27.808 0 6.496 -1.28 12.576 -3.744 18.304v0.032a48.128 48.128 0 0 1 -24.48 25.184 44.032 44.032 0 0 1 -17.856 3.68H64v31.488h2.88c6.24 0 12.16 1.28 17.792 3.872l0.032 0.032c5.696 2.496 10.528 5.888 14.56 10.176l0.064 0.064c4.16 4.16 7.456 9.12 9.824 14.88l0.032 0.064c2.496 5.76 3.744 11.776 3.744 18.112 0 9.28 -0.192 18.56 -0.576 27.808 -0.384 9.472 -0.128 18.72 0.768 27.84v0.032c1.056 9.056 3.168 17.856 6.304 26.368v0.032c3.392 8.736 8.672 16.768 15.808 24.096 7.136 7.36 15.424 13.024 24.8 16.96 9.376 3.936 19.072 5.92 29.12 5.92H192v-31.488h-2.88c-6.4 0 -12.384 -1.216 -18.016 -3.68a51.616 51.616 0 0 1 -14.624 -10.24 53.088 53.088 0 0 1 -9.888 -14.944c-2.368 -5.76 -3.52 -11.84 -3.52 -18.336 0 -7.296 0.096 -14.496 0.352 -21.504 0.256 -7.296 0.256 -14.4 0 -21.28a148.448 148.448 0 0 0 -1.76 -20.48 85.824 85.824 0 0 0 -5.376 -19.488A73.088 73.088 0 0 0 112.704 256a73.088 73.088 0 0 0 23.616 -30.56c2.56 -6.144 4.32 -12.576 5.376 -19.264 1.056 -6.72 1.632 -13.536 1.76 -20.48 0.256 -7.04 0.256 -14.144 0 -21.312 -0.256 -7.168 -0.384 -14.4 -0.384 -21.696a47.04 47.04 0 0 1 28.064 -43.328 42.56 42.56 0 0 1 18.016 -3.872H192zm128 321.024V448h2.88c10.016 0 19.712 -1.984 29.088 -5.92 9.376 -3.936 17.664 -9.6 24.8 -16.96 7.136 -7.36 12.416 -15.36 15.776 -24.096v-0.032c3.2 -8.512 5.28 -17.376 6.336 -26.56v-0.064c0.896 -8.96 1.152 -18.144 0.768 -27.616 -0.384 -9.28 -0.576 -18.56 -0.576 -27.808 0 -6.496 1.28 -12.576 3.744 -18.304v-0.032a48.064 48.064 0 0 1 24.48 -25.184 44.16 44.16 0 0 1 17.856 -3.68H448v-31.488h-2.88c-6.272 0 -12.192 -1.28 -17.824 -3.872l-0.032 -0.032a44.032 44.032 0 0 1 -14.56 -10.176l-0.064 -0.064a45.28 45.28 0 0 1 -9.824 -14.88v-0.064a44.96 44.96 0 0 1 -3.776 -18.112c0 -9.28 0.192 -18.56 0.576 -27.808a197.568 197.568 0 0 0 -0.768 -27.84v-0.032a113.184 113.184 0 0 0 -6.304 -26.368v-0.032a71.36 71.36 0 0 0 -15.808 -24.096 74.592 74.592 0 0 0 -24.8 -16.96 74.4 74.4 0 0 0 -29.12 -5.92H320v31.488h2.88c6.4 0 12.384 1.216 17.984 3.68 5.568 2.624 10.432 6.016 14.624 10.24 4.064 4.288 7.36 9.28 9.888 14.944 2.368 5.76 3.52 11.84 3.52 18.336 0 7.296 -0.096 14.464 -0.352 21.504 -0.256 7.296 -0.256 14.4 0 21.28 0.128 7.104 0.704 13.92 1.76 20.48 1.056 6.848 2.848 13.312 5.376 19.488a73.12 73.12 0 0 0 23.616 30.56 73.12 73.12 0 0 0 -23.616 30.56 86.048 86.048 0 0 0 -5.376 19.264c-1.056 6.72 -1.632 13.536 -1.76 20.48a292.8 292.8 0 0 0 0 21.312c0.256 7.168 0.384 14.4 0.384 21.696a47.072 47.072 0 0 1 -28.064 43.328 42.56 42.56 0 0 1 -18.016 3.872H320z"]},vsKebabVertical:Ot,vsKey:{prefix:"vs",iconName:"key",icon:[512,512,[],"f000","M363.232 34.912a144.896 144.896 0 0 1 110.08 101.12c6.88 23.168 7.904 47.68 2.976 71.36a146.656 146.656 0 0 1 -141.984 115.2c-14.016 0 -27.968 -2.016 -41.376 -6.08l-25.6 30.016 -12.128 5.6H224v48l-16 16H160v48l-16 16h-96l-16 -16v-73.824l4.672 -11.296L195.84 219.84a142.848 142.848 0 0 1 -6.4 -44.96 144.896 144.896 0 0 1 173.792 -140zm42.176 230.4a114.176 114.176 0 0 0 39.648 -64.16l0.128 0.16A113.376 113.376 0 0 0 311.04 66.56a114.432 114.432 0 0 0 -89.6 108.8c-0.32 14.592 2.24 29.056 7.648 42.56l-3.52 17.376L64 396.928v51.2h64v-48l16 -16H192v-48l16 -16h39.84l28.032 -32.512 17.952 -4.48a111.04 111.04 0 0 0 40.608 7.616 114.176 114.176 0 0 0 70.976 -25.44zm-26.816 -87.424a32 32 0 1 0 -53.184 -35.52 32 32 0 0 0 53.184 35.52z"]},vsLaw:Mt,vsLayersActive:{prefix:"vs",iconName:"layers-active",icon:[512,512,[],"f000","M261.92 34.656l-17.856 0.128 -189.088 129.184 0.128 26.496L244.16 317.28l17.6 0.128 194.944 -126.816 0.096 -26.752 -194.88 -129.184zm-169.376 142.4l160.672 -109.76 165.632 109.76 -165.632 107.776 -160.672 -107.776zm151.648 220.224L57.376 272h57.44l138.4 92.8 142.688 -92.8h58.656l-25.6 16.64a128.064 128.064 0 0 0 -134.72 87.648l-32.416 21.12 -17.632 -0.128zm43.936 24.832l-34.88 22.72L114.784 352H57.376l186.816 125.28 17.6 0.128 32.64 -21.216a127.616 127.616 0 0 1 -6.304 -34.08zm74.528 -85.92a96 96 0 1 1 106.656 159.584 96 96 0 0 1 -106.656 -159.584zm54.336 122.144l57.28 -76.384 -25.6 -19.2 -47.36 63.168 -28.032 -22.4 -19.968 24.96 40.896 32.736 22.784 -2.88z"]},vsLayersDot:{prefix:"vs",iconName:"layers-dot",icon:[512,512,[],"f000","M261.92 34.656l-17.856 0.128 -189.088 129.184 0.128 26.496L244.16 317.28l17.6 0.128 194.944 -126.816 0.096 -26.752 -194.88 -129.184zm-169.376 142.4l160.672 -109.76 165.632 109.76 -165.632 107.776 -160.672 -107.776zm151.648 220.224L57.376 272h57.44l138.4 92.8 142.688 -92.8h58.656l-25.6 16.64a128.064 128.064 0 0 0 -134.72 87.648l-32.416 21.12 -17.632 -0.128zm43.936 24.832l-34.88 22.72L114.784 352H57.376l186.816 125.28 17.6 0.128 32.64 -21.216a127.616 127.616 0 0 1 -6.304 -34.08z"]},vsLayers:{prefix:"vs",iconName:"layers",icon:[512,512,[],"f000","M244.064 34.784l17.856 -0.128 194.912 129.184 -0.096 26.752L261.824 317.44l-17.632 -0.128 -189.12 -126.816 -0.096 -26.496 189.12 -129.184zm9.152 32.512l-160.672 109.76 160.672 107.776 165.632 -107.776 -165.632 -109.76zM57.376 272l186.816 125.28 17.6 0.128L454.592 272h-58.656l-142.688 92.8 -138.4 -92.8H57.376zm186.816 205.28L57.376 352h57.44l138.4 92.8 142.688 -92.8h58.656l-192.736 125.44 -17.632 -0.16z"]},vsLibrary:{prefix:"vs",iconName:"library",icon:[512,512,[],"f000","M160 80l16 -16h64l16 16v352l-16 16h-64l-16 -16v-352zM192 96v320h32V96H192zm101.472 11.04l9.568 -20.512 60.16 -21.888 20.48 9.568 120.384 330.752 -9.568 20.512 -60.128 21.888 -20.48 -9.568L293.44 107.04zm35.52 4.096l109.44 300.672 30.08 -10.912 -109.44 -300.704 -30.08 10.944zM32 80l16 -16h64l16 16v352l-16 16h-64l-16 -16v-352zM64 96v320h32V96H64z"]},vsLightbulbAutofix:{prefix:"vs",iconName:"lightbulb-autofix",icon:[512,512,[],"f000","M384 288a96 96 0 1 0 0 192 96 96 0 0 0 0 -192zm41.92 160L384 416l-41.6 32 16 -48.96 -38.4 -26.56h47.04L384 320l17.28 52.48H448l-38.4 26.56 16.32 48.96zm-68.48 -189.28A127.328 127.328 0 0 0 265.216 336H205.088v70.432c0 2.592 0.896 4.8 2.88 6.784a9.28 9.28 0 0 0 6.816 2.88h45.216c2.848 11.136 7.136 21.696 12.672 31.424 -2.112 0.32 -4.288 0.48 -6.496 0.48H214.784a41.12 41.12 0 0 1 -29.504 -12.128 41.696 41.696 0 0 1 -12.16 -29.44v-51.2c0 -15.328 -2.944 -29.472 -8.768 -42.528a113.792 113.792 0 0 0 -24.832 -35.648 150.048 150.048 0 0 1 -32.192 -45.984A133.984 133.984 0 0 1 96 176a141.824 141.824 0 0 1 19.712 -72.64c6.304 -10.752 13.824 -20.48 22.56 -29.248a147.2 147.2 0 0 1 29.152 -22.464c10.816 -6.272 22.4 -11.136 34.688 -14.528a142.4 142.4 0 0 1 38.4 -5.12 143.232 143.232 0 0 1 72.832 19.648 143.2 143.2 0 0 1 51.904 51.712 142.016 142.016 0 0 1 19.712 72.64c0 19.744 -3.744 38.112 -11.296 55.072a145.184 145.184 0 0 1 -16.192 27.648z"]},vsLightbulb:{prefix:"vs",iconName:"lightbulb",icon:[512,512,[],"f000","M373.44 277.056a117.152 117.152 0 0 0 -24.992 35.648 104.96 104.96 0 0 0 -8.576 42.528v51.2a41.728 41.728 0 0 1 -25.408 38.304 41.024 41.024 0 0 1 -16.288 3.264H246.784a41.12 41.12 0 0 1 -29.504 -12.128 41.696 41.696 0 0 1 -12.16 -29.44v-51.2c0 -15.328 -2.944 -29.472 -8.768 -42.528a113.792 113.792 0 0 0 -24.832 -35.648 150.048 150.048 0 0 1 -32.192 -45.984A133.984 133.984 0 0 1 128 176a141.824 141.824 0 0 1 19.712 -72.64c6.304 -10.752 13.824 -20.48 22.56 -29.248a147.2 147.2 0 0 1 29.152 -22.464c10.816 -6.272 22.4 -11.136 34.688 -14.528a142.4 142.4 0 0 1 38.4 -5.12 143.232 143.232 0 0 1 72.832 19.648 143.2 143.2 0 0 1 51.904 51.712 142.016 142.016 0 0 1 19.712 72.64c0 19.744 -3.744 38.112 -11.296 55.072a150.08 150.08 0 0 1 -32.192 45.984zM307.936 336H237.088v70.432c0 2.592 0.896 4.8 2.88 6.784a9.28 9.28 0 0 0 6.816 2.88h51.392a9.248 9.248 0 0 0 6.816 -2.88 9.152 9.152 0 0 0 2.88 -6.784V336z"]},vsLinkExternal:{prefix:"vs",iconName:"link-external",icon:[512,512,[],"f000","M48 32H192v32H64v384h384v-128h32v144l-16 16h-416l-16 -16v-416l16 -16zm432 16V256h-32V86.624L231.776 302.88l-22.624 -22.656L425.376 64H256V32h208l16 16z"]},vsLink:Nt,vsListFilter:{prefix:"vs",iconName:"list-filter",icon:[512,512,[],"f000","M192 384v-32h128v32H192zM128 224h256v32H128V224zm320 -128v32H64V96h384z"]},vsListFlat:{prefix:"vs",iconName:"list-flat",icon:[512,512,[],"f000","M64 320V288h384v32H64zm0 -128h384v32H64V192zm384 -96v32H64V96h384zM64 384v32h384v-32H64z"]},vsListOrdered:{prefix:"vs",iconName:"list-ordered",icon:[512,512,[],"f000","M73.184 74.432L86.144 64h21.664v96h-22.656V89.344l-11.968 8.992v-23.904zM160 96h320v32H160V96zm0 128h320v32H160V224zm320 128H160v32h320v-32zM119.744 244.032l0.928 -1.248 2.08 -2.88a26.88 26.88 0 0 0 4.992 -16.224c0 -3.84 -0.64 -7.68 -1.824 -11.328a27.136 27.136 0 0 0 -15.744 -16.928 35.936 35.936 0 0 0 -14.464 -2.624 35.008 35.008 0 0 0 -14.656 2.784 27.744 27.744 0 0 0 -15.328 16.704A33.216 33.216 0 0 0 64 222.624v1.6h25.92v-1.6a9.6 9.6 0 0 1 1.472 -5.024 5.568 5.568 0 0 1 1.824 -1.728 6.08 6.08 0 0 1 5.504 0 6.016 6.016 0 0 1 1.792 1.92 7.68 7.68 0 0 1 0.992 2.592 14.24 14.24 0 0 1 -1.152 9.28 41.888 41.888 0 0 1 -3.84 5.824l-32 36.416 -0.384 0.416v17.28h63.616v-22.4h-28.8l20.8 -23.168zm-1.184 122.144c1.472 1.024 2.752 2.24 3.84 3.648a26.912 26.912 0 0 1 5.344 17.6c0 3.424 -0.544 6.816 -1.6 10.048a25.344 25.344 0 0 1 -15.584 16 41.216 41.216 0 0 1 -15.36 2.528c-3.68 0 -7.36 -0.512 -10.912 -1.568a30.08 30.08 0 0 1 -8.256 -3.936 24.032 24.032 0 0 1 -5.824 -5.664 34.016 34.016 0 0 1 -3.712 -6.4A33.216 33.216 0 0 1 64 386.496v-1.568h26.048v1.568c0 0.864 0.096 1.76 0.288 2.624a6.624 6.624 0 0 0 0.96 2.368 4.48 4.48 0 0 0 1.696 1.664 6.4 6.4 0 0 0 5.024 0.256 5.088 5.088 0 0 0 1.792 -1.248 7.04 7.04 0 0 0 1.344 -2.4 13.344 13.344 0 0 0 0.544 -4.032 15.456 15.456 0 0 0 -0.704 -5.216 6.4 6.4 0 0 0 -1.632 -2.56 4.416 4.416 0 0 0 -1.92 -0.928 17.184 17.184 0 0 0 -2.464 -0.224h-5.152v-20.64h5.376a7.712 7.712 0 0 0 2.208 -0.352 5.248 5.248 0 0 0 2.08 -1.088 5.6 5.6 0 0 0 1.536 -2.144 9.152 9.152 0 0 0 0.672 -3.872 8.96 8.96 0 0 0 -0.512 -3.2 5.312 5.312 0 0 0 -3.104 -3.168 6.4 6.4 0 0 0 -4.992 0.224 5.248 5.248 0 0 0 -1.76 1.696 11.008 11.008 0 0 0 -1.28 4.992v1.568H64v-1.568a31.584 31.584 0 0 1 5.76 -17.408 25.6 25.6 0 0 1 5.728 -5.952 27.84 27.84 0 0 1 8.384 -4.256c3.648 -1.152 7.488 -1.696 11.328 -1.632 3.712 -0.032 7.392 0.32 11.008 1.152 2.944 0.672 5.76 1.76 8.416 3.2a24.224 24.224 0 0 1 10.24 10.176 23.36 23.36 0 0 1 2.88 11.104 25.92 25.92 0 0 1 -5.344 16.896 17.984 17.984 0 0 1 -3.84 3.648z"]},vsListSelection:{prefix:"vs",iconName:"list-selection",icon:[512,512,[],"f000","M32 384v-32h288v32H32zm0 -160h448v32H32V224zm352 -128v32H32V96h352z"]},vsListTree:{prefix:"vs",iconName:"list-tree",icon:[512,512,[],"f000","M448 96v32H64V96h384zm-32 96v32H192V192h224zm0 96v32H160V288h256zm0 96v32H160v-32h256zM160 128h32v288H160z"]},vsListUnordered:Dt,vsLiveShare:{prefix:"vs",iconName:"live-share",icon:[512,512,[],"f000","M293.013 36.139L323.797 21.333l171.285 134.997v29.611l-171.285 129.536 -30.784 -14.805v-59.221h-12.587c-86.613 -0.427 -143.147 2.219 -226.347 110.144l-32.725 -10.517a175.573 175.573 0 0 1 5.781 -48.107 235.221 235.221 0 0 1 83.627 -144.917 241.899 241.899 0 0 1 160.043 -54.336h22.187v-57.6zm38.485 168.896v59.221l121.088 -91.328 -120.491 -96.96v56.832h-61.013A198.379 198.379 0 0 0 123.093 188.757a222.805 222.805 0 0 0 -51.221 87.936c71.488 -68.544 132.053 -71.659 209.024 -71.659h50.624zm-163.136 125.781a91.947 91.947 0 1 1 102.144 152.875 91.947 91.947 0 0 1 -102.144 -152.875zm20.373 122.197a55.211 55.211 0 1 0 61.397 -91.776 55.211 55.211 0 0 0 -61.397 91.776z"]},vsLoading:xt,vsLocation:{prefix:"vs",iconName:"location",icon:[512,512,[],"f000","M346.624 86.016A129.792 129.792 0 0 0 256.64 48h-1.28a129.792 129.792 0 0 0 -128 128c-0.416 24 6.336 47.584 19.392 67.744L247.488 448h17.056l100.704 -204.256c13.088 -20.16 19.84 -43.744 19.392 -67.744a129.792 129.792 0 0 0 -38.016 -89.984zM253.6 80l2.624 0.32 2.368 -0.32a98.4 98.4 0 0 1 94.112 97.184 87.68 87.68 0 0 1 -14.944 50.176l-0.64 1.088 -0.544 1.12L256 392.928l-80.544 -163.2 -0.544 -1.248 -0.64 -1.088a87.68 87.68 0 0 1 -14.944 -50.176A98.368 98.368 0 0 1 253.568 80zm19.584 69.408a32 32 0 1 0 -35.584 53.216 32 32 0 0 0 35.584 -53.216zM219.84 122.784a64 64 0 1 1 71.04 106.432 64 64 0 0 1 -71.04 -106.432z"]},vsLock:Rt,vsMagnet:{prefix:"vs",iconName:"magnet",icon:[512,512,[],"f000","M256 48c-124.8 0 -224 99.2 -224 224v160l32 32h96l32 -32v-160c0 -35.2 28.8 -64 64 -64s64 28.8 64 64v160l32 32h96l32 -32v-160c0 -124.8 -99.2 -224 -224 -224zm-96 384H64v-96h96v96zm288 0h-96v-96h96v96zm-96 -128v-32c0 -54.4 -41.6 -96 -96 -96 -51.2 0 -92.8 41.6 -96 89.6v38.4H64v-32c0 -105.6 86.4 -192 192 -192s192 86.4 192 192v32h-96z"]},vsMailRead:{prefix:"vs",iconName:"mail-read",icon:[512,512,[],"f000","M264 50.24h-16.32L32 177.92v254.08l16 16h416l16 -16V177.92L264 50.24zM256 82.56l180.16 106.24 -43.84 50.88H119.68L77.76 188.8 256 82.56zM448 416H64V221.44L99.52 265.6l12.48 6.08h288l12.48 -6.08L448 221.44V416z"]},vsMail:{prefix:"vs",iconName:"mail",icon:[512,512,[],"f000","M32 112l16 -16h416l16 16v288l-16 16h-416l-16 -16v-288zm32 33.12V384h384V145.152L265.92 284.8H246.4L64 145.12zM416.96 128H95.04L256 251.808 416.96 128z"]},vsMarkdown:It,vsMegaphone:{prefix:"vs",iconName:"megaphone",icon:[512,512,[],"f000","M64 216.64l394.56 -109.76 21.44 16.96v275.2l-21.44 16.96 -194.848 -51.04a69.12 69.12 0 1 1 -133.696 -35.04L64 312.64l-13.44 -16.96V233.6L64 216.64zm96.192 121.184a36.16 36.16 0 0 0 -1.28 7.744 37.44 37.44 0 0 0 73.216 11.104l-71.936 -18.848zM82.56 282.24L448 378.56V144L82.56 247.04v35.2z"]},vsMention:{prefix:"vs",iconName:"mention",icon:[512,512,[],"f000","M334.88 395.52a176.512 176.512 0 0 1 -97.696 23.552 136.384 136.384 0 0 1 -146.24 -145.376 172.192 172.192 0 0 1 172.512 -178.272c76.064 0 141.216 44 141.216 128.192 0 69.824 -41.344 117.12 -92.8 117.12 -21.632 0 -35.2 -8.768 -36.032 -29.344a64.384 64.384 0 0 1 -56.192 29.216c-31.008 0 -52.128 -20.64 -52.128 -61.536 0 -56.416 36.736 -108.8 83.84 -108.8a42.048 42.048 0 0 1 45.664 29.76l6.752 -25.888h28.8L307.2 276.672c-7.232 29.312 -4.16 38.88 10.944 38.88 31.488 0 58.656 -38.72 58.656 -90.4 0 -66.176 -46.24 -104.48 -115.52 -104.48 -84.576 0 -139.968 68.224 -140.224 153.152a110.176 110.176 0 0 0 117.952 118.944c31.136 1.28 62.08 -5.728 89.6 -20.288l6.272 23.04zM198.944 276.448c0 25.216 9.824 38.592 29.216 38.592 24.256 0 44.16 -19.2 53.856 -58.592C292.352 215.872 283.2 195.2 254.08 195.2c-33.28 0 -55.136 42.848 -55.136 81.248z"]},vsMenu:Lt,vsMerge:{prefix:"vs",iconName:"merge",icon:[512,512,[],"f000","M336 148.672L267.328 80h-22.624L176 148.672l22.624 22.624L233.6 136.352V168.96h-0.64v14.592l0.8 0.032 0.192 10.208c0.128 5.984 0.64 12.128 1.6 18.368 0.96 6.24 2.208 12.48 3.744 18.752 1.536 6.24 3.648 12.928 6.4 20.064 4.96 12.128 10.976 23.104 18.08 32.992 7.072 9.888 14.72 19.136 22.88 27.744 8.16 8.64 16.256 17.12 24.32 25.504 8 8.384 15.296 17.312 21.792 26.816 6.496 9.504 11.776 19.872 15.808 31.136 4 11.232 6.016 24.16 6.016 38.816v28.288H400v-28.288a191.712 191.712 0 0 0 -5.312 -44.48 148.416 148.416 0 0 0 -13.664 -35.2 188 188 0 0 0 -19.328 -28.704c-7.104 -8.64 -14.496 -16.864 -22.176 -24.768 -7.68 -7.872 -15.072 -15.744 -22.176 -23.616a204.48 204.48 0 0 1 -19.328 -25.12 121.408 121.408 0 0 1 -13.856 -29.248 117.632 117.632 0 0 1 -5.12 -36.16V168.96h-0.032v-32l34.368 34.368 22.624 -22.656zM225.344 311.712a262.08 262.08 0 0 0 10.528 -11.808 193.92 193.92 0 0 1 -19.84 -36.8L215.808 262.4a232.32 232.32 0 0 1 -3.04 -8.416c-5.44 8.192 -11.488 15.936 -18.08 23.232 -7.104 7.872 -14.496 15.744 -22.176 23.616 -7.68 7.904 -15.04 16.128 -22.176 24.768 -7.072 8.64 -13.536 18.176 -19.328 28.672a148.576 148.576 0 0 0 -13.664 35.264 191.84 191.84 0 0 0 -5.312 44.448v28.288h45.44v-28.288c0 -14.624 1.984 -27.584 6.016 -38.816 4 -11.264 9.28 -21.632 15.776 -31.136 6.496 -9.504 13.76 -18.432 21.824 -26.816 8.032 -8.384 16.128 -16.864 24.32 -25.504z"]},vsMilestone:{prefix:"vs",iconName:"milestone",icon:[512,512,[],"f000","M256 32H224v64H48l-16 16v128l16 16H224v224h32V256h143.68l10.88 -4.16 69.76 -64v-23.68l-69.76 -64L400 96H256V32zm137.28 192H64V128h329.28l52.16 48L393.28 224zM160 160h160v32H160V160z"]},vsMirror:{prefix:"vs",iconName:"mirror",icon:[512,512,[],"f000","M274.24 32l198.4 128 7.36 12.16v294.4l-24.32 13.44L256 352l-199.68 128 -24.32 -13.44v-294.4L39.36 160l198.4 -128h36.48zm-1.92 292.16L448 437.44V180.8l-175.68 -112V160h-32V68.16L64 181.44v256l176.32 -113.92v0.64h32zm28.8 -152.96l22.72 -22.4 79.04 79.36v22.72l-78.72 78.72 -22.4 -22.4L352.64 256h-192L211.2 307.2l-22.4 22.4 -78.72 -78.72v-22.72l79.36 -79.36 22.4 22.4L159.36 224h194.56L301.12 171.2z"]},vsMortarBoard:{prefix:"vs",iconName:"mortar-board",icon:[512,512,[],"f000","M480 181.12L261.76 96h-11.52L32 181.12V384h32V224l73.92 28.8a139.2 139.2 0 0 0 -25.28 79.36c-0.32 3.52 -0.32 7.04 0 10.56v3.52l8.96 12.8L248.96 416h13.12l126.08 -57.92 8.96 -12.8v-14.08a140.48 140.48 0 0 0 -24.96 -79.04L480 210.24v-29.12zm-112.64 149.76v2.24L256 384l-112 -51.2a4.16 4.16 0 0 1 0 -1.92 110.08 110.08 0 0 1 24 -67.84l82.56 32h11.52l81.92 -32a108.8 108.8 0 0 1 23.36 67.84zM256 264L80.64 195.84 256 128l175.36 68.48L256 264z"]},vsMove:{prefix:"vs",iconName:"move",icon:[512,512,[],"f000","M327.424 342.624L272 398.08V288h-32v110.08l-55.424 -55.456 -22.624 22.624L244.672 448h22.656l82.72 -82.752 -22.624 -22.624zM161.952 114.752l22.624 22.624L240 81.92V192h32V81.92l55.424 55.456 22.624 -22.624L267.328 32h-22.656L161.952 114.752zm-8.576 53.824L97.92 224H208v32H97.92l55.456 55.424 -22.624 22.624L48 251.328v-22.656l82.752 -82.72 22.624 22.624zM304 224h110.08l-55.456 -55.424 22.624 -22.624L464 228.672v22.656l-82.752 82.72 -22.624 -22.624L414.08 256H304V224z"]},vsMultipleWindows:{prefix:"vs",iconName:"multiple-windows",icon:[512,512,[],"f000","M192 48l16 -16h256l16 16v224l-16 16H384V256h64V128H224v32H192V48zM224 64v32h224V64H224zM48 224l-16 16v224l16 16h256l16 -16v-224L304 224h-256zM64 288V256h224v32H64zm0 32h224v128H64v-128z"]},vsMute:{prefix:"vs",iconName:"mute",icon:[512,512,[],"f000","M48 160h89.28l123.52 -122.56 27.2 11.2v416l-27.2 10.56L137.28 352H48l-16 -16v-160l16 -16zm107.2 165.44L256 425.92V87.36L155.2 187.2 144 192H64v128h80l11.2 5.44zm300.192 -131.456l22.624 22.624L422.624 272l55.392 55.424 -22.624 22.624L400 294.624l-55.424 55.424 -22.624 -22.624L377.376 272 321.92 216.64l22.624 -22.624 55.456 55.36 55.392 -55.392z"]},vsNewFile:Ft,vsNewFolder:kt,vsNoNewline:{prefix:"vs",iconName:"no-newline",icon:[512,512,[],"f000","M74.656 176.192a96 96 0 1 1 106.688 159.648 96 96 0 0 1 -106.688 -159.68zm85.664 24.864A63.552 63.552 0 0 0 64 256.288c0.128 11.296 3.264 22.336 9.056 32.032L160.32 201.056zM95.68 310.944A63.552 63.552 0 0 0 192 255.712a63.616 63.616 0 0 0 -9.056 -32.032L95.68 310.944zM448 160v63.488a16 16 0 0 1 -16 16H299.744L352 187.232l-22.624 -22.624 -67.872 67.872 -13.536 13.536v18.176l81.408 81.408 22.624 -22.624 -51.52 -51.488h131.52a48 48 0 0 0 48 -48V160h-32z"]},vsNote:{prefix:"vs",iconName:"note",icon:[512,512,[],"f000","M48 64h416l16 16v320l-16 16h-416l-16 -16v-320l16 -16zM64 96v288h384V96H64zm64 64h256v32H128V160zm192 64H128v32h192V224zM128 288h128v32H128V288z"]},vsNotebookTemplate:{prefix:"vs",iconName:"notebook-template",icon:[512,512,[],"f000","M32 160H0V128h32v32zm0 64H0V192h32v32zm0 64H0V256h32v32zm0 64H0v-32h32v32zm0 64H0v-32h32v32zm0 32v32H0v-32h32zm0 32h32v32H32v-32zm64 0h32v32H96v-32zM32 32H0V0h32v32zm64 0H64V0h32v32zm32 -32h32v32H128V0zm96 32H192V0h32v32zm64 0H256V0h32v32zm64 0h-32V0h32v32zm0 32V32h32v32h-32zm32 64h-32V96h32v32zM32 96H0V64h32v32zm128 96l32 -32h224l32 32v288l-32 32H192l-32 -32V192zm32 0v288h224V192H192zm288 32h32v64h-32V224zm0 96h32v64h-32v-64zm0 96h32v64h-32v-64zM224 256h160v32H224z"]},vsNotebook:{prefix:"vs",iconName:"notebook",icon:[512,512,[],"f000","M64 64l32 -32h288l32 32v384l-32 32H96l-32 -32V64zm32 0v384h288V64H96zm32 64l32 -32h160l32 32v32l-32 32H160L128 160V128zm32 0v32h160V128H160zm320 32h-32v64h32V160zm-32 96h32v64h-32V256zm32 96h-32v64h32v-64z"]},vsOctoface:{prefix:"vs",iconName:"octoface",icon:[512,512,[],"f000","M443.616 181.536c3.616 -8.96 15.36 -44.544 -3.648 -92.704 0 0 -29.408 -9.216 -96.32 36.416 -28 -7.84 -57.984 -8.96 -87.648 -8.96 -29.696 0 -59.648 1.12 -87.648 8.96 -66.912 -45.92 -96.32 -36.416 -96.32 -36.416 -19.04 48.16 -7.264 83.744 -3.616 92.704C45.696 205.856 32 237.216 32 275.296c0 144.224 93.248 176.704 223.424 176.704 130.24 0 224.576 -32.48 224.576 -176.672 0 -38.08 -13.728 -69.44 -36.384 -93.792zM256 424.576c-92.416 0 -167.424 -4.224 -167.424 -93.824 0 -21.28 10.624 -41.44 28.544 -57.952 29.952 -27.424 81.184 -12.864 138.88 -12.864 57.952 0 108.64 -14.56 138.88 12.864 18.208 16.512 28.576 36.416 28.576 57.952 0 89.312 -75.072 93.792 -167.456 93.792zM185.728 284.256c-18.496 0 -33.6 22.4 -33.6 49.824 0 27.456 15.104 50.112 33.6 50.112 18.464 0 33.6 -22.4 33.6 -50.112 0 -27.712 -15.136 -49.824 -33.6 -49.824zm140.544 0c-18.464 0 -33.6 22.112 -33.6 49.824s15.136 50.112 33.6 50.112c18.496 0 33.6 -22.4 33.6 -50.112 0 -27.712 -14.816 -49.824 -33.6 -49.824z"]},vsOpenPreview:{prefix:"vs",iconName:"open-preview",icon:[512,512,[],"f000","M96 32h352l32 32v169.6a102.72 102.72 0 0 0 -32 -9.6V64H288v348.16L252.16 448H96l-32 -32V64l32 -32zm0 384h160V64H96v352zm332.128 -159.936a80.96 80.96 0 0 0 -38.08 11.136h-0.96a80.32 80.32 0 0 0 -25.568 112.96L288 455.36l22.72 22.72 75.2 -75.52c10.4 7.04 22.4 11.456 34.88 12.8a79.04 79.04 0 0 0 36.48 -4.16 80.32 80.32 0 0 0 32 -20.16 78.72 78.72 0 0 0 18.56 -32 84.16 84.16 0 0 0 2.24 -36.8 80.96 80.96 0 0 0 -43.2 -57.92 80.96 80.96 0 0 0 -38.752 -8.256zm7.68 127.744a48 48 0 0 1 -31.328 -7.808 49.6 49.6 0 0 1 -17.92 -21.76 47.68 47.68 0 0 1 -2.56 -27.52 47.68 47.68 0 0 1 37.76 -37.76 47.68 47.68 0 0 1 27.52 2.56c8.832 3.744 16.384 9.952 21.76 17.92a48 48 0 0 1 -35.2 74.368z"]},vsOrganization:{prefix:"vs",iconName:"organization",icon:[512,512,[],"f000","M291.552 149.216A64 64 0 1 1 220.48 42.784a64 64 0 0 1 71.104 106.432zm-17.76 -79.808A32 32 0 1 0 238.208 122.56a32 32 0 0 0 35.584 -53.12zm83.52 0.96a47.808 47.808 0 0 1 60.64 6.016 48.416 48.416 0 0 1 -15.584 78.72 47.744 47.744 0 0 1 -52.32 -10.432 48.384 48.384 0 0 1 7.296 -74.272zm15.36 51.52a15.968 15.968 0 1 0 22.56 -22.656 16.288 16.288 0 0 0 -11.232 -4.8 15.968 15.968 0 0 0 -16 16.096 16.32 16.32 0 0 0 4.672 11.392zM102.08 399.584H160v32.16H102.08a38.304 38.304 0 0 1 -26.944 -11.424 38.72 38.72 0 0 1 -11.136 -27.2v-57.92a31.904 31.904 0 0 1 -22.72 -10.624A32.224 32.224 0 0 1 32 301.056V231.232c0.096 -15.104 6.08 -29.536 16.64 -40.256 10.528 -10.592 24.768 -16.64 39.68 -16.736H147.2a93.184 93.184 0 0 0 -17.6 32.192H88.32a25.536 25.536 0 0 0 -17.28 7.424 24.864 24.864 0 0 0 -7.04 17.376v71.424h32v90.432a6.464 6.464 0 0 0 1.6 4.832 7.68 7.68 0 0 0 4.48 1.6zm233.6 -208.576a56.48 56.48 0 0 0 -40 -16.736H216.32a56.48 56.48 0 0 0 -39.68 16.736c-10.56 10.72 -16.544 25.152 -16.64 40.256v101.696a33.92 33.92 0 0 0 9.28 23.488 32 32 0 0 0 22.72 10.624v74.336a38.464 38.464 0 0 0 11.2 27.36c5.76 5.376 13.024 8.864 20.8 9.984h64a36.8 36.8 0 0 0 32 -37.344V367.04a31.904 31.904 0 0 0 22.72 -10.624 32.192 32.192 0 0 0 9.28 -23.488V231.232a57.6 57.6 0 0 0 -16.32 -40.256zM320 334.528H288v106.88a6.464 6.464 0 0 1 -1.92 4.48 5.44 5.44 0 0 1 -4.48 1.92H230.08a6.72 6.72 0 0 1 -6.4 -6.4v-106.88H192V231.232c0 -6.496 2.528 -12.736 7.04 -17.376a25.536 25.536 0 0 1 17.28 -7.424h79.36a24.896 24.896 0 0 1 22.56 15.36 23.936 23.936 0 0 1 1.76 9.44v103.296zm89.92 97.184H352v-32.16h57.6a7.68 7.68 0 0 0 4.48 -1.6 6.4 6.4 0 0 0 1.92 -4.864V302.656h32V231.232a24.864 24.864 0 0 0 -7.04 -17.376 25.536 25.536 0 0 0 -17.28 -7.424h-41.28a93.12 93.12 0 0 0 -17.6 -32.192h58.88a56.64 56.64 0 0 1 39.68 16.736c10.56 10.72 16.544 25.152 16.64 40.256v69.824c0 8.736 -3.296 17.12 -9.248 23.456 -5.952 6.368 -14.08 10.176 -22.752 10.656v57.92c0 10.208 -4 19.968 -11.136 27.2a38.304 38.304 0 0 1 -26.944 11.424zM128 62.24a47.808 47.808 0 0 0 -44.352 29.824A48.544 48.544 0 0 0 94.08 144.64 47.904 47.904 0 0 0 176 110.528c0 -12.8 -5.056 -25.088 -14.08 -34.144A47.872 47.872 0 0 0 128 62.24zm0 64.384a15.968 15.968 0 0 1 -16 -16.096 16.128 16.128 0 0 1 16 -16.096 16.288 16.288 0 0 1 16 16.096 16.128 16.128 0 0 1 -16 16.096z"]},vsOutput:{prefix:"vs",iconName:"output",icon:[512,512,[],"f000","M416 0v32L448 64v416L416 512h-320L64 480V64l32 -32V0H128v32h64V0h32v32h64V0H320v32h64V0h32zm-320 480h320V64h-320v416zM160 128h192v32h-192V128zm192 128h-192v32h192V256zm-192 128h192v32h-192V384z"]},vsPackage:{prefix:"vs",iconName:"package",icon:[512,512,[],"f000","M275.52 96l183.68 48.96L480 160v215.68l-11.84 15.36 -196.16 54.08 -196.48 -54.08 -11.52 -15.36V160l19.52 -15.04L266.88 96h8.64zm-2.88 32l-128 32 17.6 6.4 109.76 28.8 96 -25.92 30.4 -9.28 -125.76 -32zM96 363.52l160 43.84V224L96 181.12v182.4zM288 224v183.36l160 -43.84V180.16l-64.64 17.696V280l-32 8.32V206.624L288 224z"]},vsPaintcan:{prefix:"vs",iconName:"paintcan",icon:[512,512,[],"f000","M465.28 377.952l-36.48 -99.84v-1.92l-157.12 -157.12v-39.68a53.12 53.12 0 0 0 -3.52 -18.56 47.36 47.36 0 0 0 -26.56 -25.6 45.44 45.44 0 0 0 -18.56 -3.2 47.04 47.04 0 0 0 -47.36 47.36v104.32l-97.92 96a48.64 48.64 0 0 0 0 67.84l116.16 116.16c4.48 4.512 9.824 8.096 15.68 10.56a48.96 48.96 0 0 0 36.48 0 48.32 48.32 0 0 0 15.68 -10.56l157.76 -157.44 -21.12 70.4a38.08 38.08 0 0 0 0 14.72c1.056 4.864 3.136 9.472 6.08 13.44 3.136 3.872 6.912 7.136 11.2 9.6 4.48 2.24 9.408 3.52 14.4 3.84a32 32 0 0 0 15.36 -2.88 36.48 36.48 0 0 0 12.48 -9.28 31.36 31.36 0 0 0 7.04 -14.08c1.024 -4.64 1.12 -9.408 0.32 -14.08zm-256 -298.56a14.72 14.72 0 0 1 0 -6.4 16.64 16.64 0 0 1 3.84 -5.44 20.48 20.48 0 0 1 5.76 -3.2 16 16 0 0 1 6.72 0 16 16 0 0 1 10.24 4.8 16 16 0 0 1 3.84 10.56v40.32l-32 32 1.6 -72.64zm32 363.2a11.52 11.52 0 0 1 -5.12 3.52 15.04 15.04 0 0 1 -12.16 0 11.552 11.552 0 0 1 -5.12 -3.52l-116.16 -115.84a16 16 0 0 1 0 -22.72l139.2 -139.2v91.2a23.68 23.68 0 0 0 -7.68 17.6 24 24 0 1 0 37.44 -17.6v-90.56l123.2 123.84 -153.6 153.28z"]},vsPassFilled:At,vsPass:Pt,vsPersonAdd:{prefix:"vs",iconName:"person-add",icon:[512,512,[],"f000","M416 320h-32v64h-64v32h64v64h32v-64h64v-32h-64v-64zM273.792 69.408a32 32 0 1 0 -35.584 53.216 32 32 0 0 0 35.584 -53.216zm-53.344 -26.624A64 64 0 1 1 291.52 149.216a64 64 0 0 1 -71.04 -106.432zM216.64 175.68h78.72A56.64 56.64 0 0 1 352 232.32V256h-32v-23.68a24.32 24.32 0 0 0 -24.64 -24.64H216.64a24.32 24.32 0 0 0 -24.64 24.64V320h32v105.92a6.4 6.4 0 0 0 6.4 6.4H256v32.64h-25.6a38.4 38.4 0 0 1 -38.4 -38.4V352a33.92 33.92 0 0 1 -32 -35.2V232.32a56.64 56.64 0 0 1 56.64 -56.64z"]},vsPerson:{prefix:"vs",iconName:"person",icon:[512,512,[],"f000","M256 64a32 32 0 1 1 0 64 32 32 0 0 1 0 -64zm0 -32a64 64 0 1 0 0 128 64 64 0 0 0 0 -128zm39.36 143.68H216.64A56.64 56.64 0 0 0 160 232.32V316.8A33.92 33.92 0 0 0 192 352v74.56a38.4 38.4 0 0 0 38.4 38.4h51.2a38.4 38.4 0 0 0 38.4 -39.68V352a33.92 33.92 0 0 0 32 -35.2V232.32a56.64 56.64 0 0 0 -56.64 -56.64zM192 320V232.32a24.32 24.32 0 0 1 24.64 -24.64h78.72a24.32 24.32 0 0 1 24.64 24.64V320H288v105.92a6.4 6.4 0 0 1 -6.4 6.4H230.4a6.4 6.4 0 0 1 -6.4 -6.4V320H192z"]},vsPieChart:{prefix:"vs",iconName:"pie-chart",icon:[512,512,[],"f000","M320 192h124.8A160.192 160.192 0 0 0 320 67.2V192zm0 -157.344A192.16 192.16 0 0 1 480 224H288V32c10.88 0 21.6 0.896 32 2.656zM224 256l32 32h156.8A160.064 160.064 0 0 1 96 256a160.064 160.064 0 0 1 128 -156.8V256zm32 192a192.064 192.064 0 0 0 192 -192H256V64a192.064 192.064 0 0 0 0 384z"]},vsPin:{prefix:"vs",iconName:"pin",icon:[512,512,[],"f000","M448 160v224h-8.896c-12.992 0 -24.896 -2.752 -35.744 -8.256A80.896 80.896 0 0 1 375.36 352H283.84a110.816 110.816 0 0 1 -17.472 26.496 117.92 117.92 0 0 1 -23.52 20.256c-8.64 5.664 -18.08 9.92 -28.224 12.736a124 124 0 0 1 -31.52 4.512h-16V288H64l-32 -16L64 256h103.104V128h16c10.848 0 21.248 1.504 31.264 4.48 9.984 3.008 19.424 7.264 28.256 12.8A108.928 108.928 0 0 1 283.84 192h91.488a81.92 81.92 0 0 1 28 -23.488c10.816 -5.504 22.72 -8.32 35.744 -8.512H448zm-24.896 34.752a39.104 39.104 0 0 0 -10.24 4.992 47.712 47.712 0 0 0 -13.76 14.752L393.12 224H261.856l-3.744 -10.752a78.624 78.624 0 0 0 -22.752 -33.504C224.864 170.592 205.664 162.88 192 160v224c13.664 -2.816 32.864 -10.56 43.36 -19.744 10.496 -9.184 18.08 -20.352 22.72 -33.504L261.888 320h131.264l5.76 9.504c1.824 3.008 3.904 5.664 6.24 8 2.336 2.336 4.896 4.576 7.744 6.72 2.816 2.208 6.24 3.84 10.24 5.024V194.752z"]},vsPinnedDirty:{prefix:"vs",iconName:"pinned-dirty",icon:[512,512,[],"f000","M128 64h224v8.896c0 12.992 -2.752 24.896 -8.256 35.744 -5.504 10.848 -13.44 20.16 -23.744 28v91.52c9.824 4.64 18.656 10.496 26.496 17.472a118.4 118.4 0 0 1 17.28 19.136 157.44 157.44 0 0 0 -28.672 13.184l-0.224 0.128 -0.96 0.576a78.592 78.592 0 0 0 -35.168 -24.768L288 250.144V118.88l9.504 -5.76c3.008 -1.824 5.664 -3.904 8 -6.24a72.96 72.96 0 0 0 6.72 -7.744 30.976 30.976 0 0 0 5.024 -10.24H162.752c1.344 4 3.008 7.424 4.992 10.24a47.808 47.808 0 0 0 14.752 13.76L192 118.88v131.264l-10.752 3.744c-13.152 4.672 -24.32 12.256 -33.504 22.752C138.592 287.136 130.88 306.336 128 320h160.064a160.8 160.8 0 0 0 -15.392 24.896H256V448l-16 32 -16 -32v-103.104H96v-16c0 -10.848 1.504 -21.248 4.48 -31.264 3.008 -9.984 7.264 -19.424 12.8 -28.256A108.928 108.928 0 0 1 160 228.16V136.64a81.952 81.952 0 0 1 -23.488 -28A80.16 80.16 0 0 1 128 72.896V64zm239.52 269.12a93.568 93.568 0 0 1 22.976 -9.664c8.192 -2.304 16.704 -3.456 25.504 -3.456s17.312 1.152 25.504 3.456a94.592 94.592 0 0 1 42.272 24.736 94.592 94.592 0 0 1 24.768 42.304c2.304 8.192 3.456 16.704 3.456 25.504s-1.152 17.312 -3.456 25.504a94.496 94.496 0 0 1 -24.768 42.368 96.416 96.416 0 0 1 -42.272 24.768c-8.192 2.24 -16.704 3.36 -25.504 3.36s-17.312 -1.12 -25.504 -3.36a97.184 97.184 0 0 1 -42.368 -24.768 97.184 97.184 0 0 1 -24.736 -42.368A95.808 95.808 0 0 1 320 416c0 -8.8 1.12 -17.312 3.36 -25.504a96.416 96.416 0 0 1 28.256 -45.6c4.928 -4.48 10.24 -8.384 15.904 -11.776z"]},vsPinned:{prefix:"vs",iconName:"pinned",icon:[512,512,[],"f000","M128 64h224v8.896c0 12.992 -2.752 24.896 -8.256 35.744 -5.504 10.848 -13.44 20.16 -23.744 28v91.52c9.824 4.64 18.656 10.496 26.496 17.472 7.84 7.008 14.592 14.848 20.256 23.52 5.664 8.64 9.92 18.08 12.736 28.224 2.848 10.176 4.352 20.672 4.512 31.52v16H256V448l-16 32 -16 -32v-103.104H96v-16c0 -10.848 1.504 -21.248 4.48 -31.264 3.008 -9.984 7.264 -19.424 12.8 -28.256A108.928 108.928 0 0 1 160 228.16V136.64a81.952 81.952 0 0 1 -23.488 -28A80.16 80.16 0 0 1 128 72.896V64zm34.752 24.896c1.344 4 3.008 7.424 4.992 10.24a47.808 47.808 0 0 0 14.752 13.76L192 118.88v131.264l-10.752 3.744c-13.152 4.672 -24.32 12.256 -33.504 22.752C138.592 287.136 130.88 306.336 128 320h224c-2.816 -13.664 -10.56 -32.864 -19.744 -43.36a78.592 78.592 0 0 0 -33.504 -22.72L288 250.112V118.88l9.504 -5.76c3.008 -1.824 5.664 -3.904 8 -6.24a72.96 72.96 0 0 0 6.72 -7.744 30.976 30.976 0 0 0 5.024 -10.24H162.752z"]},vsPlayCircle:{prefix:"vs",iconName:"play-circle",icon:[512,512,[],"f000","M275.2 32c51.2 3.2 99.2 28.8 134.4 64 41.6 44.8 64 99.2 64 163.2 0 51.2 -19.2 99.2 -51.2 140.8 -32 38.4 -76.8 67.2 -128 76.8 -51.2 9.6 -102.4 3.2 -147.2 -22.4 -44.8 -25.6 -80 -64 -99.2 -112C28.8 294.4 25.6 240 41.6 192c16 -51.2 44.8 -92.8 89.6 -121.6C172.8 41.6 224 28.8 275.2 32zm16 412.8c41.6 -9.6 80 -32 108.8 -67.2 25.6 -35.2 41.6 -76.8 38.4 -121.6 0 -51.2 -19.2 -102.4 -54.4 -137.6 -32 -32 -70.4 -51.2 -115.2 -54.4 -41.6 -3.2 -86.4 6.4 -121.6 32 -35.2 25.6 -60.8 60.8 -73.6 105.6 -12.8 41.6 -12.8 86.4 6.4 128 19.2 41.6 48 73.6 86.4 96 38.4 22.4 83.2 28.8 124.8 19.2zM192 160l24.864 -13.312 144 96v26.624l-144 96L192 352V160zm32 29.888v132.224L323.168 256 224 189.888z"]},vsPlay:_t,vsPlug:{prefix:"vs",iconName:"plug",icon:[512,512,[],"f000","M224 32H192v96H144l-16 16V256a128 128 0 0 0 112 127.008V480h32v-96.992A128 128 0 0 0 384 256V144l-16 -16H320V32H288v96H224V32zm99.872 291.872A96 96 0 0 1 160 256V160h192v96a96 96 0 0 1 -28.128 67.872z"]},vsPreserveCase:{prefix:"vs",iconName:"preserve-case",icon:[512,512,[],"f000","M273.088 398.944H237.952l-28.704 -75.936h-114.88l-27.04 75.936H32L135.936 128h32.864l104.32 270.944zm-74.24 -104.48L156.32 179.008a110.528 110.528 0 0 1 -4.16 -18.144h-0.736c-1.28 7.68 -2.72 13.76 -4.352 18.144L104.928 294.464h93.92zm114.304 104.48V128h77.12c23.424 0 41.984 5.76 55.712 17.184 13.76 11.488 20.608 26.4 20.608 44.8 0 15.36 -4.16 28.704 -12.48 40.064 -8.32 11.328 -19.776 19.392 -34.4 24.16v0.768c18.272 2.144 32.896 9.056 43.84 20.8 10.976 11.584 16.448 26.688 16.448 45.344 0 23.168 -8.32 41.92 -24.96 56.32 -16.608 14.336 -37.568 21.504 -62.912 21.504H313.152zm31.744 -242.24v87.488h32.512c17.376 0 31.04 -4.16 40.992 -12.48 9.952 -8.416 14.912 -20.256 14.912 -35.52 0 -26.304 -17.28 -39.456 -51.936 -39.456h-36.48zm0 116.032v97.504h43.072c18.656 0 33.088 -4.416 43.296 -13.248 10.304 -8.8 15.488 -20.896 15.488 -36.256 0 -32 -21.792 -48 -65.376 -48h-36.48z"]},vsPreview:Ht,vsPrimitiveSquare:{prefix:"vs",iconName:"primitive-square",icon:[512,512,[],"f000","M112 128l16 -16h256l16 16v256l-16 16H128l-16 -16V128zm32 16v224h224v-224h-224z"]},vsProject:{prefix:"vs",iconName:"project",icon:[512,512,[],"f000","M48 32h416l16 16v416l-16 16h-416l-16 -16v-416l16 -16zM64 448h384V64H64v384zM96 96h64v320H96V96zm192 0H224v192h64V96zm64 0h64v256h-64V96z"]},vsPulse:{prefix:"vs",iconName:"pulse",icon:[512,512,[],"f000","M377.6 288L320 96H288L229.056 308.48 191.68 150.08h-31.04L123.2 288H32v31.68h103.36l15.68 -11.84 23.68 -86.4L210.88 384h32.96l59.84 -225.28 46.72 149.76 15.36 11.52H480V288h-102.4z"]},vsQuestion:jt,vsQuote:{prefix:"vs",iconName:"quote",icon:[512,512,[],"f000","M229.12 112C151.36 161.92 113.6 213.44 113.6 299.52c5.12 -1.6 9.6 -1.6 14.08 -1.6 40.64 0 80 27.52 80 77.12 0 51.52 -32.96 83.52 -80 83.52 -60.8 0 -95.68 -48.64 -95.68 -136 0 -121.6 56 -208.96 160.64 -269.44L229.12 112zm224 0c-77.76 49.92 -115.52 101.44 -115.52 187.52 5.12 -1.6 9.6 -1.6 14.08 -1.6 40.64 0 80 27.52 80 77.12 0 51.52 -32.96 83.52 -80 83.52 -60.48 0 -95.36 -48.64 -95.36 -136 0 -121.6 56 -208.96 160.64 -269.44l36.48 58.88h-0.32z"]},vsRadioTower:{prefix:"vs",iconName:"radio-tower",icon:[512,512,[],"f000","M95.936 178.56a177.6 177.6 0 0 1 51.84 -124.16l-22.72 -22.4a206.4 206.4 0 0 0 0 293.12l22.72 -22.4a177.6 177.6 0 0 1 -51.84 -124.16zm33.92 0a141.44 141.44 0 0 0 42.24 101.44l22.72 -22.72a104.64 104.64 0 0 1 -24.32 -35.84 110.4 110.4 0 0 1 0 -85.44 103.04 103.04 0 0 1 24.32 -36.16l-22.72 -22.72a142.72 142.72 0 0 0 -42.24 101.44zm244.8 102.72l-22.72 -22.72c10.56 -10.24 18.88 -22.528 24.32 -36.16a110.368 110.368 0 0 0 0 -85.44 103.04 103.04 0 0 0 -24.32 -36.16l22.72 -22.4a142.976 142.976 0 0 1 0 202.88zM418.176 32l-22.72 22.72a173.76 173.76 0 0 1 0 247.68l22.72 22.72a206.4 206.4 0 0 0 0 -293.12zM319.776 173.76a48 48 0 0 1 -7.84 31.36 64 64 0 0 1 -8.64 7.36l110.08 247.36 -29.44 12.8 -24.64 -55.36h-177.28l-24.64 55.36 -29.44 -12.8 110.08 -247.36a48.64 48.64 0 0 1 -10.56 -52.16 49.6 49.6 0 0 1 17.92 -21.76 48 48 0 0 1 74.4 35.2zm-51.04 -10.88a16.64 16.64 0 0 0 -8 4.48 16.64 16.64 0 0 0 -3.52 7.04 15.36 15.36 0 0 0 0 9.28c1.28 2.88 3.264 5.44 5.76 7.36a17.28 17.28 0 0 0 8.96 2.56 16.32 16.32 0 0 0 16 -16 17.28 17.28 0 0 0 -2.56 -8.96 18.56 18.56 0 0 0 -7.36 -5.76 15.36 15.36 0 0 0 -9.28 0zm7.36 65.6h-8.64l-27.84 62.08h64l-27.52 -62.08zm70.4 158.08l-28.48 -64h-92.16l-28.48 64h149.12z"]},vsReactions:{prefix:"vs",iconName:"reactions",icon:[512,512,[],"f000","M384 240c0 5.408 -0.32 10.752 -0.864 16h32.16A176 176 0 1 0 256 415.296v-32.16A144 144 0 1 1 384 240zM176 224a32 32 0 1 0 0 -64 32 32 0 0 0 0 64zm64 80c22.784 0 43.36 -9.536 57.92 -24.832l22.624 22.656A111.68 111.68 0 0 1 240 336a111.68 111.68 0 0 1 -81.76 -35.456l22.624 -22.656A79.808 79.808 0 0 0 240 304zm64 -80a32 32 0 1 0 0 -64 32 32 0 0 0 0 64zm80 96h32v64h64v32h-64v64h-32v-64h-64v-32h64v-64z"]},vsRecordKeys:Vt,vsRecord:{prefix:"vs",iconName:"record",icon:[512,512,[],"f000","M256 320a64 64 0 1 0 0 -128 64 64 0 0 0 0 128zm19.2 -288c51.2 3.2 99.2 28.8 134.4 64 41.6 44.8 64 99.2 64 163.2 0 51.2 -19.2 99.2 -51.2 140.8 -32 38.4 -76.8 67.2 -128 76.8 -51.2 9.6 -102.4 3.2 -147.2 -22.4 -44.8 -25.6 -80 -64 -99.2 -112C28.8 294.4 25.6 240 41.6 192c16 -51.2 44.8 -92.8 89.6 -121.6C172.8 41.6 224 28.8 275.2 32zm16 412.8c41.6 -9.6 80 -32 108.8 -67.2 25.6 -35.2 41.6 -76.8 38.4 -121.6 0 -51.2 -19.2 -102.4 -54.4 -137.6 -32 -32 -70.4 -51.2 -115.2 -54.4 -41.6 -3.2 -86.4 6.4 -121.6 32 -35.2 25.6 -60.8 60.8 -73.6 105.6 -12.8 41.6 -12.8 86.4 6.4 128 19.2 41.6 48 73.6 86.4 96 38.4 22.4 83.2 28.8 124.8 19.2z"]},vsRedo:{prefix:"vs",iconName:"redo",icon:[512,512,[],"f000","M400 64v112L384 192H272V160h80.672l-30.112 -30.112a113.664 113.664 0 1 0 -160.736 160.736l166.304 166.336 -23.04 23.04 -166.336 -166.336A146.24 146.24 0 0 1 345.6 106.848l22.4 22.4V64h32z"]},vsReferences:{prefix:"vs",iconName:"references",icon:[512,512,[],"f000","M236.907 97.301l-73.173 73.109 -24.192 -23.893 44.16 -44.373h-102.4a51.2 51.2 0 1 0 0 102.4h18.987v34.133h-18.773a85.333 85.333 0 0 1 0 -170.475h102.4L139.52 24.107 163.733 0l73.173 73.216v24.107zM354.56 512h-204.8l-17.067 -17.067V222.123l17.067 -17.067h204.8l17.067 17.067V494.933l-17.067 17.067zm-187.733 -34.133h170.667V239.189h-170.667V477.867zm119.467 -443.691h204.8l17.067 17.067v272.768l-17.067 17.067h-85.333v-34.133h68.267V68.267h-170.667v102.123h-34.133V51.221l17.067 -17.067zm17.067 238.635h-102.4v34.133h102.4v-34.133zm-102.4 68.267h102.4v34.133h-102.4v-34.133zm102.4 68.267h-102.4v34.133h102.4v-34.133zm34.133 -307.2h102.4v34.133h-102.4v-34.133zm102.4 136.533h-34.133v34.133h34.133v-34.133zm-71.211 -67.755v-0.512h71.211v34.133h-37.589l-33.621 -33.621z"]},vsRefresh:zt,vsRegex:{prefix:"vs",iconName:"regex",icon:[512,512,[],"f000","M320.384 64h31.232v99.616l81.92 -49.824 15.552 28.32L367.04 192l82.048 49.888 -15.52 28.32 -81.952 -49.824V320h-31.232V220.384l-81.92 49.824 -15.552 -28.32L304.96 192 222.912 142.112l15.52 -28.32 81.952 49.824V64zM64 320h128v128H64v-128z"]},vsRemoteExplorer:{prefix:"vs",iconName:"remote-explorer",icon:[512,512,[],"f000","M28.672 45.333h433.323l16.683 16.661v183.445a166.933 166.933 0 0 0 -33.344 -19.456V78.677H45.333V378.667h166.677a166.677 166.677 0 0 0 33.323 100.011H112v-33.344h100.011v-33.344H28.672l-16.683 -16.64V61.973l16.683 -16.661zM378.667 245.333a133.333 133.333 0 1 0 0 266.667 133.333 133.333 0 0 0 0 -266.667zm0 233.344a100.011 100.011 0 1 1 0 -200.043 100.011 100.011 0 0 1 0 200.043zm55.531 -66.816L388.267 365.931 434.197 320l13.803 13.781 -32.128 32.149L448 398.059l-13.803 13.803zM320 367.915l32.128 32.149L320 432.192l13.803 13.803 45.931 -45.931 -45.931 -45.931 -13.803 13.781z"]},vsRemote:{prefix:"vs",iconName:"remote",icon:[512,512,[],"f000","M412.928 306.24L285.696 179.072l127.232 -127.232 -19.808 -19.84L256 169.152v19.808l137.12 137.12 19.84 -19.776zM96 179.84l130.304 130.24L96 440.416l19.808 19.776L256 320v-19.808L115.808 160 96 179.808z"]},vsRemove:Ut,vsReplaceAll:{prefix:"vs",iconName:"replace-all",icon:[512,512,[],"f000","M371.2 85.664c4.704 -9.92 11.392 -14.88 20.032 -14.88 7.936 0 14.08 3.776 18.336 11.296 4.288 7.552 6.432 17.824 6.432 30.912 0 14.176 -2.496 25.536 -7.52 34.144 -4.992 8.576 -11.68 12.864 -20.064 12.864 -7.584 0 -13.312 -4 -17.184 -11.968h-0.256v9.92H352V32h18.976v53.664h0.256zm-0.512 35.2a24.96 24.96 0 0 0 3.424 13.632c2.272 3.616 5.216 5.408 8.768 5.408 4.352 0 7.68 -2.304 10.048 -6.912 2.4 -4.64 3.616 -11.2 3.616 -19.68 0 -7.04 -1.12 -12.48 -3.328 -16.448 -2.144 -3.968 -5.248 -5.984 -9.28 -5.984 -3.84 0 -7.008 1.984 -9.504 5.92a28.352 28.352 0 0 0 -3.744 15.36v8.704zM131.84 246.24L64 178.176l21.184 -21.184 32.192 32v-48.32A44.48 44.48 0 0 1 161.76 96H236.8v28.96H161.76a15.68 15.68 0 0 0 -14.976 15.776l0.224 48 30.368 -30.208 20.992 20.992 -66.56 66.72zM299.392 157.76H320V103.04C320 77.056 309.92 64 289.792 64c-4.32 0 -9.12 0.768 -14.4 2.336a46.208 46.208 0 0 0 -12.416 5.344v21.28c7.584 -6.496 15.584 -9.728 24 -9.728 8.352 0 12.544 4.992 12.544 15.008l-19.2 3.296c-16.192 2.752 -24.32 12.992 -24.32 30.752 0 8.416 1.952 15.136 5.856 20.192A19.52 19.52 0 0 0 278.08 160c9.28 0 16.288 -5.12 21.024 -15.36h0.288v13.12zm0.128 -43.36v6.176a24 24 0 0 1 -3.84 13.952 11.776 11.776 0 0 1 -10.016 5.44 8.832 8.832 0 0 1 -7.04 -3.04 12.16 12.16 0 0 1 -2.56 -7.936c0 -7.104 3.52 -11.232 10.624 -12.448l12.8 -2.144zM224 413.76h-20.608v-13.12h-0.288c-4.736 10.24 -11.744 15.36 -21.024 15.36a19.52 19.52 0 0 1 -16.224 -7.52c-3.904 -5.056 -5.856 -11.776 -5.856 -20.16 0 -17.792 8.128 -28.032 24.32 -30.784l19.2 -3.296c0 -10.016 -4.16 -15.04 -12.544 -15.04 -8.416 0 -16.416 3.264 -24 9.76v-21.28c3.04 -2.016 7.168 -3.808 12.416 -5.344 5.28 -1.568 10.08 -2.336 14.4 -2.336 20.16 0 30.208 13.024 30.208 39.04v54.72zm-20.48 -37.184v-6.176l-12.8 2.176c-7.104 1.184 -10.656 5.312 -10.656 12.416 0 3.2 0.864 5.856 2.56 7.936a8.832 8.832 0 0 0 7.04 3.04 11.776 11.776 0 0 0 9.984 -5.44c2.56 -3.712 3.84 -8.32 3.84 -13.952zM296.384 416c10.272 0 18.176 -1.856 23.616 -5.536v-22.72a28.8 28.8 0 0 1 -17.664 6.624 19.808 19.808 0 0 1 -16 -6.88c-3.84 -4.64 -5.792 -11.04 -5.792 -19.136 0 -8.32 2.016 -14.848 6.048 -19.584a20.608 20.608 0 0 1 16.512 -7.136c6.208 0 11.84 2.208 16.896 6.624v-23.968c-4.128 -2.88 -10.816 -4.288 -20.032 -4.288 -13.344 0 -24.032 4.48 -32.032 13.504 -7.968 8.96 -11.936 21.184 -11.936 36.736 0 13.44 3.712 24.448 11.168 32.96 7.424 8.544 17.184 12.8 29.216 12.8zM64 288l32 -32h288l32 32v160l-32 32H96l-32 -32V288zm32 0v160h288V288H96zm96 -64l32 -32h224l32 32v160l-32 32V224H192z"]},vsReplace:{prefix:"vs",iconName:"replace",icon:[512,512,[],"f000","M103.072 119.648l72.352 72.608L246.4 121.088l-22.4 -22.4 -32.384 32.224 -0.256 -51.2a16.736 16.736 0 0 1 16 -16.832H256V32H207.36A47.424 47.424 0 0 0 160 79.648V131.2L125.664 97.056l-22.592 22.592zm213.44 57.408h0.32c5.856 9.952 14.432 14.944 25.792 14.944 12.576 0 22.592 -5.376 30.08 -16.096 7.552 -10.72 11.296 -24.96 11.296 -42.656 0 -16.352 -3.2 -29.216 -9.632 -38.624 -6.432 -9.44 -15.616 -14.144 -27.52 -14.144 -12.96 0 -22.976 6.208 -30.016 18.592h-0.32V32H288v157.408h28.48v-12.352zm-0.48 -33.952v-10.88c0 -7.936 1.856 -14.336 5.6 -19.232a17.28 17.28 0 0 1 14.24 -7.36 15.68 15.68 0 0 1 13.952 7.456c3.328 4.928 4.96 11.776 4.96 20.576 0 10.56 -1.792 18.784 -5.408 24.576a16.768 16.768 0 0 1 -15.04 8.64 15.84 15.84 0 0 1 -13.152 -6.752 27.296 27.296 0 0 1 -5.12 -17.024zM288 408.608c-8.192 4.928 -20 7.392 -35.456 7.392 -18.016 0 -32.64 -5.696 -43.808 -17.056 -11.168 -11.36 -16.736 -26.016 -16.736 -43.968 0 -20.736 5.952 -37.056 17.92 -48.96 11.968 -12.032 28 -18.016 48 -18.016 13.856 0 23.872 1.92 30.08 5.728v31.936a40.32 40.32 0 0 0 -25.344 -8.832c-10.4 0 -18.656 3.2 -24.768 9.536 -6.08 6.272 -9.056 14.976 -9.056 26.112 0 10.816 2.88 19.296 8.704 25.504 5.824 6.112 13.792 9.184 23.968 9.184 9.024 0 17.856 -2.944 26.496 -8.832v30.272zM128 224L96 256v192l32 32h224l32 -32V256l-32 -32H128zm0 32h224v192H128V256z"]},vsReply:{prefix:"vs",iconName:"reply",icon:[512,512,[],"f000","M201.792 68.672l-128.64 128.64v22.656l128.64 128.64 22.656 -22.624L121.824 223.36H182.08c90.016 0 147.36 19.36 182.56 55.328 35.264 36 51.68 92.064 51.68 173.472v11.2h32v-11.2c0 -84.672 -16.864 -151.04 -60.8 -195.872C343.52 211.36 275.744 191.36 182.08 191.36H124.384l100.064 -100.032 -22.656 -22.656z"]},vsRepoClone:{prefix:"vs",iconName:"repo-clone",icon:[512,512,[],"f000","M416 320H128V64h128V32H119.68a60.8 60.8 0 0 0 -21.44 4.16 53.12 53.12 0 0 0 -18.24 13.12 55.36 55.36 0 0 0 -11.84 18.88 53.76 53.76 0 0 0 -4.16 19.84v304a56 56 0 0 0 34.24 51.84 60.8 60.8 0 0 0 21.44 4.16H128v-32h-8.32a23.04 23.04 0 0 1 -9.28 -1.92 24.96 24.96 0 0 1 -12.8 -12.8 29.76 29.76 0 0 1 0 -9.28v-16a29.76 29.76 0 0 1 0 -9.28 24.96 24.96 0 0 1 12.8 -12.8 23.04 23.04 0 0 1 9.28 -1.92H416v64H288v32h144l16 -16V288h-32v32zM192 96H160v32h32V96zM160 160h32v32H160V160zm0 64h32v32H160V224zm8.96 256H160v-96h96v96h-8.96L208 431.68 168.96 480zM320 32h144l16 16v192l-16 16H384v32h-32V256h-32a32 32 0 0 1 -32 -32V64a32 32 0 0 1 32 -32zm16 192h16V192h-16a16 16 0 0 0 0 32zM384 224h64V192h-64v32zm-32 -64h96V64h-96v96z"]},vsRepoForcePush:{prefix:"vs",iconName:"repo-force-push",icon:[512,512,[],"f000","M119.68 32h312.32l16 16v384l-16 16H320v-32h96v-64h-96v-32h96V64H128v256h96v32H119.68a23.68 23.68 0 0 0 -23.68 24v16a23.68 23.68 0 0 0 23.68 24H224v32H119.68A55.68 55.68 0 0 1 64 392v-304A55.68 55.68 0 0 1 119.68 32zm51.2 154.56l22.72 22.4L256 146.56v46.4L172.16 276.8l22.72 22.4 61.44 -61.44V480h32V234.496l64.96 64.704 22.4 -22.4L288 188.8V145.216l64 63.744 22.4 -22.4L284.16 96h-22.72L170.88 186.56z"]},vsRepoForked:{prefix:"vs",iconName:"repo-forked",icon:[512,512,[],"f000","M448 128a64 64 0 1 0 -79.04 62.08V224a15.36 15.36 0 0 1 -8.64 14.08L271.68 284.16l-88.32 -44.8A15.68 15.68 0 0 1 174.72 224V190.08a64 64 0 1 0 -32 0V224a48.32 48.32 0 0 0 26.24 42.88L256 311.68v42.24a64 64 0 1 0 32 0V311.68l86.4 -43.52A47.68 47.68 0 0 0 400.64 224V189.44A64 64 0 0 0 448 128zM128 128a32 32 0 1 1 64 0 32 32 0 0 1 -64 0zm175.04 288a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zM384 160a32 32 0 1 1 0 -64 32 32 0 0 1 0 64z"]},vsRepoPull:{prefix:"vs",iconName:"repo-pull",icon:[512,512,[],"f000","M416 48V96h-32V64H96v256h320v112l-16 16H256v-32h128v-64H87.52a23.04 23.04 0 0 0 -9.12 1.92 23.68 23.68 0 0 0 -12.8 12.8 29.76 29.76 0 0 0 -1.6 9.28v16a29.76 29.76 0 0 0 1.6 9.28 23.68 23.68 0 0 0 12.8 12.8c2.912 1.28 6.08 1.92 9.28 1.92H96v32h-8.32a60.8 60.8 0 0 1 -21.44 -4.16 56.64 56.64 0 0 1 -30.08 -30.4 54.4 54.4 0 0 1 -4.16 -21.44v-304a54.4 54.4 0 0 1 4.16 -19.84 56.64 56.64 0 0 1 30.08 -32A60.8 60.8 0 0 1 87.68 32h312.32l16 16zM64 325.44V87.936v237.504zM160 96H128v32h32V96zm0 64H128v32h32V160zM128 224h32v32H128V224zm258.24 -115.52l-22.4 22.72 61.44 61.44H224v32h204.48l-64.64 64.96 22.4 22.4 90.56 -90.24v-22.72l-90.56 -90.56zM176 431.68L136.96 480H128v-96h96v96h-8.96L176 431.68z"]},vsRepoPush:{prefix:"vs",iconName:"repo-push",icon:[512,512,[],"f000","M432 32H119.68A55.68 55.68 0 0 0 64 88v304A55.68 55.68 0 0 0 119.68 448H224v-32H119.68a23.68 23.68 0 0 1 -23.68 -24v-16a23.68 23.68 0 0 1 23.68 -24H224v-32H128V64h288v256h-96v32h96v64h-96v32h112l16 -16v-384l-16 -16zM96 87.36a24 24 0 0 0 0 0.64v237.44zM192 96H160v32h32V96zm-19.84 180.8l22.72 22.4 61.44 -61.44V480h32V234.496l64.96 64.704 22.4 -22.4 -90.24 -90.56h-22.72L172.16 276.8zM160 160h32v32H160V160z"]},vsRepo:{prefix:"vs",iconName:"repo",icon:[512,512,[],"f000","M448 320V48l-16 -16H119.68a60.8 60.8 0 0 0 -21.44 4.16 56.64 56.64 0 0 0 -30.08 32 54.4 54.4 0 0 0 -4.16 19.84v304a54.4 54.4 0 0 0 4.16 21.44c5.664 13.664 16.48 24.576 30.08 30.4a60.8 60.8 0 0 0 21.44 4.16H128v-32h-8.32a23.04 23.04 0 0 1 -9.28 -1.92 23.68 23.68 0 0 1 -12.8 -12.8 29.76 29.76 0 0 1 -1.6 -9.28v-16a29.76 29.76 0 0 1 1.6 -9.28 23.68 23.68 0 0 1 12.8 -12.8 23.04 23.04 0 0 1 9.152 -1.92H416v64H288v32h144l16 -16V320zM128 320V64h288v256H128zm32 -224h32v32H160V96zm0 64h32v32H160V160zm32 64H160v32h32V224zm16 207.68L168.96 480H160v-96h96v96h-8.96L208 431.68z"]},vsReport:{prefix:"vs",iconName:"report",icon:[512,512,[],"f000","M48 32h416l16 16v320l-16 16H246.624l-91.296 91.328L128 464V384H48l-16 -16v-320l16 -16zm192 320H448V64H64v288h80l16 16v57.376l68.672 -68.704L240 352zm0 -256h32v160h-32V96zm0 224h32V288h-32v32z"]},vsRequestChanges:{prefix:"vs",iconName:"request-changes",icon:[512,512,[],"f000","M464 32h-416l-16 16v320l16 16H128v80l27.328 11.328L246.624 384H464l16 -16v-320l-16 -16zM448 352H240l-11.328 4.672L160 425.376V368l-16 -16H64V64h384v288zm-128 -32H192V287.328h128V320zM240 96h32v64h64v32h-64v64h-32V192h-64V160h64V96z"]},vsRocket:{prefix:"vs",iconName:"rocket",icon:[512,512,[],"f000","M463.712 32c-115.136 0.128 -212.928 63.456 -282.72 128H48l-16 16v96l4.704 11.328 31.712 31.712 0.032 0.288 128 128 0.288 0.032 31.968 31.968L240 480h96l16 -16v-132.928c64.608 -69.696 127.872 -167.456 127.744 -283.072l-16.032 -16zM64 192h84.576a762.496 762.496 0 0 0 -71.2 86.72L64 265.408V192zm182.4 256l-13.44 -13.536a754.88 754.88 0 0 0 86.88 -70.912V448H246.4zm-36.576 -36.608L100.352 301.984C132.096 256 268.128 75.36 447.296 64.512c-10.432 179.584 -191.584 315.296 -237.472 346.88zM128 480v-32H64v-64H32v96h96zm215.936 -245.344a48 48 0 1 0 -79.872 -53.312 48 48 0 0 0 79.84 53.312z"]},vsRootFolderOpened:{prefix:"vs",iconName:"root-folder-opened",icon:[512,512,[],"f000","M32 200.224V80l16 -16h160l11.2 4.8 27.52 27.2h185.28l16 16V192h36.16l15.36 20.16 -84.16 224 -15.36 11.84H279.776a175.36 175.36 0 0 0 21.024 -32h87.36l75.84 -192H279.776a177.088 177.088 0 0 0 -23.04 -23.168l4.064 -4.032L272 192H416V128H240l-11.2 -4.8L201.28 96H64l0.32 83.008c-11.552 5.888 -22.4 13.024 -32.32 21.216zM192 336a48 48 0 1 1 -96 0 48 48 0 0 1 96 0zm64 0a112 112 0 1 1 -224 0 112 112 0 0 1 224 0zM144 416a80 80 0 1 0 0 -160 80 80 0 0 0 0 160z"]},vsRootFolder:{prefix:"vs",iconName:"root-folder",icon:[512,512,[],"f000","M246.72 96h217.28l16.32 16v320l-16 16H279.776a175.36 175.36 0 0 0 21.024 -32h146.88v-48.32l0.32 -128v-48H246.08l-0.544 0.544a175.808 175.808 0 0 0 -28.192 -16.256l11.136 -11.168 11.2 -4.8h208l0.32 -31.68H240l-11.52 -4.8 -27.2 -27.2H64V179.2a174.4 174.4 0 0 0 -31.68 20.768V80l16 -16h160l11.2 4.8 27.2 27.2zM192 336a48 48 0 1 1 -96 0 48 48 0 0 1 96 0zm64 0a112 112 0 1 1 -224 0 112 112 0 0 1 224 0zM144 416a80 80 0 1 0 0 -160 80 80 0 0 0 0 160z"]},vsRss:{prefix:"vs",iconName:"rss",icon:[512,512,[],"f000","M160 416H96v-64c35.52 0 64 28.48 64 64zM96 96v32a288 288 0 0 1 288 288h32C416 239.36 272.64 96 96 96zm0 128v32c88 0 160 72 160 160h32c0 -105.92 -86.08 -192 -192 -192z"]},vsRuby:Bt,vsRunAbove:{prefix:"vs",iconName:"run-above",icon:[512,512,[],"f000","M56.64 32.32L32 45.44v384l24.96 13.44 288 -192v-26.56l-288.32 -192zM64 399.68V75.52l243.2 162.24L64 399.68zM388.8 256h22.72l80 80 -22.72 22.72L416 305.92V480h-32V305.6l-52.8 52.8 -22.4 -22.4 80 -80z"]},vsRunAll:Wt,vsRunBelow:{prefix:"vs",iconName:"run-below",icon:[512,512,[],"f000","M57.6 32.32l-24.96 13.12v384l24.96 13.44 288 -192v-26.56l-288 -192zm7.04 367.36V75.52l243.2 162.24 -243.2 161.92zM411.2 480h-22.72l-80 -80 22.72 -22.72L384 430.08V256h32v174.4l52.8 -52.8 22.72 22.72L411.2 480z"]},vsRunErrors:{prefix:"vs",iconName:"run-errors",icon:[512,512,[],"f000","M160 77.12L184.96 64l288 192v26.56L288 405.856v-38.4l147.2 -98.016L192 107.2V224H160V77.12zm-4.096 172.736c-27.2 -1.696 -54.56 5.088 -76.896 20.512 -24.096 15.52 -39.456 37.888 -47.968 64.96 -8.608 25.92 -6.816 55.04 3.392 80.576a120.768 120.768 0 0 0 53.056 59.936c24.192 13.824 51.712 17.184 78.944 12.096 27.552 -5.184 51.52 -20.64 68.576 -41.12l0.16 -0.192c16.928 -21.984 27.264 -47.648 27.264 -75.264a124.224 124.224 0 0 0 -34.112 -87.04l-0.192 -0.16c-18.72 -18.72 -44.416 -32.576 -72.224 -34.304zM94.432 293.856c16.384 -11.936 37.504 -16.544 57.344 -15.04h0.032c20.992 1.536 39.04 10.496 54.304 25.728 16.512 16.512 25.696 40.768 25.696 65.216v0.448c1.504 20.768 -5.856 40.32 -18.112 57.248 -13.632 16.576 -31.776 27.2 -51.52 31.712a80.384 80.384 0 0 1 -58.56 -9.024c-18.304 -10.656 -32 -25.856 -41.216 -45.76 -8.96 -19.424 -9.024 -40.48 -2.912 -60.32v-0.128a91.68 91.68 0 0 1 34.944 -50.08zm49.728 58.56L105.344 311.936l-20.416 20.384 39.04 40.64 -39.04 40.64 20.416 20.384L144.16 393.6l38.816 40.448 20.416 -20.384 -39.008 -40.64 39.008 -40.64 -20.416 -20.384 -38.816 40.416z"]},vsSaveAll:{prefix:"vs",iconName:"save-all",icon:[512,512,[],"f000","M475.2 84.8l-48 -48L416 32H143.36l-16 16V128H48l-16 16v320l16 16h320l16 -16V384h80l16 -16V96l-4.8 -11.2zM352 448H64V160h32v98.24h192V160h25.28L352 198.72V448zM192 224V160h64v64H192zm256 128h-64V192l-4.8 -11.2 -48 -48L320 128H160V64h249.92l38.72 38.72L448 352z"]},vsSaveAs:{prefix:"vs",iconName:"save-as",icon:[512,512,[],"f000","M353.28 42.56L406.72 96l9.28 22.72v10.56h-16l-16 16v-26.56l-53.44 -53.44H320v128H128v-128H64v320h96l-16 32H64l-32 -32v-320l32 -32h266.56l22.72 9.28zM224 160h64V64H224v96zm208 0L480 208l-0.64 22.08 -176 176 -4.16 3.84 -11.84 11.84 -3.2 2.88 -96 48 -21.44 -21.44 48 -96 2.88 -3.2 11.84 -11.84 3.84 -4.16 176 -176h22.72zm-199.04 231.68l-16.64 32 33.28 -15.36 -16.64 -16.64zm22.08 -32.96l25.28 25.28 164.8 -164.8 -25.28 -25.28 -164.8 164.8z"]},vsSave:Gt,vsScreenFull:{prefix:"vs",iconName:"screen-full",icon:[512,512,[],"f000","M96 384h320V128H96v256zm64 -192h192v128H160V192zM64 192H32V80l16 -16H160v32H64v96zm416 -112V192h-32V96h-96V64h112l16 16zM448 320h32v112l-16 16H352v-32h96v-96zM64 416h96v32H48l-16 -16V320h32v96z"]},vsScreenNormal:{prefix:"vs",iconName:"screen-normal",icon:[512,512,[],"f000","M112 128H32V96h64V32h32v80l-16 16zM416 96V32h-32v80l16 16H480V96h-64zm-32 304V480h32v-64h64v-32h-80l-16 16zM32 384v32h64v64h32v-80l-16 -16H32zm352 -48l-16 16h-224l-16 -16v-160l16 -16h224l16 16v160zM320 224H192v64h128V224z"]},vsSearchStop:{prefix:"vs",iconName:"search-stop",icon:[512,512,[],"f000","M183.616 106.176a144 144 0 0 0 -28.064 163.936A143.36 143.36 0 0 0 195.2 320a147.84 147.84 0 0 0 -3.2 32v5.44c-5.12 -3.52 -10.24 -7.04 -15.04 -10.88L56 464 32 442.88l121.6 -118.08a176 176 0 1 1 307.84 -116.8c0 8.576 -0.64 17.12 -1.92 25.6a167.424 167.424 0 0 0 -30.08 -21.76V208a144 144 0 0 0 -245.824 -101.824zm97.28 139.392a128 128 0 1 1 142.208 212.864 128 128 0 0 1 -142.208 -212.864zm3.2 174.304A96 96 0 0 0 352 448a96 96 0 0 0 55.68 -17.6L273.6 296.32A96 96 0 0 0 256 352a96 96 0 0 0 28.128 67.872zm12.224 -146.24l134.08 134.048A96 96 0 0 0 448 352a96 96 0 0 0 -96 -96 96 96 0 0 0 -55.68 17.6z"]},vsSearch:qt,vsServerEnvironment:{prefix:"vs",iconName:"server-environment",icon:[512,512,[],"f000","M192 96h128v32H192V96zm0 192h128v32H192V288zm0 64h128v32H192v-32zm292.48 160H27.52l40 -160H128V64a30.4 30.4 0 0 1 2.496 -12.256c1.664 -3.84 3.936 -7.232 6.752 -10.24a29.504 29.504 0 0 1 10.24 -7.008A32.32 32.32 0 0 1 160 32h192a30.4 30.4 0 0 1 12.256 2.496c3.84 1.664 7.232 3.936 10.24 6.752a29.504 29.504 0 0 1 7.008 10.24c1.664 4 2.496 8.192 2.496 12.512v288h60.48l40 160zM160 416h192V64H160v352zm283.52 64l-24 -96H384v64H128v-64H92.48l-24 96h375.04z"]},vsServerProcess:{prefix:"vs",iconName:"server-process",icon:[512,512,[],"f000","M48 64h416l16 16V288h-32V192H64v224h224v32H48l-16 -16v-352l16 -16zM64 160h384V96H64v64zm160 224v-35.008a52.256 52.256 0 0 1 -15.008 -8.48l-30.24 17.248 -16 -27.52 29.984 -17.504a50.24 50.24 0 0 1 0 -17.504l-29.984 -17.472 16 -27.52 30.24 17.28c4.832 -3.84 9.856 -6.688 15.008 -8.512V224h32v35.008a47.36 47.36 0 0 1 15.008 8.48l30.24 -17.248 16 27.52 -29.984 17.504a50.24 50.24 0 0 1 0 17.472l29.984 17.504 -16 27.52 -30.24 -17.28a57.824 57.824 0 0 1 -15.008 8.512V384H224zm-8 -80c0 6.656 2.336 12.32 7.008 16.992a23.136 23.136 0 0 0 16.992 7.008 23.136 23.136 0 0 0 16.992 -7.008 23.136 23.136 0 0 0 7.008 -16.992 23.136 23.136 0 0 0 -7.008 -16.992 23.136 23.136 0 0 0 -16.992 -7.008 23.136 23.136 0 0 0 -16.992 7.008 23.136 23.136 0 0 0 -7.008 16.992zm170.688 176v-35.008a52.288 52.288 0 0 1 -15.008 -8.48l-30.24 17.248 -16 -27.52 30.016 -17.504a50.304 50.304 0 0 1 0 -17.504l-30.016 -17.472 16 -27.52 30.24 17.28c4.832 -3.84 9.856 -6.688 15.04 -8.512V320h32v35.008a47.552 47.552 0 0 1 14.976 8.48l30.24 -17.248 16 27.52 -29.984 17.504a49.984 49.984 0 0 1 0 17.472l29.984 17.504 -16 27.52 -30.24 -17.28a57.792 57.792 0 0 1 -15.008 8.512V480h-32zm-8 -80c0 6.656 2.336 12.32 7.008 16.992a23.136 23.136 0 0 0 16.992 7.008 23.136 23.136 0 0 0 16.992 -7.008 23.136 23.136 0 0 0 7.04 -16.992 23.136 23.136 0 0 0 -7.04 -16.992 23.136 23.136 0 0 0 -16.96 -7.008 23.136 23.136 0 0 0 -17.024 7.008 23.136 23.136 0 0 0 -7.008 16.992z"]},vsServer:{prefix:"vs",iconName:"server",icon:[512,512,[],"f000","M80 160L64 144v-96l16 -16h352l16 16v96l-16 16h-352zM320 64H288v32H256V64H224v32H192V64H160v32H128V64H96v64h320V64h-64v32h-32V64zm-240 256L64 304v-96l16 -16h352l16 16v96l-16 16h-352zM192 224H160v32H128V224H96v64h320V224h-64v32h-32V224H288v32H256V224H224v32H192V224zm240 256l16 -16v-96l-16 -16h-352l-16 16v96l16 16h352zM96 448v-64h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h64v64H96z"]},vsSettingsGear:{prefix:"vs",iconName:"settings-gear",icon:[512,512,[],"f000","M423.467 186.667l88.533 17.707v103.253l-88.533 17.707 50.133 75.093 -73.173 73.173 -75.093 -50.133 -17.707 88.533H204.373l-17.707 -88.533 -75.093 50.133 -73.173 -73.173 50.133 -75.093L0 307.627V204.373l88.533 -17.707L38.4 111.573 111.573 38.4l75.093 50.133L204.373 0h103.253l17.707 88.533 75.093 -50.133 73.173 73.173 -50.133 75.093zm-33.493 108.16l85.333 -17.28v-42.667l-85.333 -17.28 -11.52 -27.733 48.853 -73.173 -30.507 -30.507 -73.173 48.853 -27.733 -11.52 -17.28 -85.333h-42.667l-17.28 85.333 -27.733 11.52 -73.173 -48.853 -30.507 30.507L136.107 189.867l-11.52 27.733 -85.333 17.28v42.667l85.333 17.28 11.52 27.733 -48.853 73.173 30.507 30.507 73.173 -48.853 27.733 11.52 17.28 85.333h42.667l17.28 -85.333 27.733 -11.52 73.173 48.853 30.507 -30.507 -48.853 -73.173 11.52 -27.733zm-174.635 -99.669A73.173 73.173 0 0 1 256 182.827 73.387 73.387 0 0 1 329.173 256a73.173 73.173 0 1 1 -113.835 -60.843zm20.395 91.179c5.995 4.011 13.056 6.144 20.267 6.144A36.267 36.267 0 0 0 292.48 256a36.48 36.48 0 1 0 -56.747 30.336z"]},vsSettings:{prefix:"vs",iconName:"settings",icon:[512,512,[],"f000","M112 64h-32v160h32V64zm195.2 160H204.8L192 206.4v-32L204.8 160h102.4l12.8 16v32l-12.8 16zm-160 96H44.8L32 304v-32l12.8 -16h102.4l12.8 16v32l-12.8 16zm124.8 -256h-32v64h32V64zm-32 192h32v192h-32V256zm-128 96h-32v96h32v-96zm252.8 0h102.08l12.8 -16v-30.4l-12.8 -16H364.8l-12.8 16v30.4l12.8 16zm67.2 -288h-32v192h32V64zm-32 320h32v64h-32v-64z"]},vsShield:{prefix:"vs",iconName:"shield",icon:[512,512,[],"f000","M263.872 470.816a889.344 889.344 0 0 1 -48.16 -30.496c-16.032 -10.88 -31.456 -22.624 -46.208 -35.2 -14.656 -12.64 -28.416 -26.24 -41.216 -40.768 -12.8 -14.56 -24.096 -30.4 -33.6 -47.296a249.6 249.6 0 0 1 -22.4 -54.08A225.312 225.312 0 0 1 64 201.6V99.2l16 -16c10.656 0 20.992 -0.352 31.04 -1.152 9.472 -0.736 18.912 -2.112 28.224 -4.096 9.088 -1.984 17.984 -4.736 26.624 -8.192 9.088 -3.776 17.824 -8.352 26.112 -13.664a154.56 154.56 0 0 1 37.888 -18.08 153.6 153.6 0 0 1 64 -4.544 128.576 128.576 0 0 1 39.584 12.256c6.368 3.104 12.544 6.528 18.56 10.304 8.32 5.344 17.12 9.92 26.272 13.696 8.64 3.488 17.504 6.208 26.592 8.192 9.312 1.984 18.784 3.392 28.288 4.128 9.952 0.768 20.288 1.12 30.944 1.12l16 16v102.4a225.376 225.376 0 0 1 -8.192 61.408 249.728 249.728 0 0 1 -22.4 54.08 280.032 280.032 0 0 1 -33.6 47.296c-12.8 14.464 -26.528 28.064 -41.152 40.64a510.08 510.08 0 0 1 -46.336 35.2 918.72 918.72 0 0 1 -48.32 30.592h-16.256zM96 114.88V201.6c-0.128 17.76 2.24 35.52 7.04 52.64a214.4 214.4 0 0 0 19.52 47.136c8.416 14.944 18.4 28.96 29.76 41.856 11.84 13.344 24.512 25.92 38.016 37.568 13.824 11.776 28.256 22.784 43.264 32.96 12.8 8.544 25.6 16.736 38.4 24.608 12.8 -7.744 25.6 -15.936 38.4 -24.576 15.04 -10.208 29.536 -21.216 43.36 -32.992 13.472 -11.648 26.144 -24.192 37.952 -37.504a249.6 249.6 0 0 0 29.76 -41.856c8.352 -14.88 14.912 -30.72 19.52 -47.136 4.8 -17.184 7.136 -34.88 7.04 -52.704V114.88c-5.088 0 -10.016 -0.384 -14.88 -0.736l-2.528 -0.192a254.4 254.4 0 0 1 -32.576 -4.704 195.584 195.584 0 0 1 -63.232 -26.048 165.312 165.312 0 0 0 -15.424 -8.64 99.936 99.936 0 0 0 -30.176 -9.28 117.952 117.952 0 0 0 -49.856 3.392c-10.624 3.456 -20.768 8.32 -30.08 14.464 -9.984 6.4 -20.48 11.904 -31.456 16.416a204.8 204.8 0 0 1 -32 9.824c-10.72 2.24 -21.6 3.84 -32.544 4.672 -5.568 0.32 -11.36 0.64 -17.28 0.832zm194.08 137.6a48 48 0 1 0 -36.16 0L240 336h64l-13.92 -83.52z"]},vsSignIn:{prefix:"vs",iconName:"sign-in",icon:[512,512,[],"f000","M352.64 120.64l0.32 -0.32 31.68 31.68V80l-16 -16h-288l-16.32 16v15.776L64 96v329.28l11.52 14.72 160 55.04L256 480v-32h112.64l16 -16v-72l-32 32V416H256V150.72l-10.56 -14.72L129.152 96h223.488v24.64zM224 456.96l-128 -42.88V119.04l128 42.88v295.04zm98.88 -216h159.04v32h-157.76l50.88 51.2 -22.72 22.4 -79.04 -78.72v-22.72l79.68 -79.36 22.4 22.4 -52.48 52.8z"]},vsSignOut:{prefix:"vs",iconName:"sign-out",icon:[512,512,[],"f000","M352.64 120.64v49.92l32 -31.68V80l-16 -16h-288l-16 16v15.552L64 96v329.28l11.52 14.72 160 55.04L256 480v-32h112.64l16 -16v-57.92l-32 -32V416H256V150.72l-10.56 -14.72L129.152 96h223.488v24.64zM224 456.96l-128 -42.88V119.04l128 42.88v295.04zm208.64 -185.6H273.6v-32h157.76l-51.2 -51.2 22.72 -22.4 79.04 78.72v22.72l-79.68 79.36 -22.4 -22.4 52.8 -52.8z"]},vsSmiley:{prefix:"vs",iconName:"smiley",icon:[512,512,[],"f000","M131.552 69.76a224 224 0 1 1 248.896 372.48A224 224 0 0 1 131.52 69.76zm17.792 345.888a192 192 0 1 0 213.312 -319.296 192 192 0 0 0 -213.312 319.296zM208 224a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zm160 0a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zM256 352a96 96 0 0 1 -84.8 -50.56l-27.84 15.36a128 128 0 0 0 227.84 -5.12l-28.8 -13.76A96 96 0 0 1 256 352z"]},vsSortPrecedence:{prefix:"vs",iconName:"sort-precedence",icon:[512,512,[],"f000","M224 64L192 96v96h32V96h224v78.496l6.624 -5.12 25.376 25.376V96l-32 -32H224zm32 64h64v64H256V128zM160 288H96v64h64V288zM64 224L32 256v160l32 32h224l32 -32V256L288 224H64zm0 192V256h224v160H64zm192 -96H192v64h64v-64zm160 -192h-32v123.648l-37.824 -37.824 -22.624 22.624 65.12 65.152h22.656l65.12 -65.152 -22.624 -22.624L416 251.648V128z"]},vsSourceControl:{prefix:"vs",iconName:"source-control",icon:[512,512,[],"f000","M448.149 175.403A79.744 79.744 0 0 0 320.96 110.933a79.723 79.723 0 0 0 24.661 140.437 63.744 63.744 0 0 1 -56.917 35.627h-63.787a95.061 95.061 0 0 0 -63.765 24.853V157.867a79.723 79.723 0 1 0 -31.872 0v194.496a80.555 80.555 0 1 0 38.741 2.112 63.787 63.787 0 0 1 56.917 -35.563h63.787a95.659 95.659 0 0 0 90.091 -64.832 79.701 79.701 0 0 0 69.333 -78.656zM97.387 79.744a47.829 47.829 0 1 1 95.659 0 47.829 47.829 0 0 1 -95.659 0zm95.659 350.741a47.829 47.829 0 1 1 -95.659 0 47.829 47.829 0 0 1 95.659 0zm175.381 -207.253a47.829 47.829 0 1 1 0 -95.68 47.829 47.829 0 0 1 0 95.68z"]},vsSplitHorizontal:Kt,vsSplitVertical:{prefix:"vs",iconName:"split-vertical",icon:[512,512,[],"f000","M448 32H96L64 64v352l32 32h352l32 -32V64l-32 -32zm0 384H96V256h352v160zm0 -192H96V64h352v160z"]},vsSquirrel:{prefix:"vs",iconName:"squirrel",icon:[512,512,[],"f000","M177.856 84.544a118.336 118.336 0 0 0 -3.936 -0.32A47.04 47.04 0 0 0 127.968 48.64v41.824a156.736 156.736 0 0 0 -95.776 114.784v12.48c14.688 26.752 60.992 36.16 68.928 37.76 0.864 0.192 1.28 0.288 1.12 0.288 -77.408 10.24 -70.08 71.968 -70.08 71.968a32 32 0 0 0 32 29.76c8.704 -0.608 17.216 -2.56 25.28 -5.76h65.92a96 96 0 0 0 -11.52 32h-10.24a81.6 81.6 0 0 0 -69.44 80.896 13.44 13.44 0 0 0 12.48 15.36h213.664a120.32 120.32 0 0 0 125.728 -133.056 116.768 116.768 0 0 0 -24 -66.88l-3.52 -4.48c-13.76 -17.6 -21.76 -29.088 -17.6 -41.248 4.16 -12.16 11.68 -12.8 11.68 -12.8s5.92 -0.96 14.56 2.88c7.04 4.096 14.72 7.04 22.72 8.64a50.56 50.56 0 0 0 55.552 -28.96c3.04 -6.656 4.576 -13.92 4.576 -21.248 0.192 -22.976 -10.56 -46.56 -23.2 -66.816a159.936 159.936 0 0 0 -49.728 -50.24 127.936 127.936 0 0 0 -84.448 -12.8 97.568 97.568 0 0 0 -53.44 28.48 113.92 113.92 0 0 0 -24.928 43.488 139.456 139.456 0 0 0 -20.352 -23.904v-5.088A47.04 47.04 0 0 0 177.856 48.64v35.904zm169.728 279.648c3.552 23.712 7.04 58.272 -27.744 78.144 -9.472 3.296 -19.456 5.12 -29.536 5.344H102.88a32 32 0 0 1 29.44 -32h40.928v-15.968a57.28 57.28 0 0 1 52.896 -58.4l-20.032 -28.384c-7.552 2.144 -14.816 4.896 -18.464 7.456H84.96a24.128 24.128 0 0 0 -8.448 2.24c-4.416 1.76 -8.768 3.488 -12.672 0.96 -6.4 -4.16 3.52 -35.84 32.32 -35.84h32c15.68 0 18.24 -17.28 18.24 -17.28l8.96 -36.128a108.448 108.448 0 0 1 -91.2 -29.76 108.448 108.448 0 0 1 100.48 -85.056l2.656 0.064c8.32 0.256 13.92 0.448 24.832 5.376 29.76 13.44 68.768 79.008 68.768 79.008l1.92 2.88h5.44v-2.24c-1.92 -14.176 -0.64 -46.848 3.712 -60.48 4.384 -13.568 11.744 -26.048 21.536 -36.48a75.168 75.168 0 0 1 41.6 -21.088 84.448 84.448 0 0 1 59.52 9.28c14.72 9.088 27.2 21.44 36.448 36.064 9.248 14.624 15.232 26.752 17.12 43.968 -0.032 0.64 0 1.504 0.064 2.592 0.224 4.576 0.64 12.48 -4.096 17.504 -4.064 4.32 -14.336 7.36 -21.44 5.76a50.24 50.24 0 0 1 -14.4 -5.76 42.56 42.56 0 0 0 -36.448 -4.16 45.44 45.44 0 0 0 -30.08 32 74.176 74.176 0 0 0 20.48 71.616l3.52 4.48c11.104 13.888 17.472 30.912 18.24 48.64a95.968 95.968 0 0 1 -9.792 45.6 86.656 86.656 0 0 0 -14.848 -41.728l-11.84 11.776zM135.68 160a16 16 0 1 0 0 32 16 16 0 0 0 0 -32z"]},vsStarEmpty:{prefix:"vs",iconName:"star-empty",icon:[512,512,[],"f000","M307.04 200.064L256 32 204.96 200.064H32l139.936 108.8L120 480 256 374.24 392 480l-51.936 -171.136L480 200.064H307.04zm-231.904 15.04H215.04L256 80.224 215.04 215.104H75.136zm113.184 88l-41.824 137.76 41.824 -137.76zm248.544 -88H296.96h139.904zm-280 28.8h75.712L256 166.848l23.424 77.12h75.744l-61.28 47.68 23.392 77.088L256 321.024l-61.28 47.68 23.392 -77.12 -61.28 -47.68z"]},vsStarFull:{prefix:"vs",iconName:"star-full",icon:[512,512,[],"f000","M307.04 200.064L256 32 204.96 200.064H32l139.936 108.8L120 480 256 374.24 392 480l-51.936 -171.136L480 200.064H307.04z"]},vsStarHalf:{prefix:"vs",iconName:"star-half",icon:[512,512,[],"f000","M204.96 200.064L256 32l51.04 168.064H480l-139.936 108.8L392 480 256 374.24 120 480l51.936 -171.136L32 200.064h172.96zM256 321.024l61.28 47.68 -23.392 -77.12 61.28 -47.68H279.424L256 166.848v154.24zm0 -240.8zm180.864 134.88H296.96h139.904z"]},vsStopCircle:{prefix:"vs",iconName:"stop-circle",icon:[512,512,[],"f000","M192 192h128v128H192zm83.2 -160c51.2 3.2 99.2 28.8 134.4 64 41.6 44.8 64 99.2 64 163.2 0 51.2 -19.2 99.2 -51.2 140.8 -32 38.4 -76.8 67.2 -128 76.8 -51.2 9.6 -102.4 3.2 -147.2 -22.4 -44.8 -25.6 -80 -64 -99.2 -112C28.8 294.4 25.6 240 41.6 192c16 -51.2 44.8 -92.8 89.6 -121.6C172.8 41.6 224 28.8 275.2 32zm16 412.8c41.6 -9.6 80 -32 108.8 -67.2 25.6 -35.2 41.6 -76.8 38.4 -121.6 0 -51.2 -19.2 -102.4 -54.4 -137.6 -32 -32 -70.4 -51.2 -115.2 -54.4 -41.6 -3.2 -86.4 6.4 -121.6 32 -35.2 25.6 -60.8 60.8 -73.6 105.6 -12.8 41.6 -12.8 86.4 6.4 128 19.2 41.6 48 73.6 86.4 96 38.4 22.4 83.2 28.8 124.8 19.2z"]},vsSymbolArray:{prefix:"vs",iconName:"symbol-array",icon:[512,512,[],"f000","M48 64l-16 16v352l16 16H128v-32H64V96h64V64H48zm416 384l16 -16v-352l-16 -16H384v32h64v320h-64v32h80z"]},vsSymbolBoolean:{prefix:"vs",iconName:"symbol-boolean",icon:[512,512,[],"f000","M32 112l16 -16h416l16 16v288l-16 16h-416l-16 -16v-288zM448 128H256v111.776h-16l-114.368 -0.16 66.88 -66.88 -22.624 -22.624 -94.56 94.56v22.656l94.56 94.56 22.624 -22.624 -67.648 -67.648 127.872 0.16H256v-31.552l125.024 0.16 -67.648 -67.648 22.624 -22.624 94.592 94.56v22.656L336 361.888l-22.624 -22.624 66.88 -66.88L256 272.224V384h192V128z"]},vsSymbolClass:{prefix:"vs",iconName:"symbol-class",icon:[512,512,[],"f000","M362.88 310.72h22.72l85.44 -85.44v-22.72L428.16 160h-22.4l-58.24 57.92h-160V177.92l59.52 -59.2V96l-64 -64H160L32 160v22.72l64 64h22.72l36.48 -36.8v185.28l16 16H320v16.64l42.56 42.88h22.72l85.44 -85.44v-22.72L427.84 320h-22.4l-59.52 59.2h-160v-128H320v15.36l42.88 44.16zm54.08 -116.8l20.16 20.16 -64 64 -20.16 -20.16 64 -64zm0 160l20.16 20.16 -64 64 -20.16 -20.16 64 -64zM107.2 212.8l-41.28 -41.6 105.28 -105.28 41.6 41.28 -105.6 105.6z"]},vsSymbolColor:{prefix:"vs",iconName:"symbol-color",icon:[512,512,[],"f000","M256 32.096a224 224 0 0 0 -224 224v13.76c2.88 48.32 61.12 57.28 96 22.4a59.84 59.84 0 0 1 84.48 84.48c-35.2 37.12 -25.28 98.24 25.6 102.4h19.2a224 224 0 1 0 0 -448l-1.28 0.96zm0 416h-16.64a18.56 18.56 0 0 1 -11.52 -4.48 17.92 17.92 0 0 1 -4.8 -9.6 39.68 39.68 0 0 1 11.2 -34.56 91.84 91.84 0 0 0 0 -128 91.84 91.84 0 0 0 -129.92 0 32 32 0 0 1 -28.8 10.88 13.12 13.12 0 0 1 -7.04 -3.84 13.44 13.44 0 0 1 -3.2 -9.28v-11.84a192 192 0 1 1 192 192l-1.28 -1.28zM288 127.904a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zm96 224.224a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zm-224 -160a32 32 0 1 0 0 -64 32 32 0 0 0 0 64zm224 -32a32 32 0 1 1 -64 0 32 32 0 0 1 64 0zM416 256a32 32 0 1 1 -64 0 32 32 0 0 1 64 0z"]},vsSymbolConstant:{prefix:"vs",iconName:"symbol-constant",icon:[512,512,[],"f000","M128 192h256v32H128V192zm256 96H128v32h256V288zM32 128l32 -32h384l32 32v256l-32 32H64l-32 -32V128zm32 0v256h384V128H64z"]},vsSymbolEnumMember:{prefix:"vs",iconName:"symbol-enum-member",icon:[512,512,[],"f000","M224 96l32 -32h192l32 32v160l-32 32h-128V256h128V96H256v96H224V96zm64 192V256L256 224H64L32 256v160l32 32h192l32 -32V288zM256 256v160H64V256h192zm45.248 -32L288 210.752V192h128v32H301.248zM288 128h128v32H288V128zm-64 192H96v32h128v-32z"]},vsSymbolEnum:{prefix:"vs",iconName:"symbol-enum",icon:[512,512,[],"f000","M448 64H256L224 96v96h32V96h192v160h-128v32h128l32 -32V96l-32 -32zM288 192h128v32H301.12L288 210.88V192zM224 224H64L32 256v160l32 32h192l32 -32V256L256 224H224zm32 192H64V256h192v160zM96 288h128v32H96V288zm0 64h128v32H96v-32zm192 -224h128v32H288V128z"]},vsSymbolEvent:{prefix:"vs",iconName:"symbol-event",icon:[512,512,[],"f000","M237.248 49.92L265.984 32h105.408l26.176 50.4L327.552 192h56.992l23.04 54.24L179.776 480l-51.264 -37.216L195.808 320H156.736L128 273.92l109.248 -224zM248.96 288L156.8 457.76 384.576 224H265.984l105.408 -160H265.984L156.736 288H248.96z"]},vsSymbolField:{prefix:"vs",iconName:"symbol-field",icon:[512,512,[],"f000","M462.4 144l-160 -80h-28.8l-224 112 -17.6 28.48v144l17.6 28.8 160 80h28.8l224 -112 17.6 -28.8v-144l-17.6 -28.48zm-256 276.48l-144 -72V229.44l144 64v127.04zm16 -153.6L73.28 199.36l213.12 -106.88 149.44 74.88 -213.44 99.52zm224 49.6l-208 104V294.72l208 -96v117.76z"]},vsSymbolFile:{prefix:"vs",iconName:"symbol-file",icon:[512,512,[],"f000","M443.2 142.08l-104.96 -105.6 -11.2 -4.48H80l-16 16v416l16 16h352l16 -16V153.6l-4.8 -11.52zM416 160h-96V64l96 96zM96 448V64h192v112l16 16H416v256H96z"]},vsSymbolInterface:{prefix:"vs",iconName:"symbol-interface",icon:[512,512,[],"f000","M367.872 128a111.68 111.68 0 0 0 -110.72 96h-99.2a64 64 0 1 0 0 32h99.2a112 112 0 1 0 110.72 -128zm0 192a80 80 0 1 1 0 -160 80 80 0 0 1 0 160z"]},vsSymbolKey:{prefix:"vs",iconName:"symbol-key",icon:[512,512,[],"f000","M231.136 349.856c10.432 6.144 22.368 9.28 34.464 9.024a69.088 69.088 0 0 0 56.128 -26.944 105.312 105.312 0 0 0 20.928 -67.616 92.352 92.352 0 0 0 -18.432 -60.064 63.68 63.68 0 0 0 -52.288 -23.456 73.408 73.408 0 0 0 -48.736 18.144V111.2h-31.712V355.2h31.84v-11.008c2.432 2.112 5.056 4 7.808 5.664zM251.2 214.4c5.952 -2.528 12.416 -3.616 18.88 -3.2a34.56 34.56 0 0 1 28.672 13.696c8.224 11.616 12.224 25.664 11.424 39.84a79.52 79.52 0 0 1 -12.8 47.488 36.256 36.256 0 0 1 -30.72 16.256 39.168 39.168 0 0 1 -31.232 -13.344A48.704 48.704 0 0 1 223.2 281.6v-19.2a55.104 55.104 0 0 1 12.576 -36.64c4.16 -4.928 9.472 -8.832 15.424 -11.36zM105.248 181.6a96.96 96.96 0 0 0 -29.984 5.184 82.88 82.88 0 0 0 -25.6 12.8l-3.2 2.464v38.4l13.536 -11.488a67.2 67.2 0 0 1 43.712 -18.304 24.256 24.256 0 0 1 21.152 9.024c4.8 7.424 7.36 16.096 7.392 24.928L92.8 250.4a83.2 83.2 0 0 0 -44.096 18.4 52.8 52.8 0 0 0 -0.704 74.752 55.584 55.584 0 0 0 40.096 14.528 62.72 62.72 0 0 0 35.424 -10.624c3.264 -2.176 6.304 -4.64 9.152 -7.328v14.208h30.112V246.88a70.176 70.176 0 0 0 -15.008 -48 53.984 53.984 0 0 0 -42.528 -17.28zm27.424 97.312c0.64 13.376 -3.84 26.528 -12.512 36.736a39.072 39.072 0 0 1 -30.56 13.504 26.624 26.624 0 0 1 -19.456 -6.4 26.656 26.656 0 0 1 0 -34.912c8.992 -5.568 19.2 -8.864 29.76 -9.6l32.64 -4.736 0.128 5.408zm266.016 74.144c9.824 4.16 20.48 6.176 31.136 5.824 15.84 0.384 31.456 -3.648 45.12 -11.68l3.936 -2.4 0.416 -0.224V307.68l-14.272 10.24c-10.112 7.168 -22.272 10.88 -34.688 10.528A41.6 41.6 0 0 1 396.8 313.6a63.2 63.2 0 0 1 -12.8 -41.984 64.32 64.32 0 0 1 14.496 -44.192A45.824 45.824 0 0 1 435.2 211.2a57.6 57.6 0 0 1 31.072 8.928l13.76 8.48V191.04l-5.44 -2.336a92.8 92.8 0 0 0 -37.44 -7.904 80.64 80.64 0 0 0 -61.728 26.144 92.8 92.8 0 0 0 -23.904 65.568c-0.896 22.624 6.72 44.8 21.44 62.048 7.104 7.968 15.904 14.272 25.728 18.496z"]},vsSymbolKeyword:{prefix:"vs",iconName:"symbol-keyword",icon:[512,512,[],"f000","M480 128h-160V96h160v32zm-32 96h-64v32h64V224zm-128 0H32v32h288V224zm64 192H32v32h352v-32zm-160 -96H32v32h192v-32zm256 0h-160v32h160v-32zM256 64v96H32V64h224zM224 96H64v32h160V96z"]},vsSymbolMethod:{prefix:"vs",iconName:"symbol-method",icon:[512,512,[],"f000","M432.32 128l-160 -96h-32l-160 96 -15.68 27.52v192l15.68 27.2 160 96h32l160 -96 15.68 -27.2v-192L432.32 128zm-192 305.92l-144 -86.4V182.4l144 78.4v173.12zM104.64 150.4l151.68 -90.88 151.68 90.88 -151.68 82.88L104.64 150.4zm311.68 197.12l-144 86.4V260.8l144 -78.4v165.12z"]},vsSymbolMisc:{prefix:"vs",iconName:"symbol-misc",icon:[512,512,[],"f000","M128 64h256v128c10.912 1.12 21.664 3.584 32 7.36V32H96v271.36l32 -56V64zm68.48 256L160 256 128 312 105.28 352 32 480h256l-73.28 -128 -18.24 -32zm-109.44 128l55.04 -96L160 320l17.92 32 55.04 96H87.04zm218.752 -205.12a112 112 0 1 1 124.416 186.24 112 112 0 0 1 -124.416 -186.24zm17.76 159.648a80 80 0 1 0 88.896 -133.024 80 80 0 0 0 -88.896 133.024z"]},vsSymbolNamespace:{prefix:"vs",iconName:"symbol-namespace",icon:[512,512,[],"f000","M192 95.488V64h-2.88c-10.016 0 -19.712 1.984 -29.088 5.92a74.56 74.56 0 0 0 -24.8 16.96 71.36 71.36 0 0 0 -15.776 24.096v0.032a113.344 113.344 0 0 0 -6.336 26.56v0.064a194.56 194.56 0 0 0 -0.768 27.616c0.384 9.28 0.576 18.56 0.576 27.808 0 6.496 -1.28 12.576 -3.744 18.304v0.032a48.128 48.128 0 0 1 -24.48 25.184 44.032 44.032 0 0 1 -17.856 3.68H64v31.488h2.88c6.24 0 12.16 1.28 17.792 3.872l0.032 0.032c5.696 2.496 10.528 5.888 14.56 10.176l0.064 0.064c4.16 4.16 7.456 9.12 9.824 14.88l0.032 0.064c2.496 5.76 3.744 11.776 3.744 18.112 0 9.28 -0.192 18.56 -0.576 27.808 -0.384 9.472 -0.128 18.72 0.768 27.84v0.032c1.056 9.056 3.168 17.856 6.304 26.368v0.032c3.392 8.736 8.672 16.768 15.808 24.096 7.136 7.36 15.424 13.024 24.8 16.96 9.376 3.936 19.072 5.92 29.12 5.92H192v-31.488h-2.88c-6.368 0 -12.384 -1.216 -17.984 -3.68a51.616 51.616 0 0 1 -14.624 -10.24 53.088 53.088 0 0 1 -9.888 -14.944c-2.368 -5.76 -3.52 -11.84 -3.52 -18.336 0 -7.296 0.096 -14.496 0.352 -21.504 0.256 -7.296 0.256 -14.4 0 -21.28a148.448 148.448 0 0 0 -1.76 -20.48 85.824 85.824 0 0 0 -5.376 -19.488A73.088 73.088 0 0 0 112.704 256a73.088 73.088 0 0 0 23.616 -30.56c2.56 -6.144 4.32 -12.576 5.376 -19.264 1.056 -6.72 1.632 -13.536 1.76 -20.48 0.256 -7.04 0.256 -14.144 0 -21.312 -0.256 -7.168 -0.384 -14.4 -0.384 -21.696a47.04 47.04 0 0 1 28.064 -43.328 42.56 42.56 0 0 1 18.016 -3.872H192zm128 321.024V448h2.88c10.016 0 19.712 -1.984 29.088 -5.92 9.376 -3.936 17.664 -9.6 24.8 -16.96 7.136 -7.36 12.416 -15.36 15.776 -24.096v-0.032c3.2 -8.512 5.28 -17.376 6.336 -26.56v-0.064c0.896 -8.96 1.152 -18.144 0.768 -27.616 -0.384 -9.28 -0.576 -18.56 -0.576 -27.808 0 -6.496 1.28 -12.576 3.744 -18.304v-0.032a48.128 48.128 0 0 1 24.48 -25.184c5.632 -2.464 11.584 -3.68 17.856 -3.68H448v-31.488h-2.88c-6.24 0 -12.16 -1.28 -17.792 -3.872l-0.032 -0.032a44.032 44.032 0 0 1 -14.56 -10.176l-0.064 -0.064a45.248 45.248 0 0 1 -9.824 -14.88l-0.032 -0.064a44.96 44.96 0 0 1 -3.744 -18.112c0 -9.28 0.192 -18.56 0.576 -27.808a198.08 198.08 0 0 0 -0.768 -27.84v-0.032a113.344 113.344 0 0 0 -6.304 -26.368v-0.032a71.36 71.36 0 0 0 -15.808 -24.096 74.56 74.56 0 0 0 -24.8 -16.96 74.4 74.4 0 0 0 -29.12 -5.92H320v31.488h2.88c6.4 0 12.352 1.216 17.984 3.68 5.568 2.624 10.432 6.016 14.624 10.24 4.064 4.288 7.36 9.28 9.888 14.944 2.368 5.76 3.52 11.84 3.52 18.336 0 7.296 -0.096 14.464 -0.352 21.504 -0.256 7.296 -0.256 14.4 0 21.28 0.128 7.104 0.704 13.92 1.76 20.48 1.056 6.848 2.848 13.312 5.376 19.488a73.024 73.024 0 0 0 23.616 30.56 73.024 73.024 0 0 0 -23.616 30.56 86.4 86.4 0 0 0 -5.376 19.264c-1.056 6.72 -1.632 13.536 -1.76 20.48 -0.256 7.04 -0.256 14.144 0 21.312 0.256 7.168 0.384 14.4 0.384 21.696a47.04 47.04 0 0 1 -13.44 33.12 46.912 46.912 0 0 1 -14.624 10.208 42.56 42.56 0 0 1 -18.016 3.872H320z"]},vsSymbolNumeric:{prefix:"vs",iconName:"symbol-numeric",icon:[512,512,[],"f000","M352 32v128h128v32h-128v128h128v32h-128v128h-32v-128H192v128H160v-128H32v-32h128V192H32V160h128V32h32v128h128V32h32zM192 192v128h128V192H192z"]},vsSymbolOperator:Yt,vsSymbolParameter:{prefix:"vs",iconName:"symbol-parameter",icon:[512,512,[],"f000","M352 192h-32v-16a16 16 0 0 0 -16 -16H271.328v176a16 16 0 0 0 16 16h16v32h-96v-32h16a16 16 0 0 0 16 -16V160H208a16 16 0 0 0 -16 16V192H160V128h192v64zm93.248 65.536l-46.784 -46.784 22.624 -22.624 58.112 58.112v22.624l-56.576 56.544 -22.624 -22.624 45.248 -45.248zM113.536 302.784L66.752 256 112 210.752l-22.624 -22.624 -56.576 56.544v22.656l58.112 58.08 22.624 -22.624z"]},vsSymbolProperty:{prefix:"vs",iconName:"symbol-property",icon:[512,512,[],"f000","M89.824 479.2a56 56 0 0 1 -40.16 -17.792 53.888 53.888 0 0 1 -17.408 -35.2A55.04 55.04 0 0 1 43.52 387.2c38.656 -40.64 114.784 -116.8 170.176 -171.04a136.224 136.224 0 0 1 1.536 -98.496 131.04 131.04 0 0 1 53.28 -63.008 136.288 136.288 0 0 1 129.28 -11.52l19.744 8.576 -91.712 94.432 40.16 40.288 94.208 -92.064 8.544 19.808a137.44 137.44 0 0 1 1.28 105.952 134.336 134.336 0 0 1 -29.536 44.544 136.64 136.64 0 0 1 -23.776 18.592 134.944 134.944 0 0 1 -121.984 14.272c-35.136 35.584 -122.88 123.904 -170.24 168.128a52.16 52.16 0 0 1 -34.688 13.536zm254.016 -417.504a106.24 106.24 0 0 0 -59.168 17.824c-6.816 4.16 -13.184 9.088 -18.912 14.656a106.272 106.272 0 0 0 -21.024 119.456l4.32 9.504 -7.456 7.264c-55.616 54.304 -136.608 135.04 -175.52 176.128a25.76 25.76 0 0 0 4.224 33.6 29.152 29.152 0 0 0 9.536 7.04c3.2 1.408 6.688 2.208 10.208 2.304a22.208 22.208 0 0 0 14.4 -5.792c50.336 -47.008 147.584 -145.248 176.128 -174.08l7.36 -7.424 9.408 4.32a105.152 105.152 0 0 0 103.2 -8.128 106.56 106.56 0 0 0 18.912 -14.848 104.96 104.96 0 0 0 30.848 -75.456c0 -6.88 -0.672 -13.76 -2.048 -20.544L365.76 228 284.128 146.496l80.48 -82.88a105.152 105.152 0 0 0 -20.8 -1.92z"]},vsSymbolRuler:{prefix:"vs",iconName:"symbol-ruler",icon:[512,512,[],"f000","M128 32L96 64v384l32 32h256l32 -32V64l-32 -32H128zm0 64V64h256v384H128v-32h64v-32H128v-64h128V288H128V224h64V192H128V128h128V96H128z"]},vsSymbolSnippet:{prefix:"vs",iconName:"symbol-snippet",icon:[512,512,[],"f000","M80 32l-16 16V416h32V64h352v352h32V48l-16 -16h-384zM64 480v-32h32v32H64zm96 -32H128v32h32v-32zm32 0h32v32H192v-32zm96 0H256v32h32v-32zm32 0h32v32h-32v-32zm160 32v-32h-32v32h32zm-96 -32h32v32h-32v-32z"]},vsSymbolString:{prefix:"vs",iconName:"symbol-string",icon:[512,512,[],"f000","M64 64L32 96v288l32 32h384l32 -32V96l-32 -32H64zm0 320V96h384v288H64zm107.392 -98.24H192V231.04C192 205.056 181.92 192 161.792 192c-4.32 0 -9.12 0.768 -14.4 2.336a46.208 46.208 0 0 0 -12.416 5.344v21.28c7.584 -6.496 15.584 -9.728 24 -9.728 8.352 0 12.544 4.992 12.544 15.008l-19.2 3.296c-16.192 2.752 -24.32 12.992 -24.32 30.752 0 8.416 1.952 15.136 5.856 20.192A19.52 19.52 0 0 0 150.08 288c9.28 0 16.288 -5.12 21.024 -15.36h0.288v13.12zm0.128 -43.36v6.176a24 24 0 0 1 -3.84 13.952 11.776 11.776 0 0 1 -10.016 5.44 8.832 8.832 0 0 1 -7.04 -3.04 12.16 12.16 0 0 1 -2.56 -7.936c0 -7.104 3.52 -11.232 10.624 -12.448l12.8 -2.144zM243.2 276.032h-0.224v9.92H224V160h18.976v53.664h0.256c4.672 -9.92 11.36 -14.88 20 -14.88 7.936 0 14.08 3.776 18.336 11.296 4.288 7.552 6.432 17.824 6.432 30.912 0 14.176 -2.496 25.536 -7.52 34.144C275.52 283.712 268.8 288 260.416 288c-7.584 0 -13.312 -4 -17.184 -11.968zm-0.512 -35.872v8.704a24.96 24.96 0 0 0 3.424 13.632c2.272 3.616 5.216 5.408 8.768 5.408 4.32 0 7.68 -2.304 10.048 -6.912 2.4 -4.64 3.616 -11.2 3.616 -19.68 0 -7.04 -1.12 -12.48 -3.328 -16.448 -2.144 -3.968 -5.248 -5.984 -9.28 -5.984 -3.84 0 -7.008 1.984 -9.536 5.92a28.384 28.384 0 0 0 -3.712 15.36zM360.384 288c10.272 0 18.144 -1.856 23.616 -5.536v-22.72a28.8 28.8 0 0 1 -17.664 6.624 19.808 19.808 0 0 1 -16 -6.88c-3.84 -4.64 -5.792 -11.04 -5.792 -19.136 0 -8.32 2.016 -14.848 6.048 -19.584a20.608 20.608 0 0 1 16.512 -7.136c6.208 0 11.84 2.208 16.896 6.624v-23.968c-4.128 -2.88 -10.816 -4.288 -20.032 -4.288 -13.344 0 -24.032 4.48 -32.032 13.504 -7.968 8.96 -11.936 21.184 -11.936 36.736 0 13.44 3.712 24.448 11.168 32.96 7.424 8.544 17.184 12.8 29.216 12.8z"]},vsSymbolStructure:{prefix:"vs",iconName:"symbol-structure",icon:[512,512,[],"f000","M64 64L32 96v96l32 32h384l32 -32V96l-32 -32H64zm0 32h384v96H64V96zm-32 224l32 -32h96l32 32v96l-32 32H64l-32 -32v-96zm64 0H64v96h96v-96H96zm224 0l32 -32h96l32 32v96l-32 32h-96l-32 -32v-96zm64 0h-32v96h96v-96h-64z"]},vsSymbolVariable:{prefix:"vs",iconName:"symbol-variable",icon:[512,512,[],"f000","M64 160h64V128H48l-16 16v256l16 16H128v-32H64V160zm400 -32H384v32h64v224h-64v32h80l16 -16v-256l-16 -16zm-87.68 82.24L384 224v80.32l-9.6 14.4 -144 64h-14.72l-80 -48 -7.68 -13.76v-80l9.6 -14.72 144 -64h14.72l80 48zM160 310.72l48 28.8V296.96L160 268.16v42.56zm18.56 -68.8l46.4 27.84 108.48 -48 -46.4 -27.84 -108.48 48zm62.4 101.44l112 -49.92v-44.8l-112 49.6v45.12z"]},vsSyncIgnored:{prefix:"vs",iconName:"sync-ignored",icon:[512,512,[],"f000","M174.976 117.984l-24.224 -22.592a192 192 0 0 1 297.12 153.568L486.08 211.2l24 24.32 -66.88 66.24 -24.32 -0.32L352 233.92l24.32 -24.32 39.552 40a160 160 0 0 0 -240.896 -131.616zm145.6 284.448l25.088 23.36a192 192 0 0 1 -281.472 -161.28L24.96 304 0 279.36l66.88 -66.24 24.32 0.32 66.88 67.84 -24.32 24.32 -37.344 -37.76a160 160 0 0 0 224.16 134.592zM35.936 94.368l21.824 -23.424L439.04 426.496l-21.824 23.424z"]},vsSync:{prefix:"vs",iconName:"sync",icon:[512,512,[],"f000","M64.192 264.544L24.96 304 0 279.36l66.88 -66.24 24.32 0.32 66.88 67.84 -24.32 24.32 -37.344 -37.76a160 160 0 0 0 300.8 63.456l26.016 19.104a192 192 0 0 1 -359.04 -85.856zm351.68 -14.912L376.32 209.6l-24.32 24.32 66.88 67.52 24.32 0.32 66.88 -66.24 -24 -24.32 -38.208 37.76a192 192 0 0 0 -355.52 -93.44l25.92 19.008a160 160 0 0 1 297.6 75.072z"]},vsTable:{prefix:"vs",iconName:"table",icon:[512,512,[],"f000","M432 64h-384l-16 16v352l16 16h384l16 -16v-352l-16 -16zM64 96h352v32H64V96zm224 128H192V160h96v64zm0 32v64H192V256h96zM64 160h96v64H64V160zm0 96h96v64H64V256zm0 160v-64h96v64H64zm128 0v-64h96v64H192zm224 0h-96v-64h96v64zm0 -96h-96V256h96v64zm-96 -96V160h96v64h-96z"]},vsTag:{prefix:"vs",iconName:"tag",icon:[512,512,[],"f000","M422.4 64H256.544l-11.296 4.672L32 281.92v22.624L197.856 470.4h22.624l70.88 -70.88A143.36 143.36 0 0 0 500.8 288c0.864 -5.312 1.408 -10.624 1.632 -16a144.16 144.16 0 0 0 -64 -119.68V80l-16 -16zm-16 72.288A144.128 144.128 0 0 0 358.4 128a16 16 0 1 0 0 32 112 112 0 0 1 48 10.816v68.416L280.8 364.8a16.192 16.192 0 0 0 -6.944 6.944l-64.704 64.704 -143.2 -143.232L263.168 96H406.4v40.288zm32 57.344a112 112 0 0 1 32 78.368 110.016 110.016 0 0 1 -1.632 16 111.584 111.584 0 0 1 -153.376 87.52l118.336 -118.336 4.672 -11.328V193.632z"]},vsTasklist:{prefix:"vs",iconName:"tasklist",icon:[512,512,[],"f000","M114.24 214.368l182.176 -157.952L274.72 32 104.736 179.072l-48.32 -58.624L32 142.144l59.2 70.848 23.04 1.376zM480 160H218.368l73.824 -64H480v64zM192 224h288v64H192V224zm288 128H192v64h288v-64z"]},vsTelescope:{prefix:"vs",iconName:"telescope",icon:[512,512,[],"f000","M359.68 32l18.88 7.68 67.52 157.76 -7.36 18.88 -105.28 45.12 -18.88 -7.68 -5.44 -13.12L195.2 288l-18.56 -6.08 -5.12 -12.16L89.6 303.68l-18.56 -7.68 -23.04 -53.44 8.96 -18.88 80 -33.92 -5.76 -13.12 7.68 -18.56L252.8 109.12 247.04 96 256 77.44 359.68 32zM80 244.48l11.2 27.2 71.04 -29.12 -11.84 -27.2 -70.4 29.12zm87.68 -67.84l35.52 78.4 96 -40.96 -35.52 -78.08 -96 40.64zM281.28 96l59.52 131.52 73.28 -32.32L357.76 64 279.04 96h2.24zM272 291.2l96.64 156.8h-37.44l-60.16 -96.96v128h-32V314.24L178.56 448h-35.2l54.4 -124.8 74.24 -32z"]},vsTerminalBash:{prefix:"vs",iconName:"terminal-bash",icon:[512,512,[],"f000","M436.96 113.92L285.376 24a57.12 57.12 0 0 0 -58.24 0L75.616 113.92a60.448 60.448 0 0 0 -29.472 52.096v179.968a60.448 60.448 0 0 0 29.216 52.064l151.552 89.984a57.12 57.12 0 0 0 58.24 0l151.552 -89.984a60.416 60.416 0 0 0 29.216 -52.064V166.016a60.448 60.448 0 0 0 -28.928 -52.064zm-117.408 280.992v12.928a4.768 4.768 0 0 1 -2.24 3.968l-7.648 4.384c-1.216 0.64 -2.24 0 -2.24 -1.696v-12.672a24.96 24.96 0 0 1 -17.44 1.696 2.336 2.336 0 0 1 -0.864 -2.88l2.752 -11.68a4.896 4.896 0 0 1 2.272 -3.072 1.536 1.536 0 0 1 1.216 0 21.184 21.184 0 0 0 15.904 -2.016 21.184 21.184 0 0 0 11.84 -18.144c0 -6.592 -3.584 -9.344 -12.288 -9.376 -11.008 0 -21.152 -2.112 -21.44 -18.368A47.04 47.04 0 0 1 307.2 301.984V288.96a4.704 4.704 0 0 1 2.24 -4.032l7.392 -4.704c1.216 -0.64 2.24 0 2.24 1.728v13.088a24.128 24.128 0 0 1 14.496 -1.76 2.336 2.336 0 0 1 0.96 3.04l-2.592 11.584a4.992 4.992 0 0 1 -2.08 2.88 1.76 1.76 0 0 1 -1.12 0 19.2 19.2 0 0 0 -13.952 2.304 17.568 17.568 0 0 0 -10.592 15.552c0 5.92 3.136 7.744 13.6 7.936 14.016 0 20.064 6.368 20.224 20.448a50.176 50.176 0 0 1 -18.432 37.92zm79.392 -21.76a3.008 3.008 0 0 1 -1.152 2.944l-38.336 23.264a1.088 1.088 0 0 1 -1.28 0.096 1.12 1.12 0 0 1 -0.512 -1.184v-9.92a2.752 2.752 0 0 1 1.76 -2.432l37.728 -22.592a1.12 1.12 0 0 1 1.792 1.12v8.736zm26.464 -221.248L281.984 240.48c-17.888 10.592 -31.04 22.176 -31.04 43.744v176.64c0 12.928 5.28 21.184 13.216 23.712a46.88 46.88 0 0 1 -7.936 0.8c-8.448 0 -16.704 -2.304 -23.936 -6.624L80.704 388.8a49.856 49.856 0 0 1 -24 -42.816V166.016a49.856 49.856 0 0 1 24 -42.88l151.616 -89.92a46.72 46.72 0 0 1 47.648 0l151.552 89.984a49.536 49.536 0 0 1 23.296 34.656c-4.928 -10.688 -16.256 -13.664 -29.44 -5.92h0.064z"]},vsTerminalCmd:{prefix:"vs",iconName:"terminal-cmd",icon:[512,512,[],"f000","M348 224l64.256 160h-22.752l-64.256 -160h22.752zm-164 19.008c-8.832 0 -16.832 1.312 -24 4a49.344 49.344 0 0 0 -18.496 12c-5.184 5.312 -9.184 11.84 -12 19.52a75.648 75.648 0 0 0 -4.256 26.464c0 9.184 1.28 17.504 3.744 24.992 2.496 7.52 6.272 13.856 11.264 19.008 4.992 5.184 11.072 9.28 18.24 12.256 7.168 3.008 15.36 4.416 24.512 4.256a84.16 84.16 0 0 0 31.744 -6.24l4 15.488a63.936 63.936 0 0 1 -15.744 4.736 140.192 140.192 0 0 1 -24 2.24 83.52 83.52 0 0 1 -29.248 -4.992 70.624 70.624 0 0 1 -23.744 -14.496 60.096 60.096 0 0 1 -15.52 -23.744 102.528 102.528 0 0 1 -5.76 -32.736c0 -11.68 1.92 -22.336 5.76 -32 3.84 -9.664 9.184 -18.016 16 -25.024 6.848 -6.976 15.072 -12.416 24.768 -16.224a86.08 86.08 0 0 1 32 -5.76c9.472 0 17.152 0.736 22.976 2.24 5.856 1.504 10.08 3.008 12.768 4.48l-4.768 15.776a59.2 59.2 0 0 0 -12.992 -4.48 76.352 76.352 0 0 0 -17.248 -1.76zM256 256h32v32H256V256zm0 64h32v32H256v-32zm240 -288H16l-16 16v416l16 16h480l16 -16v-416l-16 -16zM480 448H32V160h448v288zm0 -320H32V64h448v64z"]},vsTerminalDebian:{prefix:"vs",iconName:"terminal-debian",icon:[512,512,[],"f000","M226.688 0.928a40.832 40.832 0 0 0 -11.36 1.6L211.904 2.08a302.72 302.72 0 0 1 16.448 -1.536c2.4 -0.16 4.8 -0.32 7.168 -0.544a53.44 53.44 0 0 1 -8.832 0.928zm132.064 244.672c3.008 -7.616 5.504 -13.952 5.12 -24.384l-4.256 9.024c4.32 -13.12 3.936 -27.104 3.584 -40.384 -0.16 -5.984 -0.32 -11.84 -0.064 -17.376l-1.728 -0.48c-1.536 -45.152 -40.576 -93.152 -75.328 -109.408 -29.952 -13.824 -76.032 -16.192 -97.344 -5.76a21.024 21.024 0 0 1 6.784 -2.72c3.424 -0.992 6.304 -1.856 4.32 -2.976 -19.2 1.92 -24.896 5.472 -31.136 9.408a61.44 61.44 0 0 1 -20.32 8.736c-3.52 3.392 1.632 2.016 5.792 0.928 4.128 -1.12 7.232 -1.92 -0.128 2.432a54.4 54.4 0 0 1 -9.696 1.6c-8.32 0.8 -15.744 1.536 -30.72 17.024 0.832 1.312 3.52 -0.288 5.376 -1.408 2.304 -1.376 3.392 -2.016 -1.728 4.384C98.24 91.872 56.96 137.92 48.224 153.184l4.576 0.8c-3.2 8 -6.816 14.752 -10.016 20.768 -4.352 8.128 -7.968 14.848 -8.736 21.344a543.04 543.04 0 0 1 -1.984 20.32C29.024 243.808 25.28 277.728 35.84 289.92l-1.28 12.992 1.664 3.52c1.152 2.528 2.272 5.024 3.84 7.36l-2.976 0.256c7.04 22.144 10.816 22.528 15.136 22.944 4.384 0.416 9.312 0.896 18.72 24.224 -2.688 -0.896 -5.44 -1.92 -9.376 -7.232 -0.48 4.064 5.76 16.256 13.12 25.792l-3.104 3.584a28.48 28.48 0 0 0 8.64 9.952c0.736 0.608 1.44 1.152 2.112 1.76 -11.904 -6.496 3.2 13.696 11.872 25.28 2.496 3.328 4.48 5.952 5.088 6.976l2.336 -4.224c-0.32 6.08 4.352 13.856 13.12 24.704l7.328 -0.288c3.008 5.952 14.016 16.704 20.704 17.216l-4.448 5.792c8.128 2.56 10.272 4.32 12.704 6.24 2.56 2.048 5.44 4.352 16.064 8.096l-4.16 -7.36c3.456 3.04 6.144 5.952 8.736 8.704 5.184 5.632 9.92 10.72 19.84 15.392 11.264 3.936 17.152 4.864 23.68 5.888 5.376 0.832 11.2 1.76 20.768 4.48a1082.24 1082.24 0 0 0 -6.944 -0.16c-16.192 -0.384 -33.792 -0.8 -46.176 -5.216 -96.512 -26.144 -184.832 -139.392 -178.368 -256 -0.64 -9.952 -0.32 -20.96 0 -30.752 0.384 -13.504 0.704 -24.832 -1.568 -28.224l1.024 -3.36c5.312 -17.28 11.68 -38.112 23.744 -62.624L27.552 125.44v-0.064c0.384 0.384 3.392 3.424 8.8 -5.76 1.28 -2.88 2.528 -5.824 3.744 -8.832 2.56 -6.08 5.12 -12.256 8.448 -17.92l2.56 -0.64c1.728 -10.08 17.056 -23.808 29.76 -35.2 6.08 -5.472 11.584 -10.432 14.72 -14.176l0.64 4.416C113.312 31.264 141.248 19.552 162.368 10.688c4.864 -2.016 9.312 -3.904 13.248 -5.632 -3.424 3.776 2.144 2.624 9.952 1.024 4.8 -0.96 10.4 -2.144 15.296 -2.432 -1.28 0.736 -2.624 1.408 -3.904 2.08 -2.72 1.44 -5.44 2.816 -8 4.64 8.32 -1.984 11.936 -1.408 15.968 -0.768 3.488 0.576 7.264 1.152 14.592 0.192 -5.568 0.8 -12.288 3.008 -11.2 3.84 7.84 0.928 12.736 -0.064 17.184 -0.96 5.568 -1.088 10.464 -2.08 19.52 0.96L244 8.8c7.52 2.72 13.088 4.384 18.048 5.856 10.016 3.008 17.6 5.28 34.144 14.048a18.56 18.56 0 0 0 7.36 -1.184c3.584 -1.12 6.976 -2.208 15.264 1.184 0.448 0.8 0.704 1.472 0.96 2.112 0.96 2.56 1.728 4.576 14.592 12.256 1.792 -0.704 -3.104 -5.184 -7.04 -8.768l-0.096 -0.128c32.32 17.28 67.456 54.144 78.176 93.568 -6.016 -11.104 -5.184 -5.472 -4.288 0.48 0.576 3.968 1.184 8.096 -0.192 7.52 4.48 12.064 8.16 24.512 10.4 37.376l-0.736 -2.72c-3.264 -11.776 -9.6 -34.592 -20.032 -49.76 -0.384 4.384 -2.944 3.904 -5.28 3.456 -3.36 -0.608 -6.272 -1.152 -1.856 12.576 2.592 3.808 3.072 2.368 3.488 1.088 0.48 -1.504 0.864 -2.752 4.704 5.248 0.064 4.256 1.088 8.512 2.24 13.248 0.704 3.008 1.472 6.24 2.08 9.792 -1.088 -0.192 -2.24 -2.24 -3.392 -4.16 -1.44 -2.432 -2.784 -4.704 -3.744 -3.232 2.432 11.456 6.432 17.44 8 18.304 -0.288 0.64 -0.672 0.64 -1.088 0.672 -0.864 0.064 -1.792 0.096 -1.888 5.344 0.704 13.696 3.264 12.48 5.312 11.552 0.64 -0.288 1.184 -0.544 1.632 -0.32a55.168 55.168 0 0 1 -2.656 7.84c-2.752 7.072 -6.016 15.36 -3.392 26.112a75.392 75.392 0 0 0 -3.392 -9.44 188.672 188.672 0 0 1 -1.472 -3.744c-0.576 4.832 -0.32 8.192 -0.096 11.36 0.416 5.312 0.736 9.984 -3.008 19.84 4.32 -14.144 3.84 -26.912 -0.224 -20.768 0.96 10.976 -3.84 20.544 -8.128 29.056 -3.552 7.104 -6.752 13.44 -5.888 19.264l-5.152 -7.104c-7.616 11.008 -7.04 13.344 -6.464 15.648 0.48 1.92 0.96 3.84 -3.36 10.848 1.632 -2.88 1.312 -3.584 0.992 -4.256 -0.32 -0.768 -0.672 -1.472 1.696 -5.056 -1.6 0.096 -5.44 3.84 -10.112 8.48 -3.936 3.872 -8.48 8.352 -12.864 11.776 -37.504 30.08 -82.272 33.984 -125.632 17.792 0.192 -0.992 -0.192 -2.112 -3.104 -4.096 -36.736 -28.16 -58.464 -52.096 -50.912 -107.52 2.176 -1.632 3.744 -6.176 5.6 -11.584 2.88 -8.416 6.496 -18.88 14.336 -23.84 7.84 -17.312 31.328 -33.28 56.448 -33.664 25.6 -1.408 47.232 13.664 58.112 27.904 -19.776 -18.432 -52.16 -24.032 -79.776 -10.368 -28.224 12.672 -44.96 43.776 -42.528 74.752 0.32 -0.512 0.672 -0.736 0.96 -0.96 0.64 -0.48 1.184 -0.864 1.536 -3.456 -0.864 60.16 64.832 104.256 112.128 82.016l0.576 1.248c12.704 -3.488 15.904 -6.56 20.256 -10.72 2.24 -2.144 4.736 -4.544 8.96 -7.456a14.112 14.112 0 0 1 -2.4 2.72c-2.176 2.144 -4.576 4.48 -1.6 4.544 5.312 -1.376 20.288 -14.88 30.304 -23.872l4.256 -3.808c1.984 -4.288 1.632 -5.664 1.28 -7.072 -0.384 -1.664 -0.8 -3.328 2.432 -9.6l7.328 -3.648c0.96 -2.816 1.984 -5.376 2.944 -7.776zM211.584 321.92a0.576 0.576 0 0 0 -0.16 0.512 3.648 3.648 0 0 0 0.16 -0.512zm-0.16 0.512c0.256 2.208 8.608 8.576 14.88 11.808 16.512 6.08 35.2 6.336 49.888 5.792 -31.776 13.28 -92.448 -13.504 -112.288 -49.024 1.824 0.384 5.376 4.48 9.696 9.504 6.528 7.488 14.784 17.024 21.696 19.36 -6.816 -5.44 -12.064 -12.384 -16.96 -19.52 9.216 10.56 20.384 19.2 32.608 24.928a3.264 3.264 0 0 1 0.32 -2.464l0.16 -0.384zM216.064 7.008a211.584 211.584 0 0 1 -2.4 -0.416c15.104 0.448 13.984 1.44 9.056 2.56 0.576 -0.928 -2.88 -1.504 -6.656 -2.144zM308.16 215.424c1.024 -15.264 -3.008 -10.432 -4.352 -4.608 0.608 0.32 1.152 1.888 1.664 3.424 0.896 2.56 1.728 5.056 2.688 1.184zm-6.752 21.248a53.76 53.76 0 0 1 -10.048 22.496c0.192 -1.952 -1.216 -2.368 -2.656 -2.752 -2.944 -0.832 -5.856 -1.664 5.632 -16.128a35.616 35.616 0 0 1 -4.032 7.744c-3.584 5.888 -6.72 11.008 4.032 4.256l1.056 -1.92a45.76 45.76 0 0 0 6.016 -13.696zm-42.88 39.904c-11.104 -1.696 -21.184 -5.952 -12.704 -6.08 7.072 0.64 14.08 0.64 20.992 -1.056a113.408 113.408 0 0 1 -8.32 7.136zM222.656 9.12l-3.2 0.64 3.008 -0.256 0.192 -0.384zM153.28 282.176l-1.216 5.952c1.504 2.048 2.944 4.16 4.352 6.24 3.84 5.6 7.584 11.136 12.8 15.456a151.36 151.36 0 0 0 -6.848 -11.776c-2.56 -4.16 -5.408 -8.704 -9.12 -15.872zm7.232 -10.208c1.664 3.456 3.328 6.816 5.92 9.664l2.624 7.68 -1.216 -2.016c-3.2 -5.312 -6.4 -10.656 -8.064 -16.768l0.736 1.44zm239.168 -41.024l-1.248 3.136a150.944 150.944 0 0 1 -14.784 47.168c8.352 -15.68 13.76 -32.896 16.032 -50.304zM13.952 109.632zm0.064 0.704c0.256 1.184 1.376 0.896 2.4 0.64 1.92 -0.48 3.648 -0.96 -0.128 7.552 -2.368 1.664 -3.808 2.784 -4.608 3.392l-0.864 0.64a1.6 1.6 0 0 1 0.256 -0.544 19.104 19.104 0 0 0 2.944 -11.68zM3.776 152.32a93.44 93.44 0 0 1 -3.392 13.952 18.816 18.816 0 0 0 -0.16 -4.928c-0.416 -3.36 -0.8 -6.304 4.32 -12.864a128.288 128.288 0 0 0 -0.736 3.84z"]},vsTerminalLinux:{prefix:"vs",iconName:"terminal-linux",icon:[512,512,[],"f000","M424.992 356.992a26.88 26.88 0 0 1 12 9.504c2.688 4 4.576 8.832 5.76 14.496 0.64 3.328 1.408 6.4 2.24 9.28a56.704 56.704 0 0 0 7.008 15.232c1.504 2.336 3.52 4.896 6.016 7.744 2.144 2.336 4.064 5.344 5.76 8.992a25.376 25.376 0 0 1 2.464 10.496 15.68 15.68 0 0 1 -2.976 9.76 30.208 30.208 0 0 1 -7.52 7.008c-3.84 2.656 -7.84 4.992 -12 7.008 -4.16 1.984 -8.32 4.064 -12.48 6.24a115.968 115.968 0 0 0 -17.76 10.496c-4.992 3.68 -10.016 8.32 -15.008 14.016a90.08 90.08 0 0 1 -20 16.736 47.072 47.072 0 0 1 -12.256 5.504c-4.16 1.152 -8.32 1.92 -12.48 2.24 -9.664 0 -17.664 -1.664 -24 -4.992 -6.336 -3.328 -11.84 -9.408 -16.512 -18.24 -1.344 -2.528 -2.656 -4.096 -4 -4.768a24.768 24.768 0 0 0 -6.496 -1.76L277.44 480c-8.32 -0.64 -16.8 -0.992 -25.472 -0.992a136.96 136.96 0 0 0 -21.504 1.728c-7.328 1.184 -14.592 2.592 -21.76 4.256 -1.472 0.32 -2.976 1.6 -4.48 3.744a54.4 54.4 0 0 1 -6.272 7.264 35.392 35.392 0 0 1 -10.72 7.008 47.2 47.2 0 0 1 -17.76 3.232c-5.504 0 -11.424 -0.576 -17.76 -1.728a58.24 58.24 0 0 1 -16.992 -5.76 114.496 114.496 0 0 0 -30.496 -10.496c-10.016 -1.824 -20.576 -3.52 -31.744 -4.992a108.544 108.544 0 0 1 -11.008 -2.016 24.768 24.768 0 0 1 -9.28 -4.256 22.56 22.56 0 0 1 -6.208 -7.008 24.96 24.96 0 0 1 -2.528 -11.232c0 -5.184 0.672 -10.176 2.016 -15.008 1.344 -4.8 2.08 -9.92 2.24 -15.232 0 -3.68 -0.256 -7.264 -0.736 -10.752a112.96 112.96 0 0 1 -1.024 -11.264c0 -8.48 2.016 -14.72 6.016 -18.752 4 -4 9.824 -7.168 17.504 -9.504a31.68 31.68 0 0 0 9.504 -4.736 72.64 72.64 0 0 0 7.488 -6.496 59.52 59.52 0 0 0 6.496 -7.744c2.016 -2.848 4.256 -5.696 6.752 -8.512a3.648 3.648 0 0 0 0.768 -2.24c0 -2.016 -0.096 -3.936 -0.256 -5.76l-0.512 -6.016c0 -11.328 1.76 -22.72 5.248 -34.24 3.52 -11.52 8.096 -22.72 13.76 -33.76a290.56 290.56 0 0 1 19.008 -31.744c6.976 -10.144 13.92 -19.584 20.736 -28.256a139.2 139.2 0 0 0 21.76 -38.496c4.8 -13.312 7.328 -27.84 7.488 -43.52 0 -6.624 -0.32 -13.216 -0.992 -19.712a195.904 195.904 0 0 1 -0.992 -20c0 -13.344 1.504 -25.344 4.48 -36 3.008 -10.688 7.68 -19.84 14.016 -27.52s14.592 -13.408 24.736 -17.248C239.168 2.4 251.328 0.32 265.472 0c16.864 0 30.272 3.328 40.288 10.016 9.984 6.656 17.664 15.392 22.976 26.24 5.344 10.816 8.768 22.912 10.24 36.256 1.536 13.312 2.368 26.816 2.528 40.48v4.256c0 6.848 0.064 12.928 0.256 18.24a80.864 80.864 0 0 0 7.232 31.264c2.336 5.152 5.824 10.752 10.496 16.736 8 10.528 16.192 21.12 24.512 31.776 8.32 10.656 15.904 21.664 22.72 32.96 6.848 11.36 12.448 23.2 16.768 35.52 4.352 12.352 6.592 25.664 6.752 40a105.6 105.6 0 0 1 -5.248 33.28zm-209.728 -260.48c2.304 0 4.224 0.576 5.76 1.728a11.424 11.424 0 0 1 3.488 4.768 27.2 27.2 0 0 1 1.728 5.984c0.32 2.016 0.512 4.096 0.512 6.272a9.024 9.024 0 0 1 -0.768 4 8.64 8.64 0 0 1 -2.24 2.752l-3.008 2.496a25.472 25.472 0 0 0 -2.976 2.976 13.696 13.696 0 0 1 -4.768 4.512 68.128 68.128 0 0 0 -5.76 3.744 41.92 41.92 0 0 0 -4.992 4.256 8.448 8.448 0 0 0 -2.24 6.24c0 1.504 0.736 2.752 2.24 3.744a22.528 22.528 0 0 1 8.512 9.76c1.664 3.84 3.52 7.584 5.504 11.264 1.984 3.648 4.576 6.72 7.744 9.248 3.168 2.496 8.096 3.744 14.72 3.744h1.536c6.656 -0.32 12.992 -2.08 19.008 -5.248 5.984 -3.168 12 -6.496 17.984 -10.016a20.256 20.256 0 0 1 3.264 -1.472 11.84 11.84 0 0 0 3.232 -1.76l18.24 -14.24a29.632 29.632 0 0 0 0.768 -3.264 88 88 0 0 0 0.512 -3.52 7.552 7.552 0 0 0 -1.28 -4.48 12.8 12.8 0 0 0 -2.976 -3.008 10.88 10.88 0 0 0 -4.256 -1.728 29.088 29.088 0 0 1 -4.48 -1.28 34.656 34.656 0 0 1 -11.264 -4.48 46.624 46.624 0 0 0 -11.008 -4.992c-0.64 -0.192 -1.152 -0.672 -1.504 -1.504a31.456 31.456 0 0 1 -0.992 -3.008 7.36 7.36 0 0 1 -0.256 -3.264 4.032 4.032 0 0 0 -0.256 -2.496c0 -1.984 0.16 -4.064 0.512 -6.24a17.632 17.632 0 0 1 2.24 -6.24 13.344 13.344 0 0 1 4 -4.48 13.152 13.152 0 0 1 6.496 -1.792c5.184 0 8.928 1.92 11.264 5.76 2.336 3.84 3.584 8 3.744 12.48a12.704 12.704 0 0 1 -1.248 5.76 12.128 12.128 0 0 0 -1.28 5.504c0 1.344 0.448 2.24 1.28 2.752a8.32 8.32 0 0 0 3.264 0.992c3.84 0 6.304 -0.896 7.488 -2.72a17.056 17.056 0 0 0 1.984 -8.256c0 -3.84 -0.32 -8.096 -0.96 -12.768a42.24 42.24 0 0 0 -4.032 -12.992 31.008 31.008 0 0 0 -7.744 -10.016 18.368 18.368 0 0 0 -12.256 -3.968c-8.64 0 -14.912 2.144 -18.752 6.496 -3.84 4.32 -5.824 10.816 -5.984 19.488 0 2.496 0.16 4.992 0.48 7.488 0.32 2.528 0.512 5.024 0.512 7.52 0 0.832 -0.096 1.248 -0.256 1.248a6.976 6.976 0 0 1 -1.504 -0.512 136.416 136.416 0 0 1 -2.976 -1.248 24.768 24.768 0 0 0 -3.776 -1.248 16.448 16.448 0 0 0 -6.496 -0.256 32.224 32.224 0 0 1 -4 0.256c-2.336 0 -3.52 -0.416 -3.52 -1.248 0 -2.496 -0.128 -5.664 -0.48 -9.504 -0.32 -3.84 -1.152 -7.68 -2.496 -11.52a31.84 31.84 0 0 0 -4.992 -9.472c-2.016 -2.496 -4.992 -3.84 -8.992 -4a10.336 10.336 0 0 0 -7.264 2.752 28.96 28.96 0 0 0 -5.248 6.496 20.48 20.48 0 0 0 -2.752 8.512 172.8 172.8 0 0 1 -0.992 8 46.688 46.688 0 0 0 2.24 12.992c0.832 2.656 1.76 4.992 2.752 7.008 0.992 1.984 2.176 2.976 3.52 2.976 0.8 0 1.92 -0.576 3.232 -1.728 1.344 -1.184 2.016 -2.24 2.016 -3.264 0 -0.512 -0.256 -0.832 -0.768 -0.992a4.704 4.704 0 0 0 -1.504 -0.256c-1.152 0 -2.176 -0.576 -3.008 -1.76a14.976 14.976 0 0 1 -1.984 -4 164.608 164.608 0 0 1 -1.504 -4.736 18.048 18.048 0 0 1 1.76 -12.736c1.504 -2.688 4.256 -4.096 8.256 -4.256zM160.736 485.76c4 0 7.936 -0.32 11.776 -1.024a31.04 31.04 0 0 0 10.752 -4 19.648 19.648 0 0 0 7.488 -7.744 30.176 30.176 0 0 0 3.008 -12 26.112 26.112 0 0 0 -1.504 -8.736 30.816 30.816 0 0 0 -4.256 -8 88.416 88.416 0 0 0 -6.496 -8.992 88.416 88.416 0 0 1 -6.496 -9.024 2013.76 2013.76 0 0 1 -9.28 -13.76c-2.976 -4.48 -5.984 -9.216 -8.96 -14.24a259.968 259.968 0 0 1 -7.52 -12.992 84.672 84.672 0 0 0 -8.512 -12.736 38.496 38.496 0 0 0 -6.976 -6.752 15.008 15.008 0 0 0 -9.28 -3.008 13.952 13.952 0 0 0 -9.472 3.52 72.32 72.32 0 0 0 -8.256 8.48 103.712 103.712 0 0 1 -9.504 9.76c-3.52 3.168 -8 5.664 -13.504 7.488a23.808 23.808 0 0 0 -9.984 5.504c-2.336 2.336 -3.52 5.92 -3.52 10.752 0 3.328 0.256 6.656 0.768 9.984 0.48 3.328 0.832 6.688 0.992 10.016 0 4.48 -0.64 8.736 -2.016 12.736a37.024 37.024 0 0 0 -1.984 11.744c0 4.512 1.6 7.68 4.736 9.504 3.2 1.856 6.752 3.104 10.752 3.744 5.024 0.864 9.76 1.504 14.272 2.016 4.48 0.512 8.896 1.28 13.248 2.24 4.32 1.024 8.64 2.08 12.992 3.264 4.32 1.152 8.928 3.008 13.76 5.504 0.96 0.48 2.496 1.088 4.48 1.728l6.752 2.24c2.496 0.864 4.832 1.536 7.008 2.016a23.712 23.712 0 0 0 4.736 0.768zm91.52 -30.016c4.672 0 9.664 -0.48 15.008 -1.504a113.28 113.28 0 0 0 31.232 -10.752 82.88 82.88 0 0 0 12.992 -8.224 7.104 7.104 0 0 0 1.024 -1.504 9.76 9.76 0 0 0 0.736 -2.016v-0.256c0.992 -3.648 1.824 -7.68 2.496 -12a276.16 276.16 0 0 0 1.76 -13.248 287.36 287.36 0 0 1 1.76 -13.248c0.64 -4.32 1.248 -8.576 1.728 -12.736 0.672 -4.48 1.504 -8.832 2.496 -12.992 1.024 -4.16 2.336 -8.096 4 -11.776a32.96 32.96 0 0 1 6.752 -9.728 49.28 49.28 0 0 1 11.008 -8v-0.512l-0.256 -0.736a9.28 9.28 0 0 1 1.504 -4.768 44.8 44.8 0 0 1 3.744 -5.248 18.624 18.624 0 0 1 4.768 -4.256 30.272 30.272 0 0 1 5.248 -2.496 314.784 314.784 0 0 0 -3.264 -12 158.016 158.016 0 0 1 -3.008 -12 228.032 228.032 0 0 0 -2.976 -15.232 94.528 94.528 0 0 0 -3.52 -11.52 42.144 42.144 0 0 0 -5.76 -10.24c-2.464 -3.328 -5.568 -7.36 -9.216 -12a38.048 38.048 0 0 1 -3.776 -4.992 17.76 17.76 0 0 1 -1.472 -6.272 70.592 70.592 0 0 0 -1.504 -6.496 303.36 303.36 0 0 0 -7.744 -24 93.12 93.12 0 0 0 -5.504 -12.256 123.84 123.84 0 0 0 -5.504 -9.248c-1.664 -2.496 -3.424 -3.744 -5.248 -3.744 -4 0 -8.768 1.6 -14.272 4.768 -5.472 3.168 -11.328 6.656 -17.472 10.496 -6.176 3.84 -12.16 7.424 -18.016 10.752 -5.824 3.328 -11.072 4.896 -15.744 4.736a22.4 22.4 0 0 1 -13.76 -4.736 71.552 71.552 0 0 1 -11.52 -11.008c-3.488 -4.16 -6.4 -7.744 -8.736 -10.752 -2.336 -3.008 -4.064 -4.672 -5.248 -4.992 -1.312 0 -2.08 0.992 -2.24 2.976a81.92 81.92 0 0 0 -0.256 6.752v4.256c0 1.024 -0.16 1.664 -0.512 2.016 -1.824 3.84 -3.84 7.584 -5.984 11.232 -2.176 3.68 -4.32 7.424 -6.496 11.264a51.552 51.552 0 0 0 -7.008 24.256c0 2.496 0.16 4.992 0.512 7.488 0.32 2.496 1.152 4.928 2.496 7.264l-0.512 0.96a41.92 41.92 0 0 1 -4.256 5.024 34.304 34.304 0 0 0 -4.224 5.248 89.472 89.472 0 0 0 -13.024 29.76c-2.496 10.656 -3.84 21.504 -4 32.48 0 2.848 0.192 5.696 0.512 8.512 0.32 2.848 0.512 5.664 0.512 8.512a16.832 16.832 0 0 1 -0.256 2.752 16.8 16.8 0 0 0 -0.256 2.752 24 24 0 0 1 10.016 3.488c3.84 2.176 8 4.928 12.48 8.256 4.48 3.328 8.768 7.168 12.768 11.52 4 4.32 7.808 8.544 11.488 12.736 3.68 4.16 6.336 8.32 8 12.48 1.664 4.16 2.752 7.584 3.232 10.24a14.208 14.208 0 0 1 -4 10.528 30.56 30.56 0 0 1 -9.984 6.496c2.848 4.992 6.336 9.248 10.496 12.736 4.16 3.52 8.672 6.336 13.504 8.512 4.832 2.176 10.08 3.744 15.744 4.736 5.664 1.024 11.2 1.504 16.512 1.504zm100.256 35.52c3.488 0 6.912 -0.512 10.24 -1.504a52.8 52.8 0 0 0 14.24 -6.496c4.352 -2.848 8.32 -6.336 12 -10.528a98.24 98.24 0 0 1 31.264 -24l8.256 -3.744a69.76 69.76 0 0 0 8.224 -4.256 30.784 30.784 0 0 0 5.28 -4.224 8.192 8.192 0 0 0 2.496 -6.016 9.44 9.44 0 0 0 -0.768 -3.744 18.56 18.56 0 0 0 -2.24 -3.744 164.352 164.352 0 0 1 -6.496 -9.76 63.296 63.296 0 0 1 -4.768 -9.504l-4 -9.984a81.856 81.856 0 0 1 -3.52 -11.264 8.96 8.96 0 0 0 -1.728 -3.232 16.96 16.96 0 0 0 -14.72 -7.52 17.056 17.056 0 0 0 -8.512 2.24l-8.512 4.768a234.72 234.72 0 0 1 -8.992 4.736 20.992 20.992 0 0 1 -9.504 2.24 13.152 13.152 0 0 1 -8.256 -2.464 20.352 20.352 0 0 1 -5.504 -6.752 70.976 70.976 0 0 1 -3.744 -8.256l-3.008 -8.256a40.32 40.32 0 0 1 -4.48 6.016 21.312 21.312 0 0 0 -4 6.496c-2.176 4.992 -3.52 10.56 -4 16.736 -0.832 9.664 -1.92 19.072 -3.264 28.256a150.4 150.4 0 0 1 -6.72 27.52 61.248 61.248 0 0 0 -2.016 8.736 92.16 92.16 0 0 0 -1.024 9.248c0 8.16 2.528 14.912 7.52 20.256 4.992 5.312 11.744 8 20.256 8z"]},vsTerminalPowershell:{prefix:"vs",iconName:"terminal-powershell",icon:[512,512,[],"f000","M80 32.224l415.968 5.44 13.76 16.032 -58.24 411.904 -18.24 15.648 -416 -5.44 -13.76 -16.064L61.76 47.84l18.24 -15.616zM37.76 444.32l383.936 5.024 53.76 -380.224L91.52 64.096 37.76 444.32zm185.312 -111.68l-4.48 31.712 160 2.112 4.48 -31.68 -160 -2.112zm54.72 -78.624l-117.216 -93.76 -22.144 25.472 84.352 67.584L119.648 318.4l14.88 25.984L277.76 254.016z"]},vsTerminalTmux:{prefix:"vs",iconName:"terminal-tmux",icon:[512,512,[],"f000","M432 32h-384l-16 16v416l16 16h384l16 -16v-416l-16 -16zM224 240V416H64V64h160v176zm192 176H256V256h160v160zm0 -192H256V64h160v160z"]},vsTerminalUbuntu:{prefix:"vs",iconName:"terminal-ubuntu",icon:[512,512,[],"f000","M104.32 256A43.84 43.84 0 1 1 16.64 256a43.84 43.84 0 0 1 87.68 0zm249.28 213.12a43.84 43.84 0 1 0 75.968 -43.84 43.84 43.84 0 0 0 -75.968 43.84zm75.84 -382.4a43.84 43.84 0 1 0 -75.84 -43.936 43.84 43.84 0 0 0 75.84 43.936zM281.28 131.2a124.8 124.8 0 0 1 124.48 113.6h64a189.76 189.76 0 0 0 -55.36 -121.6 61.12 61.12 0 0 1 -53.12 -3.84 64.032 64.032 0 0 1 -30.08 -44.16 192 192 0 0 0 -49.28 -6.4 186.56 186.56 0 0 0 -83.52 19.52l32 55.36a126.08 126.08 0 0 1 50.88 -12.48zM156.16 256a125.76 125.76 0 0 1 53.12 -102.4l-32 -54.4A189.76 189.76 0 0 0 99.2 208a61.44 61.44 0 0 1 0 96 189.76 189.76 0 0 0 77.44 108.8l32 -54.4A125.76 125.76 0 0 1 156.16 256zm125.12 125.12a128 128 0 0 1 -52.8 -11.84l-32 55.36c25.92 12.896 54.528 19.584 83.52 19.52 16.64 0 33.216 -2.144 49.28 -6.4a64 64 0 0 1 30.08 -44.16 61.152 61.152 0 0 1 53.12 -3.84 189.76 189.76 0 0 0 55.36 -121.6h-64a125.12 125.12 0 0 1 -122.56 112.96z"]},vsTerminal:Xt,vsTextSize:{prefix:"vs",iconName:"text-size",icon:[512,512,[],"f000","M107.52 224L32 416h42.88l16.32 -47.04h72.32L180.48 416H224L148.8 224H107.52zm-4.8 112.96l24.96 -68.48 24.96 68.48H102.72zM378.24 128h-51.2L224 416h49.92l24 -73.28h107.52l24.64 73.28H480l-101.76 -288zM309.44 304l37.76 -114.88c1.888 -5.92 3.2 -12.032 3.84 -18.24 0.864 6.144 2.048 12.224 3.52 18.24l40 114.88H309.44z"]},vsThreeBars:{prefix:"vs",iconName:"three-bars",icon:[512,512,[],"f000","M448 160H64V96h384v64zm0 128H64V224h384v64zM64 416h384v-64H64v64z"]},vsThumbsdown:{prefix:"vs",iconName:"thumbsdown",icon:[512,512,[],"f000","M174.72 451.52a46.72 46.72 0 0 1 -25.92 -8 44.16 44.16 0 0 1 -14.4 -54.08L165.44 320H76.16a43.52 43.52 0 0 1 -37.12 -19.52 43.2 43.2 0 0 1 -2.88 -42.24C57.6 211.84 96 128 108.8 92.8A44.16 44.16 0 0 1 150.08 64h285.76A44.8 44.8 0 0 1 480 108.8v112.32a44.16 44.16 0 0 1 -44.16 44.16h-44.16L204.8 440a45.12 45.12 0 0 1 -30.08 11.52zM150.08 96a12.48 12.48 0 0 0 -11.52 8C125.76 138.88 91.52 214.4 64 271.68a12.48 12.48 0 0 0 0 11.52 11.84 11.84 0 0 0 12.16 4.8h105.6l16.64 21.76v14.72l-34.88 78.08a11.84 11.84 0 0 0 4.16 14.72 12.16 12.16 0 0 0 15.36 0l193.92 -178.88 15.04 -4.16h43.84a12.16 12.16 0 0 0 12.16 -13.12V108.8a12.8 12.8 0 0 0 -12.16 -12.8H150.08z"]},vsThumbsup:{prefix:"vs",iconName:"thumbsup",icon:[512,512,[],"f000","M337.28 64c9.248 0.032 18.24 2.816 25.92 8a44.16 44.16 0 0 1 14.4 54.08l-31.04 69.44h89.28a43.52 43.52 0 0 1 37.12 19.52 43.2 43.2 0 0 1 2.88 42.24c-21.44 46.4 -59.84 130.24 -72.64 165.44a44.16 44.16 0 0 1 -41.28 28.8H76.16A44.8 44.8 0 0 1 32 406.72V294.4a44.16 44.16 0 0 1 44.16 -44.16h44.16L307.2 75.52a45.12 45.12 0 0 1 30.08 -11.52zm24.64 355.52a12.48 12.48 0 0 0 11.52 -8c12.8 -34.88 47.04 -110.4 74.56 -167.68a12.48 12.48 0 0 0 0 -11.52 11.84 11.84 0 0 0 -12.16 -4.8h-105.6l-16.64 -21.76v-14.72l34.88 -78.08a11.84 11.84 0 0 0 -4.16 -14.72 12.16 12.16 0 0 0 -15.36 0L135.04 277.12l-15.04 4.16H76.16A12.16 12.16 0 0 0 64 294.4v112.32a12.8 12.8 0 0 0 12.16 12.8h285.76z"]},vsTools:Zt,vsTrash:$t,vsTriangleDown:Qt,vsTriangleLeft:{prefix:"vs",iconName:"triangle-left",icon:[512,512,[],"f000","M334.08 64l17.92 13.216v358.208l-17.28 12.576L160 267.936v-26.464L334.08 64z"]},vsTriangleRight:Jt,vsTriangleUp:{prefix:"vs",iconName:"triangle-up",icon:[512,512,[],"f000","M448 334.08l-13.216 17.92H76.576L64 334.72 244.064 160h26.464L448 334.08z"]},vsTwitter:{prefix:"vs",iconName:"twitter",icon:[512,512,[],"f000","M480 121.088a180.16 180.16 0 0 1 -20.8 25.696 193.856 193.856 0 0 1 -25.152 21.76 174.144 174.144 0 0 1 0.448 12.064c0 18.368 -1.952 36.512 -5.888 54.464a270.944 270.944 0 0 1 -17.088 52.064 270.208 270.208 0 0 1 -40.448 65.28 248.576 248.576 0 0 1 -55.04 48.672 250.72 250.72 0 0 1 -67.04 30.4 272.768 272.768 0 0 1 -76.128 10.528 261.696 261.696 0 0 1 -73.376 -10.4A253.472 253.472 0 0 1 32 400.64a184.384 184.384 0 0 0 136.064 -38.08 90.944 90.944 0 0 1 -72.736 -38.08 92.096 92.096 0 0 1 -13.024 -25.6c2.912 0.448 5.792 0.832 8.64 1.12a89.504 89.504 0 0 0 32.704 -2.848 89.856 89.856 0 0 1 -29.632 -11.584 94.144 94.144 0 0 1 -23.296 -20.256 90.848 90.848 0 0 1 -20.8 -58.304v-1.056c12.864 7.264 26.784 11.136 41.792 11.584a94.176 94.176 0 0 1 -29.952 -33.28 94.56 94.56 0 0 1 -8.096 -20.768 94.24 94.24 0 0 1 0.224 -46.496c2.016 -7.776 5.152 -15.168 9.408 -22.176 11.648 14.432 24.64 27.392 38.912 38.816a262.88 262.88 0 0 0 96.256 48.8 254.88 254.88 0 0 0 54.24 8.416 68.8 68.8 0 0 1 -1.856 -10.4 104.48 104.48 0 0 1 -0.544 -10.592c0 -12.704 2.4 -24.64 7.232 -35.776a92.544 92.544 0 0 1 48.896 -48.896 89.28 89.28 0 0 1 35.744 -7.2 91.072 91.072 0 0 1 67.168 29.088 182.4 182.4 0 0 0 58.176 -22.336 90.08 90.08 0 0 1 -40.256 50.752A182.528 182.528 0 0 0 480 121.12z"]},vsTypeHierarchySub:{prefix:"vs",iconName:"type-hierarchy-sub",icon:[512,512,[],"f000","M432 352h-55.328L270.016 192H304l16 -16v-128L304 32h-128l-16 16v128l16 16h33.984l-106.656 160H48l-16 16v96l16 16h96l16 -16v-96l-16 -16h-2.176L240 204.8l98.176 147.2H336l-16 16v96l16 16h96l16 -16v-96l-16 -16zM192 160V64h96v96H192zm-64 224v64H64v-64h64zm288 64h-64v-64h64v64z"]},vsTypeHierarchySuper:{prefix:"vs",iconName:"type-hierarchy-super",icon:[512,512,[],"f000","M432 32h-96l-16 16v96l16 16h2.176L240 307.2 141.824 160H144l16 -16v-96L144 32h-96l-16 16v96l16 16h55.328l106.656 160H176l-16 16v128l16 16h128l16 -16v-128l-16 -16H270.016l106.656 -160H432l16 -16v-96l-16 -16zM64 128V64h64v64H64zm224 224v96H192v-96h96zm128 -224h-64V64h64v64z"]},vsTypeHierarchy:{prefix:"vs",iconName:"type-hierarchy",icon:[512,512,[],"f000","M432 384h-57.376L320 329.376V208L304 192H256V128h16l16 -16v-64L272 32h-64l-16 16v64l16 16H224v64H176l-16 16v121.376L105.376 384H48l-16 16v64l16 16h64l16 -16v-57.376L182.624 352h114.752L352 406.624V464l16 16h64l16 -16v-64l-16 -16zM224 64h32v32H224V64zM192 224h96v96H192V224zm-96 224H64v-32h32v32zm320 0h-32v-32h32v32z"]},vsUnfold:{prefix:"vs",iconName:"unfold",icon:[512,512,[],"f000","M240.96 208.32v-128l-32 32 -22.72 -22.72L244.8 32h22.72l58.88 58.56 -22.72 22.4 -32 -32v127.36h-30.72zm0 95.36v128l-32 -32 -22.72 22.72L244.8 480h22.72l58.88 -58.56 -22.72 -22.4 -32 32V303.68h-30.72zM439.36 128L448 160.64l-117.76 93.76L448 351.36 439.36 384h-134.4v-32h96L305.6 274.24H209.28L110.4 352h98.56v32H72.64L64 351.36l117.76 -93.44L64 160.64 72.64 128h136.32v32H110.4l96 77.44h96.32L400.96 160h-96V128h134.4z"]},vsUngroupByRefType:{prefix:"vs",iconName:"ungroup-by-ref-type",icon:[512,512,[],"f000","M92.8 32L160 99.2l-25.6 22.4L96 83.2V224H64V80L25.6 121.6l-22.4 -22.4L70.4 32h22.4zM96 428.8V288H64v140.8L25.6 390.4l-22.4 22.4L70.4 480h22.4L160 412.8l-22.4 -22.4L96 428.8zM272 224h-64L192 208v-64l16 -16h64l16 16v64l-16 16zM224 192h32V160H224v32zm240 32h-96l-16 -16v-96l16 -16h96l16 16v96l-16 16zM384 192h64V128h-64v64zm-112 192h-64l-16 -16v-64l16 -16h64l16 16v64l-16 16zM224 352h32v-32H224v32zm240 64h-96l-16 -16v-96l16 -16h96l16 16v96l-16 16zM384 384h64v-64h-64v64zm-32 -64H288v32h64v-32zm0 -160H288v32h64V160z"]},vsUnlock:{prefix:"vs",iconName:"unlock",icon:[512,512,[],"f000","M160 224V160a96 96 0 0 1 186.56 -32h33.408A128.064 128.064 0 0 0 128 160v64H96L64 256v192l32 32h320l32 -32V256l-32 -32H160zm192 32h64v192H96V256h256z"]},vsUnmute:{prefix:"vs",iconName:"unmute",icon:[512,512,[],"f000","M48 154.56h89.28L260.8 32l27.2 11.2v416l-27.2 10.56 -123.52 -123.2H48l-16 -16v-160l16 -16zM155.2 320L256 420.48V81.92L155.2 181.76l-11.2 4.8H64v128h80l11.2 5.44zM480 250.56a223.04 223.04 0 0 1 -50.496 141.696l-22.784 -22.72A191.2 191.2 0 0 0 448 250.56c0 -44.8 -15.36 -86.048 -41.088 -118.72l22.784 -22.72A223.072 223.072 0 0 1 480 250.56zm-64 0a159.296 159.296 0 0 1 -32.064 96.128l-22.912 -22.912A127.424 127.424 0 0 0 384 250.56a127.36 127.36 0 0 0 -22.816 -72.96l22.912 -22.912c20.032 26.72 31.904 59.904 31.904 95.872zm-64 0c0 18.368 -5.12 35.52 -14.08 50.112l-23.648 -23.616a63.776 63.776 0 0 0 0.16 -52.704l23.648 -23.648c8.832 14.528 13.92 31.616 13.92 49.856z"]},vsUnverified:{prefix:"vs",iconName:"unverified",icon:[512,512,[],"f000","M245.44 471.04h22.72L323.2 416h76.8l16 -16v-77.44l55.68 -55.04v-22.72l-54.72 -55.04V111.68l-16 -15.68H323.2L268.16 41.28h-22.72L192 96H112.96L96 112v77.76L41.92 244.8v22.72L96 322.56v77.44l16.96 16H192l53.44 55.04zM197.12 384H128V315.84l-3.84 -11.2L75.84 256l47.36 -48.32 4.8 -11.2V128h69.12l11.52 -4.48L256 75.2l49.28 48.32 11.2 4.48H384v68.48l5.44 11.2L438.08 256l-49.6 48.64 -4.48 11.2V384H316.48l-12.16 4.8L256 437.12l-47.36 -48.64 -11.52 -4.48zm46.176 -187.488a30.784 30.784 0 0 0 -4.096 9.312c-0.96 3.488 -1.6 6.88 -1.984 10.144l-0.16 1.376h-28.64l0.096 -1.632c0.576 -10.432 2.848 -19.68 6.784 -27.648 1.664 -3.456 3.744 -6.848 6.176 -10.176 2.592 -3.392 5.76 -6.4 9.408 -8.96 3.808 -2.688 8.16 -4.8 13.088 -6.4A54.72 54.72 0 0 1 261.28 160c8.96 0 16.736 1.472 23.232 4.48 6.4 2.848 11.712 6.72 15.808 11.616 4.064 4.864 7.04 10.432 8.928 16.64 1.856 6.208 2.784 12.608 2.784 19.168 0 6.112 -1.024 11.872 -3.136 17.28 -2.048 5.248 -4.576 10.24 -7.616 14.912 -3.008 4.576 -6.304 8.96 -9.92 13.12 -3.52 4.128 -6.752 8.064 -9.728 11.904a79.04 79.04 0 0 0 -7.36 10.88 20.896 20.896 0 0 0 -2.816 10.176v15.36h-28.416v-17.248c0 -5.376 0.992 -10.336 3.008 -14.848a68.8 68.8 0 0 1 7.68 -12.832c3.072 -4.064 6.4 -8 9.856 -11.776a151.68 151.68 0 0 0 9.568 -11.392c2.976 -3.84 5.44 -7.872 7.296 -12.064a31.488 31.488 0 0 0 2.88 -13.472 33.28 33.28 0 0 0 -1.504 -10.176v-0.032a20.416 20.416 0 0 0 -4.16 -7.776 17.856 17.856 0 0 0 -6.912 -5.056H270.72a22.048 22.048 0 0 0 -9.408 -1.888 20.576 20.576 0 0 0 -10.848 2.656 23.744 23.744 0 0 0 -7.136 6.88zM272 352h-28.416v-28.416H272V352z"]},vsVariableGroup:{prefix:"vs",iconName:"variable-group",icon:[512,512,[],"f000","M172.384 368.736a12.864 12.864 0 0 1 18.976 -11.744c1.856 0.992 3.52 2.08 5.024 3.264 1.504 1.152 2.816 2.24 4 3.232a5.664 5.664 0 0 0 3.744 1.504c1.664 0 3.84 -1.28 6.496 -3.744 2.656 -2.496 5.6 -5.824 8.736 -10.016 3.2 -4.16 6.432 -8.576 9.76 -13.248 3.328 -4.672 6.4 -9.408 9.28 -14.24l7.232 -12.48c1.984 -3.52 3.424 -6.368 4.256 -8.512a490.56 490.56 0 0 0 -4.256 -16.768 492.288 492.288 0 0 1 -4.256 -16.736 119.04 119.04 0 0 0 -4.256 -13.504 33.28 33.28 0 0 0 -5.984 -10.016 20.992 20.992 0 0 0 -8.512 -5.984 43.968 43.968 0 0 0 -12 -2.24 52.096 52.096 0 0 0 -10.496 0.992v-6.24L246.08 224a75.04 75.04 0 0 1 14.752 23.488c1.664 4.16 3.104 8.416 4.256 12.768 1.184 4.32 2.432 9.056 3.744 14.24 2.496 -3.68 5.6 -8.32 9.28 -14.016a143.68 143.68 0 0 1 12.736 -16.736c4.8 -5.504 9.92 -10.08 15.232 -13.76A32.64 32.64 0 0 1 322.848 224c4.16 0 7.904 1.088 11.232 3.232 3.36 2.176 5.024 5.6 5.024 10.24 0 9.024 -4.512 13.536 -13.504 13.536a19.456 19.456 0 0 1 -9.28 -2.24 19.456 19.456 0 0 0 -9.216 -2.272c-3.2 0 -6.496 1.6 -10.016 4.736a73.6 73.6 0 0 0 -9.984 11.264 304 304 0 0 0 -15.52 23.488l14.272 59.264a49.92 49.92 0 0 0 2.976 11.008 21.408 21.408 0 0 0 3.008 5.472 5.888 5.888 0 0 0 4 2.528 11.84 11.84 0 0 0 6.752 -2.752 68.48 68.48 0 0 0 13.76 -15.04c1.664 -2.464 2.976 -4.8 4 -6.976l5.984 3.008a64.8 64.8 0 0 1 -7.008 11.744 120.8 120.8 0 0 1 -11.232 13.504 108.16 108.16 0 0 1 -12.992 11.52c-4.512 3.328 -8.608 4.896 -12.256 4.736a12.704 12.704 0 0 1 -8.992 -3.264 47.712 47.712 0 0 1 -6.528 -7.488 51.168 51.168 0 0 1 -4.224 -11.52 264.416 264.416 0 0 1 -3.776 -16.224 1093.12 1093.12 0 0 1 -3.232 -17.024 70.784 70.784 0 0 0 -3.52 -13.248l-6.496 12a143.648 143.648 0 0 1 -8.96 14.496c-3.52 5.024 -7.104 10.112 -10.784 15.264a78.72 78.72 0 0 1 -12 13.504c-4.32 3.84 -8.48 7.072 -12.48 9.76A21.12 21.12 0 0 1 189.12 384a17.248 17.248 0 0 1 -11.52 -4.256 14.528 14.528 0 0 1 -5.216 -11.008zm195.52 15.264c8.96 -11.52 15.872 -23.936 20.736 -37.248a123.84 123.84 0 0 0 7.232 -42.24c0 -15.04 -2.4 -29.184 -7.232 -42.528A146.24 146.24 0 0 0 367.84 224h23.488a120.64 120.64 0 0 1 29.504 80.48c0 15.168 -2.336 29.344 -6.976 42.528 -4.672 13.152 -12.16 25.472 -22.528 36.992h-23.488zM120.64 384a107.936 107.936 0 0 1 -22.528 -36.768 127.04 127.04 0 0 1 -6.976 -42.752c0 -30.496 9.824 -57.312 29.504 -80.48h23.232a132.224 132.224 0 0 0 -20.48 37.76 134.56 134.56 0 0 0 -7.264 42.72A125.728 125.728 0 0 0 143.872 384H120.64zM496 32H16l-16 16v416l16 16h480l16 -16v-416l-16 -16zM480 448H32V160h448v288zm0 -320H32V64h448v64z"]},vsVerified:{prefix:"vs",iconName:"verified",icon:[512,512,[],"f000","M245.44 471.04h22.72L323.2 416h76.8l16 -16v-77.44l55.68 -55.04v-22.72l-54.72 -55.04V111.68l-16 -15.68H323.2L268.16 41.28h-22.72L192 96H112.96L96 112v77.76L41.92 244.8v22.72L96 322.56v77.44l16.96 16H192l53.44 55.04zM197.12 384H128V315.84l-3.84 -11.2L75.84 256l47.36 -48.32 4.8 -11.2V128h69.12l11.52 -4.48L256 75.2l49.28 48.32 11.2 4.48H384v68.48l5.44 11.2L438.08 256l-49.6 48.64 -4.48 11.2V384H316.48l-12.16 4.8L256 437.12l-47.36 -48.64 -11.52 -4.48zm18.24 -48.64h22.72l120.64 -120.64L336 192 226.88 301.44 182.72 257.28 160 280l55.36 55.36z"]},vsVersions:{prefix:"vs",iconName:"versions",icon:[512,512,[],"f000","M256 96L224 128v256l32 32h192l32 -32V128l-32 -32H256zm192 288H256V128h192v256zM160 288V160h32V128H144l-16 16v224l16 16H192v-32H160V288zM64 256V192h32V160H48l-16 16v160l16 16H96v-32H64V256z"]},vsVmActive:{prefix:"vs",iconName:"vm-active",icon:[512,512,[],"f000","M48 64h416l16 16v176.096a160.192 160.192 0 0 0 -32 -18.656V96H64v288h160a160 160 0 0 0 32 96H128v-32h96v-32H48l-16 -16v-320l16 -16zm264.896 213.568a128 128 0 1 1 142.208 212.864 128 128 0 0 1 -142.208 -212.864zm68.16 159.68l76.384 -101.824 -25.6 -19.2 -66.464 88.608 -41.632 -33.312 -20 24.96 54.528 43.648 22.816 -2.88z"]},vsVmConnect:{prefix:"vs",iconName:"vm-connect",icon:[512,512,[],"f000","M48 64h416l16 16v176.096a160.192 160.192 0 0 0 -32 -18.656V96H64v288h160a160 160 0 0 0 32 96H128v-32h96v-32H48l-16 -16v-320l16 -16zM384 256a128 128 0 1 0 0 256 128 128 0 0 0 0 -256zm0 224a96 96 0 1 1 0 -192.032A96 96 0 0 1 384 480zm4.256 -114.08l45.952 45.952 13.792 -13.792 -32.128 -32.16L448 333.792l-13.792 -13.76 -45.952 45.888zm-36.128 34.144L320 367.936l13.792 -13.792 45.952 45.92 -45.952 45.952 -13.792 -13.792 32.128 -32.16z"]},vsVmOutline:{prefix:"vs",iconName:"vm-outline",icon:[512,512,[],"f000","M48 64h416l16 16v176.096a160.192 160.192 0 0 0 -32 -18.656V96H64v288h160a160 160 0 0 0 32 96H128v-32h96v-32H48l-16 -16v-320l16 -16zM384 256a128 128 0 1 0 0 256 128 128 0 0 0 0 -256zm0 224a96 96 0 1 1 0 -192.032A96 96 0 0 1 384 480z"]},vsVmRunning:{prefix:"vs",iconName:"vm-running",icon:[512,512,[],"f000","M48 64h416l16 16v176.096a160.192 160.192 0 0 0 -32 -18.656V96H64v288h160a160 160 0 0 0 32 96H128v-32h96v-32H48l-16 -16v-320l16 -16zM384 256c11.744 0 23.072 1.504 34.016 4.48 10.88 3.008 21.056 7.36 30.496 13.024 9.408 5.664 18.016 12.32 25.856 20 7.84 7.68 14.56 16.288 20.16 25.856a128.96 128.96 0 0 1 12.96 98.624c-2.976 10.944 -7.328 21.12 -12.992 30.528a140.224 140.224 0 0 1 -20 25.856c-7.68 7.84 -16.288 14.56 -25.856 20.16a128.928 128.928 0 0 1 -98.624 12.96 121.088 121.088 0 0 1 -30.528 -12.992 140.224 140.224 0 0 1 -25.856 -20 121.856 121.856 0 0 1 -20.16 -25.856 128.864 128.864 0 0 1 -12.96 -98.624c2.976 -10.944 7.328 -21.12 12.992 -30.528 5.664 -9.408 12.32 -18.016 20 -25.856 7.68 -7.84 16.288 -14.56 25.856 -20.16A128.896 128.896 0 0 1 384 256zm64 127.616L352 320v128l96 -64.384z"]},vsVm:{prefix:"vs",iconName:"vm",icon:[512,512,[],"f000","M464 64h-416l-16 16v320l16 16H224v32H128v32h256v-32H288v-32h176l16 -16v-320l-16 -16zM448 384H64V96h384v288z"]},vsWand:{prefix:"vs",iconName:"wand",icon:[512,512,[],"f000","M140.16 160h32V128h32V96h-32V64h-32v32h-32v32h32v32zm256 128h-32v32h-32v32h32v32h32v-32h32v-32h-32V288zM448 64V32h-32v32h-32v32h32v32h32V96h32V64h-32zm-94.304 78.144a47.68 47.68 0 0 0 -67.84 0l-239.68 239.68a47.68 47.68 0 0 0 0 67.84c18.88 18.88 49.28 18.88 67.84 0l239.68 -239.68c18.56 -18.56 18.56 -48.96 0 -67.84zm-262.4 284.8c-6.4 6.4 -16.32 6.4 -22.72 0 -6.4 -6.4 -6.4 -16.32 0 -22.72l206.72 -206.72 22.72 22.72 -206.72 206.72zm239.68 -239.68l-10.24 10.24 -22.72 -22.72 10.24 -10.24c6.4 -6.4 16.32 -6.4 22.72 0 6.08 6.4 6.08 16.64 0 22.72z"]},vsWarning:en,vsWatch:tn,vsWhitespace:{prefix:"vs",iconName:"whitespace",icon:[512,512,[],"f000","M384 64V32H208a112 112 0 0 0 0 224H256v160H224v32h160v-32h-32V64h32zM256 224H208a80 80 0 1 1 0 -160H256v160zm64 192H288V64h32v352z"]},vsWholeWord:{prefix:"vs",iconName:"whole-word",icon:[512,512,[],"f000","M32 64h448v32H32V64zm416 64h-32v256h32V128zm-87.296 140.384a75.296 75.296 0 0 0 -11.52 -25.152 55.872 55.872 0 0 0 -19.488 -16.96 58.624 58.624 0 0 0 -27.712 -6.176c-6.336 0 -12.16 0.768 -17.504 2.336a56.32 56.32 0 0 0 -14.496 6.56 55.168 55.168 0 0 0 -11.68 10.176l-5.728 8.256V146.496H224V384h28.576v-18.4l4.032 5.6c2.784 3.264 6.048 6.08 9.728 8.608 3.744 2.496 7.968 4.48 12.736 5.952 4.768 1.472 10.048 2.176 15.936 2.176 11.296 0 21.312 -2.272 29.984 -6.784 8.704 -4.576 15.968 -10.816 21.824 -18.752 5.856 -8 10.272 -17.376 13.248 -28.128 2.976 -10.816 4.48 -22.496 4.48 -35.104a120.192 120.192 0 0 0 -3.84 -30.784zM313.376 248.96c4.832 2.272 9.024 5.632 12.48 10.048 3.488 4.48 6.208 10.016 8.16 16.544 1.632 5.568 2.624 11.872 2.848 18.784l-0.224 4c0 10.464 -1.056 19.84 -3.2 27.808a60.352 60.352 0 0 1 -8.896 19.648c-3.744 5.184 -8.32 9.12 -13.472 11.712 -10.304 5.184 -24.32 5.312 -34.208 0.48a40.448 40.448 0 0 1 -12.576 -9.472 40.736 40.736 0 0 1 -6.976 -11.744s-5.728 -14.304 -5.728 -30.304c0 -16 5.728 -32.064 5.728 -32.064 1.984 -5.664 4.352 -10.176 7.168 -13.76 3.648 -4.576 8.192 -8.288 13.568 -11.04 5.376 -2.752 11.68 -4.128 18.784 -4.128 6.08 0 11.648 1.184 16.544 3.488zM480 416H32v32h448v-32zM90.016 320l-23.296 64.992H32l0.8 -2.304 78.112 -226.752h30.112l79.52 229.056H185.92L161.024 320H90.016zm35.872 -114.496h-0.704l-28.96 88.096h58.912l-29.248 -88.096z"]},vsWindow:{prefix:"vs",iconName:"window",icon:[512,512,[],"f000","M464 64h-416l-16 16v352l16 16h416l16 -16v-352l-16 -16zM448 416H64V192h384v224zm0 -256H64V96h384v64z"]},vsWordWrap:{prefix:"vs",iconName:"word-wrap",icon:[512,512,[],"f000","M123.776 110.368a38.72 38.72 0 0 0 -15.136 -10.528c-8.768 -3.552 -19.936 -4.8 -33.76 -2.432a112 112 0 0 0 -22.72 6.656c-2.624 1.12 -5.12 2.464 -7.52 4l-1.376 0.96v33.792l5.376 -4.448c4.8 -3.968 10.432 -7.2 16.864 -9.696 6.272 -2.368 12.8 -3.616 19.328 -3.616 6.016 0 10.56 1.632 13.792 5.024 2.784 3.04 4.384 7.936 4.704 14.592l-30.784 4.608c-7.008 0.96 -13.12 2.752 -18.24 5.312a39.84 39.84 0 0 0 -12.736 9.952c-3.296 4 -5.792 8.64 -7.328 13.632 -3.104 10.56 -2.976 21.76 0.352 32.256a35.072 35.072 0 0 0 20.416 21.44c4.96 2.016 10.496 2.976 16.896 2.976a40 40 0 0 0 31.296 -14.112v11.04h32.224V148.8c0 -8.16 -0.96 -15.488 -2.848 -21.792a45.536 45.536 0 0 0 -8.8 -16.64zm-20.352 60.672v7.552c0 3.808 -0.576 7.392 -1.76 10.912a23.84 23.84 0 0 1 -12.064 14.304 22.208 22.208 0 0 1 -16.384 0.864 14.528 14.528 0 0 1 -4.992 -3.008 12.448 12.448 0 0 1 -3.008 -4.448 15.168 15.168 0 0 1 -1.12 -5.952c0 -2.464 0.32 -4.704 0.768 -6.784a10.56 10.56 0 0 1 2.496 -4.512 13.952 13.952 0 0 1 5.152 -3.488 41.6 41.6 0 0 1 9.76 -2.336l21.152 -3.104zm161.632 -34.144a72.096 72.096 0 0 0 -7.808 -20.992 43.328 43.328 0 0 0 -13.952 -14.688 37.28 37.28 0 0 0 -20.544 -5.536 36.352 36.352 0 0 0 -22.08 7.136 42.56 42.56 0 0 0 -8.448 8.512V32H162.88v199.168h29.376v-8.992c3.936 4.864 9.184 8.512 15.104 10.496 3.136 1.024 6.656 1.504 10.56 1.504 8.16 0 15.456 -1.92 21.664 -5.664 6.144 -3.68 11.36 -8.896 15.552 -15.552a73.28 73.28 0 0 0 9.376 -22.976 123.84 123.84 0 0 0 3.072 -28.352 118.848 118.848 0 0 0 -2.496 -24.736zm-27.52 24.256c0 7.424 -0.64 14.048 -1.92 19.616 -1.152 5.504 -2.88 10.08 -5.088 13.568a20.448 20.448 0 0 1 -7.456 7.584 18.624 18.624 0 0 1 -18.08 0.448 21.856 21.856 0 0 1 -6.72 -5.856 29.6 29.6 0 0 1 -4.544 -9.056A37.984 37.984 0 0 1 192 176v-16.544c0 -5.248 0.64 -10.048 1.92 -14.304 1.152 -4.224 2.784 -7.744 4.992 -10.752a21.376 21.376 0 0 1 7.296 -6.656 18.688 18.688 0 0 1 9.28 -2.272 17.728 17.728 0 0 1 15.872 8.928c2.016 3.168 3.456 6.848 4.576 11.328 0.992 4.576 1.6 9.792 1.6 15.424zM77.024 316.8a29.216 29.216 0 0 1 10.112 -7.648c6.976 -3.2 17.504 -3.36 24.512 -0.576 3.328 1.344 6.528 3.2 10.24 5.888l10.56 8.32V286.24l-3.104 -1.984a61.824 61.824 0 0 0 -28.96 -6.88c-9.856 0 -18.976 1.824 -27.072 5.376 -8 3.52 -14.944 8.64 -20.704 15.2 -5.76 6.72 -10.176 14.496 -12.896 22.944 -2.88 8.704 -4.384 18.24 -4.384 28.64 0 9.248 1.376 17.952 4.16 25.856 2.752 7.968 6.752 15.072 11.936 20.864 5.152 5.92 11.552 10.656 19.104 14.112 7.424 3.328 15.776 4.96 24.896 4.96 7.456 0 13.888 -0.896 19.616 -2.688 5.28 -1.6 10.304 -3.936 14.912 -6.944l2.496 -1.952v-28.448l-6.4 3.04a12.8 12.8 0 0 1 -2.432 0.832c-1.6 0.544 -3.168 1.12 -4.096 1.568 -1.152 0.736 -7.264 2.88 -7.264 2.88 -1.92 0.768 -4.48 1.376 -6.976 1.888a31.264 31.264 0 0 1 -19.168 -1.824 26.464 26.464 0 0 1 -9.792 -7.2 34.816 34.816 0 0 1 -6.56 -12.032 55.296 55.296 0 0 1 -2.432 -16.928c0 -6.72 0.896 -12.768 2.656 -17.92 1.728 -5.056 4.16 -9.408 7.04 -12.8zM448 192h-128V160h144l16 16v192l-16 16H252.128l66.24 66.272 -22.592 22.624 -92.48 -92.448v-22.624l92.48 -92.48L318.4 288l-64 64H448V192z"]},vsWorkspaceTrusted:{prefix:"vs",iconName:"workspace-trusted",icon:[512,512,[],"f000","M258.208 0c8.384 0 16.64 0.544 24.32 1.824a131.2 131.2 0 0 1 22.304 4.928c7.296 2.208 14.432 4.96 21.568 8.416 6.944 3.296 14.08 7.328 21.216 11.712 12.064 7.68 23.936 13.888 36.032 18.848a241.184 241.184 0 0 0 74.592 16.8c12.992 0.928 26.336 1.472 40.224 1.472v128c0 24.32 -3.104 47.36 -9.312 69.312a287.872 287.872 0 0 1 -25.248 62.176 329.984 329.984 0 0 1 -38.016 55.2 482.912 482.912 0 0 1 -47.744 49.024 562.24 562.24 0 0 1 -54.496 42.4c-19.008 13.184 -38.208 25.44 -57.408 36.576l-7.68 4.576 -7.68 -4.576a866.976 866.976 0 0 1 -57.792 -36.576 498.56 498.56 0 0 1 -54.496 -42.4 482.624 482.624 0 0 1 -47.712 -49.024 350.304 350.304 0 0 1 -38.208 -55.2 312.096 312.096 0 0 1 -25.248 -62.176A252.704 252.704 0 0 1 18.272 192V64c13.92 0 27.264 -0.544 40.256 -1.472a261.12 261.12 0 0 0 38.016 -5.472c12.256 -2.752 24.512 -6.4 36.576 -11.328A210.016 210.016 0 0 0 168.96 27.072C183.04 17.92 197.312 11.168 211.392 6.72A153.28 153.28 0 0 1 258.208 0zm208.064 95.456a306.112 306.112 0 0 1 -71.488 -12.064 254.72 254.72 0 0 1 -65.472 -30.176A136.416 136.416 0 0 0 295.36 37.12 124.32 124.32 0 0 0 258.368 31.808a127.68 127.68 0 0 0 -37.28 5.312 126.272 126.272 0 0 0 -33.856 16.096A253.632 253.632 0 0 1 121.6 83.52c-22.688 6.592 -46.432 10.624 -71.328 12.096v96.544c0 21.216 2.752 41.504 8.256 61.056a274.56 274.56 0 0 0 23.04 55.776 307.328 307.328 0 0 0 34.56 50.304c13.344 15.712 27.584 30.336 42.944 44.224 15.36 13.92 31.456 26.72 48.288 38.592 16.992 11.904 34.016 22.688 51.008 32.544a716.704 716.704 0 0 0 50.848 -32.544 492.448 492.448 0 0 0 48.448 -38.592c15.36 -13.888 29.632 -28.512 42.976 -44.224a307.072 307.072 0 0 0 34.56 -50.304 264.256 264.256 0 0 0 22.688 -55.776 218.048 218.048 0 0 0 8.384 -61.056V95.456zm-88.768 55.232l-14.08 -12.096 -12.992 1.12 -139.52 164.736 -47.52 -67.84 -12.8 -2.176 -14.816 10.592 -2.208 12.8 61.088 87.232 6.944 3.84 14.624 0.896 7.488 -3.264 154.72 -182.88 -0.928 -12.96z"]},vsWorkspaceUnknown:{prefix:"vs",iconName:"workspace-unknown",icon:[512,512,[],"f000","M258.144 0c8.416 0 16.64 0.544 24.32 1.824a131.2 131.2 0 0 1 22.304 4.928c7.328 2.208 14.464 4.96 21.6 8.416 6.944 3.296 14.08 7.328 21.184 11.712a230.4 230.4 0 0 0 36.032 18.848 241.088 241.088 0 0 0 74.624 16.8c12.96 0.928 26.304 1.472 40.224 1.472v128c0 24.32 -3.104 47.36 -9.344 69.312a287.872 287.872 0 0 1 -25.216 62.176 329.792 329.792 0 0 1 -38.048 55.2 482.624 482.624 0 0 1 -47.712 49.024 562.24 562.24 0 0 1 -54.496 42.4c-19.008 13.184 -38.208 25.44 -57.408 36.576l-7.68 4.576 -7.68 -4.576a866.816 866.816 0 0 1 -57.792 -36.576 498.528 498.528 0 0 1 -54.496 -42.4 482.56 482.56 0 0 1 -47.712 -49.024 350.336 350.336 0 0 1 -38.24 -55.2 312.096 312.096 0 0 1 -25.216 -62.176A252.704 252.704 0 0 1 18.24 192V64c13.888 0 27.232 -0.544 40.224 -1.472a261.12 261.12 0 0 0 38.048 -5.472c12.256 -2.752 24.48 -6.4 36.576 -11.328a210.016 210.016 0 0 0 35.84 -18.656C183.008 17.92 197.248 11.168 211.328 6.72A153.28 153.28 0 0 1 258.144 0zm208.096 95.456a306.144 306.144 0 0 1 -71.488 -12.064 254.72 254.72 0 0 1 -65.472 -30.176 136.448 136.448 0 0 0 -34.016 -16.096A124.32 124.32 0 0 0 258.336 31.808a127.68 127.68 0 0 0 -37.312 5.312 126.272 126.272 0 0 0 -33.824 16.096 253.664 253.664 0 0 1 -65.632 30.336c-22.688 6.592 -46.464 10.624 -71.328 12.096v96.544c0 21.216 2.752 41.504 8.224 61.056a274.56 274.56 0 0 0 23.04 55.776 307.328 307.328 0 0 0 34.56 50.304c13.344 15.712 27.616 30.336 42.976 44.224 15.36 13.92 31.456 26.72 48.288 38.592 16.992 11.904 33.984 22.688 51.008 32.544a716.8 716.8 0 0 0 50.816 -32.544 492.288 492.288 0 0 0 48.48 -38.592c15.36 -13.888 29.6 -28.512 42.976 -44.224a307.488 307.488 0 0 0 34.56 -50.304 264.608 264.608 0 0 0 22.656 -55.776 218.048 218.048 0 0 0 8.416 -61.056V95.456zM301.856 151.04c5.472 5.472 10.048 12.064 13.152 19.392 3.296 7.296 4.96 15.36 4.768 24.128a51.2 51.2 0 0 1 -3.648 20.48 71.68 71.68 0 0 1 -9.344 15.36 89.184 89.184 0 0 1 -11.328 12.256 144.64 144.64 0 0 0 -10.784 10.24 45.472 45.472 0 0 0 -7.68 10.24 22.4 22.4 0 0 0 -2.752 11.136v11.52l-4.192 4.416h-22.88l-4.576 -4.576V274.24c0 -7.68 1.28 -14.4 3.84 -20.288 2.4 -5.664 5.312 -10.976 8.96 -15.552a109.44 109.44 0 0 1 11.712 -12.224c3.84 -3.488 7.328 -6.784 10.624 -10.24 3.104 -3.296 5.824 -6.784 7.84 -10.432a22.624 22.624 0 0 0 2.752 -11.328 30.912 30.912 0 0 0 -2.368 -11.52 31.104 31.104 0 0 0 -6.4 -9.536 30.08 30.08 0 0 0 -42.24 0 28.16 28.16 0 0 0 -6.4 9.536 26.528 26.528 0 0 0 -2.4 11.52L224 198.72h-22.88l-4.192 -4.384c0 -8.416 1.472 -16.448 4.736 -23.936 3.296 -7.328 7.68 -13.92 13.184 -19.392 5.664 -5.664 12.256 -10.24 19.552 -13.344a60.256 60.256 0 0 1 48.096 0c7.328 3.296 13.888 7.68 19.392 13.344zM242.24 308.672l4.576 -4.576h22.848l4.576 4.576v22.848l-4.576 4.576h-22.848l-4.576 -4.576v-22.848z"]},vsWorkspaceUntrusted:{prefix:"vs",iconName:"workspace-untrusted",icon:[512,512,[],"f000","M258.144 0c8.416 0 16.64 0.544 24.32 1.824a131.2 131.2 0 0 1 22.304 4.928c7.328 2.208 14.464 4.96 21.6 8.416 6.944 3.296 14.08 7.328 21.184 11.712a230.4 230.4 0 0 0 36.032 18.848 241.088 241.088 0 0 0 74.624 16.8c12.96 0.928 26.304 1.472 40.224 1.472v128c0 24.32 -3.104 47.36 -9.344 69.312a287.872 287.872 0 0 1 -25.216 62.176 329.792 329.792 0 0 1 -38.048 55.2 482.624 482.624 0 0 1 -47.712 49.024 562.24 562.24 0 0 1 -54.496 42.4c-19.008 13.184 -38.208 25.44 -57.408 36.576l-7.68 4.576 -7.68 -4.576a866.816 866.816 0 0 1 -57.792 -36.576 498.528 498.528 0 0 1 -54.496 -42.4 482.56 482.56 0 0 1 -47.712 -49.024 350.336 350.336 0 0 1 -38.24 -55.2 312.096 312.096 0 0 1 -25.216 -62.176A252.704 252.704 0 0 1 18.24 192V64c13.888 0 27.232 -0.544 40.224 -1.472a261.12 261.12 0 0 0 38.048 -5.472c12.256 -2.752 24.48 -6.4 36.576 -11.328a210.016 210.016 0 0 0 35.84 -18.656C183.008 17.92 197.248 11.168 211.328 6.72A153.28 153.28 0 0 1 258.144 0zm208.096 95.456a306.144 306.144 0 0 1 -71.488 -12.064 254.72 254.72 0 0 1 -65.472 -30.176 136.448 136.448 0 0 0 -34.016 -16.096A124.32 124.32 0 0 0 258.336 31.808a127.68 127.68 0 0 0 -37.312 5.312 126.272 126.272 0 0 0 -33.824 16.096 253.664 253.664 0 0 1 -65.632 30.336c-22.688 6.592 -46.464 10.624 -71.328 12.096v96.544c0 21.216 2.752 41.504 8.224 61.056a274.56 274.56 0 0 0 23.04 55.776 307.328 307.328 0 0 0 34.56 50.304c13.344 15.712 27.616 30.336 42.976 44.224 15.36 13.92 31.456 26.72 48.288 38.592 16.992 11.904 33.984 22.688 51.008 32.544a716.8 716.8 0 0 0 50.816 -32.544 492.288 492.288 0 0 0 48.48 -38.592c15.36 -13.888 29.6 -28.512 42.976 -44.224a307.488 307.488 0 0 0 34.56 -50.304 264.608 264.608 0 0 0 22.656 -55.776 218.048 218.048 0 0 0 8.416 -61.056V95.456zm-121.056 78.816l-12.8 -12.992h-6.592L262.4 224.736 198.912 161.28h-6.4l-12.992 12.992v6.4l63.456 63.456L179.52 307.52v6.592l12.992 12.8h6.4l63.456 -63.456 63.424 63.456h6.592l12.8 -12.8V307.52L281.728 244.16l63.456 -63.456v-6.4z"]},vsZoomIn:{prefix:"vs",iconName:"zoom-in",icon:[512,512,[],"f000","M384.864 196.768a176.64 176.64 0 0 1 -40.64 125.056l136.32 136.32 -22.4 22.72 -136.32 -136.64a176.64 176.64 0 1 1 63.04 -147.456zm-174.4 156.416a144.32 144.32 0 0 0 101.76 -42.24l-1.28 0.64a144.32 144.32 0 0 0 43.52 -102.4 144 144 0 1 0 -144 144zm78.08 -128v-32h-64v-64h-32v64h-64v32h64v64h32v-64h64z"]},vsZoomOut:{prefix:"vs",iconName:"zoom-out",icon:[512,512,[],"f000","M384.864 196.768a176.64 176.64 0 0 1 -40.64 125.056l136.32 136.32 -22.4 22.72 -136.32 -136.64a176.64 176.64 0 1 1 63.04 -147.456zm-174.4 156.416a144.32 144.32 0 0 0 101.76 -42.24l-1.28 0.64a144.32 144.32 0 0 0 43.52 -102.4 144 144 0 1 0 -144 144zm-81.28 -159.36h160v32h-160v-32z"]},dhArrowToBottom:nn,dhArrowToTop:an,dhCheckSquare:sn,dhChevronDownSquare:{prefix:"dh",iconName:"chevron-down-square",icon:[512,512,[],"f000","M425.6 64H86.4l-22.4 22.4v342.4l22.4 19.2h342.4l22.4 -22.4V86.4l-25.6 -22.4zm-160 275.2h-19.2l-128 -131.2 19.2 -19.2L256 310.4 377.6 192l19.2 19.2 -131.2 128z"]},dhCircleLargeOutlineNotch:{prefix:"dh",iconName:"circle-large-outline-notch",icon:[512,512,[],"f000","M470.4 195.2c-9.6 -38.4 -28.8 -70.4 -57.6 -99.2 -25.6 -25.6 -57.6 -44.8 -92.8 -57.6v35.2c12.8 3.2 22.4 9.6 32 16l38.4 28.8c12.8 12.8 22.4 25.6 28.8 38.4 9.6 12.8 16 28.8 19.2 44.8 6.4 19.2 9.6 35.2 9.6 54.4 0 16 -3.2 35.2 -6.4 51.2s-9.6 32 -19.2 44.8c-16 28.8 -41.6 51.2 -70.4 70.4 -12.8 9.6 -28.8 16 -44.8 19.2 -16 3.2 -32 6.4 -51.2 6.4 -16 0 -35.2 -3.2 -51.2 -6.4s-32 -9.6 -44.8 -19.2l-38.4 -28.8c-25.6 -25.6 -41.6 -54.4 -51.2 -86.4 -3.2 -16 -6.4 -32 -6.4 -51.2 0 -16 3.2 -35.2 6.4 -51.2s9.6 -32 19.2 -44.8c16 -28.8 41.6 -54.4 70.4 -70.4 9.6 -6.4 22.4 -9.6 32 -16v-32c-16 6.4 -35.2 12.8 -48 22.4 -35.2 19.2 -60.8 44.8 -80 80 -12.8 16 -19.2 35.2 -25.6 51.2C35.2 214.4 32 236.8 32 256c0 19.2 3.2 41.6 6.4 60.8 6.4 16 12.8 35.2 25.6 51.2 9.6 16 22.4 32 35.2 44.8 12.8 16 28.8 25.6 44.8 35.2 16 9.6 35.2 16 54.4 22.4 16 6.4 38.4 9.6 57.6 9.6 19.2 0 41.6 -3.2 60.8 -6.4 19.2 -6.4 35.2 -12.8 54.4 -22.4 32 -19.2 60.8 -48 80 -80 9.6 -16 16 -35.2 22.4 -54.4 3.2 -19.2 6.4 -41.6 6.4 -60.8s-3.2 -41.6 -9.6 -60.8z"]},dhClock:{prefix:"dh",iconName:"clock",icon:[512,512,[],"f000","M470.4 195.2c-9.6 -38.4 -28.8 -70.4 -57.6 -99.2 -25.6 -25.6 -60.8 -44.8 -96 -54.4C297.6 35.2 275.2 32 256 32c-19.2 0 -41.6 3.2 -60.8 9.6 -16 3.2 -35.2 9.6 -51.2 22.4 -35.2 19.2 -60.8 44.8 -80 80 -12.8 16 -19.2 35.2 -25.6 51.2C35.2 214.4 32 236.8 32 256c0 19.2 3.2 41.6 6.4 60.8 6.4 16 12.8 35.2 25.6 51.2 9.6 16 22.4 32 35.2 44.8 12.8 16 28.8 25.6 44.8 35.2 16 9.6 35.2 16 54.4 22.4 16 6.4 38.4 9.6 57.6 9.6 19.2 0 41.6 -3.2 60.8 -6.4 19.2 -6.4 35.2 -12.8 54.4 -22.4 32 -19.2 60.8 -48 80 -80 9.6 -16 16 -35.2 22.4 -54.4 3.2 -19.2 6.4 -41.6 6.4 -60.8s-3.2 -41.6 -9.6 -60.8zm-115.2 121.6l-115.2 -64V89.6h32v147.2L371.2 288l-16 28.8z"]},dhExclamation:rn,dhEyeSlash:on,dhEye:ln,dhFileCertificate:{prefix:"dh",iconName:"file-certificate",icon:[512,512,[],"f000","M128 448V64h160v128h128v32h32V160l-9.6 -22.4 -96 -96L320 32H128L96 64v384l32 32h96v-32H128zm192 -384l96 96h-96V64zm60.8 224l19.2 19.2 9.6 9.6H448V352l9.6 9.6 19.2 19.2 -19.2 19.2 -9.6 9.6V448h-38.4l-9.6 9.6 -19.2 19.2 -16 -16 -9.6 -9.6H313.6v-38.4l-9.6 -9.6 -16 -22.4 19.2 -19.2 6.4 -9.6V313.6H352l9.6 -9.6 19.2 -16m6.4 -38.4h-12.8l-32 32H294.4l-12.8 9.6v48l-32 35.2v12.8l32 35.2v48l9.6 9.6h48l32 35.2h12.8l35.2 -35.2h48l9.6 -9.6v-48l35.2 -35.2v-12.8l-32 -35.2V291.2l-9.6 -9.6h-48l-35.2 -32z"]},dhFileCsv:cn,dhFileDownload:hn,dhFilePrint:dn,dhFileSearch:un,dhFileSpreadsheet:mn,dhFilterFilled:pn,dhFilterSlash:gn,dhFreeze:vn,dhGearFilled:fn,dhGearsFilled:{prefix:"dh",iconName:"gears-filled",icon:[512,512,[],"f000","M281.6 112l-48 32 -12.8 -57.6H153.6l-16 57.6 -51.2 -32L41.6 160l35.2 48 -60.8 9.6V288l57.6 12.8 -32 51.2 48 48 48 -35.2 12.8 60.8h70.4l12.8 -57.6 51.2 32 48 -48 -32 -51.2 60.8 -12.8V220.8l-64 -12.8 32 -51.2 -48 -44.8zm38.4 32l28.8 6.4 -16 25.6 25.6 25.6 25.6 -16 6.4 28.8h35.2l6.4 -28.8 25.6 16 22.4 -25.6 -16 -25.6 28.8 -6.4V108.8l-28.8 -6.4 16 -22.4 -25.6 -25.6 -25.6 16 -6.4 -28.8h-35.2l-3.2 28.8 -25.6 -16 -25.6 25.6 16 25.6 -28.8 3.2v35.2zm86.4 -41.6c16 0 25.6 9.6 25.6 25.6s-9.6 25.6 -25.6 25.6 -25.6 -9.6 -25.6 -25.6 9.6 -25.6 25.6 -25.6zM320 403.2l28.8 6.4 -16 25.6 25.6 25.6 25.6 -16 6.4 28.8h35.2l6.4 -28.8 25.6 16 25.6 -25.6 -16 -25.6 28.8 -6.4v-35.2l-28.8 -6.4 16 -25.6 -25.6 -25.6 -25.6 16 -6.4 -28.8h-35.2l-6.4 28.8 -25.6 -16 -25.6 25.6 16 25.6 -28.8 6.4v35.2zm86.4 -44.8c16 0 25.6 9.6 25.6 25.6s-9.6 25.6 -25.6 25.6 -25.6 -9.6 -25.6 -25.6c0 -12.8 9.6 -25.6 25.6 -25.6zM220.8 291.2c-19.2 19.2 -48 19.2 -70.4 0 -19.2 -19.2 -19.2 -48 0 -70.4s48 -19.2 70.4 0 19.2 48 0 70.4z"]},dhGraphLineDown:bn,dhGraphLineUp:Cn,dhICursor:Sn,dhInput:En,dhNewCircleLargeFilled:wn,dhNewSquareFilled:{prefix:"dh",iconName:"new-square-filled",icon:[512,512,[],"f000","M432 32h-384l-16 16v384l16 16h384l16 -16v-384l-16 -16zM352 256H256v96H224V256H128V224h96V128h32v96h96v32z"]},dhPanels:yn,dhPython:Tn,dhRefresh:On,dhRemoveSquareFilled:Mn,dhShapes:Nn,dhShareFilled:{prefix:"dh",iconName:"share-filled",icon:[512,512,[],"f000","M400 320c-25.6 0 -51.2 12.8 -64 35.2L188.8 288c3.2 -3.2 3.2 -9.6 3.2 -16 0 -9.6 -3.2 -16 -3.2 -22.4l150.4 -83.2c16 16 35.2 25.6 60.8 25.6C444.8 192 480 156.8 480 112S444.8 32 400 32 320 67.2 320 112c0 9.6 3.2 16 3.2 22.4L172.8 220.8C156.8 201.6 137.6 192 112 192 67.2 192 32 227.2 32 272S67.2 352 112 352c25.6 0 51.2 -12.8 64 -35.2l144 64c0 6.4 -3.2 12.8 -3.2 16 0 44.8 35.2 80 80 80s80 -35.2 80 -80 -32 -76.8 -76.8 -76.8z"]},dhShare:{prefix:"dh",iconName:"share",icon:[512,512,[],"f000","M400 320c-25.6 0 -51.2 12.8 -64 35.2L188.8 288c3.2 -3.2 3.2 -9.6 3.2 -16 0 -9.6 -3.2 -16 -3.2 -22.4l150.4 -83.2c16 16 35.2 25.6 60.8 25.6C444.8 192 480 156.8 480 112S444.8 32 400 32 320 67.2 320 112c0 9.6 3.2 16 3.2 22.4L172.8 220.8C156.8 201.6 137.6 192 112 192 67.2 192 32 227.2 32 272S67.2 352 112 352c25.6 0 51.2 -12.8 64 -35.2l144 64c0 6.4 -3.2 12.8 -3.2 16 0 44.8 35.2 80 80 80s80 -35.2 80 -80 -32 -76.8 -76.8 -76.8zm0 -256c25.6 0 48 22.4 48 48S425.6 160 400 160 352 137.6 352 112 374.4 64 400 64zm-288 256C86.4 320 64 297.6 64 272S86.4 224 112 224 160 246.4 160 272 137.6 320 112 320zm288 128c-25.6 0 -48 -22.4 -48 -48s22.4 -48 48 -48 48 22.4 48 48 -22.4 48 -48 48z"]},dhSortAlphaDown:Dn,dhSortAlphaUp:xn,dhSortAmountDown:Rn,dhSortDown:In,dhSortUp:Ln,dhSort:Fn,dhSplitBoth:{prefix:"dh",iconName:"split-both",icon:[512,512,[],"f000","M448 32H96L64 64v352l32 32h352l32 -32V64l-32 -32zM96 64h160v160H96V64zm0 352V256h160v160H96zm352 0H288V256h160v160zm0 -192H288V64h160v160z"]},dhSquareFilled:kn,dhStickyNoteFilled:{prefix:"dh",iconName:"sticky-note-filled",icon:[512,512,[],"f000","M288 288h160V48l-16 -16h-384l-16 16v384l16 16H288V288zm32 28.8V448l128 -131.2h-128z"]},dhTable:An,dhTrashUndo:Pn,dhTriangleDownSquare:_n,dhTruck:Hn,dhUnlink:jn,dhUserIncognito:{prefix:"dh",iconName:"user-incognito",icon:[512,512,[],"f000","M348.8 278.4C371.2 256 384 227.2 384 192c0 -22.4 -6.4 -44.8 -19.2 -64H416V96H96v32h51.2c-12.8 19.2 -19.2 41.6 -19.2 64 0 35.2 12.8 64 35.2 86.4 -57.6 32 -99.2 92.8 -99.2 166.4 0 16 86.4 35.2 192 35.2s192 -19.2 192 -35.2c0 -73.6 -38.4 -134.4 -99.2 -166.4zM160 192c0 -25.6 9.6 -48 25.6 -64h144c12.8 16 22.4 38.4 22.4 64 0 28.8 -12.8 54.4 -35.2 73.6 -19.2 12.8 -38.4 22.4 -60.8 22.4s-41.6 -9.6 -57.6 -22.4C176 246.4 160 220.8 160 192zm96 252.8c-76.8 0 -131.2 -9.6 -153.6 -16 6.4 -57.6 41.6 -102.4 92.8 -121.6 19.2 6.4 38.4 12.8 60.8 12.8s41.6 -6.4 60.8 -16c51.2 19.2 86.4 67.2 92.8 121.6 -22.4 9.6 -76.8 19.2 -153.6 19.2zM169.6 76.8c16 3.2 160 3.2 176 0 19.2 -3.2 -19.2 -48 -25.6 -60.8C310.4 6.4 275.2 32 256 32 236.8 32 201.6 6.4 195.2 16c-9.6 12.8 -48 57.6 -25.6 60.8zm67.2 128h32c6.4 9.6 16 19.2 28.8 19.2 16 0 32 -12.8 32 -32s-12.8 -32 -32 -32c-9.6 0 -19.2 6.4 -25.6 16h-32c-6.4 -12.8 -16 -19.2 -28.8 -19.2 -16 0 -32 12.8 -32 32s12.8 32 32 32c12.8 0 22.4 -6.4 25.6 -16z"]},dhUser:{prefix:"dh",iconName:"user",icon:[512,512,[],"f000","M348.8 278.4C371.2 256 384 227.2 384 192c0 -70.4 -57.6 -128 -128 -128S128 121.6 128 192c0 35.2 12.8 64 35.2 86.4 -57.6 32 -99.2 92.8 -99.2 166.4 0 16 86.4 35.2 192 35.2s192 -19.2 192 -35.2c0 -73.6 -38.4 -134.4 -99.2 -166.4zM160 192c0 -51.2 41.6 -96 96 -96s96 41.6 96 96c0 28.8 -12.8 54.4 -35.2 73.6 -19.2 12.8 -38.4 22.4 -60.8 22.4s-41.6 -9.6 -57.6 -22.4C176 246.4 160 220.8 160 192zm96 252.8c-76.8 0 -131.2 -9.6 -153.6 -16 6.4 -57.6 41.6 -102.4 92.8 -121.6 19.2 6.4 38.4 12.8 60.8 12.8s41.6 -6.4 60.8 -16c51.2 19.2 86.4 67.2 92.8 121.6 -22.4 9.6 -76.8 19.2 -153.6 19.2z"]},dhWarningCircleFilled:Vn,dhWarningFilled:zn},Bn=n(717),Wn=n.n(Bn);function Gn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function qn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Kn=Object.freeze(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Gn(Object(n),!0).forEach((function(t){qn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Gn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({transitionMs:150,transitionMidMs:200,transitionLongMs:300,transitionSlowMs:1e3},Wn.a)),Yn=(n(798),e=>{var{className:t=""}=e;return a.a.createElement("div",{className:qe()("loading-spinner fa-layers",t)},a.a.createElement(Ke.a,{icon:st,className:"text-white-50"}),a.a.createElement(Ke.a,{icon:xt,className:"text-primary",spin:!0}))}),Xn=(n(792),e=>{var{isLoaded:t=!1,isLoading:n=!0,errorMessage:i=null}=e;return a.a.createElement(We.CSSTransition,{in:!!i||!t||n,timeout:Kn.transitionMs,classNames:t?"fade":"",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"fill-parent-absolute"},a.a.createElement("div",{className:qe()("iris-panel-message-overlay","fill-parent-absolute",{"iris-panel-scrim-background":t})},a.a.createElement("div",{className:"message-content"},a.a.createElement("div",{className:"message-icon"},n&&a.a.createElement(Yn,null),!n&&i&&a.a.createElement(Ke.a,{icon:en})),a.a.createElement("div",{className:"message-text"},i)))))}),Zn=n(170),$n=n.n(Zn),Qn=n(479),Jn=n.n(Qn),ei=n(393);window.$=ei,window.jQuery=ei,window.React=a.a,window.ReactDOM=r.a;n(778),n(779),n(780);var ti=n(67),ni=n.n(ti),ii=n(486),ai=n.n(ii),si=Object.freeze({tabHeight:parseInt(ai.a["tab-height"],10),dragBorderWidth:parseInt(ai.a["drag-border-width"],10)});function ri(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function oi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ri(Object(n),!0).forEach((function(t){li(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ri(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function li(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ci=p.module("LayoutUtils");class hi{static activateTab(e,t){var n=hi.getStackForRoot(e,t,!1);if(n){var i=hi.getContentItemInStack(n,t);n.setActiveContentItem(i)}else ci.error("Could not find stack for config",t)}static isActiveTab(e,t){var n=hi.getStackForRoot(e,t,!1);if(!n)return ci.error("Could not find stack for config",t),!1;var i=hi.getContentItemInStack(n,t);return n.getActiveContentItem()===i}static addStack(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=t?"column":"row";if(e.isRoot){e.contentItems&&0!==e.contentItems.length||e.addChild({type:n});var i=e.contentItems[0];if(!(t?i.isColumn:i.isRow)){e.removeChild(i,!0),e.addChild({type:n});var a=document.activeElement;e.contentItems[0].addChild(i),null===a||void 0===a||a.focus()}return this.addStack(e.contentItems[0],t)}if(e.contentItems.length<2)return e.addChild({type:"stack"}),e.contentItems[e.contentItems.length-1];var s=e.contentItems[e.contentItems.length-1];return(t?s.isRow:s.isColumn)||(e.addChild({type:t?"row":"column"}),e.removeChild(s,!0),e.contentItems[e.contentItems.length-1].addChild(s),s=e.contentItems[e.contentItems.length-1]),this.addStack(s,!t)}static getStackForConfig(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(n&&e.isStack&&0===e.contentItems.length)return e;if(!e.contentItems)return null;for(var i=0;i<e.contentItems.length;i+=1){var a=e.contentItems[i];if(a.isComponent&&a.config){for(var s=!0,r=Object.keys(t),o=0;o<r.length;o+=1){var l=r[o];if(t[l]!==a.config[l]){s=!1;break}}if(s)return e}var c=this.getStackForConfig(a,t,n);if(c)return c}return null}static getStackForRoot(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=this.getStackForConfig(e,t);return!s&&i&&(s=this.getStackForConfig(e,{component:t.component},a)),!s&&n&&(s=this.addStack(e)),s}static getStackForComponentTypes(e,t){for(var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=0;s<t.length;s+=1){var r=t[s],o=s===t.length-1,l=hi.getStackForRoot(e,{component:r},n&&o,i,a);if(l)return l}return null}static getContentItemInStack(e,t){for(var n=0;n<e.contentItems.length;n+=1){var i=e.contentItems[n];if(i.isComponent&&i.config){for(var a=!0,s=Object.keys(t),r=0;r<s.length;r+=1){var o=s[r];if(t[o]!==i.config[o]){a=!1;break}}if(a)return i}}return null}static dehydrateLayoutConfig(e,t){if(!e||!e.length)return[];for(var n=[],i=0;i<e.length;i+=1){var a=e[i],{component:s,content:r}=a;if(s){var o=t(s,a);o?n.push(o):ci.debug2('dehydrateLayoutConfig: skipping unmapped component "'.concat(s,'"'))}else if(r){var l=oi(oi({},a),{},{content:hi.dehydrateLayoutConfig(r,t)});n.push(l)}else n.push(a)}return n}static getTabPoint(e){var{tab:t}=e;if(null==t)throw new Error("Cannot get tab for panel container",e);var n=t.element[0].getBoundingClientRect();return[n.left+.5*n.width,n.bottom-8]}static dropLayoutMinorChange(e){for(var t=0;t<e.length;t+=1){var n=e[t],{component:i,content:a,activeItemIndex:s}=n;a?((s||0===s)&&delete n.activeItemIndex,hi.dropLayoutMinorChange(a)):"IrisGridPanel"===i&&n.props.panelState&&(delete n.id,n.props.panelState.irisGridState.sorts=[],n.props.panelState.irisGridState.quickFilters=[])}}static isEqual(e,t){if(arguments.length>2&&void 0!==arguments[2]&&arguments[2]){var n=hi.cloneLayout(e),i=hi.cloneLayout(t);return hi.dropLayoutMinorChange(n),hi.dropLayoutMinorChange(i),oe()(n,i)}return oe()(e,t)}static cloneLayout(e){return JSON.parse(JSON.stringify(e))}static hydrateLayoutConfig(e,t){if(!e||!e.length)return[];for(var n=[],i=0;i<e.length;i+=1){var a,s=e[i],{component:r,content:o,props:l,type:c}=s;if("react-component"===c)n.push(oi(oi({},s),{},{id:null!==(a=null===s||void 0===s?void 0:s.id)&&void 0!==a?a:ni()(),props:t(r,l)}));else if(o){var h=hi.hydrateLayoutConfig(o,t);null!=s.activeItemIndex&&s.activeItemIndex>=h.length&&(ci.warn("Fixing bad activeItemIndex!",s.activeItemIndex,s),s.activeItemIndex=0),n.push(oi(oi({},s),{},{content:h}))}else n.push(s)}return n}static openComponent(){var{root:e,config:t,replaceExisting:n=!0,replaceConfig:i=null,createNewStack:a=!1,focusElement:s=null,dragEvent:r=null}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},o=document.activeElement,l=oi({},t);if(l.id||(l.id=ni.a.generate()),r)e.layoutManager.createDragSourceFromEvent(l,r);else{var c=i||{id:l.id,component:l.component},h=a?hi.addStack(e):hi.getStackForRoot(e,c),d=hi.getContentItemInStack(h,c);if(s){var u=e=>{ci.debug("Component created, focusing element",s),h.off("componentCreated",u);var{element:t}=e.origin;requestAnimationFrame((()=>{hi.focusElement(t[0],s)}))};h.on("componentCreated",u)}if(n&&d){var m=h.contentItems.indexOf(d);h.addChild(l,m+1),h.removeChild(d),h.setActiveContentItem(h.contentItems[m])}else h.addChild(l);!s&&o&&o.focus()}}static openComponentInStack(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=document.activeElement,a={id:t.id,component:t.component},s=hi.getContentItemInStack(e,a);if(n&&s){var r=e.contentItems.indexOf(s);e.addChild(t,r+1),e.removeChild(s),e.setActiveContentItem(e.contentItems[r])}else e.addChild(t);i&&i.focus()}static closeComponent(e,t){var n=hi.getStackForRoot(e,t,!1,!1,!1);if(n){var i=hi.getContentItemInStack(n,t),a=document.activeElement;i.isComponent?i.container.close():n.removeChild(i),a&&document.contains(a)&&a.focus()}else ci.warn("Cannot find stack for component, ignoring close",t)}static renameComponent(e,t,n){var i=hi.getStackForRoot(e,t,!1);i?hi.getContentItemInStack(i,t).setTitle(n):ci.error("Could not find stack for config",t)}static cloneComponent(e,t){var n=hi.getStackForRoot(e,t,!1);if(!n)return ci.error("Could not find stack for config",t),null;var i=hi.getPanelComponentState(t),a={type:"react-component",component:t.component,props:oi(oi({},t.props),{},{panelState:i}),title:"".concat(t.title," Copy"),id:ni.a.generate()};return hi.openComponentInStack(n,a),a}static getPanelComponentState(e){var t,n,i,a;return null!==(t=null!==(n=null===(i=e.componentState)||void 0===i?void 0:i.panelState)&&void 0!==n?n:null===(a=e.props)||void 0===a?void 0:a.panelState)&&void 0!==t?t:null}static makeDefaultLayout(){return{dimensions:{headerHeight:si.tabHeight,borderWidth:si.dragBorderWidth,borderGrabWidth:10},settings:{showPopoutIcon:!1,showCloseIcon:!1,constrainDragToContainer:!1}}}static getRootFromContainer(e){return e.layoutManager.root}static getComponentConfigFromContainer(e){return e?e.tab&&e.tab.contentItem?e.tab.contentItem.config:e._config:null}static getTitleFromContainer(e){return e&&e.tab&&e.tab.contentItem?e.tab.contentItem.config.title:null}static getTitleFromTab(e){return e&&e.contentItem?e.contentItem.config.title:null}static getIdFromContainer(e){var t=hi.getComponentConfigFromContainer(e);return t?t.id:null}static getIdFromPanel(e){var{glContainer:t}=e.props;return hi.getIdFromContainer(t)}static getComponentNameFromPanel(e){var t,{glContainer:n}=e.props,i=hi.getComponentConfigFromContainer(n);return null!==(t=null===i||void 0===i?void 0:i.component)&&void 0!==t?t:null}static getComponentName(e){var t,n,i=null!==(t=null===(n=e.WrappedComponent)||void 0===n?void 0:n.displayName)&&void 0!==t?t:e.displayName;if(null==i)throw new Error("Component displayName not defined",e);return i}static focusElement(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:hi.DEFAULT_FOCUS_SELECTOR;if(null==e)return null;var n=e.querySelector(t);return null==n?null:(n.focus(),n)}static onInitialized(e){return new Promise((t=>{if(e.isInitialised)t();else{var n=()=>{e.off("initialised",n),t()};e.on("initialised",n)}}))}}li(hi,"DEFAULT_FOCUS_SELECTOR","input, select, textarea, button");var di=hi,ui=(n(789),a.a.forwardRef(((e,t)=>{var n=di.getComponentNameFromPanel({props:e});return a.a.createElement("div",{ref:t,className:"panel-placeholder"},'Component "',n,'" is not registered.')}))),mi=n(1),pi=n.n(mi);function gi(e){var t=Object(i.useRef)();return Object(i.useEffect)((()=>{t.current=e})),t.current}function vi(e){var t=Object(i.useRef)(null);return Object(i.useEffect)((()=>{e&&("function"===typeof e?e(t.current):e.current=t.current)})),t}var fi=Object.freeze({FOCUS:"PanelEvent.FOCUS",MOUNT:"PanelEvent.MOUNT",UNMOUNT:"PanelEvent.UNMOUNT",TITLE_CHANGED:"PanelEvent.TITLE_CHANGED",REOPEN:"PanelEvent.REOPEN",DELETE:"PanelEvent.DELETE",CLONED:"PanelEvent.CLONED",CLOSED:"PanelEvent.CLOSED",CLOSE:"PanelEvent.CLOSE"});function bi(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Ci(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bi(Object(n),!0).forEach((function(t){Si(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bi(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Si(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ei=p.module("PanelManager");class wi{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(e,t)=>t,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:(e,t)=>t,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:new Map,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:()=>{};Si(this,"layout",void 0),Si(this,"hydrateComponent",void 0),Si(this,"dehydrateComponent",void 0),Si(this,"onPanelsUpdated",void 0),Si(this,"closed",void 0),Si(this,"openedMap",void 0),this.handleFocus=this.handleFocus.bind(this),this.handleMount=this.handleMount.bind(this),this.handleUnmount=this.handleUnmount.bind(this),this.handleReopen=this.handleReopen.bind(this),this.handleDeleted=this.handleDeleted.bind(this),this.handleClosed=this.handleClosed.bind(this),this.handleControlClose=this.handleControlClose.bind(this),this.layout=e,this.hydrateComponent=t,this.dehydrateComponent=n,this.onPanelsUpdated=s,this.openedMap=new Map(i),this.closed=[...a],this.startListening()}startListening(){var{eventHub:e}=this.layout;e.on(fi.FOCUS,this.handleFocus),e.on(fi.MOUNT,this.handleMount),e.on(fi.UNMOUNT,this.handleUnmount),e.on(fi.REOPEN,this.handleReopen),e.on(fi.DELETE,this.handleDeleted),e.on(fi.CLOSED,this.handleClosed),e.on(fi.CLOSE,this.handleControlClose)}stopListening(){var{eventHub:e}=this.layout;e.off(fi.FOCUS,this.handleFocus),e.off(fi.MOUNT,this.handleMount),e.off(fi.UNMOUNT,this.handleUnmount),e.off(fi.REOPEN,this.handleReopen),e.off(fi.DELETE,this.handleDeleted),e.off(fi.CLOSED,this.handleClosed),e.off(fi.CLOSE,this.handleControlClose)}getClosedPanelConfigsOfType(e){return this.closed.filter((t=>t.component===e))}getOpenedPanels(){return Array.from(this.openedMap.values())}getOpenedPanelConfigs(){return this.getOpenedPanels().map((e=>{var{glContainer:t}=e.props;return di.getComponentConfigFromContainer(t)}))}getOpenedPanelConfigsOfType(e){return this.getOpenedPanelConfigs().filter((t=>null!=t&&t.component===e))}getOpenedPanelById(e){return this.openedMap.get(e)}getContainerByPanelId(e){var t,n=di.getStackForConfig(this.layout.root,{id:e});return null!==(t=n&&di.getContentItemInStack(n,{id:e}))&&void 0!==t?t:null}getLastUsedPanel(e){for(var t=this.getOpenedPanels(),n=t.length-1;n>=0;n-=1){var i=t[n];if(null==e||e(i))return i}}getLastUsedPanelOfType(e){return this.getLastUsedPanelOfTypes([e])}getLastUsedPanelOfTypes(e){return this.getLastUsedPanel((t=>e.some((e=>t instanceof e||function(e){return void 0!==(null===e||void 0===e?void 0:e.WrappedComponent)}(e)&&e.WrappedComponent&&t instanceof e.WrappedComponent))))}updatePanel(e){var t=di.getIdFromPanel(e);t?(Ei.debug2("Updating panel ID ".concat(t," in open panels map")),this.openedMap.delete(t),this.openedMap.set(t,e)):Ei.error("updatePanel Panel did not have an ID",e)}removePanel(e){var t=di.getIdFromPanel(e);t?this.openedMap.has(t)?this.openedMap.get(t)===e?(Ei.debug2("Removing panel ID ".concat(t," from open panels map")),this.openedMap.delete(t)):Ei.debug("Panel argument doesn't match the open panels map entry for ".concat(t,", removePanel ignored")):Ei.error("Missing panel ID ".concat(t," in open panels map")):Ei.error("removePanel Panel did not have an ID",e)}removeClosedPanelConfig(e){var t=this.closed.findIndex((t=>t===e||t.id&&e.id&&t.id===e.id));t>=0&&this.closed.splice(t,1)}handleFocus(e){Ei.debug2("Focus: ",e),this.updatePanel(e)}handleMount(e){Ei.debug2("Mount: ",e),this.updatePanel(e),this.sendUpdate()}handleUnmount(e){Ei.debug2("Unmount: ",e),this.removePanel(e),this.sendUpdate()}handleReopen(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;Ei.debug2("Reopen:",e,t),this.removeClosedPanelConfig(e);var{component:n}=e,{props:i}=e;i=this.hydrateComponent(n,i);var a=Ci(Ci({},e),{},{props:i}),{root:s}=this.layout;di.openComponent({root:s,config:a,replaceConfig:t})}handleDeleted(e){Ei.debug2("Deleted:",e),this.removeClosedPanelConfig(e),this.sendUpdate()}handleClosed(e,t){Ei.debug2("Closed: ",e),this.addClosedPanel(t),this.sendUpdate()}handleControlClose(e){var t={id:e},{root:n}=this.layout;di.closeComponent(n,t)}addClosedPanel(e){var t=di.getComponentConfigFromContainer(e);if(t){var n=this.dehydrateComponent(t.component,t);n&&this.closed.push(n)}}sendUpdate(){var{closed:e,openedMap:t}=this;this.onPanelsUpdated({closed:[...e],openedMap:new Map(t)})}}Si(wi,"MAX_CLOSED_PANEL_COUNT",100);var yi=wi,Ti=pi.a.shape({on:pi.a.func,off:pi.a.func,isHidden:pi.a.bool,tab:pi.a.shape({header:pi.a.shape({tabs:pi.a.arrayOf(pi.a.shape({contentItem:pi.a.shape({})}))})}),title:pi.a.string,setTitle:pi.a.func,close:pi.a.func}),Oi=pi.a.shape({on:pi.a.func,off:pi.a.func,emit:pi.a.func}),Mi=pi.a.shape({registerComponent:pi.a.func,root:pi.a.shape({addChild:pi.a.func}),on:pi.a.func,off:pi.a.func,eventHub:Oi}),Ni=Object.freeze({Container:Ti,EventHub:Oi,Layout:Mi}),Di=(e,t,n)=>Object(i.useEffect)((()=>(e.on(t,n),()=>{e.off(t,n)})),[e,t,n]),xi=(n(790),p.module("PanelErrorBoundary"));class Ri extends i.Component{constructor(e){super(e),this.state={error:null}}componentDidCatch(e){this.setState({error:e})}componentWillUnmount(){var{glContainer:e,glEventHub:t}=this.props,n=di.getIdFromContainer(e);xi.debug("componentWillUnmount",n),t.emit(fi.CLOSED,n,e)}render(){var{children:e}=this.props,{error:t}=this.state;return null!=t?a.a.createElement("div",{className:"panel-error-boundary"},a.a.createElement(Xn,{errorMessage:"".concat(t),isLoading:!1,isLoaded:!1})):e}}Ri.propTypes={children:pi.a.node.isRequired,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired};var Ii=Ri;function Li(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Fi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Li(Object(n),!0).forEach((function(t){ki(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Li(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ki(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ai(e){var{props:t,componentState:n}=e,{metadata:i}=t,{panelState:a=null}=t;n&&({panelState:a}=n);var s={};return i&&(s.metadata=i),a&&(s.panelState=a),Fi(Fi({},e),{},{componentState:null,props:s,type:"react-component"})}function Pi(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Fi(Fi({metadata:{}},e),{},{localDashboardId:t})}var _i={dehydrate:Ai,hydrate:Pi},Hi="SET_DASHBOARD_DATA",ji=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return function(){var i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;if(a.type===e){var{id:s,payload:r}=a;return n&&oe()({payload:r},{payload:i[s]})?i:ce(ce({},i),{},{[s]:r})}return i}}(Hi,{},!1),Vi={dashboardData:ji},zi=new Map,Ui=Object.freeze({}),Bi=Object.freeze([]),Wi=(e,t)=>{var n;return null!==(n=(e=>e.dashboardData)(e)[t])&&void 0!==n?n:Ui},Gi=(e,t)=>{var n;return null!==(n=Wi(e,t).closed)&&void 0!==n?n:Bi},qi=(e,t)=>{var n;return null!==(n=Wi(e,t).openedMap)&&void 0!==n?n:zi};function Ki(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Yi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ki(Object(n),!0).forEach((function(t){Xi(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ki(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Xi(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Zi=(e,t)=>({type:Hi,id:e,payload:t}),$i=(e,t)=>(n,i)=>n(Zi(e,Yi(Yi({},Wi(i(),e)),t)));function Qi(){return Qi=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Qi.apply(this,arguments)}Object.entries(Vi).map((e=>{var[t,n]=e;return Ee.register(t,n)}));var Ji=p.module("DashboardLayout"),ea=Object.freeze({}),ta=[],na=()=>{},ia=e=>e,aa=e=>{var t,n,{id:s,children:r,emptyDashboard:l=a.a.createElement("div",null,"Dashboard is empty."),layout:c,layoutConfig:h=ta,onLayoutChange:d=na}=e,u=Object(o.c)(),m=null!==(t=Object(o.d)((e=>Wi(e,s))))&&void 0!==t?t:ea,[p,g]=Object(i.useState)(!1),[v,f]=Object(i.useState)(!1),[b,C]=Object(i.useState)(),[S]=Object(i.useState)(null!==(n=null===m||void 0===m?void 0:m.closed)&&void 0!==n?n:[]),E=Object(i.useMemo)((()=>new Map),[]),w=Object(i.useMemo)((()=>new Map),[]),y=Object(o.e)(),T=Object(i.useCallback)((function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Pi,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Ai;function s(e,n){var i=t,{glContainer:s,glEventHub:r}=e;return a.a.createElement(o.a,{store:y},a.a.createElement(Ii,{glContainer:s,glEventHub:r},a.a.createElement(i,Qi({},e,{ref:n}))))}Ji.debug2("registerComponent",e,t,n,i);var r=a.a.forwardRef(s),l=c.registerComponent(e,r);return E.set(e,n),w.set(e,i),l}),[E,w,c,y]),O=Object(i.useCallback)(((e,t)=>{var n;return(null!==(n=E.get(e))&&void 0!==n?n:ia)(t,s)}),[E,s]),M=Object(i.useCallback)(((e,t)=>{var n;return(null!==(n=w.get(e))&&void 0!==n?n:ia)(t,s)}),[w,s]),N=Object(i.useMemo)((()=>new yi(c,O,M,new Map,S,(e=>{var{closed:t,openedMap:n}=e;u($i(s,{closed:t,openedMap:n}))}))),[M,u,O,s,S,c]),D=Object(i.useCallback)((()=>{if(!v){var e=c.toConfig().content,t=di.dehydrateLayoutConfig(e,M),n=null==b||!di.isEqual(b,t);Ji.debug("handleLayoutStateChanged",n,e,t),n&&(g(0===c.root.contentItems.length),C(t),d(t))}}),[M,v,b,c,d]),x=Object(i.useCallback)((()=>{f(!0)}),[]),R=Object(i.useCallback)((()=>{f(!1)}),[]),I=Object(i.useCallback)((e=>{if(Ji.debug2("handleComponentCreated",e),e&&e.config&&e.config.component&&e.element){var t=e.config.component.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),n="".concat(t,"-component");e.element.addClass(n)}}),[]);Di(c,"stateChanged",D),Di(c,"itemPickedUp",x),Di(c,"itemDropped",R),Di(c,"componentCreated",I),Di(c.eventHub,fi.TITLE_CHANGED,D);var L=gi(h);return Object(i.useEffect)((()=>{if(L!==h&&h!==b){Ji.debug("Setting new layout content...");for(var e=di.hydrateLayoutConfig(h,O);c.root.contentItems.length>0;)c.root.contentItems[0].remove();for(var t=0;t<e.length;t+=1)c.root.addChild(e[t]);g(0===c.root.contentItems.length)}}),[O,c,h,b,N,L]),a.a.createElement(a.a.Fragment,null,p&&l,a.a.Children.map(r,(e=>e?a.a.cloneElement(e,{id:s,layout:c,panelManager:N,registerComponent:T}):null)))};aa.propTypes={id:pi.a.string.isRequired,children:pi.a.node,data:pi.a.shape({}),emptyDashboard:pi.a.node,layout:Ni.Layout.isRequired,layoutConfig:pi.a.arrayOf(pi.a.shape({})),onLayoutChange:pi.a.func};var sa=aa;n(799);function ra(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function oa(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var la=()=>{},ca=Object.freeze({}),ha=e=>{var{id:t="default",children:n,emptyDashboard:s,layoutConfig:r,layoutSettings:o=ca,onLayoutConfigChange:l=la,onGoldenLayoutChange:c=la,fallbackComponent:h=ui}=e,d=Object(i.useRef)(null),[u,m]=Object(i.useState)(!1),[p,g]=Object(i.useState)();Object(i.useEffect)((()=>{if(d.current){var e=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ra(Object(n),!0).forEach((function(t){oa(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ra(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},di.makeDefaultLayout());Object.assign(e.settings,o),e.content=[];var t=new Jn.a(e,d.current),n=()=>{t.off("initialised",n),m(!0)};return t.on("initialised",n),h&&t.setFallbackComponent(h),t.init(),g(t),c(t),()=>{t.destroy()}}g(void 0)}),[o,h,c,m,g]);var v=Object(i.useMemo)((()=>$n()((()=>{null!==p&&void 0!==p&&p.isInitialised&&(null===p||void 0===p||p.updateSize())}),100)),[p]);return Object(i.useEffect)((()=>(window.addEventListener("resize",v),()=>{window.removeEventListener("resize",v)})),[v]),a.a.createElement("div",{className:"dashboard-container w-100 h-100"},a.a.createElement("div",{className:"w-100 h-100",ref:d}),u&&p&&a.a.createElement(sa,{emptyDashboard:s,id:t,layout:p,layoutConfig:r,onLayoutChange:l},n))},da="default",ua=n(36),ma=n(70),pa=n.n(ma),{dh:ga}=globalThis,va=ga,fa=pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired,description:pi.a.string,constituentType:pi.a.string}),ba=pi.a.shape({not:pi.a.func.isRequired,and:pi.a.func.isRequired,or:pi.a.func.isRequired}),Ca=pi.a.shape({asc:pi.a.func.isRequired,desc:pi.a.func.isRequired,abs:pi.a.func.isRequired,column:fa.isRequired,direction:pi.a.string.isRequired,isAbs:pi.a.bool.isRequired}),Sa=pi.a.shape({columns:pi.a.arrayOf(fa).isRequired,customColumns:pi.a.arrayOf(pi.a.string).isRequired,filter:pi.a.arrayOf(ba),addEventListener:pi.a.func.isRequired,removeEventListener:pi.a.func.isRequired,size:pi.a.number.isRequired,sort:pi.a.arrayOf(pi.a.any),copy:pi.a.func.isRequired,applyFilter:pi.a.func.isRequired,applySort:pi.a.func.isRequired,applyCustomColumns:pi.a.func.isRequired,description:pi.a.string}),Ea=pi.a.shape({columns:pi.a.arrayOf(fa),filter:pi.a.arrayOf(pi.a.any),isExpanded:pi.a.func.isRequired,saveExpandedState:pi.a.func.isRequired,addEventListener:pi.a.func.isRequired,removeEventListener:pi.a.func.isRequired,size:pi.a.number.isRequired,sort:pi.a.arrayOf(pi.a.any),applyFilter:pi.a.func.isRequired,applySort:pi.a.func.isRequired}),wa=pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired}),ya=pi.a.shape({created:pi.a.arrayOf(wa).isRequired,updated:pi.a.arrayOf(wa).isRequired,removed:pi.a.arrayOf(wa).isRequired}),Ta=pi.a.shape({groupingColumns:pi.a.arrayOf(pi.a.string),aggregations:pi.a.shape({}),includeConstituents:pi.a.bool,includeOriginalColumns:pi.a.bool,includeDescriptions:pi.a.bool}),Oa=pi.a.shape({addEventListener:pi.a.func.isRequired,removeEventListener:pi.a.func.isRequired,onLogMessage:pi.a.func,getTable:pi.a.func.isRequired,runCode:pi.a.func.isRequired}),Ma=Object.freeze({Column:fa,FilterCondition:ba,IdeSession:Oa,RollupConfig:Ta,Sort:Ca,Table:Sa,TreeTable:Ea,VariableChanges:ya,VariableDefinition:wa});class Na extends Error{constructor(){super(...arguments),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isCanceled",!0)}}var Da=Na;function xa(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ra="column_",Ia=new Set(["in","not","i","ii","k"]),La=new Set(["abstract","continue","for","new","switch","assert","default","if","package","synchronized","boolean","do","goto","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","null","true","false"]),Fa=/[^a-zA-Z0-9_$+@-]/g,ka=/[^A-Za-z0-9_$]/g;class Aa{}xa(Aa,"legalize",((e,t,n,i,a)=>{var s=e.trim().replace(/[- ]/g,"_");return i&&(Ia.has(s)||La.has(s))&&(s=t+s),(s=s.replace(n,""))||(s=t+a),Number.isNaN(Number(s.charAt(0)))||(s=t+s),s})),xa(Aa,"legalizeTableName",(e=>Aa.legalize(e,"table_",Fa,!1,0))),xa(Aa,"legalizeColumnNames",(e=>{var t=[];return e.forEach(((e,n)=>{var i=Aa.legalizeColumnName(e,n);t.includes(i)&&(i=Ra+n),t.push(i)})),t})),xa(Aa,"legalizeColumnName",(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return Aa.legalize(e,Ra,ka,!0,t)})),xa(Aa,"isValidTableName",(e=>Aa.legalizeTableName(e)===e)),xa(Aa,"isValidColumnName",(e=>Aa.legalizeColumnName(e)===e));var Pa=Aa;var _a={getClosestByClassName:function(e,t){return e?e.closest(".".concat(t)):null}};class Ha extends Error{constructor(){super(...arguments),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isTimeout",!0)}}var ja=Ha;class Va{static makeCancelable(e,t){var n,i=!1,a=new Promise(((a,s)=>{Promise.resolve(e).then((e=>{i?(t&&t(e),s(new Da)):(n=e,a(e))}),(e=>s(i?new Da:e)))}));return a.cancel=()=>{i=!0,null!=n&&t&&t(n)},a}static isCanceled(e){return e instanceof Da}static isTimedOut(e){return e instanceof ja}}function za(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ua=class{constructor(){za(this,"pending",[]),za(this,"resolved",[])}add(e,t){var n=Va.makeCancelable(e,t);return this.pending.push(n),n.then((()=>{this.resolve(n)}),(()=>{this.resolve(n)})),n}remove(e){for(var t=0;t<this.pending.length;t+=1)if(this.pending[t]===e)return void this.pending.splice(t,1)}resolve(e){this.remove(e),this.resolved.push(e)}cancel(){for(var e=[...this.pending,...this.resolved],t=0;t<e.length;t+=1)e[t].cancel();this.pending=[],this.resolved=[]}};class Ba{static isValidRange(e){return null!=e&&2===e.length&&Number.isInteger(e[0])&&Number.isInteger(e[1])&&e[0]<=e[1]}static validateRange(e){if(!Ba.isValidRange(e))throw new Error("Invalid range! ".concat(e))}static isSelected(e,t){for(var n=0;n<e.length;n+=1){var i=e[n],a=i[0],s=i[1];if(a<=t&&t<=s)return!0}return!1}static selectRange(e,t){for(var[n,i]=t,a=[...e],s=a.length-1;s>=0;s-=1){var r=a[s],o=r[0],l=r[1];if(o<=n&&i<=l)return a;n<=l&&o<=i&&(n=Math.min(n,o),i=Math.max(i,l),a.splice(s,1))}return a.push([n,i]),a}static deselectRange(e,t){for(var[n,i]=t,a=[...e],s=a.length-1;s>=0;s-=1){var r=a[s],o=r[0],l=r[1];if(i<o||l<n);else{if(o<n&&i<l){a[s]=[o,n-1],a.splice(s+1,0,[i+1,l]);break}n<=o&&l<=i?a.splice(s,1):a[s]=o<n?[o,n-1]:[i+1,l]}}return a}static count(e){return e.reduce(((e,t)=>e+(t[1]-t[0]+1)),0)}}var Wa=Ba;var Ga=class{static join(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"and";if(null==e||0===e.length)return"";if(1===e.length)return e[0];if(2===e.length)return"".concat(e[0]," ").concat(t," ").concat(e[1]);var n=e.slice(0,e.length-1).join(", "),i=e[e.length-1];return"".concat(n,", ").concat(t," ").concat(i)}static toLower(e){if(null==e){if(!(arguments.length>1&&void 0!==arguments[1])||arguments[1])return"";throw new Error("Null string passed in to TextUtils.toLower")}return e.toLowerCase()}static sort(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return e<t?n?-1:1:e>t?n?1:-1:0}};function qa(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Ka{static formatElapsedTime(e){if("number"!==typeof e||!Number.isInteger(e))throw new Error("".concat(e," is not a number that can be expressed as a formatted time"));var t=Math.floor(e/3600),n=Math.floor(e%3600/60),i=e%60;return"".concat(t>0?"".concat(t,"h "):"")+"".concat(n>0||t>0?"".concat(n,"m "):"")+"".concat(e>=60?"".concat(i,"s").padStart(3,"0"):"".concat(i,"s"))}static formatTime(e){if("number"!==typeof e||!Number.isInteger(e)||e<0)throw new Error("".concat(e," is not a number that can be expressed as a formatted time"));var t=String(Math.floor(e/3600)).padStart(2,"0"),n=e%3600,i=String(Math.floor(n/60)).padStart(2,"0"),a=n%60,s=String(Math.ceil(a)).padStart(2,"0");return"".concat(t,":").concat(i,":").concat(s)}static isTimeString(e){return new RegExp(Ka.TIME_PATTERN).test(e)}static parseTime(e){if(!e||"string"!==typeof e)throw new Error("".concat(e," is not a valid string"));var t=e.split(":");if(3!==t.length)throw new Error("".concat(e," is not a time string that can be parsed"));return 60*Number(t[0])*60+60*Number(t[1])+Number(t[2])}}qa(Ka,"TIME_PATTERN","([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]"),qa(Ka,"TIME_ZONES",Object.freeze([{label:"Tokyo UTC+9 No DST",value:"Asia/Tokyo"},{label:"Seoul UTC+9 No DST",value:"Asia/Seoul"},{label:"Hong Kong UTC+8 No DST",value:"Asia/Hong_Kong"},{label:"Singapore UTC+8 No DST",value:"Asia/Singapore"},{label:"Kolkata UTC+5:30 No DST",value:"Asia/Kolkata"},{label:"Berlin UTC+1",value:"Europe/Berlin"},{label:"UTC UTC\xb10 No DST",value:"UTC"},{label:"London UTC\xb10",value:"Europe/London"},{label:"Sao Paulo UTC-2",value:"America/Sao_Paulo"},{label:"Newfoundland UTC-3:30",value:"America/St_Johns"},{label:"Halifax UTC-4",value:"America/Halifax"},{label:"New York UTC\u22125",value:"America/New_York"},{label:"Chicago UTC-6",value:"America/Chicago"},{label:"Denver UTC-7",value:"America/Denver"},{label:"Los Angeles UTC-8",value:"America/Los_Angeles"},{label:"Anchorage UTC-9",value:"America/Anchorage"},{label:"Honolulu UTC-10 No DST",value:"Pacific/Honolulu"},{label:"Zurich UTC+1",value:"Europe/Zurich"},{label:"Amsterdam UTC+1",value:"Europe/Amsterdam"},{label:"Taipei UTC+8 No DST",value:"Asia/Taipei"},{label:"Sydney UTC+10",value:"Australia/Sydney"}]));var Ya=Ka;Error;class Xa extends Error{constructor(){super(...arguments),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isInvalid",!0)}}var Za=Xa;n(517);function $a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Qa{static makeDateWrapper(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,r=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:0,l="".concat(t).padStart(4,"0"),c="".concat(n+1).padStart(2,"0"),h="".concat(i).padStart(2,"0"),d="".concat(a).padStart(2,"0"),u="".concat(s).padStart(2,"0"),m="".concat(r).padStart(2,"0"),p="".concat(o).padStart(9,"0"),g="".concat(l,"-").concat(c,"-").concat(h," ").concat(d,":").concat(u,":").concat(m,".").concat(p);return va.i18n.DateTimeFormat.parse(Qa.FULL_DATE_FORMAT,g,va.i18n.TimeZone.getTimeZone(e))}static getNextNanos(e){var t=parseInt(e,10),n="0".repeat(9-e.length),i="".concat(t+1).concat(n);return parseInt(i,10)}static getNextDate(e,t,n){var{year:i,month:a,date:s,hours:r,minutes:o,seconds:l,nanos:c}=t;if(null!=e.nanos){if(9===e.nanos.length)return null;(c=Qa.getNextNanos(e.nanos))>999999999&&(l+=1,c=0)}else null!=e.seconds?l+=1:null!=e.minutes?o+=1:null!=e.hours?r+=1:null!=e.date?s+=1:null!=e.month?a+=1:i+=1;var h=new Date(i,a,s,r,o,l);return Qa.makeDateWrapper(n,h.getFullYear(),h.getMonth(),h.getDate(),h.getHours(),h.getMinutes(),h.getSeconds(),c)}static parseMonth(e){var t=parseInt(e,10);if(!Number.isNaN(t))return t>=1&&t<=12?t-1:NaN;var n=e.trim().toLowerCase();if(n.length>=3)for(var i=0;i<Qa.months.length;i+=1)if(Qa.months[i].startsWith(n))return i;return NaN}static parseDateValues(e,t,n,i,a,s,r){var o=parseInt(e,10),l=null!=t?this.parseMonth(t):0,c=null!=n?parseInt(n,10):1,h=null!=i?parseInt(i,10):0,d=null!=a?parseInt(a,10):0,u=null!=s?parseInt(s,10):0,m=null!=r?parseInt(r.padEnd(9,"0"),10):0;return Number.isNaN(o)||Number.isNaN(l)||Number.isNaN(c)||Number.isNaN(h)||Number.isNaN(d)||Number.isNaN(u)||Number.isNaN(m)?null:{year:o,month:l,date:c,hours:h,minutes:d,seconds:u,nanos:m}}static parseDateTimeString(e){var t=/\s*(\d{4})([-./]([\da-z]+))?([-./](\d{1,2}))?([tT\s](\d{2})([:](\d{2}))?([:](\d{2}))?([.](\d{1,9}))?)?(.*)/.exec(e);if(null==t)throw new Error("Unexpected date string: ".concat(e));var[,n,,i,,a,,s,,r,,o,,l,c]=t;if(null!=c&&c.length>0)throw new Error("Unexpected characters after date string '".concat(e,"': ").concat(c));return{year:n,month:i,date:a,hours:s,minutes:r,seconds:o,nanos:l}}static parseDateRange(e,t){var n=e.trim().toLowerCase();if(0===n.length)throw new Error("Cannot parse date range from empty string");if("null"===n)return[null,null];if("today"===n){var i=new Date(Date.now());return[Qa.makeDateWrapper(t,i.getFullYear(),i.getMonth(),i.getDate()),Qa.makeDateWrapper(t,i.getFullYear(),i.getMonth(),i.getDate()+1)]}if("yesterday"===n){var a=new Date(Date.now());return[Qa.makeDateWrapper(t,a.getFullYear(),a.getMonth(),a.getDate()-1),Qa.makeDateWrapper(t,a.getFullYear(),a.getMonth(),a.getDate())]}if("now"===n){var s=new Date(Date.now());return[va.DateWrapper.ofJsDate(s),null]}var r=Qa.parseDateTimeString(n);if(null==r.year&&null==r.month&&null==r.date)throw new Error("Unable to extract year, month, or day ".concat(n));var o=Qa.parseDateValues(r.year,r.month,r.date,r.hours,r.minutes,r.seconds,r.nanos);return[Qa.makeDateWrapper(t,o.year,o.month,o.date,o.hours,o.minutes,o.seconds,o.nanos),Qa.getNextDate(r,o,t)]}static getJsDate(e){return e.asDate?e.asDate():new Date(e)}}$a(Qa,"FULL_DATE_FORMAT","yyyy-MM-dd HH:mm:ss.SSSSSSSSS"),$a(Qa,"months",["january","february","march","april","may","june","july","august","september","october","november","december"]);var Ja=Qa;function es(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class ts{}es(ts,"eq","eq"),es(ts,"eqIgnoreCase","eqIgnoreCase"),es(ts,"notEq","notEq"),es(ts,"notEqIgnoreCase","notEqIgnoreCase"),es(ts,"greaterThan","greaterThan"),es(ts,"greaterThanOrEqualTo","greaterThanOrEqualTo"),es(ts,"lessThan","lessThan"),es(ts,"lessThanOrEqualTo","lessThanOrEqualTo"),es(ts,"in","in"),es(ts,"inIgnoreCase","inIgnoreCase"),es(ts,"notIn","notIn"),es(ts,"notInIgnoreCase","notInIgnoreCase"),es(ts,"isTrue","isTrue"),es(ts,"isFalse","isFalse"),es(ts,"isNull","isNull"),es(ts,"invoke","invoke"),es(ts,"contains","contains"),es(ts,"notContains","notContains"),es(ts,"startsWith","startsWith"),es(ts,"endsWith","endsWith"),es(ts,"containsAny","containsAny");var ns=ts;function is(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class as{}is(as,"not","not"),is(as,"and","and"),is(as,"or","or");var ss=as;function rs(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var os=p.module("TableUtils");class ls{static getSortIndex(e,t){for(var n=0;n<e.length;n+=1){var i;if((null===(i=e[n].column)||void 0===i?void 0:i.index)===t)return n}return null}static getSortForColumn(e,t){var n=ls.getSortIndex(e,t);return null!=n?e[n]:null}static getFilterText(e){return e?e.toString():null}static getFilterTypes(e){return ls.isBooleanType(e)?[ns.isTrue,ns.isFalse,ns.isNull]:ls.isCharType(e)?[ns.eq,ns.notEq]:ls.isNumberType(e)||ls.isDateType(e)?[ns.eq,ns.notEq,ns.greaterThan,ns.greaterThanOrEqualTo,ns.lessThan,ns.lessThanOrEqualTo]:ls.isTextType(e)?[ns.eq,ns.eqIgnoreCase,ns.notEq,ns.notEqIgnoreCase,ns.contains,ns.notContains,ns.startsWith,ns.endsWith]:[]}static getNextSort(e,t){if(!e||!e.columns||t<0||t>=e.columns.length)return null;var n=ls.getSortForColumn(e.sort,t);return null===n?e.columns[t].sort().asc():n.direction===ls.sortDirection.ascending?n.desc():null}static makeColumnSort(e,t,n,i){if(!e||!e.columns||t<0||t>=e.columns.length)return null;if(n===ls.sortDirection.none)return null;var a=e.columns[t].sort();switch(n){case ls.sortDirection.ascending:a=a.asc();break;case ls.sortDirection.descending:a=a.desc()}return i&&(a=a.abs()),a}static toggleSortForColumn(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!t||n<0||n>=t.columns.length)return[];var a=ls.getNextSort(t,n);return ls.setSortForColumn(e,n,a,i)}static sortColumn(e,t,n,i,a){if(!e||t<0||t>=e.columns.length)return[];var s=ls.makeColumnSort(e,t,n,i);return ls.setSortForColumn(e.sort,t,s,a)}static setSortForColumn(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a=ls.getSortIndex(e,t),s=[];return i&&(s=s.concat(e.filter((e=>{var{direction:t}=e;return t!==ls.sortDirection.reverse}))),null!==a&&s.splice(a,1)),null!==n&&s.push(n),s}static getNormalizedType(e){switch(e){case"boolean":case"java.lang.Boolean":case ls.dataType.BOOLEAN:return ls.dataType.BOOLEAN;case"char":case"java.lang.Character":case ls.dataType.CHAR:return ls.dataType.CHAR;case"java.lang.String":case ls.dataType.STRING:return ls.dataType.STRING;case"io.deephaven.db.tables.utils.DBDateTime":case"io.deephaven.time.DateTime":case"com.illumon.iris.db.tables.utils.DBDateTime":case ls.dataType.DATETIME:return ls.dataType.DATETIME;case"double":case"java.lang.Double":case"float":case"java.lang.Float":case ls.dataType.DECIMAL:return ls.dataType.DECIMAL;case"int":case"java.lang.Integer":case"long":case"java.lang.Long":case"short":case"java.lang.Short":case"byte":case"java.lang.Byte":case ls.dataType.INT:return ls.dataType.INT;default:return null}}static isLongType(e){switch(e){case"long":case"java.lang.Long":return!0;default:return!1}}static isDateType(e){switch(e){case"io.deephaven.db.tables.utils.DBDateTime":case"io.deephaven.time.DateTime":case"com.illumon.iris.db.tables.utils.DBDateTime":return!0;default:return!1}}static isNumberType(e){return ls.isIntegerType(e)||ls.isDecimalType(e)}static isIntegerType(e){switch(e){case"int":case"java.lang.Integer":case"java.math.BigInteger":case"long":case"java.lang.Long":case"short":case"java.lang.Short":case"byte":case"java.lang.Byte":return!0;default:return!1}}static isDecimalType(e){switch(e){case"double":case"java.lang.Double":case"java.math.BigDecimal":case"float":case"java.lang.Float":return!0;default:return!1}}static isBooleanType(e){switch(e){case"boolean":case"java.lang.Boolean":return!0;default:return!1}}static isCharType(e){switch(e){case"char":case"java.lang.Character":return!0;default:return!1}}static isTextType(e){switch(e){case"char":case"java.lang.Character":case"java.lang.String":return!0;default:return!1}}static getBaseType(e){return e.split("[]")[0]}static isCompatibleType(e,t){return ls.getNormalizedType(e)===ls.getNormalizedType(t)}static makeQuickFilter(e,t,n){for(var i=t.split("||"),a=null,s=0;s<i.length;s+=1){for(var r=i[s].split("&&"),o=null,l=0;l<r.length;l+=1){var c=r[l].trim();if(c.length>0){var h=ls.makeQuickFilterFromComponent(e,c,n);if(!h)throw new Error("Unable to parse quick filter from text ".concat(t));o=o?o.and(h):h}}a=a?a.or(o):o}return a}static makeQuickFilterFromComponent(e,t,n){var{type:i}=e;return ls.isNumberType(i)?this.makeQuickNumberFilter(e,t):ls.isBooleanType(i)?this.makeQuickBooleanFilter(e,t):ls.isDateType(i)?this.makeQuickDateFilter(e,t,n):ls.isCharType(i)?this.makeQuickCharFilter(e,t):this.makeQuickTextFilter(e,t)}static makeQuickNumberFilter(e,t){if(null==t)return null;var n=e.filter(),i=null,a=/\s*(>=|<=|=>|=<|>|<|!=|=|!)?(\s*-\s*)?(\s*\d*(?:,\d{3})*(?:\.\d*)?\s*)?(null|nan|infinity|inf|\u221E)?(.*)/i.exec(t),s=null,r=null,o=null,l=null,c=null;if(a.length>3&&([,s,r,o,l,c]=a),null!=c&&c.trim().length>0)return null;if(null==s&&(s="="),null==o&&null==l)return null;if(null!=l){if("="!==s&&"!"!==s&&"!="!==s)return null;switch(l=l.trim().toLowerCase()){case"null":i=n.isNull();break;case"nan":i=va.FilterCondition.invoke("isNaN",n);break;case"infinity":case"inf":case"\u221e":i=null!=r?va.FilterCondition.invoke("isInf",n).and(n.lessThan(va.FilterValue.ofNumber(0))):va.FilterCondition.invoke("isInf",n).and(n.greaterThan(va.FilterValue.ofNumber(0)))}return"!"!==s&&"!="!==s||(i=i.not()),i}if(o=ls.removeCommas(o),ls.isLongType(e.type))try{o=va.FilterValue.ofNumber(va.LongWrapper.ofString("".concat(null!=r?"-":"").concat(o)))}catch(h){return os.warn("Unable to create long filter",h),null}else{if(null==(o=parseFloat(o))||Number.isNaN(o))return null;o=va.FilterValue.ofNumber(null!=r?0-o:o)}return i=e.filter(),ls.makeRangeFilterWithOperation(i,s,o)}static makeQuickTextFilter(e,t){if(null==t)return null;var n="".concat(t).trim(),i=/^(!~|!=|~|=|!)?(.*)/.exec(n),a=null,s=null;if(i.length>2&&([,a,s]=i,null!=s&&(s=s.trim())),null==s||0===s.length)return null;null==a&&(a="=");var r=e.filter();if("null"===s.toLowerCase())switch(a){case"=":return r.isNull();case"!=":case"!":return r.isNull().not();default:return null}var o=null,l=null;switch(s.startsWith("*")?(o="*",s=s.substring(1)):s.endsWith("*")&&!s.endsWith("\\*")&&(l="*",s=s.substring(0,s.length-1)),s=s.replace("\\",""),a){case"~":return r.isNull().not().and(r.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(s,"\\E.*"))));case"!~":return r.isNull().or(r.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(s,"\\E.*"))).not());case"!=":return"*"===o?r.isNull().or(r.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(s,"\\E$"))).not()):"*"===l?r.isNull().or(r.invoke("matches",va.FilterValue.ofString("(?s)(?i)^\\Q".concat(s,"\\E.*"))).not()):r.notEqIgnoreCase(va.FilterValue.ofString(s.toLowerCase()));case"=":return"*"===o?r.isNull().not().and(r.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(s,"\\E$")))):"*"===l?r.isNull().not().and(r.invoke("matches",va.FilterValue.ofString("(?s)(?i)^\\Q".concat(s,"\\E.*")))):r.eqIgnoreCase(va.FilterValue.ofString(s.toLowerCase()))}return null}static makeQuickBooleanFilter(e,t){if(null==t)return null;var n=/^(!=|=|!)?(.*)/.exec("".concat(t).trim()),[,i,a]=n,s="!"===i||"!="===i,r=a.trim().toLowerCase(),o=e.filter();try{var l=ls.makeBooleanValue(r);return o=l?o.isTrue():null===l?o.isNull():o.isFalse(),s?o.not():o}catch(c){return null}}static makeQuickDateFilter(e,t,n){var i=t.trim(),a=/\s*(>=|<=|=>|=<|>|<|!=|!|=)?(.*)/.exec(i);if(null==a||a.length<=2)throw new Error("Unable to parse date filter: ".concat(t));var s=null,r=null;[,s,r]=a;var o=ns.eq;switch(s){case"<":o=ns.lessThan;break;case"<=":case"=<":o=ns.lessThanOrEqualTo;break;case">":o=ns.greaterThan;break;case">=":case"=>":o=ns.greaterThanOrEqualTo;break;case"!=":case"!":o=ns.notEq;break;default:o=ns.eq}return ls.makeQuickDateFilterWithOperation(e,r,o,n)}static makeQuickDateFilterWithOperation(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ns.eq,i=arguments.length>3?arguments[3]:void 0;if(null==e)throw new Error("Column is null");var[a,s]=Ja.parseDateRange(t,i),r=null!=a?va.FilterValue.ofNumber(a):null,o=null!=s?va.FilterValue.ofNumber(s):null,l=e.filter();if(null==r&&null==o)return n===ns.notEq?l.isNull().not():l.isNull();switch(n){case ns.eq:if(null!=o){var c=l.greaterThanOrEqualTo(r),h=l.lessThan(o);return c.and(h)}return l.eq(r);case ns.lessThan:return l.lessThan(r);case ns.lessThanOrEqualTo:return null!=o?l.lessThan(o):l.lessThanOrEqualTo(r);case ns.greaterThan:return null!=o?l.greaterThanOrEqualTo(o):l.greaterThan(r);case ns.greaterThanOrEqualTo:return l.greaterThanOrEqualTo(r);case ns.notEq:if(null!=o){var d=l.lessThan(r),u=l.greaterThanOrEqualTo(o);return d.or(u)}return l.notEq(r);default:throw new Error("Invalid operator: ".concat(n))}}static makeQuickCharFilter(e,t){if(null==t)return null;var n="".concat(t).trim(),i=/^(!=|=|!)?(null|.)?(.*)/.exec(n),a=null,s=null,r=null;if(i.length>3&&([,a,s,r]=i),null!=r&&r.trim().length>0)return null;if(null==s||0===s.length)return null;null==a&&(a="=");var o=e.filter();if("null"===s.toLowerCase())switch(a){case"=":return o.isNull();case"!=":case"!":return o.isNull().not();default:return null}return ls.makeRangeFilterWithOperation(o,a,va.FilterValue.ofString(s))}static makeRangeFilterWithOperation(e,t,n){switch(t){case"=":return e.eq(n);case"<":return e.lessThan(n);case"<=":case"=<":return e.lessThanOrEqualTo(n);case">":return e.greaterThan(n);case">=":case"=>":return e.greaterThanOrEqualTo(n);case"!=":case"!":return e.notEq(n);default:return null}}static makeCancelableTablePromise(e){return Va.makeCancelable(e,(e=>{e.close()}))}static makeCancelableTableEventPromise(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=null,s=null,r=!0,o=new Promise(((o,l)=>{s=setTimeout((()=>{a(),r=!1,l(new ja('Event "'.concat(t,'" timed out.')))}),n),a=e.addEventListener(t,(e=>{null==i||i(e)?(os.debug2("Event triggered, resolving."),a(),clearTimeout(s),r=!1,o(e)):os.debug2("Event triggered, but matcher returned false.")}))}));return o.cancel=()=>{if(r)return os.debug2("Pending promise cleanup."),a(),clearTimeout(s),void(r=!1);os.debug2("Ignoring non-pending promise cancel.")},o}static makeAdvancedFilter(e,t,n){for(var{filterItems:i,filterOperators:a,invertSelection:s,selectedValues:r}=t,o=null,l=0;l<i.length;l+=1){var c=i[l],{selectedType:h,value:d}=c;if(null!=h&&h.length>0&&null!=d&&d.length>0)try{var u=ls.makeAdvancedValueFilter(e,h,d,n);if(null!=u){if(0===l)o=u;else if(null!==o&&l-1<a.length){var m=a[l-1];if(m===ss.and)o=o.and(u);else{if(m!==ss.or){os.error("Unexpected filter operator",m,u),o=null;break}o=o.or(u)}}}else os.debug2("Empty filter ignored for",h,d)}catch(g){os.error("Unable to create filter",g),o=null;break}}var p=ls.makeSelectValueFilter(e,r,s);return null!=p&&(o=null!=o?o.and(p):p),o}static removeCommas(e){return e.replace(/[\s|,]/g,"")}static makeFilterValue(e,t){var n=ls.getBaseType(e);return ls.isTextType(n)?va.FilterValue.ofString(t):ls.isLongType(n)?va.FilterValue.ofNumber(va.LongWrapper.ofString(ls.removeCommas(t))):va.FilterValue.ofNumber(ls.removeCommas(t))}static makeFilterRawValue(e,t){return ls.isTextType(e)?va.FilterValue.ofString(t):ls.isBooleanType(e)?va.FilterValue.ofBoolean(t):va.FilterValue.ofNumber(t)}static makeValue(e,t,n){if(null==t||"null"===t)return null;if(ls.isTextType(e))return t;if(ls.isLongType(e))return va.LongWrapper.ofString(ls.removeCommas(t));if(ls.isBooleanType(e))return ls.makeBooleanValue(t,!0);if(ls.isDateType(e)){var[i]=Ja.parseDateRange(t,n);return i}return ls.isNumberType(e)?ls.makeNumberValue(t):(os.error("Unexpected column type",e),null)}static makeBooleanValue(e){if(""===e&&(arguments.length>1&&void 0!==arguments[1]&&arguments[1]))return null;switch(null===e||void 0===e?void 0:e.toLowerCase()){case"null":return null;case"0":case"f":case"fa":case"fal":case"fals":case"false":case"n":case"no":return!1;case"1":case"t":case"tr":case"tru":case"true":case"y":case"ye":case"yes":return!0;default:throw new Error("Invalid boolean '".concat(e,"'"))}}static makeNumberValue(e){if(null==e||"null"===e||""===e)return null;var t=e.toLowerCase().trim();if("\u221e"===t||"infinity"===t||"inf"===t)return Number.POSITIVE_INFINITY;if("-\u221e"===t||"-infinity"===t||"-inf"===t)return Number.NEGATIVE_INFINITY;var n=ls.removeCommas(t);if(ls.NUMBER_REGEX.test(n))return parseFloat(n);throw new Error("Invalid number '".concat(e,"'"))}static makeAdvancedValueFilter(e,t,n,i){if(ls.isDateType(e.type))return ls.makeQuickDateFilterWithOperation(e,n,t,i);var a=ls.makeFilterValue(e.type,n),s=e.filter();switch(t){case ns.eq:return s.eq(a);case ns.eqIgnoreCase:return s.eqIgnoreCase(a);case ns.notEq:return s.notEq(a);case ns.notEqIgnoreCase:return s.notEqIgnoreCase(a);case ns.greaterThan:return s.greaterThan(a);case ns.greaterThanOrEqualTo:return s.greaterThanOrEqualTo(a);case ns.lessThan:return s.lessThan(a);case ns.lessThanOrEqualTo:return s.lessThanOrEqualTo(a);case ns.isTrue:return s.isTrue();case ns.isFalse:return s.isFalse();case ns.isNull:return s.isNull();case ns.contains:return s.isNull().not().and(s.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(n,"\\E.*"))));case ns.notContains:return s.isNull().or(s.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(n,"\\E.*"))).not());case ns.startsWith:return s.isNull().not().and(s.invoke("matches",va.FilterValue.ofString("(?s)(?i)^\\Q".concat(n,"\\E.*"))));case ns.endsWith:return s.isNull().not().and(s.invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(n,"\\E$"))));default:throw new Error("Unexpected filter operation: ".concat(t))}}static makeSelectValueFilter(e,t,n){if(0===t.length){if(n)return null;var i=null;i=ls.isTextType(e.type)?va.FilterValue.ofString("a"):ls.isBooleanType(e.type)?va.FilterValue.ofBoolean(!0):ls.isDateType(e.type)?va.FilterValue.ofNumber(va.DateWrapper.ofJsDate(new Date)):va.FilterValue.ofNumber(0);var a=e.filter().eq(i),s=e.filter().notEq(i);return a.and(s)}for(var r=[],o=!1,l=0;l<t.length;l+=1){var c=t[l];null==c?o=!0:ls.isTextType(e.type)?r.push(va.FilterValue.ofString("number"===typeof c?String.fromCharCode(c):c)):ls.isBooleanType(e.type)?r.push(va.FilterValue.ofBoolean(!!c)):r.push(va.FilterValue.ofNumber(c))}return o?r.length>0?n?e.filter().isNull().not().and(e.filter().notIn(r)):e.filter().isNull().or(e.filter().in(r)):n?e.filter().isNull().not():e.filter().isNull():n?e.filter().notIn(r):e.filter().in(r)}static isTreeTable(e){return e&&e.expand&&e.collapse}static sortColumns(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return[...e].sort(((e,n)=>{var i=e.name.toUpperCase(),a=n.name.toUpperCase();return Ga.sort(i,a,t)}))}}rs(ls,"dataType",{BOOLEAN:"boolean",CHAR:"char",DATETIME:"datetime",DECIMAL:"decimal",INT:"int",STRING:"string"}),rs(ls,"sortDirection",{ascending:"ASC",descending:"DESC",reverse:"REVERSE",none:null}),rs(ls,"REVERSE_TYPE",Object.freeze({NONE:"none",PRE_SORT:"pre-sort",POST_SORT:"post-sort"})),rs(ls,"NUMBER_REGEX",/^-?\d+(\.\d+)?$/);var cs=ls;function hs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function ds(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?hs(Object(n),!0).forEach((function(t){us(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hs(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function us(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ms=p.module("ChartUtils"),ps=Object.freeze(va.calendar.DayOfWeek.values()),gs="io.deephaven.time.DateTime";class vs{static getPlotlyChartType(e,t){switch(e){case va.plot.SeriesPlotStyle.SCATTER:return t?"scatter":"scattergl";case va.plot.SeriesPlotStyle.LINE:return"scatter";case va.plot.SeriesPlotStyle.BAR:case va.plot.SeriesPlotStyle.STACKED_BAR:return"bar";case va.plot.SeriesPlotStyle.PIE:return"pie";case va.plot.SeriesPlotStyle.HISTOGRAM:return"histogram";case va.plot.SeriesPlotStyle.OHLC:return"ohlc";default:return null}}static getPlotlyChartMode(e){switch(e){case va.plot.SeriesPlotStyle.SCATTER:return"markers";case va.plot.SeriesPlotStyle.LINE:return"lines";default:return null}}static getPlotlyProperty(e,t){switch(e){case va.plot.SeriesPlotStyle.PIE:switch(t){case va.plot.SourceType.X:return"labels";case va.plot.SourceType.Y:return"values"}break;case va.plot.SeriesPlotStyle.OHLC:if(t===va.plot.SourceType.TIME)return"x"}switch(t){case va.plot.SourceType.X:return"x";case va.plot.SourceType.Y:return"y";case va.plot.SourceType.Z:return"z";case va.plot.SourceType.X_LOW:return"xLow";case va.plot.SourceType.X_HIGH:return"xHigh";case va.plot.SourceType.Y_LOW:return"yLow";case va.plot.SourceType.Y_HIGH:return"yHigh";case va.plot.SourceType.TIME:return"time";case va.plot.SourceType.OPEN:return"open";case va.plot.SourceType.HIGH:return"high";case va.plot.SourceType.LOW:return"low";case va.plot.SourceType.CLOSE:return"close";case va.plot.SourceType.SHAPE:return"shape";case va.plot.SourceType.SIZE:return"size";case va.plot.SourceType.LABEL:return"label";case va.plot.SourceType.COLOR:return"color";default:throw new Error("Unrecognized source type",t)}}static getPlotlySeriesOrientation(e){var{sources:t}=e;return 2===t.length&&t[0].axis.type===va.plot.AxisType.Y?vs.ORIENTATION.HORIZONTAL:vs.ORIENTATION.VERTICAL}static getPlotlyErrorBars(e,t,n){var i=n.map(((t,n)=>t-e[n])),a=t.map(((t,n)=>e[n]-t));return{type:"data",symmetric:!1,array:i,arrayminus:a}}static getPlotlyDateFormat(e,t,n){var i=null==n?null:n.replace("%","%%").replace(/S{9}/g,"%9f").replace(/S{8}/g,"%8f").replace(/S{7}/g,"%7f").replace(/S{6}/g,"%6f").replace(/S{5}/g,"%5f").replace(/S{4}/g,"%4f").replace(/S{3}/g,"%3f").replace(/S{2}/g,"%2f").replace(/S{1}/g,"%1f").replace(/y{4}/g,"%Y").replace(/y{2}/g,"%y").replace(/M{4}/g,"%B").replace(/M{3}/g,"%b").replace(/M{2}/g,"%m").replace(/M{1}/g,"%-m").replace(/E{4,}/g,"%A").replace(/E{1,}/g,"%a").replace(/d{2}/g,"%d").replace(/([^%]|^)d{1}/g,"$1%-d").replace(/H{2}/g,"%H").replace(/h{2}/g,"%I").replace(/h{1}/g,"%-I").replace(/m{2}/g,"%M").replace(/s{2}/g,"%S").replace("'T'","T").replace(" z",""),a=null,s=e.getColumnTypeFormatter(t);return null!=s.dhTimeZone&&s.showTimeZone&&(a=va.i18n.DateTimeFormat.format(" z",new Date,s.dhTimeZone)),{tickformat:i,ticksuffix:a,automargin:!0}}static convertNumberPrefix(e){return e.replace(/\u00A4\u00A4/g,"USD").replace(/\u00A4/g,"$")}static getPlotlyNumberFormat(e,t,n){if(!n)return null;var i=n.split(";"),[,a,s,r,,o,l,c,h,d]=i[0].match(/^([^#,0.]*)([#,]*)([0,]*)(\.?)(0*)(#*)(E?0*)(%?)(.*)/),u=r.replace(",","").length,m=s.indexOf(",")>=0||r.indexOf(",")>=0?",":"",p=h||(c?"e":"f"),g=o.length+l.length;return{tickformat:"0".concat(u).concat(m,".").concat(g).concat("").concat(p),tickprefix:vs.convertNumberPrefix(a),ticksuffix:vs.convertNumberPrefix(d),automargin:!0}}static getPlotlyAxisFormat(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,{axis:n,columnType:i}=e,{formatPattern:a}=n,s=null;return cs.isDateType(i)?(s=vs.getPlotlyDateFormat(t,i,a),s=vs.addTickSpacing(s,n,!0)):cs.isNumberType(i)&&(s=vs.getPlotlyNumberFormat(t,i,a),s=vs.addTickSpacing(s,n,!1)),n.formatType===va.plot.AxisFormatType.CATEGORY&&(s?s.type="category":s={type:"category",tickformat:null,ticksuffix:null}),s}static addTickSpacing(e,t,n){var{gapBetweenMajorTicks:i}=t;if(i>0){var a=e||{},s=i;return n&&(s=i/1e6),t.log&&(s=Math.log(s)),a.tickmode="linear",a.dtick=s,a}return e}static getSourceForAxis(e,t){for(var n=0;n<e.series.length;n+=1)for(var i=e.series[n],a=0;a<i.sources.length;a+=1){var s=i.sources[a];if(s.axis===t)return s}return null}static getSeriesVisibility(e,t){var n;return null===t||void 0===t||null===(n=t.hiddenSeries)||void 0===n||!n.includes(e)||"legendonly"}static getHiddenLabels(e){return null!==e&&void 0!==e&&e.hiddenSeries?[...e.hiddenSeries]:[]}static makeSeriesData(e,t,n){return{type:e,mode:t,name:n,orientation:arguments.length>3&&void 0!==arguments[3]?arguments[3]:vs.ORIENTATION.VERTICAL}}static makeSeriesDataFromSeries(e,t,n,i){var{name:a,plotStyle:s,lineColor:r,shapeColor:o,sources:l}=e,c=l.some((e=>e.axis.businessCalendar)),h=vs.getChartType(s,c),d=vs.getPlotlyChartMode(s),u=vs.getPlotlySeriesOrientation(e),m=vs.makeSeriesData(h,d,a,u);return vs.addSourcesToSeriesData(m,s,l,t),vs.addStylingToSeriesData(m,s,i,r,o,n),m}static addSourcesToSeriesData(e,t,n,i){for(var a=e,s=0;s<n.length;s+=1){var r=n[s],{axis:o,type:l}=r;a[vs.getPlotlyProperty(t,l)]=[];var c=vs.getAxisPropertyName(o.type),h=i.get(o.type).indexOf(o);if(null!=c){var d=h>0?"".concat(h+1):"";a["".concat(c,"axis")]="".concat(c).concat(d)}}}static addStylingToSeriesData(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,r=e;r.marker={line:{}},r.line={width:1},t===va.plot.SeriesPlotStyle.AREA?r.fill="tozeroy":t===va.plot.SeriesPlotStyle.STACKED_AREA?r.stackgroup="stack":t===va.plot.SeriesPlotStyle.STEP?r.line.shape="hv":t===va.plot.SeriesPlotStyle.HISTOGRAM?(r.width=[],Object.assign(r.marker.line,{color:n.paper_bgcolor,width:1})):t===va.plot.SeriesPlotStyle.OHLC?(r.increasing={line:{color:n.ohlc_increasing}},r.decreasing={line:{color:n.ohlc_decreasing}}):t===va.plot.SeriesPlotStyle.PIE&&(r.textinfo="label+percent",r.outsidetextfont={color:n.title_color}),null!=i&&(t===va.plot.SeriesPlotStyle.BAR?r.marker.color=i:r.line.color=i),null!=a&&(r.marker.color=a),null!=s&&t!==va.plot.SeriesPlotStyle.PIE&&(r.visible=s)}static getAxisFormats(e,t){for(var n=new Map,i={tickformat:null,ticksuffix:null},{charts:a}=e,s=0;s<a.length;s+=1)for(var r=a[s],o=vs.groupArray(r.axes,"type"),l=0;l<r.series.length;l+=1)for(var c=r.series[l],{sources:h}=c,d=0;d<h.length;d+=1){var u=h[d],{axis:m}=u,{type:p}=m,g=o.get(p).indexOf(m),v=vs.getAxisPropertyName(p),f=vs.getAxisLayoutProperty(v,g);if(n.has(f))ms.debug("".concat(f," already added."));else{var b=function(){ms.debug("Adding ".concat(f," to axisFormats."));var e=vs.getPlotlyAxisFormat(u,t);if(null===e)n.set(f,i);else{n.set(f,e);var{businessCalendar:a}=m;if(a){var s;e.rangebreaks=[];var{businessPeriods:o,businessDays:l,holidays:c,timeZone:h}=a,d=null===t||void 0===t||null===(s=t.getColumnTypeFormatter(gs))||void 0===s?void 0:s.dhTimeZone,p=d?(h.standardOffset-d.standardOffset)/60:0;c.length>0&&e.rangebreaks.push(...vs.createRangeBreakValuesFromHolidays(c,h,d)),o.forEach((t=>e.rangebreaks.push({pattern:"hour",bounds:[vs.periodToDecimal(t.close)+p,vs.periodToDecimal(t.open)+p]}))),l.length<ps.length&&vs.createBoundsFromDays(l).forEach((t=>e.rangebreaks.push({pattern:"day of week",bounds:t})))}if(n.size===r.axes.length)return{v:n}}}();if("object"===typeof b)return b.v}}return n}static getChartType(e,t){return e===va.plot.SeriesPlotStyle.HISTOGRAM?"bar":vs.getPlotlyChartType(e,t)}static getAxisPropertyName(e){switch(e){case va.plot.AxisType.X:return"x";case va.plot.AxisType.Y:return"y";default:return null}}static getAxisSide(e){switch(e){case va.plot.AxisPosition.BOTTOM:return"bottom";case va.plot.AxisPosition.TOP:return"top";case va.plot.AxisPosition.LEFT:return"left";case va.plot.AxisPosition.RIGHT:return"right";default:return null}}static getChartForSeries(e,t){for(var{charts:n}=e,i=0;i<n.length;i+=1)for(var a=n[i],s=0;s<a.series.length;s+=1)if(t===a.series[s])return a;return null}static getLayoutRanges(e){for(var t={},n=Object.keys(e).filter((e=>e.indexOf("axis")>=0)),i=0;i<n.length;i+=1){var a=n[i];e[a]&&e[a].range&&!e[a].autorange&&(t[a]=[...e[a].range])}return t}static updateLayoutAxes(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},r=n>0?Math.max(vs.MIN_AXIS_SIZE,Math.min(vs.AXIS_SIZE_PX/i,vs.MAX_AXIS_SIZE)):vs.DEFAULT_AXIS_SIZE,o=i>0?Math.max(vs.MIN_AXIS_SIZE,Math.min(vs.AXIS_SIZE_PX/n,vs.MAX_AXIS_SIZE)):vs.DEFAULT_AXIS_SIZE,l={left:0,bottom:0,top:1,right:1},c=vs.groupArray(t,"position");(c.get(va.plot.AxisPosition.RIGHT)||[]).length>0&&(l.right=n>0?1-Math.max(0,Math.min(vs.LEGEND_WIDTH_PX/n,vs.MAX_LEGEND_SIZE)):1-vs.DEFAULT_AXIS_SIZE);for(var h=e,d=vs.groupArray(t,"type"),u=[...d.keys()],m=0;m<u.length;m+=1){var p=u[m],g=vs.getAxisPropertyName(p);if(null!=g){var v=d.get(p),f=p===va.plot.AxisType.Y?i:n,b=0;for(b=0;b<v.length;b+=1){var C=v[b],S=vs.getAxisLayoutProperty(g,b);null==h[S]&&(h[S]=vs.makeLayoutAxis(p,s));var E=h[S];vs.updateLayoutAxis(E,C,b,c,r,o,l);var{range:w,autorange:y}=E;if(a&&w&&!y){var T=a(C),[O,M]=T(w);ms.debug("Setting downsample range",f,O,M),C.range(f,O,M)}else C.range(f)}for(var N=vs.getAxisLayoutProperty(g,b);null!=h[N];)delete h[N],b+=1,N=vs.getAxisLayoutProperty(g,b)}}}static getAxisLayoutProperty(e,t){var n=t>0?"".concat(t+1):"";return"".concat(e,"axis").concat(n)}static updateLayoutAxis(e,t,n,i,a,s,r){var o=t.type===va.plot.AxisType.Y?s:a,l=e;if(l.title.text=t.label,t.log&&(l.type="log"),l.side=vs.getAxisSide(t.position),n>0){l.overlaying=vs.getAxisPropertyName(t.type);var c=i.get(t.position),h=c.indexOf(t);h>0&&(l.anchor="free",t.position===va.plot.AxisPosition.RIGHT?l.position=r.right+(h-c.length+1)*o:t.position===va.plot.AxisPosition.TOP?l.position=r.top+(h-c.length+1)*o:t.position===va.plot.AxisPosition.BOTTOM?l.position=r.bottom+(c.length-h+1)*o:t.position===va.plot.AxisPosition.LEFT&&(l.position=r.left+(c.length-h+1)*o))}else if(t.type===va.plot.AxisType.X){var d=i.get(va.plot.AxisPosition.LEFT)||[],u=i.get(va.plot.AxisPosition.RIGHT)||[],m=Math.max(r.left,r.left+(d.length-1)*s),p=Math.min(r.right-(u.length-1)*s,r.right);l.domain=[m,p]}else if(t.type===va.plot.AxisType.Y){var g=i.get(va.plot.AxisPosition.BOTTOM)||[],v=i.get(va.plot.AxisPosition.TOP)||[],f=Math.max(r.bottom,r.bottom+(g.length-1)*a),b=Math.min(r.top-(v.length-1)*a,r.top);l.domain=[f,b]}}static periodToDecimal(e){var t=e.split(":");return Number(t[0])+Number(t[1]/60)}static createBoundsFromDays(e){var t=e.map((e=>ps.indexOf(e))),n=ps.filter((t=>!e.includes(t))).map((e=>ps.indexOf(e))),i=new Set;n.forEach((e=>{for(var n=e+1;n<e+ps.length;n+=1){var a=n%ps.length;if(t.includes(a)){i.add(a);break}}}));var a=[];return i.forEach((e=>{for(var n=e-1;n>e-ps.length;n-=1){var i=n<0?n+ps.length:n;if(t.includes(i)){var s=(i+1)%7;a.push([s,e]);break}}})),a}static createRangeBreakValuesFromHolidays(e,t,n){var i=[],a=[];return e.forEach((e=>{e.businessPeriods.length>0?a.push(...vs.createPartialHoliday(e,t,n)):i.push(vs.createFullHoliday(e,t,n))})),[{values:i},...a]}static createFullHoliday(e,t,n){return vs.adjustDateForTimeZone("".concat(e.date.toString()," 00:00:00.000000"),t,n)}static createPartialHoliday(e,t,n){var i=e.date.toString(),a=["00:00"];e.businessPeriods.forEach((e=>{a.push(e.open),a.push(e.close)})),a.push("24:00");for(var s=[],r=0;r<a.length;r+=2){var o=a[r],l=a[r+1];if(o!==l){var c=[vs.adjustDateForTimeZone("".concat(i," ").concat(o,":00.000000"),t,n)],h=36e5*(vs.periodToDecimal(l)-vs.periodToDecimal(o));s.push({values:c,dvalue:h})}}return s}static adjustDateForTimeZone(e,t,n){return n&&n.standardOffset!==t.standardOffset?vs.unwrapValue(vs.wrapValue(e,gs,t),n):e}static groupArray(e,t){return e.reduce(((e,n)=>{var i=n[t],a=e.get(i)||[];return a.push(n),e.set(i,a),e}),new Map)}static updateRanges(){}static unwrapValue(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(null!=e){if(e.asDate)return va.i18n.DateTimeFormat.format(vs.DATE_FORMAT,e,t);if(e.asNumber)return e.asNumber()}return e}static wrapValue(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(cs.isDateType(t)&&"string"===typeof e){var i=e,a=vs.DATE_FORMAT.substr(0,e.length),s=va.i18n.DateTimeFormat.parse(a,i);if(!n)return s;var r="".concat(a," Z"),o=va.i18n.DateTimeFormat.format("Z",s,n),l=va.i18n.DateTimeFormat.parse(r,"".concat(i," ").concat(o)),c=va.i18n.DateTimeFormat.format("Z",l,n);return va.i18n.DateTimeFormat.parse(r,"".concat(i," ").concat(c))}return e}static makeLayoutAxis(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n={automargin:!0,gridcolor:t.gridcolor,linecolor:t.linecolor,rangeslider:{visible:!1},showline:!0,ticklen:5,tickcolor:t.paper_bgcolor,tickfont:{color:t.zerolinecolor},title:{font:{color:t.title_color}}};return e===va.plot.AxisType.X?Object.assign(n,{showgrid:!0}):e===va.plot.AxisType.Y&&Object.assign(n,{zerolinecolor:t.zerolinecolor,zerolinewidth:2}),n}static getColorwayFromTheme(e){var t=[];return e.colorway&&(Array.isArray(e.colorway)?t=e.colorway:"string"===typeof e.colorway?t=e.colorway.split(" "):ms.warn("Unable to handle colorway property: ".concat(e.colorway))),t}static makeDefaultLayout(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ds(ds({},e),{},{autosize:!0,colorway:vs.getColorwayFromTheme(e),font:{family:"'Fira Sans', sans-serif"},title:{font:{color:e.title_color},yanchor:"top",pad:ds({},vs.DEFAULT_TITLE_PADDING),y:1},legend:{font:{color:e.title_color}},margin:ds({},vs.DEFAULT_MARGIN),xaxis:vs.makeLayoutAxis(va.plot.AxisType.X,e),yaxis:vs.makeLayoutAxis(va.plot.AxisType.Y,e)});return t.datarevision=0,t}static dehydrateSettings(e){return ds(ds({},e),{},{type:"".concat(e.type)})}static hydrateSettings(e){return ds(ds({},e),{},{type:va.plot.SeriesPlotStyle[e.type]})}static titleFromSettings(e){var{series:t,xAxis:n,title:i="".concat(t.join(", ")," by ").concat(n)}=e;return i}static makeFigureSettings(e,t){var{series:n,xAxis:i,type:a}=e,s=vs.titleFromSettings(e),r={formatType:"".concat(va.plot.AxisFormatType.NUMBER),type:"".concat(va.plot.AxisType.X),position:"".concat(va.plot.AxisPosition.BOTTOM)},o={formatType:"".concat(va.plot.AxisFormatType.NUMBER),type:"".concat(va.plot.AxisType.Y),position:"".concat(va.plot.AxisPosition.LEFT)};return{charts:[{chartType:"".concat(va.plot.ChartType.XY),axes:[r,o],series:n.map((e=>({plotStyle:"".concat(a),name:e,dataSources:[{type:"".concat(va.plot.SourceType.X),columnName:i,axis:r,table:t},{type:"".concat(va.plot.SourceType.Y),columnName:e,axis:o,table:t}]})))}],title:s}}}us(vs,"DEFAULT_AXIS_SIZE",.15),us(vs,"MIN_AXIS_SIZE",.025),us(vs,"MAX_AXIS_SIZE",.2),us(vs,"AXIS_SIZE_PX",75),us(vs,"LEGEND_WIDTH_PX",50),us(vs,"MAX_LEGEND_SIZE",.25),us(vs,"ORIENTATION",Object.freeze({HORIZONTAL:"h",VERTICAL:"v"})),us(vs,"DATE_FORMAT","yyyy-MM-dd HH:mm:ss.SSSSSS"),us(vs,"DEFAULT_MARGIN",Object.freeze({l:60,r:50,t:30,b:60,pad:0})),us(vs,"DEFAULT_TITLE_PADDING",Object.freeze({t:8})),us(vs,"SUBTITLE_LINE_HEIGHT",25);var fs=vs;var bs=class{static getColumnFormats(e){var{formatter:t}=e;return t}static getDateTimeFormatterOptions(e){var{timeZone:t,defaultDateTimeFormat:n,showTimeZone:i,showTSeparator:a}=e;return{timeZone:t,defaultDateTimeFormatString:n,showTimeZone:i,showTSeparator:a}}};function Cs(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Ss{static isValid(e){return!0}static isSameFormat(e,t){throw new Error("isSameFormat not implemented")}static makeFormat(e,t,n){return{label:e,formatString:t,type:n}}format(e,t){return""}}Cs(Ss,"TYPE_GLOBAL","type-global"),Cs(Ss,"TYPE_CONTEXT_PRESET","type-context-preset"),Cs(Ss,"TYPE_CONTEXT_CUSTOM","type-context-custom");var Es=Ss;var ws=class extends Es{format(e){return"".concat(e)}};var ys=class extends Es{format(e){switch(e){case 1:case!0:return"true";case 0:case!1:return"false";default:return""}}};var Ts=class extends Es{format(e){return String.fromCharCode(e)}};function Os(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ms=p.module("DateTimeColumnFormatter");class Ns extends Es{static isValid(e){try{return va.i18n.DateTimeFormat.format(e.formatString,new Date),!0}catch(t){return!1}}static makeFormat(e,t){return{label:e,formatString:t,type:arguments.length>2&&void 0!==arguments[2]?arguments[2]:Es.TYPE_CONTEXT_PRESET}}static isSameFormat(e,t){return e===t||null!=e&&null!=t&&e.type===t.type&&e.formatString===t.formatString}static makeGlobalFormatStringMap(e,t){var n=t?"'T'":" ",i=e?" z":"";return new Map([["yyyy-MM-dd HH:mm:ss","yyyy-MM-dd".concat(n,"HH:mm:ss").concat(i)],["yyyy-MM-dd HH:mm:ss.SSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSS").concat(i)],["yyyy-MM-dd HH:mm:ss.SSSSSSSSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSSSSSSSS").concat(i)]])}static getGlobalFormats(e,t){return[...Ns.makeGlobalFormatStringMap(e,t).keys()]}static makeFormatStringMap(e,t){var n=t?"'T'":" ",i=e?" z":"";return new Map([["yyyy-MM-dd","yyyy-MM-dd".concat(i)],["MM-dd-yyyy","MM-dd-yyyy".concat(i)],["HH:mm:ss","HH:mm:ss".concat(i)],["HH:mm:ss.SSS","HH:mm:ss.SSS".concat(i)],["HH:mm:ss.SSSSSSSSS","HH:mm:ss.SSSSSSSSS".concat(i)],["yyyy-MM-dd HH:mm:ss","yyyy-MM-dd".concat(n,"HH:mm:ss").concat(i)],["yyyy-MM-dd HH:mm:ss.SSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSS").concat(i)],["yyyy-MM-dd HH:mm:ss.SSSSSSSSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSSSSSSSS").concat(i)]])}static getFormats(e,t){return[...Ns.makeFormatStringMap(e,t).keys()]}constructor(){var{timeZone:e="",showTimeZone:t=!0,showTSeparator:n=!1,defaultDateTimeFormatString:i=Ns.DEFAULT_DATETIME_FORMAT_STRING}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super(),Os(this,"dhTimeZone",void 0),Os(this,"defaultDateTimeFormatString",void 0),Os(this,"showTimeZone",void 0),Os(this,"showTSeparator",void 0),Os(this,"formatStringMap",void 0);var a=e||Ns.DEFAULT_TIME_ZONE_ID;try{this.dhTimeZone=va.i18n.TimeZone.getTimeZone(a)}catch(s){Ms.error("Unsupported time zone id",a),this.dhTimeZone=va.i18n.TimeZone.getTimeZone(Ns.DEFAULT_TIME_ZONE_ID)}this.defaultDateTimeFormatString=i,this.showTimeZone=t,this.showTSeparator=n,this.formatStringMap=Ns.makeFormatStringMap(t,n)}getEffectiveFormatString(e){return this.formatStringMap.get(e)||e}format(e,t){var n=t&&t.formatString||this.defaultDateTimeFormatString,i=this.getEffectiveFormatString(n);try{return va.i18n.DateTimeFormat.format(i,e,this.dhTimeZone)}catch(a){Ms.error("Invalid format arguments")}return""}}Os(Ns,"DEFAULT_DATETIME_FORMAT_STRING","yyyy-MM-dd HH:mm:ss.SSS"),Os(Ns,"DEFAULT_TIME_ZONE_ID","America/New_York");var Ds=Ns;function xs(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Rs=p.module("DecimalTableColumnFormatter");class Is extends Es{static isValid(e){try{return va.i18n.NumberFormat.format(e.formatString,0),!0}catch(t){return!1}}static makeFormat(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return{label:e,type:arguments.length>3&&void 0!==arguments[3]?arguments[3]:Es.TYPE_CONTEXT_PRESET,formatString:t,multiplier:n}}static makeCustomFormat(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return Is.makeFormat("Custom Format",e,t,Es.TYPE_CONTEXT_CUSTOM)}static isSameFormat(e,t){return e===t||null!=e&&null!=t&&e.type===t.type&&e.formatString===t.formatString&&e.multiplier===t.multiplier}format(e,t){var n=t&&t.formatString||Is.DEFAULT_FORMAT_STRING,i=t&&t.multiplier?e*t.multiplier:e;try{return va.i18n.NumberFormat.format(n,i)}catch(a){Rs.error("Invalid format arguments")}return""}}xs(Is,"DEFAULT_FORMAT_STRING","###,##0.0000"),xs(Is,"FORMAT_PERCENT",Is.makeFormat("Percent","##0.00%")),xs(Is,"FORMAT_BASIS_POINTS",Is.makeFormat("Basis Points","###,##0 bp",1e4)),xs(Is,"FORMAT_MILLIONS",Is.makeFormat("Millions","###,##0.000 mm",1e-6)),xs(Is,"FORMAT_ROUND",Is.makeFormat("Round","###,##0")),xs(Is,"FORMAT_ROUND_TWO_DECIMALS",Is.makeFormat("0.00","###,##0.00")),xs(Is,"FORMAT_ROUND_FOUR_DECIMALS",Is.makeFormat("0.0000","###,##0.0000"));var Ls=Is;function Fs(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ks=p.module("IntegerColumnFormatter");class As extends Es{static isValid(e){try{return va.i18n.NumberFormat.format(e.formatString,0),!0}catch(t){return!1}}static makeFormat(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return{label:e,type:arguments.length>3&&void 0!==arguments[3]?arguments[3]:Es.TYPE_CONTEXT_PRESET,formatString:t,multiplier:n}}static makeCustomFormat(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return As.makeFormat("Custom Format",e,t,Es.TYPE_CONTEXT_CUSTOM)}static isSameFormat(e,t){return e===t||null!=e&&null!=t&&e.type===t.type&&e.formatString===t.formatString&&e.multiplier===t.multiplier}format(e,t){var n=t&&t.formatString||As.DEFAULT_FORMAT_STRING,i=t&&t.multiplier?e*t.multiplier:e;try{return va.i18n.NumberFormat.format(n,i)}catch(a){ks.error("Invalid format arguments")}return""}}Fs(As,"DEFAULT_FORMAT_STRING","###,##0"),Fs(As,"FORMAT_MILLIONS",As.makeFormat("Millions","###,##0.000 mm",1e-6));var Ps=As;class _s{static makeColumnFormatMap(e){return null==e?new Map:e.reduce(((e,t)=>{var n=cs.getNormalizedType(t.columnType);return e.has(n)||e.set(n,new Map),e.get(n).set(t.columnName,t.format),e}),new Map)}static makeColumnFormattingRule(e,t,n){return{columnType:e,columnName:t,format:n}}constructor(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.defaultColumnFormatter=new ws,this.typeFormatterMap=new Map([[cs.dataType.BOOLEAN,new ys],[cs.dataType.CHAR,new Ts],[cs.dataType.DATETIME,new Ds(t)],[cs.dataType.DECIMAL,new Ls],[cs.dataType.INT,new Ps]]),this.columnFormatMap=_s.makeColumnFormatMap(e)}getColumnFormatMapForType(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=cs.getNormalizedType(e);return t&&!this.columnFormatMap.has(n)&&this.columnFormatMap.set(n,new Map),this.columnFormatMap.get(n)}getColumnFormat(e,t){var n=this.getColumnFormatMapForType(e);return n&&n.has(t)?n.get(t):null}getColumnTypeFormatter(e){var t=cs.getNormalizedType(e);return t&&this.typeFormatterMap.has(t)?this.typeFormatterMap.get(t):this.defaultColumnFormatter}getFormattedString(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;if(null==e)return"";var a=this.getColumnTypeFormatter(t),s=i||this.getColumnFormat(t,n);return a.format(e,s)}get timeZone(){var e,t;return null===(e=this.typeFormatterMap.get(cs.dataType.DATETIME))||void 0===e||null===(t=e.dhTimeZone)||void 0===t?void 0:t.id}}var Hs=_s,js=n(487),Vs=n.n(js),zs=n(718),Us=n.n(zs),Bs=n(719),Ws=n.n(Bs),Gs=n(720),qs=n.n(Gs),Ks=n(721),Ys=n.n(Ks),Xs=n(722),Zs=n.n(Xs);Vs.a.register([Us.a,Ws.a,qs.a,Ys.a,Zs.a]);var $s=Vs.a,Qs=n(408),Js=n.n(Qs),er="function"===typeof Js.a?Js()($s):Js.a.default($s);function tr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class nr{constructor(){this.listeners=[],this.formatter=null,this.rect=null,this.isDownsamplingDisabled=!1,this.title=null}getData(){return[]}getDefaultTitle(){return""}getLayout(){return{}}getFilterColumnMap(){return new Map}isFilterRequired(){return!1}setFilter(){}close(){}setFormatter(e){this.formatter=e}setDownsamplingDisabled(e){this.isDownsamplingDisabled=e}setDimensions(e){this.rect=e}setTitle(e){this.title=e}subscribe(e){this.listeners.push(e)}unsubscribe(e){this.listeners=this.listeners.filter((t=>t!==e))}fireEvent(e){for(var t=0;t<this.listeners.length;t+=1)this.listeners[t](e)}fireUpdate(e){this.fireEvent(new CustomEvent(nr.EVENT_UPDATED,{detail:e}))}fireDisconnect(){this.fireEvent(new CustomEvent(nr.EVENT_DISCONNECT))}fireReconnect(){this.fireEvent(new CustomEvent(nr.EVENT_RECONNECT))}fireDownsampleStart(e){this.fireEvent(new CustomEvent(nr.EVENT_DOWNSAMPLESTARTED,{detail:e}))}fireDownsampleFinish(e){this.fireEvent(new CustomEvent(nr.EVENT_DOWNSAMPLEFINISHED,{detail:e}))}fireDownsampleFail(e){this.fireEvent(new CustomEvent(nr.EVENT_DOWNSAMPLEFAILED,{detail:e}))}fireDownsampleNeeded(e){this.fireEvent(new CustomEvent(nr.EVENT_DOWNSAMPLENEEDED,{detail:e}))}fireLoadFinished(){this.fireEvent(new CustomEvent(nr.EVENT_LOADFINISHED))}}tr(nr,"EVENT_UPDATED","ChartModel.EVENT_UPDATED"),tr(nr,"EVENT_DISCONNECT","ChartModel.EVENT_DISCONNECT"),tr(nr,"EVENT_RECONNECT","ChartModel.EVENT_RECONNECT"),tr(nr,"EVENT_DOWNSAMPLESTARTED","ChartModel.EVENT_DOWNSAMPLESTARTED"),tr(nr,"EVENT_DOWNSAMPLEFINISHED","ChartModel.EVENT_DOWNSAMPLEFINISHED"),tr(nr,"EVENT_DOWNSAMPLEFAILED","ChartModel.EVENT_DOWNSAMPLEFAILED"),tr(nr,"EVENT_DOWNSAMPLENEEDED","ChartModel.EVENT_DOWNSAMPLENEEDED"),tr(nr,"EVENT_LOADFINISHED","ChartModel.EVENT_LOADFINISHED");var ir=nr,ar=n(350),sr=n.n(ar);n(866);function rr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function or(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rr(Object(n),!0).forEach((function(t){lr(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function lr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var cr=p.module("Chart");class hr extends i.Component{static convertIcon(e){var[t,,,,n]=e.icon;return{width:t,path:n,ascent:t,descent:0,transform:"matrix(1, 0, 0, 1, 0, 0)"}}static downsampleButtonTitle(e,t){return e?sr.a["title-downsampling-in-progress"]:t?sr.a["title-downsampling-disabled"]:sr.a["title-downsampling-enabled"]}constructor(e){super(e),lr(this,"getCachedConfig",Object(ua.a)(((e,t,n,i)=>{var a=[];if(e&&a.push({name:"".concat(sr.a["title-downsampling-failed"],": ").concat(e),click:()=>{},icon:hr.convertIcon(zn)}),t||n||i||e){var s=hr.downsampleButtonTitle(n,i),r=n?xt:bn;a.push({name:s,icon:hr.convertIcon(r),click:this.handleDownsampleClick})}return{displaylogo:!1,displayModeBar:!(!n&&!e)||"hover",modeBarButtons:[a,["toImage"],["zoom2d","pan2d"],["zoomIn2d","zoomOut2d","autoScale2d","resetScale2d"]]}}))),this.handleAfterPlot=this.handleAfterPlot.bind(this),this.handleDownsampleClick=this.handleDownsampleClick.bind(this),this.handleModelEvent=this.handleModelEvent.bind(this),this.handlePlotUpdate=this.handlePlotUpdate.bind(this),this.handleRelayout=this.handleRelayout.bind(this),this.handleRestyle=this.handleRestyle.bind(this),this.plot=a.a.createRef(),this.plotWrapper=a.a.createRef(),this.columnFormats=[],this.dateTimeFormatterOptions={},this.rect=null,this.ranges=null,this.isSubscribed=!1,this.isLoadedFired=!1,this.state={data:null,downsamplingError:null,isDownsampleFinished:!1,isDownsampleInProgress:!1,isDownsamplingDisabled:!1,layout:{datarevision:0},revision:0}}componentDidMount(){this.updateDimensions(),this.updateModelDimensions(),this.initData(),this.initFormatter();var{isActive:e}=this.props;e&&this.subscribe()}componentDidUpdate(e){var{isActive:t,settings:n}=this.props;this.updateFormatterSettings(n),t!==e.isActive&&(t?this.subscribe():this.unsubscribe())}componentWillUnmount(){this.unsubscribe()}getPlotRect(){var e,t;return null!==(e=null===(t=this.plotWrapper.current)||void 0===t?void 0:t.getBoundingClientRect())&&void 0!==e?e:null}initData(){var{model:e}=this.props,{layout:t}=this.state;this.setState({data:e.getData(),layout:or(or({},t),e.getLayout())})}subscribe(){if(!this.isSubscribed){var{model:e}=this.props;this.rect&&0!==this.rect.width&&0!==this.rect.height?(e.subscribe(this.handleModelEvent),this.isSubscribed=!0):cr.debug2("Delaying subscription until model dimensions are set")}}unsubscribe(){if(this.isSubscribed){var{model:e}=this.props;e.unsubscribe(this.handleModelEvent),this.isSubscribed=!1}}handleAfterPlot(){this.plot.current}handleDownsampleClick(){this.setState((e=>{var{isDownsamplingDisabled:t}=e;return{downsamplingError:null,isDownsampleInProgress:!1,isDownsampleFinished:!1,isDownsamplingDisabled:!t}}),(()=>{var{model:e}=this.props,{isDownsamplingDisabled:t}=this.state;e.setDownsamplingDisabled(t)}))}handleModelEvent(e){var{type:t,detail:n}=e;switch(cr.debug2("Received data update",t,n),t){case ir.EVENT_UPDATED:this.currentSeries+=1,this.setState((e=>{var{layout:t,revision:i}=e;return t.datarevision+=1,{data:n,layout:t,revision:i+1}}));var{onUpdate:i}=this.props;i({isLoading:!this.isLoadedFired});break;case ir.EVENT_LOADFINISHED:var{onUpdate:a}=this.props;this.isLoadedFired=!0,a({isLoading:!1});break;case ir.EVENT_DISCONNECT:var{onDisconnect:s}=this.props;s();break;case ir.EVENT_RECONNECT:var{onReconnect:r}=this.props;r();break;case ir.EVENT_DOWNSAMPLESTARTED:this.setState({isDownsampleFinished:!1,isDownsampleInProgress:!0,downsamplingError:null});break;case ir.EVENT_DOWNSAMPLEFINISHED:this.setState({isDownsampleFinished:!0,isDownsampleInProgress:!1,downsamplingError:null});break;case ir.EVENT_DOWNSAMPLENEEDED:case ir.EVENT_DOWNSAMPLEFAILED:var o=n.message?n.message:n;this.setState({isDownsampleFinished:!1,isDownsampleInProgress:!1,isDownsamplingDisabled:!1,downsamplingError:o});var{onError:l}=this.props;l(new Error(o));break;default:cr.debug("Unknown event type",t,e)}}handlePlotUpdate(e){var{layout:t}=e,n=fs.getLayoutRanges(t);!oe()(n,this.ranges)&&(this.ranges=n,this.updateModelDimensions(!0))}handleRelayout(e){if(cr.debug("handleRelayout",e),Object.keys(e).includes("hiddenlabels")){var{onSettingsChanged:t}=this.props;t({hiddenSeries:[...e.hiddenlabels]})}this.updateModelDimensions()}handleRestyle(e){var[t,n]=e;if(cr.debug("handleRestyle",t,n),Object.keys(t).includes("visible")){var{data:i}=this.state,{onSettingsChanged:a}=this.props;a({hiddenSeries:i.reduce(((e,t)=>{var{name:n,visible:i}=t;return"legendonly"===i?[...e,n]:e}),[])})}}updateModelDimensions(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.getPlotRect();if(t){if(!this.rect||this.rect.width!==t.width||this.rect.height!==t.height||e){this.rect=t;var{isActive:n,model:i}=this.props;i.setDimensions(t),n&&this.subscribe()}}else cr.warn("Unable to get plotting rect")}initFormatter(){var{settings:e}=this.props;this.updateFormatterSettings(e)}updateFormatterSettings(e){var t=bs.getColumnFormats(e),n=bs.getDateTimeFormatterOptions(e);oe()(this.columnFormats,t)&&oe()(this.dateTimeFormatterOptions,n)||(this.columnFormats=bs.getColumnFormats(e),this.dateTimeFormatterOptions=bs.getDateTimeFormatterOptions(e),this.updateFormatter())}updateFormatter(){var e=new Hs(this.columnFormats,this.dateTimeFormatterOptions),{model:t}=this.props;t.setFormatter(e)}updateDimensions(){var e=this.getPlotRect();null!=this.plot.current&&null!=e&&e.width>0&&e.height>0&&$s.relayout(this.plot.current.el,{autosize:!0}).catch((e=>{cr.debug("Unable to resize, promise rejected",e)}))}render(){var{data:e,downsamplingError:t,isDownsampleFinished:n,isDownsampleInProgress:i,isDownsamplingDisabled:s,layout:r,revision:o}=this.state,l=this.getCachedConfig(t,n,i,s),c=null!=e;return a.a.createElement("div",{className:"h-100 w-100 chart-wrapper",ref:this.plotWrapper},c&&a.a.createElement(er,{ref:this.plot,data:e,layout:r,revision:o,config:l,onAfterPlot:this.handleAfterPlot,onRelayout:this.handleRelayout,onUpdate:this.handlePlotUpdate,onRestyle:this.handleRestyle,useResizeHandler:!0,style:{height:"100%",width:"100%"}}))}}hr.propTypes={model:pi.a.instanceOf(ir).isRequired,settings:pi.a.shape({timeZone:pi.a.string.isRequired,defaultDateTimeFormat:pi.a.string.isRequired,showTimeZone:pi.a.bool.isRequired,showTSeparator:pi.a.bool.isRequired,formatter:pi.a.arrayOf(pi.a.shape({})).isRequired}),isActive:pi.a.bool,onDisconnect:pi.a.func,onReconnect:pi.a.func,onUpdate:pi.a.func,onError:pi.a.func,onSettingsChanged:pi.a.func},hr.defaultProps={isActive:!0,settings:{timeZone:"America/New_York",defaultDateTimeFormat:Ja.FULL_DATE_FORMAT,showTimeZone:!1,showTSeparator:!0,formatter:[]},onDisconnect:()=>{},onReconnect:()=>{},onUpdate:()=>{},onError:()=>{},onSettingsChanged:()=>{}};var dr,ur=hr,mr=n(238),pr=n.n(mr);function gr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.DOWN="DOWN",e.UP="UP",e.LEFT="LEFT",e.RIGHT="RIGHT"}(dr||(dr={}));class vr{static normalize(e,t,n,i){var a=e,s=t,r=n,o=i;return null!=a&&null!=r&&r<a&&(a=r,r=e),null!=s&&null!=o&&o<s&&(s=o,o=t),[a,s,r,o]}static makeNormalized(e,t,n,i){return new vr(...vr.normalize(e,t,n,i))}static makeCell(e,t){return new vr(e,t,e,t)}static makeColumn(e){return new vr(e,null,e,null)}static makeRow(e){return new vr(null,e,null,e)}static minOrNull(e,t){return null==e||null==t?null:Math.min(e,t)}static maxOrNull(e,t){return null==e||null==t?null:Math.max(e,t)}static consolidate(e){for(var t=e.slice(),n=!0;n;){n=!1;for(var i=0;i<t.length&&!n;i+=1)for(var a=t[i],s=t.length-1;s>i;s-=1){var r=t[s];if(a.contains(r))t.splice(s,1);else{if(r.contains(a)){n=!0,t[i]=r,t.splice(s,1);break}if(a.startRow===r.startRow&&a.endRow===r.endRow){if(a.touches(r)){var{startRow:o,endRow:l}=a,c=vr.minOrNull(a.startColumn,r.startColumn),h=vr.maxOrNull(a.endColumn,r.endColumn);n=!0,t[i]=new vr(c,o,h,l),t.splice(s,1);break}}else if(a.startColumn===r.startColumn&&a.endColumn===r.endColumn&&a.touches(r)){var{startColumn:d,endColumn:u}=a,m=vr.minOrNull(a.startRow,r.startRow),p=vr.maxOrNull(a.endRow,r.endRow);n=!0,t[i]=new vr(d,m,u,p),t.splice(s,1);break}}}}return t}static isAxisRangeTouching(e,t,n,i){return null==e?null==t||(null==n||n<=t+1):null==t?null==i||i>=e-1:null==n?null==i||e<=i+1:null==i?t>=n-1:n>=e-1?n<=t+1:i>=e-1}static rangeArraysEqual(e,t){if(e===t)return!0;if(null==e||null==t||e.length!==t.length)return!1;for(var n=0;n<e.length;n+=1)if(!e[n].equals(t[n]))return!1;return!0}static intersection(e,t){var n,i,a,s,r,o;if(e.equals(t))return e;var{startColumn:l,startRow:c,endColumn:h,endRow:d}=e;return l=null!=l&&null!=t.startColumn?Math.max(l,t.startColumn):null!==(n=l)&&void 0!==n?n:t.startColumn,h=null!=h&&null!=t.endColumn?Math.min(h,t.endColumn):null!==(i=h)&&void 0!==i?i:t.endColumn,c=null!=c&&null!=t.startRow?Math.max(c,t.startRow):null!==(a=c)&&void 0!==a?a:t.startRow,d=null!=d&&null!=t.endRow?Math.min(d,t.endRow):null!==(s=d)&&void 0!==s?s:t.endRow,null!=l&&l>(null!==(r=h)&&void 0!==r?r:-1)||null!=c&&c>(null!==(o=d)&&void 0!==o?o:-1)?null:new vr(l,c,h,d)}static subtractFromRange(e,t){var n=[],i=vr.intersection(e,t);return null==i?[e]:(null!=i.startRow&&(null==e.startRow||e.startRow<i.startRow)&&n.push(new vr(e.startColumn,e.startRow,e.endColumn,i.startRow-1)),null!=i.startColumn&&(null==e.startColumn||e.startColumn<i.startColumn)&&n.push(new vr(e.startColumn,i.startRow,i.startColumn-1,i.endRow)),null!=i.endColumn&&(null==e.endColumn||e.endColumn>i.endColumn)&&n.push(new vr(i.endColumn+1,i.startRow,e.endColumn,i.endRow)),null!=i.endRow&&(null==e.endRow||e.endRow>i.endRow)&&n.push(new vr(e.startColumn,i.endRow+1,e.endColumn,e.endRow)),n)}static subtractFromRanges(e,t){for(var n=[],i=0;i<e.length;i+=1)n.push(...vr.subtractFromRange(e[i],t));return n}static subtractRangesFromRanges(e,t){if(!t||0===t.length)return e;for(var n=[...e],i=0;i<t.length;i+=1)n=vr.subtractFromRanges(n,t[i]);return n}static isBounded(e){return null!=e.startRow&&null!=e.startColumn&&null!=e.endRow&&null!=e.endColumn}static boundedRange(e,t,n){var i,a,s,r;return vr.isBounded(e)?e:new vr(null!==(i=e.startColumn)&&void 0!==i?i:0,null!==(a=e.startRow)&&void 0!==a?a:0,null!==(s=e.endColumn)&&void 0!==s?s:t-1,null!==(r=e.endRow)&&void 0!==r?r:n-1)}static boundedRanges(e,t,n){return e.map((e=>vr.boundedRange(e,t,n)))}static offset(e,t,n){return new vr(null!=e.startColumn?e.startColumn+t:null,null!=e.startRow?e.startRow+n:null,null!=e.endColumn?e.endColumn+t:null,null!=e.endRow?e.endRow+n:null)}static nextCell(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:vr.SELECTION_DIRECTION.DOWN;if(0===e.length)return null;var a=-1;if(null!=t&&null!=n&&(a=e.findIndex((e=>e.containsCell(t,n))))>=0){var s=e[a].nextCell(t,n,i);if(null!=s)return s}switch(i){case vr.SELECTION_DIRECTION.DOWN:case vr.SELECTION_DIRECTION.RIGHT:return e[a<e.length-1?a+1:0].startCell(i);case vr.SELECTION_DIRECTION.LEFT:case vr.SELECTION_DIRECTION.UP:return e[a>0?a-1:e.length-1].startCell(i);default:throw new Error("Invalid direction: ".concat(i))}}static cellCount(e){return e.reduce(((e,t)=>{var n,i,a,s;return e+((null!==(n=t.endRow)&&void 0!==n?n:NaN)-(null!==(i=t.startRow)&&void 0!==i?i:NaN)+1)*((null!==(a=t.endColumn)&&void 0!==a?a:NaN)-(null!==(s=t.startColumn)&&void 0!==s?s:NaN)+1)}),0)}static rowCount(e){return e.reduce(((e,t)=>{var n,i;return e+(null!==(n=t.endRow)&&void 0!==n?n:NaN)-(null!==(i=t.startRow)&&void 0!==i?i:NaN)+1}),0)}static columnCount(e){return e.reduce(((e,t)=>{var n,i;return e+(null!==(n=t.endColumn)&&void 0!==n?n:NaN)-(null!==(i=t.startColumn)&&void 0!==i?i:NaN)+1}),0)}static containsCell(e,t,n){for(var i=0;i<e.length;i+=1){if(e[i].containsCell(t,n))return!0}return!1}static forEachCell(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:vr.SELECTION_DIRECTION.RIGHT,i=0;i<e.length;i+=1)e[i].forEach(t,n)}constructor(e,t,n,i){gr(this,"startColumn",void 0),gr(this,"startRow",void 0),gr(this,"endColumn",void 0),gr(this,"endRow",void 0),this.startColumn=e,this.startRow=t,this.endColumn=n,this.endRow=i}equals(e){return this.startColumn===e.startColumn&&this.startRow===e.startRow&&this.endColumn===e.endColumn&&this.endRow===e.endRow}contains(e){return(null==this.startColumn||null!=e.startColumn&&this.startColumn<=e.startColumn)&&(null==this.startRow||null!=e.startRow&&this.startRow<=e.startRow)&&(null==this.endColumn||null!=e.endColumn&&this.endColumn>=e.endColumn)&&(null==this.endRow||null!=e.endRow&&this.endRow>=e.endRow)}containsCell(e,t){return null!=e&&null!=t&&((null==this.startColumn||this.startColumn<=e)&&(null==this.endColumn||this.endColumn>=e)&&(null==this.startRow||this.startRow<=t)&&(null==this.endRow||this.endRow>=t))}touches(e){return vr.isAxisRangeTouching(this.startRow,this.endRow,e.startRow,e.endRow)&&vr.isAxisRangeTouching(this.startColumn,this.endColumn,e.startColumn,e.endColumn)}subtract(e){return vr.subtractFromRange(this,e)}startCell(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:vr.SELECTION_DIRECTION.DOWN;if(!vr.isBounded(this))throw new Error("Cannot get the startCell of an unbounded range");switch(e){case vr.SELECTION_DIRECTION.DOWN:case vr.SELECTION_DIRECTION.RIGHT:return{column:this.startColumn,row:this.startRow};case vr.SELECTION_DIRECTION.LEFT:case vr.SELECTION_DIRECTION.UP:return{column:this.endColumn,row:this.endRow};default:throw new Error("Invalid direction: ".concat(e))}}nextCell(e,t,n){if(!vr.isBounded(this))throw new Error("Bounded range required");if(null==e||null==t)throw new Error("Require a non-null cursor");var{startColumn:i,endColumn:a,startRow:s,endRow:r}=this;switch(n){case vr.SELECTION_DIRECTION.DOWN:if(t<r)return{column:e,row:Math.max(t+1,s)};if(e<a)return{column:Math.max(e+1,i),row:s};break;case vr.SELECTION_DIRECTION.UP:if(t>s)return{column:e,row:Math.min(t-1,r)};if(e>i)return{column:Math.min(e-1,a),row:r};break;case vr.SELECTION_DIRECTION.RIGHT:if(e<a)return{column:Math.max(e+1,i),row:t};if(t<r)return{column:i,row:Math.max(t+1,s)};break;case vr.SELECTION_DIRECTION.LEFT:if(e>i)return{column:Math.min(e-1,a),row:t};if(t>s)return{column:a,row:Math.min(t-1,r)};break;default:throw new Error("Invalid direction: ".concat(n))}return null}forEach(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:vr.SELECTION_DIRECTION.RIGHT,n=0,{column:i,row:a}=this.startCell(t);null!=i&&null!=a;){var s;e(i,a,n),n+=1,({column:i,row:a}=null!==(s=this.nextCell(i,a,t))&&void 0!==s?s:{})}}}gr(vr,"SELECTION_DIRECTION",dr);var fr=vr;function br(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Cr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?br(Object(n),!0).forEach((function(t){Sr(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):br(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Sr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Er{static getGridPointFromXY(e,t,n){var i=Er.getColumnAtX(e,n);return{x:e,y:t,row:Er.getRowAtY(t,n),column:i}}static iterateFloatingStart(e,t,n){for(var i=0;i<e&&i<t;i+=1){var a=n(i);if(void 0!==a)return a}}static iterateFloatingEnd(e,t,n){for(var i=0;i<e&&t-(e-i)>=0;i+=1){var a=n(t-(e-i));if(void 0!==a)return a}}static iterateFloating(e,t,n,i){var a=Er.iterateFloatingStart(e,n,i);return void 0!==a?a:Er.iterateFloatingEnd(t,n,i)}static iterateAllItems(e,t,n,i,a,s){var r=Math.max(e,n),o=Math.min(t,a-i-1),l=Er.iterateFloating(n,i,a,s);if(void 0!==l)return l;for(var c=r;c<=o;c+=1)if(void 0!==(l=s(c)))return l}static isInItem(e,t,n,i){var a,s,r=null!==(a=t.get(e))&&void 0!==a?a:0,o=null!==(s=n.get(e))&&void 0!==s?s:0;return r<=i&&i<=r+o}static getItemAtOffset(e,t,n,i,a,s,r){var o=Er.iterateFloating(n,i,t,(t=>{if(Er.isInItem(t,s,r,e))return t}));if(void 0!==o)return o;for(var l=0;l<a.length;l+=1){var c=a[l];if(Er.isInItem(c,s,r,e))return c}return null}static getColumnAtX(e,t){var{columnCount:n,floatingLeftColumnCount:i,floatingRightColumnCount:a,visibleColumns:s,visibleColumnXs:r,visibleColumnWidths:o,gridX:l}=t;return e<l?null:this.getItemAtOffset(e-l,n,i,a,s,r,o)}static getRowAtY(e,t){var{floatingTopRowCount:n,floatingBottomRowCount:i,rowCount:a,visibleRows:s,visibleRowYs:r,visibleRowHeights:o,gridY:l}=t;return e<l?null:this.getItemAtOffset(e-l,a,n,i,s,r,o)}static getNextShownItem(e,t,n,i){var a=n.findIndex((t=>t===e))||0;for(a-=1;null!=a&&a>=0;){var s=n[a],r=t.get(s);if(null!=r&&0!==i.get(r))return s;a-=1}return null}static getNextShownColumn(e,t){var{modelColumns:n,visibleColumns:i,userColumnWidths:a}=t;return Er.getNextShownItem(e,n,i,a)}static getNextShownRow(e,t){var{modelRows:n,visibleRows:i,userRowHeights:a}=t;return Er.getNextShownItem(e,n,i,a)}static getColumnSeparatorIndex(e,t,n,i){var{rowHeaderWidth:a,columnHeaderHeight:s,floatingColumns:r,floatingLeftWidth:o,visibleColumns:l,visibleColumnXs:c,visibleColumnWidths:h}=n,{allowColumnResize:d,headerSeparatorHandleSize:u}=i;if(s<t||!d||u<=0)return null;for(var m=e-a,p=.5*u,g=!1,v=r.length-1;v>=0;v-=1){var f,b,C=r[v],S=null!==(f=c.get(C))&&void 0!==f?f:0,E=null!==(b=h.get(C))&&void 0!==b?b:0,w=0===E;if(!g||!w){var y=S+E;if(w?y+=p:g&&(y-=p),y-p<=m&&m<=y+p)return C;g=w}}g=!1;for(var T=l.length-1;T>=0;T-=1){var O,M,N=l[T],D=null!==(O=c.get(N))&&void 0!==O?O:0,x=null!==(M=h.get(N))&&void 0!==M?M:0,R=0===x;if(D<o-x)return null;if(!g||!R){var I=D+x;if(R?I+=p:g&&(I-=p),I-p<=m&&m<=I+p)return N;g=R}}return null}static isItemHidden(e,t){return 0===t.get(e)}static isColumnHidden(e,t){var{visibleColumnWidths:n}=t;return Er.isItemHidden(e,n)}static isFloatingRow(e,t){if(null==e)return!1;var{floatingTopRowCount:n,floatingBottomRowCount:i,rowCount:a}=t;return e<n||e>=a-i}static isFloatingColumn(e,t){if(null==e)return!1;var{floatingLeftColumnCount:n,floatingRightColumnCount:i,columnCount:a}=t;return e<n||e>=a-i}static getHiddenItems(e,t,n){if(!Er.isItemHidden(e,t))return[];for(var i=[e],a=n.findIndex((t=>t===e)),s=a-1;s>=0;s-=1){var r=n[s];if(!Er.isItemHidden(r,t))break;i.push(r)}return i}static getHiddenColumns(e,t){var{visibleColumns:n,visibleColumnWidths:i}=t;return Er.getHiddenItems(e,i,n)}static getRowSeparatorIndex(e,t,n,i){var{rowHeaderWidth:a,columnHeaderHeight:s,visibleRows:r,visibleRowYs:o,visibleRowHeights:l}=n,{allowRowResize:c,headerSeparatorHandleSize:h}=i;if(a<e||!c||h<=0)return null;for(var d=t-s,u=.5*h,m=!1,p=r.length-1;p>=0;p-=1){var g,v,f=r[p],b=null!==(g=o.get(f))&&void 0!==g?g:0,C=null!==(v=l.get(f))&&void 0!==v?v:0,S=0===C;if(!m||!S){var E=b+C;if(S?E+=u:m&&(E-=u),E-u<=d&&d<=E+u)return f;m=S}}return null}static isRowHidden(e,t){var{visibleRowHeights:n}=t;return Er.isItemHidden(e,n)}static getHiddenRows(e,t){var{visibleRows:n,visibleRowHeights:i}=t;return Er.getHiddenItems(e,i,n)}static moveItem(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(e===t)return n;var i=[...n];return i.length>0&&i[i.length-1].to===e?i[i.length-1]=Cr(Cr({},i[i.length-1]),{},{to:t}):i.push({from:e,to:t}),i}static getModelIndex(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=e,i=t.length-1;i>=0;i-=1){var a=t[i];n===a.to?({from:n}=a):a.from<=n&&n<a.to?n+=1:a.to<n&&n<=a.from&&(n-=1)}return n}static getModelRangeIndexes(e,t,n){if(null==e||null==t)return[[e,t]];var i=[[e,t]];if(null==e)return i;for(var a=n.length-1;a>=0;a-=1){for(var{from:s,to:r}=n[a],o=[],l=0;l<i.length;l+=1){var[c,h]=i[l],d=o.length;s<=c?r>h?o.push([c+1,h+1]):r>=c&&(o.push([s,s]),o.push([c+1,h])):s>h?r<c?o.push([c-1,h-1]):r<=h&&(o.push([s,s]),o.push([c,h-1])):r<c?(o.push([c-1,s-1]),o.push([s+1,h])):r>h?(o.push([c,s-1]),o.push([s+1,h+1])):s>r?(r>c&&o.push([c,r-1]),o.push([s,s]),o.push([r,s-1]),s<h&&o.push([s+1,h])):s<r&&(s>c&&o.push([c,s-1]),o.push([s+1,r]),o.push([s,s]),s<h&&o.push([r+1,h])),d===o.length&&o.push([c,h])}i=o}return i}static getModelRange(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i=Er.getModelRangeIndexes(e.startColumn,e.endColumn,t),a=Er.getModelRangeIndexes(e.startRow,e.endRow,n),s=[],r=0;r<i.length;r+=1)for(var o=i[r],l=0;l<a.length;l+=1){var c=a[l];s.push(new fr(o[0],c[0],o[1],c[1]))}return s}static getModelRanges(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i=[],a=0;a<e.length;a+=1)i.push(...Er.getModelRange(e[a],t,n));return i}static getVisibleIndex(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=e,i=0;i<t.length;i+=1){var a=t[i];n===a.from?({to:n}=a):a.from<n&&n<=a.to?n-=1:a.to<=n&&n<a.from&&(n+=1)}return n}static isMacPlatform(){var{platform:e}=window.navigator;return e.startsWith("Mac")}static getModifierKey(){return Er.isMacPlatform()?"metaKey":"ctrlKey"}static isModifierKeyDown(e){return e[Er.getModifierKey()]}static checkColumnHidden(e,t){return 0===t.get(e)}static checkAllColumnsHidden(e,t){return 0!==t.size&&e.every((e=>0===t.get(e)))}static getScrollDragBounds(e,t,n){var{gridX:i,gridY:a,width:s,height:r,floatingTopRowCount:o,floatingBottomRowCount:l,floatingLeftColumnCount:c,floatingRightColumnCount:h,floatingLeftWidth:d,floatingRightWidth:u,floatingTopHeight:m,floatingBottomHeight:p,columnCount:g,rowCount:v}=e,f=i,b=a,C=s,S=r;return null!=n&&(n>c&&(f+=d),n<g-h&&(C-=u)),null!=t&&(t>o&&(b+=m),t<v-l&&(S-=p)),{x1:f,y1:b,x2:C,y2:S}}static getScrollDelta(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1024,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:768,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:20,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:20,{deltaX:s,deltaY:r}=e;return!Er.isMacPlatform()&&e.shiftKey&&0===e.deltaX&&0!==e.deltaY&&(s=e.deltaY,r=e.deltaX),(null===e||void 0===e?void 0:e.deltaMode)===WheelEvent.DOM_DELTA_PAGE?(s*=t,r*=n):(null===e||void 0===e?void 0:e.deltaMode)===WheelEvent.DOM_DELTA_LINE&&(Er.isMacPlatform()?(s=Math.round(s*i),r=Math.round(r*a)):(s=Math.round(s*this.PIXELS_PER_LINE),r=Math.round(r*this.PIXELS_PER_LINE))),{deltaX:s,deltaY:r}}}Sr(Er,"PIXELS_PER_LINE",100/3);var wr=Er;function yr(e){return void 0!==(null===e||void 0===e?void 0:e.hasExpandableRows)}function Tr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Or(e,t){var n,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=null!==(n=e.get(t))&&void 0!==n?n:i;if(void 0!==a)return a;throw new Error("Missing value for key ".concat(t))}function Mr(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Dr.CACHE_SIZE,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Math.floor(t/2);if(e.size>t)for(var i=e.keys();e.size>n;)e.delete(i.next().value)}function Nr(e,t,n,i,a){for(var s=new Map,r=0,o=0;o<e&&o<n;o+=1)s.set(o,r),r+=Or(a,o);r=i;for(var l=0;l<t&&n-l-1>=0;l+=1)r-=Or(a,n-l-1),s.set(n-l-1,r);return s}class Dr{constructor(){var{userColumnWidths:e=new Map,userRowHeights:t=new Map,calculatedColumnWidths:n=new Map,calculatedRowHeights:i=new Map,fontWidths:a=new Map,modelRows:s=new Map,modelColumns:r=new Map,movedRows:o=[],movedColumns:l=[]}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Tr(this,"userColumnWidths",void 0),Tr(this,"userRowHeights",void 0),Tr(this,"calculatedColumnWidths",void 0),Tr(this,"calculatedRowHeights",void 0),Tr(this,"fontWidths",void 0),Tr(this,"modelRows",void 0),Tr(this,"modelColumns",void 0),Tr(this,"movedRows",void 0),Tr(this,"movedColumns",void 0),this.userColumnWidths=e,this.userRowHeights=t,this.calculatedRowHeights=i,this.calculatedColumnWidths=n,this.fontWidths=a,this.modelRows=s,this.modelColumns=r,this.movedRows=o,this.movedColumns=l}getMetrics(e){var{left:t,top:n,leftOffset:i,topOffset:a,width:s,height:r,theme:o,model:l,movedRows:c,movedColumns:h}=e,{rowHeight:d,rowHeaderWidth:u,rowFooterWidth:m,columnWidth:p,columnHeaderHeight:g,minScrollHandleSize:v,scrollBarSize:f}=o;c!==this.movedRows&&(this.movedRows=c,this.modelRows.clear()),h!==this.movedColumns&&(this.movedColumns=h,this.modelColumns.clear());var{columnCount:b,rowCount:C,floatingTopRowCount:S,floatingBottomRowCount:E,floatingLeftColumnCount:w,floatingRightColumnCount:y}=l,T=this.getFirstRow(e),O=this.getFirstColumn(e),M=this.getGridX(e),N=this.getGridY(e),D=yr(l)&&l.hasExpandableRows?this.calculateTreePaddingX(e):0,x=this.getVisibleRowHeights(e),R=this.getVisibleColumnWidths(e,O,D),I=Array.from(x.keys()),L=Array.from(R.keys());x=new Map([...x,...this.getFloatingRowHeights(e)]),R=new Map([...R,...this.getFloatingColumnWidths(e)]);var F=this.getVisibleColumnXs(R,L,i),k=this.getVisibleRowYs(x,I,a),A=I.length>0?I[I.length-1]:n,P=L.length>0?L[L.length-1]:t,_=this.getBottomViewport(e,I,k,x),H=this.getRightViewport(e,L,F,R),j=Array.from(R.values()),V=Array.from(x.values()),z=j.reduce(((e,t)=>e+t),0)-i,U=V.reduce(((e,t)=>e+t),0)-a,B=this.getFloatingBottomHeight(e,x),W=this.getLastLeft(e,null,s-M-f-m),G=this.getLastTop(e,null,r-N-f-B),q=W>0,K=G>0,Y=q?f:0,X=K?f:0,Z=s-u-X,$=r-g-Y,Q=W>0?Math.min(Math.max(v,Z*((b-W)/b)),Z-1):0,J=G>0?Math.min(Math.max(v,$*((C-G)/C)),$-1):0,ee=Or(R,t,0),te=Or(x,n,0),ne=W>0?(t+(ee>0?i/ee:0))/W*(Z-Q):0,ie=G>0?(n+(te>0?a/te:0))/G*($-J):0,ae=[];(S>0||E>0)&&(ae=[...Array(S).keys(),...[...Array(E).keys()].map((e=>C-e-1))],k=new Map([...k,...this.getFloatingRowYs(e,x,Math.floor(r-N-Y))]));var se=[];(w>0||y>0)&&(se=[...Array(w).keys(),...[...Array(y).keys()].map((e=>b-e-1))],F=new Map([...F,...this.getFloatingColumnXs(e,R,Math.floor(s-M-X))]));var re=I.concat(ae),oe=L.concat(se),le=this.getModelRows(re,e),ce=this.getModelColumns(oe,e),he=this.getVisibleRowTreeBoxes(x,le,e),de=this.getTopVisible(e,k,x,I),ue=this.getLeftVisible(e,F,R,L),me=G>0?this.getBottomVisible(e,k,x,I,N):A,pe=W>0?this.getRightVisible(e,F,R,L,M):P,ge=this.getFloatingTopHeight(e,x),ve=this.getFloatingLeftWidth(e,R),fe=this.getFloatingRightWidth(e,R),{fontWidths:be,userColumnWidths:Ce,userRowHeights:Se,calculatedRowHeights:Ee,calculatedColumnWidths:we}=this;return{rowHeight:d,rowHeaderWidth:u,rowFooterWidth:m,rowCount:C,columnWidth:p,columnCount:b,columnHeaderHeight:g,floatingTopRowCount:S,floatingBottomRowCount:E,floatingLeftColumnCount:w,floatingRightColumnCount:y,gridX:M,gridY:N,firstRow:T,firstColumn:O,treePaddingX:D,treePaddingY:0,left:t,top:n,bottom:A,right:P,topOffset:a,leftOffset:i,topVisible:de,leftVisible:ue,bottomVisible:me,rightVisible:pe,bottomViewport:_,rightViewport:H,width:s,height:r,maxX:z,maxY:U,lastLeft:W,lastTop:G,barHeight:$,barWidth:Z,handleHeight:J,handleWidth:Q,hasHorizontalBar:q,hasVerticalBar:K,verticalBarWidth:X,horizontalBarHeight:Y,scrollX:ne,scrollY:ie,visibleRows:I,visibleColumns:L,floatingRows:ae,floatingColumns:se,allRows:re,allColumns:oe,visibleRowHeights:x,visibleColumnWidths:R,floatingTopHeight:ge,floatingBottomHeight:B,floatingLeftWidth:ve,floatingRightWidth:fe,visibleRowYs:k,visibleColumnXs:F,visibleRowTreeBoxes:he,modelRows:le,modelColumns:ce,fontWidths:be,userColumnWidths:Ce,userRowHeights:Se,calculatedRowHeights:Ee,calculatedColumnWidths:we}}getGridX(e){var{theme:t}=e,{rowHeaderWidth:n}=t;return n}getGridY(e){var{theme:t}=e,{columnHeaderHeight:n}=t;return n}getVisibleHeight(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingRowHeights(e),{height:n,theme:i}=e,{scrollBarSize:a}=i,s=this.getGridY(e);return n-this.getFloatingBottomHeight(e,t)-this.getFloatingTopHeight(e,t)-s-a}getVisibleWidth(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingColumnWidths(e),{width:n,theme:i}=e,{scrollBarSize:a,rowFooterWidth:s}=i,r=this.getGridX(e),o=this.getFloatingRightWidth(e,t);return n-this.getFloatingLeftWidth(e,t)-o-r-a-s}getFirstIndex(e,t,n){for(var i=e.size+1,a=0;a<i;a+=1){var s=t(a,n);if(0!==e.get(s))return a}return 0}getFirstColumn(e){return this.getFirstIndex(this.userColumnWidths,this.getModelColumn.bind(this),e)}getFirstRow(e){return this.getFirstIndex(this.userRowHeights,this.getModelRow.bind(this),e)}getLastLeft(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.getVisibleWidth(e),{model:i}=e,{columnCount:a}=i,s=a-1;null!=t&&(s=t);for(var r=0;s>=0;){if((r+=this.getVisibleColumnWidth(s,e))>=n)return Math.min(s+1,a-1);s-=1}return 0}getLastTop(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.getVisibleHeight(e),{model:i}=e,{rowCount:a,floatingBottomRowCount:s}=i,r=Math.max(0,a-s-1);null!=t&&(r=t);for(var o=0;r>0;){if((o+=this.getVisibleRowHeight(r,e))>=n)return Math.min(r+1,a-1);r-=1}return 0}getTopForTopVisible(e,t){for(var n=this.getFloatingTopHeight(e),i=t,a=0;i>0&&a<n;)i-=1,a+=this.getVisibleRowHeight(i,e);return i}getTopForBottomVisible(e,t){var{height:n}=e,i=n-this.getGridY(e)-this.getFloatingBottomHeight(e);return this.getLastTop(e,t,i)}getLeftForLeftVisible(e,t){for(var n=this.getFloatingLeftWidth(e),i=t,a=0;i>0&&a<n;)i-=1,a+=this.getVisibleColumnWidth(i,e);return i}getLeftForRightVisible(e,t){var{width:n}=e,i=n-this.getGridX(e)-this.getFloatingRightWidth(e);return this.getLastLeft(e,t,i)}getFloatingRowHeights(e){for(var{model:t}=e,{floatingTopRowCount:n,floatingBottomRowCount:i,rowCount:a}=t,s=new Map,r=0;r<n&&r<a;r+=1)s.set(r,this.getVisibleRowHeight(r,e));for(var o=0;o<i&&a-o-1>=0;o+=1){var l=a-o-1;s.set(l,this.getVisibleRowHeight(l,e))}return s}getVisibleRowHeights(e){for(var{top:t,topOffset:n,height:i,model:a}=e,s=0,r=t,o=new Map,{rowCount:l}=a;s<i+n&&r<l;){var c=this.getVisibleRowHeight(r,e);o.set(r,c),s+=c,r+=1}return o}getFloatingColumnWidths(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFirstColumn(e),n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.calculateTreePaddingX(e),{model:i}=e,{columnCount:a,floatingLeftColumnCount:s,floatingRightColumnCount:r}=i,o=new Map,l=0;l<s&&l<a;l+=1)o.set(l,this.getVisibleColumnWidth(l,e,t,n));for(var c=0;c<r&&a-c-1>=0;c+=1){var h=a-c-1;o.set(h,this.getVisibleColumnWidth(h,e,t,n))}return o}getVisibleColumnWidths(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFirstColumn(e),n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.calculateTreePaddingX(e),{left:i,leftOffset:a,width:s,model:r}=e,o=0,l=i,c=new Map,{columnCount:h}=r;o<s+a&&l<h;){var d=this.getVisibleColumnWidth(l,e,t,n);c.set(l,d),o+=d,l+=1}return c}getFloatingColumnXs(e,t,n){var{model:i}=e,{columnCount:a,floatingLeftColumnCount:s,floatingRightColumnCount:r}=i;return Nr(s,r,a,n,t)}getVisibleColumnXs(e,t,n){for(var i=new Map,a=-n,s=0;s<t.length;s+=1){var r=t[s],o=Or(e,r);i.set(r,a),a+=o}return i}getFloatingRowYs(e,t,n){var{model:i}=e,{floatingTopRowCount:a,floatingBottomRowCount:s,rowCount:r}=i;return Nr(a,s,r,n,t)}getVisibleRowYs(e,t,n){for(var i=new Map,a=-n,s=0;s<t.length;s+=1){var r=t[s],o=Or(e,r);i.set(r,a),a+=o}return i}getVisibleRowTreeBoxes(e,t,n){var i=new Map,{model:a,theme:s}=n,{treeDepthIndent:r,treeHorizontalPadding:o}=s;return yr(a)&&a.hasExpandableRows&&e.forEach(((e,n)=>{var s=Or(t,n);if(a.isRowExpandable(s)){var l=a.depthForRow(s),c=l*r+o,h=(l+1)*r+o,d=e;i.set(n,{x1:c,y1:0,x2:h,y2:d})}})),i}getFloatingLeftWidth(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingColumnWidths(e),{model:n}=e,{floatingLeftColumnCount:i}=n,a=0,s=0;s<i;s+=1)a+=Or(t,s);return a}getFloatingRightWidth(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingColumnWidths(e),{model:n}=e,{floatingRightColumnCount:i,columnCount:a}=n,s=0,r=0;r<i;r+=1)s+=Or(t,a-r-1);return s}getFloatingTopHeight(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingRowHeights(e),{model:n}=e,{floatingTopRowCount:i}=n,a=0,s=0;s<i;s+=1)a+=Or(t,s);return a}getFloatingBottomHeight(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getFloatingRowHeights(e),{model:n}=e,{floatingBottomRowCount:i,rowCount:a}=n,s=0,r=0;r<i;r+=1)s+=Or(t,a-r-1);return s}getTopVisible(e,t,n,i){for(var a=this.getFloatingTopHeight(e,n),s=0;s<i.length;s+=1){var r=i[s];if(Or(t,r)>=a)return r}return 0}getLeftVisible(e,t,n,i){for(var a=this.getFloatingLeftWidth(e,n),s=0;s<i.length;s+=1){var r=i[s];if(Or(t,r)>=a)return r}return 0}getBottomVisible(e,t,n,i,a){for(var{height:s,theme:r}=e,{scrollBarSize:o}=r,l=s-a-o-this.getFloatingBottomHeight(e,n),c=i.length-1;c>=0;c-=1){var h=i[c];if(Or(t,h)+Or(n,h)<=l)return h}return 0}getRightVisible(e,t,n,i,a){for(var{width:s,theme:r}=e,{scrollBarSize:o}=r,l=s-a-o-this.getFloatingRightWidth(e,n),c=i.length-1;c>=0;c-=1){var h=i[c];if(Or(t,h)+Or(n,h)<=l)return h}return 0}getBottomViewport(e,t,n,i){var{height:a,theme:s}=e,{rowHeight:r}=s;return this.getLastIndexViewport(t,n,i,a,r)}getRightViewport(e,t,n,i){var{width:a,theme:s}=e,{columnWidth:r}=s;return this.getLastIndexViewport(t,n,i,a,r)}getLastIndexViewport(e,t,n,i,a){var s=0,r=0;return e.length>0&&(r=Or(t,s=e[e.length-1])+Or(n,s)),r<i&&(s+=Math.ceil((i-r)/a)),s}getVisibleItemSize(e,t,n){var i;return null!==(i=t.get(e))&&void 0!==i?i:n()}getVisibleRowHeight(e,t){var n=this.getModelRow(e,t);return this.getVisibleItemSize(n,this.userRowHeights,(()=>this.calculateRowHeight(e,n,t)))}getVisibleColumnWidth(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.getFirstColumn(t),i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.calculateTreePaddingX(t),a=this.getModelColumn(e,t);return this.getVisibleItemSize(a,this.userColumnWidths,(()=>this.calculateColumnWidth(e,a,t,n,i)))}getModelRows(e,t){for(var n=new Map,i=0;i<e.length;i+=1){var a=e[i],s=this.getModelRow(a,t);n.set(a,s)}return n}getModelRow(e,t){if(this.modelRows.has(e))return Or(this.modelRows,e);var{movedRows:n}=t,i=wr.getModelIndex(e,n);return this.modelRows.set(e,i),i}getModelColumns(e,t){for(var n=new Map,i=0;i<e.length;i+=1){var a=e[i],s=this.getModelColumn(a,t);n.set(a,s)}return n}getModelColumn(e,t){if(this.modelColumns.has(e))return Or(this.modelColumns,e);var{movedColumns:n}=t,i=wr.getModelIndex(e,n);return this.modelColumns.set(e,i),i}calculateRowHeight(e,t,n){var{theme:i}=n,{autoSizeRows:a,rowHeight:s}=i;if(!a)return s;var r=this.calculatedRowHeights.get(t);return null!=r?r:(this.calculatedRowHeights.set(t,Math.ceil(s)),Mr(this.calculatedRowHeights),s)}calculateColumnWidth(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.getFirstColumn(n),a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.calculateTreePaddingX(n),{theme:s}=n,{autoSizeColumns:r,minColumnWidth:o}=s;if(!r){var{columnWidth:l}=s;return l}var c=this.calculateColumnHeaderWidth(t,n),h=this.calculateColumnDataWidth(t,n),d=this.calculatedColumnWidths.get(t),u=Math.ceil(Math.max(c,h));return u=Math.max(o,u),null!=d&&d>u?u=d:(this.calculatedColumnWidths.set(t,u),Mr(this.calculatedColumnWidths)),e===i&&(u+=a),u}calculateColumnHeaderWidth(e,t){var{model:n,theme:i}=t,{headerFont:a,headerHorizontalPadding:s}=i,r=n.textForColumnHeader(e);if(r){var o=this.getWidthForFont(a,t);return r.length*o+2*s}return 2*s}calculateColumnDataWidth(e,t){var{top:n,height:i,width:a,model:s,theme:r}=t,{floatingTopRowCount:o,floatingBottomRowCount:l,rowCount:c}=s,{font:h,cellHorizontalPadding:d,rowHeight:u,rowHeaderWidth:m,rowFooterWidth:p,scrollBarSize:g}=r,v=0,f=this.getWidthForFont(h,t),b=i/u,C=Math.ceil(n+b);return wr.iterateAllItems(n,C,o,l,c,(n=>{var i=this.getModelRow(n,t),a=s.textForCell(e,i);if(a){var r=2*d;v=Math.max(v,a.length*f+r)}})),v=Math.max(Math.min(v,(a-m-g-p)*Dr.MAX_COLUMN_WIDTH),2*d)}calculateTreePaddingX(e){var{top:t,height:n,model:i,theme:a}=e,{rowHeight:s,treeDepthIndent:r}=a;if(!yr(i)||!i.hasExpandableRows)return 0;for(var o=0,l=n/s,c=Math.ceil(t+l),h=t;h<=c;h+=1){var d=this.getModelRow(h,e),u=i.depthForRow(d);o=Math.max(o,r*(u+1))}return o}getWidthForFont(e,t){if(this.fontWidths.has(e))return Or(this.fontWidths,e);var{context:n}=t;n.font=e;var i=n.measureText("8"),{width:a}=i;return this.fontWidths.set(e,a),this.fontWidths.set(n.font,a),a}setColumnWidth(e,t){var n=new Map(this.userColumnWidths);n.set(e,Math.ceil(t)),Mr(n),this.userColumnWidths=n}resetColumnWidth(e){var t=new Map(this.userColumnWidths);t.delete(e),this.userColumnWidths=t,this.calculatedColumnWidths.delete(e)}setRowHeight(e,t){var n=new Map(this.userRowHeights);n.set(e,Math.ceil(t)),Mr(n),this.userRowHeights=n}resetRowHeight(e){var t=new Map(this.userRowHeights);t.delete(e),this.userRowHeights=t,this.calculatedRowHeights.delete(e)}}Tr(Dr,"CACHE_SIZE",1e4),Tr(Dr,"MAX_COLUMN_WIDTH",.8);var xr=Dr,Rr=Object.freeze({allowColumnResize:!0,allowRowResize:!0,autoSelectRow:!1,autoSelectColumn:!1,autoSizeColumns:!0,autoSizeRows:!0,backgroundColor:"#000000",cellHorizontalPadding:5,headerHorizontalPadding:5,font:"12px Arial, sans serif",gridColumnColor:"#8f8f8f66",gridRowColor:"#8f8f8f66",headerBackgroundColor:"#222222",headerSeparatorColor:"#000000",headerSeparatorHoverColor:"#888888",headerSeparatorHandleSize:5,headerHiddenSeparatorSize:5,headerHiddenSeparatorHoverColor:"#8888FF",headerColor:"#d5d5d5",headerFont:"10px Arial, sans serif",columnHoverBackgroundColor:"#444444",selectedColumnHoverBackgroundColor:"#494949",rowBackgroundColors:"#333333 #222222",rowHoverBackgroundColor:"#444444",selectedRowHoverBackgroundColor:"#494949",minScrollHandleSize:50,scrollBarBackgroundColor:"#111111",scrollBarHoverBackgroundColor:"#333333",scrollBarCasingColor:"#000000",scrollBarCornerColor:"#000000",scrollBarColor:"#555555",scrollBarHoverColor:"#888888",scrollBarActiveColor:"#AAAAAA",scrollBarSize:12,scrollBarHoverSize:16,scrollBarCasingWidth:1,scrollSnapToColumn:!1,scrollSnapToRow:!1,selectionColor:"#4286f433",selectionOutlineColor:"#4286f4",selectionOutlineCasingColor:"#222222",shadowBlur:8,shadowColor:"#000000",textColor:"#ffffff",maxDepth:6,treeDepthIndent:10,treeHorizontalPadding:5,treeLineColor:"#888888",treeMarkerColor:"#cccccc",treeMarkerHoverColor:"#ffffff",rowHeight:20,columnWidth:100,minRowHeight:20,minColumnWidth:55,columnHeaderHeight:20,rowHeaderWidth:30,rowFooterWidth:0,headerResizeSnapThreshold:10,headerResizeHiddenSnapThreshold:8,allowColumnReorder:!0,allowRowReorder:!0,reorderOffset:2,floatingGridColumnColor:"#8f8f8f66",floatingGridRowColor:"#8f8f8f66",floatingRowBackgroundColors:"#393939 #292929",floatingDividerOuterColor:"#000000",floatingDividerInnerColor:"#cccccc"}),Ir=n(49),Lr=n.n(Ir);function Fr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function kr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fr(Object(n),!0).forEach((function(t){Ar(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ar(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Pr=(e,t)=>{var n=!1,i=Lr()(e,kr(kr({},t),{},{dispose:()=>{n||(n=!0,i.clear(),n=!1)}}));return i},_r=n(407),Hr=n.n(_r);var jr={colorWithAlpha:function(e,t){var[n,i,a]=Hr.a.hex.rgb(e);return"rgba(".concat(n,", ").concat(i,", ").concat(a,", ").concat(t,")")},darkenForDepth:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:6,i=Hr.a.hex.lab(e);return i[0]=Math.max(i[0]-i[0]/n*t,0),"#".concat(Hr.a.lab.hex(i))}};class Vr extends Error{constructor(){super(...arguments),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isAssertionFailed",!0)}}var zr=Vr;var Ur=function(e){if(void 0===e||null===e)throw new zr("Expected 'val' to be defined, but received ".concat(e))};class Br extends Error{constructor(){super(...arguments),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isPasteError",!0)}}var Wr=Br;function Gr(e){return void 0!==(null===e||void 0===e?void 0:e.isEditable)}function qr(e){if(!Gr(e))throw new zr("Expected 'model' to be editable, but received ".concat(e))}function Kr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Yr{constructor(){Kr(this,"getCachedTruncatedString",Pr(((e,t,n,i)=>Yr.truncateToWidth(e,t,n,i)),{max:1e4})),Kr(this,"getCachedBackgroundColors",Pr(((e,t)=>e.split(" ").map((e=>{for(var n=[],i=0;i<t;i+=1)n.push(jr.darkenForDepth(e,i,t));return n}))),{max:1e3})),Kr(this,"getCachedColorWithAlpha",Pr(((e,t)=>jr.colorWithAlpha(e,t)),{max:1e3}))}static truncate(e,t){return t<e.length?e.substr(0,t)+"\u2026":e}static binaryTruncateToWidth(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:t.length;if(a>=t.length&&e.measureText(t).width<=n)return t;for(var s=i,r=Math.min(t.length-1,a),o=t;r>=s;){var l=Math.ceil((r+s)/2),c=Yr.truncate(t,l);if(e.measureText(c).width<=n){if(o=c,s===l)break;s=l}else{if(0===l){o=c;break}r=l-1}}return o}static truncateToWidth(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Yr.DEFAULT_FONT_WIDTH;if(n<=0||t.length<=0)return"";var a=Math.min(Math.max(0,Math.floor(n/i/2)-5),t.length),s=Math.min(Math.ceil(n/i*2),t.length);return Yr.binaryTruncateToWidth(e,t,n,a,s)}drawCanvas(e){var{context:t}=e;t.save(),this.configureContext(t,e),this.drawBackground(t,e),this.drawGrid(t,e),this.drawHeaders(t,e),this.drawFooters(t,e),this.drawDraggingColumn(t,e),this.drawDraggingRow(t,e),this.drawScrollBars(t,e),t.restore()}configureContext(e,t){var{theme:n}=t;e.font=n.font,e.textBaseline="middle",e.lineCap="butt"}drawBackground(e,t){var{theme:n,metrics:i}=t,{width:a,height:s}=i;e.fillStyle=n.backgroundColor,e.fillRect(0,0,a,s)}drawGrid(e,t){var{metrics:n,draggingRow:i,draggingColumn:a}=t,{gridX:s,gridY:r}=n;e.translate(s,r),this.drawGridBackground(e,t,null==i&&null==a),this.drawCellContents(e,t),this.drawFloatingRows(e,t),this.drawFloatingColumns(e,t),e.translate(-s,-r)}drawFloatingRows(e,t){var{draggingRow:n,draggingColumn:i,metrics:a,theme:s}=t,{floatingTopRowCount:r,floatingBottomRowCount:o,floatingRows:l,rowCount:c,visibleColumns:h,visibleRowYs:d,visibleRowHeights:u}=a;if(0!==l.length){s.floatingRowBackgroundColors&&this.drawRowStripesForRows(e,t,l,s.floatingRowBackgroundColors),null==n&&null==i&&this.drawFloatingMouseRowHover(e,t),this.drawGridLinesForItems(e,t,h,l,s.floatingGridColumnColor,s.floatingGridRowColor),this.drawCellBackgroundsForItems(e,t,h,l),this.drawFloatingBorders(e,t),r>0&&this.drawSelectedRanges(e,t,{top:0,bottom:r-1,maxY:Or(d,r-1)+Or(u,r-1)-.5}),o>0&&this.drawSelectedRanges(e,t,{top:c-o-1,bottom:c-1,minY:Or(d,c-o)+.5,maxY:Or(d,c-1)+Or(u,c-1)-.5});for(var m=0;m<h.length;m+=1)for(var p=h[m],g=0;g<l.length;g+=1){var v=l[g];this.drawCellContent(e,t,p,v)}}}drawFloatingColumns(e,t){var{draggingRow:n,draggingColumn:i,metrics:a,theme:s}=t,{floatingLeftColumnCount:r,floatingRightColumnCount:o,floatingLeftWidth:l,floatingRightWidth:c,floatingColumns:h,gridX:d,maxX:u,columnCount:m,visibleRows:p,visibleColumnXs:g,visibleColumnWidths:v,width:f,height:b}=a;if(0!==h.length){s.floatingRowBackgroundColors&&(this.drawRowStripesForRows(e,t,p,s.floatingRowBackgroundColors,0,l),this.drawRowStripesForRows(e,t,p,s.floatingRowBackgroundColors,f-d-c,u)),null==n&&null==i&&this.drawFloatingMouseRowHover(e,t),e.save(),e.beginPath(),e.rect(0,0,l,b),e.clip(),this.drawGridLinesForItems(e,t,h,p,s.floatingGridColumnColor,s.floatingGridRowColor),e.restore(),this.drawCellBackgroundsForItems(e,t,h,p),this.drawFloatingBorders(e,t),r>0&&this.drawSelectedRanges(e,t,{left:0,maxX:Or(g,r-1)+Or(v,r-1)}),o>0&&this.drawSelectedRanges(e,t,{left:m-o,right:m-1,minX:Or(g,m-o)+.5,maxX:Or(g,m-1)+Or(v,m-1)});for(var C=0;C<h.length;C+=1)for(var S=h[C],E=0;E<p.length;E+=1){var w=p[E];this.drawCellContent(e,t,S,w)}}}drawFloatingBorders(e,t){var{metrics:n,theme:i}=t,{floatingTopRowCount:a,floatingBottomRowCount:s,floatingLeftColumnCount:r,floatingRightColumnCount:o,rowCount:l,columnCount:c,visibleRowYs:h,visibleColumnXs:d,visibleRowHeights:u,visibleColumnWidths:m,maxX:p,maxY:g}=n,{floatingDividerOuterColor:v,floatingDividerInnerColor:f}=i;if(e.lineWidth=3,e.beginPath(),e.strokeStyle=v,a>0){var b=Or(h,a-1)+Or(u,a-1)+.5;e.moveTo(.5,b),e.lineTo(p-.5,b)}if(s>0){var C=Or(h,l-s)-.5;e.moveTo(.5,C),e.lineTo(p-.5,C)}if(r>0){var S=Or(d,r-1)+Or(m,r-1)+.5;e.moveTo(S,.5),e.lineTo(S,g-.5)}if(o>0){var E=Or(d,c-o)-.5;e.moveTo(E,.5),e.lineTo(E,g-.5)}if(e.stroke(),e.beginPath(),e.lineWidth=1,e.strokeStyle=f,a>0){var w=Or(h,a-1)+Or(u,a-1)+.5;e.moveTo(.5,w),e.lineTo(p-.5,w)}if(s>0){var y=Or(h,l-s)-.5;e.moveTo(.5,y),e.lineTo(p-.5,y)}if(r>0){var T=Or(d,r-1)+Or(m,r-1)+.5;e.moveTo(T,.5),e.lineTo(T,g-.5)}if(o>0){var O=Or(d,c-o)-.5;e.moveTo(O,.5),e.lineTo(O,g-.5)}e.stroke()}drawGridBackground(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.drawRowStripes(e,t),n&&(this.drawMouseColumnHover(e,t),this.drawMouseRowHover(e,t)),this.drawGridLines(e,t),this.drawCellBackgrounds(e,t);var{metrics:i}=t,{bottom:a,right:s,floatingBottomRowCount:r,floatingLeftColumnCount:o,floatingRightColumnCount:l,floatingTopRowCount:c,columnCount:h,rowCount:d,visibleRowHeights:u,visibleRowYs:m,visibleColumnXs:p,visibleColumnWidths:g,width:v,height:f}=i;this.drawSelectedRanges(e,t,{bottom:Math.min(a,d-r-1),right:Math.min(s,h-l-1),minX:o>0&&p.has(o+1)?Or(p,o+1):-10,minY:c>0&&m.has(c+1)?Or(m,c+1):-10,maxX:l>0&&p.has(h-l-1)?Or(p,h-l-1)+Or(g,h-l-1)-.5:v+10,maxY:r>0&&m.has(d-r-1)?Or(m,d-r-1)+Or(u,d-r-1)-.5:f+10})}drawRowStripes(e,t){var{metrics:n,theme:i}=t,{visibleRows:a}=n,{rowBackgroundColors:s}=i;s&&this.drawRowStripesForRows(e,t,a,s)}drawRowStripesForRows(e,t,n,i){for(var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:t.metrics.maxX,{theme:r,metrics:o,model:l}=t,{maxDepth:c,shadowBlur:h,shadowColor:d}=r,u=this.getCachedBackgroundColors(i,c),{visibleRowYs:m,visibleRowHeights:p}=o,g=new Map,v=[],f=[],b=(e,t)=>{var n=yr(l)?l.depthForRow(e):0,i=u[e%u.length],a=i[Math.min(n,i.length-1)];if(g.has(a)||g.set(a,[]),g.get(a).push(e),null!=t){var s=yr(l)?l.depthForRow(t):0;s<n?v.push(e):s>n&&f.push(t)}},C=0;C<n.length;C+=1){b(n[C],C>0?n[C-1]:void 0)}if(g.forEach(((t,n)=>{e.fillStyle=n,e.beginPath();for(var i=0;i<t.length;i+=1){var r=t[i],o=Or(m,r),l=Or(p,r);e.rect(a,o,s,l)}e.fill()})),v.length>0){e.save();var S=this.getCachedColorWithAlpha(d,.15),E=this.getCachedColorWithAlpha(d,0),w=e.createLinearGradient(0,0,0,h);w.addColorStop(0,S),w.addColorStop(1,E),e.fillStyle=w;for(var y=0;y<v.length;y+=1){var T=v[y],O=Or(m,T);e.translate(0,O),e.fillRect(a,0,s,h),e.translate(0,-O)}e.restore()}if(f.length>0){e.save();var M=this.getCachedColorWithAlpha(d,0),N=this.getCachedColorWithAlpha(d,.15),D=e.createLinearGradient(0,0,0,h);D.addColorStop(0,M),D.addColorStop(1,N),e.fillStyle=D;for(var x=0;x<f.length;x+=1){var R=f[x],I=Or(m,R)+Or(p,R)-h;e.translate(0,I),e.fillRect(a,0,s,h),e.translate(0,-I)}e.restore()}}drawMouseColumnHover(e,t){var{mouseX:n,mouseY:i,theme:a,metrics:s}=t;if(null!=n&&null!=i){var r=wr.getColumnAtX(n,s);if(null!=r&&a.columnHoverBackgroundColor){var{visibleColumnWidths:o,visibleColumnXs:l,maxY:c}=s;if(!(i>c)){var h=Or(l,r),d=Or(o,r);e.fillStyle=a.columnHoverBackgroundColor,e.fillRect(h,0,d,c)}}}}drawMouseRowHover(e,t){var{mouseX:n,mouseY:i,theme:a,metrics:s}=t;if(null!=n&&null!=i){var{maxX:r}=s;if(!(n>r)&&a.rowHoverBackgroundColor){var o=wr.getRowAtY(i,s);null!=o&&this.drawMouseRowHoverForRow(e,t,o)}}}drawFloatingMouseRowHover(e,t){var{mouseX:n,mouseY:i,theme:a,metrics:s}=t,{maxX:r,floatingTopRowCount:o,floatingBottomRowCount:l,rowCount:c,rowFooterWidth:h}=s;if(!(null==n||null==i||n>r+h)&&a.rowHoverBackgroundColor){var d=wr.getRowAtY(i,s);null!=d&&(d<o||c-l<=d)&&this.drawMouseRowHoverForRow(e,t,d)}}drawMouseRowHoverForRow(e,t,n){var{metrics:i,selectedRanges:a,theme:s}=t,{visibleRowHeights:r,visibleRowYs:o,maxX:l}=i,c=Or(o,n),h=Or(r,n);s.rowHoverBackgroundColor&&(e.fillStyle=s.rowHoverBackgroundColor);for(var d=0;d<a.length;d+=1){var{startRow:u,endRow:m}=a[d];if(null!=u&&null!=m&&u<=n&&m>=n){s.selectedRowHoverBackgroundColor&&(e.fillStyle=s.selectedRowHoverBackgroundColor);break}}e.fillRect(0,c,l,h)}drawGridLines(e,t){var{metrics:n,theme:i}=t,{visibleColumns:a,visibleRows:s}=n;this.drawGridLinesForItems(e,t,a,s,i.gridColumnColor,i.gridRowColor)}drawGridLinesForItems(e,t,n,i,a,s){(a||s)&&(e.lineWidth=1,e.beginPath(),a&&(e.strokeStyle=a,this.drawGridLinesForColumns(e,t,n)),s&&(e.strokeStyle=s,this.drawGridLinesForRows(e,t,i)),e.stroke())}drawGridLinesForColumns(e,t,n){for(var{metrics:i}=t,{visibleColumnXs:a,maxY:s}=i,r=0;r<n.length;r+=1){var o=Or(a,n[r])+.5;e.moveTo(o,0),e.lineTo(o,s)}}drawGridLinesForRows(e,t,n){for(var{metrics:i}=t,{visibleRowYs:a,maxX:s}=i,r=s,o=0;o<n.length;o+=1){var l=Or(a,n[o])+.5;e.moveTo(.5,l),e.lineTo(r-.5,l)}}drawCellBackgrounds(e,t){var{metrics:n}=t,{visibleColumns:i,visibleRows:a}=n;this.drawCellBackgroundsForItems(e,t,i,a)}drawCellBackgroundsForItems(e,t,n,i){e.save();for(var a=0;a<n.length;a+=1)for(var s=n[a],r=0;r<i.length;r+=1){var o=i[r],l=r+1<i.length?i[r+1]:void 0;this.drawCellBackground(e,t,s,o,l)}e.restore()}drawCellBackground(e,t,n,i,a){var{metrics:s,model:r,theme:o}=t,{firstColumn:l,modelColumns:c,modelRows:h,visibleColumnXs:d,visibleColumnWidths:u,visibleRowYs:m,visibleRowHeights:p}=s,g=Or(h,i),v=Or(c,n),f=r.backgroundColorForCell(v,g,o),b=n===l,C=yr(r)&&r.hasExpandableRows;if(f){var S=Or(d,n)+1,E=Or(m,i)+1,w=Or(u,n)-1,y=Or(p,i)-1;e.fillStyle=f,e.fillRect(S,E,w,y)}b&&C&&this.drawCellRowTreeDepthLines(e,t,i,a)}drawCellContents(e,t){for(var{metrics:n}=t,{visibleColumns:i}=n,a=0;a<i.length;a+=1){var s=i[a];this.drawColumnCellContents(e,t,s)}}drawColumnCellContents(e,t,n){var{metrics:i}=t,{visibleColumnXs:a,visibleColumnWidths:s,visibleRows:r,height:o}=i,l=Or(a,n),c=Or(s,n);e.save(),e.beginPath(),e.rect(l,0,c,o),e.clip();for(var h=0;h<r.length;h+=1){var d=r[h];this.drawCellContent(e,t,n,d)}e.restore()}drawCellContent(e,t,n,i){var{metrics:a,model:s,theme:r}=t,{firstColumn:o,fontWidths:l,modelColumns:c,modelRows:h,visibleColumnXs:d,visibleColumnWidths:u,visibleRowYs:m,visibleRowHeights:p}=a,{cellHorizontalPadding:g,treeDepthIndent:v,treeHorizontalPadding:f,textColor:b}=r,C=Or(d,n),S=Or(m,i),E=Or(u,n),w=Or(p,i),y=Or(h,i),T=Or(c,n),O=s.textForCell(T,y),M=n===o;if(O&&w>0){var N,D=s.textAlignForCell(T,y)||"left";e.textAlign=D;var x=s.colorForCell(T,y,r)||b;e.fillStyle=x;var R=0;yr(s)&&s.hasExpandableRows&&M&&(R=v*(s.depthForRow(i)+1)+f);var I=E-R,L=C+g,F=S+.5*w;L="right"===D?C+I-g:"center"===D?C+.5*I:C+g,L+=R;var k=null!==(N=l.get(e.font))&&void 0!==N?N:Yr.DEFAULT_FONT_WIDTH,A=this.getCachedTruncatedString(e,O,I-2*g,k);A&&e.fillText(A,L,F)}M&&yr(s)&&s.hasExpandableRows&&this.drawCellRowTreeMarker(e,t,i)}drawCellRowTreeMarker(e,t,n){var{metrics:i,model:a,mouseX:s,mouseY:r,theme:o}=t,{firstColumn:l,gridX:c,gridY:h,visibleColumnXs:d,visibleColumnWidths:u,visibleRowYs:m,visibleRowHeights:p,visibleRowTreeBoxes:g}=i,{treeMarkerColor:v,treeMarkerHoverColor:f}=o,b=Or(d,l),C=Or(u,l),S=Or(m,n),E=Or(p,n);if(yr(a)&&a.isRowExpandable(n)){var w=Or(g,n),y=null!=s&&null!=r&&s>=c+b&&s<=c+b+C&&r>=h+S&&r<=h+S+E?f:v;this.drawTreeMarker(e,t,b,S,w,y,a.isRowExpanded(n))}}drawTreeMarker(e,t,n,i,a,s,r){var{x1:o,y1:l,x2:c,y2:h}=a,d=r?"\u229f":"\u229e",u=n+.5*(o+c)+.5,m=i+.5*(l+h)+.5;e.fillStyle=s,e.textAlign="center",e.fillText(d,u,m)}drawCellRowTreeDepthLines(e,t,n,i){var{metrics:a,model:s,theme:r}=t;if(yr(s)){var o=s.depthForRow(n);if(0!==o){var{firstColumn:l,visibleColumnXs:c,visibleRowYs:h,visibleRowHeights:d}=a,{treeDepthIndent:u,treeHorizontalPadding:m,treeLineColor:p}=r,g=Or(c,l),v=Or(h,n),f=Or(d,n),b=void 0!==i?s.depthForRow(i):0,C=o>b?o-b:0;if(e.strokeStyle=p,e.lineWidth=1,o-C>0){e.beginPath();for(var S=0;S<o-C;S+=1){var E=g+S*u+.5*u+m+.5;e.moveTo(E,v),e.lineTo(E,v+f)}e.stroke()}if(C>0){e.beginPath();for(var w=o-C;w<o;w+=1){var y=g+w*u+.5*u+m+.5;e.moveTo(y,v),e.lineTo(y,v+Math.ceil(f/2)),e.moveTo(y-.5,v+Math.ceil(f/2)+.5),e.lineTo(y+u-.5,v+Math.ceil(f/2)+.5)}e.stroke()}}}}drawHeaders(e,t){var{theme:n}=t;e.font=n.headerFont,this.drawColumnHeaders(e,t),this.drawRowHeaders(e,t)}drawFooters(e,t){var{theme:n}=t;e.font=n.headerFont,this.drawRowFooters(e,t)}drawColumnHeaders(e,t){var{mouseX:n,mouseY:i,theme:a,metrics:s,draggingColumnSeparator:r,isDragging:o}=t,{columnHeaderHeight:l,floatingColumns:c,gridX:h,width:d,visibleColumns:u,visibleColumnWidths:m,visibleColumnXs:p,floatingLeftColumnCount:g}=s;if(!(l<=0)){var{headerBackgroundColor:v,headerColor:f,headerHiddenSeparatorSize:b,headerHiddenSeparatorHoverColor:C,headerSeparatorColor:S,headerSeparatorHoverColor:E}=a,w=.5*l,y=.5*l-.5*w,T=g>0,O=0;e.save(),e.beginPath(),e.fillStyle=v,e.fillRect(0,0,d,l),e.fillStyle=f;for(var M=0;M<u.length;M+=1){var N=u[M],D=Or(m,N),x=Or(p,N)+h;this.drawColumnHeader(e,t,N,x,D)}if(T){O=Or(p,g-1)+Or(m,g-1),e.fillStyle=v,e.fillRect(h,0,O,l),e.fillStyle=f;for(var R=0;R<c.length;R+=1){var I=c[R],L=Or(m,I),F=Or(p,I)+h;this.drawColumnHeader(e,t,I,F,L)}}if(S){e.strokeStyle=S,e.beginPath();for(var k=[],A=!1,P=0;P<u.length;P+=1){var _=u[P],H=Or(p,_),j=Or(m,_);if(!(H<O-j))if(j>0){var V=h+H+j+.5;e.moveTo(V,0),e.lineTo(V,l-.5),A=!1}else A||(A=!0,k.push(_))}A=!1;for(var z=0;z<c.length;z+=1){var U=c[z],B=Or(p,U),W=Or(m,U);if(W>0){var G=h+B+W+.5;e.moveTo(G,0),e.lineTo(G,l-.5),A=!1}else A||(A=!0,k.push(U))}e.moveTo(0,l-.5),e.lineTo(d,l-.5),e.stroke(),e.beginPath(),e.fillStyle=S;for(var q=0;q<k.length;q+=1){var K=k[q],Y=h+Or(p,K)+Or(m,K)+.5-.5*b;e.rect(Y,y,b,w)}e.fill()}if(E){var X=r;if(null==X&&null!=n&&null!=i&&(X=wr.getColumnSeparatorIndex(n,i,s,a)),null!=X&&(!o||null!=r)){e.strokeStyle=E;var Z=Or(p,X),$=Or(m,X),Q=h+Z+$+.5,J=u.indexOf(X),ee=J<u.length-1?u[J+1]:null,te=null!=ee?m.get(ee):null,ne=null!=te&&0===te;0===$?(e.strokeStyle=C,e.fillStyle=C,e.fillRect(Q,y,.5*b,w)):ne&&(e.fillStyle=E,e.fillRect(Q-.5*b,y,.5*b,w)),e.beginPath(),e.moveTo(Q,0),e.lineTo(Q,l-1),e.stroke()}}e.restore()}}drawColumnHeader(e,t,n,i,a){if(!(a<=0)){var{metrics:s,model:r,theme:o}=t,{modelColumns:l}=s,c=Or(l,n),h=r.textForColumnHeader(c),{headerHorizontalPadding:d}=o,{columnHeaderHeight:u,fontWidths:m}=s,p=(a-2*d)/(m.get(e.font)||Yr.DEFAULT_FONT_WIDTH);if(!(p<=0)){if(e.save(),e.beginPath(),e.rect(i,0,a,u),e.clip(),h.length>p){h="".concat(h.substring(0,p-1),"\u2026");var g=i+d,v=.5*u;e.textAlign="left",e.fillText(h,g,v)}else{var f=i+.5*a,b=.5*u;e.textAlign="center",e.fillText(h,f,b)}e.restore()}}}drawRowHeaders(e,t){var{mouseX:n,mouseY:i,metrics:a,theme:s,draggingRowSeparator:r}=t,{gridY:o,rowHeaderWidth:l,height:c,visibleRows:h,visibleRowHeights:d,visibleRowYs:u}=a;if(!(l<=0)){var{headerBackgroundColor:m,headerColor:p,headerHiddenSeparatorSize:g,headerHiddenSeparatorHoverColor:v,headerSeparatorColor:f,headerSeparatorHoverColor:b}=s,C=.5*l,S=.5*l-.5*C;if(e.save(),e.beginPath(),e.fillStyle=m,e.fillRect(0,0,l,c),f){e.strokeStyle=f,e.beginPath(),e.moveTo(0,o+.5),e.lineTo(l,o+.5);for(var E=[],w=!1,y=0;y<h.length;y+=1){var T=h[y],O=Or(u,T),M=Or(d,T);if(M>0){var N=o+O+M+.5;e.moveTo(0,N),e.lineTo(l,N),w=!1}else w||(w=!0,E.push(T))}e.moveTo(l-.5,0),e.lineTo(l-.5,c),e.stroke(),e.beginPath(),e.fillStyle=f;for(var D=0;D<E.length;D+=1){var x=E[D],R=o+Or(u,x)+Or(d,x)+.5-.5*g;e.rect(S,R,C,g)}e.fill()}if(b){var I=r;if(null==I&&null!=n&&null!=i&&(I=wr.getRowSeparatorIndex(n,i,a,s)),null!=I){e.strokeStyle=b;var L=Or(u,I),F=Or(d,I),k=o+L+F+.5,A=h.indexOf(I),P=A<h.length-1?h[A+1]:null,_=null!=P?d.get(P):null,H=null!=_&&0===_;0===F?(e.strokeStyle=v,e.fillStyle=v,e.fillRect(S,k,C,.5*g)):H&&(e.fillStyle=b,e.fillRect(S,k-.5*g,C,.5*g)),e.beginPath(),e.moveTo(.5,k),e.lineTo(l+.5,k),e.stroke()}}e.beginPath(),e.rect(0,o,l,c),e.clip(),e.fillStyle=p,e.textAlign="right";for(var j=0;j<h.length;j+=1){var V=h[j],z=Or(d,V),U=Or(u,V)+o;this.drawRowHeader(e,t,V,U,z)}e.restore()}}drawRowHeader(e,t,n,i,a){if(!(a<=0)){var{metrics:s,model:r,theme:o}=t,{modelRows:l,rowHeaderWidth:c}=s,h=Or(l,n),d=c-o.cellHorizontalPadding,u=i+.5*a;e.fillText(r.textForRowHeader(h),d,u)}}drawRowFooters(e,t){var{mouseX:n,mouseY:i,metrics:a,model:s,theme:r,draggingRowSeparator:o}=t,{gridY:l,gridX:c,maxX:h,modelRows:d,rowFooterWidth:u,height:m,verticalBarWidth:p,visibleRows:g,visibleRowHeights:v,visibleRowYs:f,width:b}=a;if(!(u<=0)){var{cellHorizontalPadding:C,headerBackgroundColor:S,headerColor:E,headerHiddenSeparatorSize:w,headerHiddenSeparatorHoverColor:y,headerSeparatorColor:T,headerSeparatorHoverColor:O}=r,M=.5*u,N=.5*u-.5*M,D=Math.min(c+h,b-u-p);if(e.save(),e.beginPath(),e.fillStyle=S,e.fillRect(D,l,u,m),T){e.strokeStyle=T,e.beginPath(),e.moveTo(D,l+.5),e.lineTo(u,l+.5);for(var x=[],R=!1,I=0;I<g.length;I+=1){var L=g[I],F=Or(f,L),k=Or(v,L);if(k>0){var A=l+F+k+.5;e.moveTo(D+.5,A),e.lineTo(D+u-.5,A),R=!1}else R||(R=!0,x.push(L))}e.moveTo(D+.5,l),e.lineTo(D+.5,m),e.stroke(),e.beginPath(),e.fillStyle=T;for(var P=0;P<x.length;P+=1){var _=x[P],H=l+Or(f,_)+Or(v,_)+.5-.5*w;e.rect(D+N,H,M,w)}e.fill()}if(O){var j=o;if(null==j&&null!=n&&null!=i&&(j=wr.getRowSeparatorIndex(n,i,a,r)),null!=j){e.strokeStyle=O;var V=Or(f,j),z=Or(v,j),U=l+V+z+.5,B=g.indexOf(j),W=B<g.length-1?g[B+1]:null,G=null!=W?v.get(W):null,q=null!=G&&0===G;0===z?(e.strokeStyle=y,e.fillStyle=y,e.fillRect(N,U,M,.5*w)):q&&(e.fillStyle=O,e.fillRect(N,U-.5*w,M,.5*w)),e.beginPath(),e.moveTo(D+.5,U),e.lineTo(D+u+.5,U),e.stroke()}}e.beginPath(),e.rect(D,l,u,m),e.clip(),e.fillStyle=E,e.textAlign="left";for(var K=D+C,Y=0;Y<g.length;Y+=1){var X=g[Y],Z=Or(v,X);if(Z>0){var $=Or(f,X)+l,Q=Or(d,X),J=$+.5*Z;e.fillText(s.textForRowFooter(Q),K,J)}}e.restore()}}drawSelectedRanges(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{cursorColumn:i,cursorRow:a,draggingRow:s,draggingColumn:r,editingCell:o,metrics:l,model:c,selectedRanges:h,theme:d}=t,{visibleColumnWidths:u,visibleColumnXs:m,visibleRowHeights:p,visibleRowYs:g,width:v,height:f}=l,{left:b=l.left,top:C=l.top,right:S=l.right,bottom:E=l.bottom,minY:w=-10,maxY:y=f+10,minX:T=-10,maxX:O=v+10}=n;if(0!==h.length){var M=Gr(c)&&c.isEditable&&null==o&&null==s&&null==r&&null!=i&&null!=a&&m.has(i)&&g.has(a);if(M){var N=Or(m,i),D=Or(g,a),x=Or(u,i),R=Or(p,a);e.save(),e.beginPath(),e.rect(0,0,v,f),e.rect(N,D,x,R),e.clip("evenodd")}e.beginPath();for(var I=0;I<h.length;I+=1){var L=h[I],F=null!==L.startColumn?L.startColumn:b,k=null!==L.startRow?L.startRow:C,A=null!==L.endColumn?L.endColumn:S,P=null!==L.endRow?L.endRow:E;if(P>=C&&E>=k&&A>=b&&S>=F){var _=F>=b&&m.has(F)?Math.round(Or(m,F))+.5:T,H=k>=C&&g.has(k)?Math.max(Math.round(Or(g,k))+.5,.5):w,j=A<=S&&m.has(A)?Math.round(Or(m,A)+Or(u,A))-.5:O,V=P<=E&&g.has(P)?Math.round(Or(g,P)+Or(p,P))-.5:y;e.rect(_,H,j-_,V-H)}e.fillStyle=d.selectionColor,e.fill(),e.save(),e.clip(),e.strokeStyle=d.selectionOutlineCasingColor,e.lineWidth=3,e.stroke(),e.restore(),e.strokeStyle=d.selectionOutlineColor,e.lineWidth=1,e.stroke()}M&&null!=i&&null!=a&&(e.restore(),this.drawActiveCell(e,t,i,a))}}drawActiveCell(e,t,n,i){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:Yr.ACTIVE_CELL_BORDER_WIDTH,{metrics:s,theme:r}=t,{visibleColumnWidths:o,visibleColumnXs:l,visibleRowHeights:c,visibleRowYs:h}=s,d=Or(l,n)-.5*a,u=Or(h,i)-.5*a,m=Or(o,n)+a,p=Or(c,i)+a;d<=0&&(m+=d-1,d=1),u<=0&&(p+=u-1,u=1);var{lineWidth:g}=e;e.beginPath(),e.lineWidth=a,e.strokeStyle=r.selectionOutlineColor,this.drawRoundedRect(e,d,u,m,p),e.stroke(),e.lineWidth=g}drawRoundedRect(e,t,n,i,a){var s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:Yr.DEFAULT_EDGE_RADIUS;e.beginPath(),e.moveTo(t+s,n),e.lineTo(t+i-s,n),e.quadraticCurveTo(t+i,n,t+i,n+s),e.lineTo(t+i,n+a-s),e.quadraticCurveTo(t+i,n+a,t+i-s,n+a),e.lineTo(t+s,n+a),e.quadraticCurveTo(t,n+a,t,n+a-s),e.lineTo(t,n+s),e.quadraticCurveTo(t,n,t+s,n),e.closePath()}drawDraggingColumn(e,t){var{draggingColumn:n,draggingColumnOffset:i,metrics:a,mouseX:s,theme:r}=t;if(null!=n&&null!=s){var{gridX:o,gridY:l,visibleColumnXs:c,visibleColumnWidths:h,height:d}=a,u=Or(c,n),m=Or(h,n)+1,{backgroundColor:p,font:g,headerFont:v,reorderOffset:f,shadowBlur:b,shadowColor:C}=r;e.save(),e.translate(o,0),e.fillStyle=p,e.fillRect(u,0,m,d),e.translate(s-u-o-(null!==i&&void 0!==i?i:0),l+f),e.save(),e.shadowColor=C,e.shadowBlur=b,e.fillStyle=p,e.fillRect(u,-l,m,d),e.restore(),e.beginPath(),e.rect(u,-l,m,d),e.clip(),e.font=g,this.drawGridBackground(e,t),this.drawColumnCellContents(e,t,n),e.translate(-o,-l),e.font=v,this.drawColumnHeaders(e,t),e.restore()}}drawDraggingRow(e,t){var{draggingRow:n,draggingRowOffset:i,metrics:a,mouseY:s,theme:r}=t;if(null!=n&&null!=s){var{gridX:o,gridY:l,visibleRowYs:c,visibleRowHeights:h,width:d}=a,u=Or(c,n),m=Or(h,n)+1,{backgroundColor:p,font:g,headerFont:v,reorderOffset:f,shadowBlur:b,shadowColor:C}=r;e.save(),e.translate(0,l),e.fillStyle=p,e.fillRect(0,u,d,m),e.translate(o+f,s-u-l-(null!==i&&void 0!==i?i:0)),e.save(),e.shadowColor=C,e.shadowBlur=b,e.fillStyle=p,e.fillRect(-o,u,d,m),e.restore(),e.beginPath(),e.rect(-o,u,d,m),e.clip(),e.font=g,this.drawGridBackground(e,t),this.drawCellContents(e,t),e.translate(-o,-l),e.font=v,this.drawRowHeaders(e,t),e.restore()}}drawScrollBars(e,t){var{isDraggingHorizontalScrollBar:n,isDraggingVerticalScrollBar:i,isDragging:a,metrics:s,mouseX:r,mouseY:o,theme:l}=t;if(!(l.scrollBarSize<=0)){var{rowHeaderWidth:c,columnHeaderHeight:h,width:d,height:u,handleHeight:m,handleWidth:p,scrollX:g,scrollY:v,hasHorizontalBar:f,hasVerticalBar:b,barWidth:C,barHeight:S}=s,{scrollBarBackgroundColor:E,scrollBarHoverBackgroundColor:w,scrollBarCasingColor:y,scrollBarCornerColor:T,scrollBarColor:O,scrollBarHoverColor:M,scrollBarActiveColor:N,scrollBarSize:D,scrollBarHoverSize:x,scrollBarCasingWidth:R}=l,I=null!=r&&null!=o&&r<=d&&o<=u,L=i||b&&!n&&!a&&null!=r&&null!=o&&r>=d-x&&o<=S+h&&I,F=n||f&&!i&&!a&&!L&&null!=r&&null!=o&&o>=u-x&&r<=C-c&&I,k=F?x:D,A=L?x:D;if(e.translate(c,h),f&&b&&(e.fillStyle=y,e.fillRect(d-c-D,u-h-D,D,D),e.fillStyle=T,e.fillRect(d-c-D+R,u-h-D+R,D-R,D-R)),f){var P=g,_=u-h-k;e.fillStyle=y,e.fillRect(0,_,C,k-R),e.fillStyle=F?w:E,e.fillRect(0,_+R,C,k-R),e.fillStyle=n?N:F?M:O,e.fillRect(P,_+R,p,k-R)}if(b){var H=d-c-A,j=v;e.fillStyle=y,e.fillRect(H,0,A-R,S),e.fillStyle=L?w:E,e.fillRect(H+R,0,A-R,S),e.fillStyle=i?N:L?M:O,e.fillRect(H+R,j,A-R,m)}e.translate(-c,-h)}}}Kr(Yr,"DEFAULT_FONT_WIDTH",10),Kr(Yr,"DEFAULT_EDGE_RADIUS",2),Kr(Yr,"ACTIVE_CELL_BORDER_WIDTH",2);var Xr=Yr;function Zr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var $r=class{constructor(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:5e3;Zr(this,"order",void 0),Zr(this,"cursor",null),this.order=e}onDown(e,t,n){return!1}onMove(e,t,n){return!1}onDrag(e,t,n){return!1}onLeave(e,t,n){return!1}onClick(e,t,n){return!1}onContextMenu(e,t,n){return!1}onDoubleClick(e,t,n){return!1}onUp(e,t,n){return!1}onWheel(e,t,n){return!1}};function Qr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Jr=class extends $r{constructor(){super(...arguments),Qr(this,"startPoint",void 0),Qr(this,"hasExtendedFloating",!1),Qr(this,"timer",void 0),Qr(this,"lastTriggerTime",void 0),Qr(this,"dragBounds",void 0)}onDown(e,t,n){var{x:i,y:a,column:s,row:r}=e,{metrics:o}=t;if(!o)throw new Error("metrics not set");var{gridX:l,gridY:c,maxX:h,maxY:d}=o,u=i-l,m=a-c;if(u<0||m<0||null==s&&u>h||null==r&&m>d)return!1;var p=wr.isModifierKeyDown(n),g=n.shiftKey;p||(g?t.trimSelectedRanges():t.clearSelectedRanges());var v=t.getTheme(),{autoSelectRow:f,autoSelectColumn:b}=v;return null===s&&b||null===r&&f||(t.focus(),t.moveCursorToPosition(s,r,g,!0,g&&p)),this.startPoint=e,this.hasExtendedFloating=!1,this.dragBounds=wr.getScrollDragBounds(o,r,s),!0}onDrag(e,t){if(void 0===this.startPoint)return!1;this.stopTimer();var{row:n,column:i}=this.startPoint,{x:a,y:s}=e,{row:r,column:o}=e,{metrics:l}=t;if(!l)throw new Error("metrics not set");var{left:c,lastLeft:h,top:d,lastTop:u,columnWidth:m,rowHeight:p}=l,g=wr.getScrollDragBounds(l,n,i),v=0,f=0;if(c<h&&(a<g.x1?v=a-g.x1:a>g.x2&&(v=a-g.x2)),d<u&&(s<g.y1?f=s-g.y1:s>g.y2&&(f=s-g.y2)),0!==v||0!==f)this.startTimer(t,e,v>0?Math.ceil(v/m):Math.floor(v/m),f>0?Math.ceil(f/p):Math.floor(f/p));else if(null!=r&&null!=o){var{floatingTopRowCount:b,floatingBottomRowCount:C,floatingLeftColumnCount:S,floatingRightColumnCount:E,columnCount:w,rowCount:y,bottom:T,right:O,topVisible:M,bottomVisible:N,leftVisible:D,rightVisible:x}=l;this.hasExtendedFloating||(null!==n&&n<b&&r>=b?(r=b,this.hasExtendedFloating=!0):null!==n&&n>=y-C&&r<y-C&&(r=y-C-1,this.hasExtendedFloating=!0),null!==i&&i<S&&o>=S?(o=S,this.hasExtendedFloating=!0):null!==i&&i>=w-E&&o<w-E&&(o=w-E-1,this.hasExtendedFloating=!0)),null!==n&&!wr.isFloatingRow(n,l)&&wr.isFloatingRow(r,l)&&(n>r&&r<d?r=M-1:n<r&&r>T&&(r=N+1)),null!==i&&!wr.isFloatingColumn(i,l)&&wr.isFloatingColumn(o,l)&&(i>o&&o<c?o=D-1:i<o&&o>O&&(o=x+1)),t.moveCursorToPosition(o,r,!0,!0)}return!0}onUp(e,t){return void 0!==this.startPoint&&(this.startPoint=void 0,this.dragBounds=void 0,this.stopTimer(),t.commitSelection()),!1}moveSelection(e,t,n,i){var{row:a,column:s}=t,{metrics:r}=e;if(!r)throw new Error("metrics not set");var{selectionEndRow:o,selectionEndColumn:l}=e.state;if(null==o||null==l)throw new Error("selection not set");var{rowCount:c,columnCount:h}=r,d=n<0&&null!=s?s:0,u=n>0&&null!=s?s:h-1,m=i<0&&null!=a?a:0,p=i>0&&null!=a?a:c-1;e.moveCursorToPosition(Math.min(Math.max(d,l+n),u),Math.min(Math.max(m,o+i),p),!0),this.lastTriggerTime=Date.now()}startTimer(e,t,n,i){this.stopTimer();var a=null!=this.lastTriggerTime?100-Math.min(100,Date.now()-this.lastTriggerTime):0;this.timer=setTimeout((()=>{this.moveSelection(e,t,n,i),this.startTimer(e,t,n,i)}),a)}stopTimer(){void 0!==this.timer&&(clearTimeout(this.timer),this.timer=void 0)}};function eo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var to=class extends $r{constructor(){super(...arguments),eo(this,"cursor",null),eo(this,"draggingOffset",void 0),eo(this,"startingGridPoint",void 0),eo(this,"sloppyClickThreshold",!1)}onDown(e,t){var{model:n}=t.props,{x:i,y:a,column:s}=e,{metrics:r}=t;if(!r)throw new Error("Metrics not set");var{columnHeaderHeight:o,rowHeaderWidth:l,visibleColumnXs:c}=r;if(this.startingGridPoint=e,this.sloppyClickThreshold=!1,this.cursor=null,null!=s&&a<=o&&n.isColumnMovable(s)){var h=Or(c,s);this.draggingOffset=i-h-l,t.setState({draggingColumnOffset:this.draggingOffset})}return!1}onDrag(e,t){if(void 0===this.draggingOffset||void 0===this.startingGridPoint)return!1;var{model:n}=t.props,{draggingColumn:i}=t.state,{mouseX:a,mouseY:s,isDragging:r}=t.state;if(null==a||null==s)return!1;if(!this.sloppyClickThreshold&&Math.abs(this.startingGridPoint.x-a)>=5||Math.abs(this.startingGridPoint.y-s)>=5)this.sloppyClickThreshold=!0;else if(!this.sloppyClickThreshold&&!r)return!1;if(null==i){var{column:o}=t.getGridPointFromXY(a,s);if(null!=o&&!n.isColumnMovable(o))return!1;if(i=o,t.setState({draggingColumn:i,isDragging:!0}),null==i)return!1}this.cursor="move";var{metrics:l}=t;if(!l)throw new Error("Metrics not set");var{left:c,lastLeft:h,right:d,rightVisible:u,columnCount:m,rowHeaderWidth:p,visibleColumnWidths:g,visibleColumnXs:v,width:f}=l,b=p;if(c<i){var C=i-1;b=Or(v,C)+.5*Or(g,C)+this.draggingOffset+p}var S=f;if(i<d){var E=i+1;S=Or(v,E)+.5*Or(g,E)-Or(g,i)+this.draggingOffset+p}var{movedColumns:w}=t.state;a<b&&i>0&&n.isColumnMovable(i-1)?(w=wr.moveItem(i,i-1,w),i-=1):S<a&&i<m-1&&n.isColumnMovable(i+1)&&(w=wr.moveItem(i,i+1,w),i+=1),t.setState({movedColumns:w,draggingColumn:i});var y=p+.5*Or(g,c),T=p+Or(v,u)+.5*Or(g,u);return a<y&&c>0?t.setState({left:c-1}):a>T&&c<h&&t.setState({left:c+1}),!0}onUp(e,t){return this.cursor=null,null!=this.draggingOffset&&(this.draggingOffset=void 0,t.setState({draggingColumnOffset:null,draggingColumn:null,isDragging:!1}),!0)}};function no(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var io=class extends $r{constructor(){super(...arguments),no(this,"draggingIndex",void 0),no(this,"resizingItems",[]),no(this,"hiddenItems",[]),no(this,"targetSizes",new Map),no(this,"dragOffset",0),no(this,"hiddenCursor",void 0),no(this,"defaultCursor",void 0),no(this,"pointProperty",void 0),no(this,"userSizesProperty",void 0),no(this,"visibleOffsetProperty",void 0),no(this,"visibleSizesProperty",void 0),no(this,"marginProperty",void 0),no(this,"calculatedSizesProperty",void 0),no(this,"modelIndexesProperty",void 0),no(this,"firstIndexProperty",void 0),no(this,"treePaddingProperty",void 0)}onDown(e,t){var n=this.getSeparatorIndex(e,t);if(null!=n){var{metrics:i}=t;if(!i)throw new Error("metrics not set");return this.dragOffset=0,this.draggingIndex=n,this.resizingItems=[n],this.hiddenItems=this.getHiddenItems(n,i).reverse(),this.targetSizes.clear(),this.addTargetSize(i,n),this.updateCursor(i,n),this.updateSeparator(t,n),!0}return!1}onMove(e,t){var n=this.getSeparatorIndex(e,t);if(null!=n){var{metrics:i}=t;if(!i)throw new Error("metrics not set");return this.updateCursor(i,n),!0}return!1}onDrag(e,t){if(null==this.draggingIndex)return!1;var n=e[this.pointProperty],{metricCalculator:i,metrics:a}=t;if(!a)throw new Error("metrics not set");for(var s=t.getTheme(),r=a[this.visibleOffsetProperty],o=a[this.marginProperty],l=a[this.calculatedSizesProperty],c=a[this.modelIndexesProperty],h=a[this.firstIndexProperty],d=a[this.treePaddingProperty],u=new Map,m=this.resizingItems[this.resizingItems.length-1];null!=m;){var p=n-o-Or(r,m)-this.dragOffset,g=Or(c,m),v=this.targetSizes.get(g),f=this.resizingItems.length>1,b=this.hiddenItems.indexOf(m),C=Or(l,g);m===h&&(C+=d);var S,E=p;if(Math.abs(p-C)<=s.headerResizeSnapThreshold?E=null:void 0!==v&&p>v&&(f&&0!==b||b>0)?E=v:p<=s.headerResizeHiddenSnapThreshold&&(E=0),E!==C?u.set(g,E):u.set(g,null),p<-s.headerResizeSnapThreshold&&0===E)if(b>=0&&f)this.resizingItems.pop(),this.removeTargetSize(a,m),m=this.resizingItems[this.resizingItems.length-1],this.dragOffset-=null!==(S=this.targetSizes.get(Or(c,m)))&&void 0!==S?S:0;else null!==(m=this.getNextShownItem(m,a))&&(this.resizingItems.push(m),this.addTargetSize(a,m));else void 0!==v&&p>v+s.headerResizeSnapThreshold&&E===v?b>0?(this.dragOffset+=E,m=this.hiddenItems[b-1],this.resizingItems.push(m),this.addTargetSize(a,m)):f?(this.resizingItems.pop(),this.removeTargetSize(a,m),m=this.resizingItems[this.resizingItems.length-1]):m=null:m=null}return u.forEach(((e,t)=>{null!==e?this.setSize(i,t,e):this.resetSize(i,t)})),this.updateCursor(a,this.draggingIndex),!0}onUp(e,t){return null!=this.draggingIndex&&(this.draggingIndex=void 0,this.resizingItems=[],this.hiddenItems=[],this.targetSizes.clear(),this.updateSeparator(t,null)),!1}onDoubleClick(e,t){var n=this.getSeparatorIndex(e,t);if(null!=n){var{metricCalculator:i,metrics:a}=t;if(!a)throw new Error("metrics not set");var s=Or(a[this.modelIndexesProperty],n);return this.resetSize(i,s),t.forceUpdate(),!0}return!1}updateCursor(e,t){var n=Or(e[this.visibleSizesProperty],t);this.cursor=0===n?this.hiddenCursor:this.defaultCursor}addTargetSize(e,t){var n=e[this.modelIndexesProperty],i=e[this.userSizesProperty],a=e[this.calculatedSizesProperty],s=0===t?e[this.treePaddingProperty]:0,r=Or(n,t),o=i.get(r);null!=o&&0!==o||(o=Or(a,r)+s),this.targetSizes.set(r,o)}removeTargetSize(e,t){var n=Or(e[this.modelIndexesProperty],t);this.targetSizes.delete(n)}};function ao(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class so extends io{constructor(){super(...arguments),ao(this,"hiddenCursor","e-resize"),ao(this,"defaultCursor","col-resize"),ao(this,"pointProperty","x"),ao(this,"userSizesProperty","userColumnWidths"),ao(this,"visibleOffsetProperty","visibleColumnXs"),ao(this,"visibleSizesProperty","visibleColumnWidths"),ao(this,"marginProperty","rowHeaderWidth"),ao(this,"calculatedSizesProperty","calculatedColumnWidths"),ao(this,"modelIndexesProperty","modelColumns"),ao(this,"firstIndexProperty","firstColumn"),ao(this,"treePaddingProperty","treePaddingX"),ao(this,"getHiddenItems",wr.getHiddenColumns),ao(this,"getNextShownItem",wr.getNextShownColumn),ao(this,"getSeparatorIndex",so.getColumnSeparatorIndex)}static getColumnSeparatorIndex(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=t.getTheme();if(n&&!i.allowColumnResize)return null;var{x:a,y:s}=e,{metrics:r}=t;if(!r)throw new Error("metrics not set");return wr.getColumnSeparatorIndex(a,s,r,i)}setSize(e,t,n){e.setColumnWidth(t,n)}resetSize(e,t){e.resetColumnWidth(t)}updateSeparator(e,t){e.setState({draggingColumnSeparator:t,isDragging:null!==t})}}var ro=so;function oo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class lo extends $r{constructor(){super(...arguments),oo(this,"dragOffset",void 0),oo(this,"cursor","default")}static getLeftWithOffsetFromRawLeft(e,t){var n=e.getTheme(),{metrics:i,metricCalculator:a}=e;if(!i)throw new Error("metrics not set");if(n.scrollSnapToColumn){return{left:Math.round(t),leftOffset:0}}var s=Math.floor(t),r=t-s,o=i.visibleColumnWidths.get(s);if(null==o){var l=e.getMetricState();o=a.getVisibleColumnWidth(s,l)}return{left:s,leftOffset:o*r}}isInScrollBar(e,t){var n=t.getTheme(),{scrollBarSize:i,scrollBarHoverSize:a}=n,{metrics:s}=t;if(!s)throw new Error("metrics not set");var{x:r,y:o}=e,{lastLeft:l,lastTop:c,rowHeaderWidth:h,width:d,height:u}=s;return i>0&&l>0&&o>=u-a&&o<u&&r>h&&r<(c>0?d-i:d)}onDown(e,t){var{metrics:n}=t;if(!n)throw new Error("metrics not set");var{x:i}=e,{barWidth:a,handleWidth:s,lastLeft:r,rowHeaderWidth:o,scrollX:l}=n;if(!this.isInScrollBar(e,t))return!1;var c=i-o;if(c>=l&&c<=l+s)this.dragOffset=c-l,t.setState({isDraggingHorizontalScrollBar:!0});else{this.dragOffset=0;var h=Math.min(Math.max(0,c/(a-s)*r),r),{left:d,leftOffset:u}=lo.getLeftWithOffsetFromRawLeft(t,h);t.setViewState({left:d,leftOffset:u,isDraggingHorizontalScrollBar:!0,isDragging:!0})}return!0}onDrag(e,t){if(null!=this.dragOffset){var{x:n}=e,{metrics:i}=t;if(!i)throw new Error("metrics not set");var{barWidth:a,handleWidth:s,lastLeft:r,rowHeaderWidth:o}=i,l=n-o,c=Math.min(Math.max(0,(l-this.dragOffset)/(a-s)*r),r),{left:h,leftOffset:d}=lo.getLeftWithOffsetFromRawLeft(t,c);return t.setViewState({left:h,leftOffset:d,isDraggingHorizontalScrollBar:!0,isDragging:!0}),!0}return!1}onMove(e,t){return this.isInScrollBar(e,t)}onUp(e,t){return void 0!==this.dragOffset&&(this.dragOffset=void 0,t.setState({isDraggingHorizontalScrollBar:!1,isDragging:!1})),this.isInScrollBar(e,t)}onClick(e,t){return this.isInScrollBar(e,t)}}var co=lo;function ho(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uo=class extends $r{constructor(){super(...arguments),ho(this,"cursor","move"),ho(this,"draggingOffset",void 0)}onDown(e,t){var{model:n}=t.props,{x:i,y:a,row:s}=e,{metrics:r}=t;if(!r)throw new Error("metrics not set");var{columnHeaderHeight:o,rowHeaderWidth:l,visibleRowYs:c}=r;if(i<=l&&null!==s&&n.isRowMovable(s)){var h=Or(c,s);this.draggingOffset=a-h-o,t.setState({draggingRowOffset:this.draggingOffset})}return!1}onDrag(e,t){if(null==this.draggingOffset)return!1;var{model:n}=t.props,{draggingRow:i}=t.state,{mouseX:a,mouseY:s}=t.state;if(null==a||null==s)return!1;if(null==i){var{row:r}=t.getGridPointFromXY(a,s);if(null!=r&&!n.isRowMovable(r))return!1;if(i=r,t.setState({draggingRow:i,isDragging:!0}),null==i)return!1}var{metrics:o}=t;if(!o)throw new Error("metrics not set");var{top:l,lastTop:c,bottom:h,bottomVisible:d,rowCount:u,columnHeaderHeight:m,visibleRowHeights:p,visibleRowYs:g,height:v}=o,f=m;if(l<i){var b=i-1;f=Or(g,b)+.5*Or(p,b)+m}var C=v;if(i<h){var S=i+1;C=Or(g,S)+.5*Or(p,S)+m}var{movedRows:E}=t.state;s<f&&i>0&&n.isRowMovable(i-1)?(E=wr.moveItem(i,i-1,E),i-=1):C<s&&i<u-1&&n.isRowMovable(i+1)&&(E=wr.moveItem(i,i+1,E),i+=1),t.setState({movedRows:E,draggingRow:i});var w=m+.5*Or(p,l),y=m+Or(g,d)+.5*Or(p,d);return s<w&&l>0?t.setState({top:l-1}):s>y&&l<c&&t.setState({top:l+1}),!0}onUp(e,t){return void 0!==this.draggingOffset&&(this.draggingOffset=void 0,t.setState({draggingRowOffset:null,draggingRow:null,isDragging:!1}),!0)}};function mo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class po extends io{constructor(){super(...arguments),mo(this,"hiddenCursor","s-resize"),mo(this,"defaultCursor","row-resize"),mo(this,"pointProperty","y"),mo(this,"userSizesProperty","userRowHeights"),mo(this,"visibleOffsetProperty","visibleRowYs"),mo(this,"visibleSizesProperty","visibleRowHeights"),mo(this,"marginProperty","columnHeaderHeight"),mo(this,"calculatedSizesProperty","calculatedRowHeights"),mo(this,"modelIndexesProperty","modelRows"),mo(this,"firstIndexProperty","firstRow"),mo(this,"treePaddingProperty","treePaddingY"),mo(this,"getHiddenItems",wr.getHiddenRows),mo(this,"getNextShownItem",wr.getNextShownRow),mo(this,"getSeparatorIndex",po.getRowSeparatorIndex)}static getRowSeparatorIndex(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=t.getTheme();if(n&&!i.allowRowResize)return null;var{x:a,y:s}=e,{metrics:r}=t;if(!r)throw new Error("metrics not set");return wr.getRowSeparatorIndex(a,s,r,i)}setSize(e,t,n){e.setRowHeight(t,n)}resetSize(e,t){e.resetRowHeight(t)}updateSeparator(e,t){e.setState({draggingRowSeparator:t,isDragging:null!==t})}}var go=po;class vo extends $r{static isInTreeBox(e,t){var{column:n,row:i,x:a,y:s}=e,{metrics:r}=t;if(!r)throw new Error("metrics not set");var{gridX:o,gridY:l,firstColumn:c,visibleColumnXs:h,visibleColumnWidths:d,visibleRowHeights:u,visibleRowYs:m,visibleRowTreeBoxes:p}=r;if(n===c&&null!=i&&null!=p.get(i)&&a>o&&s>l){var g=Or(h,n),v=Or(d,n),f=Or(m,i),b=Or(u,i);if(a>=o+g&&a<=o+g+v&&s>=l+f&&s<=l+f+b)return!0}return!1}onDown(e,t){return vo.isInTreeBox(e,t)}onClick(e,t){if(vo.isInTreeBox(e,t)){var{row:n}=e;if(null!==n)return t.toggleRowExpanded(n),!0}return!1}}var fo=vo;var bo=class extends $r{isInCorner(e,t){var n=t.getTheme(),{scrollBarSize:i}=n,{metrics:a}=t;if(!a)throw new Error("metrics not set");var{x:s,y:r}=e,{lastLeft:o,lastTop:l,width:c,height:h}=a;return i>0&&l>0&&o>0&&s>=c-i&&r>=h-i&&s<=c&&r<=h}onDown(e,t){return this.isInCorner(e,t)}onUp(e,t){return this.isInCorner(e,t)}onClick(e,t){return this.isInCorner(e,t)}};function Co(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class So extends $r{constructor(){super(...arguments),Co(this,"dragOffset",void 0),Co(this,"cursor","default")}static getTopWithOffsetFromRawTop(e,t){var n=e.getTheme(),{metrics:i,metricCalculator:a}=e;if(!i)throw new Error("metrics not set");if(n.scrollSnapToRow){return{top:Math.round(t),topOffset:0}}var s=Math.floor(t),r=t-s,o=i.visibleRowHeights.get(s);if(null==o){var l=e.getMetricState();o=a.getVisibleRowHeight(s,l)}return{top:s,topOffset:o*r}}isInScrollBar(e,t){var n=t.getTheme(),{scrollBarSize:i,scrollBarHoverSize:a}=n,{metrics:s}=t;if(!s)throw new Error("metrics not set");var{x:r,y:o}=e,{lastLeft:l,lastTop:c,columnHeaderHeight:h,height:d,width:u}=s;return i>0&&c>0&&r>=u-a&&r<u&&o>h&&o<(l>0?d-i:d)}onDown(e,t){var{metrics:n}=t;if(!n)throw new Error("metrics not set");var{y:i}=e,{barHeight:a,handleHeight:s,lastTop:r,columnHeaderHeight:o,scrollY:l}=n;if(!this.isInScrollBar(e,t))return!1;var c=i-o;if(c>=l&&c<=l+s)this.dragOffset=c-l,t.setState({isDraggingVerticalScrollBar:!0});else{this.dragOffset=0;var h=Math.min(Math.max(0,c/(a-s)*r),r),{top:d,topOffset:u}=So.getTopWithOffsetFromRawTop(t,h);t.setViewState({top:d,topOffset:u,isDraggingVerticalScrollBar:!0,isDragging:!0})}return!0}onMove(e,t){return this.isInScrollBar(e,t)}onDrag(e,t){if(null!=this.dragOffset){var{y:n}=e,{metrics:i}=t;if(!i)throw new Error("metrics not set");var{barHeight:a,handleHeight:s,lastTop:r,columnHeaderHeight:o}=i,l=n-o,c=Math.min(Math.max(0,(l-this.dragOffset)/(a-s)*r),r),{top:h,topOffset:d}=So.getTopWithOffsetFromRawTop(t,c);return t.setViewState({top:h,topOffset:d,isDraggingVerticalScrollBar:!0,isDragging:!0}),!0}return!1}onUp(e,t){return void 0!==this.dragOffset&&(this.dragOffset=void 0,t.setState({isDraggingVerticalScrollBar:!1,isDragging:!1})),this.isInScrollBar(e,t)}onClick(e,t){return this.isInScrollBar(e,t)}}var Eo=So;var wo=class extends $r{onDoubleClick(e,t){var{column:n,row:i}=e,{model:a}=t.props;return!(!Gr(a)||null==n||null==i||!a.isEditableRange(fr.makeCell(n,i)))&&(t.startEditing(n,i),!0)}};n(864);var yo=class{constructor(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:5e3;!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"order",void 0),this.order=e}onDown(e,t){return!1}};var To=class extends yo{onDown(e,t){switch(e.key){case"a":if(wr.isModifierKeyDown(e))return t.selectAll(),!0;break;case"ArrowUp":return this.handleArrowMove(0,-1,e,t);case"ArrowDown":return this.handleArrowMove(0,1,e,t);case"ArrowRight":return this.handleArrowMove(1,0,e,t);case"ArrowLeft":return this.handleArrowMove(-1,0,e,t);case"k":case"PageUp":return this.handlePageUp(e,t);case"j":case"PageDown":return this.handlePageDown(e,t);case"h":return t.clearSelectedRanges(),t.moveCursorToPosition(0,t.state.cursorRow),!0;case"l":var{model:n}=t.props,{columnCount:i}=n;return t.clearSelectedRanges(),t.moveCursorToPosition(i-1,t.state.cursorRow),!0;case"Home":return e.shiftKey||t.clearSelectedRanges(),t.moveCursorToPosition(wr.isModifierKeyDown(e)?t.state.cursorColumn:0,wr.isModifierKeyDown(e)?0:t.state.cursorRow,e.shiftKey,!0,!0),!0;case"End":var{model:a}=t.props,{columnCount:s,rowCount:r}=a;return e.shiftKey||t.clearSelectedRanges(),t.moveCursorToPosition(wr.isModifierKeyDown(e)?t.state.cursorColumn:s-1,wr.isModifierKeyDown(e)?r-1:t.state.cursorRow,e.shiftKey,!0,!0),!0;case"Escape":return t.clearSelectedRanges(),!0;case"Enter":if(t.state.selectedRanges.length>0)return t.moveCursorInDirection(e.shiftKey?fr.SELECTION_DIRECTION.UP:fr.SELECTION_DIRECTION.DOWN),!0;break;case"Tab":if(t.state.selectedRanges.length>0)return t.moveCursorInDirection(e.shiftKey?fr.SELECTION_DIRECTION.LEFT:fr.SELECTION_DIRECTION.RIGHT),!0}return!1}handleArrowMove(e,t,n,i){var a=n.shiftKey,s=wr.isModifierKeyDown(n);a?i.trimSelectedRanges():i.clearSelectedRanges();var{cursorRow:r,cursorColumn:o,selectionEndColumn:l,selectionEndRow:c}=i.state,h=a?l:o,d=a?c:r;if(s){var{model:u}=i.props,{columnCount:m,rowCount:p}=u,g=s&&a,v=null,f=null;e<0?(v=0,f=d):e>0?(v=m-1,f=d):t<0?(v=h,f=0):t>0&&(v=h,f=p-1),null!=v&&null!=f&&i.moveCursorToPosition(v,f,a,!0,g)}else{if(!i.metrics)throw new Error("grid.metrics are not set");var{theme:b}=i.props,{autoSelectRow:C,autoSelectColumn:S}=b;if(C&&0!==e){var{lastLeft:E}=i.metrics,{left:w}=i.state;w=pr()(w+e,0,E),i.moveCursorToPosition(w,r,a,!1),i.setViewState({left:w})}else if(S&&0!==t){var{lastTop:y}=i.metrics,{top:T}=i.state;T=pr()(T+t,0,y),i.moveCursorToPosition(T,o,a,!1),i.setViewState({top:T})}else i.moveCursor(e,t,a)}return!0}handlePageUp(e,t){var n=e.shiftKey;n?t.trimSelectedRanges():t.clearSelectedRanges();var{cursorColumn:i,selectionEndRow:a}=t.state,s=a,r=i;if(null==s)return!1;var o=t.getMetricState(),{metricCalculator:l}=t,{bottomVisible:c,topVisible:h,hasHorizontalBar:d}=l.getMetrics(o),u=s-(c-h);u-=d?0:1,u=Math.max(u,0);var m=Math.max(u-(s-h),0);return t.moveCursorToPosition(r,u,n,!1),t.setViewState({top:m}),!0}handlePageDown(e,t){var n=e.shiftKey;n?t.trimSelectedRanges():t.clearSelectedRanges();var{selectionEndRow:i,cursorColumn:a}=t.state,s=i,r=a;if(null===s)return!1;var o=t.getMetricState(),{metricCalculator:l}=t,{bottomVisible:c,topVisible:h,hasHorizontalBar:d,rowCount:u,lastTop:m}=l.getMetrics(o),p=u-1,g=c-h+s;g+=d?0:1,g=Math.min(g,p);var v=Math.min(m,g-(s-h));return t.moveCursorToPosition(r,g,n,!1),t.setViewState({top:v}),!0}};var Oo=class extends yo{onDown(e,t){switch(e.key){case"Enter":case" ":return this.handleExpandKey(e,t)}return!1}handleExpandKey(e,t){var{selectedRanges:n}=t.state;if(1===n.length){var i=n[0];if(i.startRow===i.endRow&&i.startColumn===i.endColumn){if(!t.metrics)throw new Error("grid.metrics not set");var{model:a}=t.props,{startRow:s,startColumn:r}=i;if(null!=s){var o=t.getModelRow(s);if((0===r||null==r)&&yr(a)&&a.isRowExpandable(o))return t.toggleRowExpanded(s),!0}}}return!1}};var Mo=class extends yo{onDown(e,t){if(wr.isModifierKeyDown(e))return!1;var{model:n}=t.props,{cursorColumn:i,cursorRow:a}=t.state;if(null==i||null==a||!Gr(n)||!n.isEditableRange(fr.makeCell(i,a)))return!1;var s=i,r=a;return null!=s&&null!=r&&(1===e.key.length?(t.startEditing(s,r,!0,[1,1],e.key),!0):"F2"===e.key?(t.startEditing(s,r),!0):"Backspace"===e.key?(t.startEditing(s,r,!0,void 0,""),!0):"Delete"===e.key&&(t.setValueForCell(s,r,""),!0))}};var No=class extends yo{onDown(e,t){if("v"===e.key)if(wr.isModifierKeyDown(e)){var n=document.createElement("div");document.body.appendChild(n),n.setAttribute("contenteditable","true"),n.setAttribute("style",'clip-path: "inset(50%)"; height: 1px; width: 1px; margin: -1px; overflow: hidden; padding 0; position: absolute;');var i=()=>{n.removeEventListener("input",i),n.remove(),t.focus();var e=function(e){var t,n,i=e.querySelector("table");if(null!=i)return function(e){for(var t=[],n=e.querySelectorAll("tr"),i=0;i<n.length;i+=1){for(var a=n[i].querySelectorAll("td"),s=[],r=0;r<a.length;r+=1){var o,l,c=a[r];s.push(null!==(o=null===(l=c.textContent)||void 0===l?void 0:l.trim())&&void 0!==o?o:"")}t.push(s)}return t}(i);var a=null!==(t=null===(n=e.textContent)||void 0===n?void 0:n.trim())&&void 0!==t?t:"";if(a.length>0){var s,{childNodes:r}=e,o=a.includes("\t"),l=a.includes("\xa0\xa0 \xa0");return o&&0!==r.length&&(1===r.length||r.length>1&&(null===(s=r[0].textContent)||void 0===s||!s.includes("\t")))?a.split("\n").map((e=>e.split("\t"))):r.length>1||l?function(e){var t=[];return e.forEach((e=>{var n,i=null!==(n=e.textContent)&&void 0!==n?n:"";i.length>0&&t.push(i.split(/\t|\u00a0\u00a0 \u00a0/))})),t}(e.childNodes):a}return null}(n);null!=e&&t.pasteValue(e)};return n.addEventListener("input",i),n.focus(),{preventDefault:!1,stopPropagation:!0}}return!1}},Do=(n(865),e=>{var{selectionRange:t,className:n="",disabled:s=!1,value:r="",isQuickEdit:o=!0,onChange:l=(()=>{}),onCancel:c=(()=>{}),onDone:h=(()=>{}),onContextMenu:d=(()=>{}),style:u={}}=e,m=Object(i.useRef)(null),p=Object(i.useRef)(!1),[g]=Object(i.useState)(r),[v,f]=Object(i.useState)(!1),[b,C]=Object(i.useState)(o),[S,E]=Object(i.useState)(r);Object(i.useEffect)((()=>{var{current:e}=m;null!=e&&(e.focus(),t?e.setSelectionRange(t[0],t[1]):e.setSelectionRange(e.value.length,e.value.length))}),[t]);var w=Object(i.useCallback)((e=>{l(e)}),[l]),y=Object(i.useCallback)((e=>{var{value:t}=e.target;E(t),f(!0),w(t)}),[w,E,f]),T=Object(i.useCallback)((()=>{p.current=!0,v&&w(g),f(!1),c()}),[g,v,c,w]),O=Object(i.useCallback)((()=>{C(!1)}),[C]),M=Object(i.useCallback)((function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];h(S,{direction:e,fillRange:t})}),[h,S]),N=Object(i.useCallback)((()=>{p.current||M(null)}),[p,M]),D=Object(i.useCallback)((e=>{switch(e.stopPropagation(),e.key){case"Escape":e.preventDefault(),T();break;case"Enter":if(e.preventDefault(),wr.isModifierKeyDown(e))M(void 0,!0);else if(e.altKey){var t="".concat(S,"\n");E(t),f(!0),w(t)}else M(e.shiftKey?dr.UP:dr.DOWN);break;case"Tab":e.preventDefault(),M(e.shiftKey?dr.LEFT:dr.RIGHT);break;case"ArrowDown":case"ArrowUp":case"ArrowLeft":case"ArrowRight":b&&(e.preventDefault(),M((e=>{switch(e){case"ArrowDown":return dr.DOWN;case"ArrowUp":return dr.UP;case"ArrowLeft":return dr.LEFT;case"ArrowRight":return dr.RIGHT;default:return}})(e.key)))}}),[T,M,b,E,f,w,S]),x=Object(i.useCallback)((e=>{d(e)}),[d]);return a.a.createElement("textarea",{ref:m,className:qe()("grid-cell-input-field",n),value:S,onBlur:N,onChange:y,onKeyDown:D,onContextMenu:x,onClick:O,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",spellCheck:"false",disabled:s,style:u})});Do.propTypes={selectionRange:pi.a.arrayOf(pi.a.number),className:pi.a.string,disabled:pi.a.bool,isQuickEdit:pi.a.bool,value:pi.a.string,onChange:pi.a.func,onCancel:pi.a.func,onDone:pi.a.func,onContextMenu:pi.a.func,style:pi.a.shape({})},Do.defaultProps={selectionRange:null,className:"",disabled:!1,value:"",isQuickEdit:!0,onChange:()=>{},onCancel:()=>{},onDone:()=>{},onContextMenu:()=>{},style:{}};var xo=Do;function Ro(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function Io(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Lo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Io(Object(n),!0).forEach((function(t){Fo(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Io(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Fo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class ko extends i.PureComponent{static getScale(e){var t=e;return(window.devicePixelRatio||1)/(t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1)}static getCursorClassName(e){return e?"grid-cursor-".concat(e):null}constructor(e){super(e),Fo(this,"renderer",void 0),Fo(this,"metricCalculator",void 0),Fo(this,"canvas",void 0),Fo(this,"canvasContext",void 0),Fo(this,"animationFrame",void 0),Fo(this,"prevMetrics",void 0),Fo(this,"metrics",void 0),Fo(this,"isStuckToBottom",void 0),Fo(this,"isStuckToRight",void 0),Fo(this,"documentCursor",void 0),Fo(this,"dragTimer",void 0),Fo(this,"keyHandlers",void 0),Fo(this,"mouseHandlers",void 0),Fo(this,"getCachedKeyHandlers",Object(ua.a)((e=>[...e,...this.keyHandlers].sort(((e,t)=>e.order-t.order))))),Fo(this,"getCachedMouseHandlers",Object(ua.a)((e=>[...e,...this.mouseHandlers].sort(((e,t)=>e.order-t.order))))),this.handleClick=this.handleClick.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.handleEditCellCancel=this.handleEditCellCancel.bind(this),this.handleEditCellChange=this.handleEditCellChange.bind(this),this.handleEditCellCommit=this.handleEditCellCommit.bind(this),this.handleDoubleClick=this.handleDoubleClick.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMouseDown=this.handleMouseDown.bind(this),this.handleMouseDrag=this.handleMouseDrag.bind(this),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleMouseUp=this.handleMouseUp.bind(this),this.handleResize=this.handleResize.bind(this),this.handleWheel=this.handleWheel.bind(this);var{metricCalculator:t,movedColumns:n,movedRows:i,renderer:a}=e;this.renderer=a||new Xr,this.metricCalculator=t||new xr,this.canvas=null,this.canvasContext=null,this.animationFrame=null,this.prevMetrics=null,this.metrics=null,this.isStuckToBottom=!1,this.isStuckToRight=!1,this.documentCursor=null,this.dragTimer=null,this.keyHandlers=[new Mo(400),new No(450),new To(500),new Oo(900)],this.mouseHandlers=[new go(100),new ro(200),new uo(300),new to(400),new wo(450),new Eo(500),new co(600),new bo(700),new fo(800),new Jr(900)],this.state={top:0,left:0,topOffset:0,leftOffset:0,draggingColumn:null,draggingRow:null,draggingColumnOffset:null,draggingRowOffset:null,draggingColumnSeparator:null,draggingRowSeparator:null,isDraggingHorizontalScrollBar:!1,isDraggingVerticalScrollBar:!1,isDragging:!1,mouseX:null,mouseY:null,movedColumns:n,movedRows:i,cursorRow:null,cursorColumn:null,selectionStartRow:null,selectionStartColumn:null,selectionEndRow:null,selectionEndColumn:null,selectedRanges:[],lastSelectedRanges:[],cursor:null,editingCell:null}}componentDidMount(){var e;this.initContext(),null===(e=this.canvas)||void 0===e||e.addEventListener("wheel",this.handleWheel,{passive:!1}),window.addEventListener("resize",this.handleResize),this.updateCanvasScale(),this.updateCanvas()}componentDidUpdate(e,t){var{isStickyBottom:n,isStickyRight:i,movedColumns:a,movedRows:s,onMovedColumnsChanged:r,onMoveColumnComplete:o,onMovedRowsChanged:l,onMoveRowComplete:c}=this.props,{isStickyBottom:h,isStickyRight:d,movedColumns:u,movedRows:m}=e,{movedColumns:p,movedRows:g}=t,{draggingColumn:v,draggingRow:f,movedColumns:b,movedRows:C}=this.state;if(u!==a&&this.setState({movedColumns:a}),m!==s&&this.setState({movedRows:s}),p!==b&&r(b),null!=t.draggingColumn&&null==v&&o(b),g!==C&&l(C),null!=t.draggingRow&&null==f&&c(C),n!==h&&(this.isStuckToBottom=!1),i!==d&&(this.isStuckToRight=!1),this.updateMetrics(),this.requestUpdateCanvas(),this.metrics&&this.prevMetrics){var{bottomVisible:S,rightVisible:E,rowCount:w,columnCount:y,top:T,left:O,height:M,width:N}=this.metrics,{rowCount:D,columnCount:x,height:R,width:I}=this.prevMetrics,L=this.getMetricState();if(D!==w||M!==R){var F=this.metricCalculator.getLastTop(L);(this.isStuckToBottom&&S<w-1&&S>0&&T>0||T>F)&&this.setState({top:F})}if(x!==y||N!==I){var k=this.metricCalculator.getLastLeft(L);(this.isStuckToRight&&E<y-1&&E>0&&O>0||O>k)&&this.setState({left:k})}this.validateSelection()&&this.checkSelectionChange(t)}}componentWillUnmount(){var e;null!=this.animationFrame&&cancelAnimationFrame(this.animationFrame),null===(e=this.canvas)||void 0===e||e.removeEventListener("wheel",this.handleWheel),window.removeEventListener("mousemove",this.handleMouseDrag,!0),window.removeEventListener("mouseup",this.handleMouseUp,!0),window.removeEventListener("resize",this.handleResize),this.stopDragTimer()}getTheme(){var{theme:e}=this.props;return ko.getTheme(e)}getGridPointFromEvent(e){Ur(this.canvas);var t=this.canvas.getBoundingClientRect(),n=e.clientX-t.left,i=e.clientY-t.top;return this.getGridPointFromXY(n,i)}getGridPointFromXY(e,t){if(!this.metrics)throw new Error("metrics must be set");return wr.getGridPointFromXY(e,t,this.metrics)}getMetricState(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.state,t=this.getTheme(),{model:n,stateOverride:i}=this.props;if(!this.canvasContext||!this.canvas)throw new Error("Canvas and context must be defined to get metrics");var a=this.canvasContext,s=this.canvas.clientWidth,r=this.canvas.clientHeight,{left:o,top:l,leftOffset:c,topOffset:h,movedColumns:d,movedRows:u,isDraggingHorizontalScrollBar:m,isDraggingVerticalScrollBar:p}=e;return Lo({left:o,top:l,leftOffset:c,topOffset:h,width:s,height:r,context:a,theme:t,model:n,movedColumns:d,movedRows:u,isDraggingHorizontalScrollBar:m,isDraggingVerticalScrollBar:p},i)}getKeyHandlers(){var{keyHandlers:e}=this.props;return this.getCachedKeyHandlers(e)}getMouseHandlers(){var{mouseHandlers:e}=this.props;return this.getCachedMouseHandlers(e)}getModelColumn(e){var t,n,i=null===(t=this.metrics)||void 0===t||null===(n=t.modelColumns)||void 0===n?void 0:n.get(e);if(void 0===i)throw new Error("Unable to get ModelIndex for column ".concat(e));return i}getModelRow(e){var t,n,i=null===(t=this.metrics)||void 0===t||null===(n=t.modelRows)||void 0===n?void 0:n.get(e);if(void 0===i)throw new Error("Unable to get ModelIndex for row ".concat(e));return i}toggleRowExpanded(e){var t=this.getModelRow(e),{model:n}=this.props;yr(n)&&n.isRowExpandable(t)&&n.setRowExpanded(t,!n.isRowExpanded(t)),this.clearSelectedRanges(),this.commitSelection(),this.moveCursorToPosition(0,e),this.commitSelection(),this.isStuckToBottom=!1}setSelectedRanges(e){var{model:t}=this.props,{columnCount:n,rowCount:i}=t,{cursorRow:a,cursorColumn:s,selectedRanges:r}=this.state;if(this.setState({selectedRanges:e,lastSelectedRanges:r}),e.length>0){var o=fr.boundedRange(e[0],n,i),l=a,c=s;o.containsCell(s,a)||({row:l,column:c}=o.startCell()),this.setState({selectionStartColumn:o.startColumn,selectionStartRow:o.startRow,selectionEndColumn:o.endColumn,selectionEndRow:o.endRow,cursorColumn:c,cursorRow:l})}}initContext(){var{canvas:e}=this,{canvasOptions:t}=this.props;if(!e)throw new Error("Canvas not set");this.canvasContext=e.getContext("2d",t)}requestUpdateCanvas(){null==this.animationFrame&&(this.animationFrame=requestAnimationFrame((()=>{if(this.animationFrame=null,!this.metrics)throw new Error("Metrics not set");this.updateCanvas(this.metrics)})))}updateCanvas(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.updateMetrics();this.updateCanvasScale();var{onViewChanged:t}=this.props;t(e),this.drawCanvas(e)}updateCanvasScale(){var{canvas:e,canvasContext:t}=this;if(!e)throw new Error("canvas not set");if(!t)throw new Error("canvasContext not set");if(!e.parentElement)throw new Error("Canvas has no parent element");var n=ko.getScale(t),{width:i,height:a}=e.parentElement.getBoundingClientRect();e.style.width="".concat(Math.floor(i),"px"),e.style.height="".concat(Math.floor(a),"px"),e.width=Math.floor(i)*n,e.height=Math.floor(a)*n,t.scale(n,n)}updateMetrics(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.state;this.prevMetrics=this.metrics;var{metricCalculator:t}=this,n=this.getMetricState(e);return this.metrics=t.getMetrics(n),this.metrics}checkSelectionChange(e){var{selectedRanges:t}=e,{selectedRanges:n}=this.state;if(n!==t){var{onSelectionChanged:i}=this.props;i(n)}}validateSelection(){for(var{model:e}=this.props,{selectedRanges:t}=this.state,{columnCount:n,rowCount:i}=e,a=0;a<t.length;a+=1){var s=t[a];if(null!=s.endColumn&&s.endColumn>=n||null!=s.endRow&&s.endRow>=i)return this.setState({selectedRanges:[],lastSelectedRanges:[]}),!1}return!0}clearSelectedRanges(){var{selectedRanges:e}=this.state;this.setState({selectedRanges:[],lastSelectedRanges:e})}trimSelectedRanges(){var{selectedRanges:e}=this.state;e.length>0&&this.setState({selectedRanges:e.slice(e.length-1)})}beginSelection(e,t){this.setState({selectionStartColumn:e,selectionStartRow:t,selectionEndColumn:e,selectionEndRow:t,cursorColumn:e,cursorRow:t})}moveSelection(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];this.setState((a=>{var{selectedRanges:s,selectionStartRow:r,selectionStartColumn:o}=a,{theme:l}=this.props,{autoSelectRow:c,autoSelectColumn:h}=l;if(n&&s.length>0){var d,u,m,p,g=s[s.length-1],v=null,f=null,b=null,C=null;if(i)v=c?null:Math.min(null!==e&&void 0!==e?e:0,null!==(d=g.startColumn)&&void 0!==d?d:0),f=h?null:Math.min(null!==t&&void 0!==t?t:0,null!==(u=g.startRow)&&void 0!==u?u:0),b=c?null:Math.max(null!==e&&void 0!==e?e:0,null!==(m=g.endColumn)&&void 0!==m?m:0),C=h?null:Math.max(null!==t&&void 0!==t?t:0,null!==(p=g.endRow)&&void 0!==p?p:0);else v=g.startColumn,f=g.startRow,null==o&&null==r||(c||(v=o),h||(f=r)),b=c?null:e,C=h?null:t;var S=fr.makeNormalized(v,f,b,C);if(g.equals(S))return null;var E=[...s];return E[E.length-1]=S,{selectedRanges:E,selectionEndColumn:e,selectionEndRow:t}}var w=[...s],y=c?null:e,T=h?null:t;return w.push(fr.makeNormalized(y,T,y,T)),{selectedRanges:w,selectionEndColumn:e,selectionEndRow:t}}))}commitSelection(){this.setState((e=>{var{theme:t}=this.props,{autoSelectRow:n}=t,{selectedRanges:i,lastSelectedRanges:a,cursorRow:s,cursorColumn:r}=e;if(1===i.length&&(n?1===fr.rowCount(i):1===fr.cellCount(i))&&fr.rangeArraysEqual(i,a))return{selectedRanges:[],lastSelectedRanges:[],cursorColumn:r,cursorRow:s};var o=i.slice();if(o.length>1){for(var l=o[o.length-1],c=0;c<o.length-1;c+=1){var h=o[c];if(h.contains(l)){var d=h.subtract(l);o.pop(),o.splice(c,1),o=o.concat(d);break}}o=fr.consolidate(o)}var u=r,m=s;if(!fr.containsCell(o,r,s)){var{model:p}=this.props,{columnCount:g,rowCount:v}=p,f=fr.nextCell(fr.boundedRanges(i,g,v));null!=f?({column:u,row:m}=f):(u=null,m=null)}return{cursorRow:m,cursorColumn:u,selectedRanges:o,lastSelectedRanges:i}}))}selectAll(){var{model:e,theme:t}=this.props,{autoSelectRow:n,autoSelectColumn:i}=t,a=i?null:0,s=i?null:e.rowCount-1,r=n?null:0,o=n?null:e.columnCount-1;this.setSelectedRanges([new fr(r,a,o,s)])}moveCursor(e,t,n){var{cursorRow:i,cursorColumn:a,selectionEndColumn:s,selectionEndRow:r}=this.state,o=n?s:a,l=n?r:i;if(null===l||null===o){var{left:c,top:h}=this.state;this.moveCursorToPosition(c,h,n)}else{var{model:d}=this.props,{columnCount:u,rowCount:m}=d,p=pr()(o+e,0,u-1),g=pr()(l+t,0,m-1);this.moveCursorToPosition(p,g,n)}}moveCursorInDirection(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:fr.SELECTION_DIRECTION.DOWN,{model:t}=this.props,{columnCount:n,rowCount:i}=t,{cursorRow:a,cursorColumn:s,selectedRanges:r}=this.state,o=r.length>0?r:[fr.makeCell(s,a)],l=null;if(1===o.length&&1===fr.cellCount(o)){var c,h=new fr(0,0,n-1,i-1);l=null!==(c=h.nextCell(s,a,e))&&void 0!==c?c:h.startCell(e)}else l=fr.nextCell(fr.boundedRanges(o,n,i),s,a,e);if(null!=l){var{column:d,row:u}=l;this.setState({cursorColumn:d,cursorRow:u}),fr.containsCell(r,d,u)||this.setState({selectedRanges:[fr.makeCell(d,u)],selectionStartColumn:d,selectionStartRow:u,selectionEndColumn:d,selectionEndRow:u}),this.moveViewToCell(l.column,l.row)}}moveCursorToPosition(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=arguments.length>4&&void 0!==arguments[4]&&arguments[4];n||this.beginSelection(e,t),this.moveSelection(e,t,n,a),i&&this.moveViewToCell(e,t)}moveViewToCell(e,t){if(!this.metrics)throw new Error("metrics not set");var{metricCalculator:n}=this,{bottomVisible:i,rightVisible:a,topVisible:s,leftVisible:r}=this.metrics,o=this.getMetricState(this.state),{top:l,left:c,topOffset:h,leftOffset:d}=this.state;null==t||wr.isFloatingRow(t,this.metrics)||(t<s?(l=n.getTopForTopVisible(o,t),h=0):t>i&&(l=n.getTopForBottomVisible(o,t),h=0)),null==e||wr.isFloatingColumn(e,this.metrics)||(e<r?(c=n.getLeftForLeftVisible(o,e),d=0):e>a&&(c=n.getLeftForRightVisible(o,e),d=0)),this.setViewState({top:l,left:c,topOffset:h,leftOffset:d})}setViewState(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!this.metrics)throw new Error("metrics not set");var{isStickyBottom:n,isStickyRight:i}=this.props,{top:a,left:s}=e,{lastTop:r,lastLeft:o}=this.metrics;null!=a&&(this.isStuckToBottom=n&&a>=r),null!=s&&(this.isStuckToRight=i&&s>=o),this.setState(e),t&&this.forceUpdate()}startEditing(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0,a=arguments.length>4?arguments[4]:void 0,{model:s}=this.props;if(!Gr(s))throw new Error("model is not editable");var r=this.getModelColumn(e),o=this.getModelRow(t),l={column:e,row:t,selectionRange:i,value:void 0!==a?a:s.editValueForCell(r,o),isQuickEdit:n};this.setState({editingCell:l,cursorColumn:e,cursorRow:t}),this.moveViewToCell(e,t)}isValidForCell(e,t,n){var{model:i}=this.props,a=this.getModelColumn(e),s=this.getModelRow(t);return Gr(i)&&i.isValidForCell(a,s,n)}pasteValue(e){var t,n=this;return(t=function*(){var{model:t}=n.props,{movedColumns:i,movedRows:a,selectedRanges:s}=n.state;try{if(qr(t),!t.isEditable||!s.every((e=>t.isEditableRange(e))))throw new Wr("Can't paste in to read-only area.");if(s.length<=0)throw new Wr("Select an area to paste to.");if("string"===typeof e){var r=[],o=wr.getModelRanges(s,i,a);return fr.forEachCell(o,((t,n)=>{r.push({column:t,row:n,text:e})})),void(yield t.setValues(r))}var l=e.length,c=e[0].length,{columnCount:h,rowCount:d}=t,u=s;if(u.every((e=>{var t,n;return 1===fr.cellCount([e])&&(null!==(t=e.startColumn)&&void 0!==t?t:0)+c<=h&&(null!==(n=e.startRow)&&void 0!==n?n:0)+l<=d}))&&(u=u.map((e=>{var t,n;return new fr(e.startColumn,e.startRow,(null!==(t=e.startColumn)&&void 0!==t?t:0)+c-1,(null!==(n=e.startRow)&&void 0!==n?n:0)+l-1)})),n.setSelectedRanges(u)),!u.every((e=>fr.rowCount([e])===l&&fr.columnCount([e])===c)))throw new Wr("Copy and paste area are not same size.");var m=[];u.forEach((t=>{for(var n=0;n<c;n+=1)for(var i=0;i<l;i+=1){var a,s;m.push({column:(null!==(a=t.startColumn)&&void 0!==a?a:0)+n,row:(null!==(s=t.startRow)&&void 0!==s?s:0)+i,text:e[i][n]})}})),yield t.setValues(m)}catch(g){var{onError:p}=n.props;p(g)}},function(){var e=this,n=arguments;return new Promise((function(i,a){var s=t.apply(e,n);function r(e){Ro(s,i,a,r,o,"next",e)}function o(e){Ro(s,i,a,r,o,"throw",e)}r(void 0)}))})()}setValueForCell(e,t,n){var{model:i}=this.props;qr(i);var a=this.getModelColumn(e),s=this.getModelRow(t);return!!i.isValidForCell(a,s,n)&&(i.setValueForCell(a,s,n),!0)}setValueForRanges(e,t){var{model:n}=this.props,{movedColumns:i,movedRows:a}=this.state,s=wr.getModelRanges(e,i,a);Gr(n)&&n.setValueForRanges(s,t)}isSelected(e,t){for(var{selectedRanges:n}=this.state,i=0;i<n.length;i+=1){var a,s,r=n[i],o=null===r.startRow||r.startRow<=e&&e<=(null!==(a=r.endRow)&&void 0!==a?a:0),l=null===r.startColumn||r.startColumn<=t&&t<=(null!==(s=r.endColumn)&&void 0!==s?s:0);if(o&&l)return!0}return!1}addDocumentCursor(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.documentCursor!==ko.getCursorClassName(e)&&(this.documentCursor&&document.documentElement.classList.remove(this.documentCursor),this.documentCursor=ko.getCursorClassName(e),this.documentCursor&&document.documentElement.classList.add(this.documentCursor),document.documentElement.classList.add("grid-block-events"))}removeDocumentCursor(){this.documentCursor&&(document.documentElement.classList.remove(this.documentCursor),document.documentElement.classList.remove("grid-block-events"),this.documentCursor=null)}startDragTimer(e){this.stopDragTimer();var t=new MouseEvent("custom",e.nativeEvent);this.dragTimer=setTimeout((()=>{this.handleMouseDrag(t)}),ko.dragTimeout)}stopDragTimer(){this.dragTimer&&(clearTimeout(this.dragTimer),this.dragTimer=null)}drawCanvas(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.updateMetrics();if(!this.canvas)throw new Error("canvas is not set");if(!this.canvasContext)throw new Error("context not set");var{left:t,top:n,cursorColumn:i,cursorRow:a,draggingColumn:s,draggingColumnOffset:r,draggingColumnSeparator:o,draggingRow:l,draggingRowOffset:c,draggingRowSeparator:h,editingCell:d,isDraggingHorizontalScrollBar:u,isDraggingVerticalScrollBar:m,isDragging:p,mouseX:g,mouseY:v,selectedRanges:f}=this.state,{model:b,stateOverride:C}=this.props,{renderer:S}=this,E=this.canvasContext,w=this.getTheme(),y=Lo({left:t,top:n,width:this.canvas.clientWidth,height:this.canvas.clientHeight,context:E,theme:w,model:b,metrics:e,mouseX:g,mouseY:v,selectedRanges:f,draggingColumn:s,draggingColumnOffset:r,draggingColumnSeparator:o,draggingRow:l,draggingRowOffset:c,draggingRowSeparator:h,editingCell:d,isDraggingHorizontalScrollBar:u,isDraggingVerticalScrollBar:m,isDragging:p,cursorColumn:i,cursorRow:a},C);E.save(),S.drawCanvas(y),E.restore()}focus(){var e;null===(e=this.canvas)||void 0===e||e.focus()}isFocused(){return document.activeElement===this.canvas}handleClick(e){for(var t,n=this.getGridPointFromEvent(e),i=this.getMouseHandlers(),a=0;a<i.length;a+=1){if(i[a].onClick(n,this,e)){e.stopPropagation(),e.preventDefault();break}}null===(t=this.canvas)||void 0===t||t.focus()}handleContextMenu(e){for(var t=this.getGridPointFromEvent(e),n=this.getMouseHandlers(),i=0;i<n.length;i+=1){if(n[i].onContextMenu(t,this,e)){e.stopPropagation(),e.preventDefault();break}}}handleKeyDown(e){for(var t=this.getKeyHandlers(),n=0;n<t.length;n+=1){var i=t[n].onDown(e,this);if(i){var a,s,r=i;(null===(a=null===r||void 0===r?void 0:r.stopPropagation)||void 0===a||a)&&e.stopPropagation(),(null===(s=null===r||void 0===r?void 0:r.preventDefault)||void 0===s||s)&&e.preventDefault();break}}}notifyMouseHandlers(e,t){for(var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a=this.getGridPointFromEvent(t),s=this.getMouseHandlers(),r=null,o=0;o<s.length;o+=1){var l=s[o],c=l[e]&&l[e](a,this,t);if(c){var h,d;null!=l.cursor&&(({cursor:r}=l),i&&this.addDocumentCursor(r));var u=c;(null===(h=null===u||void 0===u?void 0:u.stopPropagation)||void 0===h||h)&&t.stopPropagation(),(null===(d=null===u||void 0===u?void 0:u.preventDefault)||void 0===d||d)&&t.preventDefault();break}}if(this.setState({cursor:r}),n){var{x:m,y:p}=a;this.setState({mouseX:m,mouseY:p})}}handleMouseDown(e){window.addEventListener("mousemove",this.handleMouseDrag,!0),window.addEventListener("mouseup",this.handleMouseUp,!0),null!=e.button&&0!==e.button||(this.notifyMouseHandlers("onDown",e),this.startDragTimer(e))}handleDoubleClick(e){this.notifyMouseHandlers("onDoubleClick",e)}handleMouseMove(e){this.notifyMouseHandlers("onMove",e)}handleMouseLeave(e){this.notifyMouseHandlers("onLeave",e,!1),this.setState({mouseX:null,mouseY:null})}handleMouseDrag(e){this.setState({isDragging:!0}),this.notifyMouseHandlers("onDrag",e,!0,!0),this.stopDragTimer()}handleMouseUp(e){window.removeEventListener("mousemove",this.handleMouseDrag,!0),window.removeEventListener("mouseup",this.handleMouseUp,!0),null!=e.button&&0!==e.button||(this.notifyMouseHandlers("onUp",e,!1),this.stopDragTimer(),this.removeDocumentCursor())}handleResize(){this.updateCanvasScale(),this.updateCanvas(),this.forceUpdate()}handleWheel(e){if(this.notifyMouseHandlers("onWheel",e),!e.defaultPrevented){var{metricCalculator:t,metrics:n}=this,i=this.getMetricState();if(!n)throw new Error("metrics not set");for(var{lastTop:a,lastLeft:s}=n,{top:r,left:o,topOffset:l,leftOffset:c}=n,h=this.getTheme(),{deltaX:d,deltaY:u}=wr.getScrollDelta(e,n.barWidth,n.barHeight,n.rowHeight,n.rowHeight);0!==d;){if(c+=d,d=0,c>0&&o>=s||c<0&&o<=0){c=0;break}if(c>0){var m,p=null!==(m=n.visibleColumnWidths.get(o))&&void 0!==m?m:t.getVisibleColumnWidth(o,i);c>=p?(d=c-p,c=0,o+=1):h.scrollSnapToColumn&&(c=0,o+=1)}else if(c<0){var g,v=null!==(g=n.visibleColumnWidths.get(o-1))&&void 0!==g?g:t.getVisibleColumnWidth(o-1,i);Math.abs(c)<=v&&h.scrollSnapToColumn?(c=0,o-=1):(d=c+v,c=0,o-=1)}}for(;0!==u;){if(l+=u,u=0,l>0&&r>=a||l<0&&r<=0){l=0;break}if(l>0){var f,b=null!==(f=n.visibleRowHeights.get(r))&&void 0!==f?f:t.getVisibleRowHeight(r,i);l>=b?(u=l-b,l=0,r+=1):h.scrollSnapToRow&&(l=0,r+=1)}else if(l<0){var C,S=null!==(C=n.visibleRowHeights.get(r-1))&&void 0!==C?C:t.getVisibleRowHeight(r-1,i);Math.abs(l)<=S&&h.scrollSnapToRow?(l=0,r-=1):(u=l+S,l=0,r-=1)}}this.setViewState({top:r,left:o,leftOffset:c,topOffset:l}),e.stopPropagation(),e.preventDefault()}}handleEditCellCancel(){this.setState({editingCell:null}),this.focus()}handleEditCellChange(e){this.setState((t=>{var{editingCell:n}=t;try{return Ur(n),{editingCell:Lo(Lo({},n),{},{value:e})}}catch(a){var{onError:i}=this.props;return i(a),null}}))}handleEditCellCommit(e){var{direction:t=dr.DOWN,fillRange:n=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{editingCell:i,selectedRanges:a}=this.state;if(!i)throw new Error("editingCell not set");var{column:s,row:r}=i;this.isValidForCell(s,r,e)?(n?this.setValueForRanges(a,e):this.setValueForCell(s,r,e),null!==t&&this.moveCursorInDirection(t),this.setState({editingCell:null}),this.focus()):null===t&&this.setState({editingCell:null})}renderInputField(){var{model:e}=this.props,{editingCell:t}=this.state,{metrics:n}=this;if(null==t||null==n||!Gr(e))return null;var{selectionRange:i,value:s,isQuickEdit:r}=t,{column:o,row:l}=t,{gridX:c,gridY:h,visibleColumnXs:d,visibleRowYs:u,visibleColumnWidths:m,visibleRowHeights:p}=n,g=d.get(o),v=u.get(l),f=m.get(o),b=p.get(l),C=null!=g&&null!=v&&null!=f&&null!=b?{position:"absolute",left:c+g,top:h+v,width:f,height:b}:{opacity:0},S=this.getModelColumn(o),E=this.getModelRow(l),w=null!=S&&null!=E?{textAlign:e.textAlignForCell(S,E)}:void 0,y=e.isValidForCell(S,E,s);return a.a.createElement("div",{style:C},a.a.createElement(xo,{key:"".concat(o,",").concat(l),selectionRange:i,className:qe()({error:!y}),onCancel:this.handleEditCellCancel,onChange:this.handleEditCellChange,onDone:this.handleEditCellCommit,isQuickEdit:r,style:w,value:s}))}render(){var{cursor:e}=this.state;return a.a.createElement(a.a.Fragment,null,a.a.createElement("canvas",{className:qe()("grid-canvas",ko.getCursorClassName(e)),ref:e=>{this.canvas=e},onClick:this.handleClick,onContextMenu:this.handleContextMenu,onDoubleClick:this.handleDoubleClick,onKeyDown:this.handleKeyDown,onMouseDown:this.handleMouseDown,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,tabIndex:0},"Your browser does not support HTML canvas. Update your browser?"),this.renderInputField())}}Fo(ko,"defaultProps",{canvasOptions:{alpha:!1},isStickyBottom:!1,isStickyRight:!1,keyHandlers:[],mouseHandlers:[],movedColumns:[],movedRows:[],onError:()=>{},onSelectionChanged:()=>{},onMovedColumnsChanged:()=>{},onMoveColumnComplete:()=>{},onMovedRowsChanged:()=>{},onMoveRowComplete:()=>{},onViewChanged:()=>{},stateOverride:{},theme:{autoSelectColumn:!1,autoSelectRow:!1}}),Fo(ko,"pixelsPerLine",100/3),Fo(ko,"dragTimeout",1e3),Fo(ko,"getTheme",Object(ua.a)((e=>Lo(Lo({},Rr),e))));var Ao=ko;class Po extends g.EventTarget{get floatingTopRowCount(){return 0}get floatingBottomRowCount(){return 0}get floatingLeftColumnCount(){return 0}get floatingRightColumnCount(){return 0}textAlignForCell(e,t){return"left"}colorForCell(e,t,n){return n.textColor}backgroundColorForCell(e,t,n){return null}textForColumnHeader(e){return""}textForRowHeader(e){return""}textForRowFooter(e){return""}isColumnMovable(e){return!0}isRowMovable(e){return!0}}var _o=Po;function Ho(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function jo(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Ho(s,i,a,r,o,"next",e)}function o(e){Ho(s,i,a,r,o,"throw",e)}r(void 0)}))}}function Vo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var zo=class extends _o{constructor(){var{rowCount:e=1e9,columnCount:t=100,floatingTopRowCount:n=0,floatingBottomRowCount:i=0,floatingLeftColumnCount:a=0,floatingRightColumnCount:s=0,isEditable:r=!1,editedData:o=[]}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super(),Vo(this,"numRows",void 0),Vo(this,"numColumns",void 0),Vo(this,"floatingTop",void 0),Vo(this,"floatingBottom",void 0),Vo(this,"floatingLeft",void 0),Vo(this,"floatingRight",void 0),Vo(this,"editable",void 0),Vo(this,"editedData",void 0),this.numRows=e,this.numColumns=t,this.floatingTop=n,this.floatingBottom=i,this.floatingLeft=a,this.floatingRight=s,this.editable=r,this.editedData=o}get rowCount(){return this.numRows}get columnCount(){return this.numColumns}get floatingTopRowCount(){return this.floatingTop}get floatingBottomRowCount(){return this.floatingBottom}get floatingLeftColumnCount(){return this.floatingLeft}get floatingRightColumnCount(){return this.floatingRight}get isEditable(){return this.editable}textForCell(e,t){var n,i;return null!==(n=null===(i=this.editedData[e])||void 0===i?void 0:i[t])&&void 0!==n?n:"".concat(e,",").concat(t)}colorForCell(e,t,n){return n.textColor}textForColumnHeader(e){return"".concat(e)}textForRowHeader(e){return"".concat(e)}textForRowFooter(e){return"".concat(e)}setValueForCell(e,t,n){var i=this;return jo((function*(){null==i.editedData[e]&&(i.editedData[e]=[]),i.editedData[e][t]="".concat(n)}))()}setValueForRanges(e,t){var n=this;return jo((function*(){fr.forEachCell(e,((e,i)=>{n.setValueForCell(e,i,t)}))}))()}setValues(e){var t=this;return jo((function*(){for(var n=0;n<e.length;n+=1){var i,a,s=e[n];t.setValueForCell(null!==(i=s.column)&&void 0!==i?i:s.x,null!==(a=s.row)&&void 0!==a?a:s.y,s.text)}}))()}editValueForCell(e,t){return this.textForCell(e,t)}isValidForCell(e,t,n){return!0}isEditableRange(e){return this.isEditable}delete(e){throw new Error("Method not implemented.")}};function Uo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Bo extends zo{constructor(){var{rowCount:e=Bo.DEFAULT_ROW_COUNT,columnCount:t=Bo.DEFAULT_COLUMN_COUNT,children:n=new Map,childRowCount:i=Math.ceil(Math.max(Bo.MIN_CHILD_ROW_COUNT,e*Bo.DEFAULT_CHILD_ROW_COUNT_FACTOR)),maxDepth:a=Bo.MAX_DEPTH}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super({rowCount:e,columnCount:t}),Uo(this,"children",void 0),Uo(this,"childRowCount",void 0),Uo(this,"maxDepth",void 0),Uo(this,"getCachedModelRowOffset",Pr(((e,t)=>{for(var n=null,i=t,a=[...e].sort(((e,t)=>e[0]-t[0])),s=0;s<a.length;s+=1){var[r,o]=a[s];if(i<=r)break;var l=o.rowCount;if(i<=r+l){n=r,i=i-r-1;break}i-=l}return{key:n,offsetRow:i}}))),Uo(this,"getCachedTextForRowHeader",Pr(((e,t)=>{var{key:n,offsetRow:i}=this.getCachedModelRowOffset(e,t);if(null!=n){var a=e.get(n);if(void 0!==a)return"".concat(n,".").concat(a.textForRowHeader(i))}return"".concat(i)}))),Uo(this,"getCachedTextForCell",Pr(((e,t,n)=>{var{key:i,offsetRow:a}=this.getCachedModelRowOffset(e,n);if(null!=i){var s=e.get(i);if(void 0!==s)return"".concat(i,".").concat(s.textForCell(t,a))}return"".concat(t,",").concat(a)}))),Uo(this,"getCachedIsRowExpandable",Pr(((e,t,n)=>this.getCachedDepthForRow(e,t)<n))),Uo(this,"getCachedIsRowExpanded",Pr(((e,t)=>{var{key:n,offsetRow:i}=this.getCachedModelRowOffset(e,t);if(null!=n){var a=e.get(n);if(void 0!==a)return a.isRowExpanded(i)}return e.has(i)}))),Uo(this,"getCachedDepthForRow",Pr(((e,t)=>{var{key:n,offsetRow:i}=this.getCachedModelRowOffset(e,t);if(null!=n){var a=e.get(n);if(void 0!==a)return a.depthForRow(i)+1}return 0}))),this.children=n,this.childRowCount=i,this.maxDepth=a}textForCell(e,t){return this.getCachedTextForCell(this.children,e,t)}textForRowHeader(e){return this.getCachedTextForRowHeader(this.children,e)}isRowMovable(e){return!1}get hasExpandableRows(){return!0}get floatingBottomRowCount(){return 0}isRowExpandable(e){return this.getCachedIsRowExpandable(this.children,e,this.maxDepth)}isRowExpanded(e){return this.getCachedIsRowExpanded(this.children,e)}setRowExpanded(e,t){var{key:n,offsetRow:i}=this.getCachedModelRowOffset(this.children,e),a=new Map(this.children);if(null!=n){var s=this.children.get(n);if(void 0!==s){var{rowCount:r}=s;s.setRowExpanded(i,t),this.numRows+=s.rowCount-r}}else if(t){var o=new Bo({rowCount:this.childRowCount,columnCount:this.numColumns});a.set(i,o),this.numRows+=o.rowCount}else{var l=a.get(i);void 0!==l&&(this.numRows-=l.rowCount,a.delete(i))}this.children=a}depthForRow(e){return this.getCachedDepthForRow(this.children,e)}}Uo(Bo,"DEFAULT_ROW_COUNT",1e9),Uo(Bo,"DEFAULT_COLUMN_COUNT",100),Uo(Bo,"DEFAULT_CHILD_ROW_COUNT_FACTOR",.01),Uo(Bo,"MIN_CHILD_ROW_COUNT",10),Uo(Bo,"MAX_DEPTH",10);var Wo,Go=Bo;!function(e){e.FILTER_CONTROL_CHANGE_CLEARS_ALL_FILTERS="filter-control-change-clears-all-filters",e.LINK_CHANGE_CLEARS_ALL_FILTERS="link-change-clears-all-filters"}(Wo||(Wo={}));var qo,Ko=Wo,Yo={DEFAULTS:Object.freeze([[Ko.FILTER_CONTROL_CHANGE_CLEARS_ALL_FILTERS,!1],[Ko.LINK_CHANGE_CLEARS_ALL_FILTERS,!1]])};!function(e){e.COUNT="Count",e.MIN="Min",e.MAX="Max",e.SUM="Sum",e.ABS_SUM="AbsSum",e.VAR="Var",e.AVG="Avg",e.STD="Std",e.FIRST="First",e.LAST="Last",e.SKIP="Skip",e.COUNT_DISTINCT="CountDistinct",e.DISTINCT="Distinct",e.UNIQUE="Unique"}(qo||(qo={}));var Xo=qo,Zo=(e,t)=>e.filter((e=>((e,t)=>{switch(e){case Xo.COUNT:case Xo.FIRST:case Xo.LAST:case Xo.COUNT_DISTINCT:case Xo.DISTINCT:case Xo.UNIQUE:return!0;case Xo.MIN:case Xo.MAX:return cs.isNumberType(t)||cs.isDateType(t)||cs.isTextType(t);case Xo.SUM:case Xo.ABS_SUM:case Xo.VAR:case Xo.AVG:case Xo.STD:return cs.isNumberType(t);case Xo.SKIP:return!1}})(t,e.type))),$o=e=>!1,Qo=(e,t,n,i)=>Zo(e,t).map((e=>{var{name:t}=e;return t})).filter((e=>n.includes(e)?!i:i)),Jo=["selectedValues"],el=["selectedValues"];function tl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function nl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tl(Object(n),!0).forEach((function(t){il(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function il(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function al(e,t){if(null==e)return{};var n,i,a=function(e,t){if(null==e)return{};var n,i,a={},s=Object.keys(e);for(i=0;i<s.length;i++)n=s[i],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(i=0;i<s.length;i++)n=s[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var sl=p.module("IrisGridUtils");class rl{static dehydrateGridState(e,t){var{movedColumns:n,movedRows:i}=t,{columns:a}=e;return{movedColumns:[...n].filter((e=>{var{to:t,from:n}=e;return t>=0&&t<a.length&&n>=0&&n<a.length})).map((e=>{var{to:t,from:n}=e;return{to:a[t].name,from:a[n].name}})),movedRows:[...i]}}static hydrateGridState(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],{movedColumns:i,movedRows:a}=t,{columns:s}=e,r=rl.parseCustomColumnNames(n),o=s.map((e=>{var{name:t}=e;return t})).concat(r);return{movedColumns:[...i].map((e=>{var{to:t,from:n}=e;return("string"===typeof t||t instanceof String)&&("string"===typeof n||n instanceof String)?{to:o.findIndex((e=>e===t)),from:o.findIndex((e=>e===n))}:{to:t,from:n}})).filter((e=>{var{to:t,from:n}=e;return null!=t&&t>=0&&t<o.length&&null!=n&&n>=0&&n<o.length})),movedRows:[...a]}}static dehydrateIrisGridState(e,t){var{aggregationSettings:n={aggregations:[],showOnTop:!1},advancedSettings:i=[],advancedFilters:a,customColumnFormatMap:s,isFilterBarShown:r,metrics:o,quickFilters:l,customColumns:c,reverseType:h,rollupConfig:d=null,showSearchBar:u,searchValue:m,selectDistinctColumns:p,selectedSearchColumns:g,sorts:v,invertSearchColumns:f,pendingDataMap:b=new Map,frozenColumns:C}=t,{userColumnWidths:S,userRowHeights:E}=o,{columns:w}=e;return{advancedFilters:rl.dehydrateAdvancedFilters(w,a),advancedSettings:[...i],aggregationSettings:n,customColumnFormatMap:[...s],isFilterBarShown:r,quickFilters:rl.dehydrateQuickFilters(l),sorts:rl.dehydrateSort(v,e),userColumnWidths:[...S].filter((e=>{var[t]=e;return null!=t&&t>=0&&t<w.length})).map((e=>{var[t,n]=e;return[w[t].name,n]})),userRowHeights:[...E],customColumns:[...c],reverseType:h,rollupConfig:d,showSearchBar:u,searchValue:m,selectDistinctColumns:[...p],selectedSearchColumns:g,invertSearchColumns:f,pendingDataMap:rl.dehydratePendingDataMap(w,b),frozenColumns:C}}static hydrateIrisGridState(e,t){var{advancedFilters:n,advancedSettings:i=[],aggregationSettings:a={aggregations:[],showOnTop:!1},customColumnFormatMap:s,isFilterBarShown:r,quickFilters:o,sorts:l,customColumns:c,userColumnWidths:h,userRowHeights:d,reverseType:u,rollupConfig:m=null,showSearchBar:p,searchValue:g,selectDistinctColumns:v,selectedSearchColumns:f,invertSearchColumns:b=!0,pendingDataMap:C=[],frozenColumns:S}=t,{columns:E,formatter:w}=e;return{advancedFilters:rl.hydrateAdvancedFilters(E,n,w.timeZone),advancedSettings:new Map([...Yo.DEFAULTS,...i]),aggregationSettings:a,customColumnFormatMap:new Map(s),isFilterBarShown:r,quickFilters:rl.hydrateQuickFilters(E,o,w.timeZone),sorts:rl.hydrateSort(E,l),userColumnWidths:new Map(h.map((e=>{var[t,n]=e;return"string"===typeof t||t instanceof String?[E.findIndex((e=>{var{name:n}=e;return n===t})),n]:[t,n]})).filter((e=>{var[t]=e;return null!=t&&t>=0&&t<E.length}))),customColumns:c,userRowHeights:new Map(d),reverseType:u,rollupConfig:m,showSearchBar:p,searchValue:g,selectDistinctColumns:v,selectedSearchColumns:f,invertSearchColumns:b,pendingDataMap:rl.hydratePendingDataMap(E,C),frozenColumns:S}}static dehydrateIrisGridPanelState(e,t){var{isSelectingPartition:n,partition:i,partitionColumn:a}=t;return{isSelectingPartition:n,partition:i,partitionColumn:a?a.name:null}}static hydrateIrisGridPanelState(e,t){var{isSelectingPartition:n,partition:i,partitionColumn:a}=t,{columns:s}=e;return{isSelectingPartition:n,partition:i,partitionColumn:null!=a?rl.getColumnByName(s,a):null}}static dehydrateQuickFilters(e){return[...e].map((e=>{var[t,n]=e,{text:i}=n;return[t,{text:i}]}))}static hydrateQuickFilters(e,t,n){var i=t.map((t=>{var[i,a]=t,{text:s}=a,r=null;try{var o=rl.getColumn(e,i);null!=o&&(r=cs.makeQuickFilter(o,s,n))}catch(l){sl.error("hydrateQuickFilters error with",s,l)}return[i,{text:s,filter:r}]}));return new Map(i)}static dehydrateAdvancedFilters(e,t){return[...t].map((t=>{var[n,i]=t;return[n,{options:rl.dehydrateAdvancedFilterOptions(rl.getColumn(e,n),i.options)}]}))}static hydrateAdvancedFilters(e,t,n){var i=t.map((t=>{var[i,a]=t,s=rl.hydrateAdvancedFilterOptions(rl.getColumn(e,i),a.options),r=null;try{var o=rl.getColumn(e,i);null!=o&&(r=cs.makeAdvancedFilter(o,s,n))}catch(l){sl.error("hydrateAdvancedFilters error with",s,l)}return[i,{options:s,filter:r}]}));return new Map(i)}static dehydrateAdvancedFilterOptions(e,t){var{selectedValues:n}=t,i=al(t,Jo);return nl({selectedValues:n.map((t=>rl.dehydrateValue(t,null===e||void 0===e?void 0:e.type)))},i)}static hydrateAdvancedFilterOptions(e,t){var{selectedValues:n}=t,i=al(t,el);return nl({selectedValues:n.map((t=>rl.hydrateValue(t,null===e||void 0===e?void 0:e.type)))},i)}static dehydratePendingDataMap(e,t){return[...t].map((t=>{var[n,{data:i}]=t;return[n,{data:[...i].map((t=>{var[n,i]=t;return[e[n].name,rl.dehydrateValue(i,e[n].type)]}))}]}))}static hydratePendingDataMap(e,t){var n=new Map,i=t=>(n.has(t)||n.set(t,e.findIndex((e=>{var{name:n}=e;return n===t}))),n.get(t));return new Map(t.map((t=>{var[n,{data:a}]=t;return[n,{data:new Map(a.map((t=>{var[n,a]=t;return[i(n),rl.hydrateValue(a,e[i(n)].type)]})))}]})))}static dehydrateValue(e,t){return cs.isDateType(t)?rl.dehydrateDateTime(e):cs.isLongType(t)?rl.dehydrateLong(e):e}static hydrateValue(e,t){return cs.isDateType(t)?rl.hydrateDateTime(e):cs.isLongType(t)?rl.hydrateLong(e):e}static dehydrateDateTime(e){return null!=e?va.i18n.DateTimeFormat.format(Ja.FULL_DATE_FORMAT,e):null}static hydrateDateTime(e){return null!=e?va.i18n.DateTimeFormat.parse(Ja.FULL_DATE_FORMAT,e):null}static dehydrateLong(e){return null!=e?"".concat(e):null}static hydrateLong(e){return null!=e?va.LongWrapper.ofString(e):null}static dehydrateSort(e){return e.map((e=>{var{column:t,isAbs:n,direction:i}=e;return{column:t.index,isAbs:n,direction:i}}))}static hydrateSort(e,t){return t.map((t=>{var{column:n,isAbs:i,direction:a}=t;if(a===cs.sortDirection.reverse)return va.Table.reverse();var s=rl.getColumn(e,n);if(null!=s){var r=s.sort();return i&&(r=r.abs()),r=a===cs.sortDirection.descending?r.desc():r.asc()}return null})).filter((e=>null!=e&&e.direction!==cs.sortDirection.reverse))}static extractTableSettings(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],{irisGridPanelState:n,irisGridState:i}=e,{partitionColumn:a,partition:s}=n,{advancedFilters:r,quickFilters:o,sorts:l}=i;return{advancedFilters:r,inputFilters:t,partition:s,partitionColumn:a,quickFilters:o,sorts:l}}static applyTableSettings(e,t,n){var{columns:i}=e,a=rl.getFiltersFromFilterMap(rl.hydrateQuickFilters(i,t.quickFilters,n)),s=rl.getFiltersFromFilterMap(rl.hydrateAdvancedFilters(i,t.advancedFilters,n)),r=rl.getFiltersFromInputFilters(i,t.inputFilters,n),o=rl.hydrateSort(i,t.sorts),l=[...a,...s],{partition:c,partitionColumn:h}=t;if(c&&h){var d=rl.getColumnByName(i,h);if(d)l=[d.filter().eq(va.FilterValue.ofString(c)),...l]}l=[...r,...l],e.applyFilter(l),e.applySort(o)}static getInputFiltersForColumns(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).filter((t=>{var{name:n,type:i}=t;return e.find((e=>{var{name:t,type:a}=e;return t===n&&a===i}))}))}static getFiltersFromInputFilters(e){var t=arguments.length>2?arguments[2]:void 0;return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).map((n=>{var{name:i,type:a,value:s}=n,r=e.find((e=>{var{name:t,type:n}=e;return t===i&&n===a}));if(r)try{return cs.makeQuickFilter(r,s,t)}catch(o){sl.debug("Unable to create input filter",o)}return null})).filter((e=>e))}static getFiltersFromFilterMap(e){for(var t=[],n=Array.from(e.keys()),i=0;i<n.length;i+=1){var a=n[i],s=e.get(a);null!=s.filter&&t.push(s.filter)}return t}static getHiddenColumns(e){return[...e.entries()].filter((e=>{var[,t]=e;return 0===t})).map((e=>{var[t]=e;return t}))}static parseCustomColumnNames(e){return e.map((e=>e.split("=")[0]))}static getRemovedCustomColumnNames(e,t){var n=rl.parseCustomColumnNames(e),i=rl.parseCustomColumnNames(t);return n.filter((e=>!i.includes(e)))}static removeSortsInColumns(e,t){return e.filter((e=>!t.includes(e.column.name)))}static removeFiltersInColumns(e,t,n){var i=e.map((e=>{var{name:t}=e;return t})),a=new Map(t);return n.forEach((e=>a.delete(i.indexOf(e)))),a}static removeColumnFromMovedColumns(e,t,n){for(var i=e.map((e=>{var{name:t}=e;return t})),a=[...t],s=function(e){for(var t=n[e],s=i.findIndex((e=>e===t)),r=[],o=0;o<a.length;o+=1){var l=a[o],c=nl({},l);s!==l.from&&(l.from>s&&(c.from-=1),l.to>=s&&(c.to-=1),c.from!==c.to&&r.push(c)),l.from===s?s=l.to:l.from<s&&s<l.to?s-=1:l.to<=s&&s<l.from&&(s+=1)}a=r,i.splice(i.findIndex((e=>e===t)),1)},r=0;r<n.length;r+=1)s(r);return a}static removeColumnsFromSelectDistinctColumns(e,t){return e.filter((e=>!t.includes(e)))}static getVisibleColumnsInRange(e,t,n,i,a){for(var s=[],r=t;r<=n;r+=1){var o=wr.getModelIndex(r,i);o>=0&&o<e.length&&!a.includes(o)&&s.push(e[o])}return s}static getPrevVisibleColumns(e,t,n,i,a){for(var s=[],r=t;r>=0&&s.length<n;){var o=wr.getModelIndex(r,i);o>=0&&o<e.length&&!a.includes(o)&&s.unshift(e[o]),r-=1}return s}static getNextVisibleColumns(e,t,n,i,a){for(var s=[],r=t;r<e.length&&s.length<n;){var o=wr.getModelIndex(r,i);o>=0&&o<e.length&&!a.includes(o)&&s.push(e[o]),r+=1}return s}static getColumnsToFetch(e,t,n){var i=[...t];return n.forEach((n=>{var a=e.find((e=>{var{name:t}=e;return t===n}));null==a||t.includes(a)||i.push(a)})),i}static getModelViewportColumns(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:[],r=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0;if(null==t||null==n)return null;var o=rl.getVisibleColumnsInRange(e,t,n,i,a),l=o.length*r,c=rl.getPrevVisibleColumns(e,t-1,l,i,a),h=rl.getNextVisibleColumns(e,n+1,l,i,a),d=[...c,...o,...h];return rl.getColumnsToFetch(e,d,s)}static rangeSetFromRanges(e){var t=e.slice().sort(((e,t)=>e.startRow-t.startRow)).map((e=>{var{startRow:t,endRow:n}=e;return va.RangeSet.ofRange(t,n)}));return va.RangeSet.ofRanges(t)}static isValidSnapshotRanges(e){if(!e||0===e.length)return!1;for(var t=new Map,n=0;n<e.length;n+=1){var i=e[n],a="".concat(i.startRow,":").concat(i.endRow),s="".concat(i.startColumn,":").concat(i.endColumn);t.has(a)||t.set(a,[]),t.get(a).push(s)}for(var r=[...t.keys()],o=t.get(r[0]).sort().join(","),l=1;l<r.length;l+=1)if(t.get(r[l]).sort().join(",")!==o)return!1;return!0}static isValidIndex(e){return Number.isInteger(e)&&e>=0}static columnsFromRanges(e,t){if(!e||0===e.length)return[];if(null===e[0].startColumn&&null===e[0].endColumn)return t;for(var n=new Set,i=0;i<e.length;i+=1)for(var a=e[i],s=null!==(r=a.startColumn)&&void 0!==r?r:0;s<=(null!==(o=a.endColumn)&&void 0!==o?o:t.length-1);s+=1){var r,o;n.add(s)}return[...n].map((e=>t[e]))}static snapshotDataToMatrix(e){for(var{columns:t,rows:n}=e,i=[],a=0;a<n.length;a+=1){for(var s=n[a],r=[],o=0;o<t.length;o+=1){var l=t[o],c=s.get(l);r.push(c)}i.push(r)}return i}static getModelRollupConfig(e,t,n){var i,a;if(0===(null!==(i=null===t||void 0===t||null===(a=t.columns)||void 0===a?void 0:a.length)&&void 0!==i?i:0))return null;for(var{columns:s=[],showConstituents:r=!0,showNonAggregatedColumns:o=!0,includeDescriptions:l=!0}=null!==t&&void 0!==t?t:{},{aggregations:c=[]}=null!==n&&void 0!==n?n:{},h=c.map((t=>{var{operation:n,selected:i,invert:a}=t;return $o(n)?[]:Qo(e,n,i,a)})),d={},u=0;u<c.length;u+=1)d[c[u].operation]=h[u];if(o){var m=new Set(e.map((e=>e.name)).filter((e=>!s.includes(e))));if(h.forEach((e=>{e.forEach((e=>m.delete(e)))})),m.size>0){var p,g=null!==(p=d[Xo.FIRST])&&void 0!==p?p:[];d[Xo.FIRST]=[...g,...m]}}return{groupingColumns:s,includeConstituents:r,includeDescriptions:l,aggregations:d}}static getPendingErrors(e){e.forEach(((e,t)=>{if(!rl.isValidIndex(t))throw new Error("Invalid rowIndex",t);var{data:n}=e;n.forEach(((e,t)=>{if(!rl.isValidIndex(t))throw new Error("Invalid columnIndex",t)}))}))}static getColumn(e,t){return t<e.length?e[t]:(sl.error("Unable to retrieve column",t,">=",e.length),null)}static getColumnByName(e,t){var n=e.find((e=>{var{name:n}=e;return n===t}));return null==n&&sl.error("Unable to retrieve column by name",t,e.map((e=>{var{name:t}=e;return t}))),n}}var ol=rl,ll=p.module("GlobalContextAction");class cl extends i.Component{constructor(e){super(e),this.handleContextMenu=this.handleContextMenu.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this)}componentDidMount(){document.body.addEventListener("contextmenu",this.handleContextMenu),document.body.addEventListener("keydown",this.handleKeyDown)}componentWillUnmount(){document.body.removeEventListener("contextmenu",this.handleContextMenu),document.body.removeEventListener("keydown",this.handleKeyDown)}handleContextMenu(e){var t=e;t.contextActions||(t.contextActions=[]);var{action:n}=this.props;(n.title||n.menuElement)&&(t.contextActions||(t.contextActions=[]),t.contextActions.push(n),ll.debug("Received context menu event at global action! Menu items are now: ",t.contextActions))}handleKeyDown(e){var t,{action:n}=this.props;if(!je.actionsDisabled&&null!==(t=n.shortcut)&&void 0!==t&&t.matchesEvent(e)){var i;ll.debug("Global hotkey matched!",e);var a=null===(i=n.action)||void 0===i?void 0:i.call(n,e);(a||void 0===a)&&(e.preventDefault(),e.stopPropagation())}}render(){return null}}var hl=cl;class dl extends i.Component{render(){for(var{actions:e}=this.props,t=[],n=0;n<e.length;n+=1){var i=e[n],{shortcut:s}=i;if(i.title||i.menuElement||s){var r=a.a.createElement(hl,{key:"".concat(i.title,".").concat(null===s||void 0===s?void 0:s.id),action:i});t.push(r)}}return t}}var ul=dl;n(518);function ml(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var pl=p.module("ContextActions");class gl extends i.Component{static triggerMenu(e,t,n,i){if(e&&t&&n&&i){var a=new MouseEvent("contextmenu",{clientX:t,clientY:n,bubbles:!0,cancelable:!0});a.contextActions=i,e.dispatchEvent(a)}}constructor(e){super(e),ml(this,"container",void 0),this.handleContextMenu=this.handleContextMenu.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.container=a.a.createRef(),this.state={globalActions:[],keyboardActions:[]}}static getDerivedStateFromProps(e){return e.actions&&Array.isArray(e.actions)?{globalActions:e.actions.filter((e=>e.isGlobal)),keyboardActions:e.actions.filter((e=>!e.isGlobal&&null!=e.shortcut))}:{globalActions:[],keyboardActions:[]}}componentDidMount(){var e;null!==(e=this.container.current)&&void 0!==e&&e.parentElement&&(this.container.current.parentElement.addEventListener("contextmenu",this.handleContextMenu),this.container.current.parentElement.addEventListener("keydown",this.handleKeyDown))}componentWillUnmount(){var e;null!==(e=this.container.current)&&void 0!==e&&e.parentElement&&(this.container.current.parentElement.removeEventListener("contextmenu",this.handleContextMenu),this.container.current.parentElement.removeEventListener("keydown",this.handleKeyDown))}handleContextMenu(e){var{ignoreClassNames:t=[]}=this.props;if(t.length>0)for(var n=e.target,i=function(){var{classList:e}=n,i=t.find((t=>e.contains(t)));if(void 0!==i)return pl.debug2('Contextmenu event ignored based on the target className "'.concat(i,'"')),{v:void 0};n=n.parentElement};null!=n;){var a=i();if("object"===typeof a)return a.v}if(je.isContextActionEvent(e)||(e.contextActions=[]),je.isContextActionEvent(e)){var{actions:s}=this.props;if(s){var r=s;Array.isArray(r)&&(r=r.filter((e=>!e.isGlobal))),e.contextActions=e.contextActions.concat(r)}pl.debug("Received context menu event! Menu items are now: ",e.contextActions)}}handleKeyDown(e){for(var{keyboardActions:t}=this.state,n=0;n<t.length;n+=1){var i,a=t[n];if(!je.actionsDisabled&&null!==(i=a.shortcut)&&void 0!==i&&i.matchesEvent(e)){var s;pl.debug("Context hotkey matched!",e);var r=null===(s=a.action)||void 0===s?void 0:s.call(a,e);if(r||void 0===r)return e.stopPropagation(),void e.preventDefault();pl.debug2("Matched hotkey returned false, key event not consumed")}}}render(){var{globalActions:e}=this.state;return a.a.createElement("div",{className:"context-actions-listener",ref:this.container},a.a.createElement(ul,{actions:e}))}}ml(gl,"groups",{default:null,high:100,medium:5e3,low:1e4,global:1e5,edit:100});var vl=gl,fl=n(336);n(800);function bl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Cl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Sl extends i.Component{constructor(e){super(e),Cl(this,"element",void 0),Cl(this,"container",void 0),Cl(this,"isExiting",void 0),Cl(this,"rAF",void 0),this.handleEnter=this.handleEnter.bind(this),this.handleExit=this.handleExit.bind(this),this.handleBlur=this.handleBlur.bind(this),this.element=document.createElement("div"),this.element.className="popper-container",this.container=a.a.createRef(),this.isExiting=!1,this.rAF=0;var{isShown:t}=this.props;this.state={show:t,popper:null}}componentDidUpdate(e){var{isShown:t}=this.props;e.isShown!==t&&(t?(cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame((()=>{this.show()}))):this.hide())}componentWillUnmount(){this.destroyPopper(!1),this.isExiting=!1}getVisibleElement(e){return null==e||e.clientHeight>0||e.clientWidth>0?e:this.getVisibleElement(e.parentElement)}initPopper(){var{popper:e}=this.state,{closeOnBlur:t,referenceObject:n}=this.props;if(!e&&null!==this.container.current){var{options:i}=this.props;i=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bl(Object(n),!0).forEach((function(t){Cl(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({placement:"auto"},i),document.body.appendChild(this.element);var a=this.getVisibleElement(this.container.current);null==a&&(a=this.container.current),(e=new fl.a(n||a,this.element,i)).scheduleUpdate(),cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame((()=>{if(t&&!this.element.contains(document.activeElement)){var e=this.element.firstElementChild;e instanceof HTMLElement&&e.focus()}})),this.setState({popper:e})}}destroyPopper(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.isExiting=!1,cancelAnimationFrame(this.rAF);var{popper:t}=this.state;t&&(t.destroy(),document.body.removeChild(this.element),e&&this.setState({popper:null}))}show(){this.initPopper(),this.setState({show:!0})}hide(){this.setState({show:!1})}scheduleUpdate(){var{popper:e}=this.state;e&&e.scheduleUpdate()}handleBlur(e){e.relatedTarget instanceof HTMLElement&&(this.element.contains(e.relatedTarget)||this.hide())}handleEnter(){var{onEntered:e}=this.props;e()}handleExit(){var{onExited:e}=this.props;e();var{show:t}=this.state;t||this.destroyPopper(),this.isExiting=!1}renderContent(){var{className:e,children:t,timeout:n,interactive:i,closeOnBlur:s}=this.props,{show:r}=this.state;return a.a.createElement(We.CSSTransition,{in:r,timeout:n,classNames:"popper-transition",onEntered:this.handleEnter,onExit:()=>{this.isExiting=!0},onExited:this.handleExit},a.a.createElement("div",{onClick:e=>{e.stopPropagation()},onKeyDown:e=>{"Escape"===e.key&&this.hide()},className:qe()("popper",{interactive:i},e),onBlur:s?this.handleBlur:void 0,tabIndex:s?-1:void 0,role:"presentation"},a.a.createElement("div",{className:"popper-content"},t,a.a.createElement("div",{className:"popper-arrow","x-arrow":""}))))}render(){var{popper:e}=this.state;return a.a.createElement("div",{className:"popper-parent-container",ref:this.container,style:{display:"none"}},e&&r.a.createPortal(this.renderContent(),this.element))}}Cl(Sl,"propTypes",{children:pi.a.node.isRequired,options:pi.a.shape({}),className:pi.a.string,timeout:pi.a.number,onEntered:pi.a.func,onExited:pi.a.func,isShown:pi.a.bool,closeOnBlur:pi.a.bool,interactive:pi.a.bool,referenceObject:pi.a.shape({})}),Cl(Sl,"defaultProps",{options:{},className:"",timeout:Kn.transitionMs,onEntered(){},onExited(){},isShown:!1,interactive:!1,closeOnBlur:!1,referenceObject:null});var El=Sl;function wl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var yl=p.module("Tooltip");class Tl extends i.Component{static handleHidden(){Tl.shownTooltipCount-=1,0===Tl.shownTooltipCount&&(Tl.lastHiddenTime=Date.now())}static handleShown(){Tl.shownTooltipCount+=1}constructor(e){super(e),wl(this,"container",void 0),wl(this,"popper",void 0),wl(this,"parent",void 0),wl(this,"timer",void 0),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowMouseMove=this.handleWindowMouseMove.bind(this),this.handleWheel=this.handleWheel.bind(this),this.handleTimeout=this.handleTimeout.bind(this),this.handleExited=this.handleExited.bind(this),this.stopShowingTooltip=this.stopShowingTooltip.bind(this),this.container=a.a.createRef(),this.popper=a.a.createRef(),this.parent=null,this.timer=null,this.state={isShown:!1}}componentDidMount(){this.startListening();var{timeout:e}=this.props;0===e&&this.show()}componentDidUpdate(e,t){var{isShown:n}=t,{isShown:i}=this.state;i!==n&&(i?Tl.handleShown():Tl.handleHidden())}componentWillUnmount(){this.stopListening(),this.stopListeningWindow(),this.stopTimer();var{isShown:e}=this.state;e&&Tl.handleHidden()}startListening(){this.container.current&&this.container.current.parentElement?(this.parent=this.container.current.parentElement,this.parent.addEventListener("mousemove",this.handleMouseMove),this.parent.addEventListener("mouseleave",this.handleMouseLeave),this.parent.addEventListener("mousedown",this.stopShowingTooltip)):yl.error("Tooltip doesn't have a container or a parent set!")}stopListening(){this.parent&&(this.parent.removeEventListener("mousemove",this.handleMouseMove),this.parent.removeEventListener("mouseleave",this.handleMouseLeave),this.parent.removeEventListener("mousedown",this.stopShowingTooltip))}startListeningWindow(){window.addEventListener("mousemove",this.handleWindowMouseMove,!0),window.addEventListener("contextmenu",this.stopShowingTooltip,!0),window.addEventListener("wheel",this.handleWheel)}stopListeningWindow(){window.removeEventListener("mousemove",this.handleWindowMouseMove,!0),window.removeEventListener("contextmenu",this.stopShowingTooltip,!0),window.removeEventListener("wheel",this.handleWheel)}handleMouseMove(){this.startTimer()}handleWheel(){var{isShown:e}=this.state;this.popper.current&&this.parent&&e&&(this.popper.current.element.matches(":hover")||this.parent.matches(":hover")||(this.stopTimer(),this.hide()))}handleMouseLeave(){var{isShown:e}=this.state;this.stopTimer();var{interactive:t}=this.props;!t&&e&&this.hide()}handleTimeout(){this.show()}handleWindowMouseMove(e){var t=e.clientX,n=e.clientY,{isShown:i}=this.state;if(this.popper.current&&this.parent){var a=this.popper.current.element.getBoundingClientRect(),s=this.parent.getBoundingClientRect();t>=a.left&&t<=a.left+a.width&&n>=a.top&&n<=a.top+a.height||t>=s.left&&t<=s.left+s.width&&n>=s.top&&n<=s.top+s.height?this.handleMouseMove():i&&(this.stopTimer(),this.hide())}}startTimer(){this.stopTimer();var{timeout:e,reshowTimeout:t}=this.props,n=e;(Tl.shownTooltipCount>0||Date.now()-Tl.lastHiddenTime<Tl.triggerReshowThreshold)&&(n=t),this.timer=window.setTimeout(this.handleTimeout,n)}stopTimer(){this.timer&&(clearTimeout(this.timer),this.timer=null)}show(){var{isShown:e}=this.state;if(this.stopTimer(),!e){var t;null===(t=this.popper.current)||void 0===t||t.show(),this.setState({isShown:!0});var{interactive:n}=this.props;n&&this.startListeningWindow()}}hide(){var e;null===(e=this.popper.current)||void 0===e||e.hide(),this.stopListeningWindow()}update(){var e;null===(e=this.popper.current)||void 0===e||e.scheduleUpdate()}handleExited(){this.setState({isShown:!1})}stopShowingTooltip(){var{isShown:e}=this.state;this.stopTimer(),e&&this.hide()}render(){var{interactive:e,children:t,options:n,referenceObject:i,popperClassName:s}=this.props,{isShown:r}=this.state;return a.a.createElement("div",{ref:this.container,style:{display:"none"}},a.a.createElement(El,{className:qe()(s),options:n,ref:this.popper,onExited:this.handleExited,interactive:e,referenceObject:i},a.a.createElement("div",{className:"tooltip-content"}," ",r&&t)))}}wl(Tl,"defaultTimeout",500),wl(Tl,"defaultReshowTimeout",100),wl(Tl,"triggerReshowThreshold",300),wl(Tl,"shownTooltipCount",0),wl(Tl,"lastHiddenTime",Date.now()),wl(Tl,"defaultProps",{interactive:!1,options:{},popperClassName:"",reshowTimeout:Tl.defaultReshowTimeout,timeout:Tl.defaultTimeout,referenceObject:null});var Ol=Tl;function Ml(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Nl{}Ml(Nl,"OPEN","ChartEvent.OPEN"),Ml(Nl,"CLOSE","ChartEvent.CLOSE"),Ml(Nl,"COLUMN_SELECTED","ChartEvent.COLUMN_SELECTED");var Dl=Nl;function xl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Rl{}xl(Rl,"SESSION_OPENED","ConsoleEvent.SESSION_OPENED"),xl(Rl,"SESSION_CLOSED","ConsoleEvent.SESSION_CLOSED"),xl(Rl,"FOCUS_HISTORY","ConsoleEvent.FOCUS_HISTORY"),xl(Rl,"SEND_COMMAND","ConsoleEvent.SEND_COMMAND"),xl(Rl,"SETTINGS_CHANGED","ConsoleEvent.SETTINGS_CHANGED");var Il=Rl;function Ll(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Fl{}Ll(Fl,"TABLE_CHANGED","InputFilterEvent.TABLE_CHANGED"),Ll(Fl,"COLUMNS_CHANGED","InputFilterEvent.COLUMNS_CHANGED"),Ll(Fl,"FILTERS_CHANGED","InputFilterEvent.FILTERS_CHANGED"),Ll(Fl,"CLEAR_ALL_FILTERS","InputFilterEvent.CLEAR_ALL_FILTERS"),Ll(Fl,"COLUMN_SELECTED","InputFilterEvent.COLUMN_SELECTED"),Ll(Fl,"OPEN_DROPDOWN","InputFilterEvent.OPEN_DROPDOWN"),Ll(Fl,"OPEN_INPUT","InputFilterEvent.OPEN_INPUT"),Ll(Fl,"OPEN_FILTER_SET_MANAGER","InputFilterEvent.OPEN_FILTER_SET_MANAGER");var kl=Fl;function Al(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Pl{}Al(Pl,"OPEN_GRID","IrisGridEvent.OPEN_GRID"),Al(Pl,"CLOSE_GRID","IrisGridEvent.CLOSE_GRID"),Al(Pl,"DATA_SELECTED","IrisGridEvent.DATA_SELECTED"),Al(Pl,"COLUMN_SELECTED","IrisGridEvent.COLUMN_SELECTED"),Al(Pl,"STATE_CHANGED","IrisGridEvent.STATE_CHANGED");var _l=Pl,Hl=Object.freeze({OPEN:"MarkdownEvent.OPEN"});function jl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Vl{}jl(Vl,"CREATE_NOTEBOOK","NotebookEvent.createNotebook"),jl(Vl,"SELECT_NOTEBOOK","NotebookEvent.selectNotebook"),jl(Vl,"CLOSE_FILE","NotebookEvent.closeFile"),jl(Vl,"RENAME","NotebookEvent.rename"),jl(Vl,"RENAME_FILE","NotebookEvent.renameFile"),jl(Vl,"REGISTER_FILE","NotebookEvent.registerFile"),jl(Vl,"SEND_TO_NOTEBOOK","NotebookEvent.sendToNotebook"),jl(Vl,"UNREGISTER_FILE","NotebookEvent.unregisterFile");var zl=Vl;function Ul(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Bl{}Ul(Bl,"OPEN","PandasEvent.OPEN"),Ul(Bl,"CLOSE","PandasEvent.CLOSE");var Wl=Bl;function Gl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class ql{}Gl(ql,"focus","TabEvent.focus"),Gl(ql,"blur","TabEvent.blur"),Gl(ql,"openPQObject","TabEvent.openPQObject"),Gl(ql,"openControl","TabEvent.openControl"),Gl(ql,"reload","TabEvent.reload"),Gl(ql,"clearAllFilters","TabEvent.clearAllFilters");var Kl=ql;class Yl extends i.PureComponent{constructor(e){super(e),this.handleCloseTab=this.handleCloseTab.bind(this),this.handleCloseTabsRight=this.handleCloseTabsRight.bind(this),this.handleCloseTabsAll=this.handleCloseTabsAll.bind(this)}getAllTabs(){var e,t,n,{glContainer:i}=this.props;return[...null!==(e=null===i||void 0===i||null===(t=i.tab)||void 0===t||null===(n=t.header)||void 0===n?void 0:n.tabs)&&void 0!==e?e:[]]}handleCloseTab(){var{glContainer:e}=this.props;e.close()}handleCloseTabsAll(){this.getAllTabs().forEach((e=>{var t,n;return null===e||void 0===e||null===(t=e.contentItem)||void 0===t||null===(n=t.container)||void 0===n?void 0:n.close()}))}handleCloseTabsRight(){for(var{glContainer:e}=this.props,t=this.getAllTabs(),n=t.length-1;n>0;n-=1){var i,a,s,r,o,l,c,h;if((null===(i=t[n].contentItem)||void 0===i||null===(a=i.config)||void 0===a?void 0:a.id)===(null===(s=e.tab)||void 0===s||null===(r=s.contentItem)||void 0===r||null===(o=r.config)||void 0===o?void 0:o.id))break;null===(l=t[n])||void 0===l||null===(c=l.contentItem)||void 0===c||null===(h=c.container)||void 0===h||h.close()}}canCloseTabsRight(){for(var{glContainer:e}=this.props,t=this.getAllTabs(),n=!0,i=t.length-1;i>0;i-=1){var a,s,r,o,l,c,h,d;if((null===(a=t[i].contentItem)||void 0===a||null===(s=a.config)||void 0===s?void 0:s.id)===(null===(r=e.tab)||void 0===r||null===(o=r.contentItem)||void 0===o||null===(l=o.config)||void 0===l?void 0:l.id))break;if(null!==(c=t[i])&&void 0!==c&&null!==(h=c.contentItem)&&void 0!==h&&null!==(d=h.config)&&void 0!==d&&d.isClosable){n=!1;break}}return n}canCloseAny(){for(var e=this.getAllTabs(),t=!0,n=e.length-1;n>0;n-=1){var i,a,s;if(null!==(i=e[n])&&void 0!==i&&null!==(a=i.contentItem)&&void 0!==a&&null!==(s=a.config)&&void 0!==s&&s.isClosable){t=!1;break}}return t}render(){var e,t,n,{additionalActions:i,glContainer:s}=this.props,r=[].concat(i);return r.push({title:"Close",order:10,group:vl.groups.low,action:this.handleCloseTab,disabled:!(null!==(e=s.tab)&&void 0!==e&&null!==(t=e.contentItem)&&void 0!==t&&null!==(n=t.config)&&void 0!==n&&n.isClosable)}),r.push((()=>({title:"Close Tabs to Right",order:20,group:vl.groups.low,action:this.handleCloseTabsRight,disabled:this.canCloseTabsRight()}))),r.push((()=>({title:"Close All",order:30,group:vl.groups.low,action:this.handleCloseTabsAll,disabled:this.canCloseAny()}))),a.a.createElement(vl,{actions:r})}}Yl.propTypes={additionalActions:pi.a.oneOfType([pi.a.array,pi.a.func]),glContainer:Ni.Container.isRequired},Yl.defaultProps={additionalActions:[]};var Xl=Yl;class Zl extends i.PureComponent{constructor(e){super(e),this.handleRenameDialogOpened=this.handleRenameDialogOpened.bind(this),this.handleRenameInputChange=this.handleRenameInputChange.bind(this),this.handleRenameCancel=this.handleRenameCancel.bind(this),this.handleRenameSubmit=this.handleRenameSubmit.bind(this),this.renameInputRef=a.a.createRef();var{value:t}=e;this.state={value:t,valueWasValidated:!1}}componentDidUpdate(e){var{isShown:t}=e,{isShown:n}=this.props;n&&!t&&this.resetState()}resetState(){var{value:e}=this.props;this.setState({value:e,valueWasValidated:!1})}handleRenameDialogOpened(){this.renameInputRef&&this.renameInputRef.current.focus()}handleRenameInputChange(e){this.setState({value:e.target.value})}handleRenameCancel(){var{onCancel:e}=this.props;e()}handleRenameSubmit(e){e.stopPropagation(),e.preventDefault();var{value:t}=this.state,n=t.trim();if(""!==n){var{onSubmit:i}=this.props;i(n)}else this.setState({value:n,valueWasValidated:!0})}renderRenameDialog(){var{isShared:e,isOwner:t,itemType:n}=this.props,{value:i,valueWasValidated:s}=this.state;return a.a.createElement("form",{className:qe()("p-3",{"was-validated":s}),onSubmit:this.handleRenameSubmit,noValidate:!0,role:"presentation",onMouseDown:e=>{e.stopPropagation()},onMouseUp:e=>{e.stopPropagation()}},a.a.createElement("div",{className:"form-group"},a.a.createElement("label",{htmlFor:"rename-dialog-".concat(n,"-input")},"Rename ",n),a.a.createElement("input",{type:"text",className:"form-control",id:"rename-dialog-".concat(n,"-input"),value:i,ref:this.renameInputRef,onChange:this.handleRenameInputChange,required:!0}),a.a.createElement("div",{className:"invalid-feedback"},n," name cannot be empty"),(e||!t)&&a.a.createElement("div",{className:"pt-2"},"Renaming this ",n," will rename for all users.")),a.a.createElement("div",{className:"text-right"},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary mr-2",onClick:this.handleRenameCancel},"Cancel"),a.a.createElement("button",{type:"submit",className:"btn btn-primary"},"Rename")))}render(){var{isShown:e,onCancel:t}=this.props;return a.a.createElement(El,{isShown:e,onEntered:this.handleRenameDialogOpened,onExited:t,options:{placement:"bottom",modifiers:{preventOverflow:{boundariesElement:"viewport"}}},interactive:!0,closeOnBlur:!0},this.renderRenameDialog())}}Zl.propTypes={isShared:pi.a.bool,isOwner:pi.a.bool,isShown:pi.a.bool.isRequired,itemType:pi.a.string,onSubmit:pi.a.func.isRequired,onCancel:pi.a.func.isRequired,value:pi.a.string},Zl.defaultProps={isShared:!1,isOwner:!0,itemType:"Item"},Zl.defaultProps={value:""};var $l=p.module("Panel");class Ql extends i.PureComponent{constructor(e){super(e),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"getAdditionActions",Object(ua.a)(((e,t,n)=>{var i=[];return t&&i.push(this.getCloneAction()),n&&i.push(this.getRenameAction()),[...i,...e]}))),this.handleClearAllFilters=this.handleClearAllFilters.bind(this),this.handleCopyPanel=this.handleCopyPanel.bind(this),this.handleFocus=this.handleFocus.bind(this),this.handleBlur=this.handleBlur.bind(this),this.handleHide=this.handleHide.bind(this),this.handleResize=this.handleResize.bind(this),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.handleBeforeShow=this.handleBeforeShow.bind(this),this.handleShow=this.handleShow.bind(this),this.handleTabBlur=this.handleTabBlur.bind(this),this.handleTabFocus=this.handleTabFocus.bind(this),this.handleRenameCancel=this.handleRenameCancel.bind(this),this.handleRenameSubmit=this.handleRenameSubmit.bind(this),this.handleShowRenameDialog=this.handleShowRenameDialog.bind(this),this.handleTab=this.handleTab.bind(this);var{glContainer:t}=this.props;this.state={title:di.getTitleFromContainer(t),showRenameDialog:!1}}componentDidMount(){var{componentPanel:e,glContainer:t,glEventHub:n}=this.props;t.on("resize",this.handleResize),t.on("show",this.handleBeforeShow),t.on("shown",this.handleShow),t.on("hide",this.handleHide),t.on("tab",this.handleTab),n.on(Il.SESSION_CLOSED,this.handleSessionClosed),n.on(Il.SESSION_OPENED,this.handleSessionOpened),n.on(Kl.focus,this.handleTabFocus),n.on(Kl.blur,this.handleTabBlur),n.on(kl.CLEAR_ALL_FILTERS,this.handleClearAllFilters),n.emit(fi.MOUNT,e)}componentWillUnmount(){var{componentPanel:e,glContainer:t,glEventHub:n}=this.props;t.off("resize",this.handleResize),t.off("show",this.handleBeforeShow),t.off("shown",this.handleShow),t.off("hide",this.handleHide),t.off("tab",this.handleTab),n.off(Il.SESSION_CLOSED,this.handleSessionClosed),n.off(Il.SESSION_OPENED,this.handleSessionOpened),n.off(Kl.focus,this.handleTabFocus),n.off(Kl.blur,this.handleTabBlur),n.off(kl.CLEAR_ALL_FILTERS,this.handleClearAllFilters),n.emit(fi.UNMOUNT,e)}handleTab(e){e&&this.setState({title:di.getTitleFromTab(e)}),this.forceUpdate();var{onTab:t}=this.props;t(e)}handleClearAllFilters(){var{onClearAllFilters:e}=this.props;e(...arguments)}handleFocus(){var{componentPanel:e,glEventHub:t}=this.props;t.emit(fi.FOCUS,e);var{onFocus:n}=this.props;n(...arguments)}handleBlur(){var{onBlur:e}=this.props;e(...arguments)}handleHide(){var{onHide:e}=this.props;e(...arguments)}handleResize(){var{onResize:e}=this.props;e(...arguments)}handleSessionClosed(){var{onSessionClose:e}=this.props;e(...arguments)}handleSessionOpened(){var{onSessionOpen:e}=this.props;e(...arguments)}handleBeforeShow(){var{onBeforeShow:e}=this.props;e(...arguments)}handleShow(){var{onShow:e}=this.props;e(...arguments)}handleTabBlur(){var{onTabBlur:e}=this.props;e(...arguments)}handleTabFocus(){var{onTabFocus:e}=this.props;e(...arguments)}handleRenameCancel(){this.setState({showRenameDialog:!1})}handleShowRenameDialog(){this.setState({showRenameDialog:!0})}handleRenameSubmit(e){var{glContainer:t}=this.props;this.setState({showRenameDialog:!1,title:e});var n=di.getRootFromContainer(t),i=di.getComponentConfigFromContainer(t);di.renameComponent(n,i,e)}handleCopyPanel(){var{glContainer:e,glEventHub:t}=this.props,n=di.getRootFromContainer(e),i=di.getComponentConfigFromContainer(e);if(null!=i){var a=di.cloneComponent(n,i);null!==a&&t.emit(fi.CLONED,this,a)}else $l.error("Could not get component config from container",e)}getCloneAction(){return{title:"Copy Panel",order:10,group:vl.groups.high,action:this.handleCopyPanel}}getRenameAction(){return{title:"Rename",order:10,group:vl.groups.high,action:this.handleShowRenameDialog}}render(){var{children:e,className:t,renderTabTooltip:n,glContainer:i,additionalActions:s,errorMessage:o,isLoaded:l,isLoading:c,isClonable:h,isRenamable:d}=this.props,{tab:u}=i,{showRenameDialog:m,title:p}=this.state;return a.a.createElement("div",{className:qe()("h-100 w-100 iris-panel",t),onFocusCapture:this.handleFocus,onBlurCapture:this.handleBlur},e,a.a.createElement(Xn,{errorMessage:o,isLoaded:l,isLoading:c}),u&&r.a.createPortal(a.a.createElement(a.a.Fragment,null,a.a.createElement(Xl,{glContainer:i,additionalActions:this.getAdditionActions(s,h,d)}),d&&a.a.createElement(Zl,{isShown:m,value:p,itemType:"Panel",onCancel:this.handleRenameCancel,onSubmit:this.handleRenameSubmit}),n&&a.a.createElement(Ol,{interactive:!0,options:{placement:"bottom"},popperClassName:"panel-tab-popper"},n())),u.element[0]))}}Ql.propTypes={componentPanel:pi.a.instanceOf(i.Component).isRequired,children:pi.a.node.isRequired,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,className:pi.a.string,onFocus:pi.a.func,onBlur:pi.a.func,onTab:pi.a.func,onClearAllFilters:pi.a.func,onHide:pi.a.func,onResize:pi.a.func,onSessionClose:pi.a.func,onSessionOpen:pi.a.func,onBeforeShow:pi.a.func,onShow:pi.a.func,onTabBlur:pi.a.func,onTabFocus:pi.a.func,renderTabTooltip:pi.a.func,additionalActions:pi.a.oneOfType([pi.a.array,pi.a.func]),errorMessage:pi.a.string,isLoading:pi.a.bool,isLoaded:pi.a.bool,isClonable:pi.a.bool,isRenamable:pi.a.bool},Ql.defaultProps={className:"",onTab:()=>{},onClearAllFilters:()=>{},onFocus:()=>{},onBlur:()=>{},onHide:()=>{},onResize:()=>{},onSessionClose:()=>{},onSessionOpen:()=>{},onBeforeShow:()=>{},onShow:()=>{},onTabBlur:()=>{},onTabFocus:()=>{},renderTabTooltip:null,additionalActions:[],errorMessage:null,isLoading:!1,isLoaded:!0,isClonable:!1,isRenamable:!1};var Jl=Ql,ec=(n(801),e=>{var{widgetType:t,widgetName:n,glContainer:i,description:s}=e,r=di.getTitleFromContainer(i);return a.a.createElement("div",{className:"tab-tooltip-container"},a.a.createElement("div",{className:"row"},a.a.createElement("span",{className:"tab-tooltip-title"},a.a.createElement("b",null,t," Name ")),a.a.createElement("span",{className:"tab-tooltip-name"},n)),n!==r&&a.a.createElement("div",{className:"row"},a.a.createElement("span",{className:"tab-tooltip-title"},a.a.createElement("b",null,"Display Name")),a.a.createElement("span",{className:"tab-tooltip-name"},r)),s&&a.a.createElement("div",{className:"row"},a.a.createElement("span",{className:"tab-tooltip-description"},s)))});ec.propTypes={glContainer:Ni.Container.isRequired,widgetType:pi.a.string,widgetName:pi.a.string,description:pi.a.string},ec.defaultProps={widgetType:"",widgetName:"",description:null};var tc=ec;n(802);class nc extends i.PureComponent{constructor(e){super(e),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"getCachedRenderTabTooltip",Object(ua.a)((e=>e?()=>tc(this.props):null))),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.state={isClientDisconnected:!1,isPanelDisconnected:!1,isWidgetDisconnected:!1,isWaitingForReconnect:!1,isPanelInactive:!1}}getErrorMessage(){var{errorMessage:e}=this.props,{isClientDisconnected:t,isPanelDisconnected:n,isWidgetDisconnected:i,isWaitingForReconnect:a}=this.state;if(e)return"".concat(e);if(t&&n&&a)return"Disconnected from server.\nCheck your internet connection.";if(t&&n)return"Disconnected from server.";if(n){var{widgetName:s,widgetType:r}=this.props;return'Variable "'.concat(s,'" not set.\n').concat(r," does not exist yet.")}if(i){var{widgetName:o}=this.props;return"".concat(o," is unavailable.")}return null}handleSessionClosed(){var{onSessionClose:e}=this.props;this.setState({isPanelDisconnected:!0,isWaitingForReconnect:!1}),e(...arguments)}handleSessionOpened(){var{onSessionOpen:e}=this.props;e(...arguments)}render(){var{children:e,className:t,componentPanel:n,isLoaded:i,isLoading:s,glContainer:r,glEventHub:o,isDisconnected:l,isClonable:c,isRenamable:h,showTabTooltip:d,onClearAllFilters:u,onHide:m,onFocus:p,onBlur:g,onResize:v,onShow:f,onTabBlur:b,onTabFocus:C}=this.props,{isPanelDisconnected:S,isWidgetDisconnected:E,isPanelInactive:w}=this.state,y=this.getErrorMessage(),T=this.getCachedRenderTabTooltip(d);return a.a.createElement(Jl,{className:qe()(t,{disconnected:S||E||l,inactive:w}),componentPanel:n,glContainer:r,glEventHub:o,onClearAllFilters:u,onHide:m,onFocus:p,onBlur:g,onResize:v,onShow:f,onSessionClose:this.handleSessionClosed,onSessionOpen:this.handleSessionOpened,onTabBlur:b,onTabFocus:C,renderTabTooltip:T,errorMessage:y,isLoaded:i,isLoading:s,isClonable:c,isRenamable:h},e,w&&a.a.createElement("div",{className:"fill-parent-absolute"}))}}nc.propTypes={children:pi.a.node.isRequired,componentPanel:pi.a.instanceOf(i.Component).isRequired,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,className:pi.a.string,errorMessage:pi.a.string,isClonable:pi.a.bool,isDisconnected:pi.a.bool,isLoading:pi.a.bool,isLoaded:pi.a.bool,isRenamable:pi.a.bool,showTabTooltip:pi.a.bool,widgetName:pi.a.string,widgetType:pi.a.string,onFocus:pi.a.func,onBlur:pi.a.func,onHide:pi.a.func,onClearAllFilters:pi.a.func,onResize:pi.a.func,onSessionClose:pi.a.func,onSessionOpen:pi.a.func,onShow:pi.a.func,onTabBlur:pi.a.func,onTabFocus:pi.a.func},nc.defaultProps={className:"",errorMessage:null,isClonable:!0,isDisconnected:!1,isLoading:!1,isLoaded:!0,isRenamable:!0,showTabTooltip:!0,widgetName:"Widget",widgetType:"Widget",onFocus:()=>{},onBlur:()=>{},onHide:()=>{},onClearAllFilters:()=>{},onResize:()=>{},onSessionClose:()=>{},onSessionOpen:()=>{},onShow:()=>{},onTabBlur:()=>{},onTabFocus:()=>{}};var ic=nc,ac=Object.freeze({DEFAULT:"DEFAULT",LINKER:"LINKER"}),sc=Object.freeze({nullableBoolean:(e,t)=>null===e[t]?null:pi.a.boolean,nullableString:(e,t)=>null===e[t]?null:pi.a.string}),rc=pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired,value:sc.nullableString.isRequired}),oc=pi.a.shape({state:pi.a.shape({panelState:pi.a.shape({})})}),lc=pi.a.shape({panelId:pi.a.string.isRequired,columnName:pi.a.string.isRequired,columnType:pi.a.string.isRequired}),cc=pi.a.shape({panelId:pi.a.string.isRequired,columnName:pi.a.string.isRequired}),hc=pi.a.shape({start:cc,end:cc,id:pi.a.string,isReversed:pi.a.bool}),dc=pi.a.arrayOf(hc),uc=pi.a.shape({name:pi.a.string.isRequired,operateAs:pi.a.string.isRequired,groups:pi.a.arrayOf(pi.a.string).isRequired,permissions:pi.a.shape({isSuperUser:pi.a.bool.isRequired,isQueryViewOnly:pi.a.bool.isRequired,isNonInteractive:pi.a.bool.isRequired,canUsePanels:pi.a.bool.isRequired,canCreateDashboard:pi.a.bool.isRequired,canCreateCodeStudio:pi.a.bool.isRequired,canCreateQueryMonitor:pi.a.bool.isRequired,canCopy:pi.a.bool.isRequired,canDownloadCsv:pi.a.bool.isRequired}).isRequired}),mc=Object.freeze({InputFilter:rc,LinkPoint:lc,Link:hc,Links:dc,Panel:oc,User:uc}),pc={sessionWrapper:de("SET_SESSION_WRAPPER",null)},gc=new Map,vc=Object.freeze([]),fc=(e,t)=>{var n;return null!==(n=Wi(e,t).columns)&&void 0!==n?n:vc},bc=(e,t)=>{var n;return null!==(n=Wi(e,t).filterSets)&&void 0!==n?n:vc},Cc=(e,t)=>{var n;return null!==(n=Wi(e,t).filters)&&void 0!==n?n:vc},Sc=(e,t)=>{var n;return null!==(n=Wi(e,t).tableMap)&&void 0!==n?n:gc},Ec=(e,t)=>Wi(e,t).isolatedLinkerPanelId,wc=(e,t)=>{var n;return null!==(n=Wi(e,t).links)&&void 0!==n?n:vc},yc=(e,t)=>Wi(e,t).columnSelectionValidator,Tc=(e,t)=>Wi(e,t).sessionWrapper,Oc=(e,t)=>n=>n($i(e,{links:t})),Mc=(e,t)=>n=>n($i(e,{isolatedLinkerPanelId:t}));Object.entries(pc).map((e=>{var[t,n]=e;return Ee.register(t,n)}));var Nc=a.a.forwardRef(((e,t)=>{var{children:n,className:i,disabled:s,onClick:r,style:o,id:l}=e;return a.a.createElement("button",{ref:t,type:"button",className:qe()("btn",i),onClick:r,style:o,disabled:s,id:l},n)}));Nc.displayName="Button",Nc.propTypes={children:pi.a.node,className:pi.a.string,disabled:pi.a.bool,onClick:pi.a.func,style:pi.a.shape({}),id:pi.a.string},Nc.defaultProps={children:null,className:"",disabled:!1,onClick:()=>{},style:{},id:""};var Dc=Nc,xc=(n(803),e=>{var{columnMap:t,inputFilterMap:n,linkedColumnMap:s,onAdd:r,onOpenLinker:o,waitingFilterMap:l,waitingInputMap:c}=e,h=Object(i.useMemo)((()=>{var e=Array.from(c.keys()),t=e.find((e=>null!=n.get(e))),i=e.find((e=>null!=s.get(e))),a=Ga.join(e.map((e=>'"'.concat(e,'"'))));return t&&i?"Use a filter control or linked table to set a value for ".concat(a):t?"Set a filter control value for ".concat(a):"Double click a row in a linked table to set a value for ".concat(a)}),[n,s,c]),d=Object(i.useMemo)((()=>Array.from(t.values())),[t]),u=Object(i.useCallback)((e=>{e.stopPropagation(),e.preventDefault(),r(Array.from(l.values()))}),[r,l]),m=Object(i.useCallback)((e=>{e.stopPropagation(),e.preventDefault(),o()}),[o]),p=l.size>0,g=!p&&c.size>0;return a.a.createElement("div",{className:"chart-panel-overlay chart-filter-overlay"},a.a.createElement("div",{className:qe()("chart-panel-overlay-content chart-filter-overlay-content",{"chart-filter-waiting-filter":p},{"chart-filter-waiting-input":g})},p&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"info-message"},"This plot requires a filter control to be added to the layout or a table link to be created on the following columns:"),a.a.createElement("div",{className:"waiting-filter-list"},d.map((e=>{var t=l.has(e.name),n=t?Tt:Pt;return a.a.createElement("div",{key:e.name,className:qe()("waiting-filter-item",{"is-invalid":t})},a.a.createElement(Ke.a,{icon:n}),e.name)}))),a.a.createElement("div",null,a.a.createElement(Dc,{onClick:u,className:"btn-primary"},"Add Input Filters"),a.a.createElement(Dc,{onClick:m,className:"btn-primary"},"Open Linker Tool"))),g&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"info-message"},"Waiting for User Input"),a.a.createElement("div",{className:""},h))))});xc.propTypes={columnMap:pi.a.instanceOf(Map).isRequired,inputFilterMap:pi.a.instanceOf(Map).isRequired,linkedColumnMap:pi.a.instanceOf(Map).isRequired,onAdd:pi.a.func.isRequired,onOpenLinker:pi.a.func.isRequired,waitingFilterMap:pi.a.instanceOf(Map).isRequired,waitingInputMap:pi.a.instanceOf(Map).isRequired};var Rc=xc,Ic=(n(805),a.a.forwardRef(((e,t)=>{var{children:n,className:i,disabled:s,isLinked:r,isLinkedSource:o,isInvalid:l,onClick:c,onMouseEnter:h,onMouseLeave:d,style:u}=e;return a.a.createElement("button",{ref:t,type:"button",className:qe()("btn-socketed",{"btn-socketed-linked":r||o},{"btn-socketed-linked-source":o},{"is-invalid":l},i),onClick:c,onMouseEnter:h,onMouseLeave:d,style:u,disabled:s},n,a.a.createElement(Ke.a,{icon:Nt,className:"linked btn-socketed-icon",transform:"down-1"}),a.a.createElement(Ke.a,{icon:rn,className:"is-invalid btn-socketed-icon"}))})));Ic.displayName="SocketedButton",Ic.defaultProps={children:void 0,className:"",disabled:!1,isLinked:!1,isLinkedSource:!1,isInvalid:!1,onClick:void 0,onMouseEnter:void 0,onMouseLeave:void 0,style:void 0};var Lc=Ic,Fc=(n(804),e=>{var{columns:t,onColumnSelected:n,onMouseEnter:i,onMouseLeave:s}=e;return a.a.createElement("div",{className:"chart-panel-overlay chart-column-selector-overlay"},a.a.createElement("div",{className:qe()("chart-panel-overlay-content")},a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"info-message"},"This plot requires a filter control to be added to the layout or a table link to be created on the following columns:"),a.a.createElement("div",{className:"waiting-column-select-list"},t.map((e=>a.a.createElement(Lc,{key:e.name,className:qe()("btn-chart-column-selector",Fc.makeButtonClassName(e.name)),onClick:()=>n(e.name),onMouseEnter:()=>i(e),onMouseLeave:s,disabled:!e.isValid,isLinked:e.isActive},e.name)))))))});Fc.makeButtonClassName=e=>"btn-chart-column-selector-".concat(e),Fc.propTypes={columns:pi.a.arrayOf(pi.a.shape({name:pi.a.string.isRequired,isValid:pi.a.bool.isRequired,isActive:pi.a.bool.isRequired})).isRequired,onColumnSelected:pi.a.func.isRequired,onMouseEnter:pi.a.func,onMouseLeave:pi.a.func},Fc.defaultProps={onMouseEnter:()=>{},onMouseLeave:()=>{}};var kc=Fc;n(806);function Ac(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Pc(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ac(Object(n),!0).forEach((function(t){_c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ac(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Hc=p.module("ChartPanel");class jc extends i.Component{constructor(e){super(e),_c(this,"getWaitingInputMap",Object(ua.a)(((e,t,n)=>{if(!e)return new Map;var i=new Map(t);return n.forEach(((e,t)=>{i.delete(t)})),i}))),_c(this,"getWaitingFilterMap",Object(ua.a)(((e,t,n,i,a)=>{if(!e)return new Map;var s=new Map(t);return n.forEach(((e,t)=>{s.delete(t)})),a.forEach(((e,t)=>{s.delete(t)})),i.forEach(((e,t)=>{s.delete(t)})),s}))),_c(this,"getInputFilterColumnMap",Object(ua.a)(((e,t)=>{for(var n=new Map,i=0;i<t.length;i+=1){var a=t[i],{name:s,type:r}=a,o=e.get(s);null!=o&&o.type===r&&n.set(s,a)}return n}))),_c(this,"getLinkedColumnMap",Object(ua.a)(((e,t)=>{for(var n=new Map,i=di.getIdFromPanel(this),a=0;a<t.length;a+=1){var s=t[a],r=null;s.start&&s.start.panelId===i&&e.has(s.start.columnName)?r=s.start.columnName:s.end&&s.end.panelId===i&&e.has(s.end.columnName)&&(r=s.end.columnName),null!=r&&e.has(r)&&n.set(r,e.get(r))}return n}))),_c(this,"getSelectorColumns",Object(ua.a)(((e,t,n)=>Array.from(e.values()).map((e=>({name:e.name,type:e.type,isValid:!!n&&n(this,e),isActive:t.has(e.name)})))))),this.handleColumnSelected=this.handleColumnSelected.bind(this),this.handleColumnMouseEnter=this.handleColumnMouseEnter.bind(this),this.handleColumnMouseLeave=this.handleColumnMouseLeave.bind(this),this.handleDisconnect=this.handleDisconnect.bind(this),this.handleReconnect=this.handleReconnect.bind(this),this.handleFilterAdd=this.handleFilterAdd.bind(this),this.handleHide=this.handleHide.bind(this),this.handleError=this.handleError.bind(this),this.handleLoadError=this.handleLoadError.bind(this),this.handleLoadSuccess=this.handleLoadSuccess.bind(this),this.handleResize=this.handleResize.bind(this),this.handleSettingsChanged=this.handleSettingsChanged.bind(this),this.handleOpenLinker=this.handleOpenLinker.bind(this),this.handleShow=this.handleShow.bind(this),this.handleSourceColumnChange=this.handleSourceColumnChange.bind(this),this.handleSourceFilterChange=this.handleSourceFilterChange.bind(this),this.handleSourceSortChange=this.handleSourceSortChange.bind(this),this.handleTabBlur=this.handleTabBlur.bind(this),this.handleTabFocus=this.handleTabFocus.bind(this),this.handleUpdate=this.handleUpdate.bind(this),this.updateModelFromSource=pa()(this.updateModelFromSource.bind(this),150),this.handleClearAllFilters=this.handleClearAllFilters.bind(this),this.panelContainer=a.a.createRef(),this.chart=a.a.createRef(),this.pending=new Ua;var{metadata:t,panelState:n}=e,{filterValueMap:i=[],settings:s={}}=null!==n&&void 0!==n?n:{},r=t.query;this.state={settings:s,error:null,isActive:!1,isDisconnected:!1,isLoading:!1,isLoaded:!1,isLinked:t&&t.settings&&t.settings.isLinked,filterMap:new Map(i),filterValueMap:new Map(i),model:null,columnMap:new Map,queryName:r,panelState:n}}componentDidMount(){this.isHidden()||(this.setState({isActive:!0}),this.initModel())}componentDidUpdate(e,t){var{inputFilters:n,source:i}=this.props,{columnMap:a,model:s,filterMap:r,filterValueMap:o,isLinked:l,settings:c}=this.state;s&&(a!==t.columnMap&&this.pruneFilterMaps(),n!==e.inputFilters&&this.updateChangedInputFilters(n,e.inputFilters),r!==t.filterMap?this.updateFilters():o!==t.filterValueMap&&this.updatePanelState(),c!==t.settings&&(s.updateSettings(c),this.updatePanelState()),l!==t.isLinked?i&&(l?(this.startListeningToSource(i),this.updateModelFromSource()):this.stopListeningToSource(i)):l&&i!==e.source&&(e.source&&this.stopListeningToSource(e.source),i&&(this.startListeningToSource(i),this.updateModelFromSource())))}componentWillUnmount(){this.pending.cancel();var{source:e}=this.props;e&&this.stopListeningToSource(e)}initModel(){this.setState({isLoading:!0,isLoaded:!1,error:null});var{makeModel:e}=this.props;this.pending.add(e(),(e=>{e.close()})).then(this.handleLoadSuccess,this.handleLoadError)}startListeningToSource(e){Hc.debug("startListeningToSource",e),e.addEventListener(va.Table.EVENT_CUSTOMCOLUMNSCHANGED,this.handleSourceColumnChange),e.addEventListener(va.Table.EVENT_FILTERCHANGED,this.handleSourceFilterChange),e.addEventListener(va.Table.EVENT_SORTCHANGED,this.handleSourceSortChange)}stopListeningToSource(e){Hc.debug("stopListeningToSource",e),e.removeEventListener(va.Table.EVENT_CUSTOMCOLUMNSCHANGED,this.handleSourceColumnChange),e.removeEventListener(va.Table.EVENT_FILTERCHANGED,this.handleSourceFilterChange),e.removeEventListener(va.Table.EVENT_SORTCHANGED,this.handleSourceSortChange)}loadModelIfNecessary(){var{isActive:e,isLoaded:t,isLoading:n}=this.state;!e||t||n||this.initModel()}isHidden(){var{glContainer:e}=this.props,{isHidden:t}=e;return t}handleColumnSelected(e){var{glEventHub:t}=this.props,{columnMap:n}=this.state;t.emit(Dl.COLUMN_SELECTED,this,n.get(e))}handleColumnMouseEnter(e){var{type:t,name:n}=e,{columnSelectionValidator:i}=this.props;Hc.debug("handleColumnMouseEnter",i,t,n),i&&i(this,{type:t,name:n})}handleColumnMouseLeave(){var{columnSelectionValidator:e}=this.props;Hc.debug("handleColumnMouseLeave",e),e&&e(this,null)}handleDisconnect(){this.setState({error:new Error("Figure disconnected"),isDisconnected:!0})}handleFilterAdd(e){for(var t=0;t<e.length;t+=1)this.openInputFilter(e[t])}handleOpenLinker(){var{localDashboardId:e,setActiveTool:t,setDashboardIsolatedLinkerPanelId:n}=this.props;n(e,void 0),t(ac.LINKER)}handleReconnect(){this.setState({isDisconnected:!1,error:null}),this.sendColumnChange(),this.updateColumnFilters()}handleLoadSuccess(e){Hc.debug("handleLoadSuccess");var{model:t}=this.state;this.setState({model:e,isLoaded:!0},(()=>{var{inputFilters:n,source:i}=this.props,{filterMap:a,isLinked:s}=this.state;e!==t&&(this.sendColumnChange(),this.updateColumnFilters(),this.updateInputFilters(n,a.size>0||e.isFilterRequired()),i&&s&&(this.startListeningToSource(i),this.updateModelFromSource()))}))}handleLoadError(e){Va.isCanceled(e)||(Hc.error("handleLoadError",e),this.setState({error:e,isLoading:!1}))}handleSourceColumnChange(){this.updateModelFromSource()}handleSourceFilterChange(){this.updateModelFromSource()}handleSourceSortChange(){this.updateModelFromSource()}updateModelFromSource(){var{metadata:e,source:t}=this.props,{isLinked:n,model:i}=this.state,{settings:a}=e;n&&i&&t?(this.pending.cancel(),this.pending.add(va.plot.Figure.create(fs.makeFigureSettings(a,t))).then((e=>{i.setFigure(e)})).catch(this.handleLoadError),this.updatePanelState()):Hc.debug2("updateModelFromSource ignoring",n,i,t)}updatePanelState(){var{sourcePanel:e}=this.props,{panelState:t,filterValueMap:n,settings:i}=this.state,{tableSettings:a}=null!==t&&void 0!==t?t:{};if(e){var{inputFilters:s}=e.props,{panelState:r}=e.state;r&&(a=ol.extractTableSettings(r,s))}this.setState({panelState:{settings:i,tableSettings:a,filterValueMap:Array.from(n)}})}handleError(){this.setState({isLoading:!1})}handleResize(){this.updateChart()}handleSettingsChanged(e){this.setState((t=>{var{settings:n}=t,i=Pc(Pc({},n),e);return Hc.debug("Updated settings",i),{settings:i}}))}handleHide(){this.setActive(!1)}handleShow(){this.setActive(!0)}handleTabBlur(){this.setActive(!1)}handleTabFocus(){var e=this.isHidden();this.setActive(!e)}handleUpdate(){this.setState({isLoading:!1})}handleClearAllFilters(){this.setState({filterValueMap:new Map,filterMap:new Map}),this.updatePanelState()}openInputFilter(e){var{glEventHub:t}=this.props,{name:n,type:i}=e;t.emit(kl.OPEN_INPUT,{title:"".concat(n," Filter"),panelState:{name:n,type:i,isValueShown:!0},createNewStack:!0,focusElement:"input"})}setActive(e){this.setState({isActive:e},(()=>{e&&(this.loadModelIfNecessary(),this.updateChart())}))}sendColumnChange(){var{model:e}=this.state;if(e){var{glEventHub:t}=this.props;t.emit(kl.COLUMNS_CHANGED,this,Array.from(e.getFilterColumnMap().values()))}}getCoordinateForColumn(e){var t,n=kc.makeButtonClassName(e);if(!this.panelContainer.current)return null;var i=this.panelContainer.current.querySelector(".".concat(n)),a=null!==(t=null===i||void 0===i?void 0:i.getBoundingClientRect())&&void 0!==t?t:null;return null==a||a.width<=0||a.height<=0?null:[a.left+a.width/2,a.bottom]}setFilterMap(e){Hc.debug("setFilterMap",e),this.setState((t=>{var n,{columnMap:i,filterMap:a}=t,s=null,r=new Map(t.filterValueMap);return e.forEach(((e,t)=>{var{columnType:n,value:o}=e,l=i.get(t);null!=l&&l.type===n&&(r.set(t,o),a.get(t)!==o&&(null===s&&(s=new Map(a)),s.set(t,o)))})),{filterValueMap:r,filterMap:null!==(n=s)&&void 0!==n?n:a}}))}unsetFilterValue(e){this.setState((t=>{var{inputFilters:n}=this.props,{columnMap:i}=t,{filterMap:a,filterValueMap:s}=t;if(!s.has(e))return null;(s=new Map(t.filterValueMap)).delete(e);var r=this.getInputFilterColumnMap(i,n);if(r.has(e)){var o=a.get(e),l=r.get(e).value;null!=l&&o!==l&&(a=new Map(t.filterMap),l.length>0?a.set(e,l):a.delete(e))}else(a=new Map(t.filterMap)).delete(e);return{filterMap:a,filterValueMap:s}}))}updateChangedInputFilters(e,t){var n=t.filter((t=>!e.find((e=>e.name===t.name&&e.type===t.type))));n.length>0&&this.deleteInputFilters(n);var i=e.filter((e=>!t.includes(e)));i.length>0&&this.updateInputFilters(i)}updateInputFilters(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.setState((n=>{for(var{columnMap:i}=n,a=new Map(n.filterValueMap),s=new Map(n.filterMap),r=t?{filterMap:s,filterValueMap:a}:{},o=0;o<e.length;o+=1){var{name:l,type:c,value:h}=e[o],d=i.get(l);null!=d&&d.type===c&&(null!=h&&s.get(l)!==h&&(""===h?s.delete(l):s.set(l,h),r.filterMap=s),a.has(l)&&(a.delete(l),r.filterValueMap=a))}return Hc.debug("updateInputFilters",r),r}))}deleteInputFilters(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.setState((n=>{for(var{columnMap:i,filterValueMap:a}=n,s=new Map(n.filterMap),r=t,o=0;o<e.length;o+=1){var{name:l,type:c}=e[o],h=i.get(l);if(null!=h&&h.type===c&&s.has(l)){var d=s.get(l);if(a.has(l)){var u=a.get(l);u!==d&&(r=!0,s.set(l,u))}else r=!0,s.delete(l)}}return Hc.debug("deleteInputFilters",r),r?{filterMap:s}:null}))}updateColumnFilters(){this.setState((e=>{var{model:t}=e;return t?{columnMap:t.getFilterColumnMap()}:null}))}updateFilters(){var{columnMap:e,filterMap:t,model:n}=this.state,i=this.getWaitingInputMap(n.isFilterRequired(),e,t);if(n.setFilter(t),t.size>0&&0===i.size){var a=n.getDefaultTitle(),s=Ga.join(Array.from(t.entries()).map((e=>{var[t,n]=e;return"".concat(t,": ").concat(n)})));a?n.setTitle("".concat(a,'<br><span style="font-size: smaller">').concat(s,"</span>")):n.setTitle(s),Hc.debug2("updateFilters filters set",t),this.setState({isLoading:!0})}else Hc.debug2("updateFilters waiting on inputs",i),n.setTitle(n.getDefaultTitle()),this.setState({isLoading:!1});this.updatePanelState()}pruneFilterMaps(){this.setState((e=>{var{columnMap:t}=e,n=new Map(e.filterMap),i=new Map(e.filterValueMap),a={};return e.filterValueMap.forEach(((e,n)=>{t.has(n)||(i.delete(n),a.filterValueMap=i)})),e.filterMap.forEach(((e,i)=>{t.has(i)||(n.delete(i),a.filterMap=n)})),a}))}updateChart(){this.chart.current&&this.chart.current.updateDimensions()}render(){var{columnSelectionValidator:e,glContainer:t,glEventHub:n,inputFilters:i,isLinkerActive:s,links:r,metadata:o,settings:l}=this.props,{columnMap:c,filterMap:h,error:d,model:u,queryName:m,isActive:p,isDisconnected:g,isLoaded:v,isLoading:f}=this.state,{figure:b,querySerial:C,table:S}=o,E=this.getInputFilterColumnMap(c,i),w=this.getLinkedColumnMap(c,r),y=null!=u?this.getWaitingInputMap(u.isFilterRequired(),c,h):new Map,T=null!=u?this.getWaitingFilterMap(u.isFilterRequired(),c,h,w,E):new Map,O=d?"Unable to open chart. ".concat(d):null,M=y.size>0,N=c.size>0&&s;return a.a.createElement(ic,{className:qe()("iris-chart-panel",{"input-required":M}),componentPanel:this,glContainer:t,glEventHub:n,onHide:this.handleHide,onClearAllFilters:this.handleClearAllFilters,onResize:this.handleResize,onShow:this.handleShow,onTabBlur:this.handleTabBlur,onTabFocus:this.handleTabFocus,errorMessage:O,isDisconnected:g,isLoading:f,isLoaded:v,queryName:m,querySerial:C,widgetName:b||S,widgetType:"Chart"},a.a.createElement("div",{ref:this.panelContainer,className:"chart-panel-container h-100 w-100"},a.a.createElement("div",{className:"chart-container h-100 w-100"},v&&a.a.createElement(ur,{isActive:p,model:u,settings:l,ref:this.chart,onDisconnect:this.handleDisconnect,onReconnect:this.handleReconnect,onUpdate:this.handleUpdate,onError:this.handleError,onSettingsChanged:this.handleSettingsChanged})),a.a.createElement(We.CSSTransition,{in:M&&!N&&!f,timeout:Kn.transitionMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement(Rc,{inputFilterMap:E,linkedColumnMap:w,onAdd:this.handleFilterAdd,onOpenLinker:this.handleOpenLinker,columnMap:c,waitingFilterMap:T,waitingInputMap:y})),a.a.createElement(We.CSSTransition,{in:N,timeout:Kn.transitionMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement(kc,{columns:this.getSelectorColumns(c,w,e),onColumnSelected:this.handleColumnSelected,onMouseEnter:this.handleColumnMouseEnter,onMouseLeave:this.handleColumnMouseLeave}))))}}_c(jc,"COMPONENT","ChartPanel"),jc.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,metadata:pi.a.shape({figure:pi.a.string,table:pi.a.string,query:pi.a.string,querySerial:pi.a.string,sourcePanelId:pi.a.string,settings:pi.a.shape({isLinked:pi.a.bool})}).isRequired,makeModel:pi.a.func.isRequired,inputFilters:pi.a.arrayOf(mc.InputFilter).isRequired,links:mc.Links.isRequired,localDashboardId:pi.a.string.isRequired,isLinkerActive:pi.a.bool,source:Ma.Table,sourcePanel:mc.Panel,columnSelectionValidator:pi.a.func,setActiveTool:pi.a.func.isRequired,setDashboardIsolatedLinkerPanelId:pi.a.func.isRequired,panelState:pi.a.shape({}),settings:pi.a.shape({})},jc.defaultProps={columnSelectionValidator:null,isLinkerActive:!1,source:null,sourcePanel:null,panelState:null,settings:{}},jc.displayName="ChartPanel";var Vc=Object(o.b)(((e,t)=>{var{localDashboardId:n,metadata:i={}}=t,{sourcePanelId:a}=i,s=Sc(e,n),r=qi(e,n),o=U(e),l=Ec(e,n),c=o===ac.LINKER&&void 0===l;return{columnSelectionValidator:yc(e,n),isLinkerActive:c,inputFilters:Cc(e,n),links:wc(e,n),source:s.get(a),sourcePanel:r.get(a),settings:_(e)}}),{setActiveTool:te,setDashboardIsolatedLinkerPanelId:Mc},null,{forwardRef:!0})(jc),zc={CONSOLE:{name:"Console",CLEAR:Be.createAndAdd({id:"CONSOLE.CLEAR",name:"Clear",shortcut:[_e.CTRL,He.L],macShortcut:[_e.CTRL,He.C]}),FOCUS_HISTORY:Be.createAndAdd({id:"CONSOLE.FOCUS_HISTORY",name:"Focus History",shortcut:[_e.CTRL,He.H],macShortcut:[_e.CTRL,_e.OPTION,He.H]})},COMMAND_HISTORY:{name:"Command History",FOCUS_HISTORY:Be.createAndAdd({id:"COMMAND_HISTORY.FOCUS_HISTORY",name:"Focus History Search",shortcut:[_e.CTRL,He.H],macShortcut:[_e.CTRL,_e.OPTION,He.H]}),SEND_TO_CONSOLE:Be.createAndAdd({id:"COMMAND_HISTORY.SEND_TO_CONSOLE",name:"Send to Console",shortcut:[He.ENTER],macShortcut:[He.ENTER]}),SEND_TO_NOTEBOOK:Be.createAndAdd({id:"COMMAND_HISTORY.SEND_TO_NOTEBOOK",name:"Send to Notebook",shortcut:[_e.CTRL,He.ENTER],macShortcut:[_e.CMD,He.ENTER]}),RUN:Be.createAndAdd({id:"COMMAND_HISTORY.RUN",name:"Run",shortcut:[_e.ALT,He.R],macShortcut:[_e.OPTION,He.R]})}},Uc={COPY:Be.createAndAdd({id:"GLOBAL.COPY",name:"Copy",shortcut:[_e.CTRL,He.C],macShortcut:[_e.CMD,He.C],isEditable:!1}),PASTE:Be.createAndAdd({id:"GLOBAL.PASTE",name:"Paste",shortcut:[_e.CTRL,He.V],macShortcut:[_e.CMD,He.V],isEditable:!1}),SAVE:Be.createAndAdd({id:"GLOBAL.SAVE",name:"Save",shortcut:[_e.CTRL,He.S],macShortcut:[_e.CMD,He.S],isEditable:!1}),SELECT_ALL:Be.createAndAdd({id:"GLOBAL.SELECT_ALL",name:"Select All",shortcut:[_e.CTRL,He.A],macShortcut:[_e.CMD,He.A],isEditable:!1}),LINKER:Be.createAndAdd({id:"GLOBAL.LINKER",name:"Linker",shortcut:[_e.CTRL,He.L],macShortcut:[_e.CMD,He.L]}),LINKER_CLOSE:Be.createAndAdd({id:"GLOBAL.LINKER_CLOSE",name:"Close Linker Overlay",shortcut:[He.ESCAPE],macShortcut:[He.ESCAPE],isEditable:!1})};n(1160);function Bc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Wc extends i.PureComponent{constructor(e){super(e),Bc(this,"inputField",void 0),this.inputField=a.a.createRef()}focus(){var e;null===(e=this.inputField.current)||void 0===e||e.focus()}render(){var{value:e,placeholder:t,onChange:n,className:i,matchCount:s,id:r,onKeyDown:o}=this.props;return a.a.createElement("div",{className:qe()("search-group",i)},a.a.createElement("input",{type:"search",value:e,onChange:n,onKeyDown:o,className:"form-control",placeholder:t,ref:this.inputField,id:r}),null!=s&&a.a.createElement("span",{className:"search-match"},s),a.a.createElement("span",{className:"search-icon"},a.a.createElement(Ke.a,{icon:qt})))}}Bc(Wc,"defaultProps",{placeholder:"Search",className:"",matchCount:null,onKeyDown(){},id:""});var Gc=Wc,qc=n(725),Kc=n(724);n(1163);function Yc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Xc=p.module("ItemListItem");class Zc extends i.Component{static handleKeyDown(){return Xc.log("ItemListItem.handleKeyDown false"),!1}constructor(e){super(e),Yc(this,"itemRef",void 0),this.handleBlur=this.handleBlur.bind(this),this.handleFocus=this.handleFocus.bind(this),this.handleClick=this.handleClick.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.handleDragStart=this.handleDragStart.bind(this),this.handleDrag=this.handleDrag.bind(this),this.handleDragOver=this.handleDragOver.bind(this),this.handleDragEnd=this.handleDragEnd.bind(this),this.handleDrop=this.handleDrop.bind(this),this.handleDoubleClick=this.handleDoubleClick.bind(this),this.handleMouseDown=this.handleMouseDown.bind(this),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseUp=this.handleMouseUp.bind(this),this.itemRef=a.a.createRef()}handleBlur(e){var{itemIndex:t,onBlur:n}=this.props;n(t,e)}handleFocus(e){var{itemIndex:t,onFocus:n}=this.props;n(t,e)}handleClick(e){var{itemIndex:t,onClick:n}=this.props;n(t,e)}handleContextMenu(e){var{itemIndex:t,onContextMenu:n}=this.props;n(t,e)}handleDragStart(e){var{itemIndex:t,onDragStart:n}=this.props;n(t,e)}handleDrag(e){var{itemIndex:t,onDrag:n}=this.props;n(t,e)}handleDragOver(e){e.preventDefault();var{itemIndex:t,onDragOver:n}=this.props;n(t,e)}handleDragEnd(e){var{itemIndex:t,onDragEnd:n}=this.props;n(t,e)}handleDrop(e){var{itemIndex:t,onDrop:n}=this.props;n(t,e)}handleDoubleClick(e){var{itemIndex:t,onDoubleClick:n}=this.props;n(t,e)}handleMouseMove(e){var{itemIndex:t,onMouseMove:n}=this.props;n(t,e)}handleMouseDown(e){var{itemIndex:t,onMouseDown:n}=this.props;n(t,e)}handleMouseUp(e){var{itemIndex:t,onMouseUp:n}=this.props;n(t,e)}render(){var{isDraggable:e,isFocused:t,isSelected:n,style:i,children:s}=this.props;return a.a.createElement("div",{className:qe()("item-list-item",{active:n},{"is-focused":t},{"is-draggable":e}),onKeyDown:Zc.handleKeyDown,onContextMenu:this.handleContextMenu,onClick:this.handleClick,onDrag:this.handleDrag,onDragStart:this.handleDragStart,onDragOver:this.handleDragOver,onDragEnd:this.handleDragEnd,onDrop:this.handleDrop,onDoubleClick:this.handleDoubleClick,onMouseDown:this.handleMouseDown,onMouseMove:this.handleMouseMove,onMouseUp:this.handleMouseUp,tabIndex:-1,ref:this.itemRef,role:"presentation",style:i,onFocus:this.handleFocus,onBlur:this.handleBlur,draggable:e},s)}}Yc(Zc,"defaultProps",{children:null,isDraggable:!1,isFocused:!1,isSelected:!1,itemIndex:0,disableSelect:!1,onBlur(){},onClick(){},onContextMenu(){},onDragStart(){},onDrag(){},onDragOver(){},onDragEnd(){},onDrop(){},onDoubleClick(){},onFocus(){},onMouseDown(){},onMouseMove(){},onMouseUp(){},style:{}});var $c=Zc;n(1162);function Qc(){return Qc=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Qc.apply(this,arguments)}function Jc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var eh=p.module("ItemList");class th extends i.PureComponent{static renderItem(e){var{item:t}=e;return a.a.createElement("div",{className:"item-list-item-content"},t&&(t.displayValue||t.value||"".concat(t)))}constructor(e){super(e),Jc(this,"list",void 0),Jc(this,"listContainer",void 0),Jc(this,"getItemSelected",Lr()(((e,t)=>Wa.isSelected(t,e)),{max:th.CACHE_SIZE})),Jc(this,"getCachedItem",Lr()(((e,t,n,i,s,r,o,l)=>{var c=r({item:n,itemIndex:e,isFocused:i,isSelected:s,style:o});return a.a.createElement($c,{onContextMenu:this.handleItemContextMenu,onDoubleClick:this.handleItemDoubleClick,onMouseDown:this.handleItemMouseDown,onFocus:this.handleItemFocus,onBlur:this.handleItemBlur,disableSelect:l,onMouseMove:this.handleItemMouseMove,onMouseUp:this.handleItemMouseUp,isFocused:i,isSelected:s,itemIndex:e,style:o,key:t},c)}),{max:th.CACHE_SIZE})),Jc(this,"getOuterElement",Lr()((e=>{var t=a.a.forwardRef(((t,n)=>a.a.createElement("div",Qc({ref:n,tabIndex:-1,onKeyDown:e,role:"presentation"},t))));return t.displayName="ItemListOuterElement",t}))),Jc(this,"getInnerElement",Lr()((()=>{var e=a.a.forwardRef(((e,t)=>a.a.createElement("div",Qc({className:"item-list-inner-element",ref:t},e))));return e.displayName="ItemListInnerElement",e}))),Jc(this,"getItemData",Lr()(((e,t,n)=>({items:e,selectedRanges:t,renderItem:n})))),this.handleItemBlur=this.handleItemBlur.bind(this),this.handleItemContextMenu=this.handleItemContextMenu.bind(this),this.handleItemFocus=this.handleItemFocus.bind(this),this.handleItemDoubleClick=this.handleItemDoubleClick.bind(this),this.handleItemMouseDown=this.handleItemMouseDown.bind(this),this.handleItemMouseMove=this.handleItemMouseMove.bind(this),this.handleItemMouseUp=this.handleItemMouseUp.bind(this),this.handleItemsRendered=this.handleItemsRendered.bind(this),this.handleWindowMouseUp=this.handleWindowMouseUp.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleScroll=this.handleScroll.bind(this),this.handleResize=this.handleResize.bind(this),this.renderInnerElement=this.renderInnerElement.bind(this),this.list=a.a.createRef(),this.listContainer=a.a.createRef();var{isStickyBottom:t,selectedRanges:n}=e;this.state={focusIndex:null,mouseDownIndex:null,selectedRanges:n,overscanStartIndex:0,height:null,isDragging:!1,isStuckToBottom:t,scrollOffset:null}}componentDidMount(){var{isStickyBottom:e}=this.props;e&&!this.isListAtBottom()&&this.scrollToBottom()}componentDidUpdate(e,t){var{selectedRanges:n}=this.props,{focusIndex:i,isStuckToBottom:a,scrollOffset:s,height:r,selectedRanges:o}=this.state;if(a&&!this.isListAtBottom()&&this.scrollToBottom(),s===t.scrollOffset&&r===t.height||this.sendViewportUpdate(),n!==e.selectedRanges&&n!==o)this.setSelectedRanges(n);else if(o!==t.selectedRanges){var{onSelectionChange:l}=this.props;l(o)}if(i!==t.focusIndex){var{onFocusChange:c}=this.props;c(i)}}componentWillUnmount(){window.removeEventListener("mouseup",this.handleWindowMouseUp)}focus(){var e;null===(e=this.listContainer.current)||void 0===e||e.focus()}getElement(e){if(null==this.listContainer.current)return null;var{focusSelector:t}=this.props,{overscanStartIndex:n}=this.state;return this.listContainer.current.querySelectorAll(t)[e-n]}focusItem(e){var{disableSelect:t}=this.props;if(!t){this.setState({focusIndex:e});var n=this.getElement(e);n instanceof HTMLElement&&n.focus()}}scrollToItem(e){var t=this.getElement(e);null!=t&&t.scrollIntoView({block:"center"})}handleItemContextMenu(e,t){var{selectedRanges:n}=this.state,i=Wa.isSelected(n,e)||je.isModifierKeyDown(t);this.toggleSelect(e,t.shiftKey,i,!1)}handleItemDoubleClick(e,t){var{isDoubleClickSelect:n,onSelect:i}=this.props;n&&this.setState((t=>{var{selectedRanges:n}=t;return{selectedRanges:Wa.selectRange(n,[e,e])}}),(()=>{i(e,t)}))}handleItemMouseDown(e,t){var{selectedRanges:n}=this.state;if(!(t.target instanceof HTMLElement&&-1!==["button","select","input","textarea"].indexOf(t.target.tagName.toLowerCase())))return 2===t.button&&0===n.length?(this.focusItem(e),void this.selectItem(e)):void(null!=t.button&&0!==t.button||(this.setState({mouseDownIndex:e}),window.addEventListener("mouseup",this.handleWindowMouseUp)))}handleItemBlur(e,t){eh.debug2("item blur",e,t.currentTarget,t.relatedTarget),(!t.relatedTarget||this.listContainer.current&&t.relatedTarget instanceof HTMLElement&&!this.listContainer.current.contains(t.relatedTarget))&&this.setState({focusIndex:null})}handleItemFocus(e,t){eh.debug2("item focus",e,t.target),this.setState((t=>{var{focusIndex:n}=t;return n!==e?{focusIndex:e}:null}))}handleItemMouseMove(e,t){var{isDragSelect:n,isMultiSelect:i,disableSelect:a}=this.props,{mouseDownIndex:s,selectedRanges:r}=this.state;null==s||a||(this.setState({isDragging:!0}),(n||s===e)&&(this.focusItem(e),i?(n||this.getItemSelected(e,r)||je.isModifierKeyDown(t)||this.deselectAll(),this.selectRange([Math.min(s,e),Math.max(s,e)])):this.toggleSelect(e,t.shiftKey,je.isModifierKeyDown(t),!1)))}handleItemMouseUp(e,t){var{isDeselectOnClick:n,isDoubleClickSelect:i,onSelect:a}=this.props,{mouseDownIndex:s,isDragging:r}=this.state;if(!(t.target instanceof HTMLElement&&-1!==["button","select","input","textarea"].indexOf(t.target.tagName.toLowerCase()))){if(s===e&&!r){var o=t.shiftKey,l=je.isModifierKeyDown(t);this.focusItem(e),this.toggleSelect(e,o,l,n),i||o||l||a(e,t)}this.resetMouseState()}}handleItemsRendered(e){var{overscanStartIndex:t}=e;this.setState({overscanStartIndex:t})}handleResize(e){var{height:t}=e;this.setState({height:t})}handleMouseLeave(){this.setState({mouseDownIndex:null})}handleWindowMouseUp(){this.resetMouseState(),window.removeEventListener("mouseup",this.handleWindowMouseUp)}handleKeyDown(e){var{isMultiSelect:t,itemCount:n,onSelect:i}=this.props,{focusIndex:a}=this.state,s=a;if("Enter"!==e.key&&" "!==e.key){if("ArrowUp"===e.key)s=null!=s&&s>=0?Math.max(0,s-1):n-1;else{if("ArrowDown"!==e.key)return;s=null!=s&&s>=0?Math.min(s+1,n-1):0}if(a!==s){e.stopPropagation(),e.preventDefault(),this.focusItem(s);var{selectedRanges:r}=this.state;if(e.shiftKey&&r.length>0){var o=r[r.length-1];this.selectRange([Math.min(s,o[0]),Math.max(s,o[1])])}else{var l;if(this.deselectAll(),null!==s)this.selectItem(s);else null===(l=this.listContainer.current)||void 0===l||l.focus()}this.scrollIntoView(s)}}else t||null==s||this.setState({selectedRanges:[[s,s]]},(()=>{null!=s&&i(s,e)}))}handleScroll(e){var{scrollUpdateWasRequested:t,scrollOffset:n}=e;this.setState((e=>{if(t)return{scrollOffset:n};var{isStickyBottom:i}=this.props,{height:a}=e;return{isStuckToBottom:i&&this.isListAtBottom({scrollOffset:n,height:a}),scrollOffset:n}}))}resetMouseState(){this.setState({mouseDownIndex:null,isDragging:!1})}scrollToBottom(){var{itemCount:e}=this.props;this.list.current&&this.list.current.scrollToItem(e)}scrollIntoView(e){this.list.current&&this.list.current.scrollToItem(e)}toggleSelect(e,t,n){var i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],{isMultiSelect:a}=this.props,{selectedRanges:s}=this.state;if(a&&t&&s.length>0){var r=s[s.length-1];this.selectRange([Math.min(r[0],e),Math.max(e,r[1])])}else a&&1===s.length&&s[0][0]===e&&s[0][1]===e?i&&this.deselectItem(e):a&&n?this.getItemSelected(e,s)?i&&this.deselectItem(e):this.selectItem(e):(this.deselectAll(),this.selectItem(e))}deselectAll(){var{itemCount:e}=this.props;this.deselectRange([0,e])}deselectItem(e){this.deselectRange([e,e])}deselectRange(e){Wa.validateRange(e),this.setState((t=>{var{selectedRanges:n}=t;return{selectedRanges:Wa.deselectRange(n,e)}}))}selectItem(e){var{disableSelect:t}=this.props;t||this.selectRange([e,e])}selectRange(e){Wa.validateRange(e),this.setState((t=>{var{selectedRanges:n}=t;return{selectedRanges:Wa.selectRange(n,e)}}))}setSelectedRanges(e){this.setState({selectedRanges:e})}sendViewportUpdate(){var{scrollOffset:e,height:t}=this.state;if(null!=e&&null!=t){var{onViewportChange:n,rowHeight:i}=this.props,a=Math.floor(e/i);n(a,a+Math.ceil(t/i))}}isListAtBottom(){var{scrollOffset:e,height:t}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.state;if(null==t||null==e)return!1;var{itemCount:n,rowHeight:i}=this.props;return e+t>=n*i}renderInnerElement(e){var{index:t,style:n}=e,{items:i,offset:a,renderItem:s,disableSelect:r}=this.props,{focusIndex:o,selectedRanges:l}=this.state;if(t<a||t>=a+i.length)return null;var c=i[t-a];return this.getCachedItem(t,t,c,t===o&&!r,this.getItemSelected(t,l),s,n,r)}render(){var{items:e,itemCount:t,overscanCount:n,renderItem:i,rowHeight:s}=this.props,{selectedRanges:r}=this.state;return a.a.createElement(Kc.a,{className:"item-list-auto-sizer",onResize:this.handleResize},(o=>{var{width:l,height:c}=o;return a.a.createElement(qc.a,{className:"item-list-scroll-pane",height:c,width:l,itemCount:t,itemSize:s,itemData:this.getItemData(e,r,i),onScroll:this.handleScroll,onItemsRendered:this.handleItemsRendered,ref:this.list,outerElementType:this.getOuterElement(this.handleKeyDown),outerRef:this.listContainer,innerElementType:this.getInnerElement(),overscanCount:n},this.renderInnerElement)}))}}Jc(th,"CACHE_SIZE",1e3),Jc(th,"DEFAULT_ROW_HEIGHT",20),Jc(th,"DEFAULT_OVERSCAN",10),Jc(th,"defaultProps",{offset:0,items:[],rowHeight:th.DEFAULT_ROW_HEIGHT,isDeselectOnClick:!0,isDoubleClickSelect:!1,isDragSelect:!0,isMultiSelect:!1,isStickyBottom:!1,disableSelect:!1,onFocusChange(){},onSelect(){},onSelectionChange(){},onViewportChange(){},overscanCount:th.DEFAULT_OVERSCAN,renderItem:th.renderItem,selectedRanges:[],focusSelector:".item-list-item"});var nh=th;n(1120);class ih extends i.Component{constructor(e){super(e),this.container=null}componentDidMount(){this.colorize()}colorize(){var{children:e}=this.props;this.container&&e&&l.c.colorizeElement(this.container,{theme:"dh-dark"})}render(){var{children:e,language:t}=this.props;return a.a.createElement("div",null,a.a.createElement("div",{"data-lang":t,ref:e=>{this.container=e},style:{pointerEvents:"none"}},e))}}ih.propTypes={children:pi.a.node.isRequired,language:pi.a.string.isRequired};var ah=ih,sh=(n(1121),pi.a.shape({id:pi.a.string.isRequired,name:pi.a.string.isRequired})),rh=Object.freeze({CommandHistoryItem:sh}),oh=pi.a.shape({addItem:pi.a.func.isRequired,updateItem:pi.a.func.isRequired,getTable:pi.a.func.isRequired}),lh=pi.a.shape({size:pi.a.number.isRequired,getSnapshot:pi.a.func.isRequired}),ch=Object.freeze({CommandHistoryStorage:oh,CommandHistoryTable:lh});class hh extends i.Component{static getTimeString(e,t){if(!e||!t)return null;var n=Math.round((new Date(t)-new Date(e))/1e3);return n<1?"<1s":Ya.formatElapsedTime(n)}constructor(e){super(e),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"getPreviewText",Lr()((e=>e.split("\n",2500).join("\n")),{max:1})),this.loadData=pa()(this.loadData.bind(this),250),this.handleUpdate=this.handleUpdate.bind(this),this.handleError=this.handleError.bind(this),this.handleTimeout=this.handleTimeout.bind(this),this.timer=null,this.cleanup=null,this.state={currentTime:Date.now(),data:null,error:null}}componentDidMount(){this.loadData()}componentDidUpdate(e,t){var n,i,{data:a}=this.state;null!=this.timer||null!==a&&void 0!==a&&a.result||null===a||void 0===a||!a.startTime||null!==a&&void 0!==a&&a.endTime?(null===a||void 0===a||!a.result||null!==(n=t.data)&&void 0!==n&&n.result)&&(null===a||void 0===a||!a.endTime||null!==(i=t.data)&&void 0!==i&&i.endTime)||this.stopTimer():this.startTimer()}componentWillUnmount(){this.loadData.cancel(),null!=this.cleanup&&this.cleanup(),this.stopTimer()}loadData(){var{commandHistoryStorage:e,item:t,language:n}=this.props,{id:i}=t;this.cleanup=e.listenItem(n,i,this.handleUpdate,this.handleError)}startTimer(){this.stopTimer(),this.timer=setInterval(this.handleTimeout,1e3)}stopTimer(){this.timer&&(clearInterval(this.timer),this.timer=null)}updateTime(){this.setState({currentTime:Date.now()})}handleError(e){this.setState({error:"".concat(e)})}handleUpdate(e){var{data:t=null}=null!==e&&void 0!==e?e:{};this.setState({data:t});var{onUpdate:n}=this.props;n(t)}handleTimeout(){this.updateTime()}render(){var e,t,n,{item:{name:i},language:s}=this.props,{currentTime:r,data:o,error:l}=this.state,{result:c,startTime:h,endTime:d}=null!==o&&void 0!==o?o:{},u=null!==(e=null!==(t=null===c||void 0===c||null===(n=c.error)||void 0===n?void 0:n.message)&&void 0!==t?t:null===c||void 0===c?void 0:c.error)&&void 0!==e?e:l,m=hh.getTimeString(h,d||r),p=this.getPreviewText(i);return a.a.createElement("div",{className:"command-history-item-tooltip"},a.a.createElement(ah,{language:s},p),p.length<i.length&&a.a.createElement("p",null,"Preview Truncated..."),a.a.createElement("div",{className:"result-info"},!m&&a.a.createElement(Yn,null),m&&a.a.createElement("div",{className:"time-string"},m)),u&&a.a.createElement(a.a.Fragment,null,a.a.createElement("hr",null),a.a.createElement("div",{key:"error",className:"error-message"},u)))}}hh.propTypes={item:rh.CommandHistoryItem.isRequired,language:pi.a.string.isRequired,onUpdate:pi.a.func,commandHistoryStorage:ch.CommandHistoryStorage.isRequired},hh.defaultProps={onUpdate:()=>{}};var dh=hh,uh=e=>{var{item:t,language:n,isSelected:s,commandHistoryStorage:r}=e,o=t.name.substring(0,512),l=Object(i.useRef)(),c=Object(i.useCallback)((()=>{var e;null===(e=l.current)||void 0===e||e.update()}),[l]);return a.a.createElement("div",{className:qe()("command-history-item",{selected:s})},o,a.a.createElement(Ol,{ref:l,interactive:!0,options:{placement:"left",modifiers:{preventOverflow:{enabled:!0,boundariesElement:"viewport",order:825}}},popperClassName:"command-history-item-popper"},a.a.createElement(dh,{item:t,language:n,onUpdate:c,commandHistoryStorage:r})))};uh.propTypes={item:rh.CommandHistoryItem.isRequired,language:pi.a.string.isRequired,isSelected:pi.a.bool,commandHistoryStorage:ch.CommandHistoryStorage.isRequired},uh.defaultProps={isSelected:!1};var mh=uh;var ph=a.a.forwardRef(((e,t)=>{var n,i,s,{kind:r,variant:o,type:l,tooltip:c,icon:h,disabled:d,active:u,onClick:m,className:p,style:g,children:v}=e,f=function(e,t){switch(e){case"primary":return"btn-primary";case"secondary":return"btn-outline-primary";case"tertiary":return"btn-secondary";case"success":return"btn-success";case"danger":return"btn-danger";case"inline":return"btn-inline";case"ghost":return qe()("btn-link",{"btn-link-icon":t,"px-2":t})}}(r,h&&!v);o&&(n=function(e){if("group-end"===e)return qe()("pl-2","pr-3")}(o)),h&&(i=a.a.isValidElement(h)?h:a.a.createElement(Ke.a,{icon:h})),c&&(s="string"===typeof c?a.a.createElement(Ol,null,c):c);var b=a.a.createElement("button",{ref:t,type:l,className:qe()("btn",f,n,{active:u},p),onClick:m,style:g,disabled:d},h&&i,v,c&&!d&&s);return d?a.a.createElement("span",{className:"btn-disabled-wrapper"},b,c&&s):b}));ph.displayName="Button",ph.propTypes={kind:pi.a.oneOf(["primary","secondary","tertiary","success","danger","inline","ghost"]).isRequired,variant:pi.a.oneOf(["group-end"]),type:pi.a.oneOf(["submit","reset","button"]),tooltip(e){var{tooltip:t,icon:n,children:i}=e;return t||!n||i?null:new Error("Tooltip is required for icon only buttons")},icon(e){var{children:t,icon:n}=e;return n||t?t||a.a.isValidElement(n)||null!==n&&void 0!==n&&n.iconName?null:new Error("Icon must be react element or fontawesome IconDefinition"):new Error("Icon is required if no children are provided")},disabled:pi.a.bool,active:pi.a.bool,onClick(e){var{onClick:t,type:n}=e;return"button"===n&&"function"!==typeof t?new Error("type button requires an onClick function"):void 0!==t&&"function"!==typeof t?new Error("onClick must be a function"):null},children:pi.a.node,className:pi.a.string,style:pi.a.object},ph.defaultProps={type:"button",onClick:void 0,variant:void 0,tooltip:void 0,icon:void 0,disabled:!1,active:void 0,children:void 0,className:void 0,style:{}};var gh=ph;n(1161);class vh extends i.Component{static itemKey(e,t){return"".concat(t.title)}static renderContent(e){return e.selectionRequired&&e.icon?a.a.createElement("div",{className:"fa-md fa-layers"},a.a.createElement(Ke.a,{icon:at,mask:e.icon,transform:"right-5 down-5 shrink-4"}),a.a.createElement(Ke.a,{icon:Ye,transform:"shrink-3 right-7 down-6"})):!e.selectionRequired&&e.icon?a.a.createElement(Ke.a,{icon:e.icon}):e.title}render(){var{actions:e,hasSelection:t}=this.props;return a.a.createElement("div",{className:"command-history-actions"},e.map(((e,n)=>a.a.createElement(gh,{kind:"inline",className:qe()(e.className),key:vh.itemKey(n,e),onClick:e.action,tooltip:e.description,disabled:e.selectionRequired&&!t,icon:vh.renderContent(e)}))))}}vh.propTypes={actions:pi.a.arrayOf(pi.a.shape({action:pi.a.func.isRequired,title:pi.a.string.isRequired,description:pi.a.string,icon:pi.a.FontAwesomeIcon,selectionRequired:pi.a.bool})).isRequired,hasSelection:pi.a.bool.isRequired};var fh=vh;var bh=class{static get LANGUAGE_MAP(){try{var e;return new Map(null===(e="python=Python,groovy=Groovy,scala=Scala")?void 0:e.split(",").map((e=>e.split("="))).map((e=>{var[t,n]=e;return[t,null!==n&&void 0!==n?n:t]})))}catch(t){return new Map}}},Ch=(n(1119),p.module("CommandHistoryViewportUpdater"));var Sh=function(e){var{table:t,columns:n,top:a=0,bottom:s=0,search:r,isReversed:o=!1,onUpdate:l}=e,c=Object(i.useMemo)((()=>$n()((e=>{var n=e.bottom-e.top,i=Math.max(0,e.top-3*n),a=e.bottom+3*n;t.setViewport({top:i,bottom:a,columns:e.columns})}),150)),[t]);return Object(i.useEffect)((()=>{var e=t.onUpdate((e=>{var t,n;l({items:null!==(t=e.items)&&void 0!==t?t:[],offset:null!==(n=e.offset)&&void 0!==n?n:0})}));return()=>{Ch.debug("onUpdate cleanup"),e()}}),[t,l]),Object(i.useEffect)((()=>{t.setSearch(null!==r&&void 0!==r?r:"")}),[t,r]),Object(i.useEffect)((()=>{c({top:a,bottom:s,columns:n})}),[c,a,s,n,r,o]),Object(i.useEffect)((()=>()=>{Ch.debug2("Cancel throttledUpdateViewport"),c.cancel()}),[c]),null};function Eh(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function wh(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Eh(s,i,a,r,o,"next",e)}function o(e){Eh(s,i,a,r,o,"throw",e)}r(void 0)}))}}function yh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Th=p.module("CommandHistory");class Oh extends i.Component{static getCommandsFromViewport(e,t,n){for(var i=[],a=0;a<n.length;a+=1)for(var s=n[a],r=s[0];r<=s[1];r+=1)if(r>=t&&r<t+e.length){var{name:o}=e[r-t];i.push(o)}return i}static getCommandsFromSnapshot(e,t){return wh((function*(){return[...(yield e.getSnapshot(t)).values()].map((e=>e.name))}))()}constructor(e){super(e),this.copySelectedCommands=this.copySelectedCommands.bind(this),this.createNotebook=this.createNotebook.bind(this),this.sendToConsole=this.sendToConsole.bind(this),this.renderItem=this.renderItem.bind(this),this.runInConsole=this.runInConsole.bind(this),this.sendToNotebook=this.sendToNotebook.bind(this),this.handleSelect=this.handleSelect.bind(this),this.handleSelectionChange=this.handleSelectionChange.bind(this),this.handleSearchChange=this.handleSearchChange.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.handleViewportUpdate=this.handleViewportUpdate.bind(this),this.itemActions=[{title:"Copy Selection",description:"Copy selected commands to clipboard",icon:ft,shortcut:Uc.COPY,action:this.copySelectedCommands,group:vl.groups.edit},{title:"Send to Console",description:"Open selected commands in the console",icon:Xt,shortcut:zc.COMMAND_HISTORY.SEND_TO_CONSOLE,action:this.sendToConsole,group:Oh.menuGroups.send,order:10},{title:"Run in Console",description:"Run selected commands in the console",icon:_t,shortcut:zc.COMMAND_HISTORY.RUN,action:this.runInConsole,group:Oh.menuGroups.send,order:10},{title:"Send to Active Notebook",description:"Open selected commands in a notebook",icon:pt,shortcut:zc.COMMAND_HISTORY.SEND_TO_NOTEBOOK,action:this.sendToNotebook,group:Oh.menuGroups.send,order:20},{title:"Send to New Notebook",description:"Open selected commands in a new notebook",icon:Ft,action:this.createNotebook,group:Oh.menuGroups.send,order:30}],this.historyActions=[{title:"Send to Console",icon:Xt,selectionRequired:!0,description:"Open selected commands in the console",action:this.sendToConsole},{title:"Send to Notebook",icon:pt,selectionRequired:!0,description:"Open selected commands in a notebook",action:this.sendToNotebook}],this.pending=new Ua,this.searchInputRef=a.a.createRef();var{table:t}=e;this.state={actions:[],historyActions:this.historyActions,top:0,bottom:0,itemCount:t.size,items:[],offset:0,selectedRanges:[],searchText:""}}componentWillUnmount(){this.pending.cancel()}getSelectedCommands(){var e=this;return wh((function*(){var{items:t,offset:n,selectedRanges:i}=e.state,a=i.slice().sort(((e,t)=>e[0]-t[0]));if(0===a.length)return[];if(a[0][0]>=n&&a[a.length-1][1]<n+t.length)return Oh.getCommandsFromViewport(t,n,a);var{table:s}=e.props;return e.pending.add(Oh.getCommandsFromSnapshot(s,a))}))()}getSelectedCommandText(){return this.getSelectedCommands().then((e=>e.join("\n")))}updateActions(){this.setState((e=>{var{selectedRanges:t}=e,n=t.reduce(((e,t)=>e+t[1]-t[0]+1),0);return n>0&&n<Oh.MAX_SELECTION_COUNT?(Th.debug("Updating actions",this.itemActions),{actions:this.itemActions}):(Th.debug("Disabling actions",n),{actions:[]})}))}copySelectedCommands(){this.getSelectedCommandText().then(je.copyToClipboard).catch(Th.error)}createNotebook(){this.getSelectedCommandText().then((e=>{var{language:t,sendToNotebook:n}=this.props;n({value:e,language:t},!0)})).catch(Th.error)}sendToNotebook(){this.getSelectedCommandText().then((e=>{var{language:t,sendToNotebook:n}=this.props;n({value:e,language:t})})).catch(Th.error)}sendToConsole(){var{sendToConsole:e}=this.props;this.getSelectedCommandText().then(e).catch(Th.error)}runInConsole(){this.getSelectedCommandText().then((e=>{var{sendToConsole:t}=this.props;t(e,!0,!0)})).catch(Th.error)}handleSelect(e){var{sendToConsole:t}=this.props,{items:n,offset:i}=this.state;if(e<i||e>=i+n.length)Th.error("Invalid index!",e);else{var{name:a}=n[e-i];t(a)}}handleSelectionChange(e){this.setState({selectedRanges:e}),this.updateActions()}handleViewportChange(e,t){this.setState({top:e,bottom:t})}handleSearchChange(e){this.setState({searchText:e.target.value,selectedRanges:[]})}handleViewportUpdate(e){var{items:t,offset:n}=e,{table:i}=this.props,a=i.size;this.setState({items:t,itemCount:a,offset:n})}renderItem(e){var{item:t,itemIndex:n,isSelected:i}=e,{language:s,commandHistoryStorage:r}=this.props;return a.a.createElement(mh,{itemIndex:n,isSelected:i,item:t,language:s,commandHistoryStorage:r})}focus(){this.searchInputRef.current&&this.searchInputRef.current.focus()}render(){var{language:e,table:t}=this.props,{actions:n,historyActions:i,searchText:s,top:r,bottom:o,items:l,itemCount:c,offset:h,selectedRanges:d}=this.state,u=bh.LANGUAGE_MAP.get(e);return a.a.createElement("div",{className:"command-history"},a.a.createElement("div",{className:"command-history-search-bar"},a.a.createElement(Gc,{ref:this.searchInputRef,value:s,placeholder:"".concat(u," Command History"),onChange:this.handleSearchChange}),a.a.createElement(fh,{actions:i,hasSelection:d.length>0})),a.a.createElement("div",{className:"command-history-list"},a.a.createElement(th,{itemCount:c,items:l,offset:h,selectedRanges:d,onSelect:this.handleSelect,onSelectionChange:this.handleSelectionChange,onViewportChange:this.handleViewportChange,renderItem:this.renderItem,rowHeight:Oh.ITEM_HEIGHT,isDoubleClickSelect:!0,isMultiSelect:!0,isStickyBottom:!0}),a.a.createElement(Sh,{table:t,top:r,bottom:o,search:s,onUpdate:this.handleViewportUpdate}),a.a.createElement(vl,{actions:n})))}}yh(Oh,"ITEM_HEIGHT",29),yh(Oh,"MAX_SELECTION_COUNT",1e4),yh(Oh,"menuGroups",{send:vl.groups.medium+100}),Oh.propTypes={language:pi.a.string.isRequired,sendToConsole:pi.a.func.isRequired,sendToNotebook:pi.a.func.isRequired,table:ch.CommandHistoryTable.isRequired,commandHistoryStorage:ch.CommandHistoryStorage.isRequired};var Mh=Oh;n(1118);function Nh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Dh=p.module("CommandHistoryPanel");class xh extends i.Component{static handleError(e){Dh.error(e)}constructor(e){super(e),this.handleFocusHistory=this.handleFocusHistory.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.handleSendToConsole=this.handleSendToConsole.bind(this),this.handleSendToNotebook=this.handleSendToNotebook.bind(this),this.container=a.a.createRef(),this.pending=new Ua;var{session:t,sessionId:n,language:i,panelState:s}=e,r=null;s&&({expandedState:r=r}=s),this.state={panelState:{},session:t,sessionId:n,language:i,contextActions:[{action:this.handleFocusHistory,shortcut:zc.COMMAND_HISTORY.FOCUS_HISTORY}]}}componentDidMount(){var{glEventHub:e,session:t}=this.props;e.on(Il.FOCUS_HISTORY,this.handleFocusHistory),null!=t&&this.loadTable()}componentWillUnmount(){var{glEventHub:e}=this.props;e.off(Il.FOCUS_HISTORY,this.handleFocusHistory),this.pending.cancel()}handleFocusHistory(){this.container.current&&this.container.current.focus()}handleSessionOpened(e,t){var{language:n,sessionId:i}=t;this.setState({session:e,sessionId:i,language:n},(()=>{this.loadTable()}))}handleSessionClosed(){this.pending.cancel(),this.setState({session:null,language:null,table:null})}handleSendToNotebook(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{session:n,language:i}=this.state;if(Dh.debug("handleSendToNotebook",n,e),n){var{glEventHub:a}=this.props;a.emit(t?zl.CREATE_NOTEBOOK:zl.SEND_TO_NOTEBOOK,n,i,e)}else Dh.error("Session is not connected.")}handleSendToConsole(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];Dh.debug("handleSendToConsole",e);var{glEventHub:i}=this.props;i.emit(Il.SEND_COMMAND,e,t,n)}loadTable(){var{commandHistoryStorage:e}=this.props,{language:t,sessionId:n}=this.state;this.pending.add(e.getTable(t,n,Date.now()),(e=>e.close())).then((e=>{this.setState({table:e})})).catch(xh.handleError)}render(){var{glContainer:e,glEventHub:t,commandHistoryStorage:n}=this.props,{language:i,contextActions:s,table:r}=this.state;return a.a.createElement(Jl,{className:"command-history-pane",componentPanel:this,glContainer:e,glEventHub:t,onSessionOpen:this.handleSessionOpened,onSessionClose:this.handleSessionClosed},!r&&a.a.createElement("div",{className:"command-history-disconnected-message"},"Waiting for console connection"),r&&a.a.createElement(a.a.Fragment,null,a.a.createElement(Mh,{ref:this.container,language:i,sendToNotebook:this.handleSendToNotebook,sendToConsole:this.handleSendToConsole,table:r,commandHistoryStorage:n}),a.a.createElement(vl,{actions:s})))}}Nh(xh,"COMPONENT","CommandHistoryPanel"),Nh(xh,"TITLE","Command History"),xh.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({}),session:pi.a.shape({}),sessionId:pi.a.string,language:pi.a.string,commandHistoryStorage:pi.a.shape({getTable:pi.a.func}).isRequired},xh.defaultProps={panelState:null,session:null,sessionId:null,language:null};var Rh=Object(o.b)(((e,t)=>{var n=k(e),i=Tc(e,t.localDashboardId),{session:a,config:s}=null!==i&&void 0!==i?i:{},{type:r,id:o}=null!==s&&void 0!==s?s:{};return{commandHistoryStorage:n,language:r,session:a,sessionId:o}}),null,null,{forwardRef:!0})(xh);function Ih(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Lh=p.module("FigureChartModel");class Fh extends ir{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};super(),Ih(this,"getTimeZone",Lr()(((e,t)=>{if(null!=t){var n=t.getColumnTypeFormatter(e);if(null!=n)return n.dhTimeZone}return null}))),Ih(this,"getValueTranslator",Lr()(((e,t)=>{var n=this.getTimeZone(e,t);return e=>fs.unwrapValue(e,n)}))),Ih(this,"getValueParser",Lr()(((e,t)=>{var n=this.getTimeZone(e,t);return t=>fs.wrapValue(t,e,n)}))),Ih(this,"getRangeParser",Lr()(((e,t)=>n=>{var[i,a]=n,s=this.getValueParser(e,t);return[i=s(i),a=s(a)]}))),Ih(this,"getAxisRangeParser",Lr()(((e,t)=>n=>{var i=fs.getSourceForAxis(e,n);return i?this.getRangeParser(i.columnType,t):e=>e}))),this.handleFigureUpdated=this.handleFigureUpdated.bind(this),this.handleFigureDisconnected=this.handleFigureDisconnected.bind(this),this.handleFigureReconnected=this.handleFigureReconnected.bind(this),this.handleFigureSeriesAdded=this.handleFigureSeriesAdded.bind(this),this.handleDownsampleStart=this.handleDownsampleStart.bind(this),this.handleDownsampleFinish=this.handleDownsampleFinish.bind(this),this.handleDownsampleFail=this.handleDownsampleFail.bind(this),this.handleDownsampleNeeded=this.handleDownsampleNeeded.bind(this),this.handleRequestFailed=this.handleRequestFailed.bind(this),this.addPendingSeries=pa()(this.addPendingSeries.bind(this),Fh.ADD_SERIES_DEBOUNCE),this.figure=e,this.settings=t,this.theme=n,this.data=[],this.layout=fs.makeDefaultLayout(n),this.seriesDataMap=new Map,this.pendingSeries=[],this.oneClicks=[],this.filterColumnMap=new Map,this.lastFilter=new Map,this.isConnected=!0,this.seriesToProcess=new Set,this.setTitle(this.getDefaultTitle()),this.initAllSeries(),this.updateAxisPositions(),this.startListeningFigure()}close(){this.figure.close(),this.addPendingSeries.cancel(),this.stopListeningFigure()}getDefaultTitle(){return this.figure.charts.length>0?this.figure.charts[0].title:""}initAllSeries(){this.oneClicks=[],this.filterColumnMap.clear();for(var{charts:e}=this.figure,t=[],n=0;n<e.length;n+=1)for(var i=e[n],a=0;a<i.series.length;a+=1){var s=i.series[a];t.push(s.name),this.addSeries(s)}for(var r=[...this.seriesDataMap.keys()].filter((e=>t.indexOf(e)<0)),o=0;o<r;o+=1){var l=r[o];this.seriesDataMap.delete(l)}this.seriesToProcess=new Set([...this.seriesDataMap.keys()])}addSeries(e){var t=fs.getChartForSeries(this.figure,e);if(null!=t){var n=fs.groupArray(t.axes,"type"),i=fs.makeSeriesDataFromSeries(e,n,fs.getSeriesVisibility(e.name,this.settings),this.theme);if(this.seriesDataMap.set(e.name,i),this.data=[...this.seriesDataMap.values()],e.plotStyle===va.plot.SeriesPlotStyle.STACKED_BAR?this.layout.barmode="stack":e.plotStyle===va.plot.SeriesPlotStyle.PIE&&(this.layout.hiddenlabels=fs.getHiddenLabels(this.settings)),this.layout.showlegend=this.data.length>1||e.plotStyle===va.plot.SeriesPlotStyle.PIE,e.oneClick){for(var{oneClick:a}=e,{columns:s}=a,r=0;r<s.length;r+=1)this.filterColumnMap.set(s[r].name,s[r]);this.oneClicks.push(a)}this.updateLayoutFormats()}else Lh.error("Unable to find matching chart for series",e)}addPendingSeries(){for(var{pendingSeries:e}=this,t=0;t<e.length;t+=1){var n=e[t];this.addSeries(n),n.subscribe()}this.pendingSeries=[]}subscribe(){super.subscribe(...arguments),1===this.listeners.length&&(this.initAllSeries(),this.subscribeFigure())}unsubscribe(){super.unsubscribe(...arguments),0===this.listeners.length&&this.unsubscribeFigure()}subscribeFigure(){this.isConnected?this.figure.subscribe(this.isDownsamplingDisabled?va.plot.DownsampleOptions.DISABLE:va.plot.DownsampleOptions.DEFAULT):Lh.debug("Ignoring subscribe when figure in disconnected state")}unsubscribeFigure(){this.figure.unsubscribe()}startListeningFigure(){this.figure.addEventListener(va.plot.Figure.EVENT_UPDATED,this.handleFigureUpdated),this.figure.addEventListener(va.plot.Figure.EVENT_SERIES_ADDED,this.handleFigureSeriesAdded),this.figure.addEventListener(va.plot.Figure.EVENT_DISCONNECT,this.handleFigureDisconnected),this.figure.addEventListener(va.plot.Figure.EVENT_RECONNECT,this.handleFigureReconnected),this.figure.addEventListener(va.plot.Figure.EVENT_DOWNSAMPLESTARTED,this.handleDownsampleStart),this.figure.addEventListener(va.plot.Figure.EVENT_DOWNSAMPLEFINISHED,this.handleDownsampleFinish),this.figure.addEventListener(va.plot.Figure.EVENT_DOWNSAMPLEFAILED,this.handleDownsampleFail),this.figure.addEventListener(va.plot.Figure.EVENT_DOWNSAMPLENEEDED,this.handleDownsampleNeeded),this.figure.addEventListener(va.Client.EVENT_REQUEST_FAILED,this.handleRequestFailed)}stopListeningFigure(){this.figure.removeEventListener(va.plot.Figure.EVENT_UPDATED,this.handleFigureUpdated),this.figure.removeEventListener(va.plot.Figure.EVENT_SERIES_ADDED,this.handleFigureSeriesAdded),this.figure.removeEventListener(va.plot.Figure.EVENT_DISCONNECT,this.handleFigureDisconnected),this.figure.removeEventListener(va.plot.Figure.EVENT_RECONNECT,this.handleFigureReconnected),this.figure.removeEventListener(va.plot.Figure.EVENT_DOWNSAMPLESTARTED,this.handleDownsampleStart),this.figure.removeEventListener(va.plot.Figure.EVENT_DOWNSAMPLEFINISHED,this.handleDownsampleFinish),this.figure.removeEventListener(va.plot.Figure.EVENT_DOWNSAMPLEFAILED,this.handleDownsampleFail),this.figure.removeEventListener(va.plot.Figure.EVENT_DOWNSAMPLENEEDED,this.handleDownsampleNeeded),this.figure.removeEventListener(va.Client.EVENT_REQUEST_FAILED,this.handleRequestFailed)}handleDownsampleStart(e){Lh.debug("Downsample started",e),this.fireDownsampleStart(e.detail)}handleDownsampleFinish(e){Lh.debug("Downsample finished",e),this.fireDownsampleFinish(e.detail)}handleDownsampleFail(e){Lh.error("Downsample failed",e),this.fireDownsampleFail(e.detail)}handleDownsampleNeeded(e){Lh.info("Downsample needed",e),this.fireDownsampleNeeded(e.detail)}handleFigureUpdated(e){var{detail:t}=e,{series:n}=t;Lh.debug2("handleFigureUpdated",n);for(var i=0;i<n.length;i+=1){var a=n[i];Lh.debug2("handleFigureUpdated updating series",a.name);for(var{sources:s}=a,r=0;r<s.length;r+=1){var o=s[r],{columnType:l,type:c}=o,h=this.getValueTranslator(l,this.formatter),d=t.getArray(a,c,h);this.setDataArrayForSeries(a,c,d)}this.seriesToProcess.delete(a.name),0===this.seriesToProcess.size&&this.fireLoadFinished(),this.cleanSeries(a)}var{data:u}=this;this.fireUpdate(u)}handleRequestFailed(e){Lh.error("Request failed",e)}resubscribe(){this.listeners.length>0&&(this.unsubscribeFigure(),this.subscribeFigure())}setFormatter(e){super.setFormatter(e),this.updateLayoutFormats(),this.resubscribe()}setDownsamplingDisabled(){super.setDownsamplingDisabled(...arguments),this.resubscribe()}handleFigureDisconnected(e){Lh.debug("Figure disconnected",e),this.isConnected=!1,this.listeners.length>0&&this.unsubscribeFigure(),this.fireDisconnect()}handleFigureReconnected(e){Lh.debug("Figure reconnected",e),this.isConnected=!0,this.initAllSeries(),this.fireReconnect(),this.listeners.length>0&&this.subscribeFigure()}handleFigureSeriesAdded(e){var{detail:t}=e;Lh.debug("handleFigureSeriesAdded",t),this.pendingSeries.push(t),this.addPendingSeries()}setDimensions(e){super.setDimensions(e),this.updateAxisPositions()}setTitle(e){var t,n;super.setTitle(e);var i=null!==(t=null===(n=(null!==e&&void 0!==e?e:"").match(/<br>/g))||void 0===n?void 0:n.length)&&void 0!==t?t:0;this.layout.margin.t=fs.DEFAULT_MARGIN.t+i*fs.SUBTITLE_LINE_HEIGHT,this.layout.title.text=e,this.layout.title.pad.t=fs.DEFAULT_TITLE_PADDING.t+i*fs.SUBTITLE_LINE_HEIGHT*.5}getPlotWidth(){return this.rect&&this.rect.width?Math.max(this.rect.width-this.layout.margin.l-this.layout.margin.r,0):0}getPlotHeight(){return this.rect&&this.rect.height?Math.max(this.rect.height-this.layout.margin.t-this.layout.margin.b,0):0}updateAxisPositions(){for(var e=this.getPlotWidth(),t=this.getPlotHeight(),n=0;n<this.figure.charts.length;n+=1){var i=this.figure.charts[n],a=this.getAxisRangeParser(i,this.formatter);fs.updateLayoutAxes(this.layout,i.axes,e,t,a,this.theme)}}updateLayoutFormats(){this.formatter&&fs.getAxisFormats(this.figure,this.formatter).forEach(((e,t)=>{Lh.debug("Assigning ".concat(t),this.layout[t],e),null!=this.layout[t]?Object.assign(this.layout[t],e):Lh.debug("Ignoring null layout.".concat(t))}))}setDataArrayForSeries(e,t,n){var{name:i,plotStyle:a}=e,s=fs.getPlotlyProperty(a,t);this.seriesDataMap.get(i)[s]=n}cleanSeries(e){var{name:t,plotStyle:n}=e,i=this.seriesDataMap.get(t);if(n===va.plot.SeriesPlotStyle.HISTOGRAM){var{xLow:a,xHigh:s}=i;if(a&&s&&a.length===s.length){for(var r=[],o=0;o<a.length;o+=1)r.push(s[o]-a[o]);i.width=r}}else if(n===va.plot.SeriesPlotStyle.LINE){var{x:l,xLow:c,xHigh:h,y:d,yLow:u,yHigh:m}=i;c&&h&&c!==l&&(i.error_x=fs.getPlotlyErrorBars(l,c,h)),u&&m&&u!==d&&(i.error_y=fs.getPlotlyErrorBars(d,u,m))}}getData(){return this.data}getLayout(){return this.layout}getFilterColumnMap(){return new Map(this.filterColumnMap)}isFilterRequired(){return null!=this.oneClicks.find((e=>e.requireAllFiltersToDisplay))}setFilter(e){var t=this;if(0!==this.oneClicks.length){Lh.debug("setFilter",e);for(var n=function(n){var i=t.oneClicks[n],{columns:a}=i;new Set([...e.keys(),...t.lastFilter.keys()]).forEach((n=>{var s=e.get(n);t.lastFilter.get(n)!==s&&null!=a.find((e=>e.name===n))&&i.setValueForColumn(n,s)}))},i=0;i<this.oneClicks.length;i+=1)n(i);this.lastFilter=new Map(e)}else Lh.warn("Trying to set a filter, but no one click!")}setFigure(e){this.close(),this.figure=e,this.setTitle(this.getDefaultTitle()),this.initAllSeries(),this.updateAxisPositions(),this.startListeningFigure(),this.listeners.length>0&&this.subscribeFigure()}updateSettings(e){this.settings=e}}Ih(Fh,"ADD_SERIES_DEBOUNCE",50);var kh=Fh,Ah=n(157),Ph=n.n(Ah),_h=Object.freeze({paper_bgcolor:Ph.a["paper-bgcolor"],plot_bgcolor:Ph.a["plot-bgcolor"],title_color:Ph.a["title-color"],colorway:Ph.a.colorway,gridcolor:Ph.a.gridcolor,linecolor:Ph.a.linecolor,zerolinecolor:Ph.a.zerolinecolor,activecolor:Ph.a.activecolor,rangebgcolor:Ph.a.rangebgcolor,area_color:Ph.a["area-color"],trend_color:Ph.a["trend-color"],line_color:Ph.a["line-color"],error_band_line_color:Ph.a["error-band-line-color"],error_band_fill_color:Ph.a["error-band-fill-color"],ohlc_increasing:Ph.a["ohlc-increasing"],ohlc_decreasing:Ph.a["ohlc-decreasing"]});function Hh(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function jh(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Hh(s,i,a,r,o,"next",e)}function o(e){Hh(s,i,a,r,o,"throw",e)}r(void 0)}))}}var Vh=class{static makeModelFromSettings(e,t){var n=arguments;return jh((function*(){var i=n.length>2&&void 0!==n[2]?n[2]:_h;return t.copy().then((n=>(n.applyCustomColumns(t.customColumns),n.applyFilter(t.filter),n.applySort(t.sort),va.plot.Figure.create(fs.makeFigureSettings(e,n)).then((t=>new kh(t,e,i))))))}))()}static makeModel(e,t){var n=arguments;return jh((function*(){return new kh(t,e,n.length>2&&void 0!==n[2]?n[2]:_h)}))()}},zh=n(726),Uh=n.n(zh);class Bh{static parseArguments(e){return e&&("string"===typeof e||e instanceof String)?Uh.a.parse(e).filter((e=>!e.comment)).map((e=>{var t,n;return null!==(t=null!==(n=e.pattern)&&void 0!==n?n:e.op)&&void 0!==t?t:"".concat(e)})):[]}static formatTimestamp(e){if(!e||!(e instanceof Date))return null;var t="".concat(e.getHours()).padStart(2,"0"),n="".concat(e.getMinutes()).padStart(2,"0"),i="".concat(e.getSeconds()).padStart(2,"0"),a="".concat(e.getMilliseconds()).padStart(3,"0");return"".concat(t,":").concat(n,":").concat(i,".").concat(a)}static defaultHost(){var e=null;try{e=new URL("/jsapi").hostname}catch(t){e=window.location.hostname}return e}static isTableType(e){return e===va.VariableType.TABLE||e===va.VariableType.TREETABLE}static isWidgetType(e){return e===va.VariableType.FIGURE||e===va.VariableType.OTHERWIDGET||e===va.VariableType.PANDAS}static isOpenableType(e){return Bh.isTableType(e)||Bh.isWidgetType(e)}static isFigureType(e){return e===va.VariableType.FIGURE}static isPandas(e){return e===va.VariableType.PANDAS}}var Wh=Bh,Gh=e=>{var{type:t}=e;switch(t){case va.VariableType.TABLE:case va.VariableType.TABLEMAP:case va.VariableType.TREETABLE:return a.a.createElement(Ke.a,{icon:An});case va.VariableType.FIGURE:return a.a.createElement(Ke.a,{icon:wt});default:return a.a.createElement(Ke.a,{icon:Ht})}},qh=e=>{var{children:t}=e;return a.a.createElement("div",{className:"console-history-item-result"},a.a.createElement("div",{className:"console-history-gutter"},"-"),a.a.createElement("div",{className:"console-history-content"},t))};qh.propTypes={children:pi.a.node.isRequired};var Kh=qh;n(1172);class Yh extends i.Component{constructor(e){super(e),this.updateElapsed=this.updateElapsed.bind(this),this.timer=null,this.startTime=Date.now(),this.state={elapsed:0}}componentDidMount(){this.timer=setInterval(this.updateElapsed,1e3)}componentWillUnmount(){this.timer&&clearInterval(this.timer),this.timer=null}updateElapsed(){this.setState({elapsed:Math.round((Date.now()-this.startTime)/1e3)})}render(){var{elapsed:e}=this.state,{onCancelClick:t}=this.props;return a.a.createElement("div",{className:"console-history-result-in-progress"},a.a.createElement("span",{className:"badge"},a.a.createElement(Yn,null),"\xa0Running... ",Ya.formatElapsedTime(e),"\xa0",a.a.createElement("button",{type:"button",onClick:t},a.a.createElement(Ke.a,{icon:lt}),a.a.createElement(Ol,null,"Cancel"))))}}Yh.propTypes={onCancelClick:pi.a.func.isRequired};var Xh=Yh;class Zh extends i.PureComponent{constructor(e){super(e),this.handleKeyPress=this.handleKeyPress.bind(this),this.handleMouseDown=this.handleMouseDown.bind(this),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseUp=this.handleMouseUp.bind(this),this.handleToggleError=this.handleToggleError.bind(this),this.handleMouseEnter=this.handleMouseEnter.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.mouseX=null,this.mouseY=null,this.isClicking=!1,this.state={isExpanded:!1,isTriggerHovered:!1}}handleKeyPress(e){switch(e.key){case"Enter":case" ":this.handleToggleError(),e.stopPropagation(),e.preventDefault()}}handleMouseDown(e){this.mouseX=e.clientX,this.mouseY=e.clientY,this.isClicking=!0}handleMouseMove(e){null!=this.mouseX&&null!=this.mouseY?(Math.abs(e.clientX-this.mouseX)>=Zh.mouseDragThreshold||Math.abs(e.clientY-this.mouseY)>=Zh.mouseDragThreshold)&&(this.isClicking=!1):this.isClicking&&(this.isClicking=!1)}handleMouseUp(e){!this.isClicking||e.shiftKey||e.metaKey||e.altKey||this.handleToggleError(),this.mouseX=null,this.mouseY=null,this.isClicking=!1}handleToggleError(){this.setState((e=>({isExpanded:!e.isExpanded})))}handleMouseEnter(){this.setState({isTriggerHovered:!0})}handleMouseLeave(){this.setState({isTriggerHovered:!1})}render(){var{isExpanded:e,isTriggerHovered:t}=this.state,{message:n}=this.props,i=n.indexOf("\n"),s=i>-1,r=n;s&&(r=n.slice(0,i));var o=n.slice(i),l=t?"error-btn-link error-btn-link--active":"error-btn-link";return a.a.createElement("div",{key:"error",className:qe()("error-message",{expanded:e})},s&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"error-gutter"},a.a.createElement("button",{type:"button",onClick:this.handleToggleError,className:l,tabIndex:"-1"},a.a.createElement(Ke.a,{icon:e?Qt:Jt,transform:"left-3"}))),a.a.createElement("div",{className:"error-content"},a.a.createElement("div",{className:"console-error-text-trigger",role:"button",tabIndex:"0",onKeyPress:this.handleKeyPress,onMouseDown:this.handleMouseDown,onMouseMove:this.handleMouseMove,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave,onMouseUp:this.handleMouseUp},r),e?o:"")),!s&&a.a.createElement("div",{className:"error-content"},a.a.createElement("div",{className:"console-error-text"},r)))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Zh,"mouseDragThreshold",5),Zh.propTypes={message:pi.a.string},Zh.defaultProps={message:""};var $h=Zh,Qh=(n(1171),p.module("ConsoleHistoryItem"));class Jh extends i.PureComponent{constructor(e){super(e),this.handleCancelClick=this.handleCancelClick.bind(this),this.handleObjectClick=this.handleObjectClick.bind(this)}handleObjectClick(e){Qh.debug("handleObjectClick",e);var{openObject:t}=this.props;t(e)}handleCancelClick(){var{item:e}=this.props;e&&e.cancelResult&&(Qh.debug("Cancelling command: ".concat(e.command)),e.cancelResult())}render(){var{item:e,language:t}=this.props,{disabledObjects:n,result:i}=e,s=null;e.command&&(s=a.a.createElement("div",{className:"console-history-item-command"},a.a.createElement("div",{className:"console-history-gutter"},">"),a.a.createElement("div",{className:"console-history-content"},a.a.createElement(ah,{language:t},e.command))));var r=[];if(i){var{error:o,message:l,changes:c}=i;if(c){var{created:h,updated:d}=c;[...h,...d].filter((e=>{var{type:t}=e;return Wh.isOpenableType(t)})).forEach((e=>{var{name:t}=e,i="".concat(t),s=(null!==n&&void 0!==n?n:[]).indexOf(t)>=0,o=a.a.createElement(Dc,{key:i,onClick:()=>this.handleObjectClick(e),className:"btn-primary btn-console",disabled:s},a.a.createElement(Gh,{type:e.type})," ",t);r.push(o)}))}if(o&&!e.command){var u=o.message;u||(u=o);var m=a.a.createElement($h,{key:"result-error",message:u});r.push(m)}if(l){var p=a.a.createElement("div",{key:"log-message",className:"log-message"},l);r.push(p)}}else{var g=a.a.createElement(Xh,{key:"in_progress",onCancelClick:this.handleCancelClick});r.push(g)}var v=null;return r.length>0&&(v=a.a.createElement(Kh,null,r)),a.a.createElement("div",{className:"container-fluid"},s,v)}}Jh.propTypes={item:pi.a.shape({cancelResult:pi.a.func,command:pi.a.string,disabledObjects:pi.a.arrayOf(pi.a.string),result:pi.a.shape({error:pi.a.oneOfType([pi.a.string,pi.a.shape({message:pi.a.string})]),message:pi.a.string,changes:Ma.VariableChanges}),startTime:pi.a.number,endTime:pi.a.number}).isRequired,language:pi.a.string.isRequired,openObject:pi.a.func.isRequired};var ed=Jh;n(1170);class td extends i.Component{static itemKey(e,t){return"".concat(e,".").concat(t.command,".").concat(t.result&&t.result.message,".").concat(t.result&&t.result.error)}render(){for(var{items:e,language:t,openObject:n}=this.props,i=[],s=0;s<e.length;s+=1){var r=e[s],o=a.a.createElement(ed,{key:td.itemKey(s,r),item:r,openObject:n,language:t});i.push(o)}return a.a.createElement("div",{className:"container-fluid console-history"},i)}}td.propTypes={items:pi.a.arrayOf(pi.a.shape({})).isRequired,language:pi.a.string.isRequired,openObject:pi.a.func.isRequired};var nd=td,id=Object.freeze({FATAL:"FATAL",STDERR:"STDERR",ERROR:"ERROR",WARN:"WARN",STDOUT:"STDOUT",INFO:"INFO",DEBUG:"DEBUG",TRACE:"TRACE"}),ad=p.module("MonacoCompletionProvider");class sd extends i.PureComponent{constructor(e){super(e),this.handleCompletionRequest=this.handleCompletionRequest.bind(this),this.registeredCompletionProvider=null}componentDidMount(){var{language:e}=this.props;this.registeredCompletionProvider=l.d.registerCompletionItemProvider(e,{provideCompletionItems:this.handleCompletionRequest,triggerCharacters:['"',".","'","(","[","{",","]})}componentWillUnmount(){this.registeredCompletionProvider.dispose()}handleCompletionRequest(e,t,n){var{model:i,session:a}=this.props;if(e!==i)return null;var s={textDocument:{uri:"".concat(e.uri)},position:{line:t.lineNumber-1,character:t.column-1},context:n},r=a.getCompletionItems(s);return ad.debug("Completion items received: ",s,r),r=r.then((e=>({incomplete:!0,suggestions:e.map((e=>{var{label:t,kind:n,detail:i,documentation:a,sortText:s,filterText:r,textEdit:o,insertTextFormat:l}=e,{start:c,end:h}=o.range,d={startLineNumber:c.line+1,startColumn:c.character+1,endLineNumber:h.line+1,endColumn:h.character+1};return{label:t,kind:n,detail:i,documentation:a,sortText:s,filterText:r,insertText:o.text,insertTextRules:2===l?4:l,range:d}}))}))).catch((e=>(ad.error("There was an error retrieving completion items",e),{suggestions:[]})))}render(){return null}}sd.propTypes={model:pi.a.shape({uri:pi.a.shape({})}).isRequired,session:pi.a.shape({getCompletionItems:pi.a.func}).isRequired,language:pi.a.string.isRequired};var rd=sd;n(1173);function od(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}var ld=p.module("ConsoleInput"),cd=parseInt(y.a["line-height"],10),hd=cd+6+6;class dd extends i.PureComponent{constructor(e){super(e),this.handleWindowResize=this.handleWindowResize.bind(this),this.cancelListener=null,this.commandContainer=a.a.createRef(),this.commandEditor=null,this.commandHistoryIndex=null,this.commandSuggestionContainer=null,this.isCommandModified=!1,this.loadingPromise=null,this.timestamp=Date.now(),this.bufferIndex=0,this.history=[],this.state={commandEditorHeight:cd,isFocused:!1,model:null}}componentDidMount(){this.initCommandEditor(),window.addEventListener("resize",this.handleWindowResize),this.loadMoreHistory()}componentDidUpdate(){this.layoutEditor()}componentWillUnmount(){window.removeEventListener("resize",this.handleWindowResize),null!=this.loadingPromise&&this.loadingPromise.cancel(),this.destroyCommandEditor()}setConsoleText(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e&&(ld.debug("Command received: ",e),this.commandEditor.setValue(e),this.commandHistoryIndex=null,t&&this.focusEnd(),this.updateDimensions(),n&&this.processCommand())}initCommandEditor(){var{language:e,session:t}=this.props,n={copyWithSyntaxHighlighting:"false",cursorStyle:"block",fixedOverflowWidgets:!0,folding:!1,fontFamily:"Fira Mono",glyphMargin:!1,language:e,lineHeight:cd,lineDecorationsWidth:3,lineNumbers:"off",minimap:{enabled:!1},renderLineHighlight:"none",scrollBeyondLastLine:!1,scrollbar:{arrowSize:0,horizontal:"hidden",horizontalScrollbarSize:0},padding:{top:6,bottom:6},tabCompletion:"on",value:"",wordWrap:"on"};this.commandEditor=l.c.create(this.commandContainer.current,n),I.setEOL(this.commandEditor),I.openDocument(this.commandEditor,t),this.commandEditor.onDidChangeModelContent((()=>{this.isCommandModified=!0,this.updateDimensions()})),this.commandEditor.onDidFocusEditorText((()=>{this.setState({isFocused:!0})})),this.commandEditor.onDidBlurEditorText((()=>{this.setState({isFocused:!1})})),this.commandEditor.onKeyDown((e=>{var{commandEditor:t,commandHistoryIndex:n}=this,{lineNumber:i}=t.getPosition(),a=t.getModel();return e.keyCode===l.a.UpArrow&&1===i?(null!=n?this.loadCommand(n+1):0===a.getValueLength()&&this.loadCommand(0),this.focusStart(),e.stopPropagation(),void e.preventDefault()):e.keyCode===l.a.DownArrow&&i===a.getLineCount()?(null!=n&&n>=0?this.loadCommand(n-1):this.commandHistoryIndex=null,this.focusEnd(),e.stopPropagation(),void e.preventDefault()):void(e.altKey||e.shiftKey||e.metaKey||(e.keyCode===l.a.Enter?this.isSuggestionMenuPopulated()||(e.stopPropagation(),e.preventDefault(),this.processCommand()):e.keyCode===l.a.Tab&&(this.isSuggestionMenuActive()?this.isSuggestionMenuPopulated()||(e.stopPropagation(),e.preventDefault()):(e.stopPropagation(),e.preventDefault(),this.commandEditor.trigger("Tab key trigger suggestions","editor.action.triggerSuggest",{})))))})),this.commandEditor.addCommand(l.b.CtrlCmd|l.a.KEY_F,(()=>{})),I.removeConflictingKeybindings(this.commandEditor),I.registerPasteHandler(this.commandEditor),this.commandEditor.focus(),this.updateDimensions(),this.setState({model:this.commandEditor.getModel()})}destroyCommandEditor(){var{session:e}=this.props;this.commandEditor&&(I.closeDocument(this.commandEditor,e),this.commandEditor.dispose(),this.commandEditor=null)}handleWindowResize(){this.updateDimensions()}isSuggestionMenuActive(){return this.commandSuggestionContainer||(this.commandSuggestionContainer=this.commandEditor.getDomNode().querySelector(".suggest-widget")),this.commandSuggestionContainer&&this.commandSuggestionContainer.classList.contains("visible")}isSuggestionMenuPopulated(){return this.isSuggestionMenuActive()&&this.commandSuggestionContainer.querySelector(".monaco-list-rows").childElementCount>0}focus(){this.commandEditor.focus()}focusStart(){var e=this.commandEditor.getModel().getLineLength(1)+1,t=this.commandEditor.getTopForPosition(1,e);this.commandEditor.setPosition({lineNumber:1,column:e}),this.commandEditor.setScrollTop(t),this.commandEditor.focus()}focusEnd(){var e=this.commandEditor.getModel(),t=e.getLineCount(),n=e.getLineLength(t)+1,i=this.commandEditor.getTopForPosition(t,n);this.commandEditor.setPosition({lineNumber:t,column:n}),this.commandEditor.setScrollTop(i),this.commandEditor.focus()}clear(){this.commandEditor.focus(),this.commandEditor.getModel().setValue(""),this.commandHistoryIndex=null}layoutEditor(){this.commandEditor&&this.commandEditor.layout()}loadCommand(e){e<0?(this.commandHistoryIndex=null,this.commandEditor.getModel().setValue("")):e<this.history.length&&(this.commandHistoryIndex=e,this.commandEditor.getModel().setValue(this.history[this.history.length-e-1]),e>this.history.length-100&&this.loadMoreHistory()),this.isCommandModified=!1}loadMoreHistory(){var e,t=this;return(e=function*(){try{if(null!=t.loadingPromise||null==t.bufferIndex)return;var{commandHistoryStorage:e,language:n,scope:i}=t.props;t.loadingPromise=Va.makeCancelable(e.getTable(n,i,t.timestamp),(e=>e.close()));var a=yield t.loadingPromise;a.setReversed(!0),a.setViewport({top:t.bufferIndex,bottom:t.bufferIndex+100-1}),t.loadingPromise=Va.makeCancelable(a.getViewportData(),(()=>a.close()));var s=yield t.loadingPromise;t.bufferIndex+=100,t.bufferIndex>=a.size&&(t.bufferIndex=null),t.history=[...s.items.map((e=>{var{name:t}=e;return t})).reverse(),...t.history],t.loadingPromise=null,a.close()}catch(r){if(t.loadingPromise=null,Va.isCanceled(r))return void ld.debug2("Promise canceled, not loading history");ld.error("Error fetching history",r)}},function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){od(s,i,a,r,o,"next",e)}function o(e){od(s,i,a,r,o,"throw",e)}r(void 0)}))})()}processCommand(){this.isCommandModified=!1,this.commandHistoryIndex=null;var e=this.commandEditor.getValue().trim();this.history.push(e),this.commandEditor.setValue(""),this.updateDimensions();var{onSubmit:t}=this.props;t(e)}updateDimensions(){if(this.commandEditor){var{maxHeight:e}=this.props,t=this.commandEditor.getContentHeight(),n=Math.max(Math.min(t,e),hd),i=t>n,a=this.commandEditor.getOptions();a.overviewRulerLanes=i?void 0:0,this.setState({commandEditorHeight:n},(()=>{this.commandEditor.updateOptions(a),this.commandEditor.layout()}))}}render(){var{language:e,session:t}=this.props,{commandEditorHeight:n,isFocused:i,model:s}=this.state;return a.a.createElement("div",{className:"console-input-wrapper"},a.a.createElement("div",{className:qe()("console-input-inner-wrapper",{focus:i})},a.a.createElement("div",{className:dd.INPUT_CLASS_NAME,ref:this.commandContainer,style:{height:n}}),s&&a.a.createElement(rd,{model:s,language:e,session:t})))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(dd,"INPUT_CLASS_NAME","console-input"),dd.propTypes={session:pi.a.shape({}).isRequired,language:pi.a.string.isRequired,scope:pi.a.string,commandHistoryStorage:ch.CommandHistoryStorage.isRequired,onSubmit:pi.a.func.isRequired,maxHeight:pi.a.number},dd.defaultProps={maxHeight:10*cd,scope:null};var ud=dd;n(1166);function md(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var pd="pasted values",gd=[/^audio.*/,/^font.*/,/^image.*/,/^video.*/];class vd extends i.Component{static isValidDropItem(e){return e&&"file"===e.kind&&!gd.find((t=>t.test(e.type)))}static isValidExtension(e){return e.endsWith(".csv")||e.endsWith(".zip")||e.endsWith(".tsv")||e.endsWith(".tab")||e.endsWith(".psv")||e.endsWith(".dsv")||e.endsWith(".txt")}static handleDragOver(e){e.preventDefault(),e.stopPropagation()}static getIcon(e){return e===pd?ot:e.endsWith(".csv")?cn:e.endsWith(".zip")?gt:mn}constructor(e){super(e),this.handleSelectFile=this.handleSelectFile.bind(this),this.handleFiles=this.handleFiles.bind(this),this.handleDrop=this.handleDrop.bind(this),this.unstageFile=this.unstageFile.bind(this),this.handleMenuPaste=this.handleMenuPaste.bind(this),this.handlePasteEvent=this.handlePasteEvent.bind(this),this.fileElem=a.a.createRef(),this.divElem=a.a.createRef(),this.state={selectedFileName:"",dropError:null}}componentDidMount(){this.divElem.current.addEventListener("paste",this.handlePasteEvent),this.divElem.current.focus()}componentWillUnmount(){this.divElem.current.removeEventListener("paste",this.handlePasteEvent)}handleSelectFile(){this.fileElem.current.value=null,this.fileElem.current.click()}handleFiles(e){e.stopPropagation(),e.preventDefault(),this.handleFile(e.target.files[0])}handleDrop(e){var{clearDragError:t,dragError:n}=this.props;if(e.preventDefault(),e.stopPropagation(),n)t();else if(e.dataTransfer&&e.dataTransfer.items){var i=e.dataTransfer.items[0].getAsFile();vd.isValidExtension(i.name)?this.handleFile(i):this.setState({dropError:vd.FILE_TYPE_ERROR})}}unstageFile(e){var{onFileOpened:t}=this.props;e.stopPropagation(),e.preventDefault(),t(null),this.setState({selectedFileName:"",dropError:null})}handleFile(e){var{onFileOpened:t}=this.props;t(e),this.setState({selectedFileName:e.name,dropError:null})}handleMenuPaste(){var{onPaste:e,onError:t,uploadInProgress:n}=this.props;n||navigator.clipboard.readText().then((t=>{e(t),this.setState({selectedFileName:pd,dropError:null})})).catch((e=>t(e)))}handlePasteEvent(e){e.stopPropagation(),e.preventDefault(),this.handleMenuPaste()}makeContextMenuItems(){var{uploadInProgress:e}=this.props;return[{title:"Paste",icon:ot,action:this.handleMenuPaste,shortcut:Uc.PASTE,disabled:e}]}render(){var{dragError:e,uploadInProgress:t}=this.props,{selectedFileName:n,dropError:i}=this.state,s=e||i,r=this.makeContextMenuItems();return a.a.createElement("div",{ref:this.divElem,className:"csv-overlay fill-parent-absolute",onDragOver:vd.handleDragOver,onDrop:this.handleDrop,tabIndex:"-1"},a.a.createElement(vl,{actions:r}),a.a.createElement("input",{ref:this.fileElem,type:"file",id:"fileElem",accept:".csv, .tsv, .tab, .zip, .psv, .dsv, .txt",style:{display:"none"},onChange:this.handleFiles}),!n&&!s&&a.a.createElement("div",{className:"message-content"},a.a.createElement("div",{className:"message-icon"},a.a.createElement(Ke.a,{icon:hn})),a.a.createElement("label",null,"Drop file (or paste values) here to import"),a.a.createElement("div",{className:"message-small"},a.a.createElement("label",null,"or")),a.a.createElement("button",{type:"button",className:"btn btn-primary",onClick:this.handleSelectFile},"Select File...")),n&&!s&&a.a.createElement("div",{className:"selected-content"},a.a.createElement("div",{className:"selected-icon"},a.a.createElement(Ke.a,{icon:vd.getIcon(n)})),a.a.createElement("div",{className:"selected-text"},a.a.createElement("label",null,"Selected File"),a.a.createElement("label",{className:"selected-name"},n,!t&&a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon ml-2",onClick:this.unstageFile},a.a.createElement(Ke.a,{icon:$t}))))),s&&a.a.createElement("div",{className:"message-content"},a.a.createElement("div",{className:"message-icon"},a.a.createElement(Ke.a,{icon:en})),a.a.createElement("label",null,s),s===vd.FILE_TYPE_ERROR&&a.a.createElement("div",{className:"message-small"},a.a.createElement("label",null,"Please select a .csv, .tsv, .tab, .psv, .dsv, .txt or .zip"))))}}md(vd,"MULTIPLE_FILE_ERROR","Please select only one file"),md(vd,"FILE_TYPE_ERROR","Filetype not supported."),vd.propTypes={onFileOpened:pi.a.func.isRequired,onPaste:pi.a.func.isRequired,clearDragError:pi.a.func.isRequired,dragError:pi.a.string,onError:pi.a.func.isRequired,uploadInProgress:pi.a.bool.isRequired},vd.defaultProps={dragError:null};var fd=vd,bd=n(404),Cd=n.n(bd),Sd=a.a.forwardRef(((e,t)=>{var{checked:n=!1,children:s,className:r,disabled:o,inputClassName:l,isInvalid:c,labelClassName:h,onChange:d}=e,[u]=Object(i.useState)(ni()()),m=vi(t);Object(i.useEffect)((()=>{m.current&&(m.current.indeterminate=null===n)}),[m,n]);var p=Object(i.useCallback)((e=>{m.current&&(m.current.indeterminate=null===n),d&&d(e)}),[m,n,d]);return a.a.createElement("div",{className:qe()("custom-control custom-checkbox",r)},a.a.createElement("input",{type:"checkbox",ref:m,checked:null!==n&&void 0!==n&&n,className:qe()("custom-control-input",l,{"is-invalid":c}),disabled:o,id:u,onChange:p}),a.a.createElement("label",{className:qe()("custom-control-label",h),htmlFor:u},s))}));Sd.displayName="Checkbox",Sd.propTypes={checked:(e,t)=>{var{[t]:n}=e;return null!==n&&"boolean"!==typeof n?new Error("Checked must be a boolean or null for indeterminate"):null},children:pi.a.node.isRequired,className:pi.a.string,disabled:pi.a.bool,inputClassName:pi.a.string,isInvalid:pi.a.bool,labelClassName:pi.a.string,onChange:pi.a.func},Sd.defaultProps={checked:!1,className:"",disabled:!1,inputClassName:"",isInvalid:!1,labelClassName:"",onChange:void 0};var Ed=Sd,wd=n(347),yd=n.n(wd);function Td(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Od{}Td(Od,"INTEGER","int"),Td(Od,"LONG","long"),Td(Od,"DOUBLE","double"),Td(Od,"BOOLEAN","bool"),Td(Od,"STRING","string"),Td(Od,"DATE_TIME","datetime"),Td(Od,"LOCAL_TIME","localtime");var Md=Od;function Nd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Dd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Nd(Object(n),!0).forEach((function(t){xd(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Nd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function xd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Rd="unknown",Id=/^[0-9]{4}-[0-1][0-9]-[0-3][0-9][ T][0-2][0-9]:[0-5][0-9]:[0-6][0-9](?:\.[0-9]{1,9})?(?: [a-zA-Z]+)?$/,Ld=/^([0-9]+T)?([0-9]+):([0-9]+)(:[0-9]+)?(?:\.[0-9]{1,9})?$/;class Fd{static determineType(e,t,n){if(!e||e===n)return t;switch(t){case Md.STRING:return Md.STRING;case Md.INTEGER:return Fd.checkInteger(e);case Md.LONG:return Fd.checkLong(e);case Md.DOUBLE:return Fd.checkDouble(e);case Md.BOOLEAN:return Fd.checkBoolean(e);case Md.DATE_TIME:return Fd.checkDateTime(e);case Md.LOCAL_TIME:return Fd.checkLocalTime(e);default:return Fd.getTypeFromUnknown(e)}}static isNotParsableNumber(e){return isNaN(e)||"Infinity"===e||"-Infinity"===e}static checkInteger(e){var t=e.replace(/,/g,"");return Fd.isNotParsableNumber(t)?Md.STRING:Fd.getNumberType(t)}static checkLong(e){var t=e.replace(/,/g,"");return Fd.isNotParsableNumber(t)?Md.STRING:t.includes(".")?Md.DOUBLE:Md.LONG}static checkDouble(e){var t=e.replace(/,/g,"");return Fd.isNotParsableNumber(t)?Md.STRING:Md.DOUBLE}static checkBoolean(e){var t=e.toLowerCase();return"true"===t||"false"===t?Md.BOOLEAN:Md.STRING}static checkDateTime(e){return Id.test(e)?Md.DATE_TIME:Md.STRING}static checkLocalTime(e){return Ld.test(e)?Md.LOCAL_TIME:Md.STRING}static getTypeFromUnknown(e){var t=e.replace(/,/g,"");if(Fd.isNotParsableNumber(t)){var n=e.toLowerCase();return"true"===n||"false"===n?Md.BOOLEAN:Id.test(e)&&e.includes(":")?Md.DATE_TIME:Ld.test(e)?Md.LOCAL_TIME:Md.STRING}return Fd.getNumberType(t)}static getNumberType(e){if(e.includes("."))return Md.DOUBLE;var t=e.startsWith("-")?11:10;if(e.length>t)return Md.LONG;var n=parseInt(e,10);return n>2147483647||n<-2147483648?Md.LONG:Md.INTEGER}constructor(e,t,n,i,a,s,r,o,l,c){this.onFileCompleted=e,this.file=t,this.readHeaders=n,this.nullString=a,this.onProgress=s,this.onError=r,this.types=null,this.chunks=0,this.totalChunks=o,this.isZip=l,this.shouldTrim=c,this.zipProgress=0,this.handleChunk=this.handleChunk.bind(this),this.handleComplete=this.handleComplete.bind(this),this.handleError=this.handleError.bind(this),this.handleNodeUpdate=this.handleNodeUpdate.bind(this),this.config=Dd(Dd({},i),{},{error:this.handleError,chunk:this.handleChunk,complete:this.handleComplete})}parse(){var e=this.isZip?this.file.nodeStream("nodebuffer",this.handleNodeUpdate):this.file;yd.a.parse(e,this.config)}handleChunk(e,t){var{data:n}=e;if(!this.types){if(!n||0===n.length)return t.abort(),void this.onError("Error parsing CSV: no data in file.");this.types=new Array(n[0].length).fill(Rd),this.readHeaders&&(n=n.slice(1))}n.forEach((e=>{if(e.length>=this.types.length)for(var n=0;n<this.types.length;n+=1)this.types[n]=Fd.determineType(this.shouldTrim?e[n].trim():e[n],this.types[n],this.nullString);else t.abort(),this.onError("Error parsing CSV: Insufficient data in row.\nExpected length ".concat(this.types.length," but found ").concat(e.length,".\nRow = ").concat(e))})),this.chunks+=1;var i=0;i=this.totalChunks>0?Math.round(this.chunks/this.totalChunks*50):Math.round(this.zipProgress/2),this.onProgress(i)&&t.abort()}handleComplete(e){var{types:t,onFileCompleted:n}=this;e&&e.meta.aborted||n(t.map((e=>e===Rd?Md.STRING:e)))}handleError(e){var{onError:t}=this;t(e)}handleNodeUpdate(e){this.zipProgress=e.percent}}var kd=Fd;var Ad=p.module("CsvParser");class Pd{static generateHeaderRecursive(e){var t="",n=e;return e>=26&&(t=t.concat(Pd.generateHeaderRecursive(Math.floor(e/26)-1)),n=e%26),t.concat(String.fromCharCode(65+n))}constructor(e){var{onFileCompleted:t,session:n,file:i,type:a,readHeaders:s=!0,onProgress:r,onError:o,timeZone:l,isZip:c}=e;this.onFileCompleted=t,this.session=n,this.file=i,this.isZip=c,this.type=a,this.readHeaders=s,this.timeZone=l,this.onProgress=r,this.onError=o,this.tables=[],this.headers=null,this.types=null,this.chunks=0,this.totalChunks=c?0:Math.ceil(i.size/yd.a.LocalChunkSize),this.isComplete=!1,this.zipProgress=0,this.consolidatedChunks=null,this.numConsolidated=0,this.isCancelled=!1,this.handleChunk=this.handleChunk.bind(this),this.handleError=this.handleError.bind(this),this.handleComplete=this.handleComplete.bind(this),this.handleNodeUpdate=this.handleNodeUpdate.bind(this),this.handleCreateTable=this.handleCreateTable.bind(this),this.config={delimiter:a.delimiter,newline:a.newline,escapeChar:a.escapeChar,dynamicTyping:!1,error:this.handleError,skipEmptyLines:a.skipEmptyLines,chunk:this.handleChunk,complete:this.handleComplete,fastMode:!1}}cancel(){this.isCancelled=!0}transpose(e,t){for(var n=t.length,i=new Array(e).fill(null).map((()=>new Array(n))),a=0;a<n;a+=1){var s=t[a];if(s.length<e)throw new Error("Insufficient columns. Expected ".concat(e," but found ").concat(s.length,"\n").concat(s));for(var r=0;r<e;r+=1){var o=this.type.shouldTrim?t[a][r].trim():t[a][r];i[r][a]=this.nullCheck(o)}}return i}nullCheck(e){return e===this.type.nullString?"":e}parse(){new kd((e=>{var t=this.isZip?this.file.nodeStream("nodebuffer",this.handleNodeUpdate):this.file;this.types=e,yd.a.parse(t,this.config)}),this.file,this.readHeaders,this.config,this.type.nullString,this.onProgress,this.onError,this.totalChunks,this.isZip,this.type.shouldTrim).parse()}handleChunk(e,t){var{readHeaders:n,onError:i,handleCreateTable:a,isZip:s,tables:r}=this;if(this.isCancelled)return Ad.debug2("CSV parser cancelled."),t.abort(),void r.forEach((e=>e.close()));var{data:o}=e;this.headers||(n?(this.headers=Pa.legalizeColumnNames(o[0]),o=o.slice(1)):this.headers=Pd.generateHeaders(o[0].length));var l=[];try{if(l=this.transpose(this.headers.length,o),s)this.consolidateChunks(l,t);else{var c=this.chunks;this.chunks+=1,a(c,l,t)}}catch(h){i(h)}}consolidateChunks(e,t){if(this.consolidatedChunks)for(var n=0;n<e.length;n+=1)this.consolidatedChunks[n]=this.consolidatedChunks[n].concat(e[n]);else this.consolidatedChunks=e.slice();this.numConsolidated+=1,(this.numConsolidated>=650||this.isComplete)&&this.uploadConsolidatedChunks(t)}uploadConsolidatedChunks(e){var{handleCreateTable:t}=this,n=this.chunks;this.chunks+=1;var i=this.consolidatedChunks.slice();this.consolidatedChunks=null,this.numConsolidated=0,t(n,i,e)}handleCreateTable(e,t,n){var{session:i,tables:a,onFileCompleted:s,totalChunks:r,types:o,onProgress:l,onError:c}=this;n&&n.pause(),i.newTable(this.headers,o,t,this.timeZone).then((t=>{if(this.isCancelled)return Ad.debug2("CSV parser cancelled."),n&&n.abort(),void a.forEach((e=>e.close()));n&&n.resume(),a[e]=t;var i=0;i=r>0?Math.round(a.length/r*50)+50:Math.round(50+this.zipProgress/2),Ad.debug2("CSV parser progress ".concat(i)),l(i),this.isComplete&&a.length===this.chunks&&(Ad.debug2("CSV parser complete."),s(a))})).catch((e=>{!this.isComplete&&n&&n.abort(),c(e)}))}handleComplete(e){e&&e.meta.aborted||(this.isComplete=!0,this.consolidatedChunks&&this.uploadConsolidatedChunks(null))}handleError(e){var{onError:t}=this;t(e)}handleNodeUpdate(e){this.zipProgress=e.percent}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Pd,"generateHeaders",(e=>{for(var t=[],n=0;n<e;n+=1)t.push(Pd.generateHeaderRecursive(n));return t}));var _d=Pd;function Hd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class jd{static fromExtension(e){return e.endsWith(".csv")?"DEFAULT_CSV":e.endsWith(".tsv")||e.endsWith(".tab")?"TSV":e.endsWith(".psv")?"PIPE_SV":"AUTODETECT"}}Hd(jd,"DEFAULT_TYPE","DEFAULT_CSV"),Hd(jd,"AUTO","AUTODETECT"),Hd(jd,"TYPES",Object.freeze({DEFAULT_CSV:{name:"Default csv (trimmed)",delimiter:",",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},TSV:{name:"Tab seperated (tsv)",delimiter:"\t",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},APACHE_COMMON_CSV:{name:"Apache Common csv",delimiter:",",newline:"\r\n",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:null},EXCEL_CSV:{name:"Excel csv (strict)",delimiter:",",newline:"\r\n",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!1,nullString:null},MY_SQL_CSV:{name:"MySQL csv",delimiter:"\t",newline:"\n",escapeChar:"\\",shouldTrim:!0,skipEmptyLines:!1,nullString:"\\N"},RFC4180_CSV:{name:"RFC4180 csv",delimiter:",",newline:"\r\n",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!1,nullString:null},COLON_SV:{name:": colon sv",delimiter:":",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},SEMI_COLON_SV:{name:"; semi-colon sv",delimiter:";",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},PIPE_SV:{name:"| pipe separated (psv)",delimiter:"|",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},SPACE_SV:{name:'" " space sv',delimiter:" ",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"},AUTODETECT:{name:"autodetect",delimiter:"",newline:"",escapeChar:'"',shouldTrim:!0,skipEmptyLines:!0,nullString:"(null)"}}));var Vd=jd,zd=(n(1259),p.module("CsvInputBar")),Ud=Object.entries(Vd.TYPES).map((e=>{var[t,n]=e;return a.a.createElement("option",{key:t,value:t},n.name)}));class Bd extends i.Component{constructor(e){super(e),this.handleUpload=this.handleUpload.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleError=this.handleError.bind(this),this.handleTableName=this.handleTableName.bind(this),this.toggleFirstRowHeaders=this.toggleFirstRowHeaders.bind(this),this.handleProgress=this.handleProgress.bind(this),this.handleCancelInProgress=this.handleCancelInProgress.bind(this),this.handleQueryTypeChange=this.handleQueryTypeChange.bind(this),this.inputRef=a.a.createRef(),this.state={tableName:"",tableNameSet:!1,isFirstRowHeaders:!0,showProgress:!1,progressValue:0,type:Vd.DEFAULT_TYPE,parser:null}}componentDidUpdate(e){var{file:t,paste:n}=this.props,{tableName:i,tableNameSet:a}=this.state;if(a||!t||i)(!t&&e.file||!n&&e.paste)&&this.setState({tableName:"",tableNameSet:!1});else{var s=t.name.lastIndexOf("."),r=Pa.legalizeTableName(t.name.substring(0,s));this.setState({tableName:r,tableNameSet:!0}),this.inputRef.current.focus()}n&&!i&&this.inputRef.current&&this.inputRef.current.focus(),t&&t!==e.file?this.setState({type:Vd.fromExtension(t.name)}):n&&!e.paste&&this.setState({type:Vd.AUTO})}componentWillUnmount(){var{parser:e}=this.state;e&&e.cancel()}handleCancel(){var{onClose:e}=this.props;e()}handleError(e){var{onClose:t,onError:n}=this.props;zd.error(e),n(e),t()}handleTableName(e){this.setState({tableName:e.target.value,tableNameSet:!0})}toggleFirstRowHeaders(){var{isFirstRowHeaders:e}=this.state;this.setState({isFirstRowHeaders:!e})}handleUpload(e){e.stopPropagation(),e.preventDefault();var{file:t,paste:n,onUpdate:i}=this.props;t?t.name.endsWith(".zip")?Cd.a.loadAsync(t).then((e=>{for(var{files:n}=e,a=!1,s=Object.values(n),r=0;r<s.length;r+=1){var o=s[r];if(fd.isValidExtension(o.name)){i("Loading ".concat(o.name," as csv from ").concat(t.name)),a=!0,this.handleFile(o,!0);break}}if(!a)throw new Error("No csv file found in ".concat(t.name))})).catch((e=>this.handleError(e))):this.handleFile(t):n&&this.handleFile(new Blob([n],{type:"text/plain"}))}handleFile(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];zd.info("Starting CSV parser for ".concat(e.name," ").concat(t?"":"".concat(e.size," bytes")));var{session:n,timeZone:i,onInProgress:a}=this.props,{tableName:s,isFirstRowHeaders:r,type:o}=this.state,l=new _d({onFileCompleted:e=>{1===e.length?n.bindTableToVariable(e[0],s).then((()=>this.openTable())).catch((e=>this.handleError(e))):n.mergeTables(e).then((t=>{n.bindTableToVariable(t,s).then((()=>this.openTable())).catch((e=>this.handleError(e))),e.forEach((e=>e.close()))})).catch((e=>this.handleError(e)))},session:n,file:e,type:Vd.TYPES[o],readHeaders:r,onProgress:this.handleProgress,onError:this.handleError,timeZone:i,isZip:t});l.parse(),this.setState({showProgress:!0,parser:l}),a(!0)}handleProgress(e){var{showProgress:t}=this.state;return t&&this.setState({progressValue:e}),!t}handleCancelInProgress(){var{onInProgress:e}=this.props,{parser:t}=this.state;t&&t.cancel(),this.setState({showProgress:!1,progressValue:0}),e(!1)}openTable(){var{onOpenTable:e,onClose:t}=this.props,{tableName:n}=this.state;e(n),t()}handleQueryTypeChange(e){this.setState({type:e.target.value})}render(){var{file:e,paste:t}=this.props,{tableName:n,isFirstRowHeaders:i,showProgress:s,progressValue:r,type:o}=this.state,l=t&&!n;return a.a.createElement("div",null,!s&&a.a.createElement("form",{onSubmit:this.handleUpload,className:"csv-input-bar-container form-inline"},a.a.createElement("div",{className:"form-group"},a.a.createElement("label",{htmlFor:"tableNameInput"},"Table name"),a.a.createElement("input",{ref:this.inputRef,id:"tableNameInput",type:"text",className:qe()("form-control",{"is-invalid":l}),value:n,onChange:this.handleTableName})),a.a.createElement("div",{className:"form-group"},a.a.createElement("label",{htmlFor:"formatSelect"},"File format"),a.a.createElement("select",{id:"formatSelect",className:"custom-select",value:o,onChange:this.handleQueryTypeChange},Ud)),a.a.createElement(Ed,{className:"firstRowHeaders",checked:i,onChange:this.toggleFirstRowHeaders},"First row is column headers"),a.a.createElement("div",{className:"csv-input-buttons form-group"},a.a.createElement(gh,{kind:"secondary",onClick:this.handleCancel},"Cancel"),a.a.createElement(gh,{kind:"primary",type:"submit",disabled:!(e||t)||!n},"Upload"))),s&&a.a.createElement("div",{className:"csv-progress-container"},a.a.createElement("label",null,"Uploading Table"),a.a.createElement("div",{className:"progress"},a.a.createElement("div",{className:"progress-bar bg-primary",style:{width:"".concat(r,"%")},"aria-valuenow":r,"aria-valuemin":"0","aria-valuemax":"100"})),a.a.createElement("label",null,r,"%"),a.a.createElement("button",{type:"button",className:"btn btn-primary",onClick:this.handleCancelInProgress},"Cancel")))}}Bd.propTypes={session:pi.a.shape({bindTableToVariable:pi.a.func.isRequired,mergeTables:pi.a.func.isRequired}).isRequired,onOpenTable:pi.a.func.isRequired,onClose:pi.a.func.isRequired,onUpdate:pi.a.func.isRequired,onError:pi.a.func.isRequired,file:pi.a.instanceOf(File),paste:pi.a.string,onInProgress:pi.a.func.isRequired,timeZone:pi.a.string.isRequired},Bd.defaultProps={file:null,paste:null};var Wd=Bd,Gd=(n(1165),a.a.forwardRef(((e,t)=>{var n;function i(t){var{menuItem:n,onMenuItemMouseMove:i}=e;i(n,t)}var{children:s,menuItem:r,isKeyboardSelected:o,isMouseSelected:l}=e,c=null===(n=r.shortcut)||void 0===n?void 0:n.getDisplayText(),h=null;if(r.icon){var d,u=r.icon;if(a.a.isValidElement(u))h=u;else r.iconColor&&!r.disabled&&(d={color:r.iconColor}),h=a.a.createElement(Ke.a,{icon:u,style:d})}var m=null,p=!!s;r.actions&&(m=a.a.createElement(Ke.a,{icon:nt}));var g=null;if(r.menuElement)g=a.a.createElement("div",{className:"custom-menu-item",onMouseMove:i},function(t,n,i){if("string"===typeof t.type)return t;var{closeMenu:s,menuItem:r,isKeyboardSelected:o,isMouseSelected:l}=e,c={menuItem:r,closeMenu:s,isKeyboardSelected:o,isMouseSelected:l,iconElement:n,displayShortcut:i};return a.a.cloneElement(t,{forwardedProps:c})}(r.menuElement,h,c));else{var v=r.disabled,f=r.iconOutline;g=a.a.createElement("button",{type:"button",className:qe()("btn-context-menu",{disabled:v},{active:(p||l)&&!v},{"keyboard-active":o&&!v}),onClick:function(t){var{menuItem:n,onMenuItemClick:i}=e;i(n,t)},onMouseMove:i,onContextMenu:function(t){var{menuItem:n,onMenuItemContextMenu:i}=e;i(n,t)},title:r.description||""},a.a.createElement("div",{className:"btn-context-menu-wrapper"},a.a.createElement("span",{className:qe()("icon",{outline:f})},h),a.a.createElement("span",{className:"title"},r.title),c&&a.a.createElement("span",{className:"shortcut"},c),m&&a.a.createElement("span",{className:qe()("submenu-indicator",{disabled:v})},m)))}return a.a.createElement("div",{className:"context-menu-item",ref:t},s,g)})));Gd.displayName="ContextMenuItem",Gd.defaultProps={children:null,isKeyboardSelected:!1,isMouseSelected:!1};var qd=Gd;function Kd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Yd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Kd(Object(n),!0).forEach((function(t){Xd(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Xd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Zd extends i.PureComponent{constructor(e){var t;super(e),Xd(this,"container",void 0),Xd(this,"oldFocus",void 0),Xd(this,"rAF",void 0),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMenuItemClick=this.handleMenuItemClick.bind(this),this.handleMenuItemMouseMove=this.handleMenuItemMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleCloseMenu=this.handleCloseMenu.bind(this),this.container=a.a.createRef(),this.oldFocus=document.activeElement,this.rAF=0;var{options:n}=e,i=null!==(t=n.initialKeyboardIndex)&&void 0!==t?t:-1;this.state={menuItems:[],keyboardIndex:i,mouseIndex:-1}}componentDidMount(){this.initMenu(),this.rAF=window.requestAnimationFrame((()=>{var e;null===(e=this.container.current)||void 0===e||e.focus();var{onMenuOpened:t}=this.props;t(this)}))}componentDidUpdate(e){var{actions:t}=this.props;e.actions!==t&&this.initMenu()}componentWillUnmount(){cancelAnimationFrame(this.rAF)}getKeyboardIndex(){var{options:e}=this.props;if(e.separateKeyboardMouse){var{keyboardIndex:t}=this.state;return t}return this.getMouseIndex()}setKeyboardIndex(e){var{options:t}=this.props;t.separateKeyboardMouse?this.setState({keyboardIndex:e}):this.setMouseIndex(e)}getMouseIndex(){var{mouseIndex:e}=this.state;return e}setMouseIndex(e){this.setState({mouseIndex:e})}initMenu(){cancelAnimationFrame(this.rAF),this.setState({menuItems:[]});var{actions:e}=this.props,t=je.getMenuItems(e,!1);t.length>0&&this.setState((e=>({menuItems:je.sortActions(e.menuItems.concat(t))})))}handleKeyDown(e){var{menuItems:t}=this.state,n=this.getKeyboardIndex(),i=n;if("Enter"!==e.key&&" "!==e.key){if("Escape"===e.key)i=null;else if("ArrowUp"===e.key||"Tab"===e.key&&!0===e.shiftKey){var a;i=je.getNextMenuItem(null!==(a=i)&&void 0!==a?a:0,-1,t)}else if("ArrowDown"===e.key||"Tab"===e.key&&!1===e.shiftKey){var s;i=je.getNextMenuItem(null!==(s=i)&&void 0!==s?s:0,1,t)}n!==i&&(null!==i?this.setKeyboardIndex(i):(this.closeMenu(),this.oldFocus instanceof HTMLElement&&this.oldFocus.focus()),e.preventDefault(),e.stopPropagation())}else null!=n&&n>=0&&n<t.length&&this.handleMenuItemClick(t[n],e)}closeMenu(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],{closeMenu:t,onMenuClosed:n}=this.props;cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame((()=>{t(e),n(this)}))}handleCloseMenu(){this.closeMenu()}handleMenuItemClick(e,t){t.preventDefault(),t.stopPropagation(),null==e||e.disabled||null==e.action||(e.action(),this.closeMenu(!0))}handleMenuItemMouseMove(e){var{menuItems:t}=this.state,n=t.indexOf(e);this.setMouseIndex(n)}handleMouseLeave(){this.setMouseIndex(-1)}render(){for(var e=[],{keyboardIndex:t,menuItems:n,mouseIndex:i}=this.state,s=0;s<n.length;s+=1){var r=n[s];s>0&&r.group!==n[s-1].group&&e.push(a.a.createElement("hr",{key:"".concat(s,".separator")}));var o=a.a.createElement(qd,{key:s,isKeyboardSelected:t===s,isMouseSelected:i===s,menuItem:r,closeMenu:this.handleCloseMenu,onMenuItemClick:this.handleMenuItemClick,onMenuItemMouseMove:this.handleMenuItemMouseMove,onMenuItemContextMenu:()=>!1});e.push(o)}var{menuStyle:l}=this.props;return a.a.createElement("div",{className:"context-menu-container",style:Yd({},l),ref:this.container,onKeyDown:this.handleKeyDown,onMouseLeave:this.handleMouseLeave,role:"menuitem",tabIndex:0},e)}}Xd(Zd,"defaultProps",{closeMenu(){},onMenuOpened(){},onMenuClosed(){},options:{},menuStyle:{}});var $d=Zd;n(1169);function Qd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Jd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qd(Object(n),!0).forEach((function(t){eu(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function eu(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class tu extends i.PureComponent{constructor(e){super(e),eu(this,"container",void 0),eu(this,"parent",void 0),eu(this,"popper",void 0),eu(this,"isOpen",void 0),this.handleClick=this.handleClick.bind(this),this.handleCloseMenu=this.handleCloseMenu.bind(this),this.handleExited=this.handleExited.bind(this),this.container=a.a.createRef(),this.parent=null,this.popper=a.a.createRef(),this.isOpen=!1}componentDidMount(){var e,{isShown:t}=this.props;null===t?null!==(e=this.container.current)&&void 0!==e&&e.parentElement&&(this.parent=this.container.current.parentElement,this.parent.addEventListener("click",this.handleClick)):t&&this.openMenu()}componentDidUpdate(e){var{isShown:t}=this.props;e.isShown!==t&&(t?window.requestAnimationFrame((()=>{this.openMenu()})):this.closeMenu())}componentWillUnmount(){this.parent&&this.parent.removeEventListener("click",this.handleClick)}closeMenu(){var e;null===(e=this.popper.current)||void 0===e||e.hide()}openMenu(){this.popper.current&&!this.isOpen&&(this.popper.current.show(),this.isOpen=!0)}scheduleUpdate(){var e;null===(e=this.popper.current)||void 0===e||e.scheduleUpdate()}handleClick(e){e.preventDefault(),e.stopPropagation(),this.openMenu()}handleCloseMenu(){this.closeMenu()}handleExited(){this.isOpen=!1;var{onMenuClosed:e}=this.props;e()}render(){var{actions:e,onMenuOpened:t,popperClassName:n}=this.props,{menuStyle:i}=this.props,{options:s,popperOptions:r}=this.props;return r=Jd({placement:"bottom"},r),s=Jd({separateKeyboardMouse:!0},s),a.a.createElement("div",{className:"menu-actions-listener",ref:this.container},a.a.createElement(El,{ref:this.popper,options:r,className:qe()("menu-popper",n),onExited:this.handleExited,closeOnBlur:!0,interactive:!0},a.a.createElement($d,{actions:e,closeMenu:this.handleCloseMenu,onMenuOpened:t,options:s,menuStyle:i})))}}eu(tu,"defaultProps",{isShown:null,onMenuClosed(){},onMenuOpened(){},options:{},popperOptions:{},popperClassName:"",menuStyle:{}});var nu=tu;n(1168);function iu(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var au=p.module("ConsoleMenu");class su extends i.PureComponent{static makeItemActions(e,t,n,i,s){if(0===e.length)return[];var r={menuElement:a.a.createElement(Gc,{value:t,onChange:i,className:"console-menu",ref:n})},o=e;return t&&(o=o.filter((e=>{var{name:n}=e;return n.toLowerCase().indexOf(t.toLowerCase())>=0}))),[r,...o.map((e=>({title:e.name,action:()=>{s(e)}})))]}constructor(e){super(e),iu(this,"makeTableActions",Object(ua.a)(((e,t,n)=>{var i=e.filter((e=>Wh.isTableType(e.type)));return su.makeItemActions(i,t,(e=>{this.tableSearchField=e}),this.handleTableFilterChange,n)}))),iu(this,"makeWidgetActions",Object(ua.a)(((e,t,n)=>{var i=e.filter((e=>Wh.isWidgetType(e.type)));return su.makeItemActions(i,t,(e=>{this.widgetSearchField=e}),this.handleWidgetFilterChange,n)}))),this.handleTableFilterChange=this.handleTableFilterChange.bind(this),this.handleTableMenuClosed=this.handleTableMenuClosed.bind(this),this.handleTableMenuOpened=this.handleTableMenuOpened.bind(this),this.handleWidgetFilterChange=this.handleWidgetFilterChange.bind(this),this.handleWidgetMenuClosed=this.handleWidgetMenuClosed.bind(this),this.handleWidgetMenuOpened=this.handleWidgetMenuOpened.bind(this),this.tableSearchField=null,this.widgetSearchField=null,this.state={tableFilterText:"",widgetFilterText:""}}handleTableFilterChange(e){au.debug("filtering tables..."),this.setState({tableFilterText:e.target.value})}handleTableMenuClosed(){this.setState({tableFilterText:""})}handleTableMenuOpened(){this.tableSearchField&&this.tableSearchField.focus&&this.tableSearchField.focus()}handleWidgetFilterChange(e){au.debug("filtering widgets..."),this.setState({widgetFilterText:e.target.value})}handleWidgetMenuClosed(){this.setState({widgetFilterText:""})}handleWidgetMenuOpened(){this.widgetSearchField&&this.widgetSearchField.focus&&this.widgetSearchField.focus()}render(){var{overflowActions:e,objects:t,openObject:n}=this.props,{tableFilterText:i,widgetFilterText:s}=this.state,r=this.makeTableActions(t,i,n),o=this.makeWidgetActions(t,s,n),l={placement:"bottom-end"};return a.a.createElement("div",{className:"console-pane-menu"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",disabled:0===r.length},a.a.createElement("div",{className:"fa-md fa-layers"},a.a.createElement(Ke.a,{mask:An,icon:Qt,transform:"right-5 down-5"}),a.a.createElement(Ke.a,{icon:Qt,transform:"right-8 down-6"})),a.a.createElement(Ol,null,"Tables"),a.a.createElement(nu,{key:"table-actions ",actions:r,onMenuOpened:this.handleTableMenuOpened,onMenuClosed:this.handleTableMenuClosed,options:{initialKeyboardIndex:1},popperOptions:l})),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",disabled:0===o.length},a.a.createElement("div",{className:"fa-md fa-layers"},a.a.createElement(Ke.a,{mask:wt,icon:Qt,transform:"right-5 down-5"}),a.a.createElement(Ke.a,{icon:Qt,transform:"right-8 down-6"})),a.a.createElement(Ol,null,"Widgets"),a.a.createElement(nu,{key:"table-actions",actions:o,onMenuOpened:this.handleWidgetMenuOpened,onMenuClosed:this.handleWidgetMenuClosed,options:{initialKeyboardIndex:1},popperOptions:l})),a.a.createElement("button",{type:"button",className:"btn btn-link btn-overflow btn-link-icon"},a.a.createElement(Ke.a,{icon:Ot}),a.a.createElement(Ol,null,"More Actions..."),a.a.createElement(nu,{actions:e,popperOptions:l})))}}su.propTypes={openObject:pi.a.func.isRequired,objects:pi.a.arrayOf(Ma.VariableDefinition).isRequired,overflowActions:pi.a.oneOfType([pi.a.func,pi.a.arrayOf(pi.a.shape({}))]).isRequired};var ru=su;n(1167);class ou extends i.PureComponent{constructor(e){super(e),this.handleCommandStarted=this.handleCommandStarted.bind(this),this.handleCommandCompleted=this.handleCommandCompleted.bind(this),this.pending=new Ua,this.state={isDisconnected:!1,isCommandRunning:!1}}componentDidMount(){this.startListening()}componentWillUnmount(){this.stopListening(),this.cancelPendingPromises()}startListening(){var{session:e}=this.props;e.addEventListener(va.IdeSession.EVENT_COMMANDSTARTED,this.handleCommandStarted)}stopListening(){var{session:e}=this.props;e.removeEventListener(va.IdeSession.EVENT_COMMANDSTARTED,this.handleCommandStarted)}cancelPendingPromises(){this.pending.cancel()}handleCommandStarted(e){var{result:t}=e.detail;this.pending.add(t).then((()=>this.handleCommandCompleted(null,t))).catch((e=>this.handleCommandCompleted(e,t))),this.setState({isCommandRunning:!0})}handleCommandCompleted(e){e instanceof Da||this.setState({isCommandRunning:this.pending.pending.length>0})}render(){var{children:e,openObject:t,overflowActions:n,objects:i}=this.props,{isDisconnected:s,isCommandRunning:r}=this.state,o=null,l=null;return s?(o="console-status-icon-disconnected",l="Worker is disconnected"):r?(o="console-status-icon-pending",l="Worker is busy"):(o="console-status-icon-idle",l="Worker is idle"),a.a.createElement("div",{className:"console-pane-status-bar"},a.a.createElement("div",null,a.a.createElement("div",{className:qe()("console-status-icon",o)}),a.a.createElement(Ol,null,l)),e,a.a.createElement(ru,{overflowActions:n,openObject:t,objects:i}))}}ou.propTypes={children:pi.a.node,session:Ma.IdeSession.isRequired,openObject:pi.a.func.isRequired,objects:pi.a.arrayOf(Ma.VariableDefinition).isRequired,overflowActions:pi.a.oneOfType([pi.a.func,pi.a.arrayOf(pi.a.shape({}))]).isRequired},ou.defaultProps={children:null};var lu=ou;function cu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function hu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cu(Object(n),!0).forEach((function(t){du(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function du(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uu=p.module("Console"),mu={isAutoLaunchPanelsEnabled:!0,isPrintStdOutEnabled:!0,isClosePanelsOnDisconnectEnabled:!0};class pu extends i.PureComponent{static isErrorLevel(e){return e===id.STDERR||e===id.ERROR||e===id.FATAL}static isOutputLevel(e){return e===id.STDOUT||pu.isErrorLevel(e)}constructor(e){super(e),du(this,"getObjects",Object(ua.a)((e=>[...e.values()]))),du(this,"getContextActions",Object(ua.a)((e=>[...e,{action:this.handleClearShortcut,shortcut:zc.CONSOLE.CLEAR},{action:this.handleFocusHistory,shortcut:zc.CONSOLE.FOCUS_HISTORY}]))),this.handleCommandResult=this.handleCommandResult.bind(this),this.handleCommandStarted=this.handleCommandStarted.bind(this),this.handleCommandSubmit=this.handleCommandSubmit.bind(this),this.handleClearShortcut=this.handleClearShortcut.bind(this),this.handleFocusHistory=this.handleFocusHistory.bind(this),this.handleLogMessage=this.handleLogMessage.bind(this),this.handleOverflowActions=this.handleOverflowActions.bind(this),this.handleScrollPaneScroll=this.handleScrollPaneScroll.bind(this),this.handleToggleAutoLaunchPanels=this.handleToggleAutoLaunchPanels.bind(this),this.handleToggleClosePanelsOnDisconnect=this.handleToggleClosePanelsOnDisconnect.bind(this),this.handleTogglePrintStdout=this.handleTogglePrintStdout.bind(this),this.processLogMessageQueue=$n()(this.processLogMessageQueue.bind(this),pu.LOG_THROTTLE),this.handleUploadCsv=this.handleUploadCsv.bind(this),this.handleHideCsv=this.handleHideCsv.bind(this),this.handleCsvFileOpened=this.handleCsvFileOpened.bind(this),this.handleCsvPaste=this.handleCsvPaste.bind(this),this.handleDragEnter=this.handleDragEnter.bind(this),this.handleDragLeave=this.handleDragLeave.bind(this),this.handleClearDragError=this.handleClearDragError.bind(this),this.handleOpenCsvTable=this.handleOpenCsvTable.bind(this),this.handleCsvUpdate=this.handleCsvUpdate.bind(this),this.handleCsvError=this.handleCsvError.bind(this),this.handleCsvInProgress=this.handleCsvInProgress.bind(this),this.cancelListener=null,this.consolePane=a.a.createRef(),this.consoleInput=a.a.createRef(),this.consoleHistoryScrollPane=a.a.createRef(),this.pending=new Ua,this.queuedLogMessages=[];var{settings:t}=this.props;this.state=hu(hu({consoleHistory:[],consoleHeight:0,isScrollDecorationShown:!1,objectHistoryMap:new Map,objectMap:new Map,showCsvOverlay:!1,csvFile:null,csvPaste:null,dragError:null,csvUploadInProgress:!1},mu),t)}componentDidMount(){this.initConsoleLogging();var{session:e}=this.props;e.addEventListener(va.IdeSession.EVENT_COMMANDSTARTED,this.handleCommandStarted),this.updateDimensions()}componentDidUpdate(e,t){var{props:n,state:i}=this;this.sendSettingsChange(t,i),null!=n.disconnectedChildren&&null==e.disconnectedChildren&&this.disconnect()}componentWillUnmount(){var{session:e}=this.props;e.removeEventListener(va.IdeSession.EVENT_COMMANDSTARTED,this.handleCommandStarted),this.pending.cancel(),this.processLogMessageQueue.cancel(),this.deinitConsoleLogging()}initConsoleLogging(){var{session:e}=this.props;this.cancelListener=e.onLogMessage(this.handleLogMessage)}deinitConsoleLogging(){null!=this.cancelListener&&(this.cancelListener(),this.cancelListener=null)}disconnect(){this.setState((e=>{var{consoleHistory:t}=e;return{consoleHistory:t.map((e=>{if(null==e.result)return hu(hu({},e),{},{endTime:Date.now(),result:{}});var{result:t}=e;if(t.changes){var n=[].concat(t.changes.created).concat(t.changes.updated);return hu(hu({},e),{},{disabledItems:n})}return e})),objectHistoryMap:new Map,objectMap:new Map}}))}handleClearShortcut(e){e.preventDefault(),e.stopPropagation(),this.consoleInput.current.clear()}handleCommandStarted(e){var{code:t,result:n}=e.detail,i=this.pending.add(n),a={command:t,result:null,disabledObjects:[],startTime:Date.now(),endTime:null,cancelResult:()=>{n.cancel()},wrappedResult:i},{commandHistoryStorage:s,language:r,scope:o}=this.props,l=s.addItem(r,o,t,{command:t,startTime:(new Date).toJSON(),endTime:null,result:null});l.catch((e=>{uu.debug("Error adding workspace item",e)})),this.setState((e=>({consoleHistory:e.consoleHistory.concat(a)})),(()=>{this.scrollConsoleHistoryToBottom(!0)})),i.then((e=>{this.handleCommandResult(e,a,l)})).catch((e=>{this.handleCommandError(e,a,l)}))}handleCommandResult(e,t,n){var i=t;i.wrappedResult=null,i.cancelResult=null,e&&(i.result=e,this.updateHistory(e,i),this.updateKnownObjects(i),this.updateWorkspaceHistoryItem({error:e.error},n),this.closeRemovedItems(e.changes),this.openUpdatedItems(e.changes))}handleCommandError(e,t,n){var i=t;i.wrappedResult=null,i.cancelResult=null,e&&e.isCanceled?uu.debug("Called handleCommandError on a cancelled promise result"):(this.updateWorkspaceHistoryItem({error:"".concat(e)},n),this.setState((t=>{var n=t.consoleHistory.concat(),a=n.lastIndexOf(i);return i.endTime=Date.now(),i.result={error:e},n[a]=hu({},i),{consoleHistory:n}})))}handleFocusHistory(e){e.preventDefault(),e.stopPropagation();var{focusCommandHistory:t}=this.props;t()}handleLogMessage(e){var{isPrintStdOutEnabled:t}=this.state;t&&pu.isOutputLevel(e.logLevel)&&this.queueLogMessage(e.message,e.logLevel)}queueLogMessage(e,t){var n={};pu.isErrorLevel(t)?n.error=e:n.message=e;var i={command:null,result:n};this.queuedLogMessages.push(i),this.processLogMessageQueue()}processLogMessageQueue(){this.scrollConsoleHistoryToBottom(),this.setState((e=>{uu.debug2("processLogMessageQueue",this.queuedLogMessages.length," items");var{consoleHistory:t}=e;return t=t.concat(this.queuedLogMessages),this.queuedLogMessages=[],{consoleHistory:t}}))}openUpdatedItems(e){var{isAutoLaunchPanelsEnabled:t}=this.state;if(e&&t){var{openObject:n}=this.props;[...e.created,...e.updated].filter((e=>Wh.isOpenableType(e.type))).forEach((e=>n(e)))}}closeRemovedItems(e){if(e&&e.removed&&0!==e.removed.length){var{closeObject:t}=this.props,{removed:n}=e;n.filter((e=>Wh.isOpenableType(e.type))).forEach((e=>t(e)))}}updateHistory(e,t){var n=t;e&&e.changes&&n&&(n.endTime=Date.now(),this.scrollConsoleHistoryToBottom(),this.setState((e=>({consoleHistory:e.consoleHistory.concat()}))))}updateKnownObjects(e){var{changes:t}=e.result;t&&(t.created&&0!==t.created.length||t.updated&&0!==t.updated.length||t.removed&&0!==t.removed.length)?this.setState((n=>{var i=n.consoleHistory.concat(),a=i.lastIndexOf(e);if(a<0)return uu.error("historyItem not found in state.consoleHistory"),null;var s=new Map(n.objectHistoryMap),r=new Map(n.objectMap),o=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{name:n}=e,o=s.get(n);o>=0&&(i[o].disabledObjects=i[o].disabledObjects.concat(n),i[o]=hu({},i[o])),s.set(n,a),t?r.delete(n):r.set(n,e)};return t.updated.forEach((e=>o(e))),t.removed.forEach((e=>o(e,!0))),t.created.forEach((e=>{var{name:t}=e;s.set(t,a),r.set(t,e)})),{objectHistoryMap:s,objectMap:r,consoleHistory:i}})):uu.debug2("updateKnownObjects no changes")}updateWorkspaceHistoryItem(e,t){var n=this.pending.add(t),i=(new Date).toJSON();n.then((t=>{var n=hu(hu({},t),{},{data:hu(hu({},t.data),{},{endTime:i,result:e})}),{commandHistoryStorage:a,language:s}=this.props;a.updateItem(s,n).catch((e=>{uu.warn("Error updating command history storage",e)}))})).catch((e=>{uu.debug("Error updating workspace history item",e)}))}scrollConsoleHistoryToBottom(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.consoleHistoryScrollPane.current;!e&&t.scrollTop<t.scrollHeight-t.offsetHeight||window.requestAnimationFrame((()=>{t.scrollTop=t.scrollHeight}))}handleScrollPaneScroll(){var e=this.consoleHistoryScrollPane.current;e.scrollTop>0&&e.scrollHeight>e.clientHeight?this.setState({isScrollDecorationShown:!0}):this.setState({isScrollDecorationShown:!1})}handleToggleAutoLaunchPanels(){this.setState((e=>({isAutoLaunchPanelsEnabled:!e.isAutoLaunchPanelsEnabled})))}handleToggleClosePanelsOnDisconnect(){this.setState((e=>({isClosePanelsOnDisconnectEnabled:!e.isClosePanelsOnDisconnectEnabled})))}handleTogglePrintStdout(){this.setState((e=>({isPrintStdOutEnabled:!e.isPrintStdOutEnabled})))}handleUploadCsv(){this.setState({showCsvOverlay:!0,dragError:null,csvUploadInProgress:!1})}handleHideCsv(){this.setState({showCsvOverlay:!1,csvFile:null,csvPaste:null,dragError:null,csvUploadInProgress:!1})}handleCsvFileOpened(e){this.setState({csvFile:e,csvPaste:null})}handleCsvPaste(e){this.setState({csvFile:null,csvPaste:e})}handleDragEnter(e){if(e.dataTransfer&&e.dataTransfer.items&&0!==e.dataTransfer.items.length&&"string"!==e.dataTransfer.items[0].kind){e.preventDefault(),e.stopPropagation(),this.setState({showCsvOverlay:!0});var{items:t}=e.dataTransfer;if(t.length>1)this.setState({dragError:fd.MULTIPLE_FILE_ERROR});else{var n=t[0];fd.isValidDropItem(n)?this.setState({dragError:null}):this.setState({dragError:fd.FILE_TYPE_ERROR})}}}handleDragLeave(e){e.currentTarget&&!e.currentTarget.contains(e.relatedTarget)&&(e.preventDefault(),e.stopPropagation(),this.setState({showCsvOverlay:!1,dragError:null}))}handleClearDragError(){this.setState({dragError:null})}handleOpenCsvTable(e){var{openObject:t,commandHistoryStorage:n,language:i,scope:a}=this.props,{consoleHistory:s,objectMap:r}=this.state,o={name:e,type:va.VariableType.TABLE},l=r.has(e),c={startTime:Date.now(),endTime:Date.now(),disabledObjects:[],result:{changes:{created:[],updated:[],removed:[],[l?"updated":"created"]:[o]}}},h=s.concat(c);this.setState({consoleHistory:h}),this.scrollConsoleHistoryToBottom(!0),this.updateKnownObjects(c),t({name:e,type:va.VariableType.TABLE}),n.addItem(i,a,e,{command:e,startTime:(new Date).toJSON(),endTime:(new Date).toJSON(),result:null})}addConsoleHistoryMessage(e,t){var{consoleHistory:n}=this.state,i={command:"",startTime:Date.now(),endTime:Date.now(),result:{message:e,error:t}},a=n.concat(i);this.setState({consoleHistory:a})}handleCsvUpdate(e){this.addConsoleHistoryMessage(e)}handleCsvError(e){this.addConsoleHistoryMessage(null,e)}handleCsvInProgress(e){this.setState({csvUploadInProgress:e})}handleOverflowActions(){var{isAutoLaunchPanelsEnabled:e,isClosePanelsOnDisconnectEnabled:t,isPrintStdOutEnabled:n}=this.state,{actions:i}=this.props;return[...i,{title:"Print Stdout",action:this.handleTogglePrintStdout,group:vl.groups.high,icon:n?Je:null,order:10},{title:"Auto Launch Panels",action:this.handleToggleAutoLaunchPanels,group:vl.groups.high,icon:e?Je:null,order:20},{title:"Close Panels on Disconnect",action:this.handleToggleClosePanelsOnDisconnect,group:vl.groups.high,icon:t?Je:null,order:30},{title:"Upload Table from File",action:this.handleUploadCsv,group:vl.groups.high+10,order:40}]}handleCommandSubmit(e){if("clear"===e||"cls"===e)this.clearConsoleHistory();else if(e.length>0){var{session:t}=this.props;t.runCode(e).catch((e=>{uu.error("There was an error initiating the command",e)}))}else{var n={command:" ",result:{},startTime:Date.now(),endTime:Date.now()};this.scrollConsoleHistoryToBottom(!0),this.setState((e=>({consoleHistory:e.consoleHistory.concat(n)})))}}clearConsoleHistory(){this.pending.cancel(),this.setState((e=>({consoleHistory:[],objectHistoryMap:new Map([...e.objectHistoryMap.keys()].map((e=>[e,-1])))})))}addCommand(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.consoleInput.current&&(this.consoleInput.current.setConsoleText(e,t,n),t&&this.scrollConsoleHistoryToBottom(!0))}focus(){var e;null===(e=this.consoleInput.current)||void 0===e||e.focus()}sendSettingsChange(e,t){for(var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=Object.keys(mu),a={},s=!1,r=0;r<i.length;r+=1){var o=i[r],{[o]:l}=t,{[o]:c}=e;l!==c&&(s=!0),a[o]=l}if(!n||s){var{onSettingsChange:h}=this.props;h(a)}}updateDimensions(){this.consolePane.current&&this.setState({consoleHeight:this.consolePane.current.clientHeight}),this.consoleInput.current&&this.consoleInput.current.updateDimensions()}render(){var{actions:e,disconnectedChildren:t,language:n,statusBarChildren:i,openObject:s,session:r,scope:o,commandHistoryStorage:l,timeZone:c}=this.props,{consoleHeight:h,consoleHistory:d,isScrollDecorationShown:u,objectMap:m,showCsvOverlay:p,csvFile:g,csvPaste:v,dragError:f,csvUploadInProgress:b}=this.state,C=this.getObjects(m),S=Math.round(.7*h),E=null!=t,w=this.getContextActions(e);return a.a.createElement("div",{role:"presentation",className:qe()("iris-console h-100 w-100",{disconnected:E})},a.a.createElement("div",{className:"console-pane",ref:this.consolePane},a.a.createElement(lu,{session:r,overflowActions:this.handleOverflowActions,openObject:s,objects:C},i),a.a.createElement("div",{className:"console-csv-container",onDragOver:fd.handleDragOver,onDragEnter:this.handleDragEnter,onDragLeave:this.handleDragLeave},!E&&p&&a.a.createElement(fd,{onFileOpened:this.handleCsvFileOpened,onPaste:this.handleCsvPaste,clearDragError:this.handleClearDragError,dragError:f,onError:this.handleCsvError,uploadInProgress:b}),a.a.createElement("div",{role:"presentation",className:qe()("scroll-pane no-scroll-x",{"scroll-decoration":u}),onScroll:this.handleScrollPaneScroll,ref:this.consoleHistoryScrollPane},a.a.createElement(nd,{items:d,openObject:s,language:n}),E&&t)),!E&&!p&&a.a.createElement(ud,{ref:this.consoleInput,session:r,language:n,scope:o,onSubmit:this.handleCommandSubmit,maxHeight:S,commandHistoryStorage:l}),!E&&p&&a.a.createElement(Wd,{session:r,onOpenTable:this.handleOpenCsvTable,onClose:this.handleHideCsv,onUpdate:this.handleCsvUpdate,onError:this.handleCsvError,file:g,paste:v,onInProgress:this.handleCsvInProgress,timeZone:c})),a.a.createElement(vl,{actions:w,ignoreClassNames:[ud.INPUT_CLASS_NAME]}))}}du(pu,"LOG_THROTTLE",500),pu.propTypes={statusBarChildren:pi.a.node,settings:pi.a.shape({}),focusCommandHistory:pi.a.func.isRequired,openObject:pi.a.func.isRequired,closeObject:pi.a.func.isRequired,session:Ma.IdeSession.isRequired,language:pi.a.string.isRequired,commandHistoryStorage:ch.CommandHistoryStorage.isRequired,onSettingsChange:pi.a.func,scope:pi.a.string,actions:pi.a.arrayOf(pi.a.shape({})),timeZone:pi.a.string,disconnectedChildren:pi.a.node},pu.defaultProps={statusBarChildren:null,settings:{},onSettingsChange:()=>{},scope:null,actions:[],disconnectedChildren:null,timeZone:"America/New_York"};var gu=pu;function vu(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function fu(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){vu(s,i,a,r,o,"next",e)}function o(e){vu(s,i,a,r,o,"throw",e)}r(void 0)}))}}class bu extends _o{constructor(){super(),this.listenerCount=0}addEventListener(){super.addEventListener(...arguments),this.listenerCount+=1,1===this.listenerCount&&this.startListening()}removeEventListener(){super.removeEventListener(...arguments),this.listenerCount-=1,0===this.listenerCount&&this.stopListening()}startListening(){}stopListening(){}get columns(){throw new Error("get columns not implemented")}getColumnIndexByName(e){throw new Error("getColumnIndexByName not implemented")}get originalColumns(){return this.columns}get groupedColumns(){throw new Error("get groupedColumns not implemented")}get description(){throw new Error("get description not implemented")}formatForCell(e,t){throw new Error("formatForCell not implemented")}valueForCell(e,t){throw new Error("valueForCell not implemented")}get filter(){throw new Error("get filter not implemented")}set filter(e){throw new Error("set filter not implemented")}get formatter(){throw new Error("get formatter not implemented")}set formatter(e){throw new Error("set formatter not implemented")}displayString(e,t){throw new Error("displayString not implemented")}get sort(){throw new Error("get sort not implemented")}set sort(e){throw new Error("set sort not implemented")}get customColumns(){throw new Error("get customColumns not implemented")}set customColumns(e){throw new Error("set customColumns not implemented")}updateFrozenColumns(e){throw new Error("updateFrozenColumns not implemented")}get rollupConfig(){throw new Error("get rollupConfig not implemented")}set rollupConfig(e){throw new Error("set rollupConfig not implemented")}get totalsConfig(){throw new Error("get totalsConfig not implemented")}set totalsConfig(e){throw new Error("set totalsConfig not implemented")}get layoutHints(){return null}isColumnFrozen(e){return!1}get isFilterRequired(){return!1}get isReversible(){return!0}get isColumnStatisticsAvailable(){return!1}get isCustomColumnsAvailable(){return!1}get isExportAvailable(){return!1}get isValuesTableAvailable(){return!1}get isChartBuilderAvailable(){return!1}get isRollupAvailable(){return!1}get isTotalsAvailable(){return!1}get pendingDataMap(){throw new Error("get pendingDataMap not implemented")}set pendingDataMap(e){throw new Error("set pendingDataMap not implemented")}get pendingRowCount(){throw new Error("get pendingRowCount not implemented")}set pendingRowCount(e){throw new Error("set pendingRowCount not implemented")}get pendingDataErrors(){throw new Error("get pendingDataErrors not implemented")}commitPending(){return fu((function*(){throw new Error("commitPending not implemented")}))()}isFilterable(e){return!1}setViewport(e,t,n){throw new Error("setViewport not implemented")}snapshot(e){return fu((function*(){throw new Error("snapshot not implemented")}))()}textSnapshot(e,t,n){return fu((function*(){throw new Error("textSnapshot not implemented")}))()}export(){return fu((function*(){throw new Error("export not implemented")}))()}valuesTable(e){return fu((function*(){throw new Error("getValuesTable not implemented")}))()}columnStatistics(e){return fu((function*(){throw new Error("columnStatistics not implemented")}))()}close(){}isRowMovable(){return!1}delete(e){throw new Error("delete not implemented")}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(bu,"EVENT",Object.freeze({UPDATED:"UPDATED",FORMATTER_UPDATED:"FORMATTER_UPDATED",REQUEST_FAILED:"REQUEST_FAILED",COLUMNS_CHANGED:"COLUMNS_CHANGED",TABLE_CHANGED:"TABLE_CHANGED",FILTERS_CHANGED:"FILTERS_CHANGED",SORTS_CHANGED:"SORTS_CHANGED",DISCONNECT:"DISCONNECT",RECONNECT:"RECONNECT",TOTALS_UPDATED:"TOTALS_UPDATED",PENDING_DATA_UPDATED:"PENDING_DATA_UPDATED"}));var Cu=bu;function Su(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Eu extends Error{constructor(e,t){super("".concat(t," can't be empty (on pending row ").concat(e+1,")")),Su(this,"isMissingKey",!0),Su(this,"rowIndex",void 0),Su(this,"columnName",void 0),this.rowIndex=e,this.columnName=t}}var wu=Eu;function yu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Tu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yu(Object(n),!0).forEach((function(t){Nu(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ou(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function Mu(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Ou(s,i,a,r,o,"next",e)}function o(e){Ou(s,i,a,r,o,"throw",e)}r(void 0)}))}}function Nu(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Du=p.module("IrisGridTableModel");class xu extends Cu{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Hs,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;super(),Nu(this,"getColumnsWithLayoutHints",Object(ua.a)(((e,t,n,i)=>{var a=[...e.values()];if(t.length||n.length||i.length){var s=[],r=[],o=[];if(t.length&&(s=t.map((t=>e.get(t))).filter(Boolean)),n.length&&(r=n.map((t=>e.get(t))).filter(Boolean)),i.length&&(o=i.map((t=>e.get(t))).filter(Boolean)),s.length!==t.length||r.length!==n.length||o.length!==i.length)throw new Error("Layout hints are invalid (contain invalid column names)");var l=new Set(s),c=new Set(r),h=new Set(o),d=a.filter((e=>!l.has(e)&&!c.has(e)&&!h.has(e)));return[...o,...s,...d,...r]}return a}))),Nu(this,"getMemoizedColumnMap",Object(ua.a)((e=>{var t=new Map;return e.forEach((e=>t.set(e.name,e))),t}))),Nu(this,"getMemoizedFrontColumns",Object(ua.a)((e=>null!==e&&void 0!==e?e:[]))),Nu(this,"getMemoizedBackColumns",Object(ua.a)((e=>null!==e&&void 0!==e?e:[]))),Nu(this,"getMemoizedFrozenColumns",Object(ua.a)(((e,t)=>{var n;return null!==(n=null!==t&&void 0!==t?t:e)&&void 0!==n?n:[]}))),Nu(this,"getColumnIndicesByNameMap",Object(ua.a)((e=>{var t=new Map;return e.forEach(((e,n)=>{var{name:i}=e;return t.set(i,n)})),t}))),Nu(this,"getCachedFilterableColumnSet",Object(ua.a)((e=>new Set(e.map(((e,t)=>t)))))),Nu(this,"getCachedFormattedString",Pr(((e,t,n,i,a)=>e.getFormattedString(t,n,i,a)),{max:1e4})),Nu(this,"getCachedCustomColumnFormatFlag",Pr(((e,t,n)=>{var i=e.getColumnFormat(t,n);return null!=i&&(i.type===Es.TYPE_CONTEXT_PRESET||i.type===Es.TYPE_CONTEXT_CUSTOM)}),{max:1e4})),Nu(this,"getCachedViewportRowRange",Object(ua.a)(((e,t)=>{var n=t-e;return[Math.max(0,e-n*xu.ROW_BUFFER_PAGES),t+n*xu.ROW_BUFFER_PAGES]}))),Nu(this,"getCachedPendingErrors",Object(ua.a)(((e,t,n)=>{var i=new Map;return e.forEach(((e,a)=>{for(var{data:s}=e,r=0;r<n;r+=1)s.has(r)||(i.has(a)||i.set(a,[]),i.get(a).push(new wu(a,t[r].name)))})),i}))),this.handleTableDisconnect=this.handleTableDisconnect.bind(this),this.handleTableReconnect=this.handleTableReconnect.bind(this),this.handleTableUpdate=this.handleTableUpdate.bind(this),this.handleTotalsUpdate=this.handleTotalsUpdate.bind(this),this.handleRequestFailed=this.handleRequestFailed.bind(this),this.handleCustomColumnsChanged=this.handleCustomColumnsChanged.bind(this),this.setViewport=$n()(this.setViewport.bind(this),150),this.applyViewport=$n()(this.applyViewport.bind(this),0,{leading:!1}),this.irisFormatter=t,this.inputTable=n,this.listenerCount=0,this.subscription=null,this.table=e,this.viewport=null,this.viewportData=null,this.formattedStringData=[],this.pendingStringData=[],this.isSaveInProgress=!1,this.totalsTable=null,this.totalsTablePromise=null,this.totals=null,this.totalsDataMap=null,this.pendingNewDataMap=new Map,this.pendingNewRowCount=0,this.userFrozenColumns=null}close(){this.table.close(),null!==this.totalsTable&&this.totalsTable.close(),null!==this.totalsTablePromise&&this.totalsTablePromise.cancel()}startListening(){super.startListening(),this.table.addEventListener(va.Table.EVENT_DISCONNECT,this.handleTableDisconnect),this.table.addEventListener(va.Table.EVENT_RECONNECT,this.handleTableReconnect),this.table.addEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate),this.table.addEventListener(va.Client.EVENT_REQUEST_FAILED,this.handleRequestFailed),this.table.addEventListener(va.Table.EVENT_CUSTOMCOLUMNSCHANGED,this.handleCustomColumnsChanged),null!=this.totalsTable&&this.addTotalsListeners(this.totalsTable),this.applyViewport()}stopListening(){super.stopListening(),this.table.removeEventListener(va.Table.EVENT_DISCONNECT,this.handleTableDisconnect),this.table.removeEventListener(va.Table.EVENT_RECONNECT,this.handleTableReconnect),this.table.removeEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate),this.table.removeEventListener(va.Client.EVENT_REQUEST_FAILED,this.handleRequestFailed),this.table.removeEventListener(va.Table.EVENT_CUSTOMCOLUMNSCHANGED,this.handleCustomColumnsChanged),null!=this.totalsTable&&this.removeTotalsListeners(this.totalsTable),this.closeSubscription()}addTotalsListeners(e){e.addEventListener(va.Table.EVENT_UPDATED,this.handleTotalsUpdate),e.setViewport(0,0)}removeTotalsListeners(e){e.removeEventListener(va.Table.EVENT_UPDATED,this.handleTotalsUpdate)}handleTableDisconnect(){this.dispatchEvent(new CustomEvent(Cu.EVENT.DISCONNECT))}handleTableReconnect(){this.dispatchEvent(new CustomEvent(Cu.EVENT.RECONNECT))}handleTableUpdate(e){this.copyViewportData(e.detail),this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED))}handleTotalsUpdate(e){this.copyTotalsData(e.detail),this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED))}handleRequestFailed(e){this.dispatchEvent(new CustomEvent(Cu.EVENT.REQUEST_FAILED,e))}handleCustomColumnsChanged(){this.dispatchEvent(new CustomEvent(Cu.EVENT.COLUMNS_CHANGED,{detail:this.columns}))}get rowCount(){var e,t,n;return this.table.size+(null!==(e=null===(t=this.totals)||void 0===t||null===(n=t.operationOrder)||void 0===n?void 0:n.length)&&void 0!==e?e:0)+this.pendingNewRowCount}get pendingDataErrors(){var e,t;return this.getCachedPendingErrors(this.pendingNewDataMap,this.columns,null!==(e=null===(t=this.inputTable)||void 0===t?void 0:t.keyColumns.length)&&void 0!==e?e:0)}get pendingDataMap(){return this.pendingNewDataMap}set pendingDataMap(e){e!==this.pendingNewDataMap&&(e.forEach(((e,t)=>{if(!ol.isValidIndex(t))throw new Error("Invalid rowIndex",t);var{data:n}=e;n.forEach(((e,t)=>{if(!ol.isValidIndex(t))throw new Error("Invalid columnIndex",t)}))})),this.pendingNewDataMap=e,this.pendingNewRowCount=Math.max(this.pendingNewRowCount,this.maxPendingDataRow),this.formattedStringData=[],this.dispatchEvent(new CustomEvent(Cu.EVENT.PENDING_DATA_UPDATED)))}get pendingRowCount(){return this.pendingNewRowCount}set pendingRowCount(e){e!==this.pendingNewRowCount&&(this.pendingNewRowCount=Math.max(0,e,this.maxPendingDataRow),this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED)))}get maxPendingDataRow(){return this.pendingNewDataMap.size>0?Math.max(...this.pendingNewDataMap.keys())+1:0}get columnCount(){return this.columns.length}get floatingBottomRowCount(){var e,t,n,i;return null!==(e=this.totals)&&void 0!==e&&e.showOnTop?0:null!==(t=null===(n=this.totals)||void 0===n||null===(i=n.operationOrder)||void 0===i?void 0:i.length)&&void 0!==t?t:0}get floatingTopRowCount(){var e,t,n,i;return null!==(e=this.totals)&&void 0!==e&&e.showOnTop&&null!==(t=null===(n=this.totals)||void 0===n||null===(i=n.operationOrder)||void 0===i?void 0:i.length)&&void 0!==t?t:0}get isExportAvailable(){return null!=this.table.freeze}get isColumnStatisticsAvailable(){return null!=this.table.getColumnStatistics}get isValuesTableAvailable(){return null!=this.table.selectDistinct&&null!=this.table.copy}get isRollupAvailable(){return null!=this.table.rollup}get isSelectDistinctAvailable(){return null!=this.table.selectDistinct}get isCustomColumnsAvailable(){return null!=this.table.applyCustomColumns}get isChartBuilderAvailable(){return!0}get isTotalsAvailable(){return null!=this.table.getTotalsTable}get isEditable(){return!this.isSaveInProgress&&null!=this.inputTable}cacheFormattedValue(e,t,n){null==this.formattedStringData[e]&&(this.formattedStringData[e]=[]),this.formattedStringData[e][t]=n}cachePendingValue(e,t,n){null==this.pendingStringData[e]&&(this.pendingStringData[e]=[]),this.pendingStringData[e][t]=n}clearPendingValue(e,t){var n=this.pendingStringData[e];null!=n&&delete n[t]}textValueForCell(e,t){var n,i;if(void 0!==(null===(n=this.pendingStringData[e])||void 0===n?void 0:n[t]))return this.pendingStringData[e][t];if(void 0===(null===(i=this.formattedStringData[e])||void 0===i?void 0:i[t])){var a,s=this.valueForCell(e,t);if(null==s)return null;var r=null!==(a=this.totalsColumn(e,t))&&void 0!==a?a:this.columns[e],o=null;if(!this.getCachedCustomColumnFormatFlag(this.formatter,r.type,r.name)){var l=this.formatForCell(e,t);null!=(null===l||void 0===l?void 0:l.formatString)&&(o=l)}var c=this.displayString(s,r.type,r.name,o);this.cacheFormattedValue(e,t,c)}return this.formattedStringData[e][t]}textForCell(e,t){var n=this.textValueForCell(e,t);if(null==n&&this.isKeyColumn(e)){var i=this.pendingRow(t);if(this.pendingDataMap.has(i))return"*"}return n}colorForCell(e,t,n){var i=this.dataForCell(e,t);if(i){var{format:a}=i;if(a&&a.color)return a.color;if(this.isPendingRow(t))return n.pendingTextColor;var{value:s}=i;if(null!=s){var r,o=null!==(r=this.totalsColumn(e,t))&&void 0!==r?r:this.columns[e];if(cs.isDateType(o.type)||"Date"===o.name)return n.dateColor;if(cs.isNumberType(o.type))return s>0?n.positiveNumberColor:s<0?n.negativeNumberColor:n.zeroNumberColor}}else if(this.isPendingRow(t)&&this.isKeyColumn(e))return n.errorTextColor;return n.textColor}backgroundColorForCell(e,t){var n;return null===(n=this.formatForCell(e,t))||void 0===n?void 0:n.backgroundColor}textAlignForCell(e){var t=this.columns[e],{type:n}=t;return cs.isNumberType(n)?"right":cs.isDateType(n)||"Date"===t.name?"center":"left"}textForColumnHeader(e){var t=this.columns[e];return"".concat(t.name)}textForRowFooter(e){var t=this.totalsRow(e);return null!=t?this.totals.operationOrder[t]:""}get columns(){return this.getColumnsWithLayoutHints(this.columnMap,this.frontColumns,this.backColumns,this.frozenColumns)}get columnMap(){return this.getMemoizedColumnMap(this.table.columns)}get frontColumns(){var e;return this.getMemoizedFrontColumns(null===(e=this.layoutHints)||void 0===e?void 0:e.frontColumns)}get backColumns(){var e;return this.getMemoizedBackColumns(null===(e=this.layoutHints)||void 0===e?void 0:e.backColumns)}get frozenColumns(){var e;return this.getMemoizedFrozenColumns(null===(e=this.layoutHints)||void 0===e?void 0:e.frozenColumns,this.userFrozenColumns)}get layoutHints(){return this.table.layoutHints}get floatingLeftColumnCount(){return this.frozenColumns.length}get groupedColumns(){return[]}get description(){return this.table.description}row(e){var t,n,i,a,s,r,o,l,c,h,d=null!==(t=null===(n=this.totals)||void 0===n||null===(i=n.operationOrder)||void 0===i?void 0:i.length)&&void 0!==t?t:0,u=null!==(a=null===(s=this.totals)||void 0===s?void 0:s.showOnTop)&&void 0!==a&&a,m=this.totalsRow(e);if(null!=m){var p,g,v=this.totals.operationOrder[m];return null!==(p=null===(g=this.totalsDataMap)||void 0===g?void 0:g.get(v))&&void 0!==p?p:null}var f,b=this.pendingRow(e);if(null!=b)return null!==(f=this.pendingNewDataMap.get(b))&&void 0!==f?f:null;var C=(u?e-d:e)-(null!==(r=null===(o=this.viewportData)||void 0===o?void 0:o.offset)&&void 0!==r?r:0);return null!==(l=null===(c=this.viewportData)||void 0===c||null===(h=c.rows)||void 0===h?void 0:h[C])&&void 0!==l?l:null}totalsColumn(e,t){var n,i,a=this.totalsRow(t);if(null==a)return null;var s=this.totals.operationOrder[a],r=null!==(n=null===(i=this.totals)||void 0===i?void 0:i.defaultOperation)&&void 0!==n?n:Xo.SUM,o=this.columns[e];return this.totalsTable.columns.find((e=>e.name==="".concat(o.name,"__").concat(s)||s===r&&e.name===o.name))}totalsRow(e){var t,n,i,a,s,r=null!==(t=null===(n=this.totals)||void 0===n||null===(i=n.operationOrder)||void 0===i?void 0:i.length)&&void 0!==t?t:0,o=null!==(a=null===(s=this.totals)||void 0===s?void 0:s.showOnTop)&&void 0!==a&&a?e:e-this.table.size;return o>=0&&o<r?o:null}pendingRow(e){var t=e-this.floatingTopRowCount-this.table.size;return t>=0&&t<this.pendingNewRowCount?t:null}isTotalsRow(e){return null!=this.totalsRow(e)}isPendingRow(e){return null!=this.pendingRow(e)}dataForCell(e,t){var n;return null===(n=this.row(t))||void 0===n?void 0:n.data.get(e)}formatForCell(e,t){var n;return null===(n=this.dataForCell(e,t))||void 0===n?void 0:n.format}valueForCell(e,t){var n;return null===(n=this.dataForCell(e,t))||void 0===n?void 0:n.value}copyViewportData(e){e?(this.viewportData=this.extractViewportData(e),this.formattedStringData=[]):Du.warn("invalid data!")}copyTotalsData(e){var t,n,i,a=this;if(e){var{columns:s,rows:r}=e;if(1===r.length){for(var o=new Map,l=r[0],c=null!==(t=null===(n=this.totals)||void 0===n?void 0:n.defaultOperation)&&void 0!==t?t:Xo.SUM,h=null===(i=this.totals)||void 0===i?void 0:i.operationMap,d=function(e){var t,n,i=s[e],[r,d=(null!==(t=null===h||void 0===h||null===(n=h[r])||void 0===n?void 0:n[0])&&void 0!==t?t:c)]=i.name.split("__");o.has(d)||o.set(d,{data:new Map});var{data:u}=o.get(d),m=a.columns.findIndex((e=>e.name===r));u.set(m,{value:l.get(i),format:l.getFormat(i)})},u=0;u<s.length;u+=1)d(u);Du.debug2("copyTotalsData",o),this.totalsDataMap=o,this.formattedStringData=[]}else Du.error("Unexpected number of rows received for totals table, ignoring update")}else Du.warn("invalid data!")}getColumnIndexByName(e){return this.getColumnIndicesByNameMap(this.columns).get(e)}extractViewportData(e){for(var t={offset:e.offset,rows:[]},{columns:n}=e,i=0;i<e.rows.length;i+=1){var a=e.rows[i],s=this.extractViewportRow(a,n);t.rows.push(s)}return t}extractViewportRow(e,t){for(var n=new Map,i=0;i<t.length;i+=1){var a=t[i];n.set(this.getColumnIndexByName(a.name),{value:e.get(a),format:e.getFormat(a)})}return{data:n}}closeSubscription(){Du.debug2("closeSubscription",this.subscription),this.subscription&&(this.subscription.close(),this.subscription=null),this.setViewport.cancel(),this.applyViewport.cancel()}get filter(){return this.table.filter}set filter(e){this.closeSubscription(),this.table.applyFilter(e),this.applyViewport()}get formatter(){return this.irisFormatter}set formatter(e){this.irisFormatter=e,this.formattedStringData=[],this.dispatchEvent(new CustomEvent(Cu.EVENT.FORMATTER_UPDATED))}displayString(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return this.getCachedFormattedString(this.formatter,e,t,n,i)}get sort(){return this.table.sort}set sort(e){this.closeSubscription(),this.table.applySort(e),this.applyViewport()}get customColumns(){var e;return null!==(e=this.table.customColumns)&&void 0!==e?e:[]}set customColumns(e){this.closeSubscription(),this.table.applyCustomColumns(e),this.applyViewport()}updateFrozenColumns(e){this.userFrozenColumns=e,this.dispatchEvent(new CustomEvent(Cu.EVENT.TABLE_CHANGED))}set totalsConfig(e){Du.debug("set totalsConfig",e),e!==this.totals&&(this.totals=e,this.formattedStringData=[],null!=this.totalsTablePromise&&this.totalsTablePromise.cancel(),this.setTotalsTable(null),null!=e?(this.totalsTablePromise=Va.makeCancelable(this.table.getTotalsTable(e),(e=>e.close())),this.totalsTablePromise.then((e=>{this.totalsTablePromise=null,this.setTotalsTable(e)})).catch((e=>{Va.isCanceled(e)||(Du.error("Unable to set next totalsTable",e),this.totalsTablePromise=null,this.dispatchEvent(new CustomEvent(Cu.EVENT.REQUEST_FAILED,{detail:e})))}))):this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED)))}setTotalsTable(e){Du.debug("setTotalsTable",e),null!==this.totalsTable&&(this.listenerCount>0&&this.removeTotalsListeners(this.totalsTable),this.totalsTable.close()),this.totalsTable=e,this.totalsDataMap=null,this.listenerCount>0&&null!=this.totalsTable&&this.addTotalsListeners(e)}setViewport(e,t,n){if(t<e)Du.error("Invalid viewport",e,t);else{var{viewport:i}=this;null==i||i.top!==e||i.bottom!==t||i.columns!==n?(this.viewport={top:e,bottom:t,columns:n},Du.debug2("setViewport",this.viewport),this.applyViewport()):Du.debug2("Ignoring duplicate viewport",i)}}applyViewport(){if(this.viewport){Du.debug2("applyViewport",this.viewport);var{top:e,bottom:t,columns:n}=this.viewport,[i,a]=this.getCachedViewportRowRange(e,t);this.applyBufferedViewport(i,a,n)}}applyBufferedViewport(e,t,n){Du.debug2("applyBufferedViewport",e,t,n),null==this.subscription?(Du.debug2("applyBufferedViewport creating new subscription"),this.subscription=this.table.setViewport(e,t,n)):(Du.debug2("applyBufferedViewport using existing subscription"),this.subscription.setViewport(e,t,n))}snapshot(e){var t=arguments,n=this;return Mu((function*(){var i=t.length>1&&void 0!==t[1]&&t[1],a=t.length>2&&void 0!==t[2]?t[2]:e=>e;if(null==n.subscription)throw new Error("No subscription available");var s=fr.consolidate(e);if(!ol.isValidSnapshotRanges(s))throw new Error("Invalid snapshot ranges",e);for(var r=new Set,o=[],l=new Set,c=0;c<s.length;c+=1){for(var h=s[c],d=h.startRow;d<=h.endRow&&d<n.floatingTopRowCount;d+=1)r.add(d);h.endRow>=n.floatingTopRowCount&&h.startRow<=n.floatingTopRowCount+n.table.size&&o.push(new fr(h.startColumn,Math.min(Math.max(0,h.startRow-n.floatingTopRowCount)),h.endColumn,Math.min(Math.max(0,h.endRow-n.floatingTopRowCount),n.table.size-n.floatingTopRowCount)));for(var u=Math.max(h.startRow,n.floatingTopRowCount+n.table.size);u<=h.endRow&&u<n.floatingTopRowCount+n.table.size+n.floatingBottomRowCount;u+=1)l.add(u)}var m=ol.columnsFromRanges(s,n.columns),p=[];i&&p.push(m.map((e=>e.name)));for(var g=[...r].sort(),v=function(e){var t=g[e],s=m.map((e=>a(n.valueForCell(n.getColumnIndexByName(e.name),t),e)));i&&s.push(n.textForRowFooter(t)),p.push(s)},f=0;f<g.length;f+=1)v(f);if(o.length>0){var b=ol.rangeSetFromRanges(o),C=yield n.subscription.snapshot(b,m);p.push(...C.rows.map((e=>m.map((t=>a(e.get(t),t))))))}for(var S=[...l].sort(),E=function(e){var t=S[e],s=m.map((e=>a(n.valueForCell(n.getColumnIndexByName(e.name),t),e)));i&&s.push(n.textForRowFooter(t)),p.push(s)},w=0;w<S.length;w+=1)E(w);return p}))()}textSnapshot(e){var t=arguments,n=this;return Mu((function*(){var i=t.length>1&&void 0!==t[1]&&t[1],a=t.length>2&&void 0!==t[2]?t[2]:e=>"".concat(e);return Du.debug2("textSnapshot",e,i),(yield n.snapshot(e,i,a)).map((e=>e.join("\t"))).join("\n")}))()}get isFilterRequired(){return this.table.isUncoalesced}get hasExpandableRows(){return!1}isFilterable(e){return this.getCachedFilterableColumnSet(this.columns).has(e)}isRowExpanded(e){var t,n=this.row(e);return null!==(t=null===n||void 0===n?void 0:n.isExpanded)&&void 0!==t&&t}setRowExpanded(e,t){this.table.setExpanded(e,t)}depthForRow(e){var t,n=this.row(e);return(null!==(t=null===n||void 0===n?void 0:n.depth)&&void 0!==t?t:1)-1}valuesTable(e){var t=this;return Mu((function*(){var n=null;try{return(n=yield t.table.copy()).applyFilter([]),n.applySort([]),n.selectDistinct([e])}finally{null!=n&&n.close()}}))()}export(){var e=this;return Mu((function*(){return e.table.freeze()}))()}columnStatistics(e){return this.table.getColumnStatistics(e)}isColumnMovable(e){var t,n,i,a,s=this.columns[e].name;return!(null!==(t=this.layoutHints)&&void 0!==t&&null!==(n=t.frontColumns)&&void 0!==n&&n.includes(s)||null!==(i=this.layoutHints)&&void 0!==i&&null!==(a=i.backColumns)&&void 0!==a&&a.includes(s)||this.frozenColumns.includes(s))&&!this.isKeyColumn(e)}isColumnFrozen(e){return this.frozenColumns.includes(this.columns[e].name)}isKeyColumn(e){var t,n;return e<(null!==(t=null===(n=this.inputTable)||void 0===n?void 0:n.keyColumns.length)&&void 0!==t?t:0)}isRowMovable(){return!1}isEditableRange(e){return null!=this.inputTable&&fr.isBounded(e)&&(this.isPendingRow(e.startRow)&&this.isPendingRow(e.endRow)||e.startColumn>=this.inputTable.keyColumns.length&&e.endColumn>=this.inputTable.keyColumns.length)&&e.startRow>=this.floatingTopRowCount&&e.startRow<this.floatingTopRowCount+this.table.size+this.pendingRowCount&&e.endRow<this.floatingTopRowCount+this.table.size+this.pendingRowCount}isDeletableRange(e){return null!=this.inputTable&&null!=e.startRow&&null!=e.endRow&&e.startRow>=this.floatingTopRowCount&&e.startRow<this.floatingTopRowCount+this.table.size+this.pendingRowCount&&e.endRow<this.floatingTopRowCount+this.table.size+this.pendingRowCount}isEditableRanges(e){return e.every((e=>this.isEditableRange(e)))}isDeletableRanges(e){return e.every((e=>this.isDeletableRange(e)))}getTableAreaRange(){return new fr(null,this.floatingTopRowCount,null,this.floatingTopRowCount+this.table.size-1)}getPendingAreaRange(){return new fr(null,this.floatingTopRowCount+this.table.size,null,this.floatingTopRowCount+this.table.size+this.pendingNewRowCount-1)}setValueForCell(e,t,n){var i=this;return Mu((function*(){return i.setValueForRanges([new fr(e,t,e,t)],n)}))()}setValueForRanges(e,t){var n=this;return Mu((function*(){if(!n.isEditableRanges(e))throw new Error("Uneditable ranges",e);try{var i=new Set,a=[];fr.forEachCell(e,((e,s)=>{var r=n.columns[e];if(i.add(r),void 0===a[e]){var o=cs.makeValue(r.type,t,n.formatter.timeZone);a[e]=null!=o?n.displayString(o,r.type,r.name):null}n.cachePendingValue(e,s,a[e])}));var s=n.getPendingAreaRange(),r=e.map((e=>fr.intersection(s,e))).filter((e=>null!=e)).map((e=>fr.offset(e,0,-(n.floatingTopRowCount+n.table.size))));if(r.length>0){var o=new Map(n.pendingNewDataMap);fr.forEachCell(r,((e,i)=>{o.has(i)||o.set(i,{data:new Map});var a=n.columns[e],s=o.get(i),{data:r}=s,l=new Map(r),c=cs.makeValue(a.type,t,n.formatter.timeZone);null!=c?l.set(e,{value:c}):l.delete(e),l.size>0?o.set(i,Tu(Tu({},s),{},{data:l})):o.delete(i)})),n.pendingDataMap=o}n.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED));var l=n.getTableAreaRange(),c=e.map((e=>fr.intersection(l,e))).filter((e=>null!=e));if(c.length>0){var h=(yield n.snapshot(c.map((e=>new fr(null,e.startRow,null,e.endRow))))).map((e=>{for(var a={},s=0;s<n.columns.length;s+=1)a[n.columns[s].name]=e[s];return i.forEach((e=>{a[e.name]=cs.makeValue(e.type,t,n.formatter.timeZone)})),a})),d=yield n.inputTable.addRows(h);Du.debug("setValueForRanges(",e,",",t,") set tableRanges",c,"result",d)}fr.forEachCell(e,((e,t)=>{n.cacheFormattedValue(e,t,a[e])}))}catch(u){Du.error("Unable to set ranges",e,t,u)}finally{fr.forEachCell(e,((e,t)=>{n.clearPendingValue(e,t)}))}}))()}setValues(){var e=arguments,t=this;return Mu((function*(){var n=e.length>0&&void 0!==e[0]?e[0]:[];if(Du.debug("setValues(",n,")"),!n.every((e=>{var n,i;return t.isEditableRange(fr.makeCell(null!==(n=e.column)&&void 0!==n?n:e.x,null!==(i=e.row)&&void 0!==i?i:e.y))})))throw new Error("Uneditable ranges",n);try{var i=new Map(t.pendingNewDataMap);n.forEach((e=>{var n,a,{text:s}=e,r=null!==(n=e.column)&&void 0!==n?n:e.x,o=null!==(a=e.row)&&void 0!==a?a:e.y,l=t.columns[r],c=cs.makeValue(l.type,s,t.formatter.timeZone),h=null!=c?t.displayString(c,l.type,l.name):null;t.cachePendingValue(r,o,h);var d=t.pendingRow(o);if(null!=d){i.has(d)||i.set(d,{data:new Map});var u=i.get(d),{data:m}=u,p=new Map(m);null!=c?p.set(r,{value:c}):p.delete(r),p.size>0?i.set(d,Tu(Tu({},u),{},{data:p})):i.delete(d)}})),t.pendingDataMap=i,t.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED));var a=n.reduce(((e,t)=>{var n,i=null!==(n=t.row)&&void 0!==n?n:t.y;return e.has(i)||e.set(i,[]),e.get(i).push(t),e}),new Map),s=fr.consolidate(n.map((e=>{var t,n;return fr.makeCell(null!==(t=e.column)&&void 0!==t?t:e.x,null!==(n=e.row)&&void 0!==n?n:e.y)}))),r=t.getTableAreaRange(),o=s.map((e=>fr.intersection(r,e))).filter((e=>null!=e));if(o.length>0){var l=(yield t.snapshot(o.map((e=>new fr(null,e.startRow,null,e.endRow))))).map(((e,n)=>{for(var i=null,s=n,r=0;r<o.length;r+=1){var l=o[r],c=fr.rowCount([l]);if(s<c){i=l.startRow+s;break}s-=c}for(var h={},d=0;d<t.columns.length;d+=1)h[t.columns[d].name]=e[d];var u=a.get(i);return null!=u&&u.forEach((e=>{var n,i=t.columns[null!==(n=e.column)&&void 0!==n?n:e.x];h[i.name]=cs.makeValue(i.type,e.text,t.formatter.timeZone)})),h}));Du.info("setValues setting tableRanges",o);var c=yield t.inputTable.addRows(l);Du.info("setValues set tableRanges",o,"SUCCESS",c)}n.forEach((e=>{var n,i,{text:a}=e,s=null!==(n=e.column)&&void 0!==n?n:e.x,r=null!==(i=e.row)&&void 0!==i?i:e.y,o=t.columns[s],l=cs.makeValue(o.type,a,t.formatter.timeZone),c=null!=l?t.displayString(l,o.type,o.name):null;t.cacheFormattedValue(s,r,c)}))}finally{n.forEach((e=>{t.clearPendingValue(e.column,e.row)}))}}))()}commitPending(){var e=this;return Mu((function*(){if(e.pendingNewDataMap.size<=0)throw new Error("No pending changes to commit");try{var t,n;e.isSaveInProgress=!0;var i=[];e.pendingNewDataMap.forEach((t=>{var n={};t.data.forEach(((t,i)=>{var{value:a}=t,s=e.columns[i];n[s.name]=a})),i.push(n)}));var a=yield e.inputTable.addRows(i);return Du.debug("commitPending()",e.pendingNewDataMap,"result",a),e.pendingNewDataMap=new Map,e.pendingNewDataErrors=new Map,e.pendingNewRowCount=Math.max(0,(null!==(t=null===(n=e.viewport)||void 0===n?void 0:n.bottom)&&void 0!==t?t:0)-e.table.size),e.formattedStringData=[],e.dispatchEvent(new CustomEvent(Cu.EVENT.PENDING_DATA_UPDATED)),a}finally{e.isSaveInProgress=!1}}))()}editValueForCell(e,t){return this.textValueForCell(e,t)}delete(e){var t=this;return Mu((function*(){if(!t.isDeletableRanges(e))throw new Error("Undeletable ranges",e);var{keyColumns:n}=t.inputTable;if(0===n.length)throw new Error("No key columns to allow deletion");var i=t.getPendingAreaRange(),a=e.map((e=>fr.intersection(i,e))).filter((e=>null!=e)).map((e=>fr.offset(e,0,-(t.floatingTopRowCount+t.table.size))));if(a.length>0){for(var s=new Map(t.pendingNewDataMap),r=0;r<a.length;r+=1)for(var o=a[r],l=o.startRow;l<=o.endRow;l+=1)s.delete(l);t.pendingNewDataMap=s,t.formattedStringData=[],t.dispatchEvent(new CustomEvent(Cu.EVENT.PENDING_DATA_UPDATED)),t.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED))}var c=t.getTableAreaRange(),h=e.map((e=>fr.intersection(c,e))).filter((e=>null!=e));if(h.length<=0)return null;var[d,u]=yield Promise.all([t.snapshot(h.map((e=>new fr(0,e.startRow,n.length-1,e.endRow)))),t.table.copy()]),m=d.map((e=>{for(var t=[],i=0;i<n.length;i+=1){var a=n[i],s=e[i],r=cs.makeFilterRawValue(a.type,s),o=a.filter().eq(r);t.push(o)}return t.reduce(((e,t)=>e?e.and(t):t))})),p=m.reduce(((e,t)=>e?e.or(t):t));u.applyFilter([p]);var g=yield t.inputTable.deleteTable(u);return u.close(),g}))()}isValidForCell(e,t,n){try{var i=this.columns[e];return cs.makeValue(i.type,n,this.formatter.timeZone),!0}catch(a){return!1}}}Nu(xu,"ROW_BUFFER_PAGES",1),Nu(xu,"COLUMN_BUFFER_PAGES",0);var Ru=xu;function Iu(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function Lu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Fu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Lu(Object(n),!0).forEach((function(t){ku(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ku(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Au=class extends Ru{constructor(){super(...arguments),ku(this,"getCachedFilterableColumnSet",Object(ua.a)(((e,t)=>new Set(((null===t||void 0===t?void 0:t.length)>0?t:e).map((t=>e.findIndex((e=>t.name===e.name))))))))}applyBufferedViewport(e,t,n){this.table.setViewport(e,t,n)}textForCell(e,t){var n=this.columns[e],i=this.row(t);if(null!=i&&null!=n&&!i.hasChildren&&null!=n.constituentType){var a=this.valueForCell(e,t);return null!=a?this.displayString(a,n.constituentType,n.name):null}return super.textForCell(e,t)}extractViewportRow(e,t){var{isExpanded:n,hasChildren:i,depth:a}=e;return Fu(Fu({},super.extractViewportRow(e,t)),{},{isExpanded:n,hasChildren:i,depth:a})}snapshot(e){var t,n=arguments,i=this;return(t=function*(){var t=n.length>1&&void 0!==n[1]&&n[1],a=n.length>2&&void 0!==n[2]?n[2]:e=>e,{columns:s}=i.viewport,r=[];t&&r.push(s.map((e=>e.name)));for(var o=new fr(0,i.viewportData.offset,s.length,i.viewportData.offset+i.viewportData.rows.length),l=0;l<e.length;l+=1)for(var c=fr.intersection(o,e[l]),h=c.startRow;h<=c.endRow;h+=1){for(var d=[],u=i.viewportData.rows[h-i.viewportData.offset],m=c.startColumn;m<=c.endColumn;m+=1)d.push(a(u.data.get(m).value,i.columns[m]));r.push(d)}return r},function(){var e=this,n=arguments;return new Promise((function(i,a){var s=t.apply(e,n);function r(e){Iu(s,i,a,r,o,"next",e)}function o(e){Iu(s,i,a,r,o,"throw",e)}r(void 0)}))})()}get groupedColumns(){var e;return null!==(e=this.table.groupedColumns)&&void 0!==e?e:[]}get hasExpandableRows(){return!0}get isChartBuilderAvailable(){return!1}get isSelectDistinctAvailable(){return!1}get isReversible(){return!1}isFilterable(e){return this.getCachedFilterableColumnSet(this.columns,this.groupedColumns).has(e)}isColumnMovable(e){return e>=this.groupedColumns.length}isRowExpandable(e){var t,n=this.row(e);return null!==(t=null===n||void 0===n?void 0:n.hasChildren)&&void 0!==t&&t}isRowExpanded(e){var t,n=this.row(e);return null!==(t=null===n||void 0===n?void 0:n.isExpanded)&&void 0!==t&&t}setRowExpanded(e,t){this.table.setExpanded(e,t)}depthForRow(e){var t,n=this.row(e);return(null!==(t=null===n||void 0===n?void 0:n.depth)&&void 0!==t?t:1)-1}};function Pu(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function _u(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Pu(s,i,a,r,o,"next",e)}function o(e){Pu(s,i,a,r,o,"throw",e)}r(void 0)}))}}var Hu=p.module("IrisGridProxyModel");function ju(e,t,n){return cs.isTreeTable(e)?new Au(e,t):new Ru(e,t,n)}var Vu=class extends Cu{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Hs,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;super(),this.handleModelEvent=this.handleModelEvent.bind(this);var i=ju(e,t,n);this.originalModel=i,this.model=i,this.modelPromise=null,this.rollup=null,this.selectDistinct=[]}close(){this.originalModel.close(),this.model!==this.originalModel&&this.model.close(),null!=this.modelPromise&&this.modelPromise.cancel()}handleModelEvent(e){Hu.debug2("handleModelEvent",e);var{detail:t,type:n}=e;this.dispatchEvent(new CustomEvent(n,{detail:t}))}setModel(e){Hu.debug("setModel",e);var t=this.model;this.listenerCount>0&&this.removeListeners(t),t!==this.originalModel&&t.close(),this.model=e,this.listenerCount>0&&this.addListeners(e),this.dispatchEvent(new CustomEvent(Cu.EVENT.COLUMNS_CHANGED,{detail:e.columns})),this.dispatchEvent(new CustomEvent(Cu.EVENT.TABLE_CHANGED,{detail:e.table}))}setNextModel(e){Hu.debug2("setNextModel"),this.modelPromise&&this.modelPromise.cancel(),this.modelPromise=Va.makeCancelable(e,(e=>e.close())),this.modelPromise.then((e=>{this.modelPromise=null,this.setModel(e)})).catch((e=>{Va.isCanceled(e)||(Hu.error("Unable to set next model",e),this.modelPromise=null,this.dispatchEvent(new CustomEvent(Cu.EVENT.REQUEST_FAILED,{detail:e})))}))}startListening(){super.startListening(),this.addListeners(this.model)}stopListening(){super.stopListening(),this.removeListeners(this.model)}addListeners(e){for(var t=Object.keys(Cu.EVENT),n=0;n<t.length;n+=1)e.addEventListener(t[n],this.handleModelEvent)}removeListeners(e){for(var t=Object.keys(Cu.EVENT),n=0;n<t.length;n+=1)e.removeEventListener(t[n],this.handleModelEvent)}get rowCount(){return this.model.rowCount}get columnCount(){return this.model.columnCount}get floatingTopRowCount(){return this.model.floatingTopRowCount}get floatingBottomRowCount(){return this.model.floatingBottomRowCount}get floatingLeftColumnCount(){return this.model.floatingLeftColumnCount}get floatingRightColumnCount(){return this.model.floatingRightColumnCount}textForCell(){return this.model.textForCell(...arguments)}textAlignForCell(){return this.model.textAlignForCell(...arguments)}colorForCell(){return this.model.colorForCell(...arguments)}backgroundColorForCell(){return this.model.backgroundColorForCell(...arguments)}textForColumnHeader(){return this.model.textForColumnHeader(...arguments)}textForRowHeader(){return this.model.textForRowHeader(...arguments)}textForRowFooter(){return this.model.textForRowFooter(...arguments)}isRowMovable(){return this.model.isRowMovable(...arguments)}isColumnMovable(){return this.model.isColumnMovable(...arguments)}isColumnFrozen(){return this.model.isColumnFrozen(...arguments)}get hasExpandableRows(){return this.model.hasExpandableRows}isRowExpandable(){return this.model.isRowExpandable(...arguments)}isRowExpanded(){return this.model.isRowExpanded(...arguments)}setRowExpanded(){this.model.setRowExpanded(...arguments)}depthForRow(){return this.model.depthForRow(...arguments)}get table(){return this.model.table}get isExportAvailable(){return this.model.isExportAvailable}get isColumnStatisticsAvailable(){return this.model.isColumnStatisticsAvailable}get isValuesTableAvailable(){return this.model.isValuesTableAvailable}get isCustomColumnsAvailable(){return this.model.isCustomColumnsAvailable&&!(this.isSelectDistinctAvailable&&this.selectDistinctColumns.length>0)}get isChartBuilderAvailable(){return this.model.isChartBuilderAvailable}get isRollupAvailable(){return(this.originalModel.isRollupAvailable||null!=this.rollup)&&0===this.selectDistinct.length}get isSelectDistinctAvailable(){return(this.originalModel.isSelectDistinctAvailable||this.selectDistinct.length>0)&&null==this.rollup}get isTotalsAvailable(){return this.model.isTotalsAvailable}get isReversible(){return this.model.isReversible}get columns(){return this.model.columns}get layoutHints(){return this.model.layoutHints}updateFrozenColumns(){this.model.updateFrozenColumns(...arguments)}get originalColumns(){return this.originalModel.columns}get groupedColumns(){return this.model.groupedColumns}get description(){return this.model.description}formatForCell(e,t){return this.model.formatForCell(e,t)}valueForCell(e,t){return this.model.valueForCell(e,t)}get filter(){return this.model.filter}set filter(e){this.model.filter=e}get formatter(){return this.model.formatter}set formatter(e){this.model.formatter=e}displayString(){return this.model.displayString(...arguments)}get sort(){return this.model.sort}set sort(e){this.model.sort=e}get customColumns(){return this.model.customColumns}set customColumns(e){this.model.customColumns=e}get rollupConfig(){return this.rollup}set rollupConfig(e){if(Hu.debug("set rollupConfig",e),!this.isRollupAvailable)throw new Error("Rollup Rows are not available");if(!oe()(e,this.rollup)){this.rollup=e;var t=Promise.resolve(this.originalModel);null!=e&&(t=this.originalModel.table.rollup(e).then((e=>ju(e,this.formatter)))),this.setNextModel(t)}}get selectDistinctColumns(){return this.selectDistinct}set selectDistinctColumns(e){if(Hu.debug("set selectDistinctColumns",e),!this.isSelectDistinctAvailable)throw new Error("Select distinct is not available");if(e===this.selectDistinctColumns||0===e.length&&0===this.selectDistinctColumns.length)Hu.debug("Ignore same selectDistinctColumns",e);else{this.selectDistinct=e;var t=e.map((e=>this.originalColumns.find((t=>t.name===e)))).filter((e=>null!=e)),n=Promise.resolve(this.originalModel);e.length>0&&(n=this.originalModel.table.selectDistinct(t).then((e=>ju(e,this.formatter)))),this.setNextModel(n)}}get totalsConfig(){return this.model.totalsConfig}set totalsConfig(e){this.model.totalsConfig=e}get isFilterRequired(){return this.model.isFilterRequired}get isEditable(){return this.model.isEditable}isEditableRange(){return this.model.isEditableRange(...arguments)}isFilterable(){return this.model.isFilterable(...arguments)}setViewport(){this.model.setViewport(...arguments)}snapshot(){var e=arguments,t=this;return _u((function*(){return t.model.snapshot(...e)}))()}textSnapshot(){var e=arguments,t=this;return _u((function*(){return t.model.textSnapshot(...e)}))()}export(){var e=arguments,t=this;return _u((function*(){return t.model.export(...e)}))()}valuesTable(){var e=arguments,t=this;return _u((function*(){return t.model.valuesTable(...e)}))()}columnStatistics(){var e=arguments,t=this;return _u((function*(){return t.model.columnStatistics(...e)}))()}editValueForCell(){return this.model.editValueForCell(...arguments)}setValueForCell(){return this.model.setValueForCell(...arguments)}setValueForRanges(){return this.model.setValueForRanges(...arguments)}setValues(){return this.model.setValues(...arguments)}isValidForCell(){return this.model.isValidForCell(...arguments)}delete(){return this.model.delete(...arguments)}get pendingDataMap(){return this.model.pendingDataMap}set pendingDataMap(e){this.model.pendingDataMap=e}get pendingRowCount(){return this.model.pendingRowCount}set pendingRowCount(e){this.model.pendingRowCount=e}get pendingDataErrors(){return this.model.pendingDataErrors}commitPending(){return this.model.commitPending(...arguments)}getColumnIndexByName(e){return this.model.getColumnIndexByName(e)}};function zu(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}var Uu=class{static makeModel(e){var t,n=arguments;return(t=function*(){var t=n.length>1&&void 0!==n[1]&&n[1],i=n.length>2&&void 0!==n[2]?n[2]:new Hs;if(!t&&e.isUncoalesced)throw e.close(),new Error("Table is uncoalesced. Tables must contain a where clause when part of persistent queries to be viewable.");var a=null;return e.hasInputTable&&(a=yield e.inputTable()),new Vu(e,i,a)},function(){var e=this,n=arguments;return new Promise((function(i,a){var s=t.apply(e,n);function r(e){zu(s,i,a,r,o,"next",e)}function o(e){zu(s,i,a,r,o,"throw",e)}r(void 0)}))})()}};n(1164);function Bu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Wu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bu(Object(n),!0).forEach((function(t){Gu(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Gu(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var qu=p.module("ConsolePanel"),Ku=Object.freeze({consoleSettings:{},itemIds:[]});class Yu extends i.PureComponent{constructor(e){super(e),this.handleFocusCommandHistory=this.handleFocusCommandHistory.bind(this),this.handleOpenObject=this.handleOpenObject.bind(this),this.handleCloseObject=this.handleCloseObject.bind(this),this.handleResize=this.handleResize.bind(this),this.handleSettingsChange=this.handleSettingsChange.bind(this),this.handleShow=this.handleShow.bind(this),this.handleTabBlur=this.handleTabBlur.bind(this),this.handleTabFocus=this.handleTabFocus.bind(this),this.handlePanelMount=this.handlePanelMount.bind(this),this.savePanelState=pa()(this.savePanelState.bind(this),500),this.consoleRef=a.a.createRef();var{panelState:t}=e,n=Wu(Wu({},Ku),t||{}),{consoleSettings:i,itemIds:s}=n;this.state={consoleSettings:i,itemIds:new Map(s),panelState:n}}componentDidMount(){var{glEventHub:e}=this.props;this.closeDisconnectedPanels(),e.on(fi.MOUNT,this.handlePanelMount)}componentDidUpdate(e,t){var{consoleSettings:n,itemIds:i}=this.state;t.consoleSettings===n&&t.itemIds===i||this.savePanelState()}componentWillUnmount(){var{glEventHub:e}=this.props;this.savePanelState.flush(),e.off(fi.MOUNT,this.handlePanelMount)}setItemId(e,t){this.setState((n=>{var{itemIds:i}=n,a=new Map(i);return a.set(e,t),{itemIds:a}}))}getItemId(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],{itemIds:n}=this.state,i=n.get(e);return null==i&&t&&(i=ni.a.generate(),this.setItemId(e,i)),i}handleTabBlur(){this.consoleRef&&this.consoleRef.blur()}handleTabFocus(){this.consoleRef&&this.consoleRef.focus()}handlePanelMount(e){var t,n,i,{itemIds:a}=this.state,s=null===e||void 0===e||null===(t=e.props)||void 0===t?void 0:t.id,r=null===e||void 0===e||null===(n=e.props)||void 0===n||null===(i=n.metadata)||void 0===i?void 0:i.sourcePanelId;s&&r&&(new Set(a.values()).has(r)&&this.setItemId(s,s))}handleFocusCommandHistory(){var{glEventHub:e}=this.props;e.emit(Il.FOCUS_HISTORY)}handleResize(){this.updateDimensions()}handleShow(){this.updateDimensions()}handleOpenObject(e){var{sessionWrapper:t}=this.props,{session:n}=t,{type:i}=e;Wh.isTableType(i)?this.openTable(e,n):Wh.isFigureType(i)?this.openFigure(e,n):Wh.isPandas(i)?this.openPandas(e,n):qu.error("Unknown object",e)}handleCloseObject(e){var{name:t}=e,n=this.getItemId(t,!1),{glEventHub:i}=this.props;i.emit(fi.CLOSE,n)}handleSettingsChange(e){var{glEventHub:t}=this.props;qu.debug("handleSettingsChange",e),this.setState({consoleSettings:e}),t.emit(Il.SETTINGS_CHANGED,e)}openTable(e,t){var{name:n}=e,i=this.getItemId(n),a={table:n},{glEventHub:s}=this.props;qu.debug("handleOpenTable",i),s.emit(_l.OPEN_GRID,n,(()=>t.getObject(e).then((e=>Uu.makeModel(e,!0)))),a,i)}openFigure(e,t){var{name:n}=e,i=this.getItemId(n),a={figure:n},{glEventHub:s}=this.props;s.emit(Dl.OPEN,n,(()=>t.getObject(e).then((e=>Vh.makeModel(void 0,e)))),a,i)}openPandas(e,t){var{name:n}=e,i=this.getItemId(n),a={table:n},{glEventHub:s}=this.props;qu.debug("handleOpenTable",i),s.emit(Wl.OPEN,n,(()=>t.getObject(e).then((e=>Uu.makeModel(e,!0)))),a,i)}addCommand(e){var t,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];null===(t=this.consoleRef.current)||void 0===t||t.addCommand(e,n,i)}closeDisconnectedPanels(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],{consoleSettings:t,itemIds:n}=this.state,{isClosePanelsOnDisconnectEnabled:i=!0}=t;if(i||e){var a=[...n.values()],{glEventHub:s}=this.props;a.forEach((e=>{s.emit(fi.CLOSE,e)})),this.setState({itemIds:new Map})}}savePanelState(){var{consoleSettings:e,itemIds:t}=this.state,n={consoleSettings:e,itemIds:[...t]};qu.debug("Saving panel state",n),this.setState({panelState:n})}updateDimensions(){var e;null===(e=this.consoleRef.current)||void 0===e||e.updateDimensions()}render(){var{commandHistoryStorage:e,glContainer:t,glEventHub:n,sessionWrapper:i,timeZone:s}=this.props,{consoleSettings:r,error:o}=this.state,{config:l,session:c}=i,{id:h,type:d}=l;return a.a.createElement(Jl,{componentPanel:this,glContainer:t,glEventHub:n,onResize:this.handleResize,onShow:this.handleShow,onTabFocus:this.handleTabFocus,onTabBlur:this.handleTabBlur,isLoaded:null!=c,errorMessage:null!=o?"".concat(o):null},a.a.createElement(We.CSSTransition,{in:null!=c,timeout:Kn.transitionMidMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement(a.a.Fragment,null,c&&a.a.createElement(gu,{ref:this.consoleRef,settings:r,session:c,focusCommandHistory:this.handleFocusCommandHistory,openObject:this.handleOpenObject,closeObject:this.handleCloseObject,commandHistoryStorage:e,onSettingsChange:this.handleSettingsChange,language:d,statusBarChildren:a.a.createElement(a.a.Fragment,null,a.a.createElement("div",null,"\xa0"),a.a.createElement("div",null,bh.LANGUAGE_MAP.get(d))),scope:h,timeZone:s}))))}}Gu(Yu,"COMPONENT","ConsolePanel"),Gu(Yu,"TITLE","Console"),Yu.propTypes={commandHistoryStorage:pi.a.shape({}).isRequired,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({consoleCreatorSettings:pi.a.shape({}),consoleSettings:pi.a.shape({}),itemIds:pi.a.array}),sessionWrapper:pi.a.shape({session:Ma.IdeSession,config:pi.a.shape({type:pi.a.string,id:pi.a.string})}).isRequired,timeZone:pi.a.string.isRequired},Yu.defaultProps={panelState:null};var Xu=Object(o.b)(((e,t)=>({commandHistoryStorage:k(e),sessionWrapper:Tc(e,t.localDashboardId),timeZone:j(e)})),null,null,{forwardRef:!0})(Yu),Zu=(n(1261),e=>{var{className:t,isFlipped:n,children:s}=e,r=e=>{if(2!==s.length)throw new Error("CardFlip requires 2 children to function");return s[e]},o=Object(i.useRef)(null),l=Object(i.useCallback)((e=>{e.target===e.currentTarget&&document.body.classList.add("card-flip--is-flipping")}),[]),c=Object(i.useCallback)((e=>{e.target===e.currentTarget&&document.body.classList.remove("card-flip--is-flipping")}),[]);return Object(i.useEffect)((()=>{if(!o.current)throw Error("ref undefined");o.current.addEventListener("transitionstart",l)}),[l]),a.a.createElement("div",{className:qe()(t,{"card-flip--show-front":n,"card-flip--show-back":!n})},a.a.createElement("div",{className:"card-flip--back"},r(0)),a.a.createElement("div",{ref:o,className:"card-flip--front",onTransitionEnd:c},r(1)))});n(1260);function $u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Qu=p.module("DropdownFilter");class Ju extends i.Component{constructor(e){super(e),$u(this,"getCompatibleColumns",Object(ua.a)(((e,t)=>e?t.filter((t=>{var{type:n}=t;return cs.isCompatibleType(n,e.columnType)})):[]))),$u(this,"getColumnOptions",Object(ua.a)(((e,t)=>{var n=-1,i=[];return i.push(a.a.createElement("option",{key:"placeholder",value:"-1"},"Select a column")),e.forEach(((s,r)=>{i.push(a.a.createElement("option",{key:"".concat(s.name,"/").concat(s.type),value:r},this.getItemLabel(e,r))),null!==t&&s.name===t.name&&s.type===t.type&&(n=r)})),[i,n]}))),$u(this,"getSelectedOptionIndex",Object(ua.a)(((e,t)=>e.indexOf(t)))),$u(this,"getValueOptions",Object(ua.a)((e=>[a.a.createElement("option",{value:"-1",key:"-1"},Ju.PLACEHOLDER),...e.map(((e,t)=>a.a.createElement("option",{value:t,key:"".concat(t,"/").concat(e)},e)))]))),$u(this,"getItemLabel",Lr()(((e,t)=>{var{name:n,type:i}=e[t];if(t>0&&e[t-1].name===n||t<e.length-1&&e[t+1].name===n){var a=i.substring(i.lastIndexOf(".")+1);return"".concat(n," (").concat(a,")")}return n}))),this.handleColumnChange=this.handleColumnChange.bind(this),this.handleSettingsCancel=this.handleSettingsCancel.bind(this),this.handleSettingsClick=this.handleSettingsClick.bind(this),this.handleSettingsSave=this.handleSettingsSave.bind(this),this.handleBackgroundClick=this.handleBackgroundClick.bind(this),this.handleDropdownKeyPress=this.handleDropdownKeyPress.bind(this),this.handleValueChange=this.handleValueChange.bind(this),this.sendUpdate=pa()(this.sendUpdate.bind(this),150),this.dropdownRef=a.a.createRef();var{column:t,isValueShown:n,value:i}=e;this.state={column:t,selectedColumn:t,disableCancel:!n,isValueShown:n,value:i}}componentDidUpdate(e,t){var{source:n,values:i,isLoaded:a}=this.props,{column:s,value:r,isValueShown:o}=this.state;a&&(n!==e.source&&this.sourceUpdated(),i===e.values||""===r||i.includes(r)||this.resetValue(),o!==t.isValueShown&&o&&this.focusInput(),s===t.column&&r===t.value&&o===t.isValueShown||this.sendUpdate())}componentWillUnmount(){this.sendUpdate.flush()}handleColumnChange(e){var{value:t}=e.target;if(Qu.debug2("handleColumnChange",t),t<0)this.setState({selectedColumn:null});else{var{columns:n,source:i}=this.props,a=this.getCompatibleColumns(i,n);this.setState({selectedColumn:a[t]})}}handleDropdownKeyPress(e){"Enter"===e.key&&(e.preventDefault(),e.stopPropagation(),Qu.debug2("handleDropdownKeyPress"),this.sendUpdate(),this.sendUpdate.flush())}handleValueChange(e){var{value:t}=e.target,n=parseInt(t,10),i="",{values:a}=this.props;if(-1===n)Qu.debug2("Selected default item");else{if(!(n>=0&&n<a.length))return void Qu.error("Invalid index",n,a);i=a[n]}Qu.debug2("handleValueChange",i),this.setState({value:i})}handleSettingsCancel(){this.setState((e=>{var{column:t}=e;return{selectedColumn:t,isValueShown:!0}}))}handleSettingsSave(){this.setState((e=>{var{column:t,selectedColumn:n,value:i}=e;return{column:n,value:t===n?i:"",isValueShown:!0,disableCancel:!1}}))}handleSettingsClick(e){e.stopPropagation(),this.showSettings()}handleBackgroundClick(e){e.target!==this.dropdownRef.current&&this.focusInput()}handleMouseEnter(){var{onSourceMouseEnter:e}=this.props;e()}handleMouseLeave(){var{onSourceMouseLeave:e}=this.props;e()}sourceUpdated(){this.setState({column:null,selectedColumn:null,isValueShown:!1,disableCancel:!0,value:""})}showSettings(){var{column:e}=this.state;this.setState({selectedColumn:e,isValueShown:!1})}focusInput(){null!==this.dropdownRef.current&&this.dropdownRef.current.focus()}resetValue(){this.setState({value:""})}clearFilter(){this.resetValue()}setFilterState(e){var{name:t,type:n,value:i,isValueShown:a}=e,s=null!=t&&null!=n?{name:t,type:n}:null;this.setState({column:s,value:i,isValueShown:a})}sendUpdate(){var{onChange:e}=this.props,{column:t,value:n,isValueShown:i}=this.state;e({column:t,isValueShown:i,value:n})}render(){var e,{columns:t,disableLinking:n,isLinkerActive:i,isLoaded:s,source:r,onColumnSelected:o,onSourceMouseEnter:l,onSourceMouseLeave:c,values:h,settingsError:d}=this.props,{column:u,disableCancel:m,isValueShown:p,selectedColumn:g,value:v}=this.state,f=null===r,b=this.getCompatibleColumns(r,t),C=null!=r,S=null!==(e=null===r||void 0===r?void 0:r.columnName)&&void 0!==e?e:Ju.SOURCE_BUTTON_PLACEHOLDER,E=null!=u?"".concat(u.name," Filter"):null,[w,y]=this.getColumnOptions(b,g),T=this.getValueOptions(h),O=this.getSelectedOptionIndex(h,v),M=!C||null==g,N=p&&!i;return a.a.createElement(Zu,{className:"dropdown-filter fill-parent-absolute",isFlipped:N},a.a.createElement("div",{className:"dropdown-filter-settings-card"},a.a.createElement("div",{className:"dropdown-filter-card-content"},a.a.createElement("div",{className:"dropdown-filter-settings-grid"},a.a.createElement("label",null,"Source Column"),a.a.createElement(Lc,{isLinked:C,onClick:o,onMouseEnter:l,onMouseLeave:c,className:Ju.SOURCE_BUTTON_CLASS_NAME,disabled:n},S),a.a.createElement("div",{className:"text-muted small"},"Select a source column for the list by linking to a table."),a.a.createElement("label",null,"Filter Column"),a.a.createElement("select",{value:y,className:"custom-select",onChange:this.handleColumnChange,disabled:f},w),a.a.createElement("div",{className:"text-muted small"},"Dropdown filter control will apply its filter to all columns matching this name in this dashboard.")),d&&a.a.createElement("div",{className:"error-message text-center"},d),C&&a.a.createElement("div",{className:"dropdown-filter-settings-buttons"},a.a.createElement(gh,{kind:"secondary",type:"button",onClick:this.handleSettingsCancel,disabled:m||p||i,tooltip:i?"Cancel disabled while linker open":null},"Cancel"),a.a.createElement(gh,{kind:"primary",type:"button",className:"ml-2",onClick:this.handleSettingsSave,disabled:M||p||i,tooltip:i?"Save disabled while linker open":null},"Save")))),a.a.createElement("div",{className:"dropdown-filter-value-card",onClick:this.handleBackgroundClick},s&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"dropdown-filter-column"},a.a.createElement("div",{className:"dropdown-filter-column-title"},E)),a.a.createElement("div",{className:"dropdown-filter-card-content"},a.a.createElement("div",{className:"dropdown-filter-value-input d-flex flex-column justify-content-center"},a.a.createElement("select",{className:"custom-select",value:O,ref:this.dropdownRef,onChange:this.handleValueChange,onKeyPress:this.handleDropdownKeyPress},T)),d&&a.a.createElement("div",{className:"error-message mt-3 text-center"},d)),a.a.createElement("div",{className:"dropdown-filter-menu"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon m-2 px-2",onClick:this.handleSettingsClick},a.a.createElement(Ke.a,{icon:Et,transform:"grow-4"}))))))}}$u(Ju,"PLACEHOLDER","Select a value..."),$u(Ju,"SOURCE_BUTTON_CLASS_NAME","btn-dropdown-filter-selector"),$u(Ju,"SOURCE_BUTTON_PLACEHOLDER","Select a column"),Ju.propTypes={column:Ma.Column,columns:pi.a.arrayOf(Ma.Column).isRequired,onSourceMouseEnter:pi.a.func,onSourceMouseLeave:pi.a.func,disableLinking:pi.a.bool,isLinkerActive:pi.a.bool,isLoaded:pi.a.bool,isValueShown:pi.a.bool,settingsError:pi.a.string,source:mc.LinkPoint,value:pi.a.string,values:pi.a.arrayOf(pi.a.string),onChange:pi.a.func.isRequired,onColumnSelected:pi.a.func},Ju.defaultProps={column:null,disableLinking:!1,isLinkerActive:!1,isLoaded:!1,isValueShown:!1,settingsError:null,source:null,value:"",values:[],onColumnSelected:()=>{},onSourceMouseEnter:()=>{},onSourceMouseLeave:()=>{}};var em=Ju;n(1262);function tm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var nm=p.module("DropdownFilterPanel");class im extends i.Component{constructor(e){super(e),tm(this,"getCachedValues",Object(ua.a)(((e,t,n)=>{var{type:i,name:a}=t;return cs.isDateType(i)?e.map((e=>im.DATETIME_FORMATTER.format(e))):e.map((e=>null!=e?n.getFormattedString(e,i,a):null))}))),tm(this,"getCachedPanelLinks",Object(ua.a)(((e,t)=>{var n=di.getIdFromPanel(t);return nm.debug("getCachedPanelLinks",e,n),e.filter((e=>{var t;return(null===(t=e.end)||void 0===t?void 0:t.panelId)===n}))}))),tm(this,"getCachedSource",Object(ua.a)((e=>{nm.debug("getCachedSource",e);var t=null;if(e.length>0){var[n]=e;t=n.start,e.length>1&&nm.error("Filter has more that one link",e)}return t}))),tm(this,"getCachedSourceTable",Object(ua.a)(((e,t)=>{var n;if(nm.debug("getCachedSourceTable",e,t),null==t)return null;var{panelId:i}=t;return null!==(n=e.get(i))&&void 0!==n?n:null}))),tm(this,"getCachedSourceColumn",Object(ua.a)(((e,t)=>{var n;return nm.debug("getCachedSourceColumn",e,t),null==e||null==t?null:null!==(n=e.columns.find((e=>{var{name:n,type:i}=e;return n===t.columnName&&i===t.columnType})))&&void 0!==n?n:null}))),this.handleChange=pa()(this.handleChange.bind(this),250),this.handleClearAllFilters=this.handleClearAllFilters.bind(this),this.handleDisconnect=this.handleDisconnect.bind(this),this.handleReconnect=this.handleReconnect.bind(this),this.handleColumnSelected=this.handleColumnSelected.bind(this),this.handleSourceFilterChange=this.handleSourceFilterChange.bind(this),this.handleSourceSortChange=this.handleSourceSortChange.bind(this),this.handleSourceSizeChange=this.handleSourceSizeChange.bind(this),this.handleSourceMouseEnter=this.handleSourceMouseEnter.bind(this),this.handleSourceMouseLeave=this.handleSourceMouseLeave.bind(this),this.handleValuesTableUpdate=this.handleValuesTableUpdate.bind(this),this.dropdownFilterRef=a.a.createRef(),this.panelContainer=a.a.createRef(),this.pending=new Ua,this.cleanup=null;var{panelState:t,settings:n}=e;this.columnFormats=n.columnFormats;var{value:i="",isValueShown:s=!1,name:r,type:o,timestamp:l=null}=null!==t&&void 0!==t?t:{},c=null!=r&&null!=o?{name:r,type:o}:null;this.state={column:c,formatter:new Hs(this.columnFormats),valuesTable:null,valuesColumn:null,sourceSize:0,value:i,timestamp:l,values:[],isValueShown:s,wasFlipped:!1,skipUpdate:!1,panelState:t,isDisconnected:!1,isLoading:!1,isLoaded:!1,error:null}}componentDidMount(){this.updateValuesTable();var{column:e,value:t,timestamp:n}=this.state,i=this.getSourceTable();if(null!==i&&this.startListeningToSource(i),null!=e){var{name:a,type:s}=e;this.sendUpdate(a,s,t,n)}}componentDidUpdate(e,t){var{valuesTable:n}=this.state,{settings:i}=this.props,a=this.getSource(),s=this.getSourceTable(),r=this.getSource(e),o=this.getSourceTable(e);i!==e.settings&&this.updateFormatterSettings(i),n!==t.valuesTable&&null!==t.valuesTable&&(nm.debug("Table in state modified, closing the old table."),t.valuesTable.close()),s===o&&a===r||this.updateValuesTable(),s!==o&&(null!==o&&this.stopListeningToSource(o),null!==s&&this.startListeningToSource(s))}componentWillUnmount(){var{valuesTable:e}=this.state,t=this.getSourceTable();this.pending.cancel(),null!==t&&this.stopListeningToSource(t),this.cleanup&&this.cleanup(),null!==e&&e.close()}getCoordinateForColumn(){var e;if(!this.panelContainer.current)return null;var t=this.panelContainer.current.querySelector(".".concat(em.SOURCE_BUTTON_CLASS_NAME)),n=null!==(e=null===t||void 0===t?void 0:t.getBoundingClientRect())&&void 0!==e?e:null;return null==n||n.width<=0||n.height<=0?null:[n.left+n.width/2,n.bottom]}getSettingsErrorMessage(){var{sourceSize:e}=this.state;return e>im.MAX_TABLE_SIZE?"Table too large, must have fewer than ".concat(im.MAX_TABLE_SIZE," options."):null}getPanelErrorMessage(){var{error:e}=this.state;return e?"".concat(e):null}getSource(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props,{dashboardLinks:t}=e,n=this.getCachedPanelLinks(t,this);return this.getCachedSource(n)}getSourceTable(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props,{panelTableMap:t}=e,n=this.getSource(e);return this.getCachedSourceTable(t,n)}getValuesColumn(e){var t=this.getSource();return this.getCachedSourceColumn(e,t)}startListeningToSource(e){nm.debug("startListeningToSource"),e.addEventListener(va.Table.EVENT_FILTERCHANGED,this.handleSourceFilterChange),e.addEventListener(va.Table.EVENT_SORTCHANGED,this.handleSourceSortChange),e.addEventListener(va.Table.EVENT_SIZECHANGED,this.handleSourceSizeChange),e.addEventListener(va.Table.EVENT_DISCONNECT,this.handleDisconnect),e.addEventListener(va.Table.EVENT_RECONNECT,this.handleReconnect)}stopListeningToSource(e){nm.debug("stopListeningToSource"),e.removeEventListener(va.Table.EVENT_FILTERCHANGED,this.handleSourceFilterChange),e.removeEventListener(va.Table.EVENT_SORTCHANGED,this.handleSourceSortChange),e.removeEventListener(va.Table.EVENT_SIZECHANGED,this.handleSourceSizeChange),e.removeEventListener(va.Table.EVENT_DISCONNECT,this.handleDisconnect),e.removeEventListener(va.Table.EVENT_RECONNECT,this.handleReconnect)}handleChange(e){var{column:t,isValueShown:n,value:i}=e,{name:a=null,type:s=null}=null!==t&&void 0!==t?t:{},r=!0,o=Date.now();this.setState((e=>{var{panelState:t,timestamp:l,wasFlipped:c,skipUpdate:h}=e,d=null!=t&&n!==t.isValueShown&&a===t.name&&s===t.type&&i===t.value;return(r=!h&&n&&(!d||!c))||(o=l),{panelState:{isValueShown:n,name:a,type:s,value:i,timestamp:o},timestamp:o,wasFlipped:d,skipUpdate:!1}}),(()=>{r&&this.sendUpdate(a,s,i,o)}))}handleDisconnect(){this.setState({error:new Error("Table disconnected"),isDisconnected:!0,isLoading:!1})}handleReconnect(){this.setState({isDisconnected:!1,error:null})}handleSourceFilterChange(){this.applySourceFilters()}handleSourceSortChange(){this.applySourceSorts()}handleSourceSizeChange(e){var{detail:t}=e;this.setState({sourceSize:t})}handleColumnSelected(){nm.debug("handleColumnSelected");var{glEventHub:e}=this.props;e.emit(kl.COLUMN_SELECTED,this,im.SOURCE_COLUMN)}handleClearAllFilters(){this.dropdownFilterRef.current.clearFilter()}setPanelState(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];null!=this.getSource()?(this.setState({skipUpdate:!n}),null===(t=this.dropdownFilterRef.current)||void 0===t||t.setFilterState(e)):nm.debug("Ignore state update for unlinked filter",e)}sendUpdate(e,t,n,i){var a,{glEventHub:s}=this.props,r=null===(a=this.getSource())||void 0===a?void 0:a.panelId,o=null===r?[]:[r];nm.debug("sendUpdate",{name:e,type:t,value:n,timestamp:i,excludePanelIds:o}),s.emit(kl.FILTERS_CHANGED,this,{name:e,type:t,value:null!=n?n:"=null",timestamp:i,excludePanelIds:o})}updateValuesTable(){var e=this.getSource(),t=this.getSourceTable();if(nm.debug("updateValuesTable",e,t),this.setState({values:[],valuesTable:null,error:null}),null==e)return nm.debug("Filter unlinked."),void this.setState({isLoading:!1,isLoaded:!0,isValueShown:!1,sourceSize:0});this.setState({isLoading:!0}),null!=t&&(this.setState({isLoaded:!1,sourceSize:t.size}),this.pending.add(t.copy(),(e=>e.close())).then((e=>{this.updateViewportListener(e),this.setState({valuesTable:e})})).catch((e=>{Va.isCancelled(e)||(nm.error(e),this.setState({isLoading:!1,error:e}))})))}applySourceSorts(){var{valuesTable:e}=this.state,t=this.getSourceTable();if(nm.debug("applySourceSorts",t.sort),null!=e){var n=[...t.sort];e.applySort(n),this.setViewport(e)}else nm.debug("Table not initialized")}applySourceFilters(){var{valuesTable:e}=this.state,t=this.getSourceTable();if(nm.debug("applySourceFilters",t.filter),null!=e){var n=[...t.filter];e.applyFilter(n),this.setViewport(e)}else nm.debug("Table not initialized")}updateViewportListener(e){nm.debug("updateViewportListener",null===e||void 0===e?void 0:e.size),this.cleanup&&this.cleanup(),null!=e?(this.cleanup=e.addEventListener(va.Table.EVENT_UPDATED,this.handleValuesTableUpdate),this.setViewport(e)):this.cleanup=null}setViewport(e){var t=this.getValuesColumn(e);e.setViewport(0,im.MAX_TABLE_SIZE-1,[t])}updateFormatterSettings(e){var t=bs.getColumnFormats(e);oe()(this.columnFormats,t)||(this.columnFormats=t,this.setState({formatter:new Hs(t)}))}handleValuesTableUpdate(e){var{detail:t}=e,{rows:n}=t,{valuesTable:i}=this.state,a=this.getValuesColumn(i);if(a){var s=n.map((e=>e.get(a)));this.setState({values:s,isLoading:!1,isLoaded:!0,valuesColumn:a})}else nm.error("Values column not found")}handleSourceMouseEnter(){var{columnSelectionValidator:e}=this.props;e&&e(this,im.SOURCE_COLUMN)}handleSourceMouseLeave(){var{columnSelectionValidator:e}=this.props;e&&e(this,null)}render(){var{columns:e,disableLinking:t,glContainer:n,glEventHub:i,isLinkerActive:s}=this.props,{column:r,formatter:o,isDisconnected:l,isValueShown:c,value:h,values:d,valuesColumn:u,isLoading:m,isLoaded:p}=this.state,g=this.getSource(),v=this.getSettingsErrorMessage(),f=this.getPanelErrorMessage(),b=p&&null!=u?this.getCachedValues(d,u,o):[];return a.a.createElement(ic,{errorMessage:f,isLoading:m,isLoaded:p,isDisconnected:l,className:"iris-dropdown-filter-panel",componentPanel:this,glContainer:n,glEventHub:i,onClearAllFilters:this.handleClearAllFilters,widgetName:"Dropdown Filter",widgetType:"DropdownFilter"},a.a.createElement("div",{ref:this.panelContainer,className:"dropdown-filter-container h-100 w-100 container"},a.a.createElement(em,{ref:this.dropdownFilterRef,column:r,columns:e,isValueShown:c,isLinkerActive:s,disableLinking:t,isLoaded:p,settingsError:v,source:g,value:h,values:b,onChange:this.handleChange,onColumnSelected:this.handleColumnSelected,onSourceMouseEnter:this.handleSourceMouseEnter,onSourceMouseLeave:this.handleSourceMouseLeave})))}}tm(im,"COMPONENT","DropdownFilterPanel"),tm(im,"MAX_TABLE_SIZE",256),tm(im,"DATETIME_FORMATTER",new Ds({showTimeZone:!1,showTSeparator:!0,defaultDateTimeFormatString:"yyyy-MM-dd HH:mm:ss.SSSSSSSSS"})),tm(im,"SOURCE_COLUMN",Object.freeze({name:"FilterSource",type:null})),im.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({name:pi.a.string,type:pi.a.string,value:pi.a.string,isValueShown:pi.a.bool}),isLinkerActive:pi.a.bool.isRequired,columns:pi.a.arrayOf(pi.a.shape({})).isRequired,columnSelectionValidator:pi.a.func,disableLinking:pi.a.bool.isRequired,settings:pi.a.shape({columnFormats:pi.a.arrayOf(pi.a.shape({}))}).isRequired,panelTableMap:pi.a.instanceOf(Map).isRequired,dashboardLinks:mc.Links.isRequired},im.defaultProps={columnSelectionValidator:null,panelState:null},im.displayName="DropdownFilterPanel";var am=Object(o.b)(((e,t)=>{var{localDashboardId:n}=t,i=di.getIdFromPanel({props:t}),a=Sc(e,n),s=wc(e,n),r=U(e),o=Ec(e,n),l=r===ac.LINKER&&(void 0===o||o===i),c=r===ac.LINKER&&void 0!==o&&o!==i;return{columns:fc(e,n),columnSelectionValidator:yc(e,n),isLinkerActive:l,disableLinking:c,settings:_(e),panelTableMap:a,dashboardLinks:s}}),null,null,{forwardRef:!0})(im),sm=n(714),rm=n(670),om=n(671),lm=n(672),cm=e=>{var{children:t,className:n,style:i}=e;return a.a.createElement("div",{className:qe()("btn-group",n),style:i,role:"group"},t)};cm.displayName="ButtonGroup",cm.propTypes={children:pi.a.node.isRequired,className:pi.a.string,style:pi.a.object},cm.defaultProps={className:null,style:{}};var hm=cm,dm=e=>{var{isOpen:t,headerText:n,bodyText:s,onCancel:r,onConfirm:o,onDiscard:l,onModalDisable:c,cancelButtonText:h="Cancel",confirmButtonText:d="Okay",discardButtonText:u="Discard",children:m}=e,p=Object(i.useRef)(null),g=Object(i.useRef)(null),v=Object(i.useCallback)((()=>{var e;null!==(e=g.current)&&void 0!==e&&e.checked&&c&&c(),o()}),[o,c]),f="";return t&&(f="function"===typeof s?s():s),a.a.createElement(sm.a,{isOpen:t,className:"theme-bg-light",onOpened:()=>{var e;null===(e=p.current)||void 0===e||e.focus()}},a.a.createElement(rm.a,null,n),a.a.createElement(om.a,null,f),a.a.createElement(lm.a,null,c&&a.a.createElement("div",{className:"custom-control custom-checkbox form-group mr-auto"},a.a.createElement("input",{type:"checkbox",className:"custom-control-input",id:"move-confirmation-checkbox",defaultChecked:!1,ref:g}),a.a.createElement("label",{className:"custom-control-label",htmlFor:"move-confirmation-checkbox"},"Don't ask me again")),l&&a.a.createElement("button",{type:"button",className:"btn btn-outline-primary mr-auto","data-dismiss":"modal",onClick:l},u),r&&a.a.createElement("button",{type:"button",className:"btn btn-outline-primary","data-dismiss":"modal",onClick:r},h),a.a.createElement(hm,null,a.a.createElement(gh,{kind:"primary",onClick:v,ref:p},d),m)))};dm.propTypes={isOpen:pi.a.bool.isRequired,headerText:pi.a.string.isRequired,bodyText:pi.a.oneOfType([pi.a.string,pi.a.func]).isRequired,onCancel:pi.a.func,onConfirm:pi.a.func.isRequired,onDiscard:pi.a.func,onModalDisable:pi.a.func,cancelButtonText:pi.a.string,confirmButtonText:pi.a.string,discardButtonText:pi.a.string,children:pi.a.node},dm.defaultProps={children:void 0,cancelButtonText:"Cancel",confirmButtonText:"Okay",discardButtonText:"Discard",onCancel:void 0,onDiscard:void 0,onModalDisable:void 0};var um=dm;function mm(e){return"directory"===e.type}var pm;n(1263);!function(e){e.GROOVY="text/x-groovy",e.PLAIN_TEXT="text/plain",e.PYTHON="text/x-python",e.PYTHON_COMPILED="application/x-python-code",e.SCALA="text/x-scala",e.UNKNOWN=""}(pm||(pm={}));class gm{static fileExtensionToString(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return 0===e.length?"":".".concat(e)}static getDepth(e){var t;if(!gm.hasPath(e))throw new Error("Invalid path provided: ".concat(e));return(null!==(t=e.match(/\//g))&&void 0!==t?t:[]).length-1}static getExtension(e){var t,n=this.getBaseName(e).split(".");return n.length>1&&null!==(t=n.pop())&&void 0!==t?t:""}static getBaseName(e){var t;return null!==(t=e.split("/").pop())&&void 0!==t?t:""}static getCopyFileName(e){var t=e.lastIndexOf("."),n=null,i=null;t<0?i=e:(i=e.substring(0,t),n=e.substring(t+1));var a=i?"".concat(i,"-copy"):"Copy";return null!==n?"".concat(a,".").concat(n):a}static getMimeType(e){switch(this.getExtension(e).toLowerCase()){case"groovy":return pm.GROOVY;case"py":return pm.PYTHON;case"pyc":return pm.PYTHON_COMPILED;case"scala":return pm.SCALA;case"txt":return pm.PLAIN_TEXT;default:return pm.UNKNOWN}}static getParent(e){if(!gm.hasPath(e))throw new Error("Invalid name provided: ".concat(e));for(var t=e.split("/");""===t.pop(););if(0===t.length)throw new Error("No parent for path provided: ".concat(e));return"".concat(t.join("/"),"/")}static getPath(e){if(!gm.hasPath(e))throw new Error("Invalid filename provided: ".concat(e));var t=e.split("/");return t.pop(),"".concat(t.join("/"),"/")}static hasPath(e){return e.startsWith("/")}static isPath(e){return e.startsWith("/")&&e.endsWith("/")}static makePath(e){return e.endsWith("/")?e:"".concat(e,"/")}static replaceExtension(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=e.lastIndexOf("."),i=n>-1?e.substring(0,n):e,a=gm.fileExtensionToString(t);return"".concat(i).concat(a)}static validateName(e){var t,n=/[\\/\0]/g,i=new Map([["\0","null"]]);if(!e)throw new Za("Name cannot be empty");if([".",".."].includes(e))throw new Za('"'.concat(e,'" is a reserved name'));if(n.test(e))throw new Za('Invalid characters in name: "'.concat((null!==(t=e.match(n))&&void 0!==t?t:[]).reduce(((e,t)=>e.includes(t)?e:[...e,t]),[]).map((e=>i.has(e)?i.get(e):e)).join('", "'),'"'))}static reducePaths(e){var t=e.filter((e=>gm.isPath(e)));return e.filter((e=>!t.some((t=>e!==t&&e.startsWith(t)))))}}var vm=gm;function fm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function bm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fm(Object(n),!0).forEach((function(t){Cm(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Cm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Sm=p.module("FileList"),Em=e=>mm(e)?vm.makePath(e.filename):vm.getPath(e.filename),wm=26,ym="item-list-scroll-pane",Tm=e=>{var t,{children:n,draggedItems:i,isDragInProgress:s,isDropTargetValid:r,isSelected:o,item:l,itemIndex:c,dropTargetItem:h,onDragStart:d,onDragOver:u,onDragEnd:m,onDrop:p}=e,g=null!==(t=null===i||void 0===i?void 0:i.some((e=>e.id===l.id)))&&void 0!==t&&t,v=Em(l),f=s&&h?Em(h):null,b=s&&r&&mm(l)&&f===v,C=s&&r&&f===v,S=s&&!r&&f===v,E=function(e){if(mm(e))return e.isExpanded?Ct:St;if(vm.getMimeType(e.basename)===pm.PYTHON)return Tn;return ht}(l),w=vm.getDepth(l.filename),y=Array(w).fill(null).map(((e,t)=>a.a.createElement("span",{className:"file-list-depth-line",key:t})));return a.a.createElement("div",{className:qe()("d-flex w-100 align-items-center","file-list-item",{"is-dragged":g,"is-exact-drop-target":b,"is-in-drop-target":C,"is-invalid-drop-target":S,"is-selected":o}),onDragStart:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((e=>d(c,e))),onDragOver:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((e=>u(c,e))),onDragEnd:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((e=>m(c,e))),onDrop:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((e=>p(c,e))),draggable:!0,role:"presentation"},y," ",a.a.createElement(Ke.a,{icon:E,className:"item-icon",fixedWidth:!0})," ",null!==n&&void 0!==n?n:l.basename)};function Om(e,t){if(0===e.length||!t)throw new Error("No items to move");var n=Em(t);if(e.some((e=>{var{filename:t}=e;return vm.getPath(t)===n})))throw new Error("File already in the destination folder");if(e.some((e=>mm(e)&&n.startsWith(vm.makePath(e.filename)))))throw new Error("Destination folder cannot be a child of a dragged folder");return{files:e,targetPath:n}}var Mm=e=>{var{isMultiSelect:t=!1,table:n,onFocusChange:s=(()=>{}),onMove:r,onSelect:o,onSelectionChange:l=(()=>{}),renderItem:c=Tm,rowHeight:h=wm,overscanCount:d=th.DEFAULT_OVERSCAN}=e,[u,m]=Object(i.useState)((()=>({items:[],offset:0,itemCount:0}))),[p,g]=Object(i.useState)({top:0,bottom:0}),[v,f]=Object(i.useState)(),[b,C]=Object(i.useState)(),[S,E]=Object(i.useState)(),[w,y]=Object(i.useState)([]),T=Object(i.useRef)(null),O=Object(i.useRef)(null),M=Object(i.useCallback)((e=>{if(0===e.length||!u)return[];for(var t=[],n=0;n<e.length;n+=1)for(var i=e[n],a=i[0];a<=i[1];a+=1)a>=u.offset&&a<u.offset+u.items.length&&t.push(u.items[a-u.offset]);return t}),[u]),N=Object(i.useCallback)((e=>{var t=M([[e,e]]);if(t.length>0)return t[0]}),[M]),D=Object(i.useCallback)((()=>{var e=Wa.count(w);if(0===e)return null;if(1===e){var t=w[0][0],n=N(t);if(null!=n)return n.filename}return"".concat(e," items")}),[N,w]),x=Object(i.useCallback)((e=>{if(b&&v){Sm.debug("dropItems",b,"to",e);try{var t,{files:n,targetPath:i}=Om(b,v);if(r(n,i),null!=e)y([[e,e]]),null===(t=T.current)||void 0===t||t.focusItem(e)}catch(a){Sm.error("Unable to complete move",a)}}}),[b,v,r]),R=Object(i.useCallback)(((e,t)=>{var i=u.items[e-u.offset];void 0!==i&&(Sm.debug("handleItemClick",i),o(i,t),mm(i)&&(null===n||void 0===n||n.setExpanded(i.filename,!i.isExpanded)))}),[u,o,n]),I=Object(i.useCallback)(((e,t)=>{var n;Sm.debug2("handleItemDragStart",e,w);var i=w;Wa.isSelected(w,e)||y(i=[[e,e]]),C(M(i)),null===(n=T.current)||void 0===n||n.resetMouseState();var a=document.createElement("div");a.innerHTML='<div class="dnd-placeholder-content">'.concat(D(),"</div>"),a.className="file-list-dnd-placeholder",document.body.appendChild(a),t.dataTransfer.setDragImage(a,0,0),t.dataTransfer.effectAllowed="move",E(a)}),[D,M,w]),L=Object(i.useCallback)(((e,t)=>{t.preventDefault(),Sm.debug2("handleItemDragOver",t),f(N(e))}),[N]),F=Object(i.useCallback)(((e,t)=>{Sm.debug("handleItemDragEnd",e),null===S||void 0===S||S.remove(),C(void 0),f(void 0),E(void 0)}),[S]),k=Object(i.useCallback)(((e,t)=>{x(e)}),[x]),A=Object(i.useCallback)((()=>{Sm.debug2("handleItemDragExit"),f(void 0)}),[]),P=Object(i.useCallback)((e=>{e.target instanceof Element&&e.target.classList.contains(ym)&&(e.preventDefault(),Sm.debug2("handleListDragOver",e),f({type:"directory",filename:"/",basename:"/",id:"/"}))}),[]),_=Object(i.useCallback)((e=>{e.target instanceof Element&&e.target.classList.contains(ym)&&(Sm.debug("handleListDrop"),x())}),[x]),H=Object(i.useCallback)((e=>{if(Sm.debug2("handleSelectionChange",e),e!==w){y(e);var t=M(e);l(t)}}),[M,l,w]),j=Object(i.useCallback)((e=>{if(Sm.debug2("handleFocusChange",e),null!=e){var[t]=M([[e,e]]);s(t)}else s()}),[M,s]),V=Object(i.useCallback)(((e,t)=>{Sm.debug("handleViewportChange",e,t),e===p.top&&t===p.bottom||g({top:e,bottom:t})}),[p]),z=Object(i.useMemo)((()=>{if(!b||!v)return!1;try{return Om(b,v),Sm.debug("handleValidateDropTarget true"),!0}catch(e){return Sm.debug("handleValidateDropTarget false"),!1}}),[b,v]);Object(i.useEffect)((()=>{Sm.debug("updating table viewport",p),null===n||void 0===n||n.setViewport({top:Math.max(0,p.top-d),bottom:p.bottom+d})}),[d,n,p]),Object(i.useEffect)((()=>{var e=n.onUpdate((e=>{m({items:e.items.map((e=>bm(bm({},e),{},{itemName:e.basename}))),offset:e.offset,itemCount:n.size})}));return()=>{e()}}),[n]),Object(i.useEffect)((()=>{if(null!=v&&mm(v)&&"/"!==v.filename){var e=setTimeout((()=>{v.isExpanded||null===n||void 0===n||n.setExpanded(v.filename,!0)}),500);return()=>clearTimeout(e)}}),[v,n]);var U=Object(i.useCallback)((e=>c(bm(bm({},e),{},{isDragInProgress:null!=b,dropTargetItem:v,draggedItems:b,isDropTargetValid:z,onDragStart:I,onDragEnd:F,onDragOver:L,onDragExit:A,onDrop:k}))),[F,A,L,I,k,b,v,z,c]);return a.a.createElement("div",{ref:O,className:qe()("file-list",{"is-dragging":null!=b}),onDragOver:P,onDrop:_},a.a.createElement(th,{ref:T,items:u.items,itemCount:u.itemCount,offset:u.offset,onFocusChange:j,onSelect:R,onSelectionChange:H,onViewportChange:V,selectedRanges:w,renderItem:U,rowHeight:h,isMultiSelect:t,isDragSelect:!1,isDeselectOnClick:!1}))},Nm=(n(665),{FILE_EXPLORER:{name:"File Explorer",DELETE:Be.createAndAdd({id:"FILE_EXPLORER.DELETE",name:"Delete",shortcut:[He.DELETE],macShortcut:[_e.CMD,He.BACKSPACE]}),RENAME:Be.createAndAdd({id:"FILE_EXPLORER.RENAME",name:"Rename",shortcut:[He.ENTER],macShortcut:[He.ENTER]})}}),Dm=(n(1264),p.module("FileListItemEditor")),xm=e=>{var{item:t,onCancel:n,onSubmit:s,validate:r=(()=>Promise.resolve())}=e,o=Object(i.useRef)(null),[l,c]=Object(i.useState)(t.basename),[h,d]=Object(i.useState)(),[u,m]=Object(i.useState)(Promise.resolve()),p=Object(i.useCallback)((()=>{var e;null===(e=o.current)||void 0===e||e.focus()}),[o]),g=Object(i.useCallback)((e=>e.stopPropagation()),[]),v=Object(i.useCallback)((()=>{u.then((()=>{s(l)})).catch((e=>Dm.info("Unable to validate name",e)))}),[s,l,u]);Object(i.useEffect)((()=>{var e=Va.makeCancelable(r(l));return e.then((()=>d(void 0))).catch((e=>{Va.isCanceled(e)||d(e)})),m(e),()=>e.cancel()}),[r,l]),Object(i.useEffect)((()=>{p()}),[p]);var f=Object(i.useCallback)((()=>{Dm.debug2("handleBlur"),v()}),[v]),b=Object(i.useCallback)((e=>{var{value:t}=e.target;c(t)}),[]),C=Object(i.useCallback)((e=>{e.stopPropagation();var{key:t}=e;switch(t){case"Enter":v();break;case"Escape":n()}}),[n,v]);return a.a.createElement("div",{className:"file-list-item-editor"},a.a.createElement("input",{type:"text",className:qe()("form-control file-list-item-editor-input",{"is-invalid":h}),value:l,ref:o,onBlur:f,onKeyDown:C,onChange:b,onClick:g,onDoubleClick:g,onMouseDown:g}),h&&a.a.createElement("div",{className:"invalid-feedback"},"".concat(h)))};function Rm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Im(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rm(Object(n),!0).forEach((function(t){Lm(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Lm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Fm=e=>{var{isMultiSelect:t=!1,showContextMenu:n=!1,onCreateFile:s,onCreateFolder:r,onCopy:o,onDelete:l,onMove:c=(()=>{}),onRename:h,onSelect:d,table:u,rowHeight:m=wm,validateRename:p=(()=>Promise.resolve())}=e,[g,v]=Object(i.useState)(),[f,b]=Object(i.useState)([]),[C,S]=Object(i.useState)(),E=Object(i.useCallback)((e=>{b(e)}),[]),w=Object(i.useCallback)((e=>{S(e)}),[]),y=Object(i.useCallback)((()=>{C&&(null===o||void 0===o||o(C))}),[C,o]),T=Object(i.useCallback)((()=>{f.length>0&&(null===l||void 0===l||l(f))}),[l,f]),O=Object(i.useCallback)((()=>{null===s||void 0===s||s()}),[s]),M=Object(i.useCallback)((()=>{C&&(null===r||void 0===r||r(vm.getPath(C.filename)))}),[C,r]),N=Object(i.useCallback)((()=>{C&&v(C)}),[C]),D=Object(i.useCallback)((()=>{v(void 0)}),[]),x=Object(i.useCallback)((e=>{g&&(null===h||void 0===h||h(g,e),v(void 0))}),[h,g]),R=Object(i.useMemo)((()=>{if(g)return[];var e=[];return s&&e.push({title:"New File",description:"Create new file",action:O,group:vl.groups.medium}),r&&e.push({title:"New Folder",description:"Create new folder",action:M,group:vl.groups.medium}),o&&e.push({title:"Copy",description:"Copy",action:y,group:vl.groups.low,disabled:null==C||mm(C)}),l&&f.length>0&&e.push({title:"Delete",description:"Delete",shortcut:Nm.FILE_EXPLORER.DELETE,action:T,group:vl.groups.low}),h&&e.push({title:"Rename",description:"Rename",shortcut:Nm.FILE_EXPLORER.RENAME,action:N,group:vl.groups.low,disabled:null==C}),e}),[y,T,O,M,N,C,o,s,r,l,h,f,g]),I=Object(i.useCallback)((e=>g?p(g,e):Promise.reject(new Error("No rename item"))),[g,p]),L=Object(i.useCallback)((e=>{var{item:t}=e;return g&&g.filename===t.filename?Tm(Im(Im({},e),{},{children:a.a.createElement(xm,{item:t,validate:I,onSubmit:x,onCancel:D})})):Tm(e)}),[D,x,g,I]);return a.a.createElement("div",{className:"file-list-container"},u&&a.a.createElement(Mm,{onMove:c,onSelect:d,onSelectionChange:E,onFocusChange:w,renderItem:L,rowHeight:m,table:u,isMultiSelect:t}),n&&a.a.createElement(vl,{actions:R}))};Fm.displayName="FileListContainer";var km=Fm;function Am(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Pm=class extends Za{constructor(e){super("Name already exists"),Am(this,"isExistingFile",!0),Am(this,"info",void 0),this.info=e}};class _m extends Error{constructor(){super("No file exists at the path specified"),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"isFileNotFound",!0)}}var Hm=_m;function jm(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function Vm(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){jm(s,i,a,r,o,"next",e)}function o(e){jm(s,i,a,r,o,"throw",e)}r(void 0)}))}}var zm=p.module("FileExplorer"),Um=e=>{var{storage:t,isMultiSelect:n=!1,onDelete:s=(()=>{}),onRename:r=(()=>{}),onSelect:o,rowHeight:l=wm}=e,[c,h]=Object(i.useState)([]),[d,u]=Object(i.useState)();Object(i.useEffect)((()=>{var e;function n(){return(n=Vm((function*(){zm.debug("initTable"),e=Va.makeCancelable(t.getTable(),(e=>e.close()));try{u(yield e)}catch(n){Va.isCanceled(n)||zm.error("Unable to initialize table",n)}}))).apply(this,arguments)}return function(){n.apply(this,arguments)}(),()=>{e.cancel()}}),[t]);var m=Object(i.useCallback)((e=>{Va.isCanceled(e)||zm.error(e)}),[]),p=Object(i.useCallback)((e=>{zm.debug("handleDelete, pending confirmation",e),h(e)}),[]),g=Object(i.useCallback)((()=>{zm.debug("handleDeleteConfirm",c),c.forEach((e=>t.deleteFile(mm(e)?vm.makePath(e.filename):e.filename))),s(c),h([])}),[c,s,t]),v=Object(i.useCallback)((()=>{zm.debug("handleDeleteCancel"),h([])}),[]),f=Object(i.useCallback)(((e,n)=>{vm.reducePaths(e.map((e=>mm(e)?vm.makePath(e.filename):e.filename))).forEach((e=>{var i=vm.isPath(e)?"".concat(n).concat(vm.getBaseName(e.substring(0,e.length-1)),"/"):"".concat(n).concat(vm.getBaseName(e));t.moveFile(e,i).then((()=>{r(e,i)})).catch(m)}))}),[m,r,t]),b=Object(i.useCallback)(((e,n)=>{var i=e.filename,a=mm(e);a&&!i.endsWith("/")&&(i="".concat(i,"/"));var s="".concat(vm.getParent(i)).concat(n);a&&!s.endsWith("/")&&(s="".concat(s,"/")),zm.debug2("handleRename",i,s),t.moveFile(i,s).catch(m),r(i,s)}),[m,r,t]),C=Object(i.useCallback)(function(){var e=Vm((function*(e,n){if(n!==e.basename){vm.validateName(n);var i="".concat(vm.getPath(e.filename)).concat(n);try{var a=yield t.info(i);throw new Pm(a)}catch(s){if(!(s instanceof Hm))throw s}}}));return function(t,n){return e.apply(this,arguments)}}(),[t]),S=c.length>0,E=Object(i.useMemo)((()=>1===c.length?'Are you sure you want to delete "'.concat(c[0].filename,'"?'):"Are you sure you want to delete the selected files?"),[c]);return a.a.createElement("div",{className:"file-explorer"},d&&a.a.createElement(km,{isMultiSelect:n,showContextMenu:!0,onMove:f,onDelete:p,onRename:b,onSelect:o,rowHeight:l,table:d,validateRename:C}),a.a.createElement(um,{isOpen:S,headerText:E,bodyText:"You cannot undo this action.",onCancel:v,onConfirm:g,confirmButtonText:"Delete"}))};Um.displayName="FileExplorer";var Bm=Um;n(1268);function Wm(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function Gm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var qm=p.module("NewItemModal");class Km extends i.PureComponent{static getValidationMessage(e){return e instanceof Pm&&"directory"===e.info.type?"Error: Cannot overwrite existing directory":"".concat(e)}static handleError(e){Va.isCanceled(e)||qm.error(e)}constructor(e){super(e),Gm(this,"inputRef",a.a.createRef()),Gm(this,"cancelableValidatePromise",void 0),Gm(this,"cancelableExistingItemPromise",void 0),Gm(this,"pending",new Ua),Gm(this,"pathMap",new Map),this.handleModalSubmit=this.handleModalSubmit.bind(this),this.handleModalOpened=this.handleModalOpened.bind(this),this.handleSelect=this.handleSelect.bind(this),this.handleChange=this.handleChange.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleValidationError=this.handleValidationError.bind(this),this.handleOverwriteCancel=this.handleOverwriteCancel.bind(this),this.handleOverwriteConfirm=this.handleOverwriteConfirm.bind(this),this.handleExtensionChangeCancel=this.handleExtensionChangeCancel.bind(this),this.handleExtensionChangeConfirm=this.handleExtensionChangeConfirm.bind(this);var{defaultValue:t}=e,n=vm.hasPath(t)?vm.getPath(t):"/";this.state={isSubmitting:!1,path:n,prevExtension:vm.getExtension(t),showExtensionChangeModal:!1,showOverwriteModal:!1,value:vm.getBaseName(t)}}componentDidUpdate(e,t){var{isOpen:n}=this.props,{isOpen:i}=e,{value:a,path:s}=this.state;!i&&n&&this.resetValue(),s===t.path&&a===t.value||this.updateValidationStatus(s,a)}componentWillUnmount(){this.pending.cancel(),this.cancelableValidatePromise&&this.cancelableValidatePromise.cancel(),this.cancelableExistingItemPromise&&this.cancelableExistingItemPromise.cancel()}resetValue(){var{defaultValue:e}=this.props,t=vm.hasPath(e)?vm.getPath(e):"/";this.setState({path:t,value:vm.getBaseName(e),validationError:void 0,prevExtension:vm.getExtension(e),isSubmitting:!1})}getValidationPromise(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return this.cancelableValidatePromise&&this.cancelableValidatePromise.cancel(),this.cancelableValidatePromise=Va.makeCancelable(this.validateName(e,t,n)),this.cancelableValidatePromise}validateName(e,t,n){var i,a=this;return(i=function*(){vm.validateName(t);var{defaultValue:i,storage:s}=a.props;if(n){var r="".concat(e).concat(t);if(r!==i)try{var o=yield s.info(r);throw new Pm(o)}catch(l){if(!(l instanceof Hm))throw l}}return t},function(){var e=this,t=arguments;return new Promise((function(n,a){var s=i.apply(e,t);function r(e){Wm(s,n,a,r,o,"next",e)}function o(e){Wm(s,n,a,r,o,"throw",e)}r(void 0)}))})()}updateValidationStatus(e,t){this.getValidationPromise(e,t).then((()=>{this.setState({validationError:void 0})})).catch(this.handleValidationError).catch(Km.handleError)}handleModalOpened(){this.focusRenameInput()}handleModalSubmit(){this.submitModal()}handleChange(e){var{value:t}=e.target;this.setState({value:t})}handleSelect(e){if(qm.debug("handleSelect",e),"directory"===e.type)this.setState({path:vm.makePath(e.filename)});else{var t=e.basename,n=vm.getPath(e.filename);this.setState({value:t,path:n},(()=>{this.focusRenameInput()}))}}handleKeyDown(e){var{key:t}=e;switch(e.stopPropagation(),t){case"Enter":e.preventDefault(),this.submitModal();break;case"Escape":e.preventDefault();var{onCancel:n}=this.props;n()}}handleValidationError(e){if(!(e instanceof Za))throw e;qm.debug("Validation error",e),this.setState({validationError:e})}handleOverwriteCancel(){this.setState({showOverwriteModal:!1,isSubmitting:!1})}handleOverwriteConfirm(){this.setState({showOverwriteModal:!1});var{onSubmit:e}=this.props,{path:t,value:n}=this.state;qm.debug("handleOverwriteConfirm",t,n),e("".concat(t).concat(n))}handleExtensionChangeCancel(){qm.debug("handleExtensionChangeCancel"),this.setState((e=>{var{value:t,prevExtension:n}=e;return{showExtensionChangeModal:!1,value:vm.replaceExtension(t,n)}})),this.submitModal(!0)}handleExtensionChangeConfirm(){qm.debug("handleExtensionChangeConfirm"),this.setState({showExtensionChangeModal:!1}),this.submitModal(!0)}focusRenameInput(){var e=this.inputRef.current;if(e){var{type:t}=this.props,{value:n}=e,i="directory"===t?n.length:n.lastIndexOf(".");e.focus(),e.setSelectionRange(0,i>0?i:n.length)}}submitModal(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.setState((t=>{var{prevExtension:n,value:i,path:a}=t,{notifyOnExtensionChange:s,type:r}=this.props;qm.debug("submitModal",n,i);var o=vm.getExtension(i);return s&&!e&&null!==n&&n!==o?{isSubmitting:!1,showExtensionChangeModal:!0,newExtension:o}:(this.getValidationPromise(a,i,!0).then((e=>{var{onSubmit:t}=this.props;t("".concat(a).concat(i))})).catch((e=>{if(!(e instanceof Pm&&"directory"!==r&&"directory"!==e.info.type))throw e;this.setState({showOverwriteModal:!0})})).catch((e=>{throw Va.isCanceled(e)&&this.setState({isSubmitting:!1}),e})).catch(this.handleValidationError).catch(Km.handleError),{isSubmitting:!0,showExtensionChangeModal:!1,newExtension:void 0})}))}render(){var{storage:e,isOpen:t,onCancel:n,placeholder:i,title:s,type:r}=this.props,{isSubmitting:o,path:l,showExtensionChangeModal:c,showOverwriteModal:h,validationError:d,value:u,prevExtension:m,newExtension:p}=this.state,g="directory"===r,v=vm.fileExtensionToString(m),f=vm.fileExtensionToString(p),b=g?"Create":"Save",C=g?"New folder name":"Save file as";return a.a.createElement(a.a.Fragment,null,a.a.createElement(sm.a,{isOpen:t,toggle:n,onOpened:this.handleModalOpened,className:"modal-dialog-centered new-file-modal theme-bg-dark"},a.a.createElement(rm.a,{toggle:n},s),a.a.createElement(om.a,null,a.a.createElement("form",null,a.a.createElement("div",{className:"d-flex flex-column new-file-modal-content"},a.a.createElement("div",{className:"flex-grow-0 mb-4"},a.a.createElement("label",{htmlFor:"file-name-input"},C),a.a.createElement("input",{id:"file-name-input",type:"text",autoComplete:"off",autoCapitalize:"none",autoCorrect:"off",spellCheck:"false",className:qe()("form-control",{"is-invalid":d}),value:u,placeholder:i,ref:this.inputRef,onKeyDown:this.handleKeyDown,onChange:this.handleChange}),d&&a.a.createElement("div",{className:"invalid-feedback"},Km.getValidationMessage(d))),a.a.createElement("div",{className:"flex-grow-0"},a.a.createElement("label",null,"Directory: ",a.a.createElement("span",{className:"new-item-parentId"},l))),a.a.createElement("div",{className:"flex-grow-1 file-explorer-container"},a.a.createElement(Bm,{onSelect:this.handleSelect,storage:e}))))),a.a.createElement(lm.a,null,a.a.createElement("button",{className:"btn btn-outline-primary",onClick:n,type:"button"},"Cancel"),a.a.createElement("button",{className:"btn btn-primary",disabled:o,onClick:this.handleModalSubmit,type:"button"},b))),a.a.createElement(um,{isOpen:h,headerText:"Confirm overwrite",bodyText:"File with this name already exists, are you sure you want to overwrite it?",onCancel:this.handleOverwriteCancel,onConfirm:this.handleOverwriteConfirm,cancelButtonText:"Cancel",confirmButtonText:"Overwrite"}),a.a.createElement(um,{isOpen:c,headerText:"Confirm extension change",bodyText:'Are you sure you want to change extension from "'.concat(v,'" to "').concat(f,'"?'),onCancel:this.handleExtensionChangeCancel,onConfirm:this.handleExtensionChangeConfirm,cancelButtonText:'Keep "'.concat(v,'"'),confirmButtonText:'Use "'.concat(f,'"')}))}}Gm(Km,"propTypes",{isOpen:pi.a.bool,title:pi.a.string.isRequired,defaultValue:pi.a.string,type:pi.a.oneOf(["file","directory"]).isRequired,onSubmit:pi.a.func,onCancel:pi.a.func,placeholder:pi.a.string,storage:pi.a.shape({}).isRequired,notifyOnExtensionChange:pi.a.bool}),Gm(Km,"defaultProps",{isOpen:!1,defaultValue:"/",notifyOnExtensionChange:!1,placeholder:"",onSubmit:e=>{},onCancel:()=>{}});var Ym=Km;function Xm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Zm extends i.PureComponent{constructor(e){super(e),Xm(this,"searchInput",void 0),this.searchInput=a.a.createRef(),this.handleChange=this.handleChange.bind(this),this.sendUpdate=pa()(this.sendUpdate.bind(this),e.debounceMs),this.state={value:e.value}}componentDidUpdate(e){var{value:t}=this.props;e.value!==t&&this.setState({value:t})}focus(){var e;null===(e=this.searchInput.current)||void 0===e||e.focus()}handleChange(e){this.setState({value:e.target.value},this.sendUpdate)}sendUpdate(){var{onChange:e}=this.props,{value:t}=this.state;e(t)}render(){var{placeholder:e,className:t,matchCount:n,id:i}=this.props,{value:s}=this.state;return a.a.createElement(Gc,{value:s,placeholder:e,onChange:this.handleChange,className:t,matchCount:n,ref:this.searchInput,id:i})}}Xm(Zm,"defaultProps",{placeholder:"Search",className:"",matchCount:null,debounceMs:250,id:""});var $m=Zm,Qm=(n(1269),e=>{var{createFile:t,createFolder:n,onSearchChange:i,defaultSearchText:s=""}=e;return a.a.createElement("div",{className:"file-explorer-toolbar"},a.a.createElement("div",{className:"file-explorer-toolbar-buttons"},a.a.createElement(gh,{kind:"ghost",icon:Ft,tooltip:"New notebook",onClick:t}),a.a.createElement(gh,{kind:"ghost",icon:kt,tooltip:"New folder",onClick:n})),i&&a.a.createElement("div",{className:"file-explorer-toolbar-search"},a.a.createElement($m,{value:s,onChange:i,placeholder:"Search by name"})))});function Jm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function ep(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jm(Object(n),!0).forEach((function(t){ip(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function tp(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function np(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){tp(s,i,a,r,o,"next",e)}function o(e){tp(s,i,a,r,o,"throw",e)}r(void 0)}))}}function ip(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ap=p.module("WebdavFileStorageTable");class sp{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/";ip(this,"client",void 0),ip(this,"root",void 0),ip(this,"currentSize",0),ip(this,"currentViewport",void 0),ip(this,"listeners",[]),ip(this,"viewportUpdatePromise",void 0),ip(this,"currentViewportData",void 0),ip(this,"childTables",new Map),this.client=e,this.root=t}getViewportData(){var e;return this.viewportUpdatePromise||this.refreshInternal(),null!==(e=this.viewportUpdatePromise)&&void 0!==e?e:Promise.resolve({items:[],offset:0})}getSnapshot(e){throw new Error("Method not implemented.")}get size(){return this.currentSize}setExpanded(e,t){var n=this;return np((function*(){var i=e.split("/"),a=i.shift();if(a||(a=i.shift()),!a)throw new Error("Invalid path: ".concat(e));var s=i.join("/");if(t){if(!n.childTables.has(a)){var r=new sp(n.client,"".concat(n.root).concat(a,"/"));n.childTables.set(a,r)}if(s){var o=n.childTables.get(a);null===o||void 0===o||o.setExpanded(s,t)}}else if(n.childTables.has(a))if(s){var l=n.childTables.get(a);null===l||void 0===l||l.setExpanded(s,t)}else n.childTables.delete(a);n.currentViewport&&(yield n.refreshInternal())}))()}setSearch(e){throw new Error("Method not implemented.")}setViewport(e){this.currentViewport=e,this.refreshInternal()}setFilters(){throw new Error("Method not implemented.")}setSorts(){throw new Error("Method not implemented.")}setReversed(){throw new Error("Method not implemented.")}close(){this.listeners=[]}onUpdate(e){return this.listeners=[...this.listeners,e],()=>{this.listeners=this.listeners.filter((t=>t!==e))}}refresh(){var e=this;return np((function*(){var t;ap.debug2(e.root,"refreshData"),null===(t=e.viewportUpdatePromise)||void 0===t||t.cancel(),e.viewportUpdatePromise=Va.makeCancelable(e.fetchData());var n=yield e.viewportUpdatePromise;return e.currentViewportData=n,e.sendUpdate(),n}))()}refreshInternal(){var e=this;return np((function*(){try{yield e.refresh()}catch(t){Va.isCanceled(t)||ap.error("Unable to refresh data",t)}}))()}fetchData(){var e=this;return np((function*(){var{currentViewport:t}=e;if(!t)throw new Error("No viewport set");for(var n=yield e.client.getDirectoryContents(e.root).then((t=>t.map((t=>ep(ep({},t),{},{id:t.filename,isExpanded:"directory"===t.type?e.childTables.has(t.basename):void 0}))).sort(((e,t)=>e.type!==t.type?"directory"===e.type?-1:1:e.basename.localeCompare(t.basename))))),i=0;i<n.length;i+=1){var a=n[i],{basename:s,filename:r}=a;if(r==="".concat(e.root).concat(s)&&"directory"===a.type){var o=e.childTables.get(s);if(null!=o){o.setViewport({top:0,bottom:t.bottom-i});var l=yield o.getViewportData();n.splice(i+1,0,...l.items)}}}return e.currentSize=n.length,ap.debug2(e.root,"items",n,t),{items:n=n.slice(t.top,t.bottom),offset:t.top}}))()}sendUpdate(){for(var e,{listeners:t}=this,n=null!==(e=this.currentViewportData)&&void 0!==e?e:{items:[],offset:0},i=0;i<t.length;i+=1)t[i](n)}}var rp=sp;function op(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function lp(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){op(s,i,a,r,o,"next",e)}function o(e){op(s,i,a,r,o,"throw",e)}r(void 0)}))}}function cp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class hp{constructor(e){cp(this,"client",void 0),cp(this,"tables",[]),cp(this,"refreshTables",$n()((()=>{this.tables.every((e=>e.refresh().catch((()=>{}))))}),hp.REFRESH_THROTTLE)),this.client=e}createDirectory(e){var t=this;return lp((function*(){return yield t.client.createDirectory(e),t.refreshTables(),{type:"directory",id:e,filename:e,basename:vm.getBaseName(e)}}))()}getTable(){var e=this;return lp((function*(){var t=new rp(e.client);return e.tables.push(t),t}))()}saveFile(e){var t=this;return lp((function*(){if(!(yield t.client.putFileContents(e.filename,e.content)))throw new Error("Unable to write file");return t.refreshTables(),e}))()}loadFile(e){var t=this;return lp((function*(){var n=yield t.client.getFileContents(e,{format:"text"});return{filename:e,basename:vm.getBaseName(e),content:n}}))()}deleteFile(e){var t=this;return lp((function*(){yield t.client.deleteFile(e),t.refreshTables()}))()}moveFile(e,t){var n=this;return lp((function*(){yield n.client.moveFile(e,t),n.refreshTables()}))()}info(e){var t=this;return lp((function*(){try{var n=yield t.client.stat(e);return{filename:n.filename,basename:n.basename,id:n.filename,type:n.type}}catch(i){throw new Hm}}))()}}cp(hp,"REFRESH_THROTTLE",150);var dp=hp,up=Bm;n(1270);function mp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var pp=p.module("FileExplorerPanel"),gp=Object(o.b)(((e,t)=>{var n=A(e),i=Tc(e,t.localDashboardId),{session:a,config:s}=null!==i&&void 0!==i?i:{};return{fileStorage:n,language:null===s||void 0===s?void 0:s.type,session:a}}),null,null,{forwardRef:!0});class vp extends a.a.Component{static handleError(e){pp.error(e)}static isFocusEvent(e){return!(t=e)||"number"!==typeof t.button||e.detail>=2;var t}constructor(e){super(e),this.handleFileSelect=this.handleFileSelect.bind(this),this.handleCreateFile=this.handleCreateFile.bind(this),this.handleCreateDirectory=this.handleCreateDirectory.bind(this),this.handleCreateDirectoryCancel=this.handleCreateDirectoryCancel.bind(this),this.handleCreateDirectorySubmit=this.handleCreateDirectorySubmit.bind(this),this.handleDelete=this.handleDelete.bind(this),this.handleRename=this.handleRename.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.handleShow=this.handleShow.bind(this);var{session:t,language:n}=e;this.state={isShown:!1,language:n,session:t,showCreateFolder:!1}}componentDidMount(){this.isHidden()||this.setState({isShown:!0})}handleCreateFile(){var{glEventHub:e}=this.props,{session:t,language:n}=this.state,i={language:n,value:""};pp.debug("handleCreateFile",t,n,i),e.emit(zl.CREATE_NOTEBOOK,t,n,i)}handleCreateDirectory(e){this.setState({showCreateFolder:!0})}handleCreateDirectoryCancel(){pp.debug("handleCreateDirectoryCancel"),this.setState({showCreateFolder:!1})}handleCreateDirectorySubmit(e){pp.debug("handleCreateDirectorySubmit",e),this.setState({showCreateFolder:!1});var{fileStorage:t}=this.props;t.createDirectory(e).catch(vp.handleError)}handleDelete(e){var{glEventHub:t}=this.props;e.forEach((e=>{t.emit(zl.CLOSE_FILE,{id:e.filename,itemName:e.filename})}))}handleFileSelect(e,t){if(pp.debug("fileSelect",e),"directory"!==e.type){var n=vp.isFocusEvent(t),i={id:e.filename,itemName:e.filename},{glEventHub:a}=this.props,{session:s,language:r}=this.state,o={value:null,language:r};a.emit(zl.SELECT_NOTEBOOK,s,r,o,i,n)}}handleRename(e,t){var{glEventHub:n}=this.props;pp.debug("handleRename",e,t),n.emit(zl.RENAME_FILE,e,t)}handleSessionOpened(e,t){var{language:n}=t;this.setState({session:e,language:n})}handleSessionClosed(){this.setState({session:void 0,language:void 0})}handleShow(){this.setState({isShown:!0})}isHidden(){var{glContainer:e}=this.props,{isHidden:t}=e;return t}render(){var{fileStorage:e,glContainer:t,glEventHub:n}=this.props,{isShown:i,showCreateFolder:s}=this.state;return a.a.createElement(Jl,{className:"file-explorer-panel",componentPanel:this,glContainer:t,glEventHub:n,onSessionOpen:this.handleSessionOpened,onSessionClose:this.handleSessionClosed,onShow:this.handleShow},a.a.createElement(Qm,{createFile:this.handleCreateFile,createFolder:this.handleCreateDirectory}),i&&a.a.createElement(up,{isMultiSelect:!0,storage:e,onDelete:this.handleDelete,onRename:this.handleRename,onSelect:this.handleFileSelect}),a.a.createElement(Ym,{isOpen:s,type:"directory",title:"Create New Folder",storage:e,onSubmit:this.handleCreateDirectorySubmit,onCancel:this.handleCreateDirectoryCancel}))}}mp(vp,"COMPONENT","FileExplorerPanel"),mp(vp,"TITLE","File Explorer");var fp=gp(vp);n(1271);function bp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Cp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bp(Object(n),!0).forEach((function(t){Sp(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Sp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ep=p.module("FilterSetManager"),wp="No Available Filter Sets";class yp extends i.Component{static animateScreenFlash(){var e,t=document.createElement("div");t.classList.add("screen-flash-overlay"),t.addEventListener("animationend",(()=>{t.remove()})),null===(e=document.querySelector("body"))||void 0===e||e.appendChild(t)}constructor(e){super(e),Sp(this,"renameInputRef",a.a.createRef()),Sp(this,"dropdownRef",a.a.createRef()),Sp(this,"editDropdownRef",a.a.createRef()),Sp(this,"isRenamingExistingSet",Object(ua.a)(((e,t)=>void 0!==t&&e.some((e=>{var{id:n}=e;return n===t.id}))))),this.handleSettingsCancel=this.handleSettingsCancel.bind(this),this.handleSettingsClick=this.handleSettingsClick.bind(this),this.handleSettingsSave=this.handleSettingsSave.bind(this),this.handleBackgroundClick=this.handleBackgroundClick.bind(this),this.handleEditDropdownChange=this.handleEditDropdownChange.bind(this),this.handleFilterChange=this.handleFilterChange.bind(this),this.handleFilterApply=this.handleFilterApply.bind(this),this.handleCaptureNewSet=this.handleCaptureNewSet.bind(this),this.handleNameInputChange=this.handleNameInputChange.bind(this),this.handleNameInputKeyPress=this.handleNameInputKeyPress.bind(this),this.handleRenameConfirm=this.handleRenameConfirm.bind(this),this.handleRenameCancel=this.handleRenameCancel.bind(this),this.handleSetDelete=this.handleSetDelete.bind(this),this.handleSetRename=this.handleSetRename.bind(this),this.handleSetUpdate=this.handleSetUpdate.bind(this),this.state={editId:void 0,renameSet:void 0,nameInputValue:"",nameInputError:void 0,modifiedFilterSets:[]}}componentDidMount(){var{isValueShown:e}=this.props;e?this.updateSelectedId():this.initSettingsScreen()}componentDidUpdate(e,t){var{isValueShown:n,filterSets:i}=this.props,{modifiedFilterSets:a}=this.state;if(e.isValueShown&&!n&&this.initSettingsScreen(),this.isNameInputScreen()&&!this.isNameInputScreen(t)&&this.focusRenameInput(),i!==e.filterSets)if(!n&&i.length>0&&0===e.filterSets.length&&0===a.length){var{onChange:s}=this.props;s({isValueShown:!0,selectedId:i[0].id})}else this.updateSelectedId()}initSettingsScreen(){var{filterSets:e,selectedId:t}=this.props;Ep.debug("initSettingsScreen",e,t),this.setState({modifiedFilterSets:[...e],editId:t})}updateSelectedId(){var{isValueShown:e,filterSets:t,selectedId:n,onChange:i}=this.props;if(Ep.debug("updateSelectedId",t,n),e&&!t.some((e=>{var{id:t}=e;return t===n}))){var a=0===t.length;i({isValueShown:!a,selectedId:a?void 0:t[0].id})}}handleEditDropdownChange(e){var{value:t}=e.target;this.setState({editId:t})}handleFilterChange(e){var{value:t}=e.target,{isValueShown:n,onChange:i}=this.props;this.applyFilterSet(t),i({isValueShown:n,selectedId:t})}handleFilterApply(){var{selectedId:e}=this.props;this.applyFilterSet(e)}handleSettingsCancel(){var{onChange:e,selectedId:t,filterSets:n}=this.props;this.setState({modifiedFilterSets:[]}),n.length>0&&e({isValueShown:!0,selectedId:t})}handleSettingsSave(){var{onChange:e,onUpdateSets:t,selectedId:n}=this.props,{modifiedFilterSets:i,editId:a}=this.state;this.setState({modifiedFilterSets:[]}),Ep.debug("Update sets",i,a),t(i,a),i.length>0&&e({isValueShown:!0,selectedId:n})}handleCaptureNewSet(){var{getFilterState:e}=this.props;yp.animateScreenFlash();var t={id:ni()(),title:"",panels:e()};Ep.debug("handleSetCreate",t),this.setState({nameInputValue:"",nameInputError:void 0,renameSet:t})}handleRenameCancel(){this.setState({renameSet:void 0})}getNameError(e){var t,{renameSet:n,modifiedFilterSets:i}=this.state,a=null!==(t=null===e||void 0===e?void 0:e.trim())&&void 0!==t?t:"";return 0===a.length?(Ep.debug("Name cannot be empty",a),"Name cannot be empty"):void 0!==n&&i.some((e=>{var{title:t,id:i}=e;return t===a&&i!==n.id}))?(Ep.debug("Set with this name already exists",a),"Set with this name already exists"):void 0}handleRenameConfirm(){var e,{nameInputValue:t,renameSet:n,modifiedFilterSets:i}=this.state;if(void 0!==n){var a=this.getNameError(t);if(Ep.debug("handleRenameConfirm",t,a),void 0===a){var s=null!==(e=null===t||void 0===t?void 0:t.trim())&&void 0!==e?e:"",r=Cp(Cp({},n),{},{title:s}),o=i.findIndex((e=>{var{id:t}=e;return t===n.id})),l=[...i];o>=0?(l[o]=r,Ep.debug("Renamed existing set",l)):(l.push(r),Ep.debug("Added new set to modified sets",l)),this.setState({editId:r.id,modifiedFilterSets:l,renameSet:void 0})}else this.setState({nameInputError:a})}else Ep.error("Renamed set undefined.")}handleSetDelete(){this.setState((e=>{var{editId:t,modifiedFilterSets:n}=e,i=n.findIndex((e=>{var{id:n}=e;return n===t}));if(i<0)return Ep.error("Unable to find selected filterSet index",n,t),null;var a=n.filter((e=>{var{id:n}=e;return n!==t})),s=Math.max(0,Math.min(a.length-1,i-1)),r=a.length>0?a[s].id:void 0;return Ep.debug("Deleted selected set",t,n,a),Ep.debug("New selection",s,r),{modifiedFilterSets:a,editId:r}}))}handleSetUpdate(){var{getFilterState:e}=this.props;yp.animateScreenFlash();var t=e();this.setState((e=>{var{modifiedFilterSets:n,editId:i}=e;if(void 0===i)return Ep.error("Filter for update not selected."),null;var a=[...n],s=a.findIndex((e=>{var{id:t}=e;return t===i}));return s<0?(Ep.error("Selected set for update not found."),null):(a[s]=Cp(Cp({},a[s]),{},{panels:t}),Ep.debug("Update set",a,t),{modifiedFilterSets:a})}))}handleSetRename(){this.setState((e=>{var{editId:t,modifiedFilterSets:n}=e,i=n.find((e=>{var{id:n}=e;return n===t}));if(void 0===i)return Ep.error("Could not find selected set",t,n),null;var{title:a}=i;return{nameInputValue:a,nameInputError:void 0,renameSet:i}}))}handleSettingsClick(e){e.stopPropagation();var{onChange:t,selectedId:n}=this.props;t({isValueShown:!1,selectedId:n})}handleBackgroundClick(e){Ep.debug("handleBackgroundClick"),e.target!==this.dropdownRef.current&&this.focusInput()}handleNameInputChange(e){var{value:t}=e.target,n=this.getNameError(t);this.setState({nameInputValue:t,nameInputError:n})}handleNameInputKeyPress(e){var{key:t}=e;"Enter"===t&&(e.preventDefault(),this.handleRenameConfirm())}isNameInputScreen(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.state,{renameSet:t}=e;return void 0!==t}applyFilterSet(e){var{onApply:t,filterSets:n}=this.props;if(void 0!==e){var i=n.find((t=>{var{id:n}=t;return n===e}));void 0!==i?(Ep.debug("Apply filterSet",i),t(i)):Ep.debug("Selected id not found in filterSets",e,n)}else Ep.debug("No filter selected")}focusInput(){var e;null===(e=this.dropdownRef.current)||void 0===e||e.focus()}focusRenameInput(){var e;null===(e=this.renameInputRef.current)||void 0===e||e.focus()}render(){var{nameInputValue:e,nameInputError:t,editId:n,renameSet:i,modifiedFilterSets:s}=this.state,{isValueShown:r,filterSets:o,selectedId:l}=this.props,c=this.isNameInputScreen(),h=this.isRenamingExistingSet(s,i),d=0===s.length,u=!c&&d&&0===o.length,m=!c&&!u,p=a.a.createElement("div",{className:"fa-layers mr-3"},a.a.createElement(Ke.a,{icon:at,mask:ut,transform:"shrink-1 down-5 right-7"}),a.a.createElement(Ke.a,{icon:wn,className:"text-primary",transform:"shrink-6 down-5 right-7"})),g=a.a.createElement("div",{className:"fa-layers"},a.a.createElement(Ke.a,{icon:at,mask:ut,transform:"shrink-1 down-5 right-7"}),a.a.createElement(Ke.a,{icon:Ze,transform:"shrink-1 down-5 right-7"}));return a.a.createElement("div",{className:"filter-set-manager fill-parent-absolute"},a.a.createElement(Zu,{className:"w-100 h-100",isFlipped:r},a.a.createElement("div",{className:"filter-set-manager-settings-card fill-parent-absolute",key:"front"},a.a.createElement("div",{className:"filter-set-manager-card-content"},u&&a.a.createElement("div",null,a.a.createElement(gh,{kind:"ghost",className:"btn btn-link no-underline",onClick:this.handleCaptureNewSet,icon:p},"Capture filter set"),a.a.createElement("div",{className:"py-3 text-muted small"},"Takes a snapshot of the currently applied filters on all panels, allowing you to restore saved filter sets later.")),c&&a.a.createElement("div",{className:"d-flex flex-column justify-content-center"},a.a.createElement("div",{className:"form-group"},a.a.createElement("label",null,h?"Rename set":"Name captured set"),a.a.createElement("div",{className:"name-input-container"},a.a.createElement("input",{type:"text",className:"input-set-name form-control",placeholder:"Enter name...",value:e,ref:this.renameInputRef,onChange:this.handleNameInputChange,onKeyPress:this.handleNameInputKeyPress,spellCheck:"false"}),a.a.createElement(gh,{kind:"ghost",className:"btn btn-link no-underline pt-2 pb-2",onClick:this.handleRenameConfirm,tooltip:"Save",icon:Gt}),a.a.createElement(gh,{kind:"ghost",className:"btn btn-link no-underline pt-2 pb-2",onClick:this.handleRenameCancel,tooltip:"Cancel",icon:rt})),t&&a.a.createElement("div",{className:"error-message"},t))),m&&a.a.createElement("div",{className:"filter-set-manager-settings-grid-1"},a.a.createElement("div",{className:"form-group"},a.a.createElement("label",null,"Edit filter sets"),a.a.createElement("div",{className:"filter-select-container"},a.a.createElement("select",{ref:this.editDropdownRef,value:null!==n&&void 0!==n?n:"-1",className:"custom-select filter-value-select",onChange:this.handleEditDropdownChange,disabled:d},d&&a.a.createElement("option",{value:"-1",disabled:!0},wp),s.map((e=>{var{id:t,title:n}=e;return a.a.createElement("option",{key:t,value:t},n)}))),a.a.createElement(gh,{kind:"ghost",onClick:this.handleSetUpdate,disabled:d,icon:g,tooltip:"Update"}),a.a.createElement(gh,{kind:"ghost",onClick:this.handleSetRename,disabled:d,icon:Sn,tooltip:"Rename"}),a.a.createElement(gh,{kind:"ghost",onClick:this.handleSetDelete,disabled:d,icon:$t,tooltip:"Delete"}))),a.a.createElement("div",null,a.a.createElement(gh,{kind:"ghost",className:"btn btn-link no-underline",onClick:this.handleCaptureNewSet,icon:p},"Capture new filter set")),a.a.createElement("div",{className:"py-3 text-right"},a.a.createElement(gh,{kind:"secondary",onClick:this.handleSettingsCancel},"Cancel"),"\xa0",a.a.createElement(gh,{kind:"primary",onClick:this.handleSettingsSave},"Save"))))),a.a.createElement("div",{className:"filter-set-manager-value-card fill-parent-absolute",key:"back",onClick:this.handleBackgroundClick},a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"filter-set-manager-column"},a.a.createElement("div",{className:"filter-set-manager-column-title"},"Filter sets")),a.a.createElement("div",{className:"filter-set-manager-card-content"},a.a.createElement("div",{className:"filter-set-manager-value-input"},a.a.createElement("div",{className:"filter-select-container"},a.a.createElement("select",{ref:this.dropdownRef,value:l,className:"custom-select filter-value-select",onChange:this.handleFilterChange},0===o.length&&a.a.createElement("option",{value:"-1",disabled:!0},wp),o.map((e=>{var{id:t,title:n}=e;return a.a.createElement("option",{key:t,value:t},n)}))),a.a.createElement(gh,{kind:"ghost",onClick:this.handleFilterApply,icon:On,tooltip:"Apply Filter Set"})))),a.a.createElement("div",{className:"filter-set-manager-menu"},a.a.createElement(gh,{kind:"ghost",className:"btn btn-link btn-link-icon m-2 px-2",onClick:this.handleSettingsClick,tooltip:"Settings",icon:a.a.createElement(Ke.a,{icon:Et,transform:"grow-4"})}))))))}}var Tp=yp,Op=(n(1283),e=>{var{className:t="",show:n=!0}=e;return a.a.createElement("div",{className:qe()("dh-loader",t,{show:n})},a.a.createElement("svg",{className:"dh-outer-shape",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("path",{d:"M82.7429,0L82.7429,41.3714L45.2571,41.3714L45.2571,0L0,0L0,128L45.2571,128L45.2571,86.6286L82.5143,86.6286L82.5143,128L128,128L128,0L82.7429,0ZM41.3714,124.114L4.11429,124.114L4.11429,86.6286L41.3714,86.6286L41.3714,124.114ZM41.3714,82.7429L4.11429,82.7429L4.11429,45.2571L41.3714,45.2571L41.3714,82.7429ZM41.3714,41.3714L4.11429,41.3714L4.11429,4.11429L41.3714,4.11429L41.3714,41.3714ZM45.2571,82.7429L45.2571,45.2571L82.5143,45.2571L82.5143,82.5143L45.2571,82.5143ZM124.114,124.114L86.6286,124.114L86.6286,86.6286L123.886,86.6286L123.886,124.114ZM124.114,82.7429L86.6286,82.7429L86.6286,45.2571L123.886,45.2571L123.886,82.7429ZM86.6286,41.3714L86.6286,4.11429L123.886,4.11429L123.886,41.3714L86.6286,41.3714Z",fill:"#f0f0ee"}))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-3",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.3438",height:"37.6389",fill:"#5189e5",transform:"translate(-21.9838,29.7957) translate(21.9838,15.3027)"})))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-2",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.2755",height:"37.4675",fill:"#5189e5",transform:"translate(-21.9838,69.7957) translate(22.0822,16.7783)"})))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-5",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.3512",height:"41.3781",fill:"#35618c",transform:"translate(18.0162,72.7957) translate(23.1643,13.7278)"})))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-6",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.2483",height:"37.5869",fill:"#35618c",transform:"translate(59.0162,29.7957) translate(23.6379,15.3564)"})))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-7",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.5664",height:"41.2747",fill:"#35618c",transform:"translate(17.0162,-13.2043) translate(24.2531,13.2043)"})))),a.a.createElement("svg",{className:"dh-loader-tile dh-loader-tile-4",viewBox:"0 0 182 182"},a.a.createElement("g",{transform:"translate(91,91.0033) translate(-64,-64.0033)"},a.a.createElement("g",{transform:"translate(63.9589,64.0492) translate(-59.9751,-63.9508)"},a.a.createElement("rect",{width:"37.2854",height:"37.3014",fill:"#5189e5",transform:"translate(-21.9838,-13.2043) translate(22.0822,17.1792)"})))))}),Mp=(n(1300),e=>{var{children:t}=e,n=Object(i.useMemo)((()=>a.a.Children.toArray(t)),[t]),s=gi(n),[r,o]=Object(i.useState)(n[n.length-1]),[l,c]=Object(i.useState)(null),[h,d]=Object(i.useState)(null);Object(i.useEffect)((()=>{if(void 0!==s&&n!==s){var e=n[n.length-1];n.length===s.length||0===s.length||null!==l||null!==h?null!==l&&e!==l?c(e):e!==h&&e!==r&&o(e):n.length>s.length?c(e):n.length<s.length&&(o(e),d(s[s.length-1]))}}),[n,s,l,h,r]);var u=Object(i.useCallback)((()=>{o(l),c(null)}),[l]),m=Object(i.useCallback)((()=>{d(null)}),[]);return a.a.createElement("div",{className:"navigation-stack"},a.a.createElement("div",{className:"main-view"},r),a.a.createElement(We.CSSTransition,{in:null!=h,timeout:Kn.transitionMidMs,classNames:"slide-right",onEntered:m},a.a.createElement(a.a.Fragment,null,h&&a.a.createElement("div",{className:"popping-view"},h))),a.a.createElement(We.CSSTransition,{in:null!=l,timeout:Kn.transitionMidMs,classNames:"slide-left",onEntered:u},a.a.createElement(a.a.Fragment,null,l&&a.a.createElement("div",{className:"pushing-view"},l))))}),Np=(n(1301),e=>{var{children:t,onBack:n,onClose:i,title:s}=e;return a.a.createElement("div",{className:"navigation-page"},a.a.createElement("div",{className:"navigation-title-bar"},a.a.createElement("div",{className:"navigation-left-buttons"},void 0!==n&&a.a.createElement("button",{className:"btn btn-link btn-back",type:"button",onClick:n},a.a.createElement(Ke.a,{icon:tt}),"Back")),a.a.createElement("div",{className:"navigation-title"},s),a.a.createElement("div",{className:"navigation-right-buttons"},void 0!==i&&a.a.createElement("button",{className:"btn btn-link btn-link-icon btn-close px-2 m-1",type:"button",onClick:i},a.a.createElement(Ke.a,{icon:lt})))),a.a.createElement("div",{className:"navigation-content"},t))}),Dp=(n(1294),n(1295),e=>{var{on:t,id:n,className:i,isInvalid:s,disabled:r=!1,onClick:o}=e;return a.a.createElement("button",{type:"button",className:qe()("btn","btn-switch",i,{active:t},{"is-invalid":s}),id:n,onClick:o,disabled:r},a.a.createElement("div",{className:"handle"}))});function xp(e){return void 0!==e.isOn}var Rp=e=>{var{item:t,onSelect:n=(()=>{})}=e,{icon:s,subtitle:r,title:o}=t,l=Object(i.useMemo)((()=>xp(t)?()=>{t.onChange(!t.isOn)}:n),[t,n]);return a.a.createElement("div",{className:"btn btn-navigation-menu-item",onClick:l,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||l()},tabIndex:0,role:"menuitem"},s&&a.a.createElement("div",{className:"icon"},a.a.createElement(Ke.a,{icon:s})),a.a.createElement("div",{className:"title"},o),r&&a.a.createElement("div",{className:"shortcut"},r),a.a.createElement("div",{className:"accessory"},xp(t)&&a.a.createElement(Dp,{on:t.isOn,onClick:e=>{e.stopPropagation(),l()}})||a.a.createElement(Ke.a,{icon:nt})))},Ip=(n(1293),e=>{var{items:t,onSelect:n=(()=>{})}=e;return a.a.createElement("div",{className:"navigation-menu-view"},a.a.createElement("ul",{className:"navigation-menu-list"},t.map(((e,t)=>a.a.createElement("li",{key:e.title},a.a.createElement(Rp,{item:e,onSelect:()=>{n(t)}}))))))}),Lp=(n(1298),e=>{var{animation:t="iris-grid-bottom-bar-slide-up",children:n,className:i,isShown:s,onClick:r,onEntering:o,onEntered:l,onExiting:c,onExited:h}=e;return a.a.createElement(We.CSSTransition,{in:s,timeout:Kn.transitionMs,classNames:t,onEntering:o,onEntered:l,onExiting:c,onExited:h,mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:qe()("iris-grid-bottom-bar",i),role:"presentation",onClick:r,onKeyPress:r},n))}),Fp=(n(673),e=>{var{isSaving:t=!1,onSave:n,onDiscard:s,discardTooltip:r,saveTooltip:o,error:l,pendingDataErrors:c,pendingDataMap:h,onEntering:d,onEntered:u,onExiting:m,onExited:p}=e,[g,v]=Object(i.useState)(!1),[f,b]=Object(i.useState)(!1),C=Object(i.useRef)(),S=gi(t),E=Object(i.useMemo)((()=>0===c.size?l:c.size<=5?"Key can't be empty (on pending row".concat(c.size>1?"s":""," ").concat(Array.from(c.keys()).join(", ").trim(),")"):"Key can't be empty (on ".concat(c.size," rows)")),[l,c]);Object(i.useEffect)((()=>{S&&!t&&null==E&&(v(!0),b(!0),C.current=setTimeout((()=>{v(!1)}),3e3))}),[E,t,S]),Object(i.useEffect)((()=>{C.current&&h.size>0&&(clearTimeout(C.current),v(!1),b(!1))}),[h]),Object(i.useEffect)((()=>()=>C.current?clearTimeout(C.current):void 0),[]);var w,y=h.size;return t?w=a.a.createElement(Yn,null):f&&(w=Pt),a.a.createElement(Lp,{className:"pending-data-bottom-bar",isShown:y>0||g||null!=E,onEntering:d,onEntered:u,onExiting:m,onExited:()=>{b(!1),p&&p()}},E&&a.a.createElement("div",{className:"error-message"},a.a.createElement(Ke.a,{icon:en}),a.a.createElement("span",null,"".concat(E))),!E&&a.a.createElement("div",{className:"status-message"},y>0&&a.a.createElement("span",null,"".concat(y," row").concat(y>1?"s":""," pending"))),a.a.createElement("div",{className:"buttons-container"},!t&&!f&&a.a.createElement(gh,{kind:"secondary",onClick:s,tooltip:r},"Discard"),a.a.createElement(gh,{kind:f?"success":"primary",onClick:n,icon:w,disabled:t||f||null!=E,tooltip:o},t&&"Committing...",!t&&f&&"Success",!t&&!f&&"Commit")))});n(1299);function kp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ap=p.module("IrisGridCopyHandler");class Pp extends i.Component{static getStatusMessageText(e,t){switch(e){case Pp.COPY_STATES.CONFIRMATION_REQUIRED:return"Are you sure you want to copy ".concat(t.toLocaleString()," rows to your clipboard?");case Pp.COPY_STATES.CLICK_REQUIRED:return"Fetched ".concat(t.toLocaleString()," rows!");case Pp.COPY_STATES.FETCH_ERROR:return"Unable to copy data.";case Pp.COPY_STATES.FETCH_IN_PROGRESS:return"Fetching ".concat(t.toLocaleString()," rows for clipboard...");case Pp.COPY_STATES.DONE:return"Copied to Clipboard!";default:return""}}static getCopyButtonText(e){switch(e){case Pp.BUTTON_STATES.FETCH_IN_PROGRESS:return"Fetching";case Pp.BUTTON_STATES.CLICK_TO_COPY:return"Click to Copy";case Pp.BUTTON_STATES.RETRY:return"Retry";default:return"Copy"}}constructor(e){super(e),this.handleBackgroundClick=this.handleBackgroundClick.bind(this),this.handleCancelClick=this.handleCancelClick.bind(this),this.handleCopyClick=this.handleCopyClick.bind(this),this.handleHideTimeout=this.handleHideTimeout.bind(this),this.textData=null,this.hideTimer=null,this.fetchPromise=null,this.state={error:null,copyState:Pp.COPY_STATES.IDLE,buttonState:Pp.BUTTON_STATES.COPY,isShown:!1,rowCount:0}}componentDidMount(){var{copyOperation:e}=this.props;null!=e&&this.startCopy()}componentDidUpdate(e){var{copyOperation:t}=this.props;e.copyOperation!==t&&this.startCopy()}componentWillUnmount(){this.stopCopy()}startCopy(){Ap.debug2("startCopy"),this.stopCopy();var{copyOperation:e}=this.props;if(null==e)return Ap.debug2("No copy operation set, cancelling out"),void this.setState({isShown:!1});var{ranges:t,error:n}=e;if(null!=n)return Ap.debug("Showing copy error",n),this.setState({isShown:!0,copyState:Pp.COPY_STATES.DONE,error:n}),void this.startHideTimer();var i=fr.rowCount(t);this.setState({rowCount:i,isShown:!0,error:null}),i>Pp.NO_PROMPT_THRESHOLD?this.setState({buttonState:Pp.BUTTON_STATES.COPY,copyState:Pp.COPY_STATES.CONFIRMATION_REQUIRED}):this.startFetch()}stopCopy(){this.textData=null,this.stopFetch(),this.stopHideTimer()}handleBackgroundClick(){Ap.debug2("handleBackgroundClick");var{copyState:e}=this.state;e===Pp.COPY_STATES.DONE&&this.setState({isShown:!1})}handleCancelClick(){Ap.debug2("handleCancelClick"),this.stopFetch(),this.setState({isShown:!1})}handleCopyClick(){Ap.debug2("handleCopyClick"),null!=this.textData?this.copyText(this.textData):this.startFetch()}handleHideTimeout(){Ap.debug2("handleHideTimeout"),this.stopHideTimer(),this.setState({isShown:!1})}copyText(e){Ap.debug2("copyText",e),this.textData=e,je.copyToClipboard(e).then((()=>{this.setState({copyState:Pp.COPY_STATES.DONE}),this.startHideTimer()}),(e=>{Ap.error("copyText error",e),this.setState({buttonState:Pp.BUTTON_STATES.CLICK_TO_COPY,copyState:Pp.COPY_STATES.CLICK_REQUIRED})}))}startFetch(){this.stopFetch(),this.setState({buttonState:Pp.BUTTON_STATES.FETCH_IN_PROGRESS,copyState:Pp.COPY_STATES.FETCH_IN_PROGRESS});var{model:e,copyOperation:t}=this.props,{ranges:n,includeHeaders:i,userColumnWidths:a,movedColumns:s,formatValues:r}=t;Ap.debug("startFetch",n);var o=ol.getHiddenColumns(a),l=wr.getModelRanges(n,s);if(o.length>0){var c=o.map(fr.makeColumn);l=fr.subtractRangesFromRanges(l,c)}var h=r?(t,n)=>e.displayString(t,n.type,n.name):e=>"".concat(e);this.fetchPromise=Va.makeCancelable(e.textSnapshot(l,i,h)),this.fetchPromise.then((e=>{this.fetchPromise=null,this.copyText(e)})).catch((e=>{e instanceof Da?Ap.debug("User cancelled copy."):(Ap.error("Error fetching contents",e),this.fetchPromise=null,this.setState({buttonState:Pp.BUTTON_STATES.RETRY,copyState:Pp.COPY_STATES.FETCH_ERROR}))}))}stopFetch(){this.fetchPromise&&(Ap.debug2("stopFetch"),this.fetchPromise.cancel(),this.fetchPromise=null)}startHideTimer(){this.stopHideTimer(),this.hideTimer=setTimeout(this.handleHideTimeout,Pp.HIDE_TIMEOUT)}stopHideTimer(){null!=this.hideTimer&&(clearTimeout(this.hideTimer),this.hideTimer=null)}render(){var{onEntering:e,onEntered:t,onExiting:n,onExited:i}=this.props,{buttonState:s,copyState:r,isShown:o,rowCount:l,error:c}=this.state,h=r===Pp.COPY_STATES.DONE?"fade":"copy-slide-up",d=Pp.getCopyButtonText(s),u=null!==c&&void 0!==c?c:Pp.getStatusMessageText(r,l),m=r!==Pp.COPY_STATES.DONE,p=s===Pp.BUTTON_STATES.FETCH_IN_PROGRESS,g=r===Pp.COPY_STATES.DONE;return a.a.createElement(Lp,{animation:h,isShown:o,className:qe()("iris-grid-copy-handler",{"copy-done":g}),onClick:this.handleBackgroundClick,onEntering:e,onEntered:t,onExiting:n,onExited:i},a.a.createElement("div",{className:"status-message"},a.a.createElement("span",null,u)),a.a.createElement(We.CSSTransition,{in:m,timeout:Kn.transitionMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"buttons-container"},a.a.createElement("button",{type:"button",className:"btn btn-outline-secondary btn-cancel",onClick:this.handleCancelClick},"Cancel"),a.a.createElement("button",{type:"button",className:qe()("btn","btn-copy",{"btn-primary":!p,"btn-secondary":p,"btn-spinner":p}),onClick:this.handleCopyClick,disabled:p},p&&a.a.createElement(Yn,null),d))))}}kp(Pp,"NO_PROMPT_THRESHOLD",1e4),kp(Pp,"HIDE_TIMEOUT",3e3),kp(Pp,"COPY_STATES",{IDLE:"IDLE",CONFIRMATION_REQUIRED:"CONFIRMATION_REQUIRED",FETCH_IN_PROGRESS:"FETCH_IN_PROGRESS",FETCH_ERROR:"FETCH_ERROR",CLICK_REQUIRED:"CLICK_REQUIRED",DONE:"DONE"}),kp(Pp,"BUTTON_STATES",{COPY:"COPY",FETCH_IN_PROGRESS:"FETCH_IN_PROGRESS",CLICK_TO_COPY:"CLICK_TO_COPY",RETRY:"RETRY"}),Pp.propTypes={model:pi.a.instanceOf(Cu).isRequired,copyOperation:pi.a.shape({ranges:pi.a.arrayOf(pi.a.instanceOf(fr)).isRequired,movedColumns:pi.a.arrayOf(pi.a.shape({to:pi.a.number,from:pi.a.number})).isRequired,userColumnWidths:pi.a.instanceOf(Map).isRequired,formatValues:pi.a.bool,includeHeaders:pi.a.bool,error:pi.a.string}),onEntering:pi.a.func,onEntered:pi.a.func,onExiting:pi.a.func,onExited:pi.a.func},Pp.defaultProps={copyOperation:null,onEntering:()=>{},onEntered:()=>{},onExiting:()=>{},onExited:()=>{}};var _p=Pp;n(1282);class Hp extends i.PureComponent{constructor(e){super(e);var{debounceMs:t}=e;this.debouncedSendUpdate=pa()(this.sendUpdate.bind(this),t),this.handleCancel=this.handleCancel.bind(this),this.handleChange=this.handleChange.bind(this),this.handleCommit=this.handleCommit.bind(this),this.handleFocus=this.handleFocus.bind(this),this.handleBlur=this.handleBlur.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.inputField=null;var{value:n}=e;this.initialValue=n,this.state={isChanged:!1,value:n}}componentDidMount(){this.inputField.focus()}componentDidUpdate(e){var{debounceMs:t}=this.props;e.debounceMs!==t&&(this.debouncedSendUpdate.flush(),this.debouncedSendUpdate=pa()(this.sendUpdate.bind(this),t))}componentWillUnmount(){this.debouncedSendUpdate.cancel()}setValue(e){this.initialValue=e,this.setState({value:e})}focus(){this.inputField.focus()}handleChange(e){var{value:t}=e.target;this.setState({value:t,isChanged:!0}),this.debouncedSendUpdate(t)}handleCancel(){this.debouncedSendUpdate.cancel();var{initialValue:e}=this,{isChanged:t}=this.state;t&&this.sendUpdate(e);var{onDone:n}=this.props;n()}handleCommit(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];this.debouncedSendUpdate.flush();var{onDone:n}=this.props;n(e,t)}handleFocus(){this.inputField.select()}handleBlur(e){var{relatedTarget:t}=e;null!==t&&void 0!==t&&t.classList.contains("context-menu-container")?this.handleCommit(!1,!0):null!==t&&void 0!==t&&t.classList.contains("advanced-filter-button")?this.handleCommit(!1,!1):this.handleCommit(!0,!0)}handleTab(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.debouncedSendUpdate.flush();var{onTab:t}=this.props;t(e)}handleKeyDown(e){switch(e.key){case"Escape":e.stopPropagation(),e.preventDefault(),this.handleCancel();break;case"Enter":e.stopPropagation(),e.preventDefault(),this.handleCommit();break;case"Tab":e.stopPropagation(),e.preventDefault(),this.handleTab(e.shiftKey)}}handleContextMenu(e){var{onContextMenu:t}=this.props;t(e)}sendUpdate(e){var{onChange:t}=this.props;t(e)}render(){var{className:e,style:t,isAdvancedFilterSet:n,onAdvancedFiltersTriggered:i}=this.props,{value:s}=this.state;return a.a.createElement("div",{style:t,className:"iris-grid-input-autosized-wrapper","data-value":s},a.a.createElement("input",{ref:e=>{this.inputField=e},className:qe()("iris-grid-input-field",e),type:"text",value:s,onBlur:this.handleBlur,onFocus:this.handleFocus,onChange:this.handleChange,onKeyDown:this.handleKeyDown,onContextMenu:this.handleContextMenu,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",spellCheck:"false"}),a.a.createElement("div",{className:"advanced-filter-button-container"},a.a.createElement("button",{type:"button",className:qe()("btn btn-link btn-link-icon advanced-filter-button",{"filter-set":n}),onClick:i,onContextMenu:this.handleContextMenu},a.a.createElement("div",{className:"fa-layers "},a.a.createElement(Ke.a,{icon:pn,className:"filter-solid"}),a.a.createElement(Ke.a,{icon:bt,className:"filter-light"})))))}}Hp.propTypes={className:pi.a.string,style:pi.a.object,value:pi.a.string,isAdvancedFilterSet:pi.a.bool,onAdvancedFiltersTriggered:pi.a.func,onChange:pi.a.func,onDone:pi.a.func,onTab:pi.a.func,onContextMenu:pi.a.func,debounceMs:pi.a.number},Hp.defaultProps={style:{},className:"",value:"",isAdvancedFilterSet:!1,onAdvancedFiltersTriggered:()=>{},onChange:()=>{},onDone:()=>{},onTab:()=>{},onContextMenu:()=>{},debounceMs:150};var jp=Hp,Vp={TABLE:{TOGGLE_QUICK_FILTER:Be.createAndAdd({id:"TABLE.TOGGLE_QUICK_FILTER",name:"Toggle Quick Filter",shortcut:[_e.CTRL,He.F],macShortcut:[_e.CMD,He.F]}),CLEAR_ALL_FILTERS:Be.createAndAdd({id:"TABLE.CLEAR_ALL_FILTERS",name:"Clear All Table Filters",shortcut:[_e.CTRL,He.E],macShortcut:[_e.CMD,He.E]}),CLEAR_FILTERS:Be.createAndAdd({id:"TABLE.CLEAR_FILTERS",name:"Clear Active Table Filters",shortcut:[_e.CTRL,_e.SHIFT,He.E],macShortcut:[_e.CMD,_e.SHIFT,He.E]}),REVERSE:Be.createAndAdd({id:"TABLE.REVERSE",name:"Reverse",shortcut:[_e.CTRL,He.I],macShortcut:[_e.CMD,He.I]}),TOGGLE_SEARCH:Be.createAndAdd({id:"TABLE.TOGGLE_SEARCH",name:"Toggle Search",shortcut:[_e.CTRL,_e.SHIFT,He.F],macShortcut:[_e.CMD,_e.SHIFT,He.F]})},INPUT_TABLE:{COMMIT:Be.createAndAdd({id:"INPUT_TABLE.COMMIT",name:"Commit",shortcut:[_e.CTRL,He.S],macShortcut:[_e.CMD,He.S]}),DISCARD:Be.createAndAdd({id:"INPUT_TABLE.DISCARD",name:"Discard",shortcut:[_e.CTRL,_e.ALT,He.S],macShortcut:[_e.CMD,_e.OPTION,He.S]})}};var zp=class extends yo{constructor(e){super(),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"irisGrid",void 0),this.irisGrid=e}onDown(e){if(Vp.TABLE.REVERSE.matchesEvent(e)){if(!this.irisGrid.isReversible())return!1;var{reverseType:t}=this.irisGrid.state;return t===cs.REVERSE_TYPE.NONE?this.irisGrid.reverse(cs.REVERSE_TYPE.POST_SORT):this.irisGrid.reverse(cs.REVERSE_TYPE.NONE),!0}return!1}};var Up=class extends yo{constructor(e){super(),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"irisGrid",void 0),this.irisGrid=e}onDown(e){return!!Vp.TABLE.CLEAR_FILTERS.matchesEvent(e)&&(this.irisGrid.clearAllFilters(),!0)}};var Bp=class extends yo{constructor(e){super(),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"irisGrid",void 0),this.irisGrid=e}onDown(e){var{selectedRanges:t}=this.irisGrid.state;return!("c"!==e.key||!je.isModifierKeyDown(e))&&(ol.isValidSnapshotRanges(t)?this.irisGrid.copyRanges(t):this.irisGrid.copyRanges(t,!1,!1,"Invalid copy ranges"),!0)}};var Wp=class extends $r{constructor(e){super(),this.irisGrid=e,this.cursor=null}isActive(){var{isSelectingColumn:e}=this.irisGrid.props;return e}isValidColumn(e){if(null==e)return!1;var{columnSelectionValidator:t}=this.irisGrid.props;return!t||t(e)}updateColumnSelectionStatus(){var{columnSelectionValidator:e}=this.irisGrid.props;e&&e(null)}getTableColumn(e){if(null==e)return null;var{model:t}=this.irisGrid.props,n=this.irisGrid.getModelColumn(e);return null==n?null:t.columns[n]}onMove(e){if(!this.isActive())return!1;var{columnAllowedCursor:t,columnNotAllowedCursor:n}=this.irisGrid.props,{column:i}=e,a=this.getTableColumn(i);return this.isValidColumn(a)?(this.cursor=t,this.irisGrid.setState({hoverSelectColumn:i})):(this.cursor=n,this.irisGrid.setState({hoverSelectColumn:null})),!0}onWheel(e){if(!this.isActive())return!1;var{columnAllowedCursor:t,columnNotAllowedCursor:n}=this.irisGrid.props,{column:i}=e,a=this.getTableColumn(i);return this.isValidColumn(a)?this.cursor=t:this.cursor=n,{preventDefault:!1,stopPropagation:!1}}onLeave(){return this.isActive()&&this.irisGrid.setState({hoverSelectColumn:null}),this.updateColumnSelectionStatus(),!1}onDown(){return this.isActive()}onClick(e){if(!this.isActive())return!1;var{column:t}=e,n=this.getTableColumn(t);return this.isValidColumn(n)&&this.irisGrid.selectColumn(n),!0}};var Gp=class extends $r{constructor(e){super(),this.irisGrid=e}destroyColumnTooltip(){var{shownColumnTooltip:e}=this.irisGrid.state;null!=e&&this.irisGrid.setState({shownColumnTooltip:null})}hideColumnTooltip(){var{tooltip:e}=this.irisGrid;e&&(e.stopTimer(),e.hide())}onDown(){return this.hideColumnTooltip(),!1}onContextMenu(){return this.hideColumnTooltip(),!1}onWheel(){this.destroyColumnTooltip()}onMove(e){var{y:t,column:n,row:i}=e,{shownColumnTooltip:a}=this.irisGrid.state,s=this.irisGrid.getTheme(),r=null;return null!==n&&null===i&&t>=0&&t<=s.columnHeaderHeight&&(r=n),r!==a&&this.irisGrid.setState({shownColumnTooltip:r}),!1}};var qp=class extends $r{constructor(e){super(),this.column=null,this.irisGrid=e}getColumnFromGridPoint(e){var{y:t,column:n,row:i}=e;if(null!==n&&null===i&&t<=this.irisGrid.getTheme().columnHeaderHeight)return n;return null}onDown(e){return this.column=this.getColumnFromGridPoint(e),!1}onClick(e,t,n){var i=this.getColumnFromGridPoint(e);if(null!=i&&i===this.column){var a=je.isModifierKeyDown(n);return this.irisGrid.toggleSort(i,a),!0}return!1}};var Kp=class extends $r{constructor(e){super(),this.irisGrid=e}onDown(e){var{y:t,column:n,row:i}=e;if(null!==n&&null===i){var{isFilterBarShown:a}=this.irisGrid.state,s=this.irisGrid.getTheme();if(a&&t>s.columnHeaderHeight&&t<=s.columnHeaderHeight+s.filterBarHeight)return this.irisGrid.focusFilterBar(n),!0}return!1}onMove(e){var{y:t,column:n}=e,{isFilterBarShown:i,hoverAdvancedFilter:a}=this.irisGrid.state,s=this.irisGrid.getTheme(),r=null;return i&&null!==n&&t>=s.columnHeaderHeight&&t<=s.columnHeaderHeight+s.filterBarHeight&&(r=n),r!==a&&this.irisGrid.setState({hoverAdvancedFilter:r}),!1}onLeave(e){var{column:t}=e,{hoverAdvancedFilter:n}=this.irisGrid.state;null!==n&&t!==n&&this.irisGrid.setState({hoverAdvancedFilter:null})}};n(1278);class Yp extends i.Component{constructor(e){super(e),this.handleInputChange=this.handleInputChange.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.inputRef=a.a.createRef()}handleInputChange(){var{onChange:e}=this.props;e(this.inputRef.current.value)}closeContextMenu(){var{forwardedProps:e}=this.props,{closeMenu:t}=e;t(!0)}revertToDefault(){var{onChange:e}=this.props;e(null)}returnFocusToContextMenu(){var e=_a.getClosestByClassName(this.inputRef.current,"context-menu-container");e&&e.focus()}handleKeyDown(e){switch(e.key){case"Enter":e.stopPropagation(),this.closeContextMenu();break;case"Escape":e.stopPropagation(),this.revertToDefault(),this.closeContextMenu();break;case"ArrowRight":case"ArrowLeft":default:e.stopPropagation();break;case"ArrowUp":case"ArrowDown":this.returnFocusToContextMenu()}}render(){var{formatString:e,forwardedProps:t,placeholder:n,title:i}=this.props,{menuItem:{description:s},iconElement:r}=t;return a.a.createElement("div",{className:"form-group flex-grow mb-0"},a.a.createElement("div",{className:"custom-format-title"},a.a.createElement("span",{className:"icon"},r),a.a.createElement("label",{className:"title mb-0",htmlFor:"custom-format-input"},i,s&&a.a.createElement(Ol,null,s))),a.a.createElement("div",{className:"pl-2 pr-2 pb-2"},a.a.createElement("input",{id:"custom-format-input",className:"form-control text-right mb-0",type:"text",defaultValue:e,ref:this.inputRef,placeholder:n,onKeyDown:this.handleKeyDown,onChange:this.handleInputChange,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",spellCheck:"false"})))}}Yp.propTypes={formatString:pi.a.string,forwardedProps:pi.a.shape({menuItem:pi.a.shape({title:pi.a.string,description:pi.a.string}),closeMenu:pi.a.func,iconElement:pi.a.node}),placeholder:pi.a.string,title:pi.a.string,onChange:pi.a.func},Yp.defaultProps={formatString:"",forwardedProps:{menuItem:{},closeMenu:()=>{},iconElement:null},placeholder:"",title:"",onChange:()=>{}};var Xp=Yp;var Zp=class{static isDefaultSelected(e){return!e||![Es.TYPE_CONTEXT_CUSTOM,Es.TYPE_CONTEXT_PRESET].includes(e.type)}static isCustomSelected(e){return e&&e.type===Es.TYPE_CONTEXT_CUSTOM}static makeOption(e,t,n,i){return{title:e,description:e,group:n,format:t,isSelected:i}}static makeCustomFormatOption(e,t,n,i,s){return{title:e.label,format:e,group:t,isSelected:i,menuElement:a.a.createElement(Xp,{formatString:e.formatString,title:e.label,placeholder:n,onChange:s})}}};function $p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Qp{static getOptions(e,t){var n=new Date,i=[{group:Qp.dateGroup,formatString:"yyyy-MM-dd"},{group:Qp.dateGroup,formatString:"MM-dd-yyyy"},{group:Qp.timeGroup,formatString:"HH:mm:ss"},{group:Qp.timeGroup,formatString:"HH:mm:ss.SSS"},{group:Qp.timeGroup,formatString:"HH:mm:ss.SSSSSSSSS"},{group:Qp.dateTimeGroup,formatString:"yyyy-MM-dd HH:mm:ss"},{group:Qp.dateTimeGroup,formatString:"yyyy-MM-dd HH:mm:ss.SSS"},{group:Qp.dateTimeGroup,formatString:"yyyy-MM-dd HH:mm:ss.SSSSSSSSS"}].map((i=>{var a=Ds.makeFormat("",i.formatString,Ds.TYPE_CONTEXT_PRESET),s=e.getFormattedString(n,cs.dataType.DATETIME,"",a);return Zp.makeOption(s,a,i.group,Ds.isSameFormat(a,t))}));return[Zp.makeOption("Default",null,Qp.dateGroup,Zp.isDefaultSelected(t)),...i]}}$p(Qp,"dateGroup",10),$p(Qp,"timeGroup",20),$p(Qp,"dateTimeGroup",30);var Jp=Qp;function eg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class tg{static getOptions(e,t){var n=[{format:Ls.FORMAT_PERCENT,group:tg.presetGroup},{format:Ls.FORMAT_BASIS_POINTS,group:tg.presetGroup},{format:Ls.FORMAT_MILLIONS,group:tg.presetGroup},{format:Ls.FORMAT_ROUND,group:tg.presetRoundGroup},{format:Ls.FORMAT_ROUND_TWO_DECIMALS,group:tg.presetRoundGroup},{format:Ls.FORMAT_ROUND_FOUR_DECIMALS,group:tg.presetRoundGroup}],i=Zp.makeOption("Default",null,tg.defaultGroup,Zp.isDefaultSelected(e)),a=n.map((t=>Zp.makeOption(t.format.label,t.format,t.group,Ls.isSameFormat(t.format,e)))),s=Zp.isCustomSelected(e),r=s?e:Ls.makeCustomFormat();return[i,...a,Zp.makeCustomFormatOption(r,tg.customGroup,Ls.DEFAULT_FORMAT_STRING,s,(e=>{if(e){var n=Ls.makeCustomFormat(e);Ls.isValid(n)&&t(n)}else t(null)}))]}}eg(tg,"defaultGroup",10),eg(tg,"presetGroup",20),eg(tg,"presetRoundGroup",30),eg(tg,"customGroup",40);var ng=tg;function ig(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class ag{static getOptions(e,t){var n=[{format:Ps.FORMAT_MILLIONS,group:ag.presetGroup}],i=Zp.makeOption("Default",null,ag.defaultGroup,Zp.isDefaultSelected(e)),a=n.map((t=>Zp.makeOption(t.format.label,t.format,t.group,Ps.isSameFormat(t.format,e)))),s=Zp.isCustomSelected(e),r=s?e:Ps.makeCustomFormat();return[i,...a,Zp.makeCustomFormatOption(r,ag.customGroup,Ps.DEFAULT_FORMAT_STRING,s,(e=>{if(e){var n=Ps.makeCustomFormat(e);Ps.isValid(n)&&t(n)}else t(null)}))]}}ig(ag,"defaultGroup",10),ig(ag,"presetGroup",20),ig(ag,"customGroup",30);var sg=ag;n(1277);function rg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function og(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rg(Object(n),!0).forEach((function(t){lg(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function lg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var cg=p.module("IrisGridContextMenuHandler"),hg="yyyy-MM-dd HH:mm:ss.SSSSSSSSS";class dg extends $r{static getQuickFilterCondition(e,t){return arguments.length>2&&void 0!==arguments[2]&&arguments[2]&&e?e.and(t):t}static getQuickFilterText(e,t){return arguments.length>2&&void 0!==arguments[2]&&arguments[2]&&e?"".concat(e," && ").concat(t):t}static getNumberValueEqualsFilter(e,t){var n=e.filter();if(t===Number.POSITIVE_INFINITY)return va.FilterCondition.invoke("isInf",n).and(n.greaterThan(va.FilterValue.ofNumber(0)));if(t===Number.NEGATIVE_INFINITY)return va.FilterCondition.invoke("isInf",n).and(n.lessThan(va.FilterValue.ofNumber(0)));if(Number.isNaN(t))return va.FilterCondition.invoke("isNaN",n);var i=dg.getFilterValueForNumberOrChar(e.type,t);return n.eq(i)}static getFilterValueForNumberOrChar(e,t){return cs.isCharType(e)?va.FilterValue.ofString(String.fromCharCode(t)):va.FilterValue.ofNumber(t)}constructor(e){super(),this.debouncedUpdateCustomFormat=pa()(e.handleFormatSelection,150),this.irisGrid=e}componentWillUnmount(){this.debouncedUpdateCustomFormat.flush()}onContextMenu(e,t,n){var{irisGrid:i}=this,{y:a,column:s,row:r}=e,o=i.getModelColumn(s),l=i.getModelRow(r),{model:c,canCopy:h}=i.props,{columns:d}=c,u=c.valueForCell(o,l),m=c.textForCell(o,l),p=d[o],g=[],{metrics:v,isFilterBarShown:f,reverseType:b,quickFilters:C,advancedFilters:S,searchFilter:E}=i.state,w=i.getTheme(),{columnHeaderHeight:y,gridY:T}=v,{filterIconColor:O,filterBarActiveColor:M,contextMenuSortIconColor:N,contextMenuReverseIconColor:D}=w,{onContextMenu:x,settings:R}=i.props,I=c.sort,L=cs.getSortForColumn(I,o),F=b!==cs.REVERSE_TYPE.NONE,k=new Ds({timeZone:R.timeZone,showTimeZone:!1,showTSeparator:!0,defaultDateTimeFormatString:hg}),A=new Ds({timeZone:R.timeZone,showTimeZone:R.showTimeZone,showTSeparator:R.showTSeparator,defaultDateTimeFormatString:hg}),P=c.isColumnFrozen(s);if(null!=p){var{table:_}=c;g.push(x({table:_,model:c,value:u,valueText:m,column:p,rowIndex:r,columnIndex:s,modelRow:l,modelColumn:o}))}if(null!=p&&c.isFilterable(o)&&g.push({title:"Clear Column Filter",group:dg.GROUP_FILTER,order:30,action:()=>{this.irisGrid.removeColumnFilter(o)},disabled:!(C.has(o)||S.has(o))}),f?a<=T:a<=y){if(null!=p){var{userColumnWidths:H}=v,j=[...H.values()].some((e=>0===e));g.push({title:"Hide Column",group:dg.GROUP_HIDE_COLUMNS,action:()=>{this.irisGrid.hideColumnByVisibleIndex(s)}}),g.push({title:P?"Unfreeze Column":"Freeze Column",group:dg.GROUP_HIDE_COLUMNS,action:()=>{P?this.irisGrid.unFreezeColumnByColumnName(p.name):this.irisGrid.freezeColumnByColumnName(p.name)},order:10}),g.push({title:"Show All Columns",group:dg.GROUP_HIDE_COLUMNS,action:()=>{this.irisGrid.showAllColumns()},disabled:!j}),g.push({title:"Quick Filters",icon:Ut,iconColor:M,shortcut:Vp.TABLE.TOGGLE_QUICK_FILTER,group:dg.GROUP_FILTER,order:10,action:()=>{this.irisGrid.toggleFilterBar(s)}}),g.push({title:"Advanced Filters",icon:S.get(o)?pn:bt,iconColor:O,group:dg.GROUP_FILTER,order:20,action:()=>{this.irisGrid.handleAdvancedMenuOpened(s)}}),g.push({title:"Clear Table Filters",group:dg.GROUP_FILTER,order:40,shortcut:Vp.TABLE.CLEAR_FILTERS,action:()=>{this.irisGrid.clearAllFilters()},disabled:!(C.size>0||S.size>0||null!==E)}),g.push({title:"Sort by",icon:Ut,iconColor:N,group:dg.GROUP_SORT,order:10,actions:this.sortByActions(p,o,L)}),g.push({title:"Add Additional Sort",disabled:L&&1===I.length||F&&1===I.length||L&&F&&2===I.length||0===I.length,group:dg.GROUP_SORT,order:20,actions:this.additionalSortActions(p,o)}),g.push({title:"Clear Table Sorting",disabled:0===I.length||F&&1===I.length,group:dg.GROUP_SORT,action:()=>{this.irisGrid.sortColumn(s,dg.COLUMN_SORT_DIRECTION.none)},order:30}),g.push({title:b===cs.REVERSE_TYPE.NONE?"Reverse Table":"Clear Reverse Table",icon:Ut,iconColor:D,group:dg.GROUP_SORT,order:40,disabled:!c.isReversible,shortcut:Vp.TABLE.REVERSE,action:()=>{b===cs.REVERSE_TYPE.NONE?this.irisGrid.reverse(cs.REVERSE_TYPE.POST_SORT):this.irisGrid.reverse(cs.REVERSE_TYPE.NONE)}}),g.push({title:"Copy Column Name",group:dg.GROUP_COPY,action:()=>{je.copyToClipboard(c.textForColumnHeader(o)).catch((e=>cg.error("Unable to copy header",e)))}}),cs.isDateType(p.type)?g.push({title:"Date/Time Format",group:dg.GROUP_FORMAT,actions:this.dateFormatActions(p)}):cs.isNumberType(p.type)&&g.push({title:"Number Format",group:dg.GROUP_FORMAT,actions:this.numberFormatActions(p)})}}else{if(null!=p&&null!=r){if(c.isFilterable(o)){var V={title:"Filter By Value",icon:Ut,iconColor:O,group:dg.GROUP_FILTER,order:10,actions:null},z={title:"Add Filter By Value",icon:Ut,iconColor:O,group:dg.GROUP_FILTER,order:20,actions:null,disabled:!C.get(o)};if(null!=u)if(cs.isNumberType(p.type)||cs.isCharType(p.type)){var U=cs.isCharType(p.type)?String.fromCharCode(u):"".concat(u);V.actions=this.numberFilterActions(p,U,u),z.actions=this.numberFilterActions(p,U,u,C.get(o),!0)}else if(cs.isBooleanType(p.type))V.actions=this.booleanFilterActions(p,m),z.actions=this.booleanFilterActions(p,m,C.get(o),!0);else if(cs.isDateType(p.type)){var B=k.format(u),W=A.format(u);V.actions=this.dateFilterActions(p,B,W,u),z.actions=this.dateFilterActions(p,B,W,u,C.get(o),!0)}else V.actions=this.stringFilterActions(p,m,u),z.actions=this.stringFilterActions(p,m,u,C.get(o),!0);else V.actions=this.nullFilterActions(p),z.actions=this.nullFilterActions(p,C.get(o),!0);null!=V.actions&&V.actions.length>0&&g.push(V),null!=z.actions&&z.actions.length>0&&g.push(z)}h&&(g.push({title:"Copy Cell",group:dg.GROUP_COPY,order:10,action:()=>{i.copyCell(s,r)}}),g.push({title:"Copy Cell Unformatted",group:dg.GROUP_COPY,order:20,action:()=>{i.copyCell(s,r,!0)}}))}var{selectedRanges:G}=t.state;G.length>0&&(h&&(g.push({title:"Copy Selection",shortcut:Uc.COPY,group:dg.GROUP_COPY,order:30,action:()=>{i.copyRanges(G)}}),g.push({title:"Copy Selection w/ Headers",group:dg.GROUP_COPY,order:40,action:()=>{i.copyRanges(G,!0)}})),c.isEditable&&g.push({title:"Delete Selected Rows",group:dg.GROUP_EDIT,order:50,action:()=>{this.irisGrid.deleteRanges(G)}}))}return 0!==g.length&&(vl.triggerMenu(i.gridWrapper,n.pageX,n.pageY,g),!0)}dateFormatActions(e){for(var t=this,{model:n}=this.irisGrid.props,{formatter:i}=n,a=i.getColumnFormat(e.type,e.name),s=Jp.getOptions(i,a),r=[],o=function(i){var{description:a,format:o,group:l,isSelected:c,title:h}=s[i];r.push({title:h,description:a,icon:c?Je:null,group:l,order:i,action:()=>{t.irisGrid.handleFormatSelection(n.getColumnIndexByName(e.name),o)}})},l=0;l<s.length;l+=1)o(l);return r}numberFormatActions(e){var t,n=this,{model:i}=this.irisGrid.props,{formatter:a}=i,s=a.getColumnFormat(e.type,e.name),r=i.getColumnIndexByName(e.name);if(cs.isDecimalType(e.type))t=ng.getOptions(s,(e=>{this.debouncedUpdateCustomFormat(r,e)}));else{if(!cs.isIntegerType(e.type))return cg.error("Invalid column type in numberFormatActions"),null;t=sg.getOptions(s,(e=>{this.debouncedUpdateCustomFormat(r,e)}))}for(var o=[],l=function(e){var{format:i,isSelected:a}=t[e];o.push(og(og({},t[e]),{},{icon:a?Je:null,order:e,action:()=>{i&&i.type===Es.TYPE_CONTEXT_CUSTOM||n.irisGrid.handleFormatSelection(r,i)}}))},c=0;c<t.length;c+=1)l(c);return o}stringFilterActions(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=arguments.length>4&&void 0!==arguments[4]&&arguments[4],r=va.FilterValue.ofString(n),{filter:o,text:l}=i,c=[],{model:h}=this.irisGrid.props,d=h.getColumnIndexByName(e.name);return c.push({menuElement:a.a.createElement("div",{className:"iris-grid-filter-menu-item-value"},'"',t,'"'),order:1}),c.push({title:"text is exactly",description:"Show only rows where ".concat(e.name," is ").concat(n," (case sensitive)"),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(o,e.filter().eq(r),s),dg.getQuickFilterText(l,"=".concat(t),s))},order:10}),c.push({title:"text is not exactly",description:"Show only rows where ".concat(e.name," is not ").concat(t," (case sensitive)"),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(o,e.filter().notEq(r),s),dg.getQuickFilterText(l,"!=".concat(t),s))},order:20}),c.push({title:"text contains",description:"Show only rows where ".concat(e.name," contains ").concat(t),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(o,e.filter().contains(r),s),dg.getQuickFilterText(l,"~".concat(t),s))},order:30}),c.push({title:"text does not contain",description:"Show only rows where ".concat(e.name," does not contain ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(o,e.filter().contains(r).not(),s),dg.getQuickFilterText(l,"!~".concat(t),s))},order:40}),c.push({title:"text starts with",description:"Show only rows where ".concat(e.name," starts with ").concat(t),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(o,e.filter().invoke("startsWith",r),s),dg.getQuickFilterText(l,"".concat(t,"*"),s))},order:50}),c.push({title:"text ends with",description:"Show only rows where ".concat(e.name," ends with ").concat(t),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(i,e.filter().invoke("endsWith",r),s),dg.getQuickFilterText(l,"*".concat(t),s))},order:60}),c}numberFilterActions(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=arguments.length>4&&void 0!==arguments[4]&&arguments[4],r=dg.getFilterValueForNumberOrChar(e.type,n),{filter:o,text:l}=i,c=[],h=n!==Number.POSITIVE_INFINITY&&n!==Number.NEGATIVE_INFINITY&&!Number.isNaN(n),{model:d}=this.irisGrid.props,u=d.getColumnIndexByName(e.name);return c.push({menuElement:a.a.createElement("div",{className:"iris-grid-filter-menu-item-value"},s?" AND ":"",'"',t,'"'),order:1}),c.push({title:"is equal to",description:"Show only rows where ".concat(e.name," is ").concat(t),action:()=>{var i=dg.getNumberValueEqualsFilter(e,n);this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,i,s),dg.getQuickFilterText(l,"=".concat(t),s))},order:10}),c.push({title:"is not equal to",description:"Show only rows where ".concat(e.name," is not ").concat(t),action:()=>{var i=dg.getNumberValueEqualsFilter(e,n).not();this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,i,s),dg.getQuickFilterText(l,"!=".concat(t),s))},order:20}),h&&!cs.isCharType(e.type)&&(c.push({title:"greater than",description:"Show only rows where ".concat(e.name," is greater than ").concat(t),action:()=>{this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,e.filter().greaterThan(r),s),dg.getQuickFilterText(l,">".concat(t),s))},order:30}),c.push({title:"greater than or equal to",description:"Show only rows where ".concat(e.name," is greater than or equal to ").concat(t),action:()=>{this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,e.filter().greaterThanOrEqualTo(r),s),dg.getQuickFilterText(l,">=".concat(t),s))},order:40}),c.push({title:"less than",description:"Show only rows where ".concat(e.name," is less than ").concat(t),action:()=>{this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,e.filter().lessThan(r),s),dg.getQuickFilterText(l,"<".concat(t),s))},order:50}),c.push({title:"less than or equal to",description:"Show only rows where ".concat(e.name," is less than or equal to ").concat(t),action:()=>{this.irisGrid.setQuickFilter(u,dg.getQuickFilterCondition(o,e.filter().lessThanOrEqualTo(r),s),dg.getQuickFilterText(l,"<=".concat(t),s))},order:60})),c}booleanFilterActions(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=[],{filter:r,text:o}=n,{model:l}=this.irisGrid.props,c=l.getColumnIndexByName(e.name);return s.push({menuElement:a.a.createElement("div",{className:"iris-grid-filter-menu-item-value"},i?"AND ":"",'"',t,'"'),order:1}),s.push({title:"true",description:"Show only rows where ".concat(e.name," is true"),action:()=>{this.irisGrid.setQuickFilter(c,dg.getQuickFilterCondition(r,e.filter().isTrue(),i),dg.getQuickFilterText(o,"true",i))},order:10}),s.push({title:"false",description:"Show only rows where ".concat(e.name," is false"),action:()=>{this.irisGrid.setQuickFilter(c,dg.getQuickFilterCondition(r,e.filter().isFalse(),i),dg.getQuickFilterText(o,"false",i))},order:20}),s.push({title:"null",description:"Show only rows where ".concat(e.name," is null"),action:()=>{this.irisGrid.setQuickFilter(c,dg.getQuickFilterCondition(n,e.filter().isNull(),i),dg.getQuickFilterText(o,"null",i))},order:30}),s}dateFilterActions(e,t,n,i){var s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},r=arguments.length>5&&void 0!==arguments[5]&&arguments[5],o=va.FilterValue.ofNumber(i),{filter:l,text:c}=s,{model:h}=this.irisGrid.props,d=h.getColumnIndexByName(e.name),u=[];return u.push({menuElement:a.a.createElement("div",{className:"iris-grid-filter-menu-item-value"},r?" AND ":"",'"',n,'"'),order:1}),u.push({title:"date is",description:"Show only rows where ".concat(e.name," is ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().eq(o),r),dg.getQuickFilterText(c,"=".concat(t),r))},order:10}),u.push({title:"date is not",description:"Show only rows where ".concat(e.name," is not ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().notEq(o),r),dg.getQuickFilterText(c,"!=".concat(t),r))},order:20}),u.push({title:"date is before",description:"Show only rows where ".concat(e.name," is before ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().lessThan(o),r),dg.getQuickFilterText(c,"<".concat(t),r))},order:30}),u.push({title:"date is before or equal",description:"Show only rows where ".concat(e.name," is before or equal to ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().lessThanOrEqualTo(o),r),dg.getQuickFilterText(c,"<=".concat(t),r))},order:40}),u.push({title:"date is after",description:"Show only rows where ".concat(e.name," is greater than ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().greaterThan(o),r),dg.getQuickFilterText(c,">".concat(t),r))},order:50}),u.push({title:"date is after or equal",description:"Show only rows where ".concat(e.name," is after or equal to ").concat(n),action:()=>{this.irisGrid.setQuickFilter(d,dg.getQuickFilterCondition(l,e.filter().greaterThanOrEqualTo(o),r),dg.getQuickFilterText(c,">=".concat(t),r))},order:60}),u}nullFilterActions(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],{filter:i,text:s}=t,r=[],{model:o}=this.irisGrid.props,l=o.getColumnIndexByName(e.name);return r.push({menuElement:a.a.createElement("div",{className:"iris-grid-filter-menu-item-value"},n?" AND ":"",'"null"'),order:1}),r.push({title:"equals null",description:"Show only rows where ".concat(e.name," is null"),action:()=>{this.irisGrid.setQuickFilter(l,dg.getQuickFilterCondition(i,e.filter().isNull(),n),dg.getQuickFilterText(s,"null",n))},order:10}),r.push({title:"not equals null",description:"Show only rows where ".concat(e.name," is not null"),action:()=>{this.irisGrid.setQuickFilter(l,dg.getQuickFilterCondition(i,e.filter().isNull().not(),n),dg.getQuickFilterText(s,"!null",n))},order:20}),r}sortByActions(e,t,n){var i=this.irisGrid.getTheme(),{contextMenuSortIconColor:a}=i,s=[{title:"".concat(e.name," Ascending"),order:10,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.ascending)},icon:this.checkColumnSort(n,dg.COLUMN_SORT_DIRECTION.ascending)?Ut:null,iconColor:a},{title:"".concat(e.name," Descending"),order:20,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.descending)},icon:this.checkColumnSort(n,dg.COLUMN_SORT_DIRECTION.descending)?Ut:null,iconColor:a},{title:"Remove Sort",order:50,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.none,!1,!0)},disabled:!n}];return cs.isNumberType(e.type)&&(s.push({title:"ABS(".concat(e.name,") Ascending"),order:30,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.ascending,!0)},icon:this.checkColumnSort(n,dg.COLUMN_SORT_DIRECTION.ascending,!0)?Ut:null,iconColor:a}),s.push({title:"ABS(".concat(e.name,") Descending"),order:40,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.descending,!0)},icon:this.checkColumnSort(n,dg.COLUMN_SORT_DIRECTION.descending,!0)?Ut:null,iconColor:a})),s}additionalSortActions(e,t){var n=this.irisGrid.getTheme(),{contextMenuSortIconColor:i}=n,s=[{title:"Add Sort By",menuElement:a.a.createElement("div",{className:"btn-context-menu menu-title"},a.a.createElement("span",{className:"icon"},a.a.createElement(Ke.a,{icon:Ut,style:{color:i}})),a.a.createElement("span",{className:"title"},"Add Additional Sort"),a.a.createElement("span",{className:"shortcut"},je.isMacPlatform()?"\u2318Click":"^Click")),order:1},{title:"".concat(e.name," Ascending"),order:10,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.ascending,!1,!0)}},{title:"".concat(e.name," Descending"),order:20,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.descending,!1,!0)}}];return cs.isNumberType(e.type)&&(s.push({title:"ABS(".concat(e.name,") Ascending"),order:30,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.ascending,!0,!0)}}),s.push({title:"ABS(".concat(e.name,") Descending"),order:40,action:()=>{this.irisGrid.sortColumn(t,dg.COLUMN_SORT_DIRECTION.descending,!0,!0)}})),s}checkColumnSort(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!!e&&(e.direction===t&&e.isAbs===n)}}lg(dg,"GROUP_EDIT",vl.groups.high+10),lg(dg,"GROUP_HIDE_COLUMNS",vl.groups.high+25),lg(dg,"GROUP_FILTER",vl.groups.high+50),lg(dg,"GROUP_SORT",vl.groups.high+75),lg(dg,"GROUP_COPY",vl.groups.high+100),lg(dg,"GROUP_FORMAT",vl.groups.high+150),lg(dg,"COLUMN_SORT_DIRECTION",{ascending:"ASC",descending:"DESC",none:null});var ug=dg;var mg=class extends $r{constructor(e){super(),this.irisGrid=e}onDoubleClick(e){var{column:t,row:n}=e;return null!=n&&null!=t&&(this.irisGrid.selectData(t,n),!0)}};var pg=class extends $r{constructor(e){super(),this.irisGrid=e}onWheel(e,t,n){var{irisGrid:i}=this,{model:a}=i.props,{metrics:s,pendingRowCount:r}=i.state,{bottom:o,rowCount:l,rowHeight:c}=s,{deltaY:h}=wr.getScrollDelta(n);return a.isEditable&&o>=l-1&&h>0&&i.setState({pendingRowCount:r+Math.ceil(h/c)}),!1}},gg=e=>{var{children:t=null,onEntering:n,onEntered:s,onExiting:r,onExited:o}=e,[l,c]=Object(i.useState)(!1),h=Object(i.useRef)(),d=gi(t),u=Object(i.useCallback)((()=>{c(!0),h.current&&clearTimeout(h.current),h.current=setTimeout((()=>{c(!1)}),3e3)}),[c,h]);return Object(i.useEffect)((()=>{d!==t&&null!=t&&u()}),[t,d,c,u]),Object(i.useEffect)((()=>()=>h.current?clearTimeout(h.current):void 0),[]),a.a.createElement(Lp,{className:"toast-bottom-bar",isShown:l,onEntering:n,onEntered:s,onExiting:r,onExited:o},t)};var vg=class extends xr{getVisibleColumnWidth(e,t){var n,i,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.getFirstColumn(t),s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.calculateTreePaddingX(t),{model:r}=t,o=null!==(n=null===(i=r.layoutHints)||void 0===i?void 0:i.hiddenColumns)&&void 0!==n?n:[],l=this.getModelColumn(e,t);return this.userColumnWidths.has(l)?this.userColumnWidths.get(l):o.includes(r.columns[l].name)?0:super.getVisibleColumnWidth(e,t,a,s)}getGridY(e){var t=super.getGridY(e),{isFilterBarShown:n,theme:i,advancedFilters:a,quickFilters:s,sorts:r,reverseType:o}=e;return n?t+=i.filterBarHeight:(s&&s.size>0||a&&a.size>0)&&(t+=i.filterBarCollapsedHeight),o!==cs.REVERSE_TYPE.NONE&&r.length>0&&(t+=i.reverseHeaderBarHeight),t}},fg=a.a.memo((e=>{var{model:t,modelColumns:n,top:a,bottom:s,left:r,right:o,filter:l,formatter:c,reverseType:h,sorts:d,customColumns:u,movedColumns:m,hiddenColumns:p,alwaysFetchColumns:g,rollupConfig:v,totalsConfig:f,selectDistinctColumns:b,pendingRowCount:C,pendingDataMap:S,frozenColumns:E}=e,w=Object(i.useMemo)((()=>ol.getModelViewportColumns(n,r,o,m,p,g,1)),[n,r,o,m,p,g]);return Object(i.useEffect)((()=>{t.filter=l}),[t,l]),Object(i.useEffect)((()=>{var e=[...d];h!==cs.REVERSE_TYPE.NONE&&e.push(va.Table.reverse()),t.sort=e}),[t,d,h]),Object(i.useEffect)((()=>{t.formatter=c}),[t,c]),Object(i.useEffect)((()=>{t.isCustomColumnsAvailable&&(t.customColumns=u)}),[t,u]),Object(i.useEffect)((()=>{t.setViewport(a,s,w)}),[t,a,s,w]),Object(i.useEffect)((()=>{t.isRollupAvailable&&(t.rollupConfig=v)}),[t,t.isRollupAvailable,v]),Object(i.useEffect)((()=>{t.isSelectDistinctAvailable&&(t.selectDistinctColumns=b)}),[t,b]),Object(i.useEffect)((()=>{t.isTotalsAvailable&&(t.totalsConfig=f)}),[t,t.isTotalsAvailable,f]),Object(i.useEffect)((()=>{t.pendingRowCount=C}),[t,C]),Object(i.useEffect)((()=>{t.pendingDataMap=S}),[t,S]),Object(i.useEffect)((()=>{t.updateFrozenColumns(E)}),[t,E]),null}));fg.displayName="IrisGridModelUpdater",fg.propTypes={model:pi.a.instanceOf(Cu).isRequired,modelColumns:pi.a.arrayOf(Ma.Column).isRequired,top:pi.a.number.isRequired,bottom:pi.a.number.isRequired,left:pi.a.number,right:pi.a.number,filter:pi.a.arrayOf(Ma.FilterCondition).isRequired,sorts:pi.a.arrayOf(Ma.Sort).isRequired,reverseType:pi.a.oneOf(Object.values(cs.REVERSE_TYPE)),customColumns:pi.a.arrayOf(pi.a.string).isRequired,movedColumns:pi.a.arrayOf(pi.a.shape({})).isRequired,hiddenColumns:pi.a.arrayOf(pi.a.number).isRequired,frozenColumns:pi.a.arrayOf(pi.a.string),alwaysFetchColumns:pi.a.arrayOf(pi.a.string).isRequired,formatter:pi.a.instanceOf(Hs).isRequired,rollupConfig:Ma.RollupConfig,totalsConfig:pi.a.shape({}),selectDistinctColumns:pi.a.arrayOf(pi.a.string),pendingRowCount:pi.a.number,pendingDataMap:pi.a.instanceOf(Map)},fg.defaultProps={left:null,right:null,reverseType:cs.REVERSE_TYPE.NONE,rollupConfig:null,totalsConfig:null,selectDistinctColumns:[],pendingRowCount:0,pendingDataMap:new Map,frozenColumns:null};var bg=fg,Cg=Object.freeze({SORT_UP:"sortUp",SORT_DOWN:"sortDown",CARET_DOWN:"caretDown",CARET_RIGHT:"caretRight"}),Sg=.03;class Eg extends Xr{static isFilterValid(e,t){var n=null==e||null!=e.filter,i=null==t||null!=t.filter;return n&&i}constructor(){super(),this.initIcons()}initIcons(){this.icons={},this.setIcon(Cg.SORT_UP,Ln),this.setIcon(Cg.SORT_DOWN,In),this.setIcon(Cg.CARET_DOWN,Qt),this.setIcon(Cg.CARET_RIGHT,Jt)}setIcon(e,t){this.icons[e]=new Path2D(t.icon[4])}getIcon(e){return this.icons[e]}getSortIcon(e){return e?e.direction===cs.sortDirection.ascending?new Path2D(this.getIcon(Cg.SORT_UP)):e.direction===cs.sortDirection.descending?new Path2D(this.getIcon(Cg.SORT_DOWN)):null:null}drawCanvas(e){super.drawCanvas(e),this.drawScrim(e)}drawGridLines(e,t){super.drawGridLines(e,t),this.drawGroupedColumnLine(e,t),this.drawPendingRowLine(e,t)}drawGroupedColumnLine(e,t){var{metrics:n,model:i,theme:a}=t,{groupedColumns:s,columns:r}=i,{maxY:o,visibleColumnWidths:l,visibleColumnXs:c}=n;if(0!==s.length&&a.groupedColumnDividerColor){var h=s[s.length-1],d=r.findIndex((e=>e.name===h.name)),u=c.get(d),m=l.get(d);if(null!=u&&null!=m){var p=u+m+.5;e.strokeStyle=a.groupedColumnDividerColor,e.lineWidth=1,e.beginPath(),e.moveTo(p,0),e.lineTo(p,o),e.stroke()}}}drawPendingRowLine(e,t){var{metrics:n,model:i,theme:a}=t,{visibleRowYs:s,maxX:r}=n,{pendingRowCount:o}=i;if(!(o<=0)){var l=i.rowCount-i.pendingRowCount-i.floatingBottomRowCount,c=s.get(l);null!=c&&(c-=.5,e.save(),e.setLineDash([4,2]),e.strokeStyle=a.pendingTextColor,e.lineWidth=1,e.beginPath(),e.moveTo(0,c),e.lineTo(r,c),e.stroke(),e.restore())}}drawMouseColumnHover(e,t){var{theme:n,metrics:i,hoverSelectColumn:a}=t;if(null!=a&&n.linkerColumnHoverBackgroundColor){var{visibleColumnWidths:s,visibleColumnXs:r,maxY:o}=i,l=r.get(a),c=s.get(a);e.fillStyle=n.linkerColumnHoverBackgroundColor,e.fillRect(l,0,c,o)}}drawMouseRowHover(e,t){var{isSelectingColumn:n}=t;n||super.drawMouseRowHover(e,t)}drawScrim(e){var{context:t,loadingScrimProgress:n,metrics:i,theme:a}=e;if(null!=n){var{width:s,height:r,gridY:o}=i,{scrimBlurSize:l,scrimColor:c}=a;t.save(),t.globalCompositeOperation="color",t.filter="blur(".concat(l,"px)"),t.fillStyle=c,t.beginPath(),t.rect(0,o,s,r-o),t.clip(),t.fillRect(-l,-l+o,2*l+s,(2*l+(r-o))*n),t.restore()}}drawColumnHeaders(e,t){super.drawColumnHeaders(e,t);var{theme:n,metrics:i,model:a,reverseType:s}=t,{columnHeaderHeight:r}=i;if(this.drawFilterHeaders(e,t),!(r<=0)){var{sort:o}=a;if(1===o.length){var l=s!==cs.REVERSE_TYPE.NONE;this.drawHeaderBar(e,t,l?n.headerReverseBarColor:n.headerSortBarColor,l?n.reverseHeaderBarHeight:n.sortHeaderBarHeight)}else o.length>1&&(s!==cs.REVERSE_TYPE.NONE&&this.drawHeaderBar(e,t,n.headerReverseBarColor,n.reverseHeaderBarHeight,!1),this.drawHeaderBar(e,t,n.headerSortBarColor,n.sortHeaderBarHeight))}}drawHeaderBar(e,t,n,i){var a=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],{theme:s,metrics:r}=t,{columnHeaderHeight:o,width:l}=r,c=0;a||(c=i),e.fillStyle=s.headerBarCasingColor,e.fillRect(0,o-i-2+c,l,i+2),e.fillStyle=n,e.fillRect(0,o-i-1+c,l,i)}drawColumnHeader(e,t,n,i,a){super.drawColumnHeader(e,t,n,i,a);var{metrics:s,model:r,theme:o}=t,{modelColumns:l}=s,c=l.get(n),h=cs.getSortForColumn(r.sort,c),d=this.getSortIcon(h);if(d){var{columnHeaderHeight:u,gridX:m}=s,p=m+i+a-13,g=.5*u+(h.direction===cs.sortDirection.ascending?-6:-12),v=p-3;e.save(),e.beginPath(),e.rect(i,0,a,u),e.clip();var f=e.createLinearGradient(v,0,v+5,0);f.addColorStop(0,"".concat(o.headerBackgroundColor,"00")),f.addColorStop(1,"".concat(o.headerBackgroundColor,"CD")),e.fillStyle=f,e.fillRect(v,0,12,u),e.fillStyle=o.headerSortBarColor,e.translate(p,g),e.scale(Sg,Sg),e.fill(d),e.restore()}}drawFilterHeaders(e,t){var{isFilterBarShown:n,quickFilters:i,advancedFilters:a}=t;n?this.drawExpandedFilterHeaders(e,t):(i&&i.size>0||a&&a.size>0)&&this.drawCollapsedFilterHeaders(e,t)}drawExpandedFilterHeaders(e,t){var{metrics:n,model:i,theme:a,quickFilters:s,advancedFilters:r}=t,{filterBarHeight:o}=a;if(!(o<=0)){var{gridX:l,gridY:c,maxX:h,modelColumns:d,visibleColumns:u,visibleColumnWidths:m,visibleColumnXs:p}=n,g=c-o;if(e.save(),e.font=a.font,e.textAlign="left",s&&s.size>0||r&&r.size>0?e.fillStyle=a.filterBarExpandedActiveBackgroundColor:e.fillStyle=a.filterBarExpandedBackgroundColor,e.fillRect(l,g,h,o-1),e.fillStyle=a.headerBarCasingColor,e.fillRect(l,g+o-1,h,1),a.filterBarSeparatorColor){var v=g;e.strokeStyle=a.filterBarSeparatorColor,e.beginPath();for(var f=0;f<u.length;f+=1){var b=u[f],C=d.get(b),S=p.get(b),E=m.get(b);if(i.isFilterable(C)&&E>0){var w=l+S;e.rect(w+.5,v+.5,E,o-2)}}e.stroke()}for(var y=0;y<u.length;y+=1){var T=u[y],O=m.get(T),M=p.get(T)+l;this.drawExpandedFilterHeader(e,t,T,M,O)}e.restore()}}drawExpandedFilterHeader(e,t,n,i,a){if(!(a<=0)){var{metrics:s,theme:r,quickFilters:o,advancedFilters:l}=t,{modelColumns:c,gridY:h}=s,{filterBarHeight:d,filterBarExpandedActiveCellBackgroundColor:u,filterBarErrorColor:m,filterBarHorizontalPadding:p,headerColor:g}=r,v=h-d,f=c.get(n),b=o.get(f),C=l.get(f);if(null!=b||null!=C){var S=null;if(null!=b){var{text:E}=b;if((S=E)||(S=cs.getFilterText(b.filter)),S){var{fontWidths:w}=s,y=w.get(e.font);y||(y=e.measureText("8"))||(y=10);var T=(a-2*p)/y;T<=0?S="":S.length>T&&(S="".concat(S.substring(0,T-1),"\u2026"))}}if(e.save(),Eg.isFilterValid(C,b))e.fillStyle=u,e.fillRect(i+1,v+1,a-1,d-3);else{e.fillStyle=m,e.lineWidth=2,e.strokeStyle=m;var O=i+2,M=v+2,N=a-3,D=d-5;e.strokeRect(O,M,N,D)}if(S){var x=i+p,R=v+.5*d+1;e.fillStyle=g,e.fillText(S,x,R)}e.restore()}}}drawCollapsedFilterHeaders(e,t){var{metrics:n,theme:i}=t,{headerSeparatorColor:a,filterBarCollapsedHeight:s}=i;if(!(s<=0)){var{gridX:r,gridY:o,maxX:l,visibleColumns:c,visibleColumnWidths:h,visibleColumnXs:d}=n,u=o-s;e.save(),e.fillStyle=a,e.fillRect(r,u,l,s);for(var m=0;m<c.length;m+=1){var p=c[m],g=h.get(p),v=d.get(p)+r;this.drawCollapsedFilterHeader(e,t,p,v,g)}e.restore()}}drawCollapsedFilterHeader(e,t,n,i,a){if(!(a<=0)){var{metrics:s,theme:r,quickFilters:o,advancedFilters:l}=t,{modelColumns:c,gridY:h}=s,d=c.get(n),u=o.get(d),m=l.get(d),{filterBarCollapsedHeight:p,filterBarActiveColor:g,filterBarActiveBackgroundColor:v,filterBarErrorColor:f}=r;e.save();var b=Eg.isFilterValid(m,u);e.fillStyle=null==u&&null==m?v:b?g:f;var C=i+1,S=h-p,E=a-1,w=p-1;e.fillRect(C,S,E,w),e.restore()}}drawTreeMarker(e,t,n,i,a,s,r){e.save();var{x1:o,y1:l}=a,c=r?this.getIcon(Cg.CARET_DOWN):this.getIcon(Cg.CARET_RIGHT),h=n+o-2,d=i+l+2.5;e.fillStyle=s,e.textAlign="center",e.translate(h,d),e.scale(Sg,Sg),e.fill(c),e.restore()}drawRowFooters(e,t){var{metrics:n,model:i,mouseX:a,mouseY:s,theme:r}=t,{gridY:o,gridX:l,maxX:c,modelRows:h,floatingTopHeight:d,floatingBottomHeight:u,floatingRows:m,rowFooterWidth:p,height:g,horizontalBarHeight:v,verticalBarWidth:f,visibleRowHeights:b,visibleRowYs:C,width:S}=n;if(!(p<=0||0===m.length)){var{cellHorizontalPadding:E,floatingGridRowColor:w,floatingRowBackgroundColors:y,headerColor:T,rowHoverBackgroundColor:O}=r;e.translate(l,o),e.beginPath();var M=Math.min(c,S-p-f-l);e.fillStyle=y,d>0&&e.rect(M,0,p,d),u>0&&e.rect(M,g-o-v-u,p,u),e.fill();var N=a>=l&&a<=c+p?wr.getRowAtY(s,n):null;if(null!==N&&m.includes(N)){e.fillStyle=O;var D=C.get(N),x=b.get(N);e.fillRect(M,D,p,x)}if(e.beginPath(),e.strokeStyle=w,d>0&&(e.moveTo(M+.5,.5),e.lineTo(M+.5,d-.5)),u>0){var R=g-o-v-u;e.moveTo(M-.5,R+.5),e.lineTo(M-.5,R+u-.5)}e.stroke(),e.fillStyle=T,e.textAlign="left";for(var I=M+E,L=0;L<m.length;L+=1){var F=m[L],k=b.get(F),A=C.get(F),P=h.get(F),_=A+.5*k;e.fillText(i.textForRowFooter(P),I,_)}e.translate(-l,-o)}}}var wg=Eg,yg=n(52),Tg=n.n(yg),Og=Object.freeze({backgroundColor:Tg.a["grid-bg"],font:Tg.a.font,headerBackgroundColor:Tg.a["header-bg"],headerColor:Tg.a["header-color"],headerSeparatorColor:Tg.a["header-separator-color"],headerSeparatorHoverColor:Tg.a["header-separator-hover-color"],headerHiddenSeparatorHoverColor:Tg.a["header-hidden-separator-hover-color"],headerSortBarColor:Tg.a["header-sort-bar-color"],headerReverseBarColor:Tg.a["header-reverse-bar-color"],headerBarCasingColor:Tg.a["header-bar-casing-color"],headerFont:Tg.a["header-font"],rowBackgroundColors:Tg.a["row-background-colors"],rowHoverBackgroundColor:Tg.a["row-hover-bg"],selectionColor:Tg.a["selection-color"],selectionOutlineColor:Tg.a["selection-outline-color"],selectionOutlineCasingColor:Tg.a["selection-outline-casing-color"],selectedRowHoverBackgroundColor:Tg.a["selected-row-hover-bg"],scrollBarBackgroundColor:Tg.a["scroll-bar-bg"],scrollBarHoverBackgroundColor:Tg.a["scroll-bar-hover-bg"],scrollBarCasingColor:Tg.a["scroll-bar-casing-color"],scrollBarCornerColor:Tg.a["scroll-bar-corner-color"],scrollBarColor:Tg.a["scroll-bar-color"],scrollBarHoverColor:Tg.a["scroll-bar-hover-color"],scrollBarActiveColor:Tg.a["scroll-bar-active-color"],textColor:Tg.a["text-color"],positiveNumberColor:Tg.a["positive-number-color"],negativeNumberColor:Tg.a["negative-number-color"],zeroNumberColor:Tg.a["zero-number-color"],dateColor:Tg.a["date-color"],pendingTextColor:Tg.a["pending-text-color"],errorTextColor:Tg.a["error-text-color"],filterBarActiveBackgroundColor:Tg.a["filter-bar-active-bg"],filterBarExpandedBackgroundColor:Tg.a["filter-bar-expanded-bg"],filterBarExpandedActiveBackgroundColor:Tg.a["filter-bar-expanded-active-bg"],filterBarExpandedActiveCellBackgroundColor:Tg.a["filter-bar-expanded-active-cell-bg"],filterBarSeparatorColor:Tg.a["filter-bar-separator-color"],filterBarActiveColor:Tg.a["filter-bar-active-color"],filterBarErrorColor:Tg.a["filter-bar-error-color"],filterIconColor:Tg.a["filter-icon-color"],scrimColor:Tg.a["scrim-color"],contextMenuSortIconColor:Tg.a["context-menu-sort-icon-color"],contextMenuReverseIconColor:Tg.a["context-menu-reverse-icon-color"],allowRowResize:!1,autoSelectRow:!0,gridColumnColor:null,gridRowColor:null,groupedColumnDividerColor:Tg.a["grouped-column-divider-color"],columnHoverBackgroundColor:null,headerHorizontalPadding:12,scrollBarSize:13,scrollBarHoverSize:16,minScrollHandleSize:24,rowHeight:19,columnWidth:100,rowHeaderWidth:0,rowFooterWidth:60,columnHeaderHeight:30,filterBarHeight:30,filterBarCollapsedHeight:5,sortHeaderBarHeight:2,reverseHeaderBarHeight:4,filterBarHorizontalPadding:4,scrimBlurSize:25,minScrimTransitionTime:150,maxScrimTransitionTime:350,scrollSnapToRow:!0,linkerColumnHoverBackgroundColor:Tg.a["linker-column-hover-bg"],treeLineColor:Tg.a["tree-line-color"],treeMarkerColor:Tg.a["tree-marker-color"],treeMarkerHoverColor:Tg.a["tree-marker-hover-color"],floatingGridColumnColor:null,floatingGridRowColor:Tg.a["floating-grid-row-color"],floatingRowBackgroundColors:Tg.a["floating-row-background-colors"],floatingDividerInnerColor:Tg.a["floating-divider-inner-color"],floatingDividerOuterColor:Tg.a["floating-divider-outer-color"]});n(1284);var Mg=p.module("ColumnStatistics"),Ng={SIZE:"Number of Rows"};class Dg extends i.Component{static getStatsLabel(e){var t;return null!==(t=Ng[e])&&void 0!==t?t:e.split(" ").map((e=>e[0].toUpperCase()+e.substr(1).toLowerCase())).join(" ")}constructor(e){super(e),this.handleError=this.handleError.bind(this),this.handleGenerateStatistics=this.handleGenerateStatistics.bind(this),this.handleStatistics=this.handleStatistics.bind(this),this.handleCopyHeader=this.handleCopyHeader.bind(this),this.cancelablePromise=null,this.state={error:null,loading:!1,statistics:null,numRows:0,copied:!1}}componentDidMount(){this.maybeGenerateStatistics()}componentWillUnmount(){this.cancelablePromise&&this.cancelablePromise.cancel()}handleCopyHeader(){this.setState({copied:!0})}maybeGenerateStatistics(){var{model:e}=this.props,t=e.rowCount;this.setState({numRows:t}),e.isColumnStatisticsAvailable?t<Dg.AUTO_GENERATE_LIMIT&&this.handleGenerateStatistics():this.setState({loading:!1})}handleGenerateStatistics(){this.setState({loading:!0});var{column:e,model:t}=this.props;this.cancelablePromise=Va.makeCancelable(t.columnStatistics(e)),this.cancelablePromise.then(this.handleStatistics).catch(this.handleError)}handleStatistics(e){Mg.debug("Received statistics",e);var{model:t,onStatistics:n}=this.props,i=[];e.statisticsMap.forEach(((t,n)=>{i.push({operation:Dg.getStatsLabel(n),value:t,type:e.getType(n)})})),e.uniqueValues.forEach(((e,t)=>{i.push({operation:t,className:"column-statistics-unique-value",value:e,type:"long"})})),this.setState({loading:!1,statistics:i,numRows:t.rowCount}),n()}handleError(e){e&&e.isCanceled?Mg.debug("Called handleError on a cancelled promise result"):(Mg.error("Error generating statistics",e),this.setState({error:e,loading:!1,statistics:null}))}render(){var{column:e,model:t}=this.props,{error:n,loading:i,statistics:s,numRows:r,copied:o}=this.state,l=!i&&null==n&&null==s&&t.isColumnStatisticsAvailable,c=[],h=e.type.substring(e.type.lastIndexOf(".")+1),d=null===e.description?null:e.description;if(null!=s)for(var u=0;u<s.length;u+=1){var{operation:m,className:p,value:g,type:v}=s[u],f=v?t.displayString(g,v):t.displayString(g,e.type,e.name),b=a.a.createElement(a.a.Fragment,{key:m},a.a.createElement("div",{className:qe()("column-statistic-operation",p)},m),a.a.createElement("div",{className:"column-statistic-value"},f));c.push(b)}var C=t.hasExpandableRows?"Expanded Rows":"Number of Rows",S=t.displayString(r,"long"),E=t.getColumnIndexByName(e.name);return a.a.createElement("div",{className:"column-statistics"},a.a.createElement("div",{className:"column-statistics-title"},e.name,a.a.createElement("span",{className:"column-statistics-type"},"\xa0(",h,")"),a.a.createElement(gh,{kind:"ghost",className:"column-statistics-copy",icon:o?At:dt,onClick:()=>{je.copyToClipboard(e.name).then(this.handleCopyHeader).catch((e=>Mg.error("Unable to column name",e)))},tooltip:o?"Copied text":"Copy column name"})),d&&a.a.createElement("div",{className:"column-statistics-description"},d),!t.isColumnMovable(E)&&a.a.createElement("div",{className:"column-statistics-status"},a.a.createElement(Ke.a,{icon:t.isColumnFrozen(E)?vn:Rt,className:"mr-1"}),t.isColumnFrozen(E)?"Frozen":"Not movable"),a.a.createElement("div",{className:"column-statistics-grid"},null==s&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"column-statistic-operation"},C),a.a.createElement("div",{className:"column-statistic-value"},S)),c),l&&a.a.createElement("button",{type:"button",className:"btn btn-link px-0",onClick:this.handleGenerateStatistics},"Generate Stats"),n&&a.a.createElement("div",{className:"error-message"},"".concat(n)),s&&!i&&a.a.createElement("button",{type:"button",className:"btn btn-link px-0",onClick:this.handleGenerateStatistics},a.a.createElement(Ke.a,{icon:On,className:"mr-1"}),"Refresh"),i&&a.a.createElement("div",{className:"column-statistics-loading"},a.a.createElement(Yn,{className:"mr-2"}),"Calculating Stats..."))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Dg,"AUTO_GENERATE_LIMIT",1e5),Dg.propTypes={model:pi.a.instanceOf(Cu).isRequired,column:Ma.Column.isRequired,onStatistics:pi.a.func.isRequired};var xg=Dg,Rg=(n(1273),p.module("AdvancedFilterCreatorFilterItem"));class Ig extends i.PureComponent{static getLabelForTextFilter(e){switch(e){case ns.eq:return"is exactly";case ns.eqIgnoreCase:return"is exactly (ignore case)";case ns.notEq:return"is not exactly";case ns.notEqIgnoreCase:return"is not exactly (ignore case)";case ns.contains:return"contains";case ns.notContains:return"does not contain";case ns.startsWith:return"starts with";case ns.endsWith:return"ends with";default:return Rg.warn("Unrecognized text filter type",e),""}}static getLabelForNumberFilter(e){switch(e){case ns.eq:return"is equal to";case ns.notEq:return"is not equal to";case ns.greaterThan:return"greater than";case ns.greaterThanOrEqualTo:return"greater than or equal to";case ns.lessThan:return"less than";case ns.lessThanOrEqualTo:return"less than or equal to";default:return Rg.warn("Unrecognized number filter type",e),""}}static getLabelForDateFilter(e){switch(e){case ns.eq:return"date is";case ns.notEq:return"date is not";case ns.notEqIgnoreCase:case ns.greaterThan:return"date is after";case ns.greaterThanOrEqualTo:return"date is after or equal";case ns.lessThan:return"date is before";case ns.lessThanOrEqualTo:return"date is before or equal";default:return Rg.warn("Unrecognized date filter type",e),""}}static getLabelForBooleanFilter(e){switch(e){case ns.isTrue:return"Is True";case ns.isFalse:return"Is False";case ns.isNull:return"Is Null";default:return Rg.warn("Unrecognized boolean filter type",e),""}}static getLabelForFilter(e,t){return cs.isNumberType(e)||cs.isCharType(e)?Ig.getLabelForNumberFilter(t):cs.isTextType(e)?Ig.getLabelForTextFilter(t):cs.isDateType(e)?Ig.getLabelForDateFilter(t):cs.isBooleanType(e)?Ig.getLabelForBooleanFilter(t):(Rg.warn("Unrecognized column type: ",e),"")}constructor(e){super(e),this.handleDelete=this.handleDelete.bind(this),this.handleTypeChange=this.handleTypeChange.bind(this),this.handleValueChange=this.handleValueChange.bind(this),this.typeDropdown=null;var{selectedType:t,value:n,filterTypes:i}=e;this.state={selectedType:t||i[0],value:n}}componentDidMount(){this.typeDropdown.focus()}componentDidUpdate(e){var{selectedType:t,value:n}=this.props;e.selectedType===t&&e.value===n||this.setState({selectedType:t,value:n})}handleTypeChange(e){Rg.debug2("typeChange");var t=e.target.value;this.setState({selectedType:t});var{onChange:n}=this.props,{value:i}=this.state;null!=i&&i.length>0&&n(t,i)}handleValueChange(e){Rg.debug2("valueChange");var{value:t}=e.target;this.setState({value:t});var{onChange:n}=this.props,{selectedType:i}=this.state;null!=i&&i.length>0&&n(i,t)}handleDelete(){Rg.debug("delete");var{onDelete:e}=this.props;e()}render(){for(var{column:e,filterTypes:t}=this.props,{selectedType:n,value:i}=this.state,s=!cs.isBooleanType(e.type),r=[],o=0;o<t.length;o+=1){var l=t[o],c=Ig.getLabelForFilter(e.type,l),h=a.a.createElement("option",{key:l,value:l},c);r.push(h)}return a.a.createElement("div",{className:"advanced-filter-creator-filter-item"},a.a.createElement("div",{className:"form-row"},a.a.createElement("div",{className:"form-group col"},a.a.createElement("select",{className:"form-control custom-select",value:n,onChange:this.handleTypeChange,ref:e=>{this.typeDropdown=e}},r)),s&&a.a.createElement("div",{className:"form-group col"},a.a.createElement("div",{className:"input-group"},a.a.createElement("input",{type:"text",className:"form-control",placeholder:"Enter value",value:i,onChange:this.handleValueChange}))),a.a.createElement("div",{className:"form-group col-1 px-0"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon w-100 h-100 p-0 m-0",onClick:this.handleDelete},a.a.createElement(Ke.a,{icon:$t}),a.a.createElement(Ol,null,"Remove Filter")))))}}Ig.propTypes={column:pi.a.shape({type:pi.a.string}).isRequired,filterTypes:pi.a.arrayOf(pi.a.string).isRequired,onChange:pi.a.func.isRequired,onDelete:pi.a.func.isRequired,selectedType:pi.a.string,value:pi.a.string},Ig.defaultProps={selectedType:"",value:""};var Lg=Ig;n(1276);function Fg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class kg extends i.PureComponent{constructor(e){super(e),Fg(this,"list",void 0),Fg(this,"topRow",void 0),Fg(this,"bottomRow",void 0),Fg(this,"getCachedItem",Lr()(((e,t,n,i,s,r,o)=>{var l={height:s},c=null!=i?i:n;return a.a.createElement("li",{className:"value-list-item",style:l,key:t},a.a.createElement(Ed,{checked:r,disabled:o,onChange:()=>this.handleSelect(e)},c))}),{max:1e3})),Fg(this,"getCachedItems",Lr()(((e,t,n,i)=>{for(var a=[],s=0;s<e.length;s+=1){var r=e[s],{value:o,displayValue:l,isSelected:c}=r,h=n+s,d=h,u=this.getCachedItem(h,d,o,l,t,c,i);a.push(u)}return a}),{max:1})),this.handleScroll=this.handleScroll.bind(this),this.handleSelect=this.handleSelect.bind(this),this.list=a.a.createRef(),this.topRow=null,this.bottomRow=null}componentDidMount(){this.sendViewportUpdate()}componentDidUpdate(){this.sendViewportUpdate()}handleScroll(){this.sendViewportUpdate()}handleSelect(e){var{items:t,offset:n,onSelect:i}=this.props,a=e-n;if(a>=0&&a<t.length){var s=t[a],{value:r}=s;i(e,r)}else i(e,null)}sendViewportUpdate(){if(this.list.current&&0!==this.list.current.clientHeight){var{onViewportChange:e,rowHeight:t}=this.props,n=this.list.current.scrollTop,i=n+this.list.current.clientHeight,a=Math.floor(n/t),s=Math.ceil(i/t);this.topRow===a&&this.bottomRow===s||(this.topRow=a,this.bottomRow=s,e(a,s))}}render(){var{disabled:e,items:t,itemCount:n,offset:i,rowHeight:s}=this.props,r=this.getCachedItems(t,s,i,e);return a.a.createElement("div",{className:"select-value-list-scroll-pane h-100 w-100",onScroll:this.handleScroll,ref:this.list},a.a.createElement("div",{className:"select-value-list",style:{height:n*s}},a.a.createElement("ol",{className:"select-value-list-content",style:{position:"absolute",height:t.length*s,top:i*s,left:0}},r)))}}Fg(kg,"defaultProps",{disabled:!1,rowHeight:21});var Ag=kg,Pg=p.module("AdvancedFilterCreatorSelectValueList");class _g extends i.PureComponent{static indexOf(e,t){for(var n=0;n<t.length;n+=1){var i=t[n];if(i===e||null!=i&&i.valueOf&&null!=e&&e.valueOf&&i.valueOf()===e.valueOf())return n}return-1}constructor(e){super(e),this.handleSelect=this.handleSelect.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.handleSelectionUpdate=this.handleSelectionUpdate.bind(this),this.handleTableUpdate=this.handleTableUpdate.bind(this),this.list=null;var{selectedValues:t}=this.props;this.state={itemCount:0,items:[],offset:0,selectedValues:t,isLoading:!0}}componentDidMount(){var{table:e}=this.props;this.startListening(e)}componentDidUpdate(e){var{filters:t,invertSelection:n,selectedValues:i,table:a}=this.props;e.table!==a&&(this.stopListening(e.table),this.startListening(a),this.resetViewport()),e.invertSelection!==n&&this.setState({selectedValues:[]},this.handleSelectionUpdate),e.selectedValues!==i&&this.setState({selectedValues:i},this.handleSelectionUpdate),e.filters!==t&&(a.applyFilter(t),this.resetViewport())}componentWillUnmount(){this.stopListening()}handleSelect(e,t){var{invertSelection:n}=this.props,{selectedValues:i}=this.state;i=[].concat(i);var a=_g.indexOf(t,i);a>=0?i.splice(a,1):i.push(t);var s=a<0;n&&(s=!s);var{offset:r}=this.state,{items:o}=this.state;o=[].concat(o);var l=e-r;l>=0&&l<o.length&&(o[l].isSelected=s),this.setState({items:o,selectedValues:i});var{onChange:c}=this.props;c(i,n)}handleViewportChange(e,t){this.updateViewport(e,t)}handleSelectionUpdate(){this.updateItemSelection()}handleTableUpdate(e){for(var t=e.detail,{offset:n}=t,i=[],{table:a,formatter:s}=this.props,r=a.columns[0],o=0;o<t.rows.length;o+=1){var l=t.rows[o].get(r),c=s.getFormattedString(l,r.type,r.name),h=this.isValueSelected(l);i.push({displayValue:c,value:l,isSelected:h})}Pg.debug2("Received table update:",n,i.length);var d=a.size;this.setState({itemCount:d,items:i,offset:n,isLoading:!1})}isValueSelected(e){var{invertSelection:t}=this.props,{selectedValues:n}=this.state,i=_g.indexOf(e,n);return t?i<0:i>=0}startListening(e){null!=e&&e.addEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate)}stopListening(e){null!=e&&e.removeEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate)}resetViewport(){this.list&&this.updateViewport(this.list.topRow,this.list.bottomRow,!0)}updateItemSelection(){var{items:e}=this.state;e=[].concat(e);for(var t=0;t<e.length;t+=1){var n=e[t],{value:i}=n;n.isSelected=this.isValueSelected(i)}this.setState({items:e})}updateViewport(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],{table:i}=this.props;if(null!=i){n&&this.setState({isLoading:!0});var a=t-e+1,s=Math.max(0,e-3*a),r=Math.max(s,t+3*a);Pg.debug2("Setting viewport",s,",",r),i.setViewport(s,r,null)}}render(){var{offset:e,isLoading:t,items:n,itemCount:i}=this.state;return a.a.createElement("div",{className:"select-value-list-wrapper"},a.a.createElement(Ag,{itemCount:i,items:n,offset:e,onSelect:this.handleSelect,onViewportChange:this.handleViewportChange,ref:e=>{this.list=e}}),a.a.createElement(We.CSSTransition,{in:t,timeout:250,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"loading-list"},a.a.createElement(Yn,{className:"loading-spinner-large"}))))}}_g.propTypes={table:pi.a.shape({addEventListener:pi.a.func,removeEventListener:pi.a.func,applyFilter:pi.a.func,columns:pi.a.arrayOf(pi.a.shape({name:pi.a.string,type:pi.a.string})),setViewport:pi.a.func,size:pi.a.number}),invertSelection:pi.a.bool,selectedValues:pi.a.arrayOf(pi.a.any),onChange:pi.a.func,filters:pi.a.arrayOf(Ma.FilterCondition).isRequired,formatter:pi.a.instanceOf(Hs).isRequired},_g.defaultProps={table:null,invertSelection:!0,selectedValues:[],onChange:()=>{}};var Hg=_g;n(1275);class jg extends i.PureComponent{constructor(e){super(e),this.handleSelectAllClick=this.handleSelectAllClick.bind(this),this.handleClearAllClick=this.handleClearAllClick.bind(this),this.handleListChange=this.handleListChange.bind(this),this.handleSearchChange=this.handleSearchChange.bind(this),this.handleUpdateFilterTimeout=this.handleUpdateFilterTimeout.bind(this),this.searchTablePromise=null,this.updateFilterTimer=null;var{invertSelection:t,selectedValues:n}=e;this.state={error:null,filters:[],invertSelection:t,selectedValues:n,searchText:"",table:null}}componentDidMount(){this.initSearchTable()}componentDidUpdate(e,t){var{invertSelection:n,selectedValues:i,table:a}=this.props;e.table!==a&&this.initSearchTable(),e.invertSelection!==n&&this.setState({invertSelection:n}),e.selectedValues!==i&&this.setState({selectedValues:i});var{table:s,searchText:r}=this.state;s!==t.table&&null!=t.table&&t.table.close(),r!==t.searchText&&this.startUpdateFilterTimer()}componentWillUnmount(){var{table:e}=this.state;null!=e&&e.close(),this.searchTablePromise=null,this.stopUpdateFilterTimer()}getColumnName(){var{table:e}=this.props;return null!=e?e.columns[0].name:""}getDisplayedValuesCount(){var{invertSelection:e,selectedValues:t,table:n}=this.state;return null==n?null:e?n.totalSize-t.length:t.length}getDisplayedValueText(){var e=this.getDisplayedValuesCount(),{table:t}=this.state,{formatter:n}=this.props;if(null!=e&&null!=t){var i=n.getFormattedString(e,"long"),a=n.getFormattedString(t.totalSize,"long"),s="";return e<1e6&&(s="Displaying "),"".concat(s).concat(i," of ").concat(a)}return null}initSearchTable(){var{table:e}=this.props;if(null!=e){var t=e.copy();this.searchTablePromise=t,this.searchTablePromise.then((e=>{this.searchTablePromise===t?(this.setState({table:e}),this.searchTablePromise=null):e.close()}))}}handleListChange(e,t){this.setState({selectedValues:e,invertSelection:t});var{onChange:n}=this.props;n(e,t)}handleSearchChange(e){var t=e.target.value;this.setState({searchText:t})}handleSelectAllClick(){this.resetSelection(!0)}handleClearAllClick(){this.resetSelection(!1)}handleUpdateFilterTimeout(){this.updateFilterTimer=null,this.updateTableFilter()}resetSelection(e){var t=[];this.setState({invertSelection:e,selectedValues:t});var{onChange:n}=this.props;n(t,e)}startUpdateFilterTimer(){this.stopUpdateFilterTimer(),this.updateFilterTimer=setTimeout(this.handleUpdateFilterTimeout,jg.searchDebounceTime)}stopUpdateFilterTimer(){this.updateFilterTimer&&(clearTimeout(this.updateFilterTimer),this.updateFilterTimer=null)}updateTableFilter(){var{table:e,searchText:t}=this.state,{timeZone:n}=this.props,i=e.columns[0],a=[],s=null;if(t.length>0){var r=null;null!=(r=cs.isCharType(i.type)?cs.makeQuickFilter(i,t):cs.isTextType(i.type)?cs.makeQuickFilter(i,"~".concat(t),n):cs.makeQuickFilter(i,">=".concat(t),n))?a.push(r):s="Invalid search text"}this.setState({filters:a,error:s})}render(){var{error:e,filters:t,invertSelection:n,selectedValues:i,searchText:s,table:r}=this.state,{formatter:o,showSearch:l}=this.props,c=this.getColumnName(),h=this.getDisplayedValueText(),d=c?"Find ".concat(c,"..."):"";return a.a.createElement("div",{className:"advanced-filter-creator-select-value"},a.a.createElement("div",{className:l?"form-group":""},a.a.createElement("label",{htmlFor:"advanced-filter-creator-select-value-input"},"Select Values"),l&&a.a.createElement("input",{type:"text",className:qe()("form-control",{"is-invalid":null!=e}),id:"advanced-filter-creator-select-value-input",placeholder:d,value:s,onChange:this.handleSearchChange})),a.a.createElement(Hg,{table:r,filters:t,invertSelection:n,selectedValues:i,formatter:o,onChange:this.handleListChange}),a.a.createElement("div",{className:"advanced-filter-creator-select-meta-row"},a.a.createElement("div",null,a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.handleSelectAllClick},"Select All"),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.handleClearAllClick},"Clear")),a.a.createElement(We.CSSTransition,{in:null!=h,timeout:250,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"row-count-info"},h))))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(jg,"searchDebounceTime",250),jg.propTypes={table:pi.a.shape({close:pi.a.func,columns:pi.a.arrayOf(pi.a.shape({name:pi.a.string})),copy:pi.a.func,totalSize:pi.a.number}),invertSelection:pi.a.bool,selectedValues:pi.a.arrayOf(pi.a.any),formatter:pi.a.instanceOf(Hs).isRequired,onChange:pi.a.func,showSearch:pi.a.bool,timeZone:pi.a.string.isRequired},jg.defaultProps={table:null,invertSelection:!0,selectedValues:[],onChange:()=>{},showSearch:!0};var Vg=jg;n(1274);function zg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ug=p.module("AdvancedFilterCreator");class Bg extends i.PureComponent{constructor(e){super(e),zg(this,"getFilterTypes",Object(ua.a)((e=>cs.getFilterTypes(e)))),this.handleAddAnd=this.handleAddAnd.bind(this),this.handleAddOr=this.handleAddOr.bind(this),this.handleChangeFilterOperator=this.handleChangeFilterOperator.bind(this),this.handleDone=this.handleDone.bind(this),this.handleFilterChange=this.handleFilterChange.bind(this),this.handleFilterDelete=this.handleFilterDelete.bind(this),this.handleSelectValueChange=this.handleSelectValueChange.bind(this),this.handleReset=this.handleReset.bind(this),this.handleSortDown=this.handleSortDown.bind(this),this.handleSortUp=this.handleSortUp.bind(this),this.handleSubmit=this.handleSubmit.bind(this),this.handleFocusTrapStart=this.handleFocusTrapStart.bind(this),this.handleFocusTrapEnd=this.handleFocusTrapEnd.bind(this),this.handleUpdateTimeout=this.handleUpdateTimeout.bind(this),this.focusTrapContainer=a.a.createRef(),this.debounceTimeout=null,this.filterKey=0,this.valuesTablePromise=null;var{options:t}=e,{filterItems:n,filterOperators:i,invertSelection:s,selectedValues:r}=t;null==n&&(n=[this.makeFilterItem()]),null==i&&(i=[]),null==s&&(s=!0),null==r&&(r=[]),this.state={filterItems:n,filterOperators:i,invertSelection:s,selectedValues:r,valuesTableError:null,valuesTable:null}}componentDidMount(){this.initValuesTable()}componentWillUnmount(){null!=this.debounceTimeout&&(clearTimeout(this.debounceTimeout),this.sendUpdate()),null!=this.valuesTablePromise&&this.valuesTablePromise.cancel()}getFilterChangeHandler(e){return this.handleFilterChange.bind(this,e)}getFilterDeleteHandler(e){return this.handleFilterDelete.bind(this,e)}initValuesTable(){var{model:e,column:t}=this.props;e.isValuesTableAvailable?(this.valuesTablePromise=cs.makeCancelableTablePromise(e.valuesTable(t)),this.valuesTablePromise.then((e=>{var t=e.columns[0].sort().asc();e.applySort([t]),this.setState({valuesTable:e})})).catch((e=>{Va.isCanceled(e)||(Ug.error("Unable to open values table",e),this.setState({valuesTableError:e}))}))):Ug.debug("No values table for this model, just ignore")}handleFocusTrapEnd(){this.focusTrapContainer.current.querySelectorAll("button,select,input,textarea")[0].focus()}handleFocusTrapStart(){var e=this.focusTrapContainer.current.querySelectorAll("button,select,input,textarea");e[e.length-1].focus()}handleAddAnd(){var{filterItems:e,filterOperators:t}=this.state;e=e.concat(this.makeFilterItem()),t=t.concat(ss.and),this.setState({filterItems:e,filterOperators:t})}handleAddOr(){var{filterItems:e,filterOperators:t}=this.state;e=e.concat(this.makeFilterItem()),t=t.concat(ss.or),this.setState({filterItems:e,filterOperators:t})}handleChangeFilterOperator(e){var t=parseInt(e.target.dataset.index,10),{operator:n}=e.target.dataset,{filterOperators:i}=this.state;(i=[].concat(i))[t]=n,this.setState({filterOperators:i}),this.startUpdateTimer()}handleFilterChange(e,t,n){var{filterItems:i}=this.state;i=[].concat(i);var{key:a}=i[e];i[e]={key:a,selectedType:t,value:n},this.setState({filterItems:i}),this.startUpdateTimer()}handleFilterDelete(e){var{filterItems:t,filterOperators:n}=this.state;t=[].concat(t),n=[].concat(n),e<t.length&&t.splice(e,1),e<n.length?n.splice(e,1):e===n.length&&n.splice(n.length-1,1),0===t.length&&t.push(this.makeFilterItem()),this.setState({filterItems:t,filterOperators:n}),this.startUpdateTimer()}handleSelectValueChange(e,t){this.setState({selectedValues:e,invertSelection:t}),this.startUpdateTimer()}handleReset(){Ug.debug("Resetting Advanced Filter"),this.setState({filterItems:[this.makeFilterItem()],filterOperators:[],selectedValues:[],invertSelection:!0}),this.startUpdateTimer()}handleSortDown(e){var t=je.isModifierKeyDown(e);this.sortTable(cs.sortDirection.descending,t)}handleSortUp(e){var t=je.isModifierKeyDown(e);this.sortTable(cs.sortDirection.ascending,t)}handleSubmit(e){Ug.debug("Submitting Advanced Filter"),this.stopUpdateTimer(),this.sendUpdate(),e.preventDefault()}handleDone(e){Ug.debug("Submitting and Closing Advanced Filter"),this.stopUpdateTimer(),this.sendUpdate();var{onDone:t}=this.props;t(),e.preventDefault()}handleUpdateTimeout(){this.debounceTimeout=null,this.sendUpdate()}makeFilterItem(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.filterKey;return e&&(this.filterKey+=1),{selectedType:"",value:"",key:t}}shouldShowAddFilter(){var{filterItems:e}=this.state;if(0===e.length)return!1;var t=e[e.length-1],{selectedType:n,value:i}=t;return null!=n&&n.length>0&&null!=i&&i.length>0}sortTable(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{column:n,onSortChange:i}=this.props;i(n,e,t)}startUpdateTimer(){this.stopUpdateTimer(),this.debounceTimeout=setTimeout(this.handleUpdateTimeout,Bg.debounceFilterUpdate)}stopUpdateTimer(){this.debounceTimeout&&(clearTimeout(this.debounceTimeout),this.debounceTimeout=null)}sendUpdate(){var{filterItems:e,filterOperators:t,invertSelection:n,selectedValues:i}=this.state,{column:a,onFilterChange:s,model:r}=this.props,{formatter:o}=r,l={filterItems:e,filterOperators:t,invertSelection:n,selectedValues:i};s(a,cs.makeAdvancedFilter(a,l,o.timeZone),l)}render(){var{column:e,model:t,sortDirection:n,formatter:i}=this.props,{filterItems:s,filterOperators:r,invertSelection:o,selectedValues:l,valuesTable:c,valuesTableError:h}=this.state,{isValuesTableAvailable:d}=t,u=cs.isBooleanType(e.type),m=cs.isDateType(e.type),p=this.getFilterTypes(e.type),g=e.type.substring(e.type.lastIndexOf(".")+1),v=[];if(!u&&p.length)for(var f=0;f<s.length;f+=1){var b=s[f],{key:C,selectedType:S,value:E}=b,w=a.a.createElement(Lg,{key:C,column:e,filterTypes:p,onChange:this.getFilterChangeHandler(f),onDelete:this.getFilterDeleteHandler(f),selectedType:S,value:E});if(v.push(w),f<r.length){var y=r[f]===ss.and,T=a.a.createElement("div",{key:"filterOperator".concat(C),className:"form-row justify-content-end advanced-filter-creator-filter-operator"},a.a.createElement("button",{type:"button",className:qe()("btn btn-link filter-operator",{active:y}),onClick:this.handleChangeFilterOperator,"data-index":f,"data-operator":ss.and},"AND"),a.a.createElement("button",{type:"button",className:qe()("btn btn-link filter-operator",{active:!y}),onClick:this.handleChangeFilterOperator,"data-index":f,"data-operator":ss.or},"OR"));v.push(T)}}var O=this.shouldShowAddFilter(),M=a.a.createElement("div",{key:"addFilterItem",className:qe()("form-row justify-content-end add-filter-item",{hidden:!O})},a.a.createElement("span",{className:"text-muted"},a.a.createElement(Ke.a,{icon:wn})),a.a.createElement("button",{type:"button",className:"btn btn-link btn-filter-item",onClick:this.handleAddAnd,disabled:!O},"AND",a.a.createElement(Ol,null,"Add filter with AND")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-filter-item",onClick:this.handleAddOr,disabled:!O},"OR",a.a.createElement(Ol,null,"Add filter with OR")));return v.push(M),a.a.createElement("div",{className:"advanced-filter-creator",role:"presentation"},a.a.createElement("div",{tabIndex:"0",onFocus:this.handleFocusTrapStart}),a.a.createElement("form",{onSubmit:this.handleSubmit,ref:this.focusTrapContainer},a.a.createElement("div",{className:"title-bar"},a.a.createElement("h6",{className:"advanced-filter-title"},"Advanced Filters"),a.a.createElement("div",{className:"advanced-filter-menu-buttons"},a.a.createElement("button",{type:"button",className:qe()("btn btn-link btn-link-icon sort-operator",{active:n===cs.sortDirection.descending}),onClick:this.handleSortDown},a.a.createElement(Ke.a,{icon:Rn}),a.a.createElement(Ol,null,"Sort ",e.name," Descending")),a.a.createElement("button",{type:"button",className:qe()("btn btn-link btn-link-icon sort-operator",{active:n===cs.sortDirection.ascending}),onClick:this.handleSortUp},a.a.createElement(Ke.a,{rotation:180,icon:Rn}),a.a.createElement(Ol,null,"Sort ",e.name," Ascending")))),a.a.createElement("hr",null),a.a.createElement("div",{className:"advanced-filter-column-name"},e.name,"\xa0",a.a.createElement("span",{className:"column-type"},"(",g,")")),v,d&&!h&&a.a.createElement(a.a.Fragment,null,!u&&a.a.createElement("hr",null),a.a.createElement("div",{className:"form-group"},a.a.createElement(Vg,{table:c,onChange:this.handleSelectValueChange,invertSelection:o,selectedValues:l,formatter:i,showSearch:!m,timeZone:i.timeZone}))),a.a.createElement("div",{className:"form-row justify-content-end"},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary mr-2",onClick:this.handleReset},"Reset"),a.a.createElement("button",{type:"button",className:"btn btn-primary",onClick:this.handleDone},"Done"))),a.a.createElement("div",{tabIndex:"0",onFocus:this.handleFocusTrapEnd}))}}zg(Bg,"debounceFilterUpdate",250),Bg.propTypes={model:pi.a.instanceOf(Cu).isRequired,column:pi.a.shape({name:pi.a.string,type:pi.a.string}).isRequired,onFilterChange:pi.a.func.isRequired,onSortChange:pi.a.func.isRequired,onDone:pi.a.func.isRequired,options:pi.a.shape({filterItems:pi.a.arrayOf(pi.a.shape({})),filterOperators:pi.a.arrayOf(pi.a.shape({})),invertSelection:pi.a.bool,selectedValues:pi.a.arrayOf(pi.a.any)}),sortDirection:pi.a.string,formatter:pi.a.instanceOf(Hs).isRequired},Bg.defaultProps={options:{filterItems:null,filterOperators:null,invertSelection:!0,selectedValues:[]},sortDirection:null};var Wg,Gg=Bg;!function(e){e.ADVANCED_SETTINGS="ADVANCED_SETTINGS",e.AGGREGATIONS="AGGREGATIONS",e.AGGREGATION_EDIT="AGGREGATIONS_EDIT",e.CHART_BUILDER="CHART_BUILDER",e.CUSTOM_COLUMN_BUILDER="CUSTOM_COLUMN_BUILDER",e.QUICK_FILTERS="QUICK_FILTERS",e.ROLLUP_ROWS="ROLLUP_ROWS",e.SEARCH_BAR="SEARCH_BAR",e.SELECT_DISTINCT="SELECT_DISTINCT",e.TABLE_EXPORTER="TABLE_EXPORTER",e.VISIBILITY_ORDERING_BUILDER="VISIBILITY_ORDERING_BUILDER"}(Wg||(Wg={}));var qg=Wg,Kg=n(141);n(1280);function Yg(){return Yg=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Yg.apply(this,arguments)}function Xg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Zg=p.module("VisibilityOrderingBuilder");class $g extends i.Component{constructor(e){super(e),Xg(this,"getFirstMovableIndex",Lr()(((e,t)=>{for(var n=0;n<t.length;n+=1)if(e.isColumnMovable(n))return n;return null}))),Xg(this,"getLastMovableIndex",Lr()(((e,t)=>{for(var n=t.length-1;n>=0;n-=1)if(e.isColumnMovable(n))return n;return null}))),Xg(this,"renderImmovableItem",Lr()((e=>a.a.createElement("div",{className:"visibility-ordering-list-item immovable",key:e},a.a.createElement("div",{className:"column-item"},a.a.createElement("span",{className:"column-name"},e)))))),Xg(this,"renderVisibilityOrderingItem",Lr()(((e,t,n,i,s,r,o,l)=>a.a.createElement(Kg.b,{draggableId:"".concat(t),index:n,key:e,disableInteractiveElementBlocking:!0},(n=>a.a.createElement("div",Yg({className:"visibility-ordering-list-item",ref:n.innerRef},n.draggableProps),a.a.createElement("button",{type:"button",className:"visibility btn btn-link btn-link-icon",onMouseDown:e=>{this.handleVisibilityDraggingStart(t,i?$g.VISIBILITY_OPTIONS.SHOW:$g.VISIBILITY_OPTIONS.HIDE,e)},onMouseEnter:e=>{this.handleMouseEnter(t,e)},onMouseUp:e=>{this.handleVisibilityDraggingEnd(e)},onClick:e=>{this.handleItemClick(t,e,!1)},onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(this.handleVisibilityKeyDown(t,i?$g.VISIBILITY_OPTIONS.SHOW:$g.VISIBILITY_OPTIONS.HIDE),e.stopPropagation(),e.preventDefault())}},a.a.createElement(Ke.a,{icon:i?on:ln})),a.a.createElement("div",Yg({role:"menuitem",tabIndex:"0",className:qe()("ordering column-item",{isSelected:s},{isDragging:r},{isDragged:o},{"two-dragged":2===l},{"multiple-dragged":l>2}),onClick:e=>{this.handleItemClick(t,e)}},n.dragHandleProps),a.a.createElement("span",{className:"column-name"},e),a.a.createElement("div",null,l&&a.a.createElement("span",{className:"number-badge"},l),a.a.createElement(Ol,null,"Drag to re-order"),a.a.createElement(Ke.a,{icon:yt}))))))))),this.handleSearchInputChange=this.handleSearchInputChange.bind(this),this.debouncedSearchColumns=pa()(this.searchColumns.bind(this),150),this.handleOrderDraggingStart=this.handleOrderDraggingStart.bind(this),this.handleOrderDraggingEnd=this.handleOrderDraggingEnd.bind(this),this.state={selectedColumns:[],lastSelectedColumns:[],isDraggingVisibility:!1,visibilityDraggingOption:null,visibilityDraggingStartColumn:null,isDraggingOrder:!1,orderDraggingColumn:null,searchFilter:""},this.list=null}componentWillUnmount(){this.debouncedSearchColumns.cancel()}resetVisibilityOrdering(){var{model:e,onColumnVisibilityChanged:t,onMovedColumnsChanged:n}=this.props,{columns:i}=e;t(i.map((t=>e.getColumnIndexByName(t.name))),$g.VISIBILITY_OPTIONS.SHOW),this.setState({selectedColumns:[],lastSelectedColumns:[],searchFilter:""}),n([])}resetSelection(){var{isDraggingOrder:e}=this.state;e||this.setState({selectedColumns:[],lastSelectedColumns:[]})}handleSearchInputChange(e){var t=e.target.value;if(this.setState({searchFilter:t}),!t)return this.debouncedSearchColumns.cancel(),void this.resetSelection();this.debouncedSearchColumns(t)}searchColumns(e){var{model:t,movedColumns:n}=this.props,{columns:i}=t,a=[],s=i.length;(i.forEach(((i,r)=>{var o=i.name.toLowerCase();t.isColumnMovable(r)&&o.includes(e.toLowerCase())&&(a.push(r),s=Math.min(s,wr.getVisibleIndex(r,n)))})),this.addColumnToSelected(a,!1),a.length>0)&&this.list.querySelectorAll(".column-item")[s].scrollIntoView({block:"center"})}handleVisibilityKeyDown(e,t){var{onColumnVisibilityChanged:n}=this.props;n([e],t)}handleVisibilityDraggingStart(e,t,n){var{onColumnVisibilityChanged:i,movedColumns:a}=this.props,s=wr.isModifierKeyDown(n),r=n.shiftKey;if(!s&&!r){i([e],t);var o=wr.getVisibleIndex(e,a);this.setState({isDraggingVisibility:!0,visibilityDraggingOption:t,visibilityDraggingStartColumn:o}),this.addColumnToSelected([e])}}handleVisibilityDraggingEnd(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;e&&e.target.focus();var{isDraggingVisibility:t}=this.state;t&&this.setState({isDraggingVisibility:!1,visibilityDraggingOption:null,visibilityDraggingStartColumn:null})}handleOrderDraggingStart(e){document.documentElement.classList.add("drag-pointer-events-none");var{selectedColumns:t}=this.state,{draggableId:n,source:{index:i}}=e,a=parseInt(n,10);this.list.querySelectorAll(".column-item")[i].focus(),t.includes(a)?this.setState({isDraggingOrder:!0,orderDraggingColumn:a}):this.setState({isDraggingOrder:!0,orderDraggingColumn:a,selectedColumns:[a]})}handleOrderDraggingEnd(e){document.documentElement.classList.remove("drag-pointer-events-none");var{movedColumns:t,onMovedColumnsChanged:n}=this.props,{selectedColumns:i,orderDraggingColumn:a}=this.state;if(this.setState({isDraggingOrder:!1,orderDraggingColumn:null}),e.destination){var{index:s}=e.destination,r=[...i].sort(((e,n)=>wr.getVisibleIndex(e,t)-wr.getVisibleIndex(n,t))),o=[].concat(t),l=wr.getVisibleIndex(a,o),c=[],h=[];o=wr.moveItem(l,s,o),r.forEach((e=>{var t=wr.getVisibleIndex(e,o);e!==a&&(t<s?c.push(e):h.push(e))})),c.forEach((e=>{var t=wr.getVisibleIndex(e,o);o=wr.moveItem(t,s,o)}));var d=c.length>0||l>s?s+1:s;h.reverse().forEach((e=>{var t=wr.getVisibleIndex(e,o);o=wr.moveItem(t,d,o)})),n(o),Zg.debug("move column order by drag & drop",o)}}handleMouseEnter(e,t){var{onColumnVisibilityChanged:n,movedColumns:i,userColumnWidths:a}=this.props,{isDraggingVisibility:s,visibilityDraggingOption:r,visibilityDraggingStartColumn:o}=this.state,l=wr.getVisibleIndex(e,i),c=wr.isModifierKeyDown(t),h=t.shiftKey;if(s&&!c&&!h){t.target.focus();for(var d=[e],u=l>o,m=o;u?m<l:m>l;u?m+=1:m-=1){var p=wr.getModelIndex(m,i),g=wr.checkColumnHidden(p,a);g&&r===$g.VISIBILITY_OPTIONS.SHOW?d.push(p):g||r!==$g.VISIBILITY_OPTIONS.HIDE||d.push(p)}this.addColumnToSelected(d,!0),n(d,r)}}handleMoveColumns(e){var{movedColumns:t,onMovedColumnsChanged:n,model:i}=this.props,{columns:a}=i,{selectedColumns:s}=this.state;if(0!==s.length){var r=this.getFirstMovableIndex(i,a),o=this.getLastMovableIndex(i,a);if(null!=r&&null!=o){var l=[...s].sort(((n,i)=>e===$g.MOVE_OPTIONS.TOP||e===$g.MOVE_OPTIONS.UP?wr.getVisibleIndex(n,t)-wr.getVisibleIndex(i,t):wr.getVisibleIndex(i,t)-wr.getVisibleIndex(n,t))),c=[],h=()=>{};switch(e){case $g.MOVE_OPTIONS.TOP:l.forEach(((e,n)=>{var i=wr.getVisibleIndex(e,t);c=wr.moveItem(i,r+n,c)})),h=()=>{this.list.scrollTop=0};break;case $g.MOVE_OPTIONS.BOTTOM:l.forEach(((e,n)=>{var i=wr.getVisibleIndex(e,t);c=wr.moveItem(i,o-n,c)})),h=()=>{this.list.scrollTop=this.list.scrollHeight};break;case $g.MOVE_OPTIONS.UP:wr.getVisibleIndex(l[0],t)!==r&&l.forEach((e=>{var n=wr.getVisibleIndex(e,t);c=wr.moveItem(n,n-1,c)}));break;case $g.MOVE_OPTIONS.DOWN:wr.getVisibleIndex(l[0],t)!==o&&l.forEach((e=>{var n=wr.getVisibleIndex(e,t);c=wr.moveItem(n,n+1,c)}))}c.length>0&&n(t.concat(c),h)}}}handleSortColumns(e){for(var{model:t,onMovedColumnsChanged:n}=this.props,{columns:i}=t,a=[],s=[],r=0;r<i.length;r+=1)t.isColumnMovable(r)?a.push(r):s.push(r);for(var o=a.sort(((t,n)=>{var a=e===$g.SORTING_OPTIONS.ASC,s=i[t].name.toUpperCase(),r=i[n].name.toUpperCase();return Ga.sort(s,r,a)})),l=[],c=0;c<s.length;c+=1){var h=s[c];l[h]=h}for(var d=0,u=0;u<o.length;u+=1){for(;null!=l[d];)d+=1;l[d]=o[u]}var m=[];l.forEach(((e,t)=>{var n=wr.getVisibleIndex(e,m);m=wr.moveItem(n,t,m)})),n(m)}handleItemClick(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];t.stopPropagation(),t.currentTarget.focus();var{selectedColumns:i,lastSelectedColumns:a}=this.state,s=wr.isModifierKeyDown(t),r=t.shiftKey,o=i.includes(e),l=[e];if(o&&s)this.removeColumnFromSelected(e);else if(o&&1===i.length&&n)this.removeColumnFromSelected(e);else{if(r){for(var{movedColumns:c}=this.props,h=a[a.length-1],d=wr.getVisibleIndex(h,c),u=wr.getVisibleIndex(e,c),m=u>d,p=[],g=d;m?g<u:g>u;m?g+=1:g-=1)p.push(wr.getModelIndex(g,c));p.forEach((e=>{i.includes(e)||l.push(e)}))}this.addColumnToSelected(l,s||r)}}addColumnToSelected(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{selectedColumns:n,lastSelectedColumns:i}=this.state,a=t?n.concat(e):e,s=t?i.concat(e):e;this.setState({selectedColumns:a,lastSelectedColumns:s})}removeColumnFromSelected(e){var{selectedColumns:t,lastSelectedColumns:n}=this.state,i=[...t];i.splice(i.findIndex((t=>t===e)),1);var a=n[n.length-1],s=[...n];a===e&&s.pop(),this.setState({selectedColumns:i,lastSelectedColumns:s})}makeVisibilityOrderingList(){for(var{model:e,userColumnWidths:t,movedColumns:n}=this.props,{columns:i}=e,{selectedColumns:s,isDraggingOrder:r,orderDraggingColumn:o}=this.state,l=[],c=!1,h=0;h<i.length;h+=1){var d=wr.getModelIndex(h,n),u=i[d],m=e.isColumnMovable(d);if(h>0&&m!==c&&l.push(a.a.createElement("hr",null)),m){var p=0===t.get(d),g=s.includes(d),v=o===d,f=r&&v&&s.length>1?s.length:null;l.push(this.renderVisibilityOrderingItem(u.name,d,h,p,g,r,v,f))}else l.push(this.renderImmovableItem(u.name));c=m}return l}render(){var{model:e,userColumnWidths:t,onColumnVisibilityChanged:n}=this.props,{selectedColumns:i,searchFilter:s}=this.state,{columns:r}=e,o=0===i.length,l=o?r.map(((e,t)=>t)).filter((t=>e.isColumnMovable(t))):[...i],c=wr.checkAllColumnsHidden(l,t),h=c?"Show Selected":"Hide Selected",d=this.makeVisibilityOrderingList();return a.a.createElement("div",{role:"menu",className:"visibility-ordering-builder",tabIndex:"0",onMouseUp:()=>{this.handleVisibilityDraggingEnd()},onMouseLeave:()=>{this.handleVisibilityDraggingEnd()}},a.a.createElement("div",{className:"top-menu"},a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:()=>{n(l,c?$g.VISIBILITY_OPTIONS.SHOW:$g.VISIBILITY_OPTIONS.HIDE)}},a.a.createElement(Ke.a,{icon:c?on:ln}),a.a.createElement(Ol,null,"Toggle column visibility"),o?"Toggle All":h),a.a.createElement("div",null,a.a.createElement("button",{type:"button",className:"btn btn-link text-muted",onClick:()=>{this.resetVisibilityOrdering()}},"Reset",a.a.createElement(Ol,null,"Reset to default")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleSortColumns($g.SORTING_OPTIONS.ASC)}},a.a.createElement(Ke.a,{icon:Dn}),a.a.createElement(Ol,null,"Sort ascending")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleSortColumns($g.SORTING_OPTIONS.DSC)}},a.a.createElement(Ke.a,{icon:xn}),a.a.createElement(Ol,null,"Sort descending")),a.a.createElement("span",{className:"vertical-divider"}),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleMoveColumns($g.MOVE_OPTIONS.UP)},disabled:o},a.a.createElement(Ke.a,{icon:it}),a.a.createElement(Ol,null,"Move selection up")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleMoveColumns($g.MOVE_OPTIONS.DOWN)},disabled:o},a.a.createElement(Ke.a,{icon:et}),a.a.createElement(Ol,null,"Move selection down")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleMoveColumns($g.MOVE_OPTIONS.TOP)},disabled:o},a.a.createElement(Ke.a,{icon:an}),a.a.createElement(Ol,null,"Move selection to top")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:()=>{this.handleMoveColumns($g.MOVE_OPTIONS.BOTTOM)},disabled:o},a.a.createElement(Ke.a,{icon:nn}),a.a.createElement(Ol,null,"Move selection to bottom")))),a.a.createElement("div",{className:"top-menu"},a.a.createElement(Gc,{className:"w-100",value:s,matchCount:s?i.length:null,onChange:this.handleSearchInputChange})),a.a.createElement(Kg.a,{onDragStart:this.handleOrderDraggingStart,onDragEnd:this.handleOrderDraggingEnd},a.a.createElement(Kg.c,{droppableId:"droppable-visibility-order-list"},((e,t)=>a.a.createElement("div",Yg({role:"menu",className:qe()("visibility-ordering-list",{isDragging:t.draggingFromThisWith}),ref:e.innerRef},e.droppableProps),a.a.createElement("div",{className:"column-list",ref:e=>{this.list=e}},d,e.placeholder))))))}}Xg($g,"VISIBILITY_OPTIONS",{SHOW:"SHOW",HIDE:"HIDE"}),Xg($g,"SORTING_OPTIONS",{DSC:"DSC",ASC:"ASC"}),Xg($g,"MOVE_OPTIONS",{TOP:"TOP",BOTTOM:"BOTTOM",UP:"UP",DOWN:"DOWN"}),Xg($g,"COLUMN_CHANGE_OPTIONS",{ALL:"ALL",SELECTION:"SELECTION"}),$g.propTypes={model:pi.a.instanceOf(Cu).isRequired,movedColumns:pi.a.arrayOf(pi.a.shape({from:pi.a.number,to:pi.a.number})),userColumnWidths:pi.a.instanceOf(Map).isRequired,onColumnVisibilityChanged:pi.a.func,onMovedColumnsChanged:pi.a.func},$g.defaultProps={movedColumns:[],onColumnVisibilityChanged:()=>{},onMovedColumnsChanged:()=>{}};var Qg=$g,Jg=e=>{var{children:t,disabled:n=!1,name:s,onChange:r,value:o=""}=e,[l]=Object(i.useState)(s||ni()());return a.a.createElement(a.a.Fragment,null,a.a.Children.map(t,(e=>e?a.a.cloneElement(e,{name:l,onChange:e.props.onChange||r,checked:o===e.props.value,disabled:e.props.disabled||n}):null)))},ev=a.a.forwardRef(((e,t)=>{var{checked:n,children:s,className:r="",disabled:o=!1,inputClassName:l="",isInvalid:c=!1,labelClassName:h="",name:d,onChange:u,value:m}=e,[p]=Object(i.useState)(ni()());return a.a.createElement("div",{className:qe()("custom-control custom-radio",r)},a.a.createElement("input",{type:"radio",id:p,name:d,ref:t,className:qe()("custom-control-input",l,{"is-invalid":c}),checked:n,disabled:o,value:m,onChange:u}),a.a.createElement("label",{className:qe()("custom-control-label",h),htmlFor:p},s))}));ev.displayName="RadioItem",ev.defaultProps={checked:void 0,className:"",disabled:!1,inputClassName:"",isInvalid:!1,labelClassName:"",name:void 0,onChange:void 0};var tv=ev;n(1281);function nv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class iv extends i.Component{static getDateString(){return va.i18n.DateTimeFormat.format(iv.FILENAME_DATE_FORMAT,new Date)}constructor(e){super(e),this.handleDownloadClick=this.handleDownloadClick.bind(this),this.handleDownloadOptionChanged=this.handleDownloadOptionChanged.bind(this),this.handleCustomizedDownloadOptionChanged=this.handleCustomizedDownloadOptionChanged.bind(this),this.handleCustomizedDownloadRowsChanged=this.handleCustomizedDownloadRowsChanged.bind(this);var{name:t}=e;this.state={fileName:"".concat(t,"-").concat(iv.getDateString(),".csv"),downloadOption:iv.DOWNLOAD_OPTIONS.ALL_ROWS,customizedDownloadOption:iv.CUSTOMIZED_ROWS_OPTIONS.FIRST,customizedDownloadRows:iv.DEFAULT_DOWNLOAD_ROWS,errorMessage:null,id:ni.a.generate()}}getSnapshotRanges(){var{model:e,selectedRanges:t}=this.props,{downloadOption:n,customizedDownloadOption:i,customizedDownloadRows:a}=this.state,{rowCount:s}=e,r=[];switch(n){case iv.DOWNLOAD_OPTIONS.ALL_ROWS:r.push(new fr(null,0,null,s-1));break;case iv.DOWNLOAD_OPTIONS.SELECTED_ROWS:r=[...t].sort(((e,t)=>e.startRow-t.startRow));break;case iv.DOWNLOAD_OPTIONS.CUSTOMIZED_ROWS:switch(i){case iv.CUSTOMIZED_ROWS_OPTIONS.FIRST:r.push(new fr(null,0,null,Math.min(a-1,s-1)));break;case iv.CUSTOMIZED_ROWS_OPTIONS.LAST:r.push(new fr(null,Math.max(0,s-a),null,s-1))}}return r}resetDownloadState(){this.setState({errorMessage:null})}handleDownloadClick(){var{model:e,isDownloading:t,onDownloadStart:n,onDownload:i,onCancel:a}=this.props,{fileName:s}=this.state;if(t)a();else{this.resetDownloadState();var r=this.getSnapshotRanges();this.validateOptionInput()&&(n(),e.export().then((e=>{var t=e.setViewport(0,0);t.getViewportData().then((()=>{i(s,e,t,r)}))})))}}handleDownloadOptionChanged(e){this.setState({downloadOption:e.target.value})}handleCustomizedDownloadOptionChanged(e){this.setState({customizedDownloadOption:e.target.value})}handleCustomizedDownloadRowsChanged(e){this.setState({customizedDownloadRows:e.target.value})}validateOptionInput(){var{selectedRanges:e}=this.props,{downloadOption:t,customizedDownloadRows:n}=this.state;return t===iv.DOWNLOAD_OPTIONS.SELECTED_ROWS&&0===e.length?(this.setState({errorMessage:a.a.createElement("p",null,a.a.createElement(Ke.a,{icon:Tt})," No rows selected. Please select some rows in the table.")}),!1):!(t===iv.DOWNLOAD_OPTIONS.CUSTOMIZED_ROWS&&n<=0)||(this.setState({errorMessage:a.a.createElement("p",null,a.a.createElement(Ke.a,{icon:Tt})," Number of rows to output must be greater than 0")}),!1)}render(){var{model:e,isDownloading:t,tableDownloadProgress:n,tableDownloadEstimatedTime:i,selectedRanges:s,tableDownloadStatus:r}=this.props,{fileName:o,downloadOption:l,customizedDownloadOption:c,customizedDownloadRows:h,errorMessage:d,id:u}=this.state,{rowCount:m}=e;return a.a.createElement("div",{className:"table-csv-exporter"},a.a.createElement("div",{className:"section-title"},"Download Rows"),a.a.createElement("div",{className:"form-group"},a.a.createElement(Jg,{onChange:this.handleDownloadOptionChanged,value:l,disabled:t},a.a.createElement(tv,{value:iv.DOWNLOAD_OPTIONS.ALL_ROWS},"All Rows",a.a.createElement("span",{className:"text-muted ml-2"},"(".concat(m.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,")," rows)"))),a.a.createElement(tv,{value:iv.DOWNLOAD_OPTIONS.SELECTED_ROWS},"Only Selected Rows",a.a.createElement("span",{className:"text-muted ml-2"},s.length>0?"(".concat(fr.rowCount(s).toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,")," rows)"):null)),a.a.createElement(tv,{value:iv.DOWNLOAD_OPTIONS.CUSTOMIZED_ROWS},a.a.createElement("div",{className:"radio-input-row",role:"presentation",onClick:()=>{this.setState({downloadOption:iv.DOWNLOAD_OPTIONS.CUSTOMIZED_ROWS})}},a.a.createElement("select",{defaultValue:iv.DOWNLOAD_OPTIONS.FIRST,value:c,className:"custom-select",disabled:t,onChange:this.handleCustomizedDownloadOptionChanged},a.a.createElement("option",{value:"FIRST"},"First"),a.a.createElement("option",{value:"LAST"},"Last")),a.a.createElement("input",{type:"number",className:"form-control",id:"customizedRows-".concat(u),name:"customizedRows-".concat(u),placeholder:"100",value:h,disabled:t,onChange:this.handleCustomizedDownloadRowsChanged}),a.a.createElement("div",null,"Rows"))))),a.a.createElement("div",{className:"form-group"},a.a.createElement("label",{htmlFor:"customizedRows-".concat(u)},"File Name"),a.a.createElement("input",{type:"text",className:"form-control",id:"filename-".concat(u),name:"filename-".concat(u),value:o,onChange:e=>{this.setState({fileName:e.target.value})},disabled:t})),a.a.createElement("div",{className:"section-footer flex-column"},d&&a.a.createElement("div",{className:"error-message"},d),r&&a.a.createElement("div",{className:"download-status"},(r===iv.DOWNLOAD_STATUS.DOWNLOADING||r===iv.DOWNLOAD_STATUS.INITIATING)&&a.a.createElement(a.a.Fragment,null,r===iv.DOWNLOAD_STATUS.INITIATING&&a.a.createElement("div",{className:"text-muted"},"Starting Download..."),r===iv.DOWNLOAD_STATUS.DOWNLOADING&&a.a.createElement("div",{className:"text-muted d-flex justify-content-between"},a.a.createElement("span",null,i||0===i?"Estimated time: ".concat(Ya.formatElapsedTime(i)):null),a.a.createElement("span",null,"".concat(n,"%")))),r===iv.DOWNLOAD_STATUS.FINISHED&&a.a.createElement("div",{className:"text-muted text-right"},"Download Completed"),r===iv.DOWNLOAD_STATUS.CANCELED&&a.a.createElement("div",{className:"text-muted"},"Download Canceled"),(r===iv.DOWNLOAD_STATUS.DOWNLOADING||r===iv.DOWNLOAD_STATUS.INITIATING)&&a.a.createElement("div",{className:"progress"},a.a.createElement("div",{className:"progress-bar progress-bar-striped progress-bar-animated",style:{width:"".concat(n,"%")}})),r===iv.DOWNLOAD_STATUS.FINISHED&&a.a.createElement("div",{className:"progress"},a.a.createElement("div",{className:"progress-bar bg-success",style:{width:"".concat(n,"%")}}))),a.a.createElement("button",{type:"button",className:qe()("btn btn-primary btn-downloading",{"btn-spinner btn-cancelable":t}),onClick:this.handleDownloadClick},t&&a.a.createElement("span",null,a.a.createElement(Yn,null),a.a.createElement("span",{className:"btn-normal-content"},"Downloading"),a.a.createElement("span",{className:"btn-hover-content"},"Cancel")),!t&&"Download")))}}nv(iv,"FILENAME_DATE_FORMAT","yyyy-MM-dd-HHmmss"),nv(iv,"DOWNLOAD_STATUS",{INITIATING:"INITIATING",DOWNLOADING:"DOWNLOADING",FINISHED:"FINISHED",CANCELED:"CANCELED"}),nv(iv,"DOWNLOAD_OPTIONS",{ALL_ROWS:"ALL_ROWS",SELECTED_ROWS:"SELECTED_ROWS",CUSTOMIZED_ROWS:"CUSTOMIZED_ROWS"}),nv(iv,"CUSTOMIZED_ROWS_OPTIONS",{FIRST:"FIRST",LAST:"LAST"}),nv(iv,"DEFAULT_DOWNLOAD_ROWS",100),iv.propTypes={model:pi.a.instanceOf(Cu).isRequired,name:pi.a.string.isRequired,isDownloading:pi.a.bool,tableDownloadStatus:pi.a.string,tableDownloadProgress:pi.a.number,tableDownloadEstimatedTime:pi.a.number,onDownloadStart:pi.a.func,onDownload:pi.a.func.isRequired,onCancel:pi.a.func.isRequired,selectedRanges:pi.a.arrayOf(pi.a.instanceOf(fr))},iv.defaultProps={onDownloadStart:()=>{},isDownloading:!1,tableDownloadStatus:"",tableDownloadProgress:0,tableDownloadEstimatedTime:null,selectedRanges:[]};var av=iv;function sv(){return sv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},sv.apply(this,arguments)}var rv=function(e){return i.createElement("svg",sv({width:48,height:48,xmlns:"http://www.w3.org/2000/svg"},e),i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{fill:"#C1C0C0",d:"M4 4h1v40H4zM44 43v1H5v-1z"}),i.createElement("path",{stroke:"#7DA4FF",d:"M7.984 32.44l7.982-11.378 5.273 3.739 9.952-10.838 2.826 1.894 7.45-5.802"}),i.createElement("path",{stroke:"#BECDEF",d:"M8.244 37.926L17 33.496l5 .87 10.637-10.35 10.615-1.381"})))};function ov(){return ov=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},ov.apply(this,arguments)}var lv=function(e){return i.createElement("svg",ov({width:48,height:48,xmlns:"http://www.w3.org/2000/svg"},e),i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{fill:"#C1C0C0",d:"M44 43v1H4v-1z"}),i.createElement("path",{fill:"#7DA4FF",d:"M8 26h4v15H8zM15 17h4v24h-4zM22 21h4v20h-4zM29 17h4v24h-4zM36 11h4v30h-4z"})))};function cv(){return cv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},cv.apply(this,arguments)}var hv=function(e){return i.createElement("svg",cv({width:48,height:48,xmlns:"http://www.w3.org/2000/svg"},e),i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{fill:"#C1C0C0",d:"M44 43v1H4v-1z"}),i.createElement("path",{fill:"#939293",d:"M44 34v1H4v-1zM44 25v1H4v-1zM44 16v1H4v-1z"}),i.createElement("circle",{fill:"#7DA4FF",cx:9.5,cy:37.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:16.5,cy:30.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:22.5,cy:36.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:28.5,cy:30.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:15.5,cy:38.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:23.5,cy:25.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:19.5,cy:19.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:29.5,cy:19.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:32.5,cy:26.5,r:1.5}),i.createElement("circle",{fill:"#7DA4FF",cx:36.5,cy:13.5,r:1.5})))};function dv(){return dv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},dv.apply(this,arguments)}var uv=function(e){return i.createElement("svg",dv({width:48,height:48,xmlns:"http://www.w3.org/2000/svg"},e),i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{d:"M24 10c7.732 0 14 6.268 14 14s-6.268 14-14 14-14-6.268-14-14h14V10z",fill:"#80A6FF"}),i.createElement("path",{d:"M10 24c0-7.732 6.268-14 14-14v14H10z",fill:"#C1C0C0"})))};function mv(){return mv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},mv.apply(this,arguments)}var pv=function(e){return i.createElement("svg",mv({width:48,height:48,xmlns:"http://www.w3.org/2000/svg"},e),i.createElement("g",{fill:"none",fillRule:"evenodd"},i.createElement("path",{fill:"#C1C0C0",d:"M44 43v1H4v-1z"}),i.createElement("path",{fill:"#7DA4FF",d:"M7 34h4v8H7zM12 31h4v11h-4zM17 27h4v15h-4zM22 22h4v20h-4zM27 27h4v15h-4zM32 29h4v13h-4zM37 31h4v11h-4z"})))};n(1285);var gv=p.module("ChartBuilder");class vv extends i.PureComponent{static getTypeName(e){switch(e){case va.plot.SeriesPlotStyle.LINE:return"Line";case va.plot.SeriesPlotStyle.BAR:return"Bar";case va.plot.SeriesPlotStyle.SCATTER:return"Scatter";case va.plot.SeriesPlotStyle.PIE:return"Pie";case va.plot.SeriesPlotStyle.HISTOGRAM:return"Histogram";default:return e}}static getTypeIcon(e){switch(e){case va.plot.SeriesPlotStyle.LINE:return a.a.createElement(rv,null);case va.plot.SeriesPlotStyle.BAR:return a.a.createElement(lv,null);case va.plot.SeriesPlotStyle.SCATTER:return a.a.createElement(hv,null);case va.plot.SeriesPlotStyle.PIE:return a.a.createElement(uv,null);case va.plot.SeriesPlotStyle.HISTOGRAM:return a.a.createElement(pv,null);default:return null}}static getMaxSeriesCount(e){switch(e){case va.plot.SeriesPlotStyle.PIE:return 1;case va.plot.SeriesPlotStyle.HISTOGRAM:return 0;default:return 100}}static getXAxisLabel(e){switch(e){case va.plot.SeriesPlotStyle.PIE:return"Labels";case va.plot.SeriesPlotStyle.HISTOGRAM:return"Data";default:return"X-Axis"}}static getSeriesLabel(e){return e===va.plot.SeriesPlotStyle.PIE?"Values":"Series"}static makeSeriesItem(e){return{id:ni.a.generate(),value:e}}static makeDefaultSeriesItems(e,t){if(0===vv.getMaxSeriesCount(e)||null==t||0===t.length)return[];var n=t.length>1?t[1].name:t[0].name;return[vv.makeSeriesItem(n)]}static getDefaultXAxis(e,t){return null!=t&&t.length>0?t[0].name:null}constructor(e){super(e),this.handleAddSeries=this.handleAddSeries.bind(this),this.handleLinkStateChange=this.handleLinkStateChange.bind(this),this.handleReset=this.handleReset.bind(this),this.handleSeriesChange=this.handleSeriesChange.bind(this),this.handleSeriesDeleteClick=this.handleSeriesDeleteClick.bind(this),this.handleSubmit=this.handleSubmit.bind(this),this.handleTypeClick=this.handleTypeClick.bind(this),this.handleXAxisChange=this.handleXAxisChange.bind(this);var{model:t}=e,{columns:n}=t,i=vv.types[0],a=vv.getDefaultXAxis(i,n),s=vv.makeDefaultSeriesItems(i,n);this.state={type:i,seriesItems:s,xAxis:a,isLinked:!0}}handleAddSeries(){this.setState((e=>{var{seriesItems:t}=e;t=[].concat(t);var{model:n}=this.props,{columns:i}=n;return t.push({id:ni.a.generate(),value:i[0].name}),{seriesItems:t}}),(()=>{this.sendChange()}))}handleLinkStateChange(e){this.setState({isLinked:"true"===e.target.value})}handleReset(){var{model:e}=this.props,{columns:t}=e,n=vv.types[0],i=vv.getDefaultXAxis(n,t),a=vv.makeDefaultSeriesItems(n,t);this.setState({type:n,seriesItems:a,xAxis:i,isLinked:!0},(()=>{this.sendChange()}))}handleSeriesChange(e){var{value:t}=e.target,n=e.target.getAttribute("data-index");this.setState((e=>{var{seriesItems:i}=e;return(i=[].concat(i))[n].value=t,{seriesItems:i}}),(()=>{this.sendChange()}))}handleSeriesDeleteClick(e){var t=e.target.getAttribute("data-index");this.setState((e=>{var{seriesItems:n}=e;return(n=[].concat(n)).splice(t,1),{seriesItems:n}}),(()=>{this.sendChange()}))}handleSubmit(e){e.preventDefault();var{onSubmit:t}=this.props,{type:n,seriesItems:i,xAxis:a,isLinked:s}=this.state;t({type:n,series:i.map((e=>e.value)),xAxis:a,isLinked:s})}handleTypeClick(e){var t=e.target.getAttribute("data-index"),n=vv.types[t];gv.debug2("handleTypeSelect",n),this.setState((e=>{var t=vv.getMaxSeriesCount(n),{seriesItems:i}=e;if(0===(i=i.slice(0,t)).length&&t>0){var{model:a}=this.props,{columns:s}=a;i=vv.makeDefaultSeriesItems(n,s)}return{type:n,seriesItems:i}}),(()=>{this.sendChange()}))}handleXAxisChange(e){var t=e.target.value;gv.debug2("x-axis change",t),this.setState({xAxis:t},(()=>{this.sendChange()}))}sendChange(){var{onChange:e}=this.props,{isLinked:t,type:n,seriesItems:i,xAxis:a}=this.state;e({type:n,series:i.map((e=>e.value)),xAxis:a,isLinked:t})}render(){var{model:e}=this.props,{columns:t}=e,{seriesItems:n,type:i,xAxis:s,isLinked:r}=this.state,o=vv.getMaxSeriesCount(i),l=vv.getXAxisLabel(i),c=vv.getSeriesLabel(i),h=n.length>0,d=n.length<o;return a.a.createElement("div",{className:"chart-builder"},a.a.createElement("form",{onSubmit:this.handleSubmit},a.a.createElement("div",{className:"form-row"},a.a.createElement("label",null,"Select Chart Type"),a.a.createElement("div",{className:"form-row"},vv.types.map(((e,t)=>a.a.createElement("div",{key:e,className:"col col-chart-type"},a.a.createElement("button",{type:"button",className:qe()("btn","btn-icon","btn-chart-type",{active:e===i}),"data-index":t,onClick:this.handleTypeClick},vv.getTypeIcon(e),vv.getTypeName(e))))))),a.a.createElement("hr",null),a.a.createElement("div",{className:"form-row form-inline"},a.a.createElement("label",{className:"col-2 label-left"},l),a.a.createElement("select",{className:"form-control custom-select select-x-axis col",value:s,onChange:this.handleXAxisChange},t.map((e=>a.a.createElement("option",{key:e.name,value:e.name},e.name))))),h&&a.a.createElement("hr",null),n.map(((e,i)=>a.a.createElement("div",{className:"form-row form-inline form-series-item",key:e.id},a.a.createElement("label",{className:"col-2 label-left"},0===i?c:""),a.a.createElement("select",{className:"form-control custom-select select-series col",value:e.value,onChange:this.handleSeriesChange,"data-index":i},t.map((e=>a.a.createElement("option",{key:e.name,value:e.name,"data-index":i},e.name)))),n.length>1&&a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-delete-series ml-2 px-2","data-index":i,onClick:this.handleSeriesDeleteClick},a.a.createElement(Ke.a,{icon:$t}))))),d&&a.a.createElement("div",{className:"form-row"},a.a.createElement("div",{className:"col-2"}),a.a.createElement("button",{type:"button",className:"btn btn-link btn-add-series mt-1",onClick:this.handleAddSeries},a.a.createElement(Ke.a,{icon:wn}),"Add Series")),a.a.createElement("div",{className:"form-row chart-builder-link"},a.a.createElement("label",{className:"col-2 label-right"},a.a.createElement("div",{className:"fa-md fa-layers"},a.a.createElement(Ke.a,{mask:An,icon:at,transform:"right-5 down-5"}),a.a.createElement(Ke.a,{icon:r?Nt:jn,transform:"grow-2 right-8 down-6"}))),a.a.createElement(Jg,{onChange:this.handleLinkStateChange,value:"".concat(r)},a.a.createElement(tv,{value:"true"},"Sync State"),a.a.createElement(tv,{value:"false"},"Freeze State"))),a.a.createElement("div",{className:"form-row"},a.a.createElement("div",{className:"col-2 label-right"}),a.a.createElement("div",{className:"col chart-builder-link-info"},r?"Charts with synced state will update to match any filters or user modifications applied to the parent table.":"Freeze State disconnects the chart state from the parent table. New filters or user modifications on the parent table will not be applied.")),a.a.createElement("div",{className:qe()("form-row","justify-content-end","my-3")},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary btn-reset",onClick:this.handleReset},"Reset"),a.a.createElement("button",{type:"submit",className:"btn btn-primary btn-submit"},"Create"))))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(vv,"types",[va.plot.SeriesPlotStyle.LINE,va.plot.SeriesPlotStyle.BAR,va.plot.SeriesPlotStyle.SCATTER,va.plot.SeriesPlotStyle.PIE]),vv.propTypes={model:pi.a.instanceOf(Cu).isRequired,onSubmit:pi.a.func.isRequired,onChange:pi.a.func.isRequired};var fv=vv,bv=n(727),Cv=n.n(bv);class Sv{static reorder(e,t,n,i){var a=e===n?Sv.adjustDestinationIndex(i,t):i,s=Sv.removeItems(e,t);return n.splice(a,0,...s),s}static removeItems(e,t){for(var n=[],i=t.map(((e,t)=>({range:e,index:t}))).sort(((e,t)=>t.range[0]-e.range[0])),a=0;a<i.length;a+=1){var{range:s,index:r}=i[a],[o,l]=s;n[r]=e.splice(o,l-o+1)}return Cv()(n)}static adjustDestinationIndex(e,t){for(var n=e,i=0;i<t.length;i+=1){var[a,s]=t[i];if(a>e)break;n-=Math.min(s,e-1)-a+1}return n}static startDragging(){document.documentElement.classList.add("drag-pointer-events-none")}static stopDragging(){document.documentElement.classList.remove("drag-pointer-events-none")}}var Ev=Sv;n(1287);function wv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function yv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Tv extends i.Component{constructor(e){super(e),this.handleContentChanged=this.handleContentChanged.bind(this),this.handleEditorFocus=this.handleEditorFocus.bind(this),this.handleEditorBlur=this.handleEditorBlur.bind(this),this.handleContainerClick=this.handleContainerClick.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.state={isEditorFocused:!1,isEditorEmpty:!0},this.editorContainer=null,this.editor=null}componentDidMount(){this.initEditor()}componentWillUnmount(){this.destroyEditor()}initEditor(){var{value:e,editorSettings:t}=this.props,n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wv(Object(n),!0).forEach((function(t){yv(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({copyWithSyntaxHighlighting:"false",fixedOverflowWidgets:!0,folding:!1,fontFamily:"Fira Mono",glyphMargin:!1,language:"groovyDB",lineDecorationsWidth:8,lineNumbers:"off",minimap:{enabled:!1},renderLineHighlight:"none",scrollbar:{arrowSize:0,horizontal:"hidden",horizontalScrollbarSize:0},scrollBeyondLastLine:!1,padding:{top:6,bottom:6},tabCompletion:"off",useTabStops:!0,value:e,wordWrap:"on",automaticLayout:!0},t);this.editor=l.c.create(this.editorContainer,n),this.editor.layout(),this.editor.getModel().updateOptions({tabSize:0}),this.editor.onDidChangeModelContent(this.handleContentChanged),this.editor.onDidFocusEditorText(this.handleEditorFocus),this.editor.onDidBlurEditorText(this.handleEditorBlur)}destroyEditor(){this.editor.dispose(),this.editor=null}handleContentChanged(){var{onContentChanged:e}=this.props,t=this.editor.getModel().getValue();this.setState({isEditorEmpty:0===t.length}),e(t)}handleEditorFocus(){this.setState({isEditorFocused:!0})}handleEditorBlur(){var e=this.editor.getModel().getValue();this.setState({isEditorEmpty:0===e.length,isEditorFocused:!1})}handleContainerClick(){var{isEditorFocused:e}=this.state;e||this.editor.focus()}handleKeyDown(e){var{onTab:t,editorIndex:n}=this.props;"Tab"===e.key&&t(n,e.shiftKey)}render(){var{value:e,invalid:t}=this.props,{isEditorFocused:n,isEditorEmpty:i}=this.state;return a.a.createElement("div",{className:qe()("input-editor-wrapper",{focused:n,invalid:t}),onKeyDown:this.handleKeyDown,role:"presentation",onClick:this.handleContainerClick},a.a.createElement("div",{className:"editor-container",ref:e=>{this.editorContainer=e}}),i&&!e&&a.a.createElement("div",{className:"editor-placeholder text-muted"},"Column Formula"))}}function Ov(){return Ov=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ov.apply(this,arguments)}Tv.propTypes={value:pi.a.string,onContentChanged:pi.a.func,editorSettings:pi.a.shape({}),editorIndex:pi.a.number,onTab:pi.a.func,invalid:pi.a.bool},Tv.defaultProps={value:"",onContentChanged:()=>{},editorSettings:{},editorIndex:0,onTab:()=>{},invalid:!1};class Mv extends i.PureComponent{constructor(e){super(e),this.handleFormulaEditorContentChanged=this.handleFormulaEditorContentChanged.bind(this),this.editorContainer=null,this.formulaEditor=null}handleFormulaEditorContentChanged(e){var{onChange:t,eventKey:n}=this.props;e.replace(/(\r\n|\n|\r)/gm,""),t(n,Mv.INPUT_TYPE.FORMULA,e)}render(){var{eventKey:e,name:t,formula:n,onChange:i,onDeleteColumn:s,inputIndex:r,onTabInEditor:o,invalid:l}=this.props;return a.a.createElement(Kg.b,{draggableId:e,index:r,disableInteractiveElementBlocking:!0},((c,h)=>a.a.createElement("div",Ov({className:qe()("draggable-container",{dragging:h.isDragging}),ref:c.innerRef},c.draggableProps),a.a.createElement("div",{className:"custom-column-input-container"},a.a.createElement("div",{className:"d-flex flex-row pb-3 custom-column-name"},a.a.createElement("input",{className:qe()("form-control custom-column-input",{"is-invalid":l}),placeholder:"Column Name",value:t,onChange:t=>{i(e,Mv.INPUT_TYPE.NAME,t.target.value)}}),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon ml-1 px-2",onClick:()=>{s(e)}},a.a.createElement(Ol,null,"Delete custom column"),a.a.createElement(Ke.a,{icon:$t})),a.a.createElement("button",Ov({type:"button",className:"btn btn-link btn-link-icon px-2 btn-drag-handle"},c.dragHandleProps),a.a.createElement(Ol,null,"Drag column to re-order"),a.a.createElement(Ke.a,{icon:yt}))),a.a.createElement(Tv,{editorSettings:{language:"deephavenDb"},editorIndex:r,value:n,onContentChanged:this.handleFormulaEditorContentChanged,onTab:o,invalid:l})),a.a.createElement("hr",null))))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Mv,"INPUT_TYPE",{NAME:"name",FORMULA:"formula"}),Mv.propTypes={eventKey:pi.a.string.isRequired,inputIndex:pi.a.number,name:pi.a.string,formula:pi.a.string,onChange:pi.a.func,onDeleteColumn:pi.a.func,onTabInEditor:pi.a.func,invalid:pi.a.bool},Mv.defaultProps={name:"",inputIndex:0,formula:"",onChange:()=>{},onDeleteColumn:()=>{},onTabInEditor:()=>{},invalid:!1};var Nv=Mv;n(1286);function Dv(){return Dv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Dv.apply(this,arguments)}function xv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Rv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Iv extends i.Component{static makeCustomColumnInputEventKey(){return ni.a.generate()}static createCustomColumnInput(){return{eventKey:ni.a.generate(),name:"",formula:""}}constructor(e){super(e),Rv(this,"getInput",Object(ua.a)(((e,t)=>e.find((e=>e.eventKey===t))))),Rv(this,"getInputIndex",Object(ua.a)(((e,t)=>e.findIndex((e=>e.eventKey===t))))),this.handleAddColumnClick=this.handleAddColumnClick.bind(this),this.handleSaveClick=this.handleSaveClick.bind(this),this.handleInputChange=this.handleInputChange.bind(this),this.handleDeleteColumn=this.handleDeleteColumn.bind(this),this.handleCustomColumnUpdated=this.handleCustomColumnUpdated.bind(this),this.handleRequestFailed=this.handleRequestFailed.bind(this),this.handleDragEnd=this.handleDragEnd.bind(this),this.resetRequestFailed=this.resetRequestFailed.bind(this),this.handleEditorTabNavigation=this.handleEditorTabNavigation.bind(this),this.state={inputs:[],isCustomColumnApplying:!1,errorMessage:null,hasRequestFailed:!1},this.container=null}componentDidMount(){var{customColumns:e}=this.props;this.parseCustomColumns(e),this.startListening()}componentWillUnmount(){this.stopListening(),this.messageTimer&&clearTimeout(this.messageTimer)}resetErrorMessage(){this.setState({errorMessage:null})}startListening(){var{model:e}=this.props;e.addEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleCustomColumnUpdated),e.addEventListener(Cu.EVENT.UPDATED,this.handleCustomColumnUpdated),e.addEventListener(Cu.EVENT.REQUEST_FAILED,this.handleRequestFailed)}stopListening(){var{model:e}=this.props;e.removeEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleCustomColumnUpdated),e.removeEventListener(Cu.EVENT.UPDATED,this.handleCustomColumnUpdated),e.removeEventListener(Cu.EVENT.REQUEST_FAILED,this.handleRequestFailed)}parseCustomColumns(e){if(e.length>0){var t=e.map((e=>{var t=e.split(/=(.+)/,2);return{eventKey:Iv.makeCustomColumnInputEventKey(),name:t[0],formula:t[1]}}));this.setState({inputs:t})}else this.setState({inputs:[Iv.createCustomColumnInput()]})}handleAddColumnClick(){var{inputs:e}=this.state,t=[...e];t.push(Iv.createCustomColumnInput()),this.setState({inputs:t})}handleDeleteColumn(e){var{inputs:t}=this.state,n=this.getInputIndex(t,e),i=[...t];i.splice(n,1),0===i.length&&i.push(Iv.createCustomColumnInput()),this.setState({inputs:i})}handleInputChange(e,t,n){var{inputs:i}=this.state,a=this.getInputIndex(i,e),s=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?xv(Object(n),!0).forEach((function(t){Rv(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},this.getInput(i,e));s[t]=n;var r=[...i];r.splice(a,1,s),this.setState({inputs:r})}handleCustomColumnUpdated(){var{isCustomColumnApplying:e}=this.state;e&&this.setState({isCustomColumnApplying:!1})}handleRequestFailed(e){var{isCustomColumnApplying:t}=this.state;t&&this.setState({isCustomColumnApplying:!1,errorMessage:a.a.createElement(a.a.Fragment,null,a.a.createElement("p",null,a.a.createElement(Ke.a,{icon:Tt})," Failed to apply custom columns."),a.a.createElement("div",{className:"error-box"},e.detail.errorMessage,a.a.createElement("br",null),"Table configuration: ",JSON.stringify(e.detail.configuration))),hasRequestFailed:!0})}handleDragEnd(e){if(Ev.stopDragging(),e.destination){var{inputs:t}=this.state,n=e.source.index,i=e.destination.index,a=[...t],s=t[n];a.splice(n,1),a.splice(i,0,s),this.setState({inputs:a})}}handleEditorTabNavigation(e,t){var{inputs:n}=this.state;if(t)this.container.querySelectorAll(".btn-drag-handle")[e].focus();else if(e===n.length-1)this.container.querySelector(".btn-add-column").focus();else{var i=e+1;this.container.querySelectorAll(".custom-column-input")[i].focus()}}handleSaveClick(){var{onSave:e}=this.props,{inputs:t,isCustomColumnApplying:n}=this.state;if(!n){var i=[];t.forEach((e=>{var{name:t,formula:n}=e;t&&n&&i.push("".concat(t,"=").concat(n))})),this.resetErrorMessage(),this.setState({isCustomColumnApplying:!0}),e(i)}}resetRequestFailed(){this.setState((e=>{var{hasRequestFailed:t}=e;return t?{hasRequestFailed:!1}:null}))}renderInputs(){var{inputs:e,hasRequestFailed:t}=this.state;return e.map(((e,n)=>{var{eventKey:i,name:s,formula:r}=e;return a.a.createElement(Nv,{key:i,inputIndex:n,eventKey:i,name:s,formula:r,onChange:this.handleInputChange,onDeleteColumn:this.handleDeleteColumn,onTabInEditor:this.handleEditorTabNavigation,invalid:t})}))}render(){var{onCancel:e}=this.props,{inputs:t,errorMessage:n,isCustomColumnApplying:i}=this.state;return a.a.createElement("div",{role:"presentation",className:"custom-column-builder-container",ref:e=>{this.container=e},onClick:this.resetRequestFailed,onFocus:this.resetRequestFailed},a.a.createElement("div",{className:"section-title"},"Custom Column Name and Formula"),a.a.createElement("hr",null),a.a.createElement(Kg.a,{onDragStart:Ev.startDragging,onDragEnd:this.handleDragEnd},a.a.createElement(Kg.c,{droppableId:"droppable-custom-columns"},((e,t)=>a.a.createElement("div",Dv({ref:e.innerRef},e.droppableProps,{className:qe()("droppable-container",{dragging:t.draggingFromThisWith})}),this.renderInputs(),e.placeholder)))),a.a.createElement("div",{className:"pt-1 px-3"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-add-column",onClick:this.handleAddColumnClick},a.a.createElement(Ke.a,{icon:wn}),"Add Another Column")),a.a.createElement("div",{className:"custom-column-builder-footer"},n&&a.a.createElement("div",{className:"error-message"},n),a.a.createElement("div",{className:"d-flex justify-content-end"},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary mr-2",onClick:e},"Cancel"),a.a.createElement("button",{type:"button",className:qe()("btn btn-primary btn-apply",{"btn-spinner":i}),onClick:this.handleSaveClick},i&&a.a.createElement("span",null,a.a.createElement(Yn,null),a.a.createElement("span",{className:"btn-normal-content"},"Applying"),a.a.createElement("span",{className:"btn-hover-content"},"Applying")),!i&&(t.length>1?"Save Columns":"Save Column")))))}}Iv.propTypes={model:pi.a.instanceOf(Cu).isRequired,customColumns:pi.a.arrayOf(pi.a.string),onSave:pi.a.func,onCancel:pi.a.func},Iv.defaultProps={customColumns:[],onSave:()=>{},onCancel:()=>{}};var Lv=Iv;n(1289);function Fv(){return Fv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Fv.apply(this,arguments)}function kv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Av extends i.PureComponent{static renderHandle(){return a.a.createElement("div",null,a.a.createElement(Ol,null,"Drag to re-order"),a.a.createElement(Ke.a,{icon:yt}))}static renderBadge(e){var{text:t}=e;return t?a.a.createElement("span",{className:"number-badge"},t):null}static renderTextItem(e){var{text:t,badgeText:n="",className:i=""}=e;return a.a.createElement("div",{className:qe()("item-list-item-content","draggable-item-list-item-content",i)},a.a.createElement("span",{className:"title"},t),Av.renderBadge({text:n}),Av.renderHandle())}static renderItem(e){var{item:t,isClone:n,selectedCount:i}=e,a=t&&(t.displayValue||t.value||"".concat(t)),s=n?"".concat(i):"",r=n?"item-list-item-clone":"";return Av.renderTextItem({text:a,badgeText:s,className:r})}static getDraggableId(e,t){return"".concat(e,"/").concat(t)}static getDraggableIndex(e){return parseInt(e.split("/").pop()||"",10)}constructor(e){super(e),kv(this,"itemList",void 0),kv(this,"getCachedDraggableItem",Lr()(((e,t,n,i,s,r,o,l)=>a.a.createElement(Kg.b,{key:i,draggableId:Av.getDraggableId(e,i),index:i,isDragDisabled:o},(e=>a.a.createElement("div",Fv({role:"menuitem",className:"draggable-item-list-item",ref:e.innerRef,tabIndex:-1},e.draggableProps,e.dragHandleProps),t({item:n,itemIndex:i,isFocused:s,isSelected:r,style:l,isClone:!1}))))),{max:nh.CACHE_SIZE})),kv(this,"getCachedRenderDraggableItem",Lr()(((e,t,n)=>i=>{var{item:a,itemIndex:s,isFocused:r,isSelected:o,style:l}=i;return this.getCachedDraggableItem(e,n,a,s,r,o,t,l)}),{max:1})),kv(this,"getCachedRenderClone",Lr()(((e,t,n,i)=>(s,r,o)=>{var{selectedCount:l}=this.state,{index:c}=o.source,h=t[c-n];return a.a.createElement("div",Fv({className:qe()("draggable-item-list-dragging-item-container",e)},s.draggableProps,s.dragHandleProps,{ref:s.innerRef}),a.a.createElement("div",{className:qe()("draggable-item-list-dragging-item",{"two-dragged":2===l},{"multiple-dragged":l>2})},i({item:h,itemIndex:c,isFocused:!1,isSelected:!0,style:{},isClone:!0,selectedCount:l})))}),{max:1})),this.handleSelectionChange=this.handleSelectionChange.bind(this),this.itemList=a.a.createRef(),this.state={selectedCount:0}}selectItem(e){var t;null===(t=this.itemList.current)||void 0===t||t.selectItem(e)}focusItem(e){var t;null===(t=this.itemList.current)||void 0===t||t.focusItem(e)}scrollToItem(e){var t;null===(t=this.itemList.current)||void 0===t||t.scrollToItem(e)}handleSelectionChange(e){this.setState({selectedCount:Wa.count(e)});var{onSelectionChange:t}=this.props;t(e)}render(){var{className:e,draggablePrefix:t,draggingItemClassName:n,droppableId:i,isDoubleClickSelect:s,isDragDisabled:r,isDropDisabled:o,isMultiSelect:l,isStickyBottom:c,itemCount:h,items:d,offset:u,onFocusChange:m,onSelect:p,onViewportChange:g,renderItem:v,rowHeight:f,selectedRanges:b,style:C}=this.props;return a.a.createElement(Kg.c,{isDropDisabled:o,droppableId:i,mode:"virtual",renderClone:this.getCachedRenderClone(n,d,u,v)},((n,i)=>a.a.createElement("div",Fv({role:"menu",className:qe()("draggable-item-list",e,{"is-drop-disabled":o,"is-drag-disabled":r,"is-dragging-from-this":i.draggingFromThisWith,"is-dragging-over":i.isDraggingOver,"is-dropping":i.draggingOverWith}),style:C,ref:n.innerRef},n.droppableProps),a.a.createElement(nh,{focusSelector:".draggable-item-list-item",isDoubleClickSelect:s,isDragSelect:!1,isMultiSelect:l,isStickyBottom:c,itemCount:h,items:d,onFocusChange:m,onSelect:p,onSelectionChange:this.handleSelectionChange,onViewportChange:g,offset:u,ref:this.itemList,renderItem:this.getCachedRenderDraggableItem(t,r,v),rowHeight:f,selectedRanges:b}))))}}kv(Av,"DEFAULT_ROW_HEIGHT",30),kv(Av,"defaultProps",{className:"",draggingItemClassName:"",offset:0,items:[],rowHeight:Av.DEFAULT_ROW_HEIGHT,isDeselectOnClick:!0,isDoubleClickSelect:!0,isDropDisabled:!1,isDragDisabled:!1,isMultiSelect:!1,isStickyBottom:!1,disableSelect:!1,style:null,onFocusChange(){},onSelect(){},onSelectionChange(){},onViewportChange(){},renderItem:Av.renderItem,selectedRanges:[],draggablePrefix:"draggable-item",droppableId:"droppable-item-list"});var Pv=Av;n(1288);function _v(){return _v=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},_v.apply(this,arguments)}function Hv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var jv=p.module("RollupRows"),Vv="grouped-rollup-rows",zv="ungrouped-rollup-rows";class Uv extends i.Component{static renderColumn(e){var{item:t,isClone:n,selectedCount:i}=e,a=t&&t.name,s=n?"".concat(i):null,r=n?"item-list-item-clone":"";return Pv.renderTextItem({text:a,badgeText:s,className:r})}static addGroupings(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length;if(null==t||0===t.length)return e;var i=n,a=e.filter(((e,n)=>!t.includes(e)||(n<i&&(i-=1),!1)));return a.splice(i,0,...t),a}static isGroupable(e){return!cs.isDecimalType(e.type)}constructor(e){super(e),Hv(this,"getCachedUngroupedColumns",Lr()(((e,t)=>e.filter((e=>Uv.isGroupable(e)&&!t.find((t=>t===e.name))))))),Hv(this,"getCachedSortedColumns",Lr()(((e,t)=>null==t?[...e]:cs.sortColumns(e,t===Uv.SORT.ASCENDING)))),this.search=pa()(this.search.bind(this),150),this.handleDeleteClicked=this.handleDeleteClicked.bind(this),this.handleSearchChange=this.handleSearchChange.bind(this),this.handleUngroupedSelect=this.handleUngroupedSelect.bind(this),this.handleUngroupedSelectionChange=this.handleUngroupedSelectionChange.bind(this),this.handleDragStart=this.handleDragStart.bind(this),this.handleDragEnd=this.handleDragEnd.bind(this),this.handleGroupedSelectionChange=this.handleGroupedSelectionChange.bind(this),this.handleShowConstituentsChange=this.handleShowConstituentsChange.bind(this),this.handleShowNonAggregatedColumnsChange=this.handleShowNonAggregatedColumnsChange.bind(this),this.handleSortAscending=this.handleSortAscending.bind(this),this.handleSortDescending=this.handleSortDescending.bind(this),this.renderGroupedItem=this.renderGroupedItem.bind(this),this.ungroupedList=a.a.createRef(),this.groupedList=a.a.createRef();var{config:t}=e,{columns:n=[],showConstituents:i=!0,showNonAggregatedColumns:s=!0}=null!==t&&void 0!==t?t:{};this.state={ungroupedSelectedRanges:[],columns:n,groupedSelectedRanges:[],searchFilter:"",showConstituents:i,showNonAggregatedColumns:s,dragSource:null,sort:null}}componentDidUpdate(e,t){var{config:n}=this.props,{columns:i,showConstituents:a,showNonAggregatedColumns:s}=this.state;n!==e.config?this.updateFromConfig():i===t.columns&&a===t.showConstituents&&s===t.showNonAggregatedColumns||null!=n&&i===n.columns&&a===n.showConstituents&&s===n.showNonAggregatedColumns||this.sendChange()}componentWillUnmount(){this.search.cancel()}handleSearchChange(e){var t=e.target.value;if(this.setState({searchFilter:t}),!t)return this.search.cancel(),void this.resetSelection();this.search(t)}handleSortAscending(){this.setState((e=>{var{sort:t}=e;return{sort:t===Uv.SORT.ASCENDING?null:Uv.SORT.ASCENDING}}))}handleSortDescending(){this.setState((e=>{var{sort:t}=e;return{sort:t===Uv.SORT.DESCENDING?null:Uv.SORT.DESCENDING}}))}resetSelection(){this.setState({ungroupedSelectedRanges:[],groupedSelectedRanges:[]})}search(e){for(var t=this.getSortedUngroupedColumns(),n=[],i=null,a=0;a<t.length;a+=1){t[a].name.toLowerCase().includes(e.toLowerCase())&&(null==i&&(i=a),n.push([a,a]))}this.setState({ungroupedSelectedRanges:n}),n.length>0&&this.ungroupedList.current&&this.ungroupedList.current.scrollToItem(i)}handleDragStart(e){jv.debug("handleDragStart",e),document.documentElement.classList.add("drag-pointer-events-none"),this.setState({dragSource:e.source})}handleDragEnd(e){jv.debug("handleDragEnd",e),document.documentElement.classList.remove("drag-pointer-events-none"),this.setState({dragSource:null});var{destination:t,source:n}=e;if(null!=t&&null!=n)if(t.droppableId!==zv){var i=n.droppableId===Vv,a=t.index;i&&n.index<t.index&&(a+=1),this.setState((e=>{var{columns:t,ungroupedSelectedRanges:n,groupedSelectedRanges:s}=e,r=[...t],o=i?r:this.getSortedUngroupedColumns().map((e=>e.name)),l=i?s:n,c=Ev.reorder(o,l,r,a),h=i?Ev.adjustDestinationIndex(a,s):a;return{columns:r,ungroupedSelectedRanges:[],groupedSelectedRanges:[[h,h+c.length-1]]}})),this.resetSelection()}else this.setState((e=>{var{groupedSelectedRanges:t,columns:n}=e,i=[...n];return Ev.reorder(i,t,[],0),{columns:i,ungroupedSelectedRanges:[],groupedSelectedRanges:[]}}))}handleUngroupedSelect(e){jv.debug("handleUngroupedSelect"),this.setState((t=>{var{columns:n}=t;return{columns:Uv.addGroupings(n,[this.getSortedUngroupedColumns()[e].name]),ungroupedSelectedRanges:[],groupedSelectedRanges:[]}}))}handleUngroupedSelectionChange(e){jv.debug2("handleUngroupedSelectionChange",e),this.setState((t=>{var{ungroupedSelectedRanges:n}=t;return e===n?null:{ungroupedSelectedRanges:e,groupedSelectedRanges:[]}}))}handleGroupedSelectionChange(e){jv.debug2("handleGroupedSelectedRanges",e),this.setState((t=>{var{groupedSelectedRanges:n}=t;return e===n?null:{groupedSelectedRanges:e,ungroupedSelectedRanges:[]}}))}handleDeleteClicked(e){this.setState((t=>{var{columns:n}=t,i=n.slice();return i.splice(e,1),{columns:i}}))}handleShowConstituentsChange(){this.setState((e=>{var{showConstituents:t}=e;return{showConstituents:!t}}))}handleShowNonAggregatedColumnsChange(){this.setState((e=>{var{showNonAggregatedColumns:t}=e;return{showNonAggregatedColumns:!t}}))}updateFromConfig(){var{config:e}=this.props,{columns:t=[],showConstituents:n=!0,showNonAggregatedColumns:i=!0}=null!==e&&void 0!==e?e:{};this.setState({columns:t,showConstituents:n,showNonAggregatedColumns:i})}sendChange(){var{onChange:e}=this.props,{columns:t,showConstituents:n,showNonAggregatedColumns:i}=this.state;e({columns:t,showConstituents:n,showNonAggregatedColumns:i})}getUngroupedColumns(){var{model:e}=this.props,{columns:t,searchFilter:n}=this.state,{originalColumns:i}=e;return this.getCachedUngroupedColumns(i,t,n)}getSortedUngroupedColumns(){var{sort:e}=this.state,t=this.getUngroupedColumns();return this.getCachedSortedColumns(t,e)}renderGroupedItem(e){var{item:t,itemIndex:n,isClone:i,selectedCount:s}=e,r=i?"":"\xa0\xa0".repeat(n),o="".concat(r).concat(t),l=i?"".concat(s):null,c=i?"item-list-item-clone":"";return a.a.createElement(a.a.Fragment,null,Pv.renderTextItem({text:o,badgeText:l,className:c}),!i&&a.a.createElement(Dc,{className:"btn btn-link btn-link-icon btn-delete-grouping float-right",onClick:()=>this.handleDeleteClicked(n)},a.a.createElement(Ke.a,{icon:$t})))}render(){var{columns:e,dragSource:t,searchFilter:n,groupedSelectedRanges:i,ungroupedSelectedRanges:s,showConstituents:r,showNonAggregatedColumns:o,sort:l}=this.state,c=this.getSortedUngroupedColumns(),h=e.length*Pv.DEFAULT_ROW_HEIGHT;(null===t||void 0===t?void 0:t.droppableId)===zv&&(h+=Pv.DEFAULT_ROW_HEIGHT);var d=c.length*Pv.DEFAULT_ROW_HEIGHT+10,u=Math.min(3*Pv.DEFAULT_ROW_HEIGHT,d);return a.a.createElement("div",{role:"menu",className:qe()("rollup-rows",{"is-dragging":null!=t}),tabIndex:"0"},a.a.createElement(Kg.a,{onDragEnd:this.handleDragEnd,onDragStart:this.handleDragStart},a.a.createElement("div",{className:"rollup-rows-group-by"},a.a.createElement("div",{className:"section-title"},"Group By"),0===e.length&&a.a.createElement(Kg.c,{isDragDisabled:!0,droppableId:"placeholder"},((e,t)=>a.a.createElement("div",_v({className:qe()("placeholder","text-muted",{"is-dragging-from-this":t.draggingFromThisWith,"is-dragging-over":t.isDraggingOver,"is-dropping":t.draggingOverWith}),ref:e.innerRef},e.droppableProps),"Create rollup by dragging columns here, from the available columns list below."))),e.length>0&&a.a.createElement(Pv,{draggingItemClassName:"rollup-rows-dragging-grouped-item",draggablePrefix:Vv,droppableId:Vv,itemCount:e.length,items:e,offset:0,onSelectionChange:this.handleGroupedSelectionChange,ref:this.groupedList,renderItem:this.renderGroupedItem,selectedRanges:i,style:{height:h},isMultiSelect:!0})),a.a.createElement("div",{className:"rollup-rows-available-columns"},a.a.createElement("div",{className:"section-title"},"Available Grouping Columns"),a.a.createElement("div",{className:"top-menu"},a.a.createElement(Gc,{className:"w-100",value:n,matchCount:n?s.length:null,placeholder:"Find column...",onChange:this.handleSearchChange}),a.a.createElement(Dc,{className:qe()("btn-link btn-link-icon",{active:l===Uv.SORT.ASCENDING}),onClick:this.handleSortAscending},a.a.createElement(Ke.a,{icon:Dn}),a.a.createElement(Ol,null,"Sort ascending")),a.a.createElement(Dc,{className:qe()("btn-link btn-link-icon",{active:l===Uv.SORT.DESCENDING}),onClick:this.handleSortDescending},a.a.createElement(Ke.a,{icon:xn}),a.a.createElement(Ol,null,"Sort descending"))),a.a.createElement(Pv,{className:"rollup-available-grouping-columns",draggablePrefix:zv,droppableId:zv,itemCount:c.length,items:c,renderItem:Uv.renderColumn,offset:0,onSelect:this.handleUngroupedSelect,onSelectionChange:this.handleUngroupedSelectionChange,ref:this.ungroupedList,selectedRanges:s,style:{maxHeight:d,minHeight:u},isDropDisabled:(null===t||void 0===t?void 0:t.droppableId)!==Vv,isMultiSelect:!0}),a.a.createElement("div",{className:"bottom-menu"},a.a.createElement("div",{className:"label"},"Show:"),a.a.createElement(Ed,{checked:r,onChange:this.handleShowConstituentsChange},"Constituents"),a.a.createElement(Ed,{checked:o,onChange:this.handleShowNonAggregatedColumnsChange},"Non-Aggregated Columns")))))}}Hv(Uv,"SORT",Object.freeze({ASCENDING:"ASCENDING",DESCENDING:"DESCENDING"})),Uv.propTypes={model:pi.a.instanceOf(Cu).isRequired,onChange:pi.a.func,config:pi.a.shape({columns:pi.a.arrayOf(pi.a.string),showConstituents:pi.a.bool,showNonAggregatedColumns:pi.a.bool})},Uv.defaultProps={config:null,onChange:()=>{}};var Bv=Uv,Wv=e=>{var{children:t,onChange:n,className:s,defaultValue:r,value:o,disabled:l}=e,c=Object(i.useCallback)((e=>{n(e.target.value)}),[n]);return a.a.createElement("select",{className:qe()("custom-select",s),onChange:c,defaultValue:r,value:o,disabled:l},t)},Gv=e=>{var{children:t,value:n}=e;return a.a.createElement("option",{value:n},t)};n(1290);function qv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Kv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qv(Object(n),!0).forEach((function(t){Yv(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Yv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Xv,Zv=p.module("Aggregations"),$v=[Xo.SUM,Xo.ABS_SUM,Xo.MIN,Xo.MAX,Xo.VAR,Xo.AVG,Xo.STD,Xo.FIRST,Xo.LAST,Xo.COUNT_DISTINCT,Xo.DISTINCT,Xo.COUNT,Xo.UNIQUE],Qv=e=>{var{isRollup:t,settings:n,onChange:s,onEdit:r}=e,{aggregations:o,showOnTop:l}=n,c=Object(i.useMemo)((()=>$v.filter((e=>!o.some((t=>t.operation===e))))),[o]),[h,d]=Object(i.useState)(c[0]),[u,m]=Object(i.useState)([]),p=Object(i.useCallback)((e=>{s(Kv(Kv({},n),e))}),[s,n]),g=Object(i.useCallback)((e=>{p({aggregations:e})}),[p]),v=Object(i.useCallback)((e=>{p({showOnTop:e})}),[p]),f=Object(i.useCallback)((()=>{Zv.debug("handleDragStart"),Ev.startDragging()}),[]),b=Object(i.useCallback)((e=>{var{destination:t,source:n}=e;if(Zv.debug("handleDragEnd",t,n),Ev.stopDragging(),null!==t){var i=t.index;n.index<t.index&&(i+=1);var a=[...o],s=Ev.reorder(a,u,a,i),r=Ev.adjustDestinationIndex(i,u),l=[[r,r+s.length-1]];g(a),m(l)}}),[g,o,u,m]),C=Object(i.useCallback)((e=>{d(e)}),[d]),S=Object(i.useCallback)((()=>{g([...o,{operation:h,selected:[],invert:!0}])}),[o,h,g]),E=Object(i.useCallback)((e=>{g(o.filter(((t,n)=>n!==e)))}),[o,g]),w=Object(i.useCallback)((e=>{m(e)}),[m]),y=Object(i.useCallback)((e=>{var t=o[e];$o(t.operation)||r(t)}),[o,r]),T=Object(i.useCallback)((e=>{v("true"===e.target.value)}),[v]);Object(i.useEffect)((()=>{c.length>0&&!c.includes(h)&&d(c[0])}),[c,h]);var O=Object(i.useCallback)((e=>{var{item:n,itemIndex:i,isClone:s,selectedCount:o}=e,l=n.operation,c=s?"".concat(o):void 0,h=s?"item-list-item-clone":void 0,d=$o(n.operation),u=!s&&!d;return a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:qe()("item-list-item-content","draggable-item-list-item-content",h)},a.a.createElement("span",{className:"title"},l,!t&&d&&a.a.createElement("span",{className:"small text-warning"},a.a.createElement(Ke.a,{icon:zn})," Requires rollup")),Pv.renderBadge({text:c}),Pv.renderHandle()),!s&&a.a.createElement(a.a.Fragment,null,a.a.createElement(gh,{kind:"ghost",className:"btn-edit",icon:mt,tooltip:"Edit Columns",onClick:()=>r(n),disabled:!u}),a.a.createElement(gh,{kind:"ghost",className:"btn-delete",icon:$t,tooltip:"Delete Aggregation",onClick:()=>E(i)})))}),[E,r,t]),M=c.length>0,N=o.length>0;return a.a.createElement("div",{className:"aggregations"},M&&a.a.createElement("div",{className:"form-inline"},a.a.createElement(Wv,{onChange:C,value:h},c.map((e=>a.a.createElement(Gv,{value:e,key:e},e)))),a.a.createElement("button",{type:"button",className:"btn btn-link btn-add",onClick:S},a.a.createElement(Ke.a,{icon:wn}),"Add Aggregation")),M&&N&&a.a.createElement("hr",null),N&&a.a.createElement(a.a.Fragment,null,!t&&a.a.createElement("div",{className:"form-inline"},a.a.createElement("label",null,"Placement:\xa0"),a.a.createElement(Jg,{onChange:T,value:"".concat(l)},a.a.createElement(tv,{value:"true"},"Top"),a.a.createElement(tv,{value:"false"},"Bottom"))),a.a.createElement(Kg.a,{onDragStart:f,onDragEnd:b},a.a.createElement(Pv,{className:"selected-aggregations",itemCount:o.length,items:o,renderItem:O,offset:0,onSelectionChange:w,onSelect:y,selectedRanges:u,isMultiSelect:!0}))))};n(1291);function Jv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function ef(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jv(Object(n),!0).forEach((function(t){tf(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function tf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e[e.NONE=0]="NONE",e[e.ASCENDING=1]="ASCENDING",e[e.DESCENDING=2]="DESCENDING"}(Xv||(Xv={}));var nf=e=>{var{aggregation:t,columns:n,onChange:s}=e,[r,o]=Object(i.useState)(-1),[l,c]=Object(i.useState)(-1),[h,d]=Object(i.useState)(Xv.NONE),{invert:u,selected:m}=t,p=Object(i.useRef)(null),g=Object(i.useCallback)((e=>m.includes(e)?!u:u),[u,m]),v=Object(i.useMemo)((()=>{var e=Zo(n,t.operation);return h!==Xv.NONE&&(e=cs.sortColumns(e,h===Xv.ASCENDING)),e}),[n,t.operation,h]),f=Object(i.useMemo)((()=>r>=0?v.slice(r,l+1).map((e=>({value:e.name,displayValue:e.name,isSelected:g(e.name)}))):[]),[v,g,l,r]),b=Object(i.useCallback)((e=>{var{name:n}=v[e],i=m.indexOf(n),a=[...m],r=u;i>=0?a.splice(i,1):(a.push(n),a.length===v.length&&(a=[],r=!u)),s(ef(ef({},t),{},{selected:a,invert:r}))}),[t,u,v,m,s]),C=Object(i.useCallback)((()=>{d(Xv.NONE),s(ef(ef({},t),{},{selected:[],invert:!0}))}),[t,s]),S=Object(i.useCallback)(((e,t)=>{o(e),c(t)}),[o,c]),E=Object(i.useCallback)((()=>{0===m.length?s(ef(ef({},t),{},{invert:!u})):s(ef(ef({},t),{},{selected:[],invert:!0}))}),[t,u,s,m]),w=0===m.length?u:null,y=0!==m.length||!u||h!==Xv.NONE;return a.a.createElement("div",{role:"menu",className:"aggregation-edit"},a.a.createElement("div",{className:"top-menu"},a.a.createElement("div",{className:"form-inline"},a.a.createElement(Ed,{checked:w,onChange:E},"Toggle All"),a.a.createElement("div",{className:"spacer"}),a.a.createElement(We.CSSTransition,{in:y,timeout:Kn.transitionSlowMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0},a.a.createElement(gh,{kind:"ghost",className:"btn-reset",onClick:C},"Reset")),a.a.createElement(gh,{kind:"ghost",className:qe()({active:h===Xv.ASCENDING}),icon:Dn,tooltip:"Sort ascending",onClick:()=>d(Xv.ASCENDING)}),a.a.createElement(gh,{kind:"ghost",className:qe()({active:h===Xv.DESCENDING}),icon:xn,tooltip:"Sort descending",onClick:()=>d(Xv.DESCENDING)}))),a.a.createElement("div",{className:"aggregation-edit-item-list"},a.a.createElement(th,{itemCount:v.length,items:f,offset:r,renderItem:e=>{var{item:t}=e;return a.a.createElement(Ed,{checked:g(t.value)},t.displayValue)},onSelect:b,onViewportChange:S,rowHeight:30,focusSelector:"input",ref:p})))},af=n(728);function sf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rf=p.module("TableSaver");class of extends i.PureComponent{static csvEscapeString(e){return'"'.concat(e.replace(/"/g,'""'),'"')}constructor(e){super(e),this.handlePortMessage=this.handlePortMessage.bind(this),this.handleSnapshotResolved=this.handleSnapshotResolved.bind(this),this.handleDownloadTimeout=this.handleDownloadTimeout.bind(this),this.state={},this.sw=null,this.port=null,this.fileWriter=null,this.table=null,this.tableSubscription=null,this.columns=null,this.fileName=null,this.chunkRows=null,this.gridRanges=[],this.gridRangeCounter=0,this.rangedSnapshotsTotal=[],this.rangedSnapshotCounter=0,this.snapshotsTotal=0,this.snapshotCounter=0,this.snapshotsBuffer=new Map,this.currentSnapshotIndex=0,this.snapshotPending=0,this.cancelableSnapshots=[],this.WritableStream=window.WritableStream||af.WritableStream,this.streamTimeout=null,this.snapshotHandlerTimeout=null,this.downloadStartTime=null,this.iframes=[],this.useBlobFallback=!!window.safari}componentDidMount(){var{getDownloadWorker:e}=this.props;e().then((e=>{rf.info("found active service worker"),this.sw=e,this.sw.postMessage("ping")})).catch((e=>{rf.warn("Download csv is not optimized.",e),this.useBlobFallback=!0}))}componentWillUnmount(){this.iframes.length>0&&this.iframes.forEach((e=>{e.remove()})),clearTimeout(this.streamTimeout),clearTimeout(this.snapshotHandlerTimeout)}createWriterStream(e){var t=this.useBlobFallback,n=[],i=null;t&&(i=TextEncoder.prototype.encode.bind(new TextEncoder));var{fileName:a}=this,s={};return t?(s.write=e=>{n.push(i(e.rows))},s.close=()=>{var e=new Blob(n,{type:"application/octet-stream; charset=utf-8"}),t=document.createElement("a");t.href=URL.createObjectURL(e),t.download=a,t.click()},s.abort=()=>{e.postMessage({cancel:!0}),e.close()}):(s.write=t=>{e.postMessage(t)},s.close=()=>{e.postMessage({end:!0}),e.close()},s.abort=()=>{e.postMessage({cancel:!0}),e.close()}),new this.WritableStream(s)}startDownload(e,t,n,i){var{isDownloading:a}=this.props;if(!a){this.downloadStartTime=Date.now(),rf.info("start downloading ".concat(e)),this.table=t,this.columns=t.columns,this.tableSubscription=n,this.gridRanges=i;var s=encodeURIComponent(e.replace(/\//g,":")).replace(/['()]/g,escape).replace(/\*/g,"%2A"),r=new MessageChannel;this.port=r.port1,this.fileName=e,this.fileWriter=this.createWriterStream(this.port).getWriter(),this.useBlobFallback?this.writeCsvTable():(this.sw&&this.sw.postMessage({encodedFileName:s},[r.port2]),this.port.onmessage=this.handlePortMessage)}}finishDownload(){this.table&&this.table.close(),this.tableSubscription&&this.tableSubscription.close(),this.fileWriter&&this.fileWriter.close();var{onDownloadCompleted:e}=this.props;e(),this.resetTableSaver(),rf.info("download finished, total elapsed time ".concat((Date.now()-this.downloadStartTime)/1e3," seconds"))}cancelDownload(){this.table&&this.table.close(),this.tableSubscription&&this.tableSubscription.close(),this.fileWriter&&this.fileWriter.abort(),this.cancelableSnapshots.forEach((e=>{e&&(e.catch((()=>{})),e.cancel())}));var{onDownloadCanceled:e}=this.props;e(),this.resetTableSaver()}resetTableSaver(){this.table=null,this.tableSubscription=null,this.columns=null,this.chunkRows=null,this.gridRanges=[],this.gridRangeCounter=0,this.rangedSnapshotsTotal=[],this.rangedSnapshotCounter=0,this.snapshotsTotal=0,this.snapshotCounter=0,this.snapshotsBuffer=new Map,this.currentSnapshotIndex=0,this.snapshotPending=0,this.cancelableSnapshots=[],clearTimeout(this.streamTimeout),clearTimeout(this.snapshotHandlerTimeout),this.streamTimeout=null,this.snapshotHandlerTimeout=null}handleDownloadTimeout(){rf.info("download canceled"),this.cancelDownload()}writeTableHeader(){for(var e="",t=0;t<this.columns.length;t+=1)e+=this.columns[t].name,e+=t===this.columns.length-1?"\n":",";this.fileWriter.write({header:e}).then((()=>{}))}startWriteTableBody(){this.chunkRows=Math.floor(of.DOWNLOAD_CELL_CHUNK/this.columns.length),this.rangedSnapshotsTotal=this.gridRanges.map((e=>Math.ceil((e.endRow-e.startRow+1)/this.chunkRows))),this.snapshotsTotal=this.rangedSnapshotsTotal.reduce(((e,t)=>e+t)),rf.info("start writing table, total snapshots: ",this.snapshotsTotal),this.makeSnapshot(Math.min(of.SNAPSHOT_BUFFER_SIZE,this.snapshotsTotal))}writeCsvTable(){this.writeTableHeader(),this.startWriteTableBody()}writeSnapshot(e,t,n){if(this.currentSnapshotIndex===e&&this.fileWriter){for(;this.snapshotsBuffer.has(this.currentSnapshotIndex);)this.fileWriter.write({rows:this.convertSnapshotIntoCsv(this.snapshotsBuffer.get(this.currentSnapshotIndex),t,n)}),this.snapshotsBuffer.delete(this.currentSnapshotIndex),this.currentSnapshotIndex+=1,this.updateDownloadProgress(e);if(this.currentSnapshotIndex>=this.snapshotsTotal)return void this.finishDownload()}this.snapshotCounter<this.snapshotsTotal&&(rf.debug2("\n current range index: ".concat(this.gridRangeCounter,", \n snapshotIndexCounter: ").concat(this.snapshotCounter,", \n currentRangedSnapshotIndex : ").concat(this.rangedSnapshotCounter,", \n snapshotpending: ").concat(this.snapshotPending,", \n buffered ").concat(this.snapshotsBuffer.size,"\n making ").concat(Math.min(of.SNAPSHOT_BUFFER_SIZE-this.snapshotsBuffer.size-this.snapshotPending,this.snapshotsTotal-this.snapshotCounter)," more snapshots\n ")),this.makeSnapshot(Math.min(of.SNAPSHOT_BUFFER_SIZE-this.snapshotsBuffer.size-this.snapshotPending,this.snapshotsTotal-this.snapshotCounter)))}updateDownloadProgress(e){var{onDownloadProgressUpdate:t}=this.props;t(Math.floor(100*e/this.snapshotsTotal),e>1?Math.floor((Date.now()-this.downloadStartTime)*(this.snapshotsTotal-e)/e/1e3):null)}convertSnapshotIntoCsv(e){for(var t="",n=e.added.iterator(),{formatter:i}=this.props,a=[];n.hasNext();)a.push(n.next().value);for(var s=0;s<a.length;s+=1)for(var r=a[s],o=0;o<this.columns.length;o+=1){var l=i.getFormattedString(e.getData(r,this.columns[o]),this.columns[o].type,this.columns[o].name);t+=of.csvEscapeString(l),t+=o===this.columns.length-1?"\n":","}return t}makeSnapshot(e){var t=this;if(!(e<=0))for(var n=0,i=this.gridRanges[this.gridRangeCounter],a=function(){var e=i.startRow+t.rangedSnapshotCounter*t.chunkRows,a=Math.min(e+t.chunkRows-1,i.endRow),s=t.snapshotCounter;t.cancelableSnapshots.push(Va.makeCancelable(t.tableSubscription.snapshot(va.RangeSet.ofRange(e,a),t.columns).then((n=>(t.handleSnapshotResolved(n,s,e,a),s))).catch((e=>{rf.error(e)})),(e=>{rf.info("snapshot ".concat(e," has been canceled"))}))),t.rangedSnapshotCounter+=1,t.snapshotCounter+=1,t.snapshotPending+=1,t.rangedSnapshotCounter>=t.rangedSnapshotsTotal[t.gridRangeCounter]&&(t.gridRangeCounter+=1,t.rangedSnapshotCounter=0,i=t.gridRanges[t.gridRangeCounter]),n+=1};n<e;)a()}handlePortMessage(e){var{data:t}=e,{download:n,readableStreamPulling:i}=t;this.useBlobFallback||(n&&(this.makeIframe("".concat(n)),this.writeCsvTable()),i&&(this.useBlobFallback||(clearTimeout(this.streamTimeout),this.streamTimeout=setTimeout(this.handleDownloadTimeout,of.STREAM_TIMEOUT))))}handleSnapshotResolved(e,t,n,i){this.snapshotHandlerTimeout=setTimeout((()=>{this.snapshotsBuffer.set(t,e),this.snapshotPending-=1,this.writeSnapshot(t,n,i),this.cancelableSnapshots[t]=null}),of.SNAPSHOT_HANDLER_TIMEOUT)}makeIframe(e){var t=document.createElement("iframe");t.hidden=!0,t.src="download/".concat(e),t.loaded=!1,t.name="iframe",t.isIframe=!0,t.addEventListener("load",(()=>{t.loaded=!0}),!1),document.body.appendChild(t),this.iframes.push(t)}render(){return null}}sf(of,"DOWNLOAD_CELL_CHUNK",6e3),sf(of,"SNAPSHOT_BUFFER_SIZE",5),sf(of,"STREAM_TIMEOUT",8e3),sf(of,"SNAPSHOT_HANDLER_TIMEOUT",5),of.propTypes={getDownloadWorker:pi.a.func,isDownloading:pi.a.bool,onDownloadCompleted:pi.a.func,onDownloadCanceled:pi.a.func,onDownloadProgressUpdate:pi.a.func,formatter:pi.a.instanceOf(Hs).isRequired},of.defaultProps={getDownloadWorker:()=>Promise.reject(new Error("Download worker not provided")),isDownloading:!1,onDownloadCompleted:()=>{},onDownloadCanceled:()=>{},onDownloadProgressUpdate:()=>{}};n(1279);class lf extends i.PureComponent{static createSearchFilter(e,t,n,i){var a=i?n.filter((e=>!t.includes(e.name))).map((e=>e.name)):t;if(e&&a.length>0){var s=va.FilterValue.ofString(e);return a.length===n.length?va.FilterCondition.search(s):va.FilterCondition.search(s,n.filter((e=>a.includes(e.name))).map((e=>e.filter())))}return null}constructor(e){super(e),this.handleSearchValueChange=this.handleSearchValueChange.bind(this),this.toggleColumn=this.toggleColumn.bind(this),this.selectAll=this.selectAll.bind(this),this.clear=this.clear.bind(this),this.selectNumbers=this.selectNumbers.bind(this),this.searchField=a.a.createRef(),this.state={isConfigureColumnsShown:!1}}focus(){this.searchField.current.focus()}handleSearchValueChange(e){var{onChange:t,selectedColumns:n,invertSelection:i}=this.props;t(e.target.value,n,i)}sendColumnChange(e,t){var{onChange:n,value:i}=this.props;n(i,e,t)}setInvertSelection(e){var{onChange:t,value:n}=this.props;t(n,[],e)}toggleColumn(e){var{selectedColumns:t,invertSelection:n}=this.props;if(t.includes(e))this.sendColumnChange(t.filter((t=>t!==e)),n);else{var i=t.slice();i.push(e),this.sendColumnChange(i,n)}}selectAll(){this.setInvertSelection(!0)}clear(){this.setInvertSelection(!1)}selectNumbers(){var{columns:e}=this.props;this.sendColumnChange(e.filter((e=>cs.isNumberType(e.type))).map((e=>e.name)),!1)}render(){var e,{value:t,selectedColumns:n,invertSelection:i,columns:s}=this.props,{isConfigureColumnsShown:r}=this.state,o=0===n.length&&!0===i||n.length===s.length&&!1===i,l=0===n.length&&!1===i||n.length===s.length&&!0===i;return e=o?a.a.createElement(a.a.Fragment,null,a.a.createElement(Ke.a,{icon:kn,mask:fn,transform:"shrink-2 down-5 right-7"}),a.a.createElement(Ke.a,{icon:sn,className:"text-primary",transform:"shrink-4 down-5 right-7"})):l?a.a.createElement(a.a.Fragment,null,a.a.createElement(Ke.a,{icon:at,mask:fn,transform:"shrink-1 down-5 right-7"}),a.a.createElement(Ke.a,{icon:Vn,className:"text-danger",transform:"shrink-4 down-5 right-7"})):a.a.createElement(a.a.Fragment,null,a.a.createElement(Ke.a,{icon:kn,mask:fn,transform:"shrink-2 down-5 right-7"}),a.a.createElement(Ke.a,{icon:Mn,className:"text-primary",transform:"shrink-4 down-5 right-7"})),a.a.createElement("div",{className:"cross-column-container"},a.a.createElement(Gc,{className:"cross-column-search",placeholder:"Search Data...",value:t,onChange:this.handleSearchValueChange,ref:this.searchField}),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon px-2",onClick:()=>{r?this.setState({isConfigureColumnsShown:!1}):this.setState({isConfigureColumnsShown:!0})}},a.a.createElement("div",{className:"fa-layers"},e),a.a.createElement(Ol,null,"Configure Columns"),a.a.createElement(El,{isShown:r,className:"cross-column-popper",onExited:()=>{this.setState({isConfigureColumnsShown:!1})},closeOnBlur:!0,interactive:!0},a.a.createElement("div",{className:"cross-column-popup"},"Searched Columns",a.a.createElement("div",{className:"cross-column-scroll"},s.map((e=>a.a.createElement(a.a.Fragment,{key:e.name},a.a.createElement(Ed,{className:"cross-column-checkbox",checked:i?!n.includes(e.name):n.includes(e.name),onChange:()=>this.toggleColumn(e.name)},e.name),e.type.substring(e.type.lastIndexOf(".")+1))))),a.a.createElement("div",{className:"cross-column-button-bar"},a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.selectAll},"Select All"),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.clear},"Clear"),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.selectNumbers},"Numbers Only")),l&&a.a.createElement("p",{className:"text-danger"},a.a.createElement(Ke.a,{icon:Vn})," Select at least one column to search.")))))}}lf.propTypes={value:pi.a.string.isRequired,selectedColumns:pi.a.arrayOf(pi.a.string).isRequired,invertSelection:pi.a.bool.isRequired,onChange:pi.a.func.isRequired,columns:pi.a.arrayOf(pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired})).isRequired};var cf=lf;n(1297);var hf=p.module("PartitionSelectorSearch");class df extends i.Component{static handleError(e){e instanceof Da||hf.error(e)}constructor(e){super(e),this.debounceUpdateFilter=pa()(this.debounceUpdateFilter.bind(this),150),this.handleFilterChange=this.handleFilterChange.bind(this),this.handleInputFocus=this.handleInputFocus.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleListKeydown=this.handleListKeydown.bind(this),this.handleSelect=this.handleSelect.bind(this),this.handleTableUpdate=this.handleTableUpdate.bind(this),this.handleTextChange=this.handleTextChange.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.itemList=null,this.searchInput=null,this.timer=null,this.state={offset:0,itemCount:0,items:[],text:"",isLoading:!0}}componentDidMount(){this.startListening()}componentDidUpdate(e,t){var{isLoading:n,itemCount:i}=this.state,{onListResized:a}=this.props;i===t.itemCount&&n===t.isLoading||a()}componentWillUnmount(){this.debounceUpdateFilter.cancel(),this.stopListening()}handleKeyDown(e){if(null==this.itemList)return!1;var{items:t,itemCount:n}=this.state;switch(e.key){case"Enter":var i=null;if(t.length>0)i=t[0].value;else{var{text:a}=this.state;i=a.trim()}if(i.length>0){var{onSelect:s}=this.props;s(i)}return e.stopPropagation(),e.preventDefault(),!0;case"ArrowDown":return n>0&&this.itemList.focusItem(1),e.stopPropagation(),e.preventDefault(),!0;default:return!1}}handleListKeydown(e){if("Escape"===e.key);else this.focus()}handleFilterChange(){hf.debug2("handleFilterChange");var{table:e}=this.props,t=e.size;this.setState({itemCount:t,isLoading:!0})}handleInputFocus(){this.itemList&&this.itemList.focusItem(0)}handleSelect(e){hf.debug2("handleSelect",e);var{onSelect:t}=this.props,{offset:n,items:i}=this.state,a=e-n;if(a<0||i.length<=a)hf.error("No data for item",e);else{var{value:s}=i[a];t(s)}}handleTableUpdate(e){for(var t=e.detail,{offset:n}=t,i=[],{getFormattedString:a,table:s}=this.props,r=s.columns[0],o=0;o<t.rows.length;o+=1){var l=t.rows[o].get(r),c=a(l,r.type,r.name);i.push({displayValue:c,value:l})}var h=s.size;hf.debug2("handleTableUpdate",h,n,i.length),this.setState({itemCount:h,items:i,offset:n,isLoading:!1})}handleTextChange(e){hf.debug2("handleTextChange");var{value:t}=e.target;this.setState({text:t}),this.debounceUpdateFilter()}handleViewportChange(e,t){hf.debug2("handleViewportChange",e,t);var n=Math.max(1,t-e),i=Math.max(0,e-n),a=t+n,{table:s}=this.props;s.setViewport(i,a)}debounceUpdateFilter(){this.updateFilter()}focus(){this.searchInput&&this.searchInput.focus()}startListening(){var{initialPageSize:e,table:t}=this.props;t.addEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate),t.addEventListener(va.Table.EVENT_FILTERCHANGED,this.handleFilterChange),t.setViewport(0,e)}stopListening(){var{table:e}=this.props;e.removeEventListener(va.Table.EVENT_UPDATED,this.handleTableUpdate),e.removeEventListener(va.Table.EVENT_FILTERCHANGED,this.handleFilterChange)}updateFilter(){var{initialPageSize:e,table:t}=this.props,{text:n}=this.state,i=n.trim(),a=[];if(i.length>0){var s=t.columns[0].filter().invoke("matches",va.FilterValue.ofString("(?s)(?i).*\\Q".concat(i,"\\E.*")));a.push(s)}hf.debug2("updateFilter",a),t.applyFilter(a),t.setViewport(0,e)}render(){var{isLoading:e,itemCount:t,items:n,offset:i,text:s}=this.state,r=Math.min(t,df.MAX_VISIBLE_ITEMS)*th.DEFAULT_ROW_HEIGHT+11;return a.a.createElement("div",{className:"iris-grid-partition-selector-search"},a.a.createElement("div",{className:"search-container"},a.a.createElement("input",{type:"text",ref:e=>{this.searchInput=e},value:s,placeholder:"Available Partitions",onChange:this.handleTextChange,onFocus:this.handleInputFocus,onKeyDown:this.handleKeyDown,className:"form-control input-partition"})),!e&&t>0&&a.a.createElement("div",{className:"iris-grid-partition-selector-search-list",onKeyDown:this.handleListKeydown,role:"presentation",style:{height:r}},a.a.createElement(th,{ref:e=>{this.itemList=e},itemCount:t,items:n,offset:i,onSelect:this.handleSelect,onViewportChange:this.handleViewportChange})),!e&&0===t&&a.a.createElement("div",{className:"iris-grid-partition-selector-search-empty"},"No results"),e&&a.a.createElement("div",{className:"iris-grid-partition-selector-loading"},a.a.createElement(Yn,null),"\xa0Loading..."))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(df,"MAX_VISIBLE_ITEMS",12),df.propTypes={getFormattedString:pi.a.func.isRequired,table:pi.a.shape({addEventListener:pi.a.func.isRequired,removeEventListener:pi.a.func.isRequired,columns:pi.a.arrayOf(pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired,filter:pi.a.func.isRequired})),size:pi.a.number.isRequired,applyFilter:pi.a.func.isRequired,setViewport:pi.a.func.isRequired}).isRequired,initialPageSize:pi.a.number,onSelect:pi.a.func,onListResized:pi.a.func},df.defaultProps={initialPageSize:100,onSelect:()=>{},onListResized:()=>{}};var uf=df,mf=(n(1296),p.module("IrisGridPartitionSelector"));class pf extends i.Component{constructor(e){super(e),this.debounceUpdate=pa()(this.debounceUpdate.bind(this),250),this.handleAppendClick=this.handleAppendClick.bind(this),this.handleCloseClick=this.handleCloseClick.bind(this),this.handleIgnoreClick=this.handleIgnoreClick.bind(this),this.handlePartitionChange=this.handlePartitionChange.bind(this),this.handlePartitionSelect=this.handlePartitionSelect.bind(this),this.handlePartitionListResized=this.handlePartitionListResized.bind(this),this.handleSearchOpened=this.handleSearchOpened.bind(this),this.handleSearchClosed=this.handleSearchClosed.bind(this),this.searchMenu=null,this.selectorSearch=null;var{partition:t}=e;this.state={partition:t}}componentWillUnmount(){this.debounceUpdate.cancel()}handleAppendClick(){mf.debug2("handleAppendClick");var{onAppend:e}=this.props,{partition:t}=this.state;e(t)}handleCloseClick(){mf.debug2("handleCloseClick"),this.sendDone()}handleIgnoreClick(){mf.debug2("handleIgnoreClick"),this.sendFetchAll()}handlePartitionChange(e){mf.debug2("handlePartitionChange");var{value:t}=e.target;this.setState({partition:t}),this.debounceUpdate()}handlePartitionSelect(e){this.searchMenu&&this.searchMenu.closeMenu(),this.setState({partition:e},(()=>{this.sendUpdate()}))}handlePartitionListResized(){this.searchMenu&&this.searchMenu.scheduleUpdate()}handleSearchClosed(){var{table:e}=this.props;e.applyFilter([])}handleSearchOpened(){this.selectorSearch&&this.selectorSearch.focus()}debounceUpdate(){this.sendUpdate()}sendDone(){this.debounceUpdate.flush();var{onDone:e}=this.props;e()}sendUpdate(){mf.debug2("sendUpdate");var{onChange:e}=this.props,{partition:t}=this.state;e(t)}sendFetchAll(){mf.debug2("sendFetchAll"),this.debounceUpdate.cancel();var{onFetchAll:e}=this.props;e()}render(){var{columnName:e,getFormattedString:t,onDone:n,table:i}=this.props,{partition:s}=this.state,r=a.a.createElement(uf,{key:"search",getFormattedString:t,table:i,onSelect:this.handlePartitionSelect,onListResized:this.handlePartitionListResized,ref:e=>{this.selectorSearch=e}});return a.a.createElement("div",{className:"iris-grid-partition-selector"},a.a.createElement("div",{className:"status-message"},a.a.createElement("span",null,'Filtering "',e,'" partition to')),a.a.createElement("div",{className:"input-group"},a.a.createElement("input",{type:"text",value:s,onChange:this.handlePartitionChange,className:"form-control input-partition"}),a.a.createElement("div",{className:"input-group-append"},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary"},a.a.createElement(Ke.a,{icon:Qt}),a.a.createElement(Ol,null,"Partitions"),a.a.createElement(nu,{ref:e=>{this.searchMenu=e},actions:[{menuElement:r}],onMenuOpened:this.handleSearchOpened,onMenuClosed:this.handleSearchClosed})))),a.a.createElement("div",{className:"iris-grid-partition-selector-spacer"}),a.a.createElement("button",{type:"button",className:"btn btn-outline-primary btn-ignore",onClick:this.handleIgnoreClick},"Ignore & Fetch All"),a.a.createElement("button",{type:"button",className:"btn btn-outline-primary btn-append",onClick:this.handleAppendClick},"Append Command"),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-close",onClick:n},a.a.createElement(Ke.a,{icon:lt})))}}pf.propTypes={getFormattedString:pi.a.func.isRequired,table:pi.a.shape({applyFilter:pi.a.func}).isRequired,columnName:pi.a.string.isRequired,partition:pi.a.string,onAppend:pi.a.func,onChange:pi.a.func,onFetchAll:pi.a.func,onDone:pi.a.func},pf.defaultProps={onAppend:()=>{},onChange:()=>{},onFetchAll:()=>{},onDone:()=>{},partition:""};var gf=pf,vf=(n(1292),p.module("SelectDistinctBuilder"));class ff extends i.Component{constructor(e){super(e),this.handleAddColumnClick=this.handleAddColumnClick.bind(this),this.handleDeleteColumn=this.handleDeleteColumn.bind(this),this.handleDropdownChanged=this.handleDropdownChanged.bind(this);var{model:t,selectDistinctColumns:n}=this.props;this.state={inputs:n.length>0?[...n]:[""],columns:t.originalColumns}}componentDidUpdate(e,t){var{inputs:n}=this.state,{onChange:i}=this.props;if(t.inputs!==n){var a=n.filter((e=>""!==e));oe()(t.inputs.filter((e=>""!==e)),a)||i(a)}}handleAddColumnClick(){this.setState((e=>{var{inputs:t}=e;return{inputs:[...t,""]}}))}handleDeleteColumn(e){this.setState((t=>{var{inputs:n}=t;return{inputs:1===n.length&&0===e?[""]:n.filter(((t,n)=>e!==n))}}))}handleDropdownChanged(e,t){vf.debug("handleDropdownChanged",e,t);var{value:n}=t.target;this.setState((t=>{var{inputs:i}=t,a=[...i];return a[e]=n,{inputs:a}}))}renderInputs(){var{columns:e,inputs:t}=this.state;return t.map(((n,i)=>{var s=e.filter((e=>{var{name:i}=e;return i===n||!t.includes(i)})).map((e=>{var{name:t}=e;return a.a.createElement("option",{value:t,key:t},t)}));return a.a.createElement("div",{className:"form-inline px-3 pb-3",key:i},a.a.createElement("select",{className:"form-control custom-select col",value:n,onChange:e=>this.handleDropdownChanged(i,e)},a.a.createElement("option",{value:""},"Select a column"),s),(t.length>1||""!==n)&&a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon ml-1 px-2",onClick:()=>{this.handleDeleteColumn(i)}},a.a.createElement(Ol,null,"Delete column"),a.a.createElement(Ke.a,{icon:$t,transform:"grow-3"})))}))}render(){var{columns:e,inputs:t}=this.state,n=t.length>=e.length;return a.a.createElement("div",{role:"presentation",className:"select-distinct-builder-container h-100"},a.a.createElement("div",{className:"select-distinct-title"},"Display Unique Values From"),this.renderInputs(),a.a.createElement("hr",null),a.a.createElement("div",{className:"pt-1 px-3"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-add-column",onClick:this.handleAddColumnClick,disabled:n},a.a.createElement(Ke.a,{icon:wn}),"Add Additional Column")),a.a.createElement("div",{className:"select-distinct-builder-footer"},a.a.createElement("div",{className:"select-distinct-builder-hint"},"Modifies a table to show unique value from a column, same as"," ",a.a.createElement("span",{className:"inline-code-snippet"},'selectDistinct("Column")'),". Filters will be reset and the resulting table will contain only the selected columns above.")))}}ff.propTypes={model:pi.a.instanceOf(Cu).isRequired,selectDistinctColumns:pi.a.arrayOf(pi.a.string),onChange:pi.a.func},ff.defaultProps={selectDistinctColumns:[],onChange:()=>{}};var bf=ff,Cf=e=>{var{items:t,onChange:n=(()=>{})}=e;return a.a.createElement(Ip,{items:Array.from(t.entries()).map((e=>{var[t,i]=e;return{title:Cf.getAdvancedSettingsTitleForKey(t),isOn:i,onChange:e=>n(t,e)}}))})};Cf.getAdvancedSettingsTitleForKey=e=>{switch(e){case Ko.FILTER_CONTROL_CHANGE_CLEARS_ALL_FILTERS:return"Control filters clear existing table filters";case Ko.LINK_CHANGE_CLEARS_ALL_FILTERS:return"Inbound links clear existing table filters"}};var Sf=Cf;function Ef(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}function wf(e){return function(){var t=this,n=arguments;return new Promise((function(i,a){var s=e.apply(t,n);function r(e){Ef(s,i,a,r,o,"next",e)}function o(e){Ef(s,i,a,r,o,"throw",e)}r(void 0)}))}}function yf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Tf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yf(Object(n),!0).forEach((function(t){Of(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Of(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Mf=p.module("IrisGrid");function Nf(e){var{advancedFilters:t,quickFilters:n,sorts:i,customColumns:a,reverseType:s,searchFilter:r}=e;return 0===t.size&&0===n.size&&0===i.length&&0===a.length&&s===cs.REVERSE_TYPE.NONE&&null==r}class Df extends i.Component{static makeQuickFilter(e,t,n){try{return cs.makeQuickFilter(e,t,n)}catch(i){Mf.error("Error creating quick filter",i)}return null}constructor(e){super(e),Of(this,"getAdvancedMenuOpenedHandler",Lr()((e=>this.handleAdvancedMenuOpened.bind(this,e)),{max:100})),Of(this,"getCachedAdvancedFilterMenuActions",Lr()(((e,t,n,i,s)=>a.a.createElement(Gg,{model:e,column:t,onFilterChange:this.handleAdvancedFilterChange,onSortChange:this.handleAdvancedFilterSortChange,onDone:this.handleAdvancedFilterDone,options:n,sortDirection:i,formatter:s})),{max:50})),Of(this,"getCachedOptionItems",Lr()(((e,t,n,i,a,s,r,o,l,c,h)=>{var d=[];return e&&d.push({type:qg.CHART_BUILDER,title:"Chart Builder",icon:Cn}),d.push({type:qg.VISIBILITY_ORDERING_BUILDER,title:"Column Visibility & Ordering",icon:ln}),t&&d.push({type:qg.CUSTOM_COLUMN_BUILDER,title:"Manage Custom Columns",icon:Kt}),n&&d.push({type:qg.ROLLUP_ROWS,title:"Rollup Rows",icon:_n}),i&&d.push({type:qg.AGGREGATIONS,title:"Aggregate Columns",icon:Yt}),a&&d.push({type:qg.SELECT_DISTINCT,title:"Select Distinct Values",icon:Bt}),s&&h&&d.push({type:qg.TABLE_EXPORTER,title:"Download CSV",icon:ct}),d.push({type:qg.ADVANCED_SETTINGS,title:"Advanced Settings",icon:Zt}),d.push({type:qg.QUICK_FILTERS,title:"Quick Filters",subtitle:r.shortcut.getDisplayText(),icon:bt,isOn:l,onChange:r.action}),d.push({type:qg.SEARCH_BAR,title:"Search Bar",subtitle:o.shortcut.getDisplayText(),icon:qt,isOn:c,onChange:o.action}),d}),{max:1})),Of(this,"getCachedHiddenColumns",Lr()((e=>e),{max:1,normalizer:e=>{var[t]=e;return t.join()}})),Of(this,"getAggregationMap",Lr()(((e,t)=>{var n={};return t.forEach((t=>{var{operation:i,selected:a,invert:s}=t;n[i]=Qo(e,i,a,s)})),n}))),Of(this,"getOperationMap",Lr()(((e,t)=>{var n={};return t.filter((e=>!$o(e.operation))).forEach((t=>{var{operation:i,selected:a,invert:s}=t;Qo(e,i,a,s).forEach((e=>{var t,a=[...null!==(t=n[e])&&void 0!==t?t:[],i];n[e]=a}))})),n}))),Of(this,"getOperationOrder",Lr()((e=>e.map((e=>e.operation)).filter((e=>!$o(e)))))),Of(this,"getModelRollupConfig",Lr()(((e,t,n)=>ol.getModelRollupConfig(e,t,n)))),Of(this,"getModelTotalsConfig",Lr()(((e,t,n)=>{var i,a,s,{aggregations:r,showOnTop:o}=n;return(null!==(i=null===t||void 0===t||null===(a=t.columns)||void 0===a?void 0:a.length)&&void 0!==i?i:0)>0||0===(null!==(s=null===r||void 0===r?void 0:r.length)&&void 0!==s?s:0)?null:{operationMap:this.getOperationMap(e,r),operationOrder:this.getOperationOrder(r),showOnTop:o}}))),Of(this,"getCachedStateOverride",Lr()(((e,t,n,i,a,s,r,o,l)=>({hoverSelectColumn:e,isFilterBarShown:t,isSelectingColumn:n,loadingScrimProgress:i,quickFilters:a,advancedFilters:s,sorts:r,reverseType:o,rollupConfig:l})),{max:1})),Of(this,"getCachedFilter",Lr()(((e,t,n,i,a)=>[...e,...i,...ol.getFiltersFromFilterMap(t),...ol.getFiltersFromFilterMap(n),...a?[a]:[]]),{max:1})),Of(this,"getCachedTheme",Lr()(((e,t)=>Tf(Tf({},Og),{},{autoSelectRow:!t},e)),{max:1})),Of(this,"getAlwaysFetchColumns",Lr()(((e,t,n,i)=>{var a=[],s=[];return n&&(a=t.slice(0,n).map((e=>e.name))),i&&(s=t.slice(-i).map((e=>e.name))),[...new Set([...e,...a,...s])]}))),this.handleAdvancedFilterChange=this.handleAdvancedFilterChange.bind(this),this.handleAdvancedFilterSortChange=this.handleAdvancedFilterSortChange.bind(this),this.handleAdvancedFilterDone=this.handleAdvancedFilterDone.bind(this),this.handleAdvancedMenuOpened=this.handleAdvancedMenuOpened.bind(this),this.handleAdvancedMenuClosed=this.handleAdvancedMenuClosed.bind(this),this.handleAggregationChange=this.handleAggregationChange.bind(this),this.handleAggregationsChange=this.handleAggregationsChange.bind(this),this.handleAggregationEdit=this.handleAggregationEdit.bind(this),this.handleAnimationLoop=this.handleAnimationLoop.bind(this),this.handleAnimationStart=this.handleAnimationStart.bind(this),this.handleAnimationEnd=this.handleAnimationEnd.bind(this),this.handleChartChange=this.handleChartChange.bind(this),this.handleChartCreate=this.handleChartCreate.bind(this),this.handleGridError=this.handleGridError.bind(this),this.handleFilterBarChange=this.handleFilterBarChange.bind(this),this.handleFilterBarDone=this.handleFilterBarDone.bind(this),this.handleFilterBarTab=this.handleFilterBarTab.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleMenu=this.handleMenu.bind(this),this.handleMenuClose=this.handleMenuClose.bind(this),this.handleMenuSelect=this.handleMenuSelect.bind(this),this.handleMenuBack=this.handleMenuBack.bind(this),this.handleRequestFailed=this.handleRequestFailed.bind(this),this.handleSelectionChanged=this.handleSelectionChanged.bind(this),this.handleMovedColumnsChanged=this.handleMovedColumnsChanged.bind(this),this.handleUpdate=this.handleUpdate.bind(this),this.handleTooltipRef=this.handleTooltipRef.bind(this),this.handleViewChanged=this.handleViewChanged.bind(this),this.handleFormatSelection=this.handleFormatSelection.bind(this),this.handleUpdateCustomColumns=this.handleUpdateCustomColumns.bind(this),this.handleCustomColumnsChanged=this.handleCustomColumnsChanged.bind(this),this.handleSelectDistinctChanged=this.handleSelectDistinctChanged.bind(this),this.handlePendingDataUpdated=this.handlePendingDataUpdated.bind(this),this.handlePendingCommitClicked=this.handlePendingCommitClicked.bind(this),this.handlePendingDiscardClicked=this.handlePendingDiscardClicked.bind(this),this.handleDownloadTable=this.handleDownloadTable.bind(this),this.handleDownloadTableStart=this.handleDownloadTableStart.bind(this),this.handleCancelDownloadTable=this.handleCancelDownloadTable.bind(this),this.handleDownloadCanceled=this.handleDownloadCanceled.bind(this),this.handleDownloadProgressUpdate=$n()(this.handleDownloadProgressUpdate.bind(this),500),this.handleDownloadCompleted=this.handleDownloadCompleted.bind(this),this.handlePartitionAppend=this.handlePartitionAppend.bind(this),this.handlePartitionChange=this.handlePartitionChange.bind(this),this.handlePartitionFetchAll=this.handlePartitionFetchAll.bind(this),this.handlePartitionDone=this.handlePartitionDone.bind(this),this.handleColumnVisibilityChanged=this.handleColumnVisibilityChanged.bind(this),this.handleCrossColumnSearch=this.handleCrossColumnSearch.bind(this),this.handleRollupChange=this.handleRollupChange.bind(this),this.updateSearchFilter=pa()(this.updateSearchFilter.bind(this),250),this.grid=null,this.gridWrapper=null,this.lastFocusedFilterBarColumn=null,this.lastLoadedConfig=null,this.tooltip=null,this.pending=new Ua,this.globalColumnFormats=[],this.dateTimeFormatterOptions={},this.loadingScrimStartTime=null,this.loadingScrimFinishTime=null,this.loadingTimer=null,this.renderer=new wg,this.tableSaver=null,this.crossColumnRef=a.a.createRef(),this.isAnimating=!1,this.animationFrame=null,this.filterInputRef=a.a.createRef(),this.toggleFilterBarAction={action:()=>this.toggleFilterBar(),shortcut:Vp.TABLE.TOGGLE_QUICK_FILTER},this.toggleSearchBarAction={action:()=>this.toggleSearchBar(),shortcut:Vp.TABLE.TOGGLE_SEARCH},this.discardAction={action:()=>{var{model:e}=this.props;e.isEditable&&e.pendingDataMap.size>0&&this.discardPending().catch(Mf.error)},shortcut:Vp.INPUT_TABLE.DISCARD},this.commitAction={action:()=>{var{model:e}=this.props;e.isEditable&&e.pendingDataMap.size>0&&0===e.pendingDataErrors.size&&this.commitPending().catch(Mf.error)},shortcut:Vp.INPUT_TABLE.COMMIT},this.contextActions=[this.toggleFilterBarAction,this.toggleSearchBarAction,this.discardAction,this.commitAction];var{aggregationSettings:t,customColumnFormatMap:n,isFilterBarShown:i,isSelectingPartition:s,model:r,movedColumns:o,movedRows:l,partition:c,partitionColumn:h,rollupConfig:d,userColumnWidths:u,userRowHeights:m,showSearchBar:p,searchValue:g,selectedSearchColumns:v,invertSearchColumns:f,advancedFilters:b,quickFilters:C,selectDistinctColumns:S,pendingDataMap:E,canCopy:w,frozenColumns:y}=e,T=[new zp(this),new Up(this)];w&&T.push(new Bp(this));var O=[new Wp(this),new Gp(this),new qp(this),new Kp(this),new ug(this),new mg(this),new pg(this)],M=new vg({userColumnWidths:new Map(u),userRowHeights:new Map(m)}),N=null!==v&&void 0!==v?v:[],D=cf.createSearchFilter(g,N,r.columns,f);this.state={isFilterBarShown:i,isSelectingPartition:s,focusedFilterBarColumn:null,metricCalculator:M,metrics:null,keyHandlers:T,mouseHandlers:O,partition:c,partitionColumn:h,partitionTable:null,partitionFilters:[],quickFilters:new Map(C),advancedFilters:new Map(b),shownAdvancedFilter:null,hoverAdvancedFilter:null,filter:[],sorts:[],reverseType:cs.REVERSE_TYPE.NONE,customColumns:[],selectDistinctColumns:S,selectedRanges:[],copyOperation:null,loadingText:null,loadingScrimProgress:null,loadingSpinnerShown:!1,movedColumns:o,movedRows:l,shownColumnTooltip:null,formatter:new Hs,isMenuShown:!1,customColumnFormatMap:new Map(n),hoverSelectColumn:null,isTableDownloading:!1,isReady:!1,tableDownloadStatus:"",tableDownloadProgress:0,tableDownloadEstimatedTime:0,showSearchBar:p,searchFilter:D,searchValue:g,selectedSearchColumns:N,invertSearchColumns:f,rollupConfig:d,rollupSelectedColumns:[],aggregationSettings:t,selectedAggregation:null,openOptions:[],pendingRowCount:0,pendingDataMap:E,pendingDataErrors:new Map,pendingSavePromise:null,pendingSaveError:null,toastMessage:null,frozenColumns:y}}componentDidMount(){var{partitionColumn:e,model:t}=this.props,n=e||t.columns.find((e=>e.isPartitionColumn));t.isFilterRequired&&t.isValuesTableAvailable&&null!=n?this.loadPartitionsTable(n):this.initState(),this.startListening(t)}componentDidUpdate(e){var{inputFilters:t,isSelectingColumn:n,settings:i,model:a,customFilters:s}=this.props;a!==e.model&&(this.stopListening(e.model),this.startListening(a));var r=t!==e.inputFilters?t.filter((t=>!e.inputFilters.includes(t))):[];if(r.length>0){var o,{advancedSettings:l}=this.props,c=null!==(o=l.get(Ko.FILTER_CONTROL_CHANGE_CLEARS_ALL_FILTERS))&&void 0!==o&&o;c&&(this.clearGridInputField(),this.clearCrossColumSearch()),this.applyInputFilters(r,c)}n!==e.isSelectingColumn&&this.resetColumnSelection(),i!==e.settings&&this.updateFormatterSettings(i),s!==e.customFilters&&this.startLoading("Filtering...",!0);var{loadingScrimStartTime:h,loadingScrimFinishTime:d}=this;null!=h&&null!=d&&window.requestAnimationFrame((()=>{var e=Date.now(),t=e-h,n=d-h,i=Math.min(t/n,1);d<e&&(this.loadingScrimStartTime=null,this.loadingScrimFinishTime=null),this.setState((e=>null==e.loadingScrimProgress?(Mf.debug2("Ignoring scrim update because loading cancelled."),null):{loadingScrimProgress:i}))})),this.sendStateChange()}componentWillUnmount(){var{model:e}=this.props;this.stopListening(e),this.pending.cancel(),this.updateSearchFilter.cancel(),this.loadingTimer&&clearTimeout(this.loadingTimer),this.handleDownloadProgressUpdate.cancel(),cancelAnimationFrame(this.animationFrame)}getValueForCell(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],{model:i}=this.props,a=this.getModelColumn(e),s=this.getModelRow(t);return n?i.valueForCell(a,s):i.textForCell(a,s)}getModelColumn(e){var{metrics:t}=this.state,{modelColumns:n}=t;return n?n.get(e):null}getModelRow(e){var{metrics:t}=this.state,{modelRows:n}=t;return n?n.get(e):null}getTheme(){var{model:e,theme:t}=this.props;return this.getCachedTheme(t,e.isEditable)}getVisibleColumn(e){var{movedColumns:t}=this.state;return wr.getVisibleIndex(e,t)}applyInputFilters(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{model:n}=this.props,{advancedFilters:i,quickFilters:a}=this.state,s=t?new Map:new Map(i),r=t?new Map:new Map(a),o=t&&i.size>0;e.forEach((e=>{var{name:t,type:i,value:a}=e,l=n.columns.findIndex((e=>{var{name:n,type:a}=e;return n===t&&a===i}));l>=0?(o=s.delete(l)||o,o=this.applyQuickFilter(l,a,r)||o):Mf.error("Unable to find column for inputFilter",t,i,a)})),o&&this.setState({quickFilters:r,advancedFilters:s})}applyQuickFilter(e,t,n){var{model:i}=this.props,{formatter:a}=i,s=i.columns[e];if(null!=t&&"".concat(t).trim().length>0){var r=n.get(e);if(null!=r){var{text:o}=r;if(o===t)return Mf.debug2("Ignoring change to existing filter"),!1}return n.set(e,{text:t,filter:Df.makeQuickFilter(s,t,a.timeZone)}),!0}return n.delete(e)}setAdvancedFilter(e,t,n){null!=e?(Mf.debug("Setting advanced filter",e,t),this.startLoading("Filtering...",!0),this.setState((i=>{var{advancedFilters:a}=i,s=new Map(a);return null==t?s.delete(e):s.set(e,{filter:t,options:n}),{advancedFilters:s}}))):Mf.error("Invalid model index to filter on")}setQuickFilter(e,t,n){Mf.debug("Setting quick filter",e,t,n),this.startLoading("Filtering...",!0),this.setState((i=>{var{quickFilters:a}=i,s=new Map(a);return s.set(e,{filter:t,text:n}),{quickFilters:s}}))}setFilterMap(e){var t;Mf.debug("setFilterMap",e);var{advancedSettings:n}=this.props;null!==(t=n.get(Ko.LINK_CHANGE_CLEARS_ALL_FILTERS))&&void 0!==t&&t&&this.clearAllFilters();var{model:i}=this.props;e.forEach(((e,t)=>{var{columnType:n,text:a,value:s}=e,r=i.columns.find((e=>e.name===t&&e.type===n));if(null!=r){var o=i.getColumnIndexByName(r.name);if(null===s)this.setQuickFilter(o,r.filter().isNull(),"=null");else{var l=cs.isTextType(n)?va.FilterValue.ofString(s):va.FilterValue.ofNumber(s);this.setQuickFilter(o,r.filter().eq(l),"".concat(a))}}}))}removeColumnFilter(e){this.startLoading("Filtering...",!0),this.setState((t=>{var{advancedFilters:n,quickFilters:i}=t,a=new Map(n),s=new Map(i);return s.delete(e),a.delete(e),{quickFilters:s,advancedFilters:a}}))}clearAllFilters(){Mf.debug("Clearing all filters");var{advancedFilters:e,quickFilters:t,searchFilter:n}=this.state;0===t.size&&0===e.size&&null===n||(this.clearGridInputField(),this.startLoading("Clearing Filters...",!0),this.setState({quickFilters:new Map,advancedFilters:new Map,searchValue:"",searchFilter:null}))}clearCrossColumSearch(){Mf.debug("Clearing cross-column search"),this.setState({searchValue:"",searchFilter:null})}clearGridInputField(){null!=this.filterInputRef.current&&this.filterInputRef.current.setValue("")}rebuildFilters(){Mf.debug("Rebuilding filters");var{model:e}=this.props,{advancedFilters:t,quickFilters:n}=this.state,{columns:i,formatter:a}=e,s=new Map,r=new Map;t.forEach(((e,t)=>{var{options:n}=e,r=i[t],o=cs.makeAdvancedFilter(r,n,a.timeZone);s.set(t,{options:n,filter:o})})),n.forEach(((e,t)=>{var{text:n}=e,s=i[t];r.set(t,{text:n,filter:Df.makeQuickFilter(s,n,a.timeZone)})})),this.startLoading("Rebuilding filters...",!0),this.setState({quickFilters:r,advancedFilters:s})}setFilters(e){var{quickFilters:t,advancedFilters:n}=e;this.setState({quickFilters:t,advancedFilters:n})}updateFormatterSettings(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=bs.getColumnFormats(e),i=bs.getDateTimeFormatterOptions(e),a=!oe()(this.globalColumnFormats,n),s=!oe()(this.dateTimeFormatterOptions,i);(a||s)&&(this.globalColumnFormats=n,this.dateTimeFormatterOptions=i,this.updateFormatter({},t),s&&t&&this.rebuildFilters())}updateFormatter(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],{customColumnFormatMap:n}=this.state,i=Tf({customColumnFormatMap:n},e),a=[...this.globalColumnFormats,...i.customColumnFormatMap.values()],s=new Hs(a,this.dateTimeFormatterOptions);Mf.debug("updateFormatter",this.globalColumnFormats,a),this.setState(Tf(Tf({},i),{},{formatter:s}),(()=>{t&&this.grid&&this.grid.forceUpdate()}))}initFormatter(){var{settings:e}=this.props;this.updateFormatterSettings(e)}initState(){var{applyInputFiltersOnInit:e,inputFilters:t,sorts:n,model:i,reverseType:a,customColumns:s,searchValue:r,selectedSearchColumns:o,invertSearchColumns:l}=this.props,c=null!==o&&void 0!==o?o:[],h=cf.createSearchFilter(r,c,i.columns,l);if(e){var d=t.filter((e=>null!=e.value));this.applyInputFilters(d)}this.setState({sorts:n,reverseType:a,customColumns:s,isReady:!0,searchFilter:h}),this.initFormatter()}loadPartitionsTable(e){var t=this;return wf((function*(){var{model:n}=t.props;t.setState({isSelectingPartition:!0});try{var i=yield t.pending.add(n.valuesTable(e),(e=>e.close())),a=i.columns[0],s=a.sort().desc();i.applySort([s]),i.setViewport(0,0,[a]);var r=yield t.pending.add(i.getViewportData());if(r.rows.length>0){var o=r.rows[0].get(a);t.updatePartition(o,e),t.setState({isSelectingPartition:!0})}else Mf.info("Table does not have any data, just fetching all"),t.setState({isSelectingPartition:!1}),t.handlePartitionFetchAll();t.setState({partitionTable:i,partitionColumn:e},(()=>{t.initState()}))}catch(l){t.handleTableLoadError(l)}}))()}updatePartition(e,t){var n=[t.filter().eq(va.FilterValue.ofString(e))];this.setState({partition:e,partitionFilters:n})}copyCell(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],{canCopy:i}=this.props;if(i){var a=this.getValueForCell(e,t,n);je.copyToClipboard(a).catch((e=>Mf.error("Unable to copy cell",e)))}else Mf.error("Attempted to copyCell for user without copy permission.")}copyRanges(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,{model:a,canCopy:s}=this.props,{metricCalculator:r,movedColumns:o}=this.state,{userColumnWidths:l}=r;if(s){var c={ranges:fr.boundedRanges(e,a.columnCount,a.rowCount),includeHeaders:t,formatValues:n,movedColumns:o,userColumnWidths:l,error:i};this.setState({copyOperation:c})}else Mf.error("Attempted copyRanges for user without copy permission.")}startLoading(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.setState({loadingText:e});var n=this.getTheme();if(t&&this.grid&&(this.grid.clearSelectedRanges(),this.grid.setViewState({top:0},!0)),null==this.loadingScrimStartTime){var i,a,{minScrimTransitionTime:s,maxScrimTransitionTime:r}=n,o=null!==(i=null===(a=this.gridWrapper)||void 0===a?void 0:a.getBoundingClientRect().height)&&void 0!==i?i:0,l=Math.max(s,Math.min(o/2,r));this.loadingScrimStartTime=Date.now(),this.loadingScrimFinishTime=this.loadingScrimStartTime+l,this.setState({loadingScrimProgress:0}),this.loadingTimer=setTimeout((()=>{this.setState({loadingSpinnerShown:!0})}),Df.loadingSpinnerDelay)}}stopLoading(){this.loadingScrimStartTime=null,this.loadingScrimFinishTime=null,this.setState({loadingText:null,loadingScrimProgress:null,loadingSpinnerShown:!1}),this.loadingTimer&&(clearTimeout(this.loadingTimer),this.loadingTimer=null)}rollback(){if(this.lastLoadedConfig){Mf.debug("loading last loading config",this.lastLoadedConfig);var{advancedFilters:e,customColumns:t,quickFilters:n,reverseType:i,searchFilter:a,sorts:s}=this.lastLoadedConfig;this.lastLoadedConfig=null,this.setState({advancedFilters:e,customColumns:t,quickFilters:n,reverseType:i,searchFilter:a,sorts:s})}else Mf.debug("remove all sorts, filters, and custom columns"),this.setState({advancedFilters:new Map,quickFilters:new Map,sorts:[],customColumns:[],reverseType:cs.REVERSE_TYPE.NONE})}canRollback(){return null!=this.lastLoadedConfig||!Nf(this.state)}startListening(e){e.addEventListener(Cu.EVENT.UPDATED,this.handleUpdate),e.addEventListener(Cu.EVENT.REQUEST_FAILED,this.handleRequestFailed),e.addEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleCustomColumnsChanged),e.addEventListener(Cu.EVENT.PENDING_DATA_UPDATED,this.handlePendingDataUpdated)}stopListening(e){e.removeEventListener(Cu.EVENT.UPDATED,this.handleUpdate),e.removeEventListener(Cu.EVENT.REQUEST_FAILED,this.handleRequestFailed),e.removeEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleCustomColumnsChanged),e.removeEventListener(Cu.EVENT.PENDING_DATA_UPDATED,this.handlePendingDataUpdated)}focusFilterBar(e){var{model:t}=this.props,{columnCount:n}=t,i=this.getModelColumn(e);if(null==e||e<0||n<=e||!t.isFilterable(i))this.setState({focusedFilterBarColumn:null});else{var{metricCalculator:a,metrics:s}=this.state,{gridX:r,left:o,rightVisible:l,lastLeft:c}=s;if(e<o)this.grid.setViewState({left:e},!0);else if(l<e){var h=this.grid.getMetricState(),d=a.getLastLeft(h,e,r);this.grid.setViewState({left:Math.min(d,c)},!0)}this.lastFocusedFilterBarColumn=e,this.setState({focusedFilterBarColumn:e,isFilterBarShown:!0})}}hideColumnByVisibleIndex(e){var{metricCalculator:t,movedColumns:n}=this.state;t.setColumnWidth(wr.getModelIndex(e,n),0),this.grid.forceUpdate()}freezeColumnByColumnName(e){var t,n,i,{frozenColumns:a}=this.state,{model:s}=this.props;(Mf.debug2("freezing column",e),null==a)?(t=new Set(null!==(n=null===(i=s.layoutHints)||void 0===i?void 0:i.frozenColumns)&&void 0!==n?n:[])).add(e):t=new Set([...a,e]);this.setState({frozenColumns:[...t]})}unFreezeColumnByColumnName(e){var t,n,i,{frozenColumns:a}=this.state,{model:s}=this.props;(Mf.debug2("unfreezing column",e),null==a)?(t=new Set(null!==(n=null===(i=s.layoutHints)||void 0===i?void 0:i.frozenColumns)&&void 0!==n?n:[])).delete(e):t=new Set(a.filter((t=>t!==e)));this.setState({frozenColumns:[...t]})}handleColumnVisibilityChanged(e,t){var{metricCalculator:n}=this.state;t===Qg.VISIBILITY_OPTIONS.SHOW?e.forEach((e=>{n.resetColumnWidth(e)})):e.forEach((e=>{n.setColumnWidth(e,0)})),this.grid.forceUpdate()}handleCrossColumnSearch(e,t,n){var{model:i}=this.props;this.updateSearchFilter(e,t,i.columns,n),this.setState({searchValue:e,selectedSearchColumns:t,invertSearchColumns:n})}updateSearchFilter(e,t,n,i){var a=cf.createSearchFilter(e,t,n,i);this.setState({searchFilter:a})}handleAnimationLoop(){this.grid.updateCanvasScale(),this.grid.updateCanvas(),this.isAnimating&&(this.animationFrame=requestAnimationFrame(this.handleAnimationLoop))}handleAnimationStart(){Mf.debug2("handleAnimationStart"),this.isAnimating=!0,this.animationFrame=requestAnimationFrame(this.handleAnimationLoop)}handleAnimationEnd(){Mf.debug2("handleAnimationEnd"),this.isAnimating=!1}handlePartitionAppend(e){var{onPartitionAppend:t}=this.props,{partitionColumn:n}=this.state;t(n,e)}handlePartitionChange(e){var{partitionColumn:t}=this.state;this.updatePartition(e,t)}handlePartitionFetchAll(){this.setState({partitionFilters:[],isSelectingPartition:!1})}handlePartitionDone(){this.setState({isSelectingPartition:!1})}handleTableLoadError(e){if(!Va.isCanceled(e)){Mf.error(e);var{onError:t}=this.props;t(e)}}showAllColumns(){for(var{metricCalculator:e}=this.state,{userColumnWidths:t}=e,n=[...t.entries()],i=0;i<n.length;i+=1){var[a,s]=n[i];0===s&&e.resetColumnWidth(a)}this.grid.forceUpdate()}toggleSort(e,t){Mf.info("Toggling sort for column",e);var{model:n}=this.props,{sorts:i}=this.state,a=this.getModelColumn(e),s=cs.toggleSortForColumn(i,n.table,a,t);this.startLoading("Sorting..."),this.setState({sorts:s}),this.grid.forceUpdate()}sortColumn(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],{model:a}=this.props,s=cs.sortColumn(a.table,e,t,n,i);this.startLoading("Sorting..."),this.setState({sorts:s}),this.grid.forceUpdate()}reverse(e){this.startLoading("Reversing..."),this.setState({reverseType:e}),this.grid.forceUpdate()}isReversible(){var{model:e}=this.props;return e.isReversible}toggleFilterBar(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.lastFocusedFilterBarColumn,{isFilterBarShown:t}=this.state;if(t=!t,this.setState({isFilterBarShown:t}),t)if(null!=e)this.focusFilterBar(e);else{for(var n=0,{model:i}=this.props,{columnCount:a}=i,s=0;s<a;s+=1){var r=this.getModelColumn(s);if(null!=r){var o=i.columns[r];if(null!=o&&cs.isTextType(o.type)){n=s;break}}}this.focusFilterBar(n)}else this.grid.focus()}toggleSearchBar(){var{showSearchBar:e}=this.state,t=!e;this.setState({showSearchBar:t},(()=>{t&&this.crossColumnRef.current?this.crossColumnRef.current.focus():this.grid.focus()}))}commitPending(){var e=this;return wf((function*(){var{model:t}=e.props;if(!t.isEditable)throw new Error("Cannot save, table is not editable");var{pendingSavePromise:n}=e.state;if(null!=n)throw new Error("Save already in progress");if(document.activeElement.classList.contains("grid-cell-input-field")){if(document.activeElement.classList.contains("error"))throw new Za("Current input is invalid");e.grid.focus()}var i=e.pending.add(t.commitPending()).then((()=>{e.setState({pendingSaveError:null,pendingSavePromise:null})})).catch((t=>{Va.isCanceled(t)||e.setState({pendingSaveError:t,pendingSavePromise:null})}));return e.setState({pendingSavePromise:i}),i}))()}discardPending(){var e=this;return wf((function*(){var{pendingSavePromise:t}=e.state;if(null!=t)throw new Error("Cannot cancel a save in progress");e.setState({pendingSavePromise:null,pendingSaveError:null,pendingDataMap:new Map,pendingDataErrors:new Map})}))()}selectColumn(e){var{onColumnSelected:t}=this.props;t(e)}selectData(e,t){for(var{model:n}=this.props,{columns:i}=n,a={},s=0;s<i.length;s+=1){var r=i[s],{name:o,type:l}=r,c=n.valueForCell(s,t),h=n.textForCell(s,t);a[o]={value:c,text:h,type:l}}var{onDataSelected:d}=this.props;d(t,a)}handleAdvancedFilterChange(e,t,n){var{model:i}=this.props;this.setAdvancedFilter(i.getColumnIndexByName(e.name),t,n)}handleAdvancedFilterSortChange(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],{model:i}=this.props,a=i.getColumnIndexByName(e.name),s=cs.getSortForColumn(i.sort,a),r=null;null!=s&&s.direction===t||(r=t===cs.sortDirection.descending?e.sort().desc():e.sort().asc());var o=cs.setSortForColumn(i.sort,a,r,n);Mf.info("Setting table sorts",o),this.startLoading("Sorting..."),this.setState({sorts:o}),this.grid.forceUpdate()}handleAdvancedFilterDone(){this.grid.focus()}handleAdvancedMenuOpened(e){this.setState({shownAdvancedFilter:e})}handleAdvancedMenuClosed(e){var{focusedFilterBarColumn:t,isFilterBarShown:n}=this.state;n&&t===e&&null!==this.filterInputRef.current?(this.filterInputRef.current.focus(),this.setState({shownAdvancedFilter:null})):this.setState({focusedFilterBarColumn:null,shownAdvancedFilter:null})}handleCancel(){this.rollback()}handleChartChange(){}handleChartCreate(e){var{model:t,onCreateChart:n}=this.props;n(e,t.table)}handleGridError(e){Mf.warn("Grid Error",e),this.setState({toastMessage:a.a.createElement("div",{className:"error-message"},"".concat(e))})}handleFilterBarChange(e){this.startLoading("Filtering...",!0),this.setState((t=>{var{focusedFilterBarColumn:n,quickFilters:i}=t,a=new Map(i),s=this.getModelColumn(n);return this.applyQuickFilter(s,e,a),{quickFilters:a}}))}handleFilterBarDone(){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];(!(arguments.length>0&&void 0!==arguments[0])||arguments[0])&&this.grid.focus(),e&&this.setState({focusedFilterBarColumn:null})}handleFilterBarTab(e){var{focusedFilterBarColumn:t}=this.state;e?this.focusFilterBar(t-1):this.focusFilterBar(t+1)}handleFormatSelection(e,t){var{model:n}=this.props,i=n.columns[e],{customColumnFormatMap:a}=this.state,s=new Map(a);if(t){var r=cs.getNormalizedType(i.type),o=Hs.makeColumnFormattingRule(r,i.name,t);s.set(i.name,o)}else s.delete(i.name);this.updateFormatter({customColumnFormatMap:s})}handleMenu(){this.setState({isMenuShown:!0})}handleMenuClose(){this.setState({isMenuShown:!1,openOptions:[]})}handleMenuBack(){this.setState((e=>{var{openOptions:t}=e,n=[...t];return n.pop(),{openOptions:n}}))}handleMenuSelect(e){this.setState((t=>{var{openOptions:n}=t;return{openOptions:[...n,e]}}))}handleRequestFailed(e){if(Mf.error("request failed:",e.detail),this.stopLoading(),this.canRollback())this.startLoading("Rolling back changes...",!0),this.rollback();else{Mf.error("Table failed and unable to rollback");var{onError:t}=this.props;t(new Error("Error displaying table: ".concat(e.detail)))}}handleUpdate(){this.stopLoading(),Mf.debug2("Received model update");var{advancedFilters:e,customColumns:t,quickFilters:n,reverseType:i,searchFilter:a,sorts:s}=this.state,r={advancedFilters:e,customColumns:t,reverseType:i,quickFilters:n,searchFilter:a,sorts:s};Nf(r)?this.lastLoadedConfig=null:this.lastLoadedConfig=r,this.grid.forceUpdate()}handleViewChanged(e){var t,n,{model:i}=this.props,{bottomViewport:a}=e,{selectionEndRow:s=0}=null!==(t=null===(n=this.grid)||void 0===n?void 0:n.state)&&void 0!==t?t:{},r=0;if(i.isEditable){var o=i.rowCount-i.floatingBottomRowCount;r=s===o-1?i.pendingRowCount+1:s===o-2?i.pendingRowCount:Math.max(0,a-(i.rowCount-i.pendingRowCount)-i.floatingTopRowCount-i.floatingBottomRowCount-1)}this.setState({metrics:e,pendingRowCount:r})}handleSelectionChanged(e){var{onSelectionChanged:t}=this.props,{copyOperation:n}=this.state;this.setState({selectedRanges:e}),null!=n&&this.setState({copyOperation:null}),t(e)}handleMovedColumnsChanged(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{};this.setState({movedColumns:e},t)}handleTooltipRef(e){e&&e.startTimer(),this.tooltip=e}handleUpdateCustomColumns(e){Mf.info("handleUpdateCustomColumns:",e);var{model:t}=this.props,{movedColumns:n,sorts:i,quickFilters:a,advancedFilters:s,selectDistinctColumns:r}=this.state,{columns:o}=t,l=t.customColumns.map((e=>"".concat(e))),c=ol.getRemovedCustomColumnNames(l,e);if(c.length>0){var h=ol.removeSortsInColumns(i,c),d=ol.removeFiltersInColumns(o,a,c),u=ol.removeFiltersInColumns(o,s,c),m=ol.removeColumnFromMovedColumns(o,n,c),p=ol.removeColumnsFromSelectDistinctColumns(r,c);h.length!==i&&(Mf.debug("removing sorts from removed custom columns..."),this.setState({sorts:h})),d.size===a.size&&u.size===s.size||(Mf.debug("removing filters from removed custom columns..."),this.setState({quickFilters:d,advancedFilters:u})),oe()(n,m)||(Mf.debug("change moved columns for removed custom columns",m),this.setState({movedColumns:m})),oe()(r,p)||(Mf.debug("change selectDistinct columns for removed custom columns",m),this.setState({selectDistinctColumns:p}))}this.setState({customColumns:e,top:0}),this.startLoading("Applying custom columns...")}handleCustomColumnsChanged(){Mf.debug("custom columns changed");var{isReady:e}=this.state;e?(this.stopLoading(),this.grid.forceUpdate()):this.initState()}handlePendingCommitClicked(){return this.commitPending()}handlePendingDiscardClicked(){return this.discardPending()}handlePendingDataUpdated(){Mf.debug("pending data updated");var{model:e}=this.props,{pendingDataMap:t,pendingDataErrors:n}=e;this.setState({pendingDataMap:t,pendingDataErrors:n,pendingSaveError:null}),this.grid.forceUpdate()}handleAggregationsChange(e){Mf.debug("handleAggregationsChange",e),this.startLoading("Aggregating ".concat(e.aggregations.map((e=>e.operation)).join(", "),"...")),this.setState({aggregationSettings:e})}handleAggregationChange(e){Mf.debug("handleAggregationChange",e),this.startLoading("Aggregating ".concat(e.operation,"...")),this.setState((t=>{var{aggregationSettings:n}=t;return{selectedAggregation:e,aggregationSettings:Tf(Tf({},n),{},{aggregations:n.aggregations.map((t=>t.operation===e.operation?e:t))})}}))}handleAggregationEdit(e){Mf.debug("handleAggregationEdit",e);var{openOptions:t}=this.state;this.setState({openOptions:[...t,{type:qg.AGGREGATION_EDIT,title:"Edit Columns to ".concat(e.operation)}],selectedAggregation:e})}handleRollupChange(e){var t,n;Mf.info("Rollup change",e),this.resetGridViewState(),this.showAllColumns(),this.clearAllFilters(),this.startLoading("Grouping by columns ".concat(null!==(t=null===e||void 0===e||null===(n=e.columns)||void 0===n?void 0:n.join(", "))&&void 0!==t?t:"","...")),this.setState({rollupConfig:e,movedColumns:[],sorts:[],reverseType:cs.REVERSE_TYPE.NONE,selectDistinctColumns:[]})}handleSelectDistinctChanged(e){Mf.debug("SelectDistinct change",e),this.resetGridViewState(),this.showAllColumns(),this.clearAllFilters(),this.startLoading("Selecting distinct values in ".concat(e.length>0?e.join(", "):"","...")),this.setState({selectDistinctColumns:e,movedColumns:[],sorts:[],reverseType:cs.REVERSE_TYPE.NONE})}handleDownloadTableStart(){var{canDownloadCsv:e}=this.props;e?this.setState({isTableDownloading:!0,tableDownloadProgress:0,tableDownloadEstimatedTime:null,tableDownloadStatus:av.DOWNLOAD_STATUS.INITIATING}):Mf.error("Attempted to handleDownloadTableStart for user without download CSV permission.")}handleDownloadTable(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var{canDownloadCsv:i}=this.props;i?(Mf.info("start table downloading",...t),this.setState((()=>(this.tableSaver&&this.tableSaver.startDownload(...t),{tableDownloadStatus:av.DOWNLOAD_STATUS.DOWNLOADING})))):Mf.error("Attempted to handleDownloadTable for user without download CSV permission.")}handleCancelDownloadTable(){this.tableSaver.cancelDownload(),this.setState({isTableDownloading:!1})}handleDownloadProgressUpdate(e,t){var{tableDownloadStatus:n}=this.state;n===av.DOWNLOAD_STATUS.DOWNLOADING&&this.setState({tableDownloadProgress:e,tableDownloadEstimatedTime:t})}handleDownloadCompleted(){this.setState({isTableDownloading:!1,tableDownloadProgress:100,tableDownloadStatus:av.DOWNLOAD_STATUS.FINISHED})}handleDownloadCanceled(){this.setState({isTableDownloading:!1,tableDownloadProgress:0,tableDownloadStatus:av.DOWNLOAD_STATUS.CANCELED})}deleteRanges(e){var{model:t}=this.props;this.pending.add(t.delete(e)).catch((t=>{Va.isCanceled(t)||Mf.error("Unable to delete ranges",e,t)}))}resetColumnSelection(){if(null!=this.grid){var{isSelectingColumn:e}=this.props;if(e){var{columnAllowedCursor:t}=this.props;this.grid.setState({cursor:t})}else this.grid.setState({cursor:Ao.CURSOR_TYPE_DEFAULT}),this.setState({hoverSelectColumn:null})}}resetGridViewState(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.grid&&(this.grid.clearSelectedRanges(),this.grid.setViewState({left:0,top:0,topOffset:0,leftOffset:0},e))}sendStateChange(){if(this.grid){var{state:e}=this,{state:t}=this.grid,{onStateChange:n}=this.props;n(e,t)}}render(){var e,t,n=this,{children:i,customFilters:s,getDownloadWorker:r,isSelectingColumn:o,model:l,name:c,onlyFetchVisibleColumns:h,alwaysFetchColumns:d,advancedSettings:u,onAdvancedSettingsChange:m,canDownloadCsv:p}=this.props,{metricCalculator:g,metrics:v,isFilterBarShown:f,isSelectingPartition:b,isMenuShown:C,isReady:S,copyOperation:E,focusedFilterBarColumn:w,loadingText:y,loadingScrimProgress:T,loadingSpinnerShown:O,keyHandlers:M,mouseHandlers:N,shownColumnTooltip:D,hoverAdvancedFilter:x,shownAdvancedFilter:R,hoverSelectColumn:I,quickFilters:L,advancedFilters:F,partition:k,partitionFilters:A,partitionTable:P,partitionColumn:_,searchFilter:H,selectDistinctColumns:j,movedColumns:V,movedRows:z,formatter:U,sorts:B,reverseType:W,customColumns:G,selectedRanges:q,isTableDownloading:K,tableDownloadStatus:Y,tableDownloadProgress:X,tableDownloadEstimatedTime:Z,showSearchBar:$,searchValue:Q,selectedSearchColumns:J,invertSearchColumns:ee,aggregationSettings:te,selectedAggregation:ne,rollupConfig:ie,openOptions:ae,pendingSavePromise:se,pendingSaveError:re,pendingRowCount:oe,pendingDataErrors:le,pendingDataMap:ce,toastMessage:he,frozenColumns:de}=this.state;if(!S)return null;var ue=this.getTheme(),me=this.getCachedFilter(s,L,F,A,H),{userColumnWidths:pe}=g,ge=this.getCachedStateOverride(I,f,o,T,L,F,B,W,ie),ve=v?v.top:0,fe=v?v.bottomViewport:0,be=null,Ce=null;h&&(be=v?v.left:0,Ce=v?v.right:0);var Se=null!=v&&v.width>0&&v.height>0,Ee=(null!==(e=null===ie||void 0===ie||null===(t=ie.columns)||void 0===t?void 0:t.length)&&void 0!==e?e:0)>0,we=null,ye=v?Math.min(Math.max(Df.minDebounce,Math.round(v.rowCount/200)),Df.maxDebounce):Df.maxDebounce;if(f&&null!=w&&null!=v){var{gridX:Te,gridY:Oe,visibleColumnXs:Me,visibleColumnWidths:Ne}=v,De=Me.get(w),xe=Ne.get(w);if(null!=De&&null!=xe){var Re=Te+De,Ie={top:Oe-ue.filterBarHeight,left:Re,minWidth:xe+1,height:ue.filterBarHeight-1},Le="",Fe=!0,ke=this.getModelColumn(w),Ae=L.get(ke),Pe=F.get(ke);null!=Ae&&(Le=Ae.text,Fe=null!=Ae.filter);var _e=0!==L.size||0!==F.size;we=a.a.createElement(jp,{ref:this.filterInputRef,style:Ie,className:qe()({error:!Fe,active:""!==Le||null!=Pe,"iris-grid-has-filter":_e}),isAdvancedFilterSet:null!=Pe,onAdvancedFiltersTriggered:()=>{this.setState({shownAdvancedFilter:w})},key:w,onChange:this.handleFilterBarChange,onDone:this.handleFilterBarDone,onTab:this.handleFilterBarTab,onContextMenu:this.grid.handleContextMenu,debounceMs:ye,value:Le})}}var He=null;if(null!=y){var je=a.a.createElement("div",{className:"iris-grid-loading-status"},y),Ve=a.a.createElement(Op,{show:O}),ze=a.a.createElement("button",{type:"button",onClick:this.handleCancel,className:qe()("btn btn-secondary btn-cancelable iris-grid-btn-cancel",{show:O})},"Cancel"),Ue=v?v.gridY:0;He=a.a.createElement("div",{className:"iris-grid-loading",style:{top:Ue}},je,Ve,ze)}var Be=null;if(null!=D&&v&&this.gridWrapper){var{columnHeaderHeight:Ge,visibleColumnXs:Ye,visibleColumnWidths:Xe,width:Ze}=v,$e=Ye.get(D),Qe=Xe.get(D),Je=Math.max(0,$e),et=Qe;$e+Qe>Ze?et=Ze-$e:$e<0&&(et=Qe-Math.abs($e));var tt={position:"absolute",top:0,left:Je,width:et,height:Ge,pointerEvents:"none"},nt=this.gridWrapper.getBoundingClientRect(),it={clientWidth:1,clientHeight:Ge,getBoundingClientRect:()=>({top:nt.top,left:nt.left+pr()($e+Qe/2,20,Ze-20),bottom:nt.top+Ge,right:nt.left+pr()($e+Qe/2,20,Ze-20)+1,width:1,height:Ge})},at=this.getModelColumn(D),st=l.columns[at];null!=st&&(Be=a.a.createElement("div",{style:tt},a.a.createElement(Ol,{key:st.name,timeout:400,interactive:!0,options:{placement:"bottom",modifiers:{flip:{behavior:["bottom","top"]}}},ref:this.handleTooltipRef,referenceObject:it},a.a.createElement(xg,{model:l,column:st,onStatistics:()=>{this.tooltip&&this.tooltip.update()}}))))}var rt=[];if(v&&f)for(var{gridX:ot,gridY:lt,visibleColumns:ct,visibleColumnXs:ht,visibleColumnWidths:dt}=v,{filterBarHeight:ut}=ue,mt=function(e){var t=ct[e],i=ht.get(t),s=dt.get(t),r=n.getModelColumn(t);if(l.isFilterable(r)&&null!=i&&null!=s&&s>0){var o={position:"absolute",top:lt-ut+2,left:ot+i+s-24},c=null!=F.get(r),h=t===x||t===w||c,d=a.a.createElement("div",{className:qe()("advanced-filter-button-container",{hidden:!h}),key:t,style:o},h&&a.a.createElement("button",{type:"button",className:qe()("btn btn-link btn-link-icon advanced-filter-button",{"filter-set":c}),onClick:()=>{n.setState({shownAdvancedFilter:t})},onContextMenu:e=>{n.grid.handleContextMenu(e)},onMouseEnter:()=>{n.setState({hoverAdvancedFilter:t})},onMouseLeave:()=>{n.setState({hoverAdvancedFilter:null})}},a.a.createElement("div",{className:"fa-layers"},a.a.createElement(Ke.a,{icon:pn,className:"filter-solid"}),a.a.createElement(Ke.a,{icon:bt,className:"filter-light"}))));rt.push(d)}},pt=0;pt<ct.length;pt+=1)mt(pt);var gt=[];if(v)for(var{gridX:vt,visibleColumns:ft,visibleColumnXs:Ct,visibleColumnWidths:St,columnHeaderHeight:Et}=v,wt=function(e){var t=ft[e],i=Ct.get(t),s=St.get(t);if(null!=i&&null!=s&&s>0){var r=vt+i,o=f?{position:"absolute",top:Et,left:vt+i+s-20,width:20,height:ue.filterBarHeight}:{position:"absolute",top:0,left:r,width:s,height:Et},c=n.getModelColumn(t),h=l.columns[c],d=F.get(c),{options:u}=d||{},m=cs.getSortForColumn(l.sort,c),p=m?m.direction:null,g=a.a.createElement("div",{key:t,className:"advanced-filter-menu-container",style:o},a.a.createElement(El,{className:"advanced-filter-menu-popper",onEntered:n.getAdvancedMenuOpenedHandler(t),onExited:()=>{n.handleAdvancedMenuClosed(t)},isShown:R===t,interactive:!0,closeOnBlur:!0},n.getCachedAdvancedFilterMenuActions(l,h,u,p,U)));gt.push(g)}},yt=0;yt<ft.length;yt+=1)wt(yt);var Tt=this.getCachedOptionItems(l.isChartBuilderAvailable,l.isCustomColumnsAvailable,l.isRollupAvailable,l.isTotalsAvailable,l.isSelectDistinctAvailable,l.isExportAvailable,this.toggleFilterBarAction,this.toggleSearchBarAction,f,$,p),Ot=ae.map((e=>{switch(e.type){case qg.CHART_BUILDER:return a.a.createElement(fv,{model:l,onChange:this.handleChartChange,onSubmit:this.handleChartCreate,key:qg.CHART_BUILDER});case qg.VISIBILITY_ORDERING_BUILDER:return a.a.createElement(Qg,{model:l,movedColumns:V,userColumnWidths:pe,onColumnVisibilityChanged:this.handleColumnVisibilityChanged,onMovedColumnsChanged:this.handleMovedColumnsChanged,key:qg.VISIBILITY_ORDERING_BUILDER});case qg.CUSTOM_COLUMN_BUILDER:return a.a.createElement(Lv,{model:l,customColumns:G,onSave:this.handleUpdateCustomColumns,onCancel:this.handleMenuBack,key:qg.CUSTOM_COLUMN_BUILDER});case qg.ROLLUP_ROWS:return a.a.createElement(Bv,{metrics:v,model:l,onChange:this.handleRollupChange,config:ie,key:qg.ROLLUP_ROWS});case qg.AGGREGATIONS:return a.a.createElement(Qv,{settings:te,isRollup:Ee,onChange:this.handleAggregationsChange,onEdit:this.handleAggregationEdit});case qg.AGGREGATION_EDIT:return a.a.createElement(nf,{aggregation:ne,columns:l.originalColumns,onChange:this.handleAggregationChange});case qg.TABLE_EXPORTER:return a.a.createElement(av,{model:l,name:c,isDownloading:K,tableDownloadStatus:Y,tableDownloadProgress:X,tableDownloadEstimatedTime:Z,onDownload:this.handleDownloadTable,onDownloadStart:this.handleDownloadTableStart,onCancel:this.handleCancelDownloadTable,selectedRanges:q,key:qg.TABLE_EXPORTER});case qg.SELECT_DISTINCT:return a.a.createElement(bf,{model:l,selectDistinctColumns:j,onChange:this.handleSelectDistinctChanged});case qg.ADVANCED_SETTINGS:return a.a.createElement(Sf,{items:u,onChange:m});default:throw Error("Unexpected option type",e.type)}})),Mt=this.getCachedHiddenColumns(ol.getHiddenColumns(pe));return a.a.createElement("div",{className:"iris-grid",role:"presentation"},a.a.createElement("div",{className:"iris-grid-column"},i&&a.a.createElement("div",{className:"iris-grid-bar"},i),a.a.createElement(We.CSSTransition,{in:b,timeout:Kn.transitionSlowMs,classNames:"iris-grid-bar-horizontal",onEnter:this.handleAnimationStart,onEntered:this.handleAnimationEnd,onExit:this.handleAnimationStart,onExited:this.handleAnimationEnd,mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"iris-grid-partition-selector-wrapper iris-grid-bar iris-grid-bar-primary"},P&&_&&a.a.createElement(gf,{table:P,getFormattedString:function(){return l.displayString(...arguments)},columnName:_.name,partition:k,onChange:this.handlePartitionChange,onFetchAll:this.handlePartitionFetchAll,onAppend:this.handlePartitionAppend,onDone:this.handlePartitionDone}))),a.a.createElement(We.CSSTransition,{in:$,timeout:Kn.transitionSlowMs,classNames:"iris-grid-bar-horizontal",onEnter:this.handleAnimationStart,onEntered:this.handleAnimationEnd,onExit:this.handleAnimationStart,onExited:this.handleAnimationEnd,mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"iris-grid-bar"},a.a.createElement(cf,{value:Q,selectedColumns:J,invertSelection:ee,onChange:this.handleCrossColumnSearch,columns:l.columns,ref:this.crossColumnRef}))),a.a.createElement("div",{className:"grid-wrapper",ref:e=>{this.gridWrapper=e}},a.a.createElement(Ao,{ref:e=>{this.grid=e},isStickyBottom:!l.isEditable,metricCalculator:g,model:l,keyHandlers:M,mouseHandlers:N,movedColumns:V,movedRows:z,onError:this.handleGridError,onViewChanged:this.handleViewChanged,onSelectionChanged:this.handleSelectionChanged,onMovedColumnsChanged:this.handleMovedColumnsChanged,renderer:this.renderer,stateOverride:ge,theme:ue}),Se&&a.a.createElement(bg,{model:l,modelColumns:l.columns,top:ve,bottom:fe,left:be,right:Ce,filter:me,formatter:U,sorts:B,reverseType:W,movedColumns:V,customColumns:G,hiddenColumns:Mt,alwaysFetchColumns:this.getAlwaysFetchColumns(d,l.columns,l.floatingLeftColumnCount,l.floatingRightColumnCount),rollupConfig:this.getModelRollupConfig(l.originalColumns,ie,te),totalsConfig:this.getModelTotalsConfig(l.columns,ie,te),selectDistinctColumns:j,pendingRowCount:oe,pendingDataMap:ce,frozenColumns:de}),a.a.createElement("div",{className:qe()("grid-settings-button",{"is-menu-shown":C})},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon",onClick:this.handleMenu},a.a.createElement(Ke.a,{icon:Lt,transform:"up-1"}))),we,He,rt,Be,gt),a.a.createElement(Fp,{error:re,isSaving:null!=se,saveTooltip:"Commit (".concat(this.commitAction.shortcut.getDisplayText(),")"),discardTooltip:"Discard (".concat(this.discardAction.shortcut.getDisplayText(),")"),pendingDataErrors:le,pendingDataMap:ce,onEntering:this.handleAnimationStart,onEntered:this.handleAnimationEnd,onExiting:this.handleAnimationStart,onExited:this.handleAnimationEnd,onSave:this.handlePendingCommitClicked,onDiscard:this.handlePendingDiscardClicked}),a.a.createElement(gg,null,he),a.a.createElement(_p,{model:l,copyOperation:E,onEntering:this.handleAnimationStart,onEntered:this.handleAnimationEnd,onExiting:this.handleAnimationStart,onExited:this.handleAnimationEnd}),a.a.createElement(of,{ref:e=>{this.tableSaver=e},getDownloadWorker:r,onDownloadCompleted:this.handleDownloadCompleted,onDownloadCanceled:this.handleDownloadCanceled,onDownloadProgressUpdate:this.handleDownloadProgressUpdate,isDownloading:Y===av.DOWNLOAD_STATUS.DOWNLOADING,formatter:U})),a.a.createElement(We.CSSTransition,{in:C,timeout:Kn.transitionMidMs,classNames:"slide-left",onEntering:this.handleAnimationStart,onEntered:this.handleAnimationEnd,onExiting:this.handleAnimationStart,onExited:this.handleAnimationEnd,mountOnEnter:!0,unmountOnExit:!0},a.a.createElement("div",{className:"table-sidebar"},a.a.createElement(Mp,null,a.a.createElement(Np,{title:"Table Options",onClose:this.handleMenuClose},a.a.createElement(Ip,{onSelect:e=>this.handleMenuSelect(Tt[e]),items:Tt})),Ot.map(((e,t)=>a.a.createElement(Np,{title:ae[t].title,onBack:this.handleMenuBack,onClose:this.handleMenuClose,key:ae[t].type},e)))))),a.a.createElement(vl,{actions:this.contextActions}))}}Of(Df,"minDebounce",150),Of(Df,"maxDebounce",500),Of(Df,"loadingSpinnerDelay",800),Df.propTypes={children:pi.a.node,advancedFilters:pi.a.instanceOf(Map),advancedSettings:pi.a.instanceOf(Map),alwaysFetchColumns:pi.a.arrayOf(pi.a.string),isFilterBarShown:pi.a.bool,applyInputFiltersOnInit:pi.a.bool,customColumnFormatMap:pi.a.instanceOf(Map),movedColumns:pi.a.arrayOf(pi.a.shape({from:pi.a.number.isRequired,to:pi.a.number.isRequired})),movedRows:pi.a.arrayOf(pi.a.shape({from:pi.a.number.isRequired,to:pi.a.number.isRequired})),inputFilters:pi.a.arrayOf(pi.a.shape({name:pi.a.string.isRequired,type:pi.a.string.isRequired,value:pi.a.string.isRequired})),customFilters:pi.a.arrayOf(pi.a.shape({})),model:pi.a.instanceOf(Cu).isRequired,onCreateChart:pi.a.func,onColumnSelected:pi.a.func,onError:pi.a.func,onDataSelected:pi.a.func,onStateChange:pi.a.func,onPartitionAppend:pi.a.func,onAdvancedSettingsChange:pi.a.func,partition:pi.a.string,partitionColumn:Ma.Column,sorts:pi.a.arrayOf(pi.a.shape({})),reverseType:pi.a.string,quickFilters:pi.a.instanceOf(Map),customColumns:pi.a.arrayOf(pi.a.string),selectDistinctColumns:pi.a.arrayOf(pi.a.string),settings:pi.a.shape({timeZone:pi.a.string.isRequired,defaultDateTimeFormat:pi.a.string.isRequired,showTimeZone:pi.a.bool.isRequired,showTSeparator:pi.a.bool.isRequired,formatter:pi.a.arrayOf(pi.a.shape({})).isRequired}),userColumnWidths:pi.a.instanceOf(Map),userRowHeights:pi.a.instanceOf(Map),onSelectionChanged:pi.a.func,rollupConfig:pi.a.shape({columns:pi.a.arrayOf(pi.a.string),showConstituents:pi.a.bool,showNonAggregatedColumns:pi.a.bool,includeDescriptions:pi.a.bool}),aggregationSettings:pi.a.shape({aggregations:pi.a.arrayOf(pi.a.shape({operation:pi.a.string.isRequired,selected:pi.a.arrayOf(pi.a.string).isRequired,invert:pi.a.bool.isRequired})),showOnTop:pi.a.bool}),isSelectingColumn:pi.a.bool,isSelectingPartition:pi.a.bool,columnSelectionValidator:pi.a.func,columnAllowedCursor:pi.a.string,columnNotAllowedCursor:pi.a.string,name:pi.a.string,onlyFetchVisibleColumns:pi.a.bool,showSearchBar:pi.a.bool,searchValue:pi.a.string,selectedSearchColumns:pi.a.arrayOf(pi.a.string),invertSearchColumns:pi.a.bool,onContextMenu:pi.a.func,pendingDataMap:pi.a.instanceOf(Map),getDownloadWorker:pi.a.func,canCopy:pi.a.bool,canDownloadCsv:pi.a.bool,frozenColumns:pi.a.arrayOf(pi.a.string),theme:pi.a.shape({})},Df.defaultProps={children:null,advancedFilters:new Map,advancedSettings:new Map,alwaysFetchColumns:[],customColumnFormatMap:new Map,isFilterBarShown:!1,applyInputFiltersOnInit:!1,movedColumns:[],movedRows:[],inputFilters:[],customFilters:[],onCreateChart:()=>{},onColumnSelected:()=>{},onDataSelected:()=>{},onError:()=>{},onStateChange:()=>{},onPartitionAppend:()=>{},onAdvancedSettingsChange:()=>{},partition:null,partitionColumn:null,quickFilters:new Map,selectDistinctColumns:[],sorts:[],reverseType:cs.REVERSE_TYPE.NONE,customColumns:[],aggregationSettings:{aggregations:[],showOnTop:!1},rollupConfig:null,userColumnWidths:new Map,userRowHeights:new Map,onSelectionChanged:()=>{},isSelectingColumn:!1,isSelectingPartition:!1,columnSelectionValidator:null,columnAllowedCursor:null,columnNotAllowedCursor:null,name:"table",onlyFetchVisibleColumns:!0,showSearchBar:!1,searchValue:"",selectedSearchColumns:null,invertSearchColumns:!0,onContextMenu:()=>[],pendingDataMap:new Map,getDownloadWorker:void 0,settings:{timeZone:"America/New_York",defaultDateTimeFormat:Ja.FULL_DATE_FORMAT,showTimeZone:!1,showTSeparator:!0,formatter:[]},canCopy:!0,canDownloadCsv:!0,frozenColumns:null,theme:{}};var xf=Df;function Rf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function If(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rf(Object(n),!0).forEach((function(t){Lf(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Lf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ff=p.module("ContextMenu");class kf extends i.PureComponent{static handleContextMenu(e){e.metaKey||(e.stopPropagation(),e.preventDefault())}constructor(e){super(e),Lf(this,"container",void 0),Lf(this,"oldFocus",void 0),Lf(this,"activeSubMenuRef",void 0),Lf(this,"subMenuTimer",void 0),Lf(this,"rAF",void 0),Lf(this,"initialPosition",void 0),this.handleBlur=this.handleBlur.bind(this),this.handleCloseSubMenu=this.handleCloseSubMenu.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMenuItemClick=this.handleMenuItemClick.bind(this),this.handleMenuItemContextMenu=this.handleMenuItemContextMenu.bind(this),this.handleMenuItemMouseMove=this.handleMenuItemMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowResize=this.handleWindowResize.bind(this),this.container=a.a.createRef(),this.oldFocus=document.activeElement,this.activeSubMenuRef=a.a.createRef(),this.subMenuTimer=0,this.rAF=0,this.initialPosition={top:e.top,left:e.left},this.state={menuItems:[],pendingItems:[],activeSubMenu:null,hasOverflow:!1,subMenuTop:null,subMenuLeft:null,subMenuParentWidth:0,subMenuParentHeight:0,keyboardIndex:-1,mouseIndex:-1}}componentDidMount(){this.initMenu(),this.verifyPosition(),window.addEventListener("resize",this.handleWindowResize),this.rAF=window.requestAnimationFrame((()=>{var e;null===(e=this.container.current)||void 0===e||e.focus();var{onMenuOpened:t}=this.props;t(this)}))}componentDidUpdate(e,t){var n,i,a,{actions:s}=this.props,{activeSubMenu:r}=this.state;r!==t.activeSubMenu&&(null==r?null===(n=this.container.current)||void 0===n||n.focus():this.setActiveSubMenuPosition());e.actions!==s&&(this.initMenu(),null!==(i=this.container.current)&&void 0!==i&&i.contains(document.activeElement)||null===(a=this.container.current)||void 0===a||a.focus());this.verifyPosition()}componentWillUnmount(){this.cancelPromises(),window.removeEventListener("resize",this.handleWindowResize),cancelAnimationFrame(this.rAF)}getKeyboardIndex(){var{options:e}=this.props;if(e.separateKeyboardMouse){var{keyboardIndex:t}=this.state;return t}return this.getMouseIndex()}setKeyboardIndex(e){var{options:t}=this.props;t.separateKeyboardMouse?this.setState({keyboardIndex:e}):this.setMouseIndex(e)}getMouseIndex(){var{mouseIndex:e}=this.state;return e}setMouseIndex(e){this.setState({mouseIndex:e})}initMenu(){this.cancelPromises(),cancelAnimationFrame(this.rAF);var{options:e}=this.props,t=e.initialKeyboardIndex;void 0===t&&(t=-1);for(var{actions:n}=this.props,i=je.getMenuItems(n),a=[],s=i.length-1;s>=0;s-=1){var r=i[s];r instanceof Promise?this.initMenuPromise(r):a.push(r)}this.setState({mouseIndex:-1,keyboardIndex:t,activeSubMenu:null,menuItems:je.sortActions(a)})}initMenuPromise(e){var t=Va.makeCancelable(e);this.setState((e=>({pendingItems:e.pendingItems.concat(t)}))),t.then((e=>{this.setState((n=>{var i=n.pendingItems.indexOf(t);if(i>=0){var a=n.pendingItems.slice();return a.splice(i,1),{menuItems:je.sortActions(n.menuItems.concat(e)),pendingItems:a}}return null}))}),(e=>{Va.isCanceled(e)||(this.setState((e=>{var n=e.pendingItems.indexOf(t);if(n>=0){var i=e.pendingItems.slice();return i.splice(n,1),{pendingItems:i}}return null})),Ff.error(e))}))}cancelPromises(){var{pendingItems:e}=this.state;e.map((e=>e.cancel()))}setActiveSubMenuPosition(){if(null!==this.activeSubMenuRef.current){var e=this.activeSubMenuRef.current.getBoundingClientRect();this.setState({subMenuTop:e.top,subMenuLeft:e.right,subMenuParentHeight:e.height,subMenuParentWidth:e.width})}}verifyPosition(){var e,t,n,i,{options:a,updatePosition:s,subMenuParentWidth:r,subMenuParentHeight:o,top:l,left:c}=this.props;if(this.container.current&&!a.doNotVerifyPosition){var{top:h,left:d}=this.initialPosition,{width:u,height:m}=null!==(e=null===(t=this.container.current)||void 0===t?void 0:t.getBoundingClientRect())&&void 0!==e?e:{width:0,height:0},p=(null!==(n=null===(i=this.container.current)||void 0===i?void 0:i.scrollHeight)&&void 0!==n?n:0)>window.innerHeight;0!==m&&0!==u&&(h+m>window.innerHeight&&(h-m-o>0?h-=m-o:h=window.innerHeight-m),d+u>window.innerWidth&&(d=d-u-r),c===d&&l===h||(this.setState({hasOverflow:p}),s(h,d)))}}handleWindowResize(){this.container.current&&this.closeMenu(!0)}handleBlur(e){if(this.container.current){if(!this.container.current.contains(e.relatedTarget)){for(var t=e.relatedTarget,n=!1;t&&!n;)n=t.hasAttribute("data-dh-context-menu"),t=t.parentElement;n||this.closeMenu(!0)}}else Ff.warn("Container is null!")}isEscapeKey(e){var{left:t}=this.props;return"Escape"===e||t<0&&"ArrowRight"===e||"ArrowLeft"===e}handleKeyDown(e){var{menuItems:t}=this.state,n=this.getKeyboardIndex(),i=n,a=!1;if("Enter"!==e.key&&" "!==e.key){if("ArrowRight"===e.key?n>=0&&n<=t.length?a=!0:i=0:this.isEscapeKey(e.key)?i=null:"ArrowUp"===e.key||e.shiftKey&&"Tab"===e.key?i=je.getNextMenuItem(i,-1,t):"ArrowDown"!==e.key&&"Tab"!==e.key||(i=je.getNextMenuItem(i,1,t)),a)return this.openSubMenu(n),e.preventDefault(),void e.stopPropagation();n!==i&&(null!==i?this.setKeyboardIndex(i):(this.closeMenu(),this.oldFocus instanceof HTMLElement&&this.oldFocus.focus()),e.preventDefault(),e.stopPropagation())}else n>=0&&n<t.length&&this.handleMenuItemClick(t[n],e)}openSubMenu(e){var{menuItems:t,activeSubMenu:n}=this.state,i=t[e].actions?e:null;n!==i&&this.setState({activeSubMenu:i,subMenuTop:null,subMenuLeft:null})}closeMenu(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],{closeMenu:t,onMenuClosed:n}=this.props;cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame((()=>{t(e),n(this)}))}closeSubMenu(){this.setState({activeSubMenu:null})}handleCloseSubMenu(e){e?this.closeMenu(!0):this.closeSubMenu()}handleMenuItemClick(e,t){t.preventDefault(),t.stopPropagation();var{menuItems:n}=this.state;null==e||e.disabled||(null!=e.actions?this.openSubMenu(n.indexOf(e)):null!=e.action&&(e.action(),this.closeMenu(!0)))}handleMenuItemContextMenu(e,t){t.metaKey||this.handleMenuItemClick(e,t)}handleMenuItemMouseMove(e){var{menuItems:t}=this.state,n=t.indexOf(e);this.setMouseIndex(n),n>=0&&n<t.length&&!e.disabled&&this.openSubMenu(n)}handleMouseLeave(){this.setMouseIndex(-1)}render(){for(var e=[],{top:t,left:n}=this.props,{activeSubMenu:i,hasOverflow:s,keyboardIndex:r,menuItems:o,mouseIndex:l,pendingItems:c,subMenuTop:h,subMenuLeft:d,subMenuParentWidth:u,subMenuParentHeight:m}=this.state,p=0;p<o.length;p+=1){var g=o[p];p>0&&g.group!==o[p-1].group&&e.push(a.a.createElement("hr",{key:"".concat(p,".separator")}));var v=a.a.createElement(qd,{key:p,ref:i===p?this.activeSubMenuRef:null,isKeyboardSelected:r===p,isMouseSelected:l===p,menuItem:g,closeMenu:this.handleCloseSubMenu,onMenuItemClick:this.handleMenuItemClick,onMenuItemMouseMove:this.handleMenuItemMouseMove,onMenuItemContextMenu:this.handleMenuItemContextMenu});e.push(v)}var f=null;c.length>0&&(f=a.a.createElement("div",{className:"loading"},a.a.createElement(Yn,null)));var{menuStyle:b}=this.props,C=null!==i&&null!==h&&null!==d;return a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:qe()({"has-overflow":s},"context-menu-container"),style:If({top:t,left:n},b),ref:this.container,"data-dh-context-menu":!0,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseLeave:this.handleMouseLeave,onContextMenu:kf.handleContextMenu,role:"menuitem",tabIndex:0},e,f),C&&null!==i&&null!==h&&null!==d&&a.a.createElement(kf,{key:"sub-".concat(i),actions:o[i].actions||[],closeMenu:this.handleCloseSubMenu,top:h,left:d,updatePosition:(e,t)=>{this.setState({subMenuTop:e,subMenuLeft:t})},subMenuParentWidth:u,subMenuParentHeight:m}))}}Lf(kf,"defaultProps",{subMenuParentWidth:0,subMenuParentHeight:0,closeMenu(){},onMenuOpened(){},onMenuClosed(){},options:{},menuStyle:{}});var Af=kf;function Pf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class _f extends i.Component{constructor(e){super(e),Pf(this,"container",void 0),Pf(this,"openMenu",void 0),this.handleMenuClose=this.handleMenuClose.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.container=a.a.createRef(),this.openMenu=a.a.createRef(),this.state={actions:null,left:0,top:0}}componentDidMount(){var e;null!==(e=this.container.current)&&void 0!==e&&e.parentElement&&this.container.current.parentElement.addEventListener("contextmenu",this.handleContextMenu)}componentWillUnmount(){var e;null!==(e=this.container.current)&&void 0!==e&&e.parentElement&&this.container.current.parentElement.removeEventListener("contextmenu",this.handleContextMenu)}handleContextMenu(e){if(je.isContextActionEvent(e)&&this.container.current&&!e.metaKey&&!e.ctrlKey){var t=je.getMenuItems(e.contextActions),n=this.container.current.getBoundingClientRect(),i=e.clientY-n.top,a=e.clientX-n.left;if(0===t.length)return e.target===this.container.current?(e.preventDefault(),void this.setState({actions:null},(()=>{var t=document.elementFromPoint(a,i),n=new MouseEvent("contextmenu",{clientX:e.clientX,clientY:e.clientY,bubbles:!0,cancelable:!0});null===t||void 0===t||t.dispatchEvent(n)}))):void 0;e.preventDefault(),this.setState({actions:t,top:i,left:a})}}handleMenuClose(e){e===this.openMenu.current&&this.setState({actions:null})}render(){var e=null,{actions:t,top:n,left:i}=this.state;return t&&(e=a.a.createElement(Af,{ref:this.openMenu,actions:t,onMenuClosed:this.handleMenuClose,top:n,left:i,updatePosition:(e,t)=>{this.setState({top:e,left:t})}})),a.a.createElement("div",{className:qe()("context-menu-root",{active:t}),ref:this.container},e)}}var Hf=_f;n(1272);function jf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Vf=p.module("IrisGridPanel"),zf={IrisGrid:xf,IrisGridTableModel:Ru,ContextMenuRoot:Hf};class Uf extends i.PureComponent{constructor(e){super(e),jf(this,"getGridInputFilters",Object(ua.a)(((e,t)=>ol.getInputFiltersForColumns(e,t.filter((e=>{var{value:t,excludePanelIds:n}=e;return null!=t&&(null==n||!n.includes(di.getIdFromPanel(this)))})))))),jf(this,"getAlwaysFetchColumns",Object(ua.a)(((e,t)=>{for(var n=di.getIdFromPanel(this),i=new Set(t),a=0;a<e.length;a+=1){var{start:s}=e[a];s&&s.panelId===n&&i.add(s.columnName)}return[...i]}))),jf(this,"getPluginContent",Object(ua.a)(((e,t,n,i,s)=>null==e||null==t?null:a.a.createElement("div",{className:"iris-grid-plugin"},a.a.createElement(e,{ref:this.pluginRef,onFilter:this.handlePluginFilter,onFetchColumns:this.handlePluginFetchColumns,table:t,user:n,panel:this,workspace:i,components:zf,onStateChange:this.handlePluginStateChange,pluginState:s}))))),jf(this,"getDehydratedIrisGridPanelState",Object(ua.a)(((e,t,n,i)=>ol.dehydrateIrisGridPanelState(e,{isSelectingPartition:t,partition:n,partitionColumn:i})))),jf(this,"getDehydratedIrisGridState",Object(ua.a)(((e,t,n,i,a,s,r,o,l,c,h,d,u,m,p,g,v,f,b,C)=>ol.dehydrateIrisGridState(e,{advancedFilters:n,advancedSettings:f,aggregationSettings:v,customColumnFormatMap:i,isFilterBarShown:a,metrics:{userColumnWidths:p,userRowHeights:g},quickFilters:s,customColumns:r,reverseType:o,rollupConfig:l,showSearchBar:c,searchValue:h,selectDistinctColumns:d,selectedSearchColumns:u,sorts:t,invertSearchColumns:m,pendingDataMap:b,frozenColumns:C})))),jf(this,"getDehydratedGridState",Object(ua.a)(((e,t,n)=>ol.dehydrateGridState(e,{movedColumns:t,movedRows:n})))),jf(this,"getCachedPanelState",Object(ua.a)(((e,t,n,i)=>({irisGridPanelState:e,irisGridState:t,gridState:n,pluginState:i})))),this.savePanelState=pa()(this.savePanelState.bind(this),500),this.handleAdvancedSettingsChange=this.handleAdvancedSettingsChange.bind(this),this.handleColumnsChanged=this.handleColumnsChanged.bind(this),this.handleTableChanged=this.handleTableChanged.bind(this),this.handleColumnSelected=this.handleColumnSelected.bind(this),this.handleDataSelected=this.handleDataSelected.bind(this),this.handleError=this.handleError.bind(this),this.handleGridStateChange=this.handleGridStateChange.bind(this),this.handlePluginStateChange=this.handlePluginStateChange.bind(this),this.handlePartitionAppend=this.handlePartitionAppend.bind(this),this.handleCreateChart=this.handleCreateChart.bind(this),this.handleResize=this.handleResize.bind(this),this.handleShow=this.handleShow.bind(this),this.handleDisconnect=this.handleDisconnect.bind(this),this.handleReconnect=this.handleReconnect.bind(this),this.handleLoadSuccess=this.handleLoadSuccess.bind(this),this.handleLoadError=this.handleLoadError.bind(this),this.isColumnSelectionValid=this.isColumnSelectionValid.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.handlePluginFilter=this.handlePluginFilter.bind(this),this.handlePluginFetchColumns=this.handlePluginFetchColumns.bind(this),this.handleClearAllFilters=this.handleClearAllFilters.bind(this),this.irisGrid=a.a.createRef(),this.pluginRef=a.a.createRef(),this.modelPromise=null;var{panelState:t,metadata:n}=e,i=n.query;this.irisGridState=null,this.gridState=null,this.pluginState=null,this.state={error:null,isDisconnected:!1,isLoaded:!1,isLoading:!0,isModelReady:!1,model:null,advancedFilters:new Map,aggregationSettings:{aggregations:[],showOnTop:!1},advancedSettings:new Map(Yo.DEFAULTS),customColumns:[],customColumnFormatMap:new Map,isFilterBarShown:!1,quickFilters:new Map,sorts:[],userColumnWidths:new Map,userRowHeights:new Map,reverseType:cs.REVERSE_TYPE.NONE,movedColumns:[],movedRows:[],isSelectingPartition:!1,partition:null,partitionColumn:null,queryName:i,rollupConfig:null,showSearchBar:!1,searchValue:"",selectedSearchColumns:null,invertSearchColumns:!0,Plugin:null,pluginFilters:[],pluginFetchColumns:[],modelQueue:[],pendingDataMap:new Map,frozenColumns:null,panelState:t}}componentDidMount(){this.initModel()}componentDidUpdate(e,t){var{model:n}=this.state;n!==t.model&&(null!=t.model&&(this.stopModelListening(t.model),t.model.close()),null!=n&&this.startModelListening(n))}componentWillUnmount(){this.savePanelState.cancel(),null!=this.modelPromise&&(this.modelPromise.cancel(),this.modelPromise=null);var{model:e}=this.state;e&&(this.stopModelListening(e),e.close())}getTableName(){var{metadata:e}=this.props;return e.table}initModel(){this.setState({isModelReady:!1,isLoading:!0,error:null});var{makeModel:e}=this.props;null!=this.modelPromise&&this.modelPromise.cancel(),this.modelPromise=Va.makeCancelable(e(),(e=>e.close)),this.modelPromise.then(this.handleLoadSuccess).catch(this.handleLoadError)}handleLoadSuccess(e){var t=e,{panelState:n}=this.props,i=[];if(null!=n){var{irisGridState:a}=n,{aggregationSettings:s,customColumns:r,selectDistinctColumns:o=[],rollupConfig:l}=a;r.length>0&&i.push((e=>{e.customColumns=r})),null!=l&&l.columns.length>0&&i.push((e=>{e.rollupConfig=ol.getModelRollupConfig(e.originalColumns,l,s)})),o.length>0&&i.push((e=>{e.selectDistinctColumns=o}))}this.setState({model:t,modelQueue:i}),this.initModelQueue(t,i)}initModelQueue(e,t){var n=e;if(0!==t.length){var i=t.shift();Vf.debug("initModelQueue",i),i(n),this.setState({modelQueue:t})}else this.modelInitialized(n)}handleAdvancedSettingsChange(e,t){Vf.debug("handleAdvancedSettingsChange",e,t),this.setState((n=>{var{advancedSettings:i}=n;return i.get(e)===t?null:{advancedSettings:new Map(i).set(e,t)}}))}handlePluginFilter(e){var{model:t}=this.state,{columns:n,formatter:i}=t,a=ol.getFiltersFromInputFilters(n,e,i.timeZone);this.setState({pluginFilters:a})}handlePluginFetchColumns(e){this.setState({pluginFetchColumns:e})}handleContextMenu(e){var t,n,i;return null!==(t=null===(n=this.pluginRef.current)||void 0===n||null===(i=n.getMenu)||void 0===i?void 0:i.call(n,e))&&void 0!==t?t:[]}isColumnSelectionValid(e){var{columnSelectionValidator:t}=this.props;return!!t&&t(this,e)}handleGridStateChange(e,t){this.irisGridState=e,this.gridState=t,this.setState({isLoaded:!0,isLoading:!1}),this.savePanelState();var{glEventHub:n,onStateChange:i}=this.props;n.emit(_l.STATE_CHANGED,this),i(e,t)}handlePluginStateChange(e){var{irisGridState:t,gridState:n}=this;this.pluginState=e,null!==t&&null!==n&&this.savePanelState()}handleColumnsChanged(e){var{isModelReady:t,model:n,modelQueue:i}=this.state;t?this.sendColumnsChange(e.detail):this.initModelQueue(n,i)}handleTableChanged(e){Vf.debug("handleTableChanged",e);var{glEventHub:t}=this.props,{detail:n}=e;t.emit(kl.TABLE_CHANGED,this,n)}handlePartitionAppend(e,t){var{glEventHub:n}=this.props,{name:i}=e,a=this.getTableName(),s="".concat(a," = ").concat(a,'.where("').concat(i,"=`").concat(t,'`")');n.emit(Il.SEND_COMMAND,s,!1,!0)}handleCreateChart(e,t){this.savePanelState.flush(),this.setState((()=>null),(()=>{var{glEventHub:n,inputFilters:i,metadata:a}=this.props,{querySerial:s,table:r}=a,{panelState:o}=this.state,l=di.getIdFromPanel(this),c=ol.extractTableSettings(o,i),h=fs.titleFromSettings(e);n.emit(Dl.OPEN,h,(()=>Vh.makeModelFromSettings(e,t)),{querySerial:s,settings:fs.dehydrateSettings(e),sourcePanelId:l,table:r,tableSettings:c})}))}handleColumnSelected(e){var{glEventHub:t}=this.props;t.emit(_l.COLUMN_SELECTED,this,e)}handleDataSelected(e,t){var{glEventHub:n}=this.props;n.emit(_l.DATA_SELECTED,this,t)}handleResize(){this.updateGrid()}handleShow(){this.updateGrid()}handleError(e){Vf.error(e),this.setState({error:e,isLoading:!1})}handleDisconnect(){this.setState({error:new Error("Table disconnected"),isDisconnected:!0,isLoading:!1})}handleReconnect(){this.setState({isDisconnected:!1,error:null})}handleLoadError(e){Va.isCanceled(e)||this.handleError(e)}modelInitialized(e){var{glEventHub:t,loadPlugin:n}=this.props;this.modelPromise=null,this.loadPanelState(e),this.setState({isModelReady:!0});var{table:i}=e,{pluginName:a}=i;if(n&&a){var s=n(a);this.setState({Plugin:s})}t.emit(kl.TABLE_CHANGED,this,i),this.sendColumnsChange(e.columns)}handleClearAllFilters(){var e=this.irisGrid.current,{isDisconnected:t}=this.state;null==e||t||e.clearAllFilters()}sendColumnsChange(e){Vf.debug2("sendColumnsChange",e);var{glEventHub:t}=this.props;t.emit(kl.COLUMNS_CHANGED,this,e)}startModelListening(e){e.addEventListener(Cu.EVENT.DISCONNECT,this.handleDisconnect),e.addEventListener(Cu.EVENT.RECONNECT,this.handleReconnect),e.addEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleColumnsChanged),e.addEventListener(Cu.EVENT.TABLE_CHANGED,this.handleTableChanged)}stopModelListening(e){e.removeEventListener(Cu.EVENT.DISCONNECT,this.handleDisconnect),e.removeEventListener(Cu.EVENT.RECONNECT,this.handleReconnect),e.removeEventListener(Cu.EVENT.COLUMNS_CHANGED,this.handleColumnsChanged),e.removeEventListener(Cu.EVENT.TABLE_CHANGED,this.handleTableChanged)}getCoordinateForColumn(e){var t,{model:n}=this.state;if(!n)return null;var i=this.irisGrid.current,{gridWrapper:a}=i||{},s=null!==(t=null===a||void 0===a?void 0:a.getBoundingClientRect())&&void 0!==t?t:null;if(null==s||s.width<=0||s.height<=0)return null;var{metrics:r}=i.state,{columnHeaderHeight:o,visibleColumnXs:l,visibleColumnWidths:c,right:h}=r,d=i.getVisibleColumn(n.getColumnIndexByName(e)),u=l.get(d)||0,m=c.get(d)||0;return[Math.max(s.left,Math.min(d>h?s.right:s.left+u+.5*m,s.right)),s.top+o]}setFilterMap(e){var t=this.irisGrid.current;null!=t&&t.setFilterMap(e)}setAdvancedFilterMap(e){var t=this.irisGrid.current;null!=t&&t.setAdvancedFilterMap(e)}setFilters(e){var{quickFilters:t,advancedFilters:n}=e,i=this.irisGrid.current,{model:a,isDisconnected:s}=this.state;if(null!=i&&!s){var{columns:r,formatter:o}=a;i.clearAllFilters(),i.setFilters({quickFilters:ol.hydrateQuickFilters(r,t,o.timeZone),advancedFilters:ol.hydrateAdvancedFilters(r,n,o.timeZone)})}}unsetFilterValue(){}loadPanelState(e){var{panelState:t}=this.props;if(null!=t)try{var{gridState:n,irisGridState:i,irisGridPanelState:a}=t,{isSelectingPartition:s,partition:r,partitionColumn:o}=ol.hydrateIrisGridPanelState(e,a),{advancedFilters:l,advancedSettings:c,customColumns:h,customColumnFormatMap:d,isFilterBarShown:u,quickFilters:m,reverseType:p,rollupConfig:g,aggregationSettings:v,sorts:f,userColumnWidths:b,userRowHeights:C,showSearchBar:S,searchValue:E,selectDistinctColumns:w,selectedSearchColumns:y,invertSearchColumns:T,pendingDataMap:O,frozenColumns:M}=ol.hydrateIrisGridState(e,i),{movedColumns:N,movedRows:D}=ol.hydrateGridState(e,n,i.customColumns);this.setState({advancedFilters:l,advancedSettings:c,customColumns:h,customColumnFormatMap:d,isFilterBarShown:u,isSelectingPartition:s,movedColumns:N,movedRows:D,partition:r,partitionColumn:o,quickFilters:m,reverseType:p,rollupConfig:g,aggregationSettings:v,sorts:f,userColumnWidths:b,userRowHeights:C,showSearchBar:S,searchValue:E,selectDistinctColumns:w,selectedSearchColumns:y,invertSearchColumns:T,pendingDataMap:O,frozenColumns:M})}catch(x){Vf.error("loadPanelState failed to load panelState",t,x)}}savePanelState(){var{irisGridState:e,gridState:t,pluginState:n}=this,{onPanelStateUpdate:i}=this.props,{model:a,panelState:s,isSelectingPartition:r,partition:o,partitionColumn:l,advancedSettings:c}=this.state,{advancedFilters:h,aggregationSettings:d,customColumnFormatMap:u,isFilterBarShown:m,quickFilters:p,customColumns:g,reverseType:v,rollupConfig:f,showSearchBar:b,searchValue:C,selectDistinctColumns:S,selectedSearchColumns:E,sorts:w,invertSearchColumns:y,metrics:T,pendingDataMap:O,frozenColumns:M}=e,{userColumnWidths:N,userRowHeights:D}=T,{movedColumns:x,movedRows:R}=t,I=this.getCachedPanelState(this.getDehydratedIrisGridPanelState(a,r,o,l),this.getDehydratedIrisGridState(a,w,h,u,m,p,g,v,f,b,C,S,E,y,N,D,d,c,O,M),this.getDehydratedGridState(a,x,R),n);I!==s&&(Vf.debug("Saving panel state",this,I),this.setState({panelState:I}),i(I))}updateGrid(){var e,t,n=null!==(e=null===(t=this.irisGrid.current)||void 0===t?void 0:t.grid)&&void 0!==e?e:null;n&&n.handleResize()}render(){var e,t,{children:n,glContainer:i,glEventHub:s,columnSelectionValidator:r,getDownloadWorker:o,inputFilters:l,links:c,metadata:h,panelState:d,user:u,workspace:m,settings:p}=this.props,{advancedFilters:g,aggregationSettings:v,advancedSettings:f,customColumns:b,customColumnFormatMap:C,error:S,isDisconnected:E,isFilterBarShown:w,isSelectingPartition:y,isLoaded:T,isLoading:O,isModelReady:M,model:N,movedColumns:D,movedRows:x,partition:R,partitionColumn:I,queryName:L,quickFilters:F,reverseType:k,rollupConfig:A,sorts:P,userColumnWidths:_,userRowHeights:H,showSearchBar:j,searchValue:V,selectDistinctColumns:z,selectedSearchColumns:U,invertSearchColumns:B,Plugin:W,pluginFilters:G,pluginFetchColumns:q,pendingDataMap:K,frozenColumns:Y}=this.state,X=S?"Unable to open table. ".concat(S):null,{table:Z,querySerial:$}=h,Q=null!==(e=null===N||void 0===N?void 0:N.description)&&void 0!==e?e:null,J=null!==(t=null===d||void 0===d?void 0:d.pluginState)&&void 0!==t?t:null,ee=null!==n&&void 0!==n?n:this.getPluginContent(W,null===N||void 0===N?void 0:N.table,u,m,J),{permissions:te}=u,{canCopy:ne,canDownloadCsv:ie}=te;return a.a.createElement(ic,{errorMessage:X,isDisconnected:E,isLoading:O,isLoaded:T,className:"iris-grid-panel",glContainer:i,glEventHub:s,onClearAllFilters:this.handleClearAllFilters,onResize:this.handleResize,onShow:this.handleShow,onTabFocus:this.handleShow,queryName:L,querySerial:$,widgetName:Z,widgetType:"Table",description:Q,componentPanel:this},M&&a.a.createElement(xf,{advancedFilters:g,aggregationSettings:v,advancedSettings:f,alwaysFetchColumns:this.getAlwaysFetchColumns(c,q),columnAllowedCursor:"linker",columnNotAllowedCursor:"not-allowed",customColumns:b,customColumnFormatMap:C,columnSelectionValidator:this.isColumnSelectionValid,inputFilters:this.getGridInputFilters(N.columns,l),applyInputFiltersOnInit:null==d,isFilterBarShown:w,isSelectingColumn:null!=r,isSelectingPartition:y,movedColumns:D,movedRows:x,partition:R,partitionColumn:I,quickFilters:F,reverseType:k,rollupConfig:A,settings:p,sorts:P,userColumnWidths:_,userRowHeights:H,model:N,tableName:Z,showSearchBar:j,searchValue:V,selectedSearchColumns:U,selectDistinctColumns:z,invertSearchColumns:B,onColumnSelected:this.handleColumnSelected,onCreateChart:this.handleCreateChart,onDataSelected:this.handleDataSelected,onError:this.handleError,onPartitionAppend:this.handlePartitionAppend,onStateChange:this.handleGridStateChange,onContextMenu:this.handleContextMenu,onAdvancedSettingsChange:this.handleAdvancedSettingsChange,customFilters:G,pendingDataMap:K,canCopy:ne,canDownloadCsv:ie,ref:this.irisGrid,getDownloadWorker:o,frozenColumns:Y},ee),!M&&a.a.createElement(a.a.Fragment,null))}}jf(Uf,"COMPONENT","IrisGridPanel"),Uf.propTypes={children:pi.a.node,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,metadata:pi.a.shape({table:pi.a.string.isRequired,query:pi.a.string,querySerial:pi.a.string}).isRequired,panelState:pi.a.shape({gridState:pi.a.shape({}),irisGridState:pi.a.shape({aggregationSettings:pi.a.shape({}),customColumns:pi.a.arrayOf(pi.a.string),selectDistinctColumns:pi.a.arrayOf(pi.a.string),rollupConfig:pi.a.shape({columns:pi.a.arrayOf(pi.a.string).isRequired}),pendingDataMap:pi.a.arrayOf(pi.a.array),frozenColumns:pi.a.arrayOf(pi.a.string)}),irisGridPanelState:pi.a.shape({}),pluginState:pi.a.shape({})}),makeModel:pi.a.func.isRequired,inputFilters:pi.a.arrayOf(mc.InputFilter).isRequired,links:mc.Links.isRequired,columnSelectionValidator:pi.a.func,onStateChange:pi.a.func,onPanelStateUpdate:pi.a.func,user:mc.User.isRequired,workspace:pi.a.shape({}).isRequired,settings:pi.a.shape({timeZone:pi.a.string.isRequired}).isRequired,getDownloadWorker:pi.a.func,loadPlugin:pi.a.func},Uf.defaultProps={children:null,panelState:null,columnSelectionValidator:null,onStateChange:()=>{},onPanelStateUpdate:()=>{},getDownloadWorker:void 0,loadPlugin:void 0},Uf.displayName="IrisGridPanel";var Bf=Object(o.b)(((e,t)=>{var{localDashboardId:n}=t;return{inputFilters:Cc(e,n),links:wc(e,n),columnSelectionValidator:yc(e,n),user:L(e),workspace:P(e),settings:_(e)}}),null,null,{forwardRef:!0})(Uf);n(1302);function Wf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Gf=p.module("InputFilter");class qf extends i.Component{constructor(e){super(e),Wf(this,"getItemLabel",Lr()(((e,t)=>{var{name:n,type:i}=e[t];if(t>0&&e[t-1].name===n||t<e.length-1&&e[t+1].name===n){var a=i.substring(i.lastIndexOf(".")+1);return"".concat(n," (").concat(a,")")}return n}))),this.handleColumnChange=this.handleColumnChange.bind(this),this.handleInputKeyPress=this.handleInputKeyPress.bind(this),this.handleValueChange=this.handleValueChange.bind(this),this.handleSettingsCancel=this.handleSettingsCancel.bind(this),this.handleSettingsClick=this.handleSettingsClick.bind(this),this.handleSettingsSave=this.handleSettingsSave.bind(this),this.handleBackgroundClick=this.handleBackgroundClick.bind(this),this.sendUpdate=pa()(this.sendUpdate.bind(this),150),this.inputRef=a.a.createRef();var{column:t,isValueShown:n,value:i}=e;this.state={column:t,selectedColumn:t,value:i,isValueShown:n}}componentDidUpdate(e,t){var{column:n}=this.props,{column:i,value:a,isValueShown:s}=this.state;n!==e.column&&this.setState({column:n,selectedColumn:n}),s&&s!==t.isValueShown&&this.focusInput(),i===t.column&&a===t.value&&s===t.isValueShown||this.sendUpdate()}componentWillUnmount(){this.sendUpdate.flush()}handleColumnChange(e){var{columns:t}=this.props,{value:n}=e.target,i=t[n];Gf.debug2("handleColumnChange",i),this.setState({selectedColumn:i,value:null})}handleInputKeyPress(e){"Enter"===e.key&&(e.preventDefault(),e.stopPropagation(),this.setState((e=>{var{value:t}=e;return null==t?{value:""}:null}),(()=>{this.sendUpdate(),this.sendUpdate.flush()})))}handleValueChange(e){var{value:t}=e.target;Gf.debug2("handleValueChange",t),this.setState({value:t})}handleSettingsCancel(){var{column:e}=this.state;this.setState({selectedColumn:e,isValueShown:!0})}handleSettingsSave(){var{selectedColumn:e}=this.state;this.setState({column:e,isValueShown:!0})}handleSettingsClick(e){var{column:t}=this.state;this.setState({selectedColumn:t,isValueShown:!1}),e.stopPropagation()}handleBackgroundClick(e){e.target!==this.inputRef.current&&this.focusInput()}focusInput(){null!==this.inputRef.current&&(this.inputRef.current.select(),this.inputRef.current.focus())}clearFilter(){this.setState({value:""})}setFilterState(e){var{name:t,type:n,value:i,isValueShown:a}=e,s=null!=t&&null!=n?{name:t,type:n}:null;this.setState({column:s,value:i,isValueShown:a})}sendUpdate(){var{onChange:e}=this.props,{column:t,value:n,isValueShown:i}=this.state;e({column:t,isValueShown:i,value:n})}render(){var{columns:e}=this.props,{column:t,isValueShown:n,selectedColumn:i,value:s}=this.state,r=null==s||0===s.length?qf.PLACEHOLDER.length:s.length,o=null;if(null!=t){var l=e.findIndex((e=>e.name===t.name&&e.type===t.type));o=l>=0?this.getItemLabel(e,l):t.name}return a.a.createElement(Zu,{className:"input-filter fill-parent-absolute",isFlipped:n},a.a.createElement("div",{className:"input-filter-settings-card"},a.a.createElement("div",{className:"input-filter-settings-content"},a.a.createElement("div",{className:"input-filter-settings-grid"},a.a.createElement("label",null,"Filter Column"),a.a.createElement("select",{value:e.findIndex((e=>e.name===(null===i||void 0===i?void 0:i.name)&&e.type===(null===i||void 0===i?void 0:i.type))),className:"custom-select",onChange:this.handleColumnChange},e.map(((t,n)=>a.a.createElement("option",{key:"".concat(t.name,"/").concat(t.type),value:n},this.getItemLabel(e,n)))),0===e.length&&a.a.createElement("option",{value:"-1",disabled:!0},"No Available Columns")),a.a.createElement("div",{className:"text-muted small"},"Input filter control will apply its filter to all columns matching this name in this dashboard.")),a.a.createElement("div",{className:"input-filter-settings-buttons"},a.a.createElement("button",{type:"button",className:"btn btn-outline-primary",onClick:this.handleSettingsCancel,disabled:null==t},"Cancel"),a.a.createElement("button",{type:"button",className:"btn btn-primary ml-2",onClick:this.handleSettingsSave,disabled:null==i},"Save")))),a.a.createElement("div",{className:"input-filter-value-card",onClick:this.handleBackgroundClick},a.a.createElement("div",{className:"input-filter-column"},a.a.createElement("div",{className:"input-filter-column-title"},o," Filter")),a.a.createElement("div",{className:"d-flex justify-content-center align-items-center h-100 w-100"},a.a.createElement("div",{className:"input-filter-value-input d-flex flex-column justify-content-center"},a.a.createElement("input",{type:"text",ref:this.inputRef,placeholder:qf.PLACEHOLDER,value:null!==s&&void 0!==s?s:"",onChange:this.handleValueChange,onKeyPress:this.handleInputKeyPress,style:{width:"".concat(r+3,"ch")},spellCheck:"false"}))),a.a.createElement("div",{className:"input-filter-menu"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon m-2 px-2",onClick:this.handleSettingsClick},a.a.createElement(Ke.a,{icon:Et,transform:"grow-4"})))))}}Wf(qf,"PLACEHOLDER","Enter value..."),qf.propTypes={columns:pi.a.arrayOf(Ma.Column).isRequired,column:Ma.Column,isValueShown:pi.a.bool,value:pi.a.string,onChange:pi.a.func.isRequired},qf.defaultProps={column:null,isValueShown:!1,value:null};var Kf=qf;class Yf extends i.Component{constructor(e){super(e),this.handleChange=pa()(this.handleChange.bind(this),250),this.handleClearAllFilters=this.handleClearAllFilters.bind(this),this.inputFilterRef=a.a.createRef();var{panelState:t}=e,{value:n=null,isValueShown:i=!1,name:s,type:r,timestamp:o=null}=null!==t&&void 0!==t?t:{};this.state={columns:[],column:s&&r?{name:s,type:r}:null,value:n,timestamp:o,isValueShown:i,wasFlipped:!1,skipUpdate:!1,panelState:t}}componentDidMount(){this.updateColumns();var{column:e,value:t,timestamp:n}=this.state;if(null!=e){var{name:i,type:a}=e;this.sendUpdate(i,a,t,n)}}componentDidUpdate(e){var{columns:t}=this.props;t!==e.columns&&this.updateColumns()}handleChange(e){var{column:t,isValueShown:n,value:i}=e,{name:a,type:s}=t,r=!0,o=Date.now();this.setState((e=>{var{panelState:t,timestamp:l,wasFlipped:c,skipUpdate:h}=e,d=null!=t&&n!==t.isValueShown&&a===t.name&&s===t.type&&i===t.value;return(r=!h&&n&&(!d||!c))||(o=l),{panelState:{isValueShown:n,name:a,type:s,value:i,timestamp:o},timestamp:o,wasFlipped:d,skipUpdate:!1}}),(()=>{r&&this.sendUpdate(a,s,i,o)}))}handleClearAllFilters(){this.inputFilterRef.current.clearFilter()}sendUpdate(e,t,n,i){var{glEventHub:a}=this.props;a.emit(kl.FILTERS_CHANGED,this,{name:e,type:t,value:n,timestamp:i})}setPanelState(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.setState({skipUpdate:!n}),null===(t=this.inputFilterRef.current)||void 0===t||t.setFilterState(e)}updateColumns(){var{columns:e}=this.props;null!=e&&this.setState((t=>{var{column:n}=t;return null==n&&e.length>0?{columns:[...e],column:e[0]}:null==n||e.find((e=>{var{name:t,type:i}=e;return n.name===t&&n.type===i}))?{columns:[...e]}:{columns:[...e,n]}}))}render(){var{glContainer:e,glEventHub:t}=this.props,{column:n,columns:i,isValueShown:s,value:r}=this.state;return a.a.createElement(Jl,{className:"iris-input-filter-panel",componentPanel:this,glContainer:e,glEventHub:t,onClearAllFilters:this.handleClearAllFilters,isClonable:!0,isRenamable:!0},a.a.createElement(Kf,{ref:this.inputFilterRef,column:n,columns:i,onChange:this.handleChange,isValueShown:s,value:r}))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Yf,"COMPONENT","InputFilterPanel"),Yf.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({name:pi.a.string,type:pi.a.string,value:pi.a.string,isValueShown:pi.a.bool}),columns:pi.a.arrayOf(pi.a.shape({})).isRequired},Yf.defaultProps={panelState:null},Yf.displayName="InputFilterPanel";var Xf=Object(o.b)(((e,t)=>{var{localDashboardId:n}=t;return{columns:fc(e,n)}}),null,null,{forwardRef:!0})(Yf);n(1303);var Zf=p.module("FilterSetManagerPanel");class $f extends i.Component{static changeFilterColumnNamesToIndexes(e,t){return t.map((t=>{var{name:n,filter:i}=t,a=e.columns.findIndex((e=>e.name===n));return a<0?null:[a,i]})).filter((e=>null!=e))}static changeFilterIndexesToColumnNames(e,t){return t.map((t=>{var[n,i]=t;if(n>=e.columns.length)return null;var{name:a}=e.columns[n];return{name:a,filter:i}})).filter((e=>null!=e))}constructor(e){super(e),this.handleChange=this.handleChange.bind(this),this.handleFilterApply=this.handleFilterApply.bind(this),this.handleSetsUpdate=this.handleSetsUpdate.bind(this),this.handleGetFilterState=this.handleGetFilterState.bind(this);var{panelState:t,filterSets:n}=e,{selectedId:i=(n.length>0?n[0].id:void 0),isValueShown:a=!1}=null!==t&&void 0!==t?t:{};this.state={selectedId:i,isValueShown:a,panelState:t}}getFilterState(){var{dashboardOpenedPanelMap:e}=this.props,t=[];return[...e.keys()].forEach((n=>{var i=e.get(n),a=di.getComponentNameFromPanel(i),s=di.getIdFromPanel(i);Zf.debug("Panel:",i,a);var{glContainer:r=null}=i.props;if(null!=r){var o=di.getComponentConfigFromContainer(r);if(null!=o){var l=di.getPanelComponentState(o);if(null!=l)switch(a){case di.getComponentName(Bf):var c=this.getIrisGridPanelFilters(s,l);null!=c&&t.push({panelId:s,type:a,state:c});break;case di.getComponentName(Xf):case di.getComponentName(am):var{isValueShown:h,name:d,type:u,value:m}=l;t.push({panelId:s,type:a,state:{isValueShown:h,name:d,type:u,value:m}})}else Zf.debug("Panel state is null ".concat(s))}else Zf.error("Could not get component config from container",r)}else Zf.error("Could not get panel container",i)})),t}getIrisGridPanelFilters(e,t){var{panelTableMap:n}=this.props,i=n.get(e);if(null==i)return Zf.error("Unable to get table for panel ".concat(e,".")),null;var{irisGridState:a=null}=t,{advancedFilters:s=[],quickFilters:r=[]}=null!==a&&void 0!==a?a:{},o=ol.dehydrateAdvancedFilters(i.columns,s),l=$f.changeFilterIndexesToColumnNames(i,o),c=ol.dehydrateQuickFilters(r);return{advancedFilters:l,quickFilters:$f.changeFilterIndexesToColumnNames(i,c)}}handleGetFilterState(){return this.getFilterState()}handleChange(e){var{isValueShown:t,selectedId:n}=e;Zf.debug("handleChange",t,n),this.setState({isValueShown:t,selectedId:n}),this.updatePanelState()}handleFilterApply(e){var{dashboardOpenedPanelMap:t}=this.props,{panels:n}=e;Zf.debug("Apply filters from filter set",e),n.forEach((e=>{var{panelId:n,type:i,state:a}=e;if(t.has(n)){Zf.debug("Apply panel filters",n,i,a);var s=t.get(n);switch(i){case di.getComponentName(Bf):this.restoreIrisGridFilters(s,a);break;case di.getComponentName(Xf):case di.getComponentName(am):this.restoreInputFilterState(s,a)}}else Zf.debug("Ignore closed panel",n)}))}handleSetsUpdate(e,t){var{setDashboardFilterSets:n,localDashboardId:i}=this.props,{selectedId:a}=this.state;void 0!==e.find((e=>{var{id:t}=e;return t===a}))&&this.setState({selectedId:t}),Zf.debug("Saving updated sets",e),n(i,[...e])}updatePanelState(){this.setState((e=>{var{selectedId:t,isValueShown:n}=e;return{panelState:{selectedId:t,isValueShown:n}}}))}restoreIrisGridFilters(e,t){var{advancedFilters:n,quickFilters:i}=t,{panelTableMap:a}=this.props,s=di.getIdFromPanel(e),r=a.get(s);if(null!=r){Zf.debug("restoreIrisGridFilters",s,t);var o=$f.changeFilterColumnNamesToIndexes(r,i),l=$f.changeFilterColumnNamesToIndexes(r,n);e.setFilters({quickFilters:o,advancedFilters:l})}else Zf.error("Unable to get table for panel ".concat(s,"."))}restoreInputFilterState(e,t){Zf.debug("restoreInputFilterState",e,t),e.setPanelState(t)}render(){var{glContainer:e,glEventHub:t,filterSets:n}=this.props,{isValueShown:i,selectedId:s}=this.state;return a.a.createElement(Jl,{className:"filter-set-manager-panel",componentPanel:this,glContainer:e,glEventHub:t,isClonable:!0,isRenamable:!0},a.a.createElement("div",{className:"input-filter-container h-100 w-100 container"},a.a.createElement(Tp,{onChange:this.handleChange,onApply:this.handleFilterApply,onUpdateSets:this.handleSetsUpdate,isValueShown:i,filterSets:n,selectedId:s,getFilterState:this.handleGetFilterState})))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}($f,"COMPONENT","FilterSetManagerPanel"),$f.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({name:pi.a.string,type:pi.a.string,selectedId:pi.a.string,isValueShown:pi.a.bool}),filterSets:pi.a.arrayOf(pi.a.shape({id:pi.a.string.isRequired,title:pi.a.string.isRequired,panels:pi.a.arrayOf(pi.a.shape({})).isRequired})).isRequired,localDashboardId:pi.a.string.isRequired,dashboardOpenedPanelMap:pi.a.instanceOf(Map).isRequired,setDashboardFilterSets:pi.a.func.isRequired,panelTableMap:pi.a.instanceOf(Map).isRequired},$f.defaultProps={panelState:null};var Qf=Object(o.b)(((e,t)=>{var{localDashboardId:n}=t;return{filterSets:bc(e,n),dashboardOpenedPanelMap:qi(e,n),dashboardInputFilters:Cc(e,n),panelTableMap:Sc(e,n)}}),{setDashboardFilterSets:(e,t)=>n=>n($i(e,{filterSets:t}))},null,{forwardRef:!0})($f);n(1305),n(1306);class Jf extends i.PureComponent{constructor(e){super(e),this.handleSwitchClick=this.handleSwitchClick.bind(this)}handleSwitchClick(){var{logLevel:e,onClick:t}=this.props;t(e)}render(){var{logLevel:e,on:t}=this.props;return a.a.createElement("div",{className:qe()("log-level-menu-item",e)},a.a.createElement(Dp,{on:t,onClick:this.handleSwitchClick}),e)}}Jf.propTypes={logLevel:pi.a.string.isRequired,on:pi.a.bool.isRequired,onClick:pi.a.func.isRequired};var eb=Jf;function tb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function nb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tb(Object(n),!0).forEach((function(t){ib(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ib(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class ab extends i.PureComponent{static getLogText(e){var t=new Date(e.micros/1e3),n=Wh.formatTimestamp(t);return"".concat(n," ").concat(e.logLevel," ").concat(e.message)}constructor(e){super(e),this.handleClearClick=this.handleClearClick.bind(this),this.handleFlushTimeout=this.handleFlushTimeout.bind(this),this.handleLogMessage=this.handleLogMessage.bind(this),this.handleMenuItemClick=this.handleMenuItemClick.bind(this),this.handleResetClick=this.handleResetClick.bind(this),this.handleResize=this.handleResize.bind(this),this.handleToggleAllClick=this.handleToggleAllClick.bind(this),this.cancelListener=null,this.editor=null,this.editorContainer=null,this.logLevelMenuItems={},this.flushTimer=null,this.bufferedMessages=[],this.messages=[],this.state={shownLogLevels:{}}}componentDidMount(){this.resetLogLevels(),this.initMonaco(),this.startListening(),window.addEventListener("resize",this.handleResize)}componentDidUpdate(e,t){this.updateDimensions();var{shownLogLevels:n}=this.state;t.shownLogLevels!==n&&this.refreshLogText();var{session:i}=this.props;e.session!==i&&(this.stopListening(),this.startListening(),this.clearLogs())}componentWillUnmount(){this.stopFlushTimer(),this.stopListening(),this.destroyMonaco(),window.removeEventListener("resize",this.handleResize)}getMenuActions(e){var t=this,n=[];n.push({menuElement:a.a.createElement("div",{className:"log-level-menu-title"},"Display Log Levels"),group:1,order:10});for(var i=function(i){var s=ab.AllLogLevels[i],r=null!=e[s]&&e[s];n.push({title:s,group:1,order:i+100,menuElement:a.a.createElement(eb,{logLevel:s,on:r,onClick:t.handleMenuItemClick,ref:e=>{t.logLevelMenuItems[s]=e}})})},s=0;s<ab.AllLogLevels.length;s+=1)i(s);return n.push({group:1,order:1e3,menuElement:a.a.createElement("div",{className:"log-level-menu-controls"},a.a.createElement("button",{type:"button",className:"btn btn-link log-level-toggle-all",onClick:this.handleToggleAllClick},"Toggle All"),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.handleResetClick},"Reset"))}),n}resetLogLevels(){for(var e={},t=0;t<ab.AllLogLevels.length;t+=1){var n=ab.AllLogLevels[t],i=ab.DefaultLogLevels.indexOf(n)>=0;e[n]=i}this.setState({shownLogLevels:e})}startListening(){var{session:e}=this.props;this.cancelListener=e.onLogMessage(this.handleLogMessage)}stopListening(){null!=this.cancelListener&&(this.cancelListener(),this.cancelListener=null)}initMonaco(){this.editor=l.c.create(this.editorContainer,{copyWithSyntaxHighlighting:"false",fixedOverflowWidgets:!0,folding:!1,fontFamily:"Fira Mono",glyphMargin:!1,language:"log",lineDecorationsWidth:0,lineNumbers:"",lineNumbersMinChars:0,minimap:{enabled:!1},readOnly:!0,renderLineHighlight:"none",scrollBeyondLastLine:!1,value:"",wordWrap:"on"}),this.editor.addCommand(l.a.Escape,(()=>{})),this.editor.addCommand(l.b.Shift|l.a.Escape,(()=>{})),this.editor.addCommand(l.a.Escape,(()=>{this.editor.setPosition(this.editor.getPosition())}),"findWidgetVisible && editorTextFocus"),this.editor.addCommand(l.b.Shift|l.a.Escape,(()=>{this.editor.setPosition(this.editor.getPosition())}),"findWidgetVisible && editorTextFocus")}destroyMonaco(){this.editor&&(this.editor.dispose(),this.editor=null)}triggerFindWidget(){this.editor.focus(),this.editor.trigger("keyboard","actions.find")}toggleAll(){for(var{shownLogLevels:e}=this.state,t=!0,n=0;n<ab.AllLogLevels.length;n+=1){if(!e[ab.AllLogLevels[n]]){t=!1;break}}if(t)this.setState({shownLogLevels:{}});else{for(var i={},a=0;a<ab.AllLogLevels.length;a+=1){i[ab.AllLogLevels[a]]=!0}this.setState({shownLogLevels:i})}}toggleLogLevel(e){var{shownLogLevels:t}=this.state,n=t[e],i={};i[e]=!n,this.updateLogLevels(i)}updateLogLevels(e){var{shownLogLevels:t}=this.state;t=nb(nb({},t),e),this.setState({shownLogLevels:t})}appendLogText(e){if(this.editor){var t=this.editor.getModel(),n=t.getLineCount(),i=t.getLineLength(n),a=this.isBottomVisible(),s=[];i>0&&(s.push({range:{startLineNumber:n,startColumn:i+1,endLineNumber:n,endColumn:i+1},text:"\n",forceMoveMarkers:!0}),n+=1,i=0),s.push({range:{startLineNumber:n,startColumn:i,endLineNumber:n,endColumn:i},text:e,forceMoveMarkers:!0}),t.applyEdits(s),a&&this.editor.revealLine(t.getLineCount(),1)}}refreshLogText(){if(this.editor){this.truncateLogIfNecessary();for(var{shownLogLevels:e}=this.state,t=this.isBottomVisible(),n="",i=0;i<this.messages.length;i+=1){var a=this.messages[i];if(e[a.logLevel]){var s=ab.getLogText(a);s.length>0&&(n+=s,"\n"!==s.charAt(s.length-1)&&(n+="\n"))}}if(n=n.trimRight(),this.editor.setValue(n),t){var r=this.editor.getModel().getLineCount();this.editor.revealLine(r,1)}this.stopFlushTimer(),this.bufferedMessages=[]}}truncateLogIfNecessary(){this.messages.length>ab.maxLogSize&&(this.messages=this.messages.splice(this.messages.length-ab.truncateSize))}scrollToBottom(){if(this.editor){var e=this.editor.getModel().getLineCount();this.editor.revealLine(e,1)}}isBottomVisible(){if(!this.editor)return!0;var e=this.editor.getModel().getLineCount();return this.isLineVisible(e)}isLineVisible(e){var t=this.editor.getVisibleRanges();if(null==t||0===t.length)return!1;for(var n=0;n<t.length;n+=1){var i=t[n];if(i.startLineNumber<=e&&e<=i.endLineNumber)return!0}return!1}isLogItemVisible(e){var{shownLogLevels:t}=this.state;return t[e.logLevel]}flush(){for(var e="",t=0;t<this.bufferedMessages.length;t+=1){var n=this.bufferedMessages[t],i=ab.getLogText(n);e+=i,"\n"!==i.charAt(i.length-1)&&(e+="\n")}this.bufferedMessages=[],this.appendLogText(e)}queue(e){this.bufferedMessages.push(e),1===this.bufferedMessages.length&&(this.flushTimer=setTimeout(this.handleFlushTimeout,ab.bufferTimeout))}stopFlushTimer(){this.flushTimer&&(clearTimeout(this.flushTimer),this.flushTimer=null)}updateDimensions(){this.editor&&this.editor.layout()}handleClearClick(){this.clearLogs()}clearLogs(){this.messages=[],this.refreshLogText()}handleFlushTimeout(){this.stopFlushTimer(),this.flush()}handleLogMessage(e){this.messages.push(e),this.editor&&this.isLogItemVisible(e)&&this.queue(e)}handleMenuItemClick(e){this.toggleLogLevel(e)}handleResetClick(){this.resetLogLevels()}handleResize(){this.updateDimensions()}handleToggleAllClick(){this.toggleAll()}render(){var{shownLogLevels:e}=this.state,t=this.getMenuActions(e);return a.a.createElement("div",{className:"log-pane h-100 w-100"},a.a.createElement("div",{className:"log-pane-menu"},a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-clear-logs",onClick:this.handleClearClick},a.a.createElement(Ke.a,{icon:Pn}),a.a.createElement(Ol,null,"Clear log")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-overflow"},a.a.createElement(Ke.a,{icon:Et}),a.a.createElement(Ol,null,"Log Settings"),a.a.createElement(nu,{actions:t,popperClassName:"log-level-menu-popper",popperOptions:{placement:"bottom-end"}}))),a.a.createElement("div",{className:"log-pane-editor h-100 w-100",ref:e=>{this.editorContainer=e}}))}}ib(ab,"DefaultLogLevels",[id.STDOUT,id.ERROR,id.FATAL,id.STDERR,id.WARN]),ib(ab,"AllLogLevels",[id.INFO,id.STDOUT,id.ERROR,id.FATAL,id.STDERR,id.WARN,id.DEBUG,id.TRACE]),ib(ab,"bufferTimeout",16),ib(ab,"maxLogSize",131072),ib(ab,"truncateSize",65536),ab.propTypes={session:Ma.IdeSession.isRequired};var sb=ab;n(1304);function rb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ob=p.module("LogPanel");class lb extends i.PureComponent{constructor(e){super(e),this.handleResize=this.handleResize.bind(this),this.handleShow=this.handleShow.bind(this),this.handleHide=this.handleHide.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.isBottomVisible=!0,this.logView=null;var{session:t}=this.props;this.state={session:t}}handleResize(){this.updateDimensions()}handleShow(){this.updateDimensions(),this.logView&&(this.logView.triggerFindWidget(),this.isBottomVisible&&this.logView.scrollToBottom())}handleHide(){this.logView&&(this.isBottomVisible=this.logView.isBottomVisible())}handleSessionOpened(e){ob.debug("Session opened",[e]),this.setState({session:e})}handleSessionClosed(e){ob.debug("Session closed",e)}updateDimensions(){this.logView&&this.logView.updateDimensions()}render(){var{glContainer:e,glEventHub:t}=this.props,{session:n}=this.state;return a.a.createElement(Jl,{componentPanel:this,glContainer:e,glEventHub:t,onResize:this.handleResize,onHide:this.handleHide,onShow:this.handleShow,onSessionOpen:this.handleSessionOpened,onSessionClose:this.handleSessionClosed},!n&&a.a.createElement("div",{className:"log-panel-disconnected-message"},"Waiting for session connection"),n&&a.a.createElement(sb,{session:n,ref:e=>{this.logView=e}}))}}rb(lb,"COMPONENT","LogPanel"),rb(lb,"TITLE","Log"),lb.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,session:Ma.IdeSession},lb.defaultProps={session:null};var cb=Object(o.b)(((e,t)=>{var n;return{session:null===(n=Tc(e,t.localDashboardId))||void 0===n?void 0:n.session}}),null,null,{forwardRef:!0})(lb);class hb extends i.PureComponent{render(){var{isEditing:e,children:t,onDoubleClick:n}=this.props;return a.a.createElement("div",{className:"markdown-editor-container h-100 w-100",onDoubleClick:n},a.a.createElement("div",{className:qe()("text-muted","edit-hint",{viewing:!e})},a.a.createElement("span",null,"double-click to edit ",a.a.createElement(Ke.a,{icon:mt}))),t)}}hb.propTypes={onDoubleClick:pi.a.func.isRequired,children:pi.a.node.isRequired,isEditing:pi.a.bool},hb.defaultProps={isEditing:!1};var db=p.module("MarkdownStartPage");class ub extends i.PureComponent{constructor(e){super(e),this.handleDeleteButtonClick=this.handleDeleteButtonClick.bind(this),this.handleDeleteModalClose=this.handleDeleteModalClose.bind(this),this.state={isDeleteModalShown:!1,toBeDeleted:null}}handleDeleteButtonClick(e){this.setState({isDeleteModalShown:!0,toBeDeleted:e})}handleDeleteModalClose(){this.setState({isDeleteModalShown:!1,toBeDeleted:null})}handleDeleteMarkdown(e){db.debug("delete markdown: ",e);var{onDelete:t}=this.props;t(e),this.setState({isDeleteModalShown:!1,toBeDeleted:null})}render(){var{closedMarkdowns:e,onOpen:t,onCreate:n}=this.props,{isDeleteModalShown:i,toBeDeleted:s}=this.state;return a.a.createElement("div",{className:"markdown-panel-start-page h-100 w-100"},a.a.createElement("div",{className:"markdown-panel-start-page-container"},a.a.createElement("div",{className:"markdown-panel-start-list"},a.a.createElement("h3",{className:"list-title"},"Start"),a.a.createElement("div",{className:"list-item"},a.a.createElement("button",{className:"btn btn-link title",type:"button",onClick:n},"New Markdown Note"))),a.a.createElement("div",{className:"markdown-panel-start-list"},a.a.createElement("h3",{className:"list-title"},"Recently Closed from Dashboard"),e.map((e=>a.a.createElement("div",{className:"list-item",key:e.id},a.a.createElement("button",{className:"btn btn-link title",type:"button",onClick:()=>t(e)},e.title),a.a.createElement("button",{className:"btn-link icon",type:"button",onClick:()=>{this.handleDeleteButtonClick(e)}},a.a.createElement(Ke.a,{icon:$t}))))),a.a.createElement(sm.a,{isOpen:i,toggle:this.handleDeleteModalClose,className:"modal-dialog-centered markdown-delete-modal theme-bg-light"},a.a.createElement(rm.a,null,"Are you sure you want to permanently delete this note?"),a.a.createElement(om.a,null,"You can't undo this action."),a.a.createElement(lm.a,null,a.a.createElement("button",{className:"btn btn-outline-primary",onClick:this.handleDeleteModalClose,type:"button"},"Cancel"),a.a.createElement("button",{className:"btn btn-danger",onClick:()=>{this.handleDeleteMarkdown(s)},type:"button"},"Delete"))))))}}ub.propTypes={closedMarkdowns:pi.a.arrayOf(pi.a.shape({title:pi.a.string,content:pi.a.string})),onOpen:pi.a.func,onCreate:pi.a.func,onDelete:pi.a.func},ub.defaultProps={closedMarkdowns:[],onOpen:()=>{},onCreate:()=>{},onDelete:()=>{}};var mb=ub,pb=n(729),gb=n.n(pb);function vb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function fb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class bb extends i.Component{constructor(e){super(e),this.handleResize=this.handleResize.bind(this),this.container=null,this.editor=null,this.state={}}componentDidMount(){this.initEditor(),window.addEventListener("resize",this.handleResize)}componentWillUnmount(){window.removeEventListener("resize",this.handleResize),this.destroyEditor()}setLanguage(e){this.editor&&l.c.setModelLanguage(this.editor.getModel(),e)}handleResize(){this.updateDimensions()}toggleFind(){this.editor&&(this.editor.focus(),this.editor.trigger("toggleFind","actions.find"))}updateDimensions(){this.editor.layout()}initEditor(){var{onEditorInitialized:e}=this.props,{settings:t}=this.props;t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vb(Object(n),!0).forEach((function(t){fb(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({copyWithSyntaxHighlighting:"false",fixedOverflowWidgets:!0,folding:!1,fontFamily:"Fira Mono",glyphMargin:!1,language:"python",lineNumbersMinChars:3,minimap:{enabled:!1},scrollBeyondLastLine:!1,tabCompletion:"on",value:"",wordWrap:"off"},t),this.editor=l.c.create(this.container,t),this.editor.addAction({id:"find",label:"Find",keybindings:[l.b.CtrlCmd|l.a.KEY_F],precondition:null,keybindingContext:null,contextMenuGroupId:"navigation",contextMenuOrder:1,run:()=>(this.toggleFind(),null)}),this.editor.layout(),I.removeConflictingKeybindings(this.editor),e(this.editor)}destroyEditor(){var{onEditorWillDestroy:e}=this.props;e(this.editor),this.editor.dispose(),this.editor=null}render(){var{className:e}=this.props;return a.a.createElement("div",{className:qe()("editor-container",e),ref:e=>{this.container=e}})}}bb.propTypes={className:pi.a.string,onEditorInitialized:pi.a.func,onEditorWillDestroy:pi.a.func,settings:pi.a.shape({})},bb.defaultProps={className:"fill-parent-absolute",onEditorInitialized:()=>{},onEditorWillDestroy:()=>{},settings:{}};var Cb=bb;class Sb extends i.PureComponent{constructor(e){super(e),function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"renderMarkdown",(e=>{var{children:t,className:n}=e,i=null!==n&&void 0!==n&&n.startsWith("language-")?n.substring(9):"plaintext";return a.a.createElement("pre",null,a.a.createElement("code",null,a.a.createElement(ah,{language:i},a.a.Children.map(t,(e=>"string"===typeof e?e.trim():e)))))})),this.container=null}render(){var{isEditing:e,content:t,onEditorInitialized:n}=this.props;return a.a.createElement("div",{className:"markdown-editor-container",ref:e=>{this.container=e}},e?a.a.createElement(Cb,{settings:{language:"markdown",value:t,lineNumbers:"off"},onEditorInitialized:n}):a.a.createElement(gb.a,{components:{code:this.renderMarkdown}},t))}}Sb.propTypes={isEditing:pi.a.bool,content:pi.a.string,onEditorInitialized:pi.a.func.isRequired},Sb.defaultProps={isEditing:!1,content:""};n(1408);function Eb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wb=p.module("MarkdownPanel");class yb extends i.Component{constructor(e){super(e),Eb(this,"getClosedMarkdowns",Object(ua.a)((e=>e.filter((e=>"MarkdownPanel"===e.component)).reverse()))),this.handleContainerDoubleClick=this.handleContainerDoubleClick.bind(this),this.handleCreateMarkdown=this.handleCreateMarkdown.bind(this),this.handleDeleteMarkdown=this.handleDeleteMarkdown.bind(this),this.handleOpenMarkdown=this.handleOpenMarkdown.bind(this),this.handleEditorInitialized=this.handleEditorInitialized.bind(this),this.handleEditorBlur=this.handleEditorBlur.bind(this),this.handleEditorResize=this.handleEditorResize.bind(this);var{panelState:t}=e,n=null;t&&t.content&&({content:n}=t),this.state={isStartPageShown:null==n,isEditing:!1,content:n,panelState:t},this.markdownEditor=null,this.editor=null}setEditorPosition(e){var{container:t}=this.markdownEditor;if(this.editor&&t){var n=t.getBoundingClientRect().top,i=t.scrollTop,a=t.scrollHeight,s=this.editor.getModel().getLineCount(),r=Math.round((i+e-n)/a*s);r>s&&(r=s),this.editor.revealLine(r),this.editor.setPosition({lineNumber:r,column:1}),this.editor.focus()}}handleContainerDoubleClick(e){var{isEditing:t}=this.state,n=e.clientY;t||this.setState({isEditing:!0},(()=>{this.setEditorPosition(n)}))}handleEditorInitialized(e){wb.debug("Markdown Editor Initialized..."),this.editor=e}handleCreateMarkdown(){wb.debug("create markdown..."),this.setState({isStartPageShown:!1,content:"",isEditing:!0,panelState:{content:""}},(()=>{this.editor&&this.editor.focus&&this.editor.focus()}))}handleOpenMarkdown(e){wb.debug("open markdown...",e);var{glContainer:t,glEventHub:n}=this.props,i=di.getComponentConfigFromContainer(t);n.emit(fi.REOPEN,e,i)}handleDeleteMarkdown(e){var{glEventHub:t}=this.props;t.emit(fi.DELETE,e)}handleEditorBlur(e){var t,n;wb.debug("markdown content changed, saving...");var{isEditing:i}=this.state;if(i&&(null===(t=this.markdownEditor)||void 0===t||null===(n=t.container)||void 0===n||!n.contains(e.relatedTarget))){var a=this.editor.getValue();this.setState({content:a,isEditing:!1,panelState:{content:a}})}}handleEditorResize(){var{isEditing:e}=this.state;e&&this.editor&&this.editor.layout()}render(){var{glContainer:e,glEventHub:t,closedPanels:n}=this.props,{isEditing:i,isStartPageShown:s,content:r}=this.state,o=this.getClosedMarkdowns(n);return a.a.createElement(Jl,{glContainer:e,glEventHub:t,className:"markdown-panel",componentPanel:this,onResize:this.handleEditorResize,onBlur:this.handleEditorBlur,isClonable:!0,isRenamable:!0},s?a.a.createElement(mb,{closedMarkdowns:o,onCreate:this.handleCreateMarkdown,onOpen:this.handleOpenMarkdown,onDelete:this.handleDeleteMarkdown}):a.a.createElement(hb,{isEditing:i,onDoubleClick:this.handleContainerDoubleClick},a.a.createElement(Sb,{ref:e=>{this.markdownEditor=e},isEditing:i,content:r,onEditorInitialized:this.handleEditorInitialized})))}}Eb(yb,"COMPONENT","MarkdownPanel"),yb.propTypes={glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,panelState:pi.a.shape({content:pi.a.string}),closedPanels:pi.a.arrayOf(pi.a.object).isRequired},yb.defaultProps={panelState:null};var Tb=Object(o.b)(((e,t)=>{var{localDashboardId:n}=t;return{closedPanels:Gi(e,n)}}),null,null,{forwardRef:!0})(yb),Ob={groovy:"Groovy",python:"Python",scala:"Scala"};var Mb=class{static normalizeScriptLanguage(e){return Ob[e]||null}static getDisabledRunTooltip(e,t,n,i){return e?t?null:"".concat(n," doesn't match the session language \u2013 ").concat(i," disabled"):"Console session not connected \u2013 ".concat(i," disabled")}},Nb=(n(1410),p.module("ScriptEditor"));class Db extends i.Component{constructor(e){super(e),this.handleEditorInitialized=this.handleEditorInitialized.bind(this),this.handleEditorWillDestroy=this.handleEditorWillDestroy.bind(this),this.handleRun=this.handleRun.bind(this),this.handleRunSelected=this.handleRunSelected.bind(this),this.contextActionCleanups=[],this.completionCleanup=null,this.editor=null,this.editorComponent=a.a.createRef(),this.state={model:null}}componentDidUpdate(e){var{sessionLanguage:t,settings:n}=this.props,{language:i}=n;i!==e.settings.language&&(Nb.debug("Set language",i),this.setLanguage(i));var a=null==t&&null!=e.sessionLanguage,s=i===t,r=e.settings.language===e.sessionLanguage;(a||t&&r&&!s)&&(Nb.debug("De-init completion and context actions"),this.deInitContextActions(),this.deInitCodeCompletion()),(null!=t&&null==e.sessionLanguage&&s||t&&!r&&s)&&(Nb.debug("Init completion and context actions"),this.initContextActions(),this.initCodeCompletion())}getValue(){return this.editor?this.editor.getValue():(Nb.error("Editor not initialized"),null)}getSelectedCommand(){var e=this.editor.getSelection(),t=this.editor.getModel(),{startLineNumber:n,endLineNumber:i}=e,a=t.getLineMinColumn(n),s=t.getLineMaxColumn(i),r=e.setStartPosition(n,a).setEndPosition(i,s);return t.getValueInRange(r)}handleEditorInitialized(e){var{focusOnMount:t,onChange:n,settings:i,session:a,sessionLanguage:s}=this.props;Nb.debug("handleEditorInitialized",s,a,i),this.editor=e,this.setState({model:this.editor.getModel()}),I.setEOL(e),I.registerPasteHandler(e),a&&i&&s===i.language&&(this.initContextActions(),this.initCodeCompletion()),e.onDidChangeModelContent(n),t&&e.focus()}handleEditorWillDestroy(){Nb.debug("handleEditorWillDestroy"),this.deInitContextActions(),this.deInitCodeCompletion(),this.setState({model:null}),this.editor=null}handleRun(){var{onRunCommand:e}=this.props;e(this.getValue())}handleRunSelected(){var{onRunCommand:e}=this.props;e(this.getSelectedCommand())}initContextActions(){if(this.contextActionCleanups.length>0)Nb.error("Context actions already initialized.");else if(this.editor){var e=[];e.push(this.editor.addAction({id:"run-code",label:"Run",keybindings:[l.b.Alt|l.a.KEY_R],precondition:null,keybindingContext:null,contextMenuGroupId:"navigation",contextMenuOrder:1.5,run:()=>(this.handleRun(),null)})),e.push(this.editor.addAction({id:"run-selected-code",label:"Run Selected",keybindings:[l.b.Alt|l.b.Shift|l.a.KEY_R],precondition:null,keybindingContext:null,contextMenuGroupId:"navigation",contextMenuOrder:1.5,run:()=>(this.handleRunSelected(),null)})),this.contextActionCleanups=e}}deInitContextActions(){this.contextActionCleanups.length>0&&(this.contextActionCleanups.forEach((e=>e.dispose())),this.contextActionCleanups=[])}initCodeCompletion(){if(null==this.completionCleanup){var{session:e}=this.props;Nb.debug("initCodeCompletion",this.editor,e),this.editor&&e&&(this.completionCleanup=I.openDocument(this.editor,e))}else Nb.error("Code completion already initialized.")}deInitCodeCompletion(){var{session:e}=this.props;Nb.debug("deInitCodeCompletion",this.editor,e),this.completionCleanup&&(this.completionCleanup.dispose(),this.completionCleanup=null),this.editor&&e&&I.closeDocument(this.editor,e)}append(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=this.editor.getModel(),i=n.getValue();i?n.setValue("".concat(i,"\n").concat(e)):n.setValue("".concat(e));var a=n.getLineCount(),s=n.getLineLength(a)+1;this.editor.setPosition({lineNumber:a,column:s}),t&&this.editor.focus()}updateDimensions(){Nb.debug("updateDimensions"),this.editor&&this.editor.layout()}focus(){Nb.debug("focus"),this.editor&&this.editor.focus()}toggleFind(){this.editorComponent.current&&this.editorComponent.current.toggleFind()}setLanguage(e){this.editorComponent.current&&this.editorComponent.current.setLanguage(e)}render(){var{error:e,isLoaded:t,isLoading:n,session:i,sessionLanguage:s,settings:r}=this.props,{model:o}=this.state,l=e?"Unable to open document. ".concat(e):null,c=r?r.language:null,h=o&&i&&c===s;return a.a.createElement(a.a.Fragment,null,(e||n)&&a.a.createElement("div",{className:"h-100 w-100 position-relative"},a.a.createElement(Xn,{errorMessage:l,isLoading:n,isLoaded:t})),t&&a.a.createElement("div",{className:"h-100 w-100 script-editor"},r&&a.a.createElement(a.a.Fragment,null,a.a.createElement(Cb,{ref:this.editorComponent,settings:r,onEditorInitialized:this.handleEditorInitialized,onEditorWillDestroy:this.handleEditorWillDestroy}),h&&a.a.createElement(rd,{model:o,language:c,session:i}))))}}Db.propTypes={error:pi.a.shape({message:pi.a.string}),isLoading:pi.a.bool,isLoaded:pi.a.bool,focusOnMount:pi.a.bool,onChange:pi.a.func,onRunCommand:pi.a.func.isRequired,session:pi.a.shape({}),sessionLanguage:pi.a.string,settings:pi.a.shape({language:pi.a.string,value:pi.a.string})},Db.defaultProps={error:null,isLoading:!1,isLoaded:!1,focusOnMount:!0,onChange:()=>{},session:null,sessionLanguage:null,settings:null};var xb=Db,Rb={NOTEBOOK:{name:"Notebook",RUN:Be.createAndAdd({id:"NOTEBOOK.RUN",name:"Run",shortcut:[_e.ALT,He.R],macShortcut:[_e.OPTION,He.R],isEditable:!1}),RUN_SELECTED:Be.createAndAdd({id:"NOTEBOOK.RUN_SELECTED",name:"Run Selected",shortcut:[_e.ALT,_e.SHIFT,He.R],macShortcut:[_e.OPTION,_e.SHIFT,He.R],isEditable:!1}),FIND:Be.createAndAdd({id:"NOTEBOOK.FIND",name:"Find",shortcut:[_e.CTRL,He.F],macShortcut:[_e.CMD,He.F],isEditable:!1})}};n(1409);function Ib(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Lb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ib(Object(n),!0).forEach((function(t){Fb(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ib(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Fb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var kb=p.module("NotebookPanel");class Ab extends i.Component{static handleError(e){Va.isCanceled(e)||kb.error(e)}static languageFromFileName(e){switch(vm.getExtension(e).toLowerCase()){case"py":case"python":return"python";case"groovy":return"groovy";case"scala":return"scala";default:return null}}constructor(e){super(e),Fb(this,"getOverflowActions",Object(ua.a)((()=>[{title:"Find",icon:un,action:this.handleFind,group:vl.groups.high,shortcut:Rb.NOTEBOOK.FIND,order:10}]))),this.handleBlur=this.handleBlur.bind(this),this.handleCloseCancel=this.handleCloseCancel.bind(this),this.handleCloseDiscard=this.handleCloseDiscard.bind(this),this.handleCloseSave=this.handleCloseSave.bind(this),this.handleCopy=this.handleCopy.bind(this),this.handleEditorChange=this.handleEditorChange.bind(this),this.handleFind=this.handleFind.bind(this),this.handleFocus=this.handleFocus.bind(this),this.handleLoadSuccess=this.handleLoadSuccess.bind(this),this.handleLoadError=this.handleLoadError.bind(this),this.handlePanelTabClick=this.handlePanelTabClick.bind(this),this.handleRenameFile=this.handleRenameFile.bind(this),this.handleResize=this.handleResize.bind(this),this.handleRunCommand=this.handleRunCommand.bind(this),this.handleRunAll=this.handleRunAll.bind(this),this.handleRunSelected=this.handleRunSelected.bind(this),this.handleSave=this.handleSave.bind(this),this.handleSaveAsCancel=this.handleSaveAsCancel.bind(this),this.handleSaveAsSubmit=this.handleSaveAsSubmit.bind(this),this.handleSaveError=this.handleSaveError.bind(this),this.handleSaveSuccess=this.handleSaveSuccess.bind(this),this.handleSessionOpened=this.handleSessionOpened.bind(this),this.handleSessionClosed=this.handleSessionClosed.bind(this),this.handleShow=this.handleShow.bind(this),this.handleShowRename=this.handleShowRename.bind(this),this.handleTab=this.handleTab.bind(this),this.handleTabFocus=this.handleTabFocus.bind(this),this.handleTabBlur=this.handleTabBlur.bind(this),this.pending=new Ua,this.debouncedSavePanelState=pa()(this.savePanelState.bind(this),400),this.debouncedLoad=pa()(this.load.bind(this),400),this.notebook=null,this.tabTitleElement=null,this.unsavedIndicator=null,this.tabInitOnce=!1,this.shouldPromptClose=!0;var{isDashboardActive:t,session:n,sessionLanguage:i,panelState:a}=e,s={value:""},r=null,{isPreview:o}=e;a&&({fileMetadata:r=r,isPreview:o=o,settings:s=s}=a);var l=r.itemName&&vm.hasPath(r.itemName),c=l&&null!=s.value||!l&&s.value?1:0;this.state={error:null,isDashboardActive:t,isFocused:!1,isLoading:!0,isLoaded:!1,isPreview:o,savedChangeCount:0,changeCount:c,fileMetadata:r,settings:s,session:n,sessionLanguage:i,panelState:{fileMetadata:r,settings:s},showCloseModal:!1,showSaveAsModal:!1,scriptCode:""},kb.debug("constructor",e,this.state)}componentDidMount(){var{glContainer:e,glEventHub:t}=this.props,{tab:n}=e;n&&this.initTab(n),this.initNotebookContent(),t.on(zl.RENAME_FILE,this.handleRenameFile),e.on("tabClicked",this.handlePanelTabClick)}componentDidUpdate(e,t){var{isPreview:n}=this.state;n!==t.isPreview&&this.setPreviewStatus(n)}componentWillUnmount(){this.debouncedSavePanelState.flush(),this.pending.cancel();var{glContainer:e,glEventHub:t}=this.props,{fileMetadata:n,isPreview:i}=this.state;t.off(zl.RENAME_FILE,this.handleRenameFile),e.off("tabClicked",this.handlePanelTabClick),t.emit(zl.UNREGISTER_FILE,n,i)}initTab(e){this.tabInitOnce||(this.tabInitOnce=!0,this.initTabCloseOverride()),this.initTabClasses(e)}initTabCloseOverride(){var{glContainer:e}=this.props,t=e.close.bind(e);e.close=()=>{var{changeCount:e,savedChangeCount:n}=this.state;e!==n&&this.shouldPromptClose?this.setState({showCloseModal:!0}):t()}}initTabClasses(e){var t=e.element.get(0).querySelector(".lm_title");this.tabTitleElement=t,t.classList.add("notebook-title"),this.setPreviewStatus()}getNotebookValue(){var{changeCount:e,savedChangeCount:t,settings:n}=this.state,{value:i}=n;if(e!==t&&this.notebook){var a=this.notebook.getValue();return null!=a?a:i}return i}initNotebookContent(){var{fileMetadata:e,settings:t,isPreview:n}=this.state;return e&&e.id?(kb.debug("Init content from file"),this.registerFileMetadata(e,n),void this.load()):null!=t.value?(kb.debug("Use content passed in the settings prop"),void this.handleLoadSuccess()):void this.handleLoadError(new Error("Missing file metadata"))}closeFileTabById(e){var{glEventHub:t}=this.props;t.emit(zl.CLOSE_FILE,{id:e})}registerFileMetadata(e,t){var{glEventHub:n,metadata:i}=this.props,{id:a}=i;n.emit(zl.REGISTER_FILE,a,e,t)}renameTab(e,t){var{glEventHub:n}=this.props;n.emit(zl.RENAME,e,t)}load(){var{fileMetadata:e,settings:t}=this.state,{id:n}=e,{fileStorage:i}=this.props;this.pending.add(i.loadFile(n)).then((e=>{kb.debug("Loaded file",e);var{filename:n}=e,{itemName:i}=this.state;if(n!==i){var{metadata:a}=this.props,{id:s}=a;this.renameTab(s,vm.getBaseName(n))}var r=Lb(Lb({},t),{},{language:Ab.languageFromFileName(n)});null==t.value&&(r.value=e.content),this.setState({fileMetadata:{id:n,itemName:n},settings:r}),this.debouncedSavePanelState()})).then(this.handleLoadSuccess).catch(this.handleLoadError)}save(){var{fileMetadata:e}=this.state;if(e&&vm.hasPath(e.itemName)){var t=this.getNotebookValue();return this.saveContent(e.itemName,t),!0}return this.setState({showSaveAsModal:!0}),!1}saveContent(e,t){kb.debug("saveContent",e,t),this.updateSavedChangeCount();var{fileStorage:n}=this.props;this.pending.add(n.saveFile({filename:e,content:t})).then(this.handleSaveSuccess).catch(this.handleSaveError)}updateSavedChangeCount(){this.setState((e=>{var{changeCount:t}=e;return{savedChangeCount:t}}))}setPreviewStatus(){if(this.tabTitleElement){var{isPreview:e}=this.state;kb.debug("setPreviewStatus",this.tabTitleElement,e),e?this.tabTitleElement.classList.add("is-preview"):this.tabTitleElement.classList.remove("is-preview")}}savePanelState(){this.setState((e=>{var{changeCount:t,savedChangeCount:n,fileMetadata:i,isPreview:a,settings:s}=e,r=this.getNotebookValue(),o=t!==n?r:null,l=Lb(Lb({},s),{},{value:r}),c={settings:Lb(Lb({},s),{},{value:o}),fileMetadata:i,isPreview:a};return kb.debug("Saving panel state",c),{settings:l,panelState:c}}))}handleCloseDiscard(){this.shouldPromptClose=!1,this.setState({showCloseModal:!1});var{glContainer:e}=this.props;e.close()}handleCloseSave(){if(this.shouldPromptClose=!1,this.setState({showCloseModal:!1}),this.save()){var{glContainer:e}=this.props;e.close()}}handleCloseCancel(){this.shouldPromptClose=!0,this.setState({showCloseModal:!1})}handleCopy(){var{fileMetadata:e,settings:t}=this.state,n=this.getNotebookValue(),{language:i}=t,{itemName:a}=e,s=vm.getCopyFileName(a);kb.debug("handleCopy",e,a,s),this.createNotebook(s,i,n)}handleEditorChange(e){kb.debug2("handleEditorChanged",e),this.setState((e=>{var{isPreview:t}=e;if(t){var{fileMetadata:n}=this.state;return this.registerFileMetadata(n,!1),{isPreview:!1}}return null})),this.setState((t=>{var{changeCount:n,savedChangeCount:i}=t,{isUndoing:a,isRedoing:s}=e;return a?{changeCount:n-1}:!s&&n<i?{changeCount:n+1,savedChangeCount:0}:{changeCount:n+1}})),this.debouncedSavePanelState()}handleFind(){this.notebook&&this.notebook.toggleFind()}handleBlur(){kb.debug("handleBlur"),this.setState({isFocused:!1})}handleFocus(){kb.debug("handleFocus"),this.setState({isFocused:!0})}handleLoadSuccess(){this.setState({error:null,isLoaded:!0,isLoading:!1})}handleLoadError(e){var t=e;Va.isCanceled(t)||(Va.isTimedOut(t)&&(t=new Error("File not found.")),kb.error(t),this.setState({error:t,isLoading:!1}))}handleSave(){kb.debug("handleSave"),this.save()}handleSaveSuccess(e){var{fileStorage:t}=this.props,n={id:e.filename,itemName:e.filename},i=Ab.languageFromFileName(e.filename);this.setState((e=>{var{fileMetadata:a}=e,s=Lb(Lb({},e.settings),{},{language:i});return kb.debug("handleSaveSuccess",n,a,s),vm.hasPath(a.itemName)&&a.itemName!==n.itemName&&(kb.debug("handleSaveSuccess deleting old file",a.itemName),t.deleteFile(a.itemName).catch(Ab.handleError)),{fileMetadata:n,settings:s,isPreview:!1}})),this.debouncedSavePanelState(),this.registerFileMetadata(n,!1)}handleSaveError(e){Va.isCanceled(e)||(this.setState({savedChangeCount:0}),kb.error(e))}handleSaveAsCancel(){this.setState({showSaveAsModal:!1})}handleSaveAsSubmit(e){kb.debug("handleSaveAsSubmit",e);var{fileMetadata:t}=this.state,{itemName:n}=t,i=this.getNotebookValue();if(this.setState({showSaveAsModal:!1}),vm.getBaseName(n)!==vm.getBaseName(e)){var{metadata:a}=this.props,{id:s}=a;this.renameTab(s,vm.getBaseName(e))}this.saveContent(e,i)}handleRenameFile(e,t){var{fileMetadata:n}=this.state;n.id===e&&(this.setState({fileMetadata:{id:t,itemName:t}}),this.debouncedSavePanelState())}handleResize(){this.notebook&&this.notebook.updateDimensions()}handleRunCommand(e){this.runCommand(e)}handleRunAll(){this.notebook?this.runCommand(this.notebook.getValue()):kb.error("Editor is not initialized.")}handleRunSelected(){this.notebook?this.runCommand(this.notebook.getSelectedCommand()):kb.error("Editor is not initialized.")}handleSessionOpened(e,t){var{language:n}=t;this.setState({session:e,sessionLanguage:n})}handleSessionClosed(){this.setState({session:null,sessionLanguage:null})}handleShow(){kb.debug("handleShow"),this.notebook&&this.notebook.updateDimensions()}handleShowRename(){this.setState({showSaveAsModal:!0})}handleTab(e){kb.debug("NotebookPanel tab event",e),this.initTab(e)}handleTabFocus(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];kb.debug("handleTabFocus",...t);var{glContainer:i}=this.props;this.setState({isDashboardActive:!0}),this.notebook&&!i.isHidden&&this.notebook.updateDimensions()}handleTabBlur(){kb.debug("handleTabBlur"),this.setState({isDashboardActive:!1})}handlePanelTabClick(){kb.debug("handlePanelTabClick"),this.focus()}focus(){requestAnimationFrame((()=>{this.notebook&&this.notebook.focus()}))}createNotebook(e,t,n){var{glEventHub:i}=this.props,{session:a,sessionLanguage:s,settings:r}=this.state,o=Lb(Lb({},r),{},{language:t,value:n}),l={id:null,itemName:e};kb.debug("handleCreateNotebook",a,s,o,l),i.emit(zl.CREATE_NOTEBOOK,a,s,o,l)}runCommand(e){if(e){var{glEventHub:t}=this.props;t.emit(Il.SEND_COMMAND,e,!1,!0)}else kb.debug("Ignoring empty command.")}render(){var e,{fileStorage:t,glContainer:n,glContainer:{tab:i},glEventHub:s}=this.props,{changeCount:o,savedChangeCount:l,error:c,isDashboardActive:h,isLoaded:d,isLoading:u,isPreview:m,fileMetadata:p,session:g,sessionLanguage:v,settings:f,showCloseModal:b,showSaveAsModal:C}=this.state,S=h&&!n.isHidden&&!m,E=null!==(e=null===p||void 0===p?void 0:p.itemName)&&void 0!==e?e:Ab.DEFAULT_NAME,w=null!=(null===p||void 0===p?void 0:p.id),y=this.getOverflowActions(),T=Lb({},f),O=null!=g,M=v===T.language,N=!d||!O||!M,D=!d,x=[{action:this.handleSave,shortcut:Uc.SAVE}],R=Mb.getDisabledRunTooltip(O,M,"Notebook extension","Run"),I=Mb.getDisabledRunTooltip(O,M,"Notebook extension","Run Selected"),L=[{title:w?"Rename":"Save As\u2026",order:10,group:vl.groups.high,action:this.handleShowRename},{title:"Copy File",action:this.handleCopy,group:vl.groups.high,order:20}];return a.a.createElement(a.a.Fragment,null,i&&r.a.createPortal(a.a.createElement("span",{className:qe()("editor-unsaved-indicator",{"is-unsaved":o!==l})}),i.element.find(".lm_title_before").get(0)),a.a.createElement(Jl,{className:"notebook-container",componentPanel:this,glContainer:n,glEventHub:s,onTab:this.handleTab,onResize:this.handleResize,onShow:this.handleShow,onTabFocus:this.handleTabFocus,onTabBlur:this.handleTabBlur,onSessionOpen:this.handleSessionOpened,onSessionClose:this.handleSessionClosed,onFocus:this.handleFocus,onBlur:this.handleBlur,additionalActions:L,renderTabTooltip:()=>E},a.a.createElement("div",{className:"notebook-toolbar"},a.a.createElement("span",null,a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-play",onClick:this.handleRunAll,disabled:N},a.a.createElement(Ke.a,{icon:Wt,transform:"grow-4"}),a.a.createElement(Ol,null,"Run ",Rb.NOTEBOOK.RUN.getDisplayText())),R&&a.a.createElement(Ol,null,R)),a.a.createElement("span",null,a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon btn-play",onClick:this.handleRunSelected,disabled:N},a.a.createElement(Ke.a,{icon:_t,transform:"grow-4"}),a.a.createElement(Ol,null,"Run Selected"," ",Rb.NOTEBOOK.RUN_SELECTED.getDisplayText())),I&&a.a.createElement(Ol,null,I)),a.a.createElement("button",{type:"button",className:"btn btn-link btn-link-icon mr-auto",disabled:D,onClick:this.handleSave},a.a.createElement(Ke.a,{icon:Gt}),a.a.createElement(Ol,null,"Save")),a.a.createElement("button",{type:"button",className:"btn btn-link btn-overflow btn-link-icon",disabled:D},a.a.createElement(Ke.a,{icon:Ot}),a.a.createElement(Ol,null,"More Actions..."),a.a.createElement(nu,{actions:y,popperOptions:Ab.POPPER_OPTIONS}))),a.a.createElement(xb,{isLoaded:d,isLoading:u,error:c,onChange:this.handleEditorChange,onRunCommand:this.handleRunCommand,session:g,sessionLanguage:v,settings:T,focusOnMount:S,ref:e=>{this.notebook=e}}),a.a.createElement(Ym,{isOpen:C,type:"file",defaultValue:E,title:w?"Rename":"Save file as",onSubmit:this.handleSaveAsSubmit,onCancel:this.handleSaveAsCancel,notifyOnExtensionChange:!0,storage:t}),a.a.createElement(um,{isOpen:b,headerText:"Do you want to save the changes you made to ".concat(E,"?"),bodyText:"Your changes will be lost if you don't save them.",onCancel:this.handleCloseCancel,onDiscard:this.handleCloseDiscard,onConfirm:this.handleCloseSave,discardButtonText:"Discard Changes",confirmButtonText:"Save"}),a.a.createElement(vl,{actions:x})))}}Fb(Ab,"COMPONENT","NotebookPanel"),Fb(Ab,"POPPER_OPTIONS",{placement:"bottom-end"}),Fb(Ab,"DEFAULT_NAME","Untitled"),Ab.propTypes={fileStorage:pi.a.shape({deleteFile:pi.a.func.isRequired,loadFile:pi.a.func.isRequired,saveFile:pi.a.func.isRequired}).isRequired,glContainer:Ni.Container.isRequired,glEventHub:Ni.EventHub.isRequired,isDashboardActive:pi.a.bool,isPreview:pi.a.bool,metadata:pi.a.shape({id:pi.a.string.isRequired}).isRequired,session:pi.a.shape({}),sessionLanguage:pi.a.string,panelState:pi.a.shape({settings:pi.a.shape({}),fileMetadata:pi.a.shape({})}).isRequired},Ab.defaultProps={isDashboardActive:!0,isPreview:!1,session:null,sessionLanguage:null};var Pb=Object(o.b)(((e,t)=>{var n=A(e),i=Tc(e,t.localDashboardId),{session:a,config:s}=null!==i&&void 0!==i?i:{},{type:r}=null!==s&&void 0!==s?s:{};return{fileStorage:n,session:a,sessionLanguage:r}}),null,null,{forwardRef:!0})(Ab);n(1411);function _b(){return _b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},_b.apply(this,arguments)}class Hb extends i.Component{constructor(e){super(e),this.irisGridRef=a.a.createRef(),this.buttonRef=a.a.createRef(),this.handleReload=this.handleReload.bind(this),this.handleGridStateChange=this.handleGridStateChange.bind(this),this.handlePanelStateUpdate=this.handlePanelStateUpdate.bind(this);var{panelState:t}=e;this.state={shouldFocusGrid:!1,panelState:t}}handleReload(){this.irisGridRef.current.initModel(),this.buttonRef.current.blur(),this.setState({shouldFocusGrid:!0})}handleGridStateChange(){var e,t,n,{shouldFocusGrid:i}=this.state;i&&null!==(e=this.irisGridRef.current)&&void 0!==e&&null!==(t=e.irisGrid)&&void 0!==t&&null!==(n=t.current)&&void 0!==n&&n.grid&&(this.irisGridRef.current.irisGrid.current.grid.focus(),this.setState({shouldFocusGrid:!1}))}handlePanelStateUpdate(e){this.setState({panelState:e})}render(){var e=_b({},this.props);return a.a.createElement(Bf,_b({ref:this.irisGridRef,onStateChange:this.handleGridStateChange,onPanelStateUpdate:this.handlePanelStateUpdate},e),a.a.createElement("button",{ref:this.buttonRef,type:"button",className:"btn btn-primary btn-pandas",onClick:this.handleReload},"pandas dataframe",a.a.createElement("span",null,a.a.createElement(Ke.a,{icon:On,transform:"shrink-1",className:"mr-1"}),"Reload"),a.a.createElement(Ol,null,"Click to refresh pandas dataframe, updates do not occur automatically.")))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(Hb,"COMPONENT","PandasPanel"),Hb.propTypes={panelState:pi.a.shape({})},Hb.defaultProps={panelState:null};var jb=Hb,Vb=e=>{var{id:t,layout:n,registerComponent:s,hydrate:r=_i.hydrate}=e,o=Object(i.useCallback)((function(e,i){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:ni.a.generate(),r=arguments.length>4?arguments[4]:void 0,o={type:"react-component",component:Vc.COMPONENT,props:{localDashboardId:t,id:s,metadata:a,makeModel:i},title:e,id:s},{root:l}=n;di.openComponent({root:l,config:o,dragEvent:r})}),[t,n]),l=Object(i.useCallback)((e=>{var t={component:Vc.COMPONENT,id:e},{root:i}=n;di.closeComponent(i,t)}),[n]);return Object(i.useEffect)((()=>{var e=[s(Vc.COMPONENT,Vc,r)];return()=>{e.forEach((e=>e()))}}),[r,s]),Di(n.eventHub,Dl.OPEN,o),Di(n.eventHub,Dl.CLOSE,l),a.a.createElement(a.a.Fragment,null)},zb=p.module("ConsolePlugin");function Ub(e){return void 0!==e.notebook}var Bb=e=>{var{id:t,layout:n,panelManager:s,registerComponent:r}=e,l=Object(i.useRef)(0),[c]=Object(i.useState)(new Map),[h]=Object(i.useState)(new Map),d=Object(o.c)(),u=Object(i.useCallback)((()=>s.getLastUsedPanelOfType(Xu)),[s]),m=Object(i.useCallback)((function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=e&&e.trim();if(i){var a=u();if(!a||!(a instanceof Xu.WrappedComponent))return void zb.error("Console panel not found");zb.debug("Send command: ",e,t,n),a.addCommand(e,t,n)}else zb.info("Ignoring empty code")}),[u]),p=Object(i.useCallback)((e=>{d(((e,t)=>n=>n($i(e,{consoleSettings:t})))(t,e))}),[d,t]),g=Object(i.useCallback)((e=>{var{language:t}=e,n="python"===t?"py":t,i=null;return n?i="Untitled-".concat(l.current,".").concat(n):(zb.debug("No extension for language",t),i="Untitled-".concat(l.current)),l.current+=1,i}),[]),v=Object(i.useCallback)((function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],{id:n}=e;return n&&c.has(n)?c.get(n):n&&h.has(n)?h.get(n):t?ni.a.generate():null}),[c,h]),f=Object(i.useCallback)(((e,t)=>{di.renameComponent(n.root,{id:e},t)}),[n.root]),b=Object(i.useCallback)(((e,t)=>{var n;zb.debug("Rename file panel",e,t),c.has(e)&&(n=c.get(e),c.delete(e),null!=n&&c.set(t,n)),h.has(e)&&(n=h.get(e),h.delete(e),null!=n&&h.set(t,n)),n?f(n,vm.getBaseName(t)):zb.debug2("File ".concat(e," isn't open, no need to rename the tab"))}),[c,h,f]),C=Object(i.useCallback)((e=>{var t=v(e,!1);null!=t?di.activateTab(n.root,{id:t}):zb.error("Could not find panel id for file metadata",e)}),[v,n.root]),S=Object(i.useCallback)(((e,t,n)=>{if(zb.debug("registerFilePanel",e,t,n),t&&t.id){var{id:i}=t;if(n)h.set(i,e);else if(c.has(i)){var a=c.get(i);if(e===a){zb.debug("Update tab title for file ".concat(i));var{itemName:s}=t;b(i,vm.getBaseName(s))}else zb.error("File ".concat(i," already associated with a different tab ").concat(a))}else c.set(i,e),h.has(i)&&h.delete(i)}else zb.debug("Ignore empty file id",t)}),[c,h,b]),E=Object(i.useCallback)(((e,t)=>{if(zb.debug("unregisterFileTab",e,t),e&&e.id){var{id:n}=e;t?h.delete(n):c.delete(n)}else zb.debug("Ignore empty file id",e)}),[c,h]),w=Object(i.useCallback)((e=>{zb.debug("closeFilePanel",e);var{id:t}=e,i=null,a=!1;if(c.has(t))i=c.get(t);else{if(!h.has(t))return void zb.debug("File ".concat(t," isn't open, ignore close event"));i=h.get(t),a=!0}E(e,a),di.closeComponent(n.root,{id:i})}),[n.root,c,h,E]),y=Object(i.useCallback)((e=>{var{itemName:t}=e;return vm.getBaseName(t)}),[]),T=Object(i.useCallback)((e=>{var{id:t}=e;return zb.debug("fileIsOpen",e,t,c),t&&c.has(t)}),[c]),O=Object(i.useCallback)((e=>{var{id:t}=e;return zb.debug("fileIsOpenAsPreview",e,t,h),t&&h.has(t)}),[h]),M=Object(i.useCallback)((e=>{if(e){var t=s.getOpenedPanelById(e);t&&Ub(t)&&t.focus()}}),[s]),N=Object(i.useCallback)((e=>{var{id:n,settings:i,fileMetadata:a,session:s,sessionLanguage:r,isPreview:o=!1}=e,l={settings:i,fileMetadata:a},c=y(a);return{type:"react-component",component:Pb.COMPONENT,isFocusOnShow:!1,props:{localDashboardId:t,metadata:{id:n},session:s,sessionLanguage:r,panelState:l,isPreview:o},title:c,id:n}}),[y,t]),D=Object(i.useCallback)((function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{id:null,itemName:g(i)},s=v(a);if(T(a)&&s)return zb.debug("File is already open, focus panel"),C(a),void M(s);var r=di.getStackForComponentTypes(n.root,[Pb.COMPONENT]),o=N({id:s,settings:i,fileMetadata:a,session:e,sessionLanguage:t});zb.debug("createNotebook",o,c),di.openComponentInStack(r,o)}),[T,M,g,v,n.root,N,c,C]),x=Object(i.useCallback)((function(e,t,i,a){var s=arguments.length>4&&void 0!==arguments[4]&&arguments[4];zb.debug("selectNotebook",a,s);var r=T(a),o=O(a);if(r){if(C(a),s){var l=v(a);M(l)}}else if(!o||s){var[c]=Array.from(h.values()),d=null,u=null;null!=c&&(d=c,u=di.getStackForConfig(n.root,{component:Pb.COMPONENT,id:d})),null==u&&(d=v(a),u=di.getStackForComponentTypes(n.root,[Pb.COMPONENT]));var m=N({id:d,settings:i,fileMetadata:a,session:e,sessionLanguage:t,isPreview:!s});di.openComponentInStack(u,m),s&&M(d)}else C(a)}),[C,T,O,M,v,n.root,N,h]),R=Object(i.useCallback)((function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=s.getLastUsedPanelOfType(Pb);a&&Ub(a)?n&&n.value&&a.notebook&&a.notebook.append(n.value):i&&D(e,t,n)}),[D,s]);return Object(i.useEffect)((()=>{var e=[r(Xu.COMPONENT,Xu),r(Rh.COMPONENT,Rh),r(fp.COMPONENT,fp),r(cb.COMPONENT,cb),r(Pb.COMPONENT,Pb)];return()=>{e.forEach((e=>e()))}}),[r]),Di(n.eventHub,Il.SEND_COMMAND,m),Di(n.eventHub,Il.SETTINGS_CHANGED,p),Di(n.eventHub,zl.CLOSE_FILE,w),Di(n.eventHub,zl.CREATE_NOTEBOOK,D),Di(n.eventHub,zl.SELECT_NOTEBOOK,x),Di(n.eventHub,zl.RENAME,f),Di(n.eventHub,zl.RENAME_FILE,b),Di(n.eventHub,zl.SEND_TO_NOTEBOOK,R),Di(n.eventHub,zl.REGISTER_FILE,S),Di(n.eventHub,zl.UNREGISTER_FILE,E),a.a.createElement(a.a.Fragment,null)},Wb=p.module("FilterPlugin");function Gb(e,t){return e.concat(t)}var qb=e=>{var{id:t,layout:n,registerComponent:s}=e,r=Object(o.c)(),[l]=Object(i.useState)((()=>new Map)),[c]=Object(i.useState)((()=>new Map)),[h]=Object(i.useState)((()=>new Map)),d=Object(i.useCallback)((()=>{var e=Array.from(l.values()).reduce(Gb,[]).sort(((e,t)=>{var n=Ga.toLower(e.name),i=Ga.toLower(t.name);if(n!==i)return n>i?1:-1;var a=Ga.toLower(e.type),s=Ga.toLower(t.type);return a!==s?a>s?1:-1:0})).reduce(((e,t)=>(0!==e.length&&Ga.toLower(e[e.length-1].name)===Ga.toLower(t.name)&&Ga.toLower(e[e.length-1].type)===Ga.toLower(t.type)||e.push(t),e)),[]),n=Array.from(c.values()).reduce(Gb,[]).sort(((e,t)=>e.timestamp-t.timestamp)),i=new Map(h);Wb.debug("sendUpdate",{columns:e,filters:n,tableMap:i}),r($i(t,{columns:e,filters:n,tableMap:i}))}),[r,t,l,c,h]),u=Object(i.useCallback)(((e,t)=>{Wb.debug2("handleColumnsChanged",e,t),l.set(e,[].concat(t)),d()}),[l,d]),m=Object(i.useCallback)(((e,t)=>{Wb.debug2("handleFiltersChanged",e,t),c.set(e,[].concat(t)),d()}),[c,d]),p=Object(i.useCallback)(((e,t)=>{Wb.debug2("handleTableChanged",e,t),h.set(di.getIdFromPanel(e),t),d()}),[h,d]),g=Object(i.useCallback)((e=>{Wb.debug2("handlePanelUnmount",e),l.delete(e),c.delete(e),h.delete(di.getIdFromPanel(e)),d()}),[l,c,h,d]),v=Object(i.useCallback)((e=>{var{title:i="DropdownFilter",metadata:a={},panelState:s=null,id:r=ni.a.generate(),focusElement:o=di.DEFAULT_FOCUS_SELECTOR,createNewStack:l=!1,dragEvent:c=null}=e,h={type:"react-component",component:am.COMPONENT,props:{id:r,metadata:a,panelState:s,localDashboardId:t},title:i,id:r},{root:d}=n;di.openComponent({root:d,config:h,focusElement:o,createNewStack:l,dragEvent:c})}),[n,t]),f=Object(i.useCallback)((e=>{var{title:i="InputFilter",metadata:a={},panelState:s=null,id:r=ni.a.generate(),focusElement:o=di.DEFAULT_FOCUS_SELECTOR,createNewStack:l=!1,dragEvent:c=null}=e,h={type:"react-component",component:Xf.COMPONENT,props:{id:r,metadata:a,panelState:s,localDashboardId:t},title:i,id:r},{root:d}=n;di.openComponent({root:d,config:h,focusElement:o,createNewStack:l,dragEvent:c})}),[n,t]),b=Object(i.useCallback)((e=>{var{title:i="FilterSets",metadata:a={},panelState:s=null,id:r=ni.a.generate(),focusElement:o=di.DEFAULT_FOCUS_SELECTOR,createNewStack:l=!1,dragEvent:c=null}=e,h={type:"react-component",component:Qf.COMPONENT,props:{id:r,metadata:a,panelState:s,localDashboardId:t},title:i,id:r},{root:d}=n;di.openComponent({root:d,config:h,focusElement:o,createNewStack:l,dragEvent:c})}),[n,t]);return Object(i.useEffect)((()=>{var e=[s(am.COMPONENT,am),s(Xf.COMPONENT,Xf),s(Qf.COMPONENT,Qf)];return()=>{e.forEach((e=>e()))}}),[s]),Di(n.eventHub,kl.COLUMNS_CHANGED,u),Di(n.eventHub,kl.FILTERS_CHANGED,m),Di(n.eventHub,kl.TABLE_CHANGED,p),Di(n.eventHub,kl.OPEN_DROPDOWN,v),Di(n.eventHub,kl.OPEN_INPUT,f),Di(n.eventHub,kl.OPEN_FILTER_SET_MANAGER,b),Di(n.eventHub,fi.UNMOUNT,g),a.a.createElement(a.a.Fragment,null)},Kb=e=>{var{getDownloadWorker:t,loadPlugin:n,id:s,layout:r,registerComponent:o,hydrate:l=_i.hydrate}=e,c=Object(i.useCallback)((function(e,i){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:ni.a.generate(),l=arguments.length>4?arguments[4]:void 0,c={type:"react-component",component:Bf.COMPONENT,props:{getDownloadWorker:t,loadPlugin:n,localDashboardId:s,id:o,metadata:a,makeModel:i},title:e,id:o},{root:h}=r;di.openComponent({root:h,config:c,dragEvent:l})}),[t,s,r,n]),h=Object(i.useCallback)((e=>{var t={component:Bf.COMPONENT,id:e},{root:n}=r;di.closeComponent(n,t)}),[r]);return Object(i.useEffect)((()=>{var e=[o(Bf.COMPONENT,Bf,l)];return()=>{e.forEach((e=>e()))}}),[l,o]),Di(r.eventHub,_l.OPEN_GRID,c),Di(r.eventHub,_l.CLOSE_GRID,h),a.a.createElement(a.a.Fragment,null)};function Yb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function Xb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yb(Object(n),!0).forEach((function(t){Zb(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Zb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $b(e){return"function"===typeof e.getCoordinateForColumn}function Qb(e){var t=e;return $b(e)&&"function"===typeof t.setFilterMap&&"function"===typeof t.unsetFilterValue}var Jb=p.module("LinkerUtils");class eC{static getLinkType(e,t,n){var i;if(null==(null===e||void 0===e?void 0:e.panelId)||null==(null===t||void 0===t?void 0:t.panelId)||e.panelId===t.panelId||null!=n&&n!==e.panelId&&n!==t.panelId)return Jb.debug2("Incompatible panel ids",e,t,n),"invalid";if(null==e.panelComponent||null==t.panelComponent)return Jb.error("PanelComponent should not be null",e,t),"invalid";if(!(null===(i=eC.ALLOWED_LINKS.get(e.panelComponent))||void 0===i?void 0:i.includes(t.panelComponent)))return Jb.debug2("Incompatible panel components",e,t),"invalid";var{columnType:a}=e,{columnType:s}=t;if(!(null===s||cs.isCompatibleType(a,s)))return Jb.debug2("Incompatible type",a,s),"invalid";switch(t.panelComponent){case di.getComponentName(Vc):case di.getComponentName(Bf):return"tableLink";case di.getComponentName(am):return"filterSource"}return Jb.debug2("Incompatible target panel component",t.panelComponent),"invalid"}static findColumn(e,t){var{columnName:n,columnType:i}=t;return e.find((e=>{var{name:t,type:a}=e;return t===n&&a===i}))}static cloneLinksForPanel(e,t,n){var i=[];return e.forEach((e=>{var a;e.start.panelId===t&&"filterSource"!==e.type?i.push(Xb(Xb({},e),{},{id:ni.a.generate(),start:Xb(Xb({},e.start),{},{panelId:n})})):(null===(a=e.end)||void 0===a?void 0:a.panelId)===t&&i.push(Xb(Xb({},e),{},{id:ni.a.generate(),end:Xb(Xb({},e.end),{},{panelId:n})}))})),i}}Zb(eC,"ALLOWED_LINKS",new Map([[di.getComponentName(Bf),[di.getComponentName(Bf),di.getComponentName(Vc),di.getComponentName(am)]]]));var tC=eC;n(1412);var nC=Math.sqrt(180),iC=Math.asin(.5);class aC extends i.PureComponent{static makeCirclePath(e,t,n){return"M ".concat(e," ").concat(t," m -").concat(n,",0 a ").concat(n,",").concat(n," 0 1,0 ").concat(2*n,",0 a ").concat(n,",").concat(n," 0 1,0 -").concat(2*n,",0 z")}constructor(e){super(e),this.handleClick=this.handleClick.bind(this)}handleClick(e){e.stopPropagation(),e.preventDefault();var{id:t,onClick:n}=this.props;n(t)}render(){var{className:e,x1:t,y1:n,x2:i,y2:s,id:r}=this.props,o=Math.sqrt((t-i)**2+(n-s)**2),l=Math.atan2(s-n,i-t),c=Math.sin(l),h=Math.cos(l)+2,d=window.innerWidth,u=window.innerHeight,m=Math.max(0,Math.min(t+(i-t)/2+c*(.015*o)**1.5,d)),p=Math.max(0,Math.min(n+(s-n)/2+h*(.015*o)**1.5,u)),g="M ".concat(t," ").concat(n," Q ").concat(m," ").concat(p," ").concat(i," ").concat(s),v="M ".concat(0," ").concat(0," L ").concat(0," ").concat(u," L ").concat(d," ").concat(u," L ").concat(d," ").concat(0," z\n ").concat(aC.makeCirclePath(t,n,15),"\n ").concat(aC.makeCirclePath(i,s,15)),f="link-select-clip-".concat(r),b=Math.atan2(s-p,i-m),C=b-iC+Math.PI,S=b+iC+Math.PI,E=i+2*Math.cos(b),w=s+2*Math.sin(b),y=E+Math.cos(C)*nC,T=w+Math.sin(C)*nC,O=E+Math.cos(S)*nC,M=w+Math.sin(S)*nC,N="".concat(E,",").concat(w," ").concat(y,",").concat(T," ").concat(O,",").concat(M);return a.a.createElement("svg",{className:e},a.a.createElement("clipPath",{id:f},a.a.createElement("path",{d:v,clipRule:"evenodd"})),a.a.createElement("path",{className:"link-select",d:g,onClick:this.handleClick,clipPath:"url(#".concat(f,")")}),a.a.createElement("path",{className:"link-background",d:g}),a.a.createElement("path",{className:"link-foreground",d:g}),a.a.createElement("circle",{className:"link-dot",cx:t,cy:n,r:"5"}),a.a.createElement("polygon",{className:"link-triangle",points:N}))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(aC,"defaultProps",{className:"",onClick(){}});var sC=aC;n(1413);var rC=p.module("LinkerOverlayContent");class oC extends i.Component{constructor(e){super(e),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleEscapePressed=this.handleEscapePressed.bind(this),this.state={mouseX:void 0,mouseY:void 0}}componentDidMount(){window.addEventListener("mousemove",this.handleMouseMove,!0)}componentDidCatch(e,t){rC.error("componentDidCatch",e,t)}componentWillUnmount(){window.removeEventListener("mousemove",this.handleMouseMove,!0)}getPointFromLinkPoint(e){var{panelManager:t}=this.props,{panelId:n,columnName:i}=e,a=t.getOpenedPanelById(n);if(null!=a){if(!$b(a))throw new Error("Panel does not have getCoordinateForColumn method: ".concat(n));try{var s=a.getCoordinateForColumn(i);if(null!=s)return s}catch(o){rC.error("Could not get coordinate for column",i,a)}}var r=t.getContainerByPanelId(n);if(null==r)throw new Error("Unable to find panel container for id: ".concat(n));return di.getTabPoint(r)}handleMouseMove(e){this.setState({mouseX:e.clientX,mouseY:e.clientY})}handleEscapePressed(){var{onCancel:e}=this.props;e()}render(){var{disabled:e,links:t,messageText:n,onLinkDeleted:i,onAllLinksDeleted:s,onDone:r}=this.props,{mouseX:o,mouseY:l}=this.state,c=t.map((t=>{try{var{id:n,type:i,isReversed:a,start:s,end:r}=t,[c,h]=this.getPointFromLinkPoint(s),d=null!==o&&void 0!==o?o:c,u=null!==l&&void 0!==l?l:h;if(null!=r&&([d,u]=this.getPointFromLinkPoint(r)),a){var[m,p]=[c,h];[c,h]=[d,u],[d,u]=[m,p]}return{x1:c,y1:h,x2:d,y2:u,id:n,className:qe()("linker-link",{disabled:e},{"link-filter-source":"filterSource"===i},{"link-invalid":"invalid"===i},{interactive:null==t.end})}}catch(g){return rC.error("Unable to get point for link",t,g),null}})).filter((e=>null!=e));return a.a.createElement("div",{className:"linker-overlay"},a.a.createElement("svg",null,c.map((e=>{var{x1:t,y1:n,x2:s,y2:r,id:o,className:l}=e;return a.a.createElement(sC,{className:l,id:o,x1:t,y1:n,x2:s,y2:r,key:o,onClick:i})}))),a.a.createElement("div",{className:"linker-toast-dialog"},a.a.createElement("div",{className:"toast-body"},n),a.a.createElement("div",{className:"toast-footer"},a.a.createElement("button",{className:"btn btn-outline-primary",onClick:s,type:"button"},"Clear All"),a.a.createElement("button",{className:"btn btn-primary",onClick:r,type:"button"},"Done"))),a.a.createElement(vl,{actions:[{action:this.handleEscapePressed,shortcut:Uc.LINKER_CLOSE,isGlobal:!0}]}))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(oC,"defaultProps",{disabled:"false"});var lC=oC;function cC(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function hC(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cC(Object(n),!0).forEach((function(t){dC(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cC(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function dC(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uC=p.module("Linker"),mC=Object(o.b)(((e,t)=>({activeTool:U(e),isolatedLinkerPanelId:Ec(e,t.localDashboardId),links:wc(e,t.localDashboardId),timeZone:j(e)})),{setActiveTool:te,setDashboardLinks:Oc,addDashboardLinks:(e,t)=>(n,i)=>{var a=wc(i(),e),s=t.filter((e=>a.findIndex((t=>oe()(t.start,e.start)&&oe()(t.end,e.end)))<0));return n(Oc(e,a.concat(s)))},deleteDashboardLinks:(e,t)=>(n,i)=>{var a=wc(i(),e).filter((e=>!t.includes(e.id)));return n(Oc(e,a))},setDashboardIsolatedLinkerPanelId:Mc,setDashboardColumnSelectionValidator:(e,t)=>n=>n($i(e,{columnSelectionValidator:t}))});class pC extends i.Component{constructor(e){super(e),dC(this,"getCachedLinks",Object(ua.a)(((e,t,n)=>{var i=[...e];return t&&t.start&&i.push(t),void 0!==n?i.filter((e=>{var t,i;return(null===e||void 0===e||null===(t=e.start)||void 0===t?void 0:t.panelId)===n||(null===e||void 0===e||null===(i=e.end)||void 0===i?void 0:i.panelId)===n||null==(null===e||void 0===e?void 0:e.end)})):i}))),this.handleCancel=this.handleCancel.bind(this),this.handleDone=this.handleDone.bind(this),this.handlePanelCloned=this.handlePanelCloned.bind(this),this.handleFilterColumnSelect=this.handleFilterColumnSelect.bind(this),this.handleColumnsChanged=this.handleColumnsChanged.bind(this),this.handlePanelClosed=this.handlePanelClosed.bind(this),this.handleLayoutStateChanged=this.handleLayoutStateChanged.bind(this),this.handleAllLinksDeleted=this.handleAllLinksDeleted.bind(this),this.handleLinkDeleted=this.handleLinkDeleted.bind(this),this.handleChartColumnSelect=this.handleChartColumnSelect.bind(this),this.handleGridColumnSelect=this.handleGridColumnSelect.bind(this),this.handleUpdateValues=this.handleUpdateValues.bind(this),this.handleStateChange=this.handleStateChange.bind(this),this.handleExited=this.handleExited.bind(this),this.isColumnSelectionValid=this.isColumnSelectionValid.bind(this),this.state={linkInProgress:void 0}}componentDidMount(){var{layout:e}=this.props;this.startListening(e),this.updateSelectionValidators()}componentDidUpdate(e){var{activeTool:t,layout:n}=this.props;n!==e.layout&&(this.stopListening(e.layout),this.startListening(n)),t!==e.activeTool&&this.updateSelectionValidators()}componentDidCatch(e,t){uC.error("componentDidCatch",e,t)}componentWillUnmount(){var{layout:e}=this.props;this.stopListening(e)}startListening(e){e.on("stateChanged",this.handleLayoutStateChanged);var{eventHub:t}=e;t.on(_l.COLUMN_SELECTED,this.handleGridColumnSelect),t.on(_l.DATA_SELECTED,this.handleUpdateValues),t.on(_l.STATE_CHANGED,this.handleStateChange),t.on(Dl.COLUMN_SELECTED,this.handleChartColumnSelect),t.on(fi.CLONED,this.handlePanelCloned),t.on(kl.COLUMN_SELECTED,this.handleFilterColumnSelect),t.on(kl.COLUMNS_CHANGED,this.handleColumnsChanged),t.on(fi.CLOSED,this.handlePanelClosed)}stopListening(e){e.off("stateChanged",this.handleLayoutStateChanged);var{eventHub:t}=e;t.off(_l.COLUMN_SELECTED,this.handleGridColumnSelect),t.off(_l.DATA_SELECTED,this.handleUpdateValues),t.off(_l.STATE_CHANGED,this.handleStateChange),t.off(Dl.COLUMN_SELECTED,this.handleChartColumnSelect),t.off(fi.CLONED,this.handlePanelCloned),t.off(kl.COLUMN_SELECTED,this.handleFilterColumnSelect),t.off(kl.COLUMNS_CHANGED,this.handleColumnsChanged),t.off(fi.CLOSED,this.handlePanelClosed)}handleCancel(){var{linkInProgress:e}=this.state;if(null==e){var{setActiveTool:t}=this.props;t(ac.DEFAULT)}this.setState({linkInProgress:void 0})}handleDone(){var{setActiveTool:e}=this.props;e(ac.DEFAULT),this.setState({linkInProgress:void 0})}handleChartColumnSelect(e,t){this.columnSelected(e,t,!0)}handleFilterColumnSelect(e,t){uC.debug("handleFilterColumnSelect",this.isOverlayShown());var{links:n,localDashboardId:i,setActiveTool:a,setDashboardIsolatedLinkerPanelId:s}=this.props,r=di.getIdFromPanel(e),o=n.filter((e=>{var t,n;return(null===(t=e.start)||void 0===t?void 0:t.panelId)===r||(null===(n=e.end)||void 0===n?void 0:n.panelId)===r}));if(!this.isOverlayShown()&&null!=r)return a(ac.LINKER),s(i,r),void(0===o.length&&this.columnSelected(e,t,!0,r));this.columnSelected(e,t,!0)}handleColumnsChanged(e,t){uC.debug("handleColumnsChanged",e,t);var{links:n}=this.props,i=di.getIdFromPanel(e);if(null!=i){var a=n.filter((e=>{var{start:n,end:a}=e;return n.panelId===i&&null==tC.findColumn(t,n)||null!=a&&a.panelId===i&&null==tC.findColumn(t,a)}));this.deleteLinks(a)}else uC.error("Invalid panelId",e)}handleGridColumnSelect(e,t){this.columnSelected(e,t)}columnSelected(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0;if(void 0!==i||this.isOverlayShown()){var{isolatedLinkerPanelId:a}=this.props,{linkInProgress:s}=this.state,r=di.getIdFromPanel(e);if(null!=r){var o=di.getComponentNameFromPanel(e),{name:l,type:c}=t;if(null==s||null==s.start){var h={id:ni.a.generate(),start:{panelId:r,panelComponent:o,columnName:l,columnType:c},type:"invalid",isReversed:n};uC.debug("starting link",h),this.setState({linkInProgress:h})}else{var{start:d,id:u,isReversed:m}=s,p={panelId:r,panelComponent:o,columnName:l,columnType:c},g=tC.getLinkType(m?p:d,m?d:p,null!==i&&void 0!==i?i:a);switch(g){case"invalid":return void uC.debug("Ignore invalid link connection",s,p);case"filterSource":var{links:v}=this.props,f=m?d.panelId:p.panelId,b=v.filter((e=>{var{end:t}=e;return(null===t||void 0===t?void 0:t.panelId)===f}));this.deleteLinks(b)}var C={start:m?p:d,end:m?d:p,id:u,type:g};uC.info("creating link",C),this.setState({linkInProgress:void 0},(()=>{this.addLinks([C])}))}}}}unsetFilterValueForLink(e){var{panelManager:t}=this.props;if(e.end){var{end:n}=e,{panelId:i,columnName:a,columnType:s}=n,r=t.getOpenedPanelById(i);r?Qb(r)?r.unsetFilterValue(a,s):uC.debug("endPanel.unsetFilterValue not implemented",r):uC.debug("endPanel no longer exists, ignoring unsetFilterValue",i)}}setPanelFilterMap(e,t){uC.debug("Set filter data for panel:",e,t);var{panelManager:n}=this.props,i=n.getOpenedPanelById(e);i?Qb(i)?i.setFilterMap(t):uC.debug("panel.setFilterMap not implemented",e,i):uC.debug("panel no longer exists, ignoring setFilterMap",e)}addLinks(e){var{addDashboardLinks:t,localDashboardId:n}=this.props;t(n,e)}deleteLinks(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],{localDashboardId:n}=this.props;if(e.forEach((e=>this.unsetFilterValueForLink(e))),t){var{setDashboardLinks:i}=this.props;i(n,[])}else if(e.length>0){var{deleteDashboardLinks:a}=this.props;a(n,e.map((e=>{var{id:t}=e;return t})))}}handleAllLinksDeleted(){var{links:e,isolatedLinkerPanelId:t}=this.props;if(void 0===t)this.deleteLinks(e,!0);else{var n=e.filter((e=>{var n,i;return(null===e||void 0===e||null===(n=e.start)||void 0===n?void 0:n.panelId)===t||(null===e||void 0===e||null===(i=e.end)||void 0===i?void 0:i.panelId)===t}));this.deleteLinks(n)}this.setState({linkInProgress:void 0})}handleLinkDeleted(e){var{links:t}=this.props,n=t.find((t=>t.id===e));n?this.deleteLinks([n]):uC.error("Unable to find link to delete",e)}handleUpdateValues(e,t){for(var n=di.getIdFromPanel(e),{links:i,timeZone:a}=this.props,s=new Map,r=0;r<i.length;r+=1){var{start:o,end:l}=i[r];if(o.panelId===n&&null!=l){var{panelId:c,columnName:h,columnType:d}=l,u=s.has(c)?s.get(c):new Map,{value:m}=t[o.columnName],p="".concat(m);if(cs.isDateType(d))p=new Ds({timeZone:a,showTimeZone:!1,showTSeparator:!0,defaultDateTimeFormatString:Ja.FULL_DATE_FORMAT}).format(m);u.set(h,{columnType:d,text:p,value:m}),s.set(c,u)}}s.forEach(((e,t)=>{this.setPanelFilterMap(t,e)}))}handlePanelCloned(e,t){var{links:n}=this.props,i=di.getIdFromPanel(e),a=t.id;if(null!=i){var s=tC.cloneLinksForPanel(n,i,a);this.addLinks(s)}}handlePanelClosed(e){uC.debug("Panel ".concat(e," closed, deleting links.")),this.deleteLinksForPanelId(e)}handleLayoutStateChanged(){this.forceUpdate()}handleStateChange(){this.forceUpdate()}handleExited(){var{localDashboardId:e,setDashboardIsolatedLinkerPanelId:t}=this.props;t(e,void 0)}deleteLinksForPanelId(e){for(var{links:t}=this.props,n=0;n<t.length;n+=1){var i=t[n],{start:a,end:s,id:r}=i;a.panelId!==e&&(null===s||void 0===s?void 0:s.panelId)!==e||this.handleLinkDeleted(r)}}isOverlayShown(){var{activeTool:e}=this.props;return e===ac.LINKER}updateSelectionValidators(){var{activeTool:e,setDashboardColumnSelectionValidator:t,localDashboardId:n}=this.props;if(e===ac.LINKER)t(n,this.isColumnSelectionValid);else t(n,void 0)}updateLinkInProgressType(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"invalid";this.setState({linkInProgress:hC(hC({},e),{},{type:t})})}isColumnSelectionValid(e,t){var{linkInProgress:n}=this.state,{isolatedLinkerPanelId:i}=this.props;if(null==(null===n||void 0===n?void 0:n.start))return!0;if(null==t)return this.updateLinkInProgressType(n),!1;var{isReversed:a,start:s}=n,r=di.getIdFromPanel(e);if(null==r)return!1;var o={panelId:r,panelComponent:di.getComponentNameFromPanel(e),columnName:t.name,columnType:t.type},l=a?tC.getLinkType(o,s,i):tC.getLinkType(s,o,i);return this.updateLinkInProgressType(n,l),"invalid"!==l}render(){var{links:e,isolatedLinkerPanelId:t,panelManager:n}=this.props,{linkInProgress:i}=this.state,s=this.isOverlayShown(),r=null!=i&&null!=i.start,o=void 0===t?"Click a column source, then click a column target to create a filter link. Remove a filter link by clicking again to erase. Click done when finished.":"Create a link between the source column button and a table column by clicking on one, then the other. Remove the link by clicking it directly. Click done when finished.";return a.a.createElement(a.a.Fragment,null,a.a.createElement(We.CSSTransition,{in:s,timeout:Kn.transitionMs,classNames:"fade",mountOnEnter:!0,unmountOnExit:!0,onExited:this.handleExited},a.a.createElement(lC,{disabled:r,panelManager:n,links:this.getCachedLinks(e,i,t),messageText:o,onLinkDeleted:this.handleLinkDeleted,onAllLinksDeleted:this.handleAllLinksDeleted,onDone:this.handleDone,onCancel:this.handleCancel})))}}var gC=mC(pC),vC=e=>{var{id:t,layout:n,panelManager:i}=e;return a.a.createElement(gC,{layout:n,localDashboardId:t,panelManager:i})};function fC(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class bC{static getNewMarkdownTitle(e){for(var t="".concat(bC.DEFAULT_TITLE),n=0;e.indexOf(t)>=0;)n+=1,t="".concat(bC.DEFAULT_TITLE,"-").concat(n);return t}}fC(bC,"DEFAULT_TITLE","Note"),fC(bC,"DEFAULT_CONTENT","# Markdown Note\n\nThis note can be edited using **markdown** for styling.");var CC=bC,SC=e=>{var{id:t,layout:n,panelManager:s,registerComponent:r}=e,o=Object(i.useCallback)((e=>{var{title:t,componentState:n,props:i}=e,{panelState:a=null}=i;return n&&({panelState:a=null}=n),t&&a&&a.content&&0!==a.content.length&&a.content!==CC.DEFAULT_CONTENT?Ai(e):null}),[]),l=Object(i.useCallback)((function(){var{title:e="",metadata:i={},id:a=ni.a.generate(),focusElement:r=di.DEFAULT_FOCUS_SELECTOR,createNewStack:o=!1,dragEvent:l=null}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},c=s.getOpenedPanelConfigsOfType(Tb.COMPONENT),h=s.getClosedPanelConfigsOfType(Tb.COMPONENT),d=c.map((e=>{var t;return null!==(t=e.title)&&void 0!==t?t:""})),u=e||CC.getNewMarkdownTitle(d),m=h.length>0?null:CC.DEFAULT_CONTENT,p={type:"react-component",component:Tb.COMPONENT,props:{id:a,metadata:i,panelState:{content:m},localDashboardId:t},title:u,id:a},{root:g}=n;di.openComponent({root:g,config:p,focusElement:r,createNewStack:o,dragEvent:l})}),[t,n,s]);return Object(i.useEffect)((()=>{var e=[r(Tb.COMPONENT,Tb,Pi,o)];return()=>{e.forEach((e=>e()))}}),[o,r]),Di(n.eventHub,Hl.OPEN,l),a.a.createElement(a.a.Fragment,null)},EC=e=>{var{hydrate:t=_i.hydrate,registerComponent:n}=e;return Object(i.useEffect)((()=>{var e=[n(jb.COMPONENT,jb,t)];return()=>{e.forEach((e=>e()))}}),[t,n]),a.a.createElement(a.a.Fragment,null)},wC=n(489);const yC="SET_LAYOUT_STORAGE";function TC(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class OC{}TC(OC,"DROPDOWN_FILTER","ControlType.DROPDOWN_FILTER"),TC(OC,"INPUT_FILTER","ControlType.INPUT_FILTER"),TC(OC,"MARKDOWN","ControlType.MARKDOWN"),TC(OC,"FILTER_SET_MANAGER","ControlType.FILTER_SET_MANAGER");var MC=OC,NC=n.p+"static/media/community-wordmark-app.1acb5a93.svg",DC=n(4);const xC=p.module("FormattingSectionContent");class RC extends i.PureComponent{static focusFirstInputInContainer(e){const t=e.querySelector("input, select, textarea");t&&t.focus()}static isValidColumnName(e){return e&&Pa.isValidColumnName(e)}static isValidFormat(e,t){if(!e||!t.formatString)return!1;switch(e){case"datetime":return Ds.isValid(t);case"decimal":return Ls.isValid(t);case"int":return Ps.isValid(t);default:return xC.warn("Trying to validate format of unknown type"),!0}}static removeFormatRuleExtraProps(e){const{id:t,isNewRule:n,...i}=e;return i}static isFormatRuleValidForSave(e){return RC.isValidColumnName(e.columnName)&&RC.isValidFormat(e.columnType,e.format)}static renderTimeZoneOptions(){const e=Ya.TIME_ZONES.map((e=>{const{label:t,value:n}=e;return Object(DC.jsx)("option",{value:n,children:t},n)}));return e}static renderColumnTypeOptions(){const e=[{value:cs.dataType.DATETIME,label:"DateTime"},{value:cs.dataType.DECIMAL,label:"Decimal"},{value:cs.dataType.INT,label:"Integer"}].map((e=>Object(DC.jsx)("option",{value:e.value,children:e.label},"key-columnType-".concat(e.value))));return Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsx)("option",{disabled:!0,value:"",children:"Select Type"},"key-columnType-placeholder"),e]})}static renderDateTimeOptions(e,t,n,i,a,s){const r=new Hs([],{timeZone:t,showTimeZone:n,showTSeparator:i}),o=a?Ds.getGlobalFormats(n,i):Ds.getFormats(n,i);return s&&!o.includes(s)&&o.unshift(s),o.map((t=>{const n=Ds.makeFormat("",t,Ds.TYPE_GLOBAL);return Object(DC.jsx)("option",{value:t,children:r.getFormattedString(e,cs.dataType.DATETIME,"",n)},t)}))}constructor(e){var t;super(e),t=this,this.getCachedColumnTypeOptions=Object(ua.a)((()=>RC.renderColumnTypeOptions())),this.getCachedDateTimeFormatOptions=Object(ua.a)((function(e,n,i){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;const{timestampAtMenuOpen:r}=t.state;return RC.renderDateTimeOptions(r,e,n,i,a,s)})),this.debouncedCommitChanges=pa()(this.commitChanges.bind(this),RC.inputDebounceTime),this.handleDefaultDateTimeFormatChange=this.handleDefaultDateTimeFormatChange.bind(this),this.handleFormatRuleEntered=this.handleFormatRuleEntered.bind(this),this.handleFormatRuleChange=this.handleFormatRuleChange.bind(this),this.handleFormatRuleCreate=this.handleFormatRuleCreate.bind(this),this.handleFormatRuleDelete=this.handleFormatRuleDelete.bind(this),this.handleShowTimeZoneChange=this.handleShowTimeZoneChange.bind(this),this.handleShowTSeparatorChange=this.handleShowTSeparatorChange.bind(this),this.handleTimeZoneChange=this.handleTimeZoneChange.bind(this),this.containerRef=a.a.createRef(),this.addFormatRuleButtonRef=a.a.createRef(),this.lastFormatRuleIndex=0,this.state={formatSettings:[],formatRulesChanged:!1,showTimeZone:!0,showTSeparator:!1,timeZone:"",defaultDateTimeFormat:"",timestampAtMenuOpen:new Date}}componentDidMount(){const{formatter:e,defaultDateTimeFormat:t,showTimeZone:n,showTSeparator:i,timeZone:a}=this.props;this.setState({formatSettings:e.map((e=>({...e,id:this.getAutoIncrementFormatRuleIndex()}))),defaultDateTimeFormat:t,showTimeZone:n,showTSeparator:i,timeZone:a},(()=>{RC.focusFirstInputInContainer(this.containerRef.current)}))}componentWillUnmount(){this.debouncedCommitChanges.flush()}isDuplicateRule(e){const{formatSettings:t}=this.state;return t.some((t=>t.id!==e.id&&t.columnName===e.columnName&&t.columnType===e.columnType))}getAutoIncrementFormatRuleIndex(){const{lastFormatRuleIndex:e}=this;return this.lastFormatRuleIndex+=1,e}handleDefaultDateTimeFormatChange(e){xC.debug("handleDefaultDateTimeFormatChange",e.target.value),this.setState({defaultDateTimeFormat:e.target.value},(()=>{this.debouncedCommitChanges()}))}handleFormatRuleChange(e,t,n){this.setState((i=>{const{formatSettings:a}=i,s=a.concat();let r={};"columnType"===t&&(r={format:""});const o={...s[e],...r,[t]:n};return s[e]=o,{formatSettings:s}}),(()=>{this.debouncedCommitChanges()}))}handleFormatRuleCreate(){this.setState((e=>{const{formatSettings:t}=e;return{formatSettings:[...t,{columnType:cs.dataType.DATETIME,columnName:"",format:"",id:this.getAutoIncrementFormatRuleIndex(),isNewRule:!0}],formatRulesChanged:!0}}))}handleFormatRuleDelete(e){this.setState((t=>{const{formatSettings:n}=t;return{formatSettings:n.filter(((t,n)=>n!==e)),formatRulesChanged:!0}}),(()=>{this.debouncedCommitChanges()}))}handleShowTimeZoneChange(){this.setState((e=>({showTimeZone:!e.showTimeZone})),(()=>{this.debouncedCommitChanges()}))}handleShowTSeparatorChange(){this.setState((e=>({showTSeparator:!e.showTSeparator})),(()=>{this.debouncedCommitChanges()}))}handleTimeZoneChange(e){this.setState({timeZone:e.target.value},(()=>{this.debouncedCommitChanges()}))}handleFormatRuleEntered(e){this.scrollToFormatBlockBottom(),RC.focusFirstInputInContainer(e)}commitChanges(){const{formatSettings:e,defaultDateTimeFormat:t,showTimeZone:n,showTSeparator:i,timeZone:a}=this.state,s=e.filter(RC.isFormatRuleValidForSave).map(RC.removeFormatRuleExtraProps),{settings:r,saveSettings:o}=this.props;o({...r,formatter:s,defaultDateTimeFormat:t,showTimeZone:n,showTSeparator:i,timeZone:a})}scrollToFormatBlockBottom(){const{scrollTo:e}=this.props;e(0,this.addFormatRuleButtonRef.current.offsetHeight+this.addFormatRuleButtonRef.current.offsetTop)}getRuleError(e){const t={hasColumnNameError:!1,hasFormatError:!1,message:""},n=[];return e.isNewRule||(this.isDuplicateRule(e)&&(t.hasColumnNameError=!0,n.push("Duplicate column name/type combo.")),RC.isValidColumnName(e.columnName)||(t.hasColumnNameError=!0,n.push("Column names must start with a letter or underscore and contain only alphanumeric characters or underscores.")),e.format?RC.isValidFormat(e.columnType,e.format)||(t.hasFormatError=!0,n.push("Invalid formatting rule.")):(t.hasFormatError=!0,n.push("Empty formatting rule.")),t.message=n.join("\n")),t}renderFormatRule(e,t){const n="input-".concat(e,"-columnName"),i="input-".concat(e,"-columnType"),a="input-".concat(e,"-format"),s=this.getCachedColumnTypeOptions(),r=this.getRuleError(t);return Object(DC.jsxs)("fieldset",{className:"container-fluid format-rule-container",children:[Object(DC.jsxs)("div",{className:"form-row",children:[Object(DC.jsxs)("div",{className:"form-group col-7 mb-2",children:[Object(DC.jsx)("label",{htmlFor:n,children:"Column Name"}),Object(DC.jsx)("input",{id:n,className:qe()("form-control",{"is-invalid":r.hasColumnNameError}),"data-lpignore":!0,type:"text",value:t.columnName,onChange:t=>this.handleFormatRuleChange(e,"columnName",t.target.value),onBlur:()=>this.handleFormatRuleChange(e,"isNewRule",!1)})]}),Object(DC.jsxs)("div",{className:"form-group col mb-2",children:[Object(DC.jsx)("button",{type:"button",className:"btn btn-link btn-link-icon btn-delete-format-rule float-right",tabIndex:"-1",onClick:()=>this.handleFormatRuleDelete(e),children:Object(DC.jsx)(Ke.a,{icon:$t})}),Object(DC.jsx)("label",{htmlFor:i,children:"Column Type"}),Object(DC.jsx)("select",{id:i,className:"custom-select",value:t.columnType,onChange:t=>this.handleFormatRuleChange(e,"columnType",t.target.value),children:s})]})]}),Object(DC.jsx)("div",{className:"form-row",children:Object(DC.jsxs)("div",{className:"form-group col-12 d-flex mb-2",children:[Object(DC.jsx)("label",{className:"flex-shrink-0 col-form-label mr-3",htmlFor:a,children:"Formatting Rule"}),this.renderFormatRuleInput(e,t.columnType,a,t.format,r.hasFormatError)]})}),Object(DC.jsx)("div",{className:"form-row",children:Object(DC.jsx)("div",{className:"form-group col-12 d-flex mb-2",children:r.message&&Object(DC.jsx)("p",{className:"text-danger",children:r.message})})})]},e)}renderFormatRuleInput(e,t,n,i,a){switch(cs.getNormalizedType(t)){case cs.dataType.DATETIME:return this.renderDateTimeFormatRuleInput(e,n,i,a);case cs.dataType.DECIMAL:return this.renderDecimalFormatRuleInput(e,n,i,a);case cs.dataType.INT:return this.renderIntegerFormatRuleInput(e,n,i,a);default:return null}}renderDateTimeFormatRuleInput(e,t,n,i){const{showTimeZone:a,showTSeparator:s,timeZone:r}=this.state,o=n&&n.formatString||"";return Object(DC.jsxs)("select",{className:qe()("custom-select",{"is-invalid":i}),value:o,id:t,onChange:t=>{const n=Ds.makeFormat("",t.target.value,Ds.TYPE_GLOBAL);this.handleFormatRuleChange(e,"format",n)},children:[Object(DC.jsx)("option",{value:"",disabled:!0,children:"Select format"},"default"),this.getCachedDateTimeFormatOptions(r,a,s)]})}renderIntegerFormatRuleInput(e,t,n,i){const a=n&&n.formatString||"";return Object(DC.jsx)("input",{className:qe()("form-control","flex-grow-1",{"is-invalid":i}),"data-lpignore":!0,id:t,placeholder:Ps.DEFAULT_FORMAT_STRING,type:"text",value:a,onChange:t=>{const n=Ps.makeFormat("",t.target.value,null,Ps.TYPE_GLOBAL);this.handleFormatRuleChange(e,"format",n)}})}renderDecimalFormatRuleInput(e,t,n,i){const a=n&&n.formatString||"";return Object(DC.jsx)("input",{className:qe()("form-control","flex-grow-1",{"is-invalid":i}),"data-lpignore":!0,id:t,placeholder:Ls.DEFAULT_FORMAT_STRING,type:"text",value:a,onChange:t=>{const n=Ls.makeFormat("",t.target.value,null,Ls.TYPE_GLOBAL);this.handleFormatRuleChange(e,"format",n)}})}render(){const{formatRulesChanged:e,formatSettings:t,defaultDateTimeFormat:n,timeZone:i,showTimeZone:a,showTSeparator:s}=this.state,r=t.map(((e,t)=>Object(DC.jsx)(We.CSSTransition,{classNames:"fade",timeout:Kn.transitionMs,onEnter:this.handleFormatRuleEntered,children:this.renderFormatRule(t,e)},e.id))),o=Object(DC.jsxs)("button",{type:"button",className:"btn btn-link mb-3",onClick:this.handleFormatRuleCreate,ref:this.addFormatRuleButtonRef,children:[Object(DC.jsx)(Ke.a,{icon:wn}),"Add New Rule"]});return Object(DC.jsxs)("div",{ref:this.containerRef,children:[Object(DC.jsxs)("div",{className:"container-fluid p-0",children:[Object(DC.jsxs)("div",{className:"form-row mb-2",children:[Object(DC.jsx)("label",{className:"col-form-label col-3",children:"Time zone"}),Object(DC.jsx)("div",{className:"col-9",children:Object(DC.jsx)("select",{className:"custom-select",value:i,onChange:this.handleTimeZoneChange,children:RC.renderTimeZoneOptions()})})]}),Object(DC.jsxs)("div",{className:"form-row mb-2",children:[Object(DC.jsx)("label",{className:"col-form-label col-3",children:"DateTime"}),Object(DC.jsx)("div",{className:"col-9",children:Object(DC.jsx)("select",{className:"custom-select",value:n,onChange:this.handleDefaultDateTimeFormatChange,children:this.getCachedDateTimeFormatOptions(i,a,s,!0,n)})})]}),Object(DC.jsx)("div",{className:"form-row",children:Object(DC.jsx)("div",{className:"offset-3 col-9",children:Object(DC.jsx)(Ed,{checked:a,onChange:this.handleShowTimeZoneChange,children:"Show time zone in dates"})})}),Object(DC.jsx)("div",{className:"form-row mb-3",children:Object(DC.jsx)("div",{className:"offset-3 col-9",children:Object(DC.jsx)(Ed,{checked:s,onChange:this.handleShowTSeparatorChange,children:"Show 'T' separator"})})})]}),Object(DC.jsx)("div",{children:"Default Formatting Rules"}),Object(DC.jsx)("div",{className:"app-settings-menu-description mb-3",children:"Applies a preset column formatting rule to all columns that match a set name and type"}),Object(DC.jsx)(We.TransitionGroup,{appear:e,enter:e,exit:e,children:r}),o]})}}RC.inputDebounceTime=250,RC.defaultProps={scrollTo:()=>{}};var IC=Object(o.b)((e=>{return{formatter:(t=e,_(t).formatter),defaultDateTimeFormat:H(e),showTimeZone:V(e),showTSeparator:z(e),timeZone:j(e),settings:_(e)};var t}),{saveSettings:ee})(RC);var LC=()=>{const[e,t]=Object(i.useState)(!1),n=()=>t(!e);return Object(DC.jsxs)("button",{type:"button",className:"btn btn-link",onClick:n,children:[Object(DC.jsx)(Ke.a,{icon:Mt}),"Legal Notices",Object(DC.jsxs)(sm.a,{isOpen:e,toggle:n,className:"theme-bg-light",children:[Object(DC.jsx)(rm.a,{toggle:n,children:"Legal Notice"}),Object(DC.jsxs)(om.a,{children:[Object(DC.jsx)("p",{children:"Deephaven software is protected by U.S. Patent Nos. 9,612,959; 9,613,018; 9,613,109; 9,619,210; 9,633,060; 9,639,570; 9,672,238; 9,679,006; 9,690,821; 9,710,511; 9,760,591; 9,805,084; 9,836,495; 9,836,494; 9,886,469; 9,898,496; 9,934,266; 10,002,153; 10,002,154; 10,002,155; 10,003,673; 10,019,138; 10,069,943; 10,176,211; 10,198,465; 10,198,466; 10,198,469; 10,212,257; 10,241,960; 10,241,965; 10,242,040; 10,242,041; 10,353,893; 10,346,394; 10,452,649; 10,496,639; 10,540,351; 10,552,412; 10,565,194; 10,565,206; 10,572,474; 10,621,168; 10,642,829; 10,657,184; 10,678,787; 10,691,686; and 10,783,191. Other patents pending."}),Object(DC.jsxs)("p",{children:["\xa9 2016-",(new Date).getFullYear()," Deephaven Data Labs LLC. Patent Pending."]})]})]})]})};function FC(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class kC extends i.Component{static handleEnter(e){e.style.height="0"}static handleEntering(e){var t=e;t.style.height="".concat(kC.getHeight(t),"px")}static handleExiting(e){e.style.height="0"}static handleExit(e){var t=e;t.style.height="".concat(kC.getHeight(t),"px")}static getHeight(e){var t=e.scrollWidth-e.clientWidth;return e.scrollHeight-t}constructor(e){super(e),this.handleEntered=this.handleEntered.bind(this)}handleEntered(e){var t=e;t.style.height="";var{autoFocusOnShow:n}=this.props;if(n){var i=t.querySelector("input, select, textarea");i&&i.focus()}}render(){var{children:e,className:t,in:n}=this.props;return a.a.createElement(We.CSSTransition,{in:n,classNames:{enterActive:"collapsing",enterDone:"collapse show",exitActive:"collapsing",exitDone:"collapse"},onEnter:kC.handleEnter,onEntering:kC.handleEntering,onEntered:this.handleEntered,onExit:kC.handleExit,onExiting:kC.handleExiting,timeout:350},(n=>a.a.createElement("div",{className:qe()({collapse:"exited"===n},t)},e)))}}FC(kC,"propTypes",{className:pi.a.string,in:pi.a.bool.isRequired,children:pi.a.node.isRequired,autoFocusOnShow:pi.a.bool}),FC(kC,"defaultProps",{className:"",autoFocusOnShow:!1});var AC=kC;const PC=e=>{const{children:t,isExpanded:n,sectionKey:i,title:a,onToggle:s}=e;return Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsx)("div",{children:Object(DC.jsxs)("button",{type:"button",className:"btn btn-link btn-collapse-trigger",onClick:()=>s(i),children:[Object(DC.jsx)("div",{className:"flex-grow-1",children:a}),Object(DC.jsx)("div",{className:"flex-shrink-0",children:Object(DC.jsx)(Ke.a,{transform:n?"flip-v":"",icon:Qt})})]})}),Object(DC.jsx)(AC,{in:n,autoFocusOnShow:!0,children:t})]})};PC.defaultProps={children:null,onToggle:()=>{}};var _C=PC;n(1415);function HC(e){let{shortcut:t,displayText:n,categoryName:a,onChange:s}=e;const[r,o]=Object(i.useState)(n),[l,c]=Object(i.useState)(t.getKeyState()),[h,d]=Object(i.useState)(!1),[u,m]=Object(i.useState)("");return Object(i.useEffect)((()=>{o(n),c(t.getKeyState())}),[n,t]),Object(i.useEffect)((()=>{o(ze.getDisplayText(l)),t.matchesKeyState(l)&&d(!1)}),[l,t]),Object(i.useEffect)((()=>{if(h){if(!ze.isValidKeyState(l))return void(ze.isAllowedKey(l.keyValue)?m("Must contain a modifier key"):m("Must contain an allowed action key"));const e=Be.getConflictingShortcuts(l).filter((e=>e.id.startsWith(a)&&e!==t)).map((e=>e.name));if(e.length)return void m("Conflicts with ".concat(e.join(", ")));m("")}else m("")}),[h,l,a,t]),Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsxs)("div",{className:"shortcut-item-container",children:[Object(DC.jsxs)("label",{className:"shortcut-item-name",children:[t.name,t.tooltip&&Object(DC.jsx)(Ol,{children:t.tooltip})]}),Object(DC.jsxs)("div",{className:"shortcut-item-input-container",children:[Object(DC.jsx)("input",{className:qe()("form-control",{"is-invalid":u}),onKeyDown:function(e){if(e.stopPropagation(),e.preventDefault(),t.isEditable&&!e.repeat){const t=ze.getKeyStateFromEvent(e),n=ze.createKeyState([He.BACKSPACE]);ze.doKeyStatesMatch(t,n)?c(ze.NULL_KEY_STATE):c(t)}},onKeyUp:function(e){e.stopPropagation(),e.preventDefault(),t.matchesKeyState(l)||d(!0)},onFocus:function(){je.disableAllActions()},onBlur:function(){je.enableAllActions()},disabled:!t.isEditable,value:r,readOnly:!0}),!ze.doKeyStatesMatch(l,t.getDefaultKeyState())&&!u&&Object(DC.jsx)(gh,{className:"reset-to-default-button",kind:"ghost",icon:Object(DC.jsx)(Ke.a,{icon:zt,transform:{rotate:90,flipX:!0}}),tooltip:"Reset to default",onClick:function(){d(!0),c(t.getDefaultKeyState())}})]})]}),h&&Object(DC.jsxs)("div",{className:qe()("shortcut-item-message-container",{"is-invalid":u}),children:[Object(DC.jsx)("div",{className:"shortcut-item-message",children:u}),Object(DC.jsxs)("div",{className:"shortcut-item-message-buttons",children:[ze.isValidKeyState(l)&&Object(DC.jsx)(gh,{kind:"ghost",onClick:function(){t.setKeyState(l),d(!1),s(t)},children:"Confirm"}),Object(DC.jsx)(gh,{kind:"ghost",onClick:function(){const e=t.getKeyState();c(e),d(!1)},children:"Undo"})]})]})]})}function jC(e){let{name:t,shortcuts:n,saveShortcutOverrides:a}=e;const[s,r]=Object(i.useState)(n);function o(e){const t=s.filter((t=>t!==e&&!t.isNull()&&t.matchesKeyState(e.getKeyState())));t.forEach((e=>e.setToNull())),a([e,...t]),r((e=>[...e]))}const l=Object(i.useMemo)((()=>s.map((e=>e.getDisplayText()))),[s]);return Object(DC.jsxs)("div",{className:"mt-3",children:[Object(DC.jsx)("div",{className:"font-weight-bold",children:(c=t,c.split("_").map((e=>"".concat(e[0].toUpperCase()).concat(e.slice(1).toLowerCase()))).join(" "))}),s.map(((e,n)=>Object(DC.jsx)(HC,{shortcut:e,displayText:l[n],categoryName:t,onChange:o},e.id)))]});var c}const VC={saveSettings:ee};var zC=Object(o.b)((e=>{return{settings:_(e),shortcutOverrides:(t=e,_(t).shortcutOverrides)};var t}),VC)((function(e){let{shortcutOverrides:t={},settings:n,saveSettings:a}=e;const s=Object(i.useCallback)((e=>{const i=ze.isMacPlatform,s={mac:{...t.mac},windows:{...t.windows}},r=i?s.mac:s.windows;e.forEach((e=>{e.isDefault()?delete r[e.id]:r[e.id]=e.getKeyState()})),a({...n,shortcutOverrides:s})}),[n,a,t]);let r=Array.from(Be.shortcutsByCategory.entries()).map((e=>{let[t,n]=e;return{name:t,shortcuts:n}}));const o=r.findIndex((e=>"GLOBAL"===e.name.toUpperCase())),l=r.splice(o,1);return r=r.concat(l),Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsx)("div",{className:"app-settings-menu-description",children:"Customize shortcuts below. Assigning shortcuts that conflict with the browser or IDE shortcuts may cause unintended behavior"}),r.map((e=>Object(DC.jsx)(jC,{name:e.name,shortcuts:e.shortcuts,saveShortcutOverrides:s},e.name)))]})}));const UC=new b,BC=new E(UC);const WC="yyyy-MM-dd-HHmmss";function GC(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"root",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new Map([[e,""]]);const i={};return Object.entries(e).forEach((e=>{let[a,s]=e;try{JSON.stringify(s),i[a]=s}catch(r){const e=s;if("bigint"===typeof s)i[a]=s.toString();else if(n.has(e))i[a]="Circular ref to ".concat(n.get(e));else{const r="".concat(t,".").concat(a);n.set(e,r),i[a]=GC(s,r,n)}}})),i}function qC(){const e=Le.getState();return JSON.stringify(GC(e),null,2)}function KC(){const e={uiVersion:"0.8.1",userAgent:navigator.userAgent};return JSON.stringify(e,null,2)}n(1416);class YC extends i.Component{static focusFirstInputInContainer(e){const t=e.querySelector("input, select, textarea");t&&t.focus()}static handleExportSupportLogs(){!async function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"".concat(va.i18n.DateTimeFormat.format(WC,new Date),"_support_logs");const t=new Cd.a,n=t.folder(e);n.file("console.txt",BC.getFormattedHistory()),n.file("redux.json",qC()),n.file("metadata.json",KC());const i=await t.generateAsync({type:"blob"}),a=document.createElement("a");a.href=URL.createObjectURL(i),a.download="".concat(e,".zip"),a.click()}()}constructor(e){super(e),this.handleClose=this.handleClose.bind(this),this.handleScrollTo=this.handleScrollTo.bind(this),this.handleSectionToggle=this.handleSectionToggle.bind(this),this.menuContentRef=a.a.createRef(),this.state={expandedSectionKey:YC.FORMATTING_SECTION_KEY}}componentDidMount(){YC.focusFirstInputInContainer(this.menuContentRef.current)}isSectionExpanded(e){const{expandedSectionKey:t}=this.state;return t===e}handleScrollTo(e,t){this.menuContentRef.current.scrollTo(e,t)}handleSectionToggle(e){this.setState((t=>({expandedSectionKey:t.expandedSectionKey===e?null:e})))}handleClose(){const{onDone:e}=this.props;e()}render(){const e="https://github.com/deephaven/web-client-ui/",t="https://deephaven.io/core/docs/";return Object(DC.jsxs)("div",{className:"app-settings-menu",children:[Object(DC.jsxs)("header",{className:"app-settings-menu-header",children:[Object(DC.jsx)("div",{className:"flex-spacer"}),Object(DC.jsx)("button",{type:"button",className:"btn btn-link btn-link-icon btn-close-settings-menu",onClick:this.handleClose,children:Object(DC.jsx)(Ke.a,{icon:lt,transform:"grow-4"})})]}),Object(DC.jsxs)("div",{className:"app-settings-menu-content",ref:this.menuContentRef,children:[Object(DC.jsx)("h5",{children:"Settings"}),Object(DC.jsx)("hr",{className:"my-0"}),Object(DC.jsx)(_C,{sectionKey:YC.FORMATTING_SECTION_KEY,isExpanded:this.isSectionExpanded(YC.FORMATTING_SECTION_KEY),title:Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsx)(Ke.a,{icon:tn,transform:"grow-4",className:"mr-2"}),"Formatting & Time zone"]}),onToggle:this.handleSectionToggle,children:Object(DC.jsx)(IC,{scrollTo:this.handleScrollTo})}),Object(DC.jsx)(_C,{sectionKey:YC.SHORTCUT_SECTION_KEY,isExpanded:this.isSectionExpanded(YC.SHORTCUT_SECTION_KEY),title:Object(DC.jsxs)(DC.Fragment,{children:[Object(DC.jsx)(Ke.a,{icon:Vt,transform:"grow-2"})," ","Keyboard Shortcuts"]}),onToggle:this.handleSectionToggle,children:Object(DC.jsx)(zC,{})}),Object(DC.jsxs)("div",{className:"app-settings-footer",children:[Object(DC.jsxs)("div",{className:"app-settings-footer-section",children:[Object(DC.jsxs)("div",{className:"app-settings-footer-item",children:[Object(DC.jsx)("div",{className:"font-weight-bold",children:"Support"}),Object(DC.jsxs)("div",{children:["GitHub:\xa0",Object(DC.jsx)("a",{href:e,className:"custom-link",target:"_blank",rel:"noopener noreferrer",children:e})]}),Object(DC.jsx)("button",{type:"button",className:"btn btn-secondary mt-2 py-2",onClick:YC.handleExportSupportLogs,children:"Export Logs"})]}),Object(DC.jsxs)("div",{className:"app-settings-footer-item",children:[Object(DC.jsx)("div",{className:"font-weight-bold",children:"Documentation"}),Object(DC.jsx)("a",{target:"_blank",rel:"noreferrer noopener",href:t,className:"custom-link",children:t})]}),Object(DC.jsx)("div",{className:"app-settings-footer-item",children:Object(DC.jsxs)("div",{className:"text-muted",children:["Version ","0.8.1"]})}),Object(DC.jsx)("div",{className:"app-settings-footer-item",children:Object(DC.jsx)(LC,{})})]}),Object(DC.jsx)("div",{className:"app-settings-footer-section",children:Object(DC.jsx)("div",{className:"logo",children:Object(DC.jsx)("a",{target:"_blank",rel:"noreferrer noopener",href:"https://deephaven.io",className:"d-inline-block custom-link p-1",children:Object(DC.jsx)("img",{src:NC,alt:"Deephaven Data Labs",width:"230px"})})})})]})]})]})}}YC.FORMATTING_SECTION_KEY="SettingsMenu.formatting",YC.APPLICATION_SECTION_KEY="ApplicationMenu.settings",YC.SHORTCUT_SECTION_KEY="SettingsMenu.shortcuts",YC.defaultProps={onDone:()=>{}};var XC=YC;const ZC=e=>{const{forwardedProps:{menuItem:{action:t,title:n,disabled:a},iconElement:s,displayShortcut:r,isMouseSelected:o,isKeyboardSelected:l,closeMenu:c}}=e,h=Object(i.useRef)(),d=Object(i.useRef)(),u=Object(i.useRef)(null),[m,p]=Object(i.useState)(!1),g=Object(i.useCallback)((e=>{u.current&&(Math.abs(h.current-e.clientX)>=10||Math.abs(d.current-e.clientY)>=10)&&(p(!0),window.removeEventListener("mousemove",g),c(),t(e),u.current=null)}),[t,c]);return Object(i.useEffect)((()=>()=>{window.removeEventListener("mousemove",g)}),[g]),Object(DC.jsxs)("button",{type:"button",className:qe()("btn-context-menu",{disabled:a},{active:o&&!a},{"keyboard-active":l&&!a}),onMouseDown:function(e){h.current=e.clientX,d.current=e.clientY,u.current=e.target,window.addEventListener("mousemove",g)},onMouseUp:function(e){u.current===e.target&&(p(!0),c(),t(),window.removeEventListener("mousemove",g)),u.current=null},disabled:m,children:[Object(DC.jsx)("span",{className:qe()("icon"),children:s}),Object(DC.jsx)("span",{className:"title",children:n}),Object(DC.jsx)("span",{className:"shortcut",children:r})]})},$C=e=>{const{handleControlSelect:t,handleToolSelect:n,onClearFilter:a}=e,s=Object(i.useMemo)((()=>[{title:"Input Filter",icon:En,menuElement:Object(DC.jsx)(ZC,{}),action:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;t(MC.INPUT_FILTER,e)},order:10},{title:"Dropdown Filter",icon:_n,menuElement:Object(DC.jsx)(ZC,{}),action:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;t(MC.DROPDOWN_FILTER,e)},order:15},{title:"Markdown Widget",icon:It,menuElement:Object(DC.jsx)(ZC,{}),action:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;t(MC.MARKDOWN,e)},order:20},{title:"Filter Sets",icon:ut,menuElement:Object(DC.jsx)(ZC,{}),action:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;t(MC.FILTER_SET_MANAGER,e)},order:25},{disabled:!0,menuElement:Object(DC.jsx)("div",{className:"context-menu-group-header",children:"Tools"}),order:30},{title:"Linker",icon:Nt,action:()=>{n(ac.LINKER)},order:40,shortcut:Uc.LINKER},{disabled:!0,menuElement:Object(DC.jsx)("div",{className:"context-menu-group-header",children:"Actions"}),order:50},{title:"Clear All Filters",icon:gn,action:()=>{a()},order:60,shortcut:Vp.TABLE.CLEAR_ALL_FILTERS}]),[t,n,a]);return Object(DC.jsx)(nu,{popperClassName:"controls-menu-popper",actions:s})};$C.defaultProps={handleControlSelect:()=>{},handleToolSelect:()=>{},onClearFilter:()=>{}},ZC.defaultProps={forwardedProps:null};var QC=$C,JC={layoutStorage:de(yC,null)};Object.entries(JC).map((e=>{let[t,n]=e;return Ee.register(t,n)}));n(1417),n(1418);var eS=e=>{const{onExportLayout:t,onImportLayout:n,onResetLayout:a,onSelect:s,widgets:r=[]}=e,[o,l]=Object(i.useState)(!1),[c,h]=Object(i.useState)(""),d=Object(i.useRef)(null),u=Object(i.useRef)(),m=Object(i.useCallback)(((e,t)=>{e&&s(e,t)}),[s]),p=Object(i.useCallback)((e=>{h(e.target.value)}),[]),g=Object(i.useCallback)((e=>{null!=u.current&&(Math.abs(u.current.x-e.clientX)>=10||Math.abs(u.current.y-e.clientY)>=10)&&(l(!0),window.removeEventListener("mousemove",g),m(u.current.widget,e),u.current=void 0)}),[u,m]),v=Object(i.useCallback)(((e,t)=>{u.current={x:e.clientX,y:e.clientY,widget:t},window.addEventListener("mousemove",g)}),[g]),f=Object(i.useCallback)(((e,t)=>{var n;window.removeEventListener("mousemove",g),(null===(n=u.current)||void 0===n?void 0:n.widget)===t&&(l(!0),m(t)),u.current=void 0}),[g,u,m]),b=Object(i.useMemo)((()=>r.filter((e=>!c||e.name.toLowerCase().includes(c.toLowerCase())))),[c,r]).sort(((e,t)=>e.name.localeCompare(t.name))),C=Object(i.useMemo)((()=>b.map((e=>Object(DC.jsx)("li",{children:Object(DC.jsxs)("button",{type:"button",className:"btn btn-link","data-testid":"panel-list-item-".concat(e.name,"-button"),onMouseDown:t=>{v(t,e)},onMouseUp:t=>{f(t,e)},onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||m(e)},disabled:o,children:[Object(DC.jsx)(Gh,{type:e.type})," ",e.name]})},e.name)))),[b,o,v,f,m]),S=Object(i.useMemo)((()=>0===C.length?Object(DC.jsx)("span",{children:"No bound variables found."}):null),[C]);return Object(DC.jsxs)("div",{className:"widget-list-container d-flex flex-column",children:[Object(DC.jsx)("div",{className:"widget-list-header",children:Object(DC.jsx)(Gc,{value:c,placeholder:"Find Table, Plot or Widget",onChange:p,ref:d})}),Object(DC.jsxs)("ul",{className:"widget-list flex-grow-1",children:[S&&Object(DC.jsx)("li",{className:"widget-list-message",children:S}),!S&&C]}),Object(DC.jsx)("div",{children:Object(DC.jsx)("hr",{})}),Object(DC.jsxs)("div",{className:"widget-list-footer",children:[Object(DC.jsxs)(gh,{kind:"ghost",onClick:t,children:[Object(DC.jsxs)("div",{className:"fa-md fa-layers",children:[Object(DC.jsx)(Ke.a,{mask:Ht,icon:Xe,transform:"right-5 down-5"}),Object(DC.jsx)(Ke.a,{icon:Xe,transform:"right-8 down-6"})]}),"Export Layout"]}),Object(DC.jsxs)(gh,{kind:"ghost",onClick:n,children:[Object(DC.jsxs)("div",{className:"fa-md fa-layers",children:[Object(DC.jsx)(Ke.a,{mask:Ht,icon:Ze,transform:"right-5 down-5"}),Object(DC.jsx)(Ke.a,{icon:Ze,transform:"right-8 down-6"})]}),"Import Layout"]}),Object(DC.jsx)(gh,{kind:"ghost",icon:zt,onClick:a,tooltip:"Reset Layout"})]})]})};const tS=async(e,t,n)=>{let{settings:i={},table:a="",figure:s="",tableSettings:r={}}=t;if(n&&(n.tableSettings&&(r=n.tableSettings),n.table&&(a=n.table),n.figure&&(s=n.figure),n.settings&&(i={...i,...n.settings})),s){const t={name:s,type:va.VariableType.FIGURE},n=await e.getObject(t);return Vh.makeModel(i,n)}const o={name:a,type:va.VariableType.TABLE},l=await e.getObject(o);return ol.applyTableSettings(l,r,j(Le.getState())),Vh.makeModelFromSettings(i,l)},nS=async(e,t)=>{const{table:n}=t,i={name:n,type:va.VariableType.TABLE},a=await e.getObject(i);return Uu.makeModel(a,!1)};n(1419);var iS=e=>{let{onAutoFillClick:t=(()=>{})}=e;return Object(DC.jsxs)("div",{className:"empty-dashboard-container",children:[Object(DC.jsxs)("div",{className:"hint-container",children:[Object(DC.jsx)(Ke.a,{icon:$e})," ",Object(DC.jsx)("br",{}),"Use the panel list to add objects from a query."]}),Object(DC.jsxs)("div",{className:"empty-dashboard",children:[Object(DC.jsx)("div",{className:"add-panels-hint",children:"Drag Panels Here"}),Object(DC.jsx)(gh,{kind:"tertiary",onClick:t,children:"Auto fill objects"})]})]})};const aS=p.module("UserLayoutUtils"),sS=[{type:"column",content:[{type:"row",content:[{type:"stack",content:[{type:"react-component",component:Xu.COMPONENT,title:Xu.TITLE,isClosable:!1},{type:"react-component",component:cb.COMPONENT,title:cb.TITLE,isClosable:!1}]},{type:"stack",width:25,content:[{type:"react-component",component:Rh.COMPONENT,title:Rh.TITLE,isClosable:!1},{type:"react-component",component:fp.COMPONENT,title:fp.TITLE,isClosable:!1}]}]},{type:"row",content:[{type:"stack",title:"Notebooks",content:[]}]}]}];var rS=async e=>{const t=await e.getLayouts();if(t.length>0)try{return await e.getLayout(t[0])}catch(n){aS.error("Unable to load layout",t[0],":",n),aS.warn("No valid layouts found, falling back to default layout")}return sS};const oS=p.module("DownloadServiceWorkerUtils");class lS{static registerOnLoaded(){new URL(".",window.location.href).origin===window.location.origin&&("serviceWorker"in navigator?window.addEventListener("load",(()=>{const e=new URL("".concat("".concat("/ide/"),"download/serviceWorker.js"),window.location.href);navigator.serviceWorker.register(e).then((t=>{t.update(),oS.info("Registering service worker on ",e,t)})).catch((e=>{oS.error("Failed to register service worker",e)}))})):oS.info("Service worker is not supported."))}static async getServiceWorker(){if("serviceWorker"in navigator){const e=(await navigator.serviceWorker.getRegistrations()).find((e=>e.scope.endsWith(lS.DOWNLOAD_PATH)));if(e&&e.active)return oS.info("Download service worker is active."),e.active;throw new Error("Can not find download service worker.")}throw new Error("Download service worker is not available.")}static unregisterSW(){}}lS.DOWNLOAD_PATH="/download/";var cS=lS,hS=n(730),dS=n(731),uS=n(732);const mS=Object(dS.createRequires)(uS.resolve);var pS=Object(hS.createRemoteComponent)({requires:mS});const gS=p.module("PluginUtils");var vS=class{static loadPlugin(e){if("".split(",").includes(e)){const t=a.a.lazy((()=>n(1442)("./".concat(e)))),s=a.a.forwardRef(((e,n)=>Object(DC.jsx)(i.Suspense,{fallback:Object(DC.jsx)("div",{children:"Loading Plugin..."}),children:Object(DC.jsx)(t,{ref:n,...e})})));return s.pluginName=e,s.displayName="Local Plugin",s}const t=new URL("/ide/plugins/",window.location),s=new URL("".concat(e,".js"),t),r=a.a.forwardRef(((t,n)=>Object(DC.jsx)(pS,{url:s,render:i=>{let{err:a,Component:r}=i;if(a){const t="Error loading plugin ".concat(e," from ").concat(s," due to ").concat(a);return gS.error(t),Object(DC.jsx)("div",{className:"error-message",children:"".concat(t)})}return Object(DC.jsx)(r,{ref:n,...t})}})));return r.pluginName=e,r.displayName="Plugin",r}};const fS=p.module("AppMainContainer"),bS=Object.freeze({});class CS extends i.Component{static handleWindowBeforeUnload(e){e.preventDefault(),e.returnValue=""}constructor(e){super(e),this.handleSettingsMenuHide=this.handleSettingsMenuHide.bind(this),this.handleSettingsMenuShow=this.handleSettingsMenuShow.bind(this),this.handleError=this.handleError.bind(this),this.handleControlSelect=this.handleControlSelect.bind(this),this.handleToolSelect=this.handleToolSelect.bind(this),this.handleClearFilter=this.handleClearFilter.bind(this),this.handleDataChange=this.handleDataChange.bind(this),this.handleAutoFillClick=this.handleAutoFillClick.bind(this),this.handleGoldenLayoutChange=this.handleGoldenLayoutChange.bind(this),this.handleLayoutConfigChange=this.handleLayoutConfigChange.bind(this),this.handleExportLayoutClick=this.handleExportLayoutClick.bind(this),this.handleImportLayoutClick=this.handleImportLayoutClick.bind(this),this.handleImportLayoutFiles=this.handleImportLayoutFiles.bind(this),this.handleResetLayoutClick=this.handleResetLayoutClick.bind(this),this.handleWidgetMenuClick=this.handleWidgetMenuClick.bind(this),this.handleWidgetsMenuClose=this.handleWidgetsMenuClose.bind(this),this.handleWidgetSelect=this.handleWidgetSelect.bind(this),this.handlePaste=this.handlePaste.bind(this),this.hydrateChart=this.hydrateChart.bind(this),this.hydrateGrid=this.hydrateGrid.bind(this),this.goldenLayout=null,this.importElement=a.a.createRef(),this.widgetListenerRemover=null,this.state={contextActions:[{action:()=>{this.handleToolSelect(ac.LINKER)},shortcut:Uc.LINKER,isGlobal:!0},{action:()=>{this.sendClearFilter()},order:50,shortcut:Uc.CLEAR_ALL_FILTERS},{action:()=>{fS.debug("Consume unhandled save shortcut")},shortcut:Uc.SAVE},{action:()=>{this.sendRestartSession()}},{action:()=>{this.sendDisconnectSession()}}],isPanelsMenuShown:!1,isSettingsMenuShown:!1,widgets:[]}}componentDidMount(){this.initWidgets(),window.addEventListener("beforeunload",CS.handleWindowBeforeUnload)}componentDidUpdate(e){const{dashboardData:t}=this.props;e.dashboardData!==t&&this.handleDataChange(t)}componentWillUnmount(){this.deinitWidgets(),window.removeEventListener("beforeunload",CS.handleWindowBeforeUnload)}initWidgets(){const{session:e}=this.props;e.connection.subscribeToFieldUpdates?this.widgetListenerRemover=e.connection.subscribeToFieldUpdates((e=>{fS.debug("Got updates",e),this.setState((t=>{let{widgets:n}=t;const{updated:i,created:a,removed:s}=e,r=[...i,...s],o=n.filter((e=>!r.some((t=>t.name===e.name))));return[...i,...a].forEach((e=>{e.name&&o.push(e)})),{widgets:o}}))})):fS.warn("subscribeToFieldUpdates not supported, not initializing widgets")}deinitWidgets(){var e;null===(e=this.widgetListenerRemover)||void 0===e||e.call(this)}sendClearFilter(){this.emitLayoutEvent(kl.CLEAR_ALL_FILTERS)}emitLayoutEvent(e){for(var t,n=arguments.length,i=new Array(n>1?n-1:0),a=1;a<n;a++)i[a-1]=arguments[a];null===(t=this.goldenLayout)||void 0===t||t.eventHub.emit(e,...i)}handleError(e){Va.isCanceled(e)||fS.error(e)}handleSettingsMenuHide(){this.setState({isSettingsMenuShown:!1})}handleSettingsMenuShow(){this.setState({isSettingsMenuShown:!0})}handleControlSelect(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;switch(fS.debug("handleControlSelect",e),e){case MC.DROPDOWN_FILTER:this.emitLayoutEvent(kl.OPEN_DROPDOWN,{title:"DropdownFilter",type:e,createNewStack:!0,dragEvent:t});break;case MC.INPUT_FILTER:this.emitLayoutEvent(kl.OPEN_INPUT,{title:"InputFilter",type:e,createNewStack:!0,dragEvent:t});break;case MC.MARKDOWN:this.emitLayoutEvent(Hl.OPEN,{title:"Markdown",type:e,dragEvent:t});break;case MC.FILTER_SET_MANAGER:this.emitLayoutEvent(kl.OPEN_FILTER_SET_MANAGER,{title:"FilterSets",type:e,dragEvent:t});break;default:throw new Error("Unrecognized control type",e)}}handleToolSelect(e){fS.debug("handleToolSelect",e);const{activeTool:t,setActiveTool:n}=this.props;n(t===e?ac.DEFAULT:e)}handleClearFilter(){this.sendClearFilter()}handleDataChange(e){const{updateWorkspaceData:t}=this.props,{closed:n,filterSets:i,links:a}=e;t({closed:n,filterSets:i,links:a})}handleGoldenLayoutChange(e){this.goldenLayout=e}handleLayoutConfigChange(e){const{updateWorkspaceData:t}=this.props;t({layoutConfig:e})}handleWidgetMenuClick(){this.setState((e=>{let{isPanelsMenuShown:t}=e;return{isPanelsMenuShown:!t}}))}handleWidgetSelect(e,t){this.setState({isPanelsMenuShown:!1}),fS.debug("handleWidgetSelect",e,t),this.openWidget(e,t)}handleWidgetsMenuClose(){this.setState({isPanelsMenuShown:!1})}handleAutoFillClick(){const{widgets:e}=this.state;fS.debug("handleAutoFillClick",e);const t=e.sort(((e,t)=>e.name.localeCompare(t.name)));for(let n=0;n<t.length;n+=1)this.openWidget(t[n])}handleExportLayoutClick(){fS.info("handleExportLayoutClick"),this.setState({isPanelsMenuShown:!1});try{const{workspace:e}=this.props,{data:t}=e,{layoutConfig:n=[]}=t;fS.info("Exporting layoutConfig",n);const i=new Blob([JSON.stringify(n)],{mimeType:"application/json"}),a=va.i18n.DateTimeFormat.format("yyyy-MM-dd-HHmmss",new Date),s=document.createElement("a");s.href=URL.createObjectURL(i),s.download="deephaven-app-layout-".concat(a,".json"),s.click()}catch(e){fS.error("Unable to export layout",e)}}handleImportLayoutClick(){fS.info("handleImportLayoutClick"),this.setState({isPanelsMenuShown:!1}),this.importElement.current.value="",this.importElement.current.click()}handleResetLayoutClick(){fS.info("handleResetLayoutClick"),this.setState({isPanelsMenuShown:!1}),this.resetLayout()}handleImportLayoutFiles(e){e.stopPropagation(),e.preventDefault(),this.importLayoutFile(e.target.files[0])}async importLayoutFile(e){try{const t=await e.text(),n=JSON.parse(t),{updateWorkspaceData:i}=this.props;i({layoutConfig:n})}catch(t){fS.error("Unable to export layout",t)}}async resetLayout(){const{layoutStorage:e}=this.props,t=await rS(e),{updateWorkspaceData:n}=this.props;n({layoutConfig:t})}handlePaste(e){let t=e.target.parentElement;for(;null!=t;){if(t.classList.contains("monaco-editor"))return;t=t.parentElement}const n=(e.clipboardData||window.clipboardData).getData("Text"),i=/\u201c|\u201d/g;i.test(n)&&(e.preventDefault(),e.stopPropagation(),document.execCommand("insertText",!1,n.replace(i,'"')))}hydrateGrid(e,t){const{session:n}=this.props;return{...e,getDownloadWorker:cS.getServiceWorker,localDashboardId:t,makeModel:()=>nS(n,e.metadata)}}hydrateChart(e,t){const{session:n}=this.props;return{...e,localDashboardId:t,makeModel:()=>{const{metadata:t,panelState:i}=e;return tS(n,t,i)}}}openWidget(e,t){switch(e.type){case va.VariableType.TABLE:{const n={table:e.name};this.emitLayoutEvent(_l.OPEN_GRID,e.name,(()=>{const{session:e}=this.props;return nS(e,n)}),n,ni.a.generate(),t);break}case va.VariableType.FIGURE:{const n={figure:e.name};this.emitLayoutEvent(Dl.OPEN,e.name,(()=>{const{session:e}=this.props;return tS(e,n)}),n,ni.a.generate(),t);break}default:fS.error("Unexpected widget type",e)}}render(){const{activeTool:e,user:t,workspace:n}=this.props,{data:i={}}=n,{data:a=bS,layoutConfig:s}=i,{layoutSettings:r=bS}=a,{permissions:o}=t,{canUsePanels:l}=o,{contextActions:c,isPanelsMenuShown:h,isSettingsMenuShown:d,widgets:u}=this.state;return Object(DC.jsxs)("div",{className:qe()("app-main-tabs","w-100","h-100","d-flex","flex-column",e?"active-tool-".concat(e.toLowerCase()):""),onPaste:this.handlePaste,tabIndex:-1,children:[Object(DC.jsx)("nav",{className:"nav-container",children:Object(DC.jsxs)("div",{className:"app-main-top-nav-menus",children:[Object(DC.jsx)("img",{src:NC,alt:"Deephaven Data Labs",width:"115px",className:"ml-1"}),Object(DC.jsxs)("div",{children:[Object(DC.jsxs)("button",{type:"button",className:"btn btn-link btn-panels-menu",children:[Object(DC.jsx)(Ke.a,{icon:Nn}),"Controls",Object(DC.jsx)(QC,{handleControlSelect:this.handleControlSelect,handleToolSelect:this.handleToolSelect,onClearFilter:this.handleClearFilter})]}),l&&Object(DC.jsxs)("button",{type:"button",className:"btn btn-link btn-panels-menu btn-show-panels","data-testid":"app-main-panels-button",onClick:this.handleWidgetMenuClick,children:[Object(DC.jsx)(Ke.a,{icon:yn}),"Panels",Object(DC.jsx)(El,{isShown:h,className:"panels-menu-popper",onExited:this.handleWidgetsMenuClose,closeOnBlur:!0,interactive:!0,children:Object(DC.jsx)(eS,{widgets:u,onExportLayout:this.handleExportLayoutClick,onImportLayout:this.handleImportLayoutClick,onResetLayout:this.handleResetLayoutClick,onSelect:this.handleWidgetSelect})})]}),Object(DC.jsxs)("button",{type:"button",className:qe()("btn btn-link btn-link-icon btn-settings-menu",{"text-warning":t.operateAs!==t.name}),onClick:this.handleSettingsMenuShow,children:[Object(DC.jsx)(Ke.a,{icon:Et,transform:"grow-3 right-1 down-1"}),Object(DC.jsx)(Ol,{children:"User Settings"})]})]})]})}),Object(DC.jsxs)(ha,{emptyDashboard:Object(DC.jsx)(iS,{onAutoFillClick:this.handleAutoFillClick}),id:da,layoutConfig:s,layoutSettings:r,onGoldenLayoutChange:this.handleGoldenLayoutChange,onLayoutConfigChange:this.handleLayoutConfigChange,children:[Object(DC.jsx)(Kb,{hydrate:this.hydrateGrid,getDownloadWorker:cS.getServiceWorker,loadPlugin:vS.loadPlugin}),Object(DC.jsx)(Vb,{hydrate:this.hydrateChart}),Object(DC.jsx)(Bb,{}),Object(DC.jsx)(qb,{}),Object(DC.jsx)(EC,{}),Object(DC.jsx)(SC,{}),Object(DC.jsx)(vC,{})]}),Object(DC.jsx)(We.CSSTransition,{in:d,timeout:Kn.transitionMidMs,classNames:"slide-left",mountOnEnter:!0,unmountOnExit:!0,children:Object(DC.jsx)(XC,{onDone:this.handleSettingsMenuHide})}),Object(DC.jsx)(vl,{actions:c}),Object(DC.jsx)("input",{ref:this.importElement,type:"file",accept:".json",style:{display:"none"},onChange:this.handleImportLayoutFiles})]})}}var SS=Object(o.b)((e=>{return{activeTool:U(e),dashboardData:Wi(e,da),layoutStorage:(t=e,t.layoutStorage),session:Tc(e,da).session,user:L(e),workspace:P(e)};var t}),{setActiveTool:te,updateWorkspaceData:J})(CS);var ES,wS=()=>Object(DC.jsxs)("div",{className:"app",children:[Object(DC.jsx)(SS,{}),Object(DC.jsx)(Hf,{})]});!function(e){e.ASC="asc",e.DESC="desc"}(ES||(ES={}));p.module("StorageTableViewportUpdater");class yS{static makeSortConfig(e,t){return{column:e,direction:t}}static makeFilterConfig(e){var t=[],n=[];return e.forEach(((e,i)=>{t.push(e),i>0&&n.push(ss.and)})),{filterItems:t,filterOperators:n}}static combineFilterConfigs(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ss.and;return{filterItems:[...e.filterItems,...t.filterItems],filterOperators:[...e.filterOperators,n,...t.filterOperators]}}static makeFilterItem(e,t,n){return{columnName:e,type:t,value:n}}}var TS=n(491),OS=n(737);const MS=p.module("PouchStorageTable");function NS(e,t){switch(e){case ns.in:case ns.contains:return{$regex:new RegExp("".concat(t))};case ns.inIgnoreCase:return{$regex:new RegExp("".concat(t),"i")};case ns.eq:return{$eq:t};case ns.notEq:return{$neq:t};case ns.greaterThan:return{$gt:t};case ns.greaterThanOrEqualTo:return{$gte:t};case ns.lessThan:return{$lt:t};case ns.lessThanOrEqualTo:return{$lte:t};case ns.startsWith:return{$regex:new RegExp("^(?".concat(t,").*"))};default:throw new Error("Unsupported type: ".concat(e))}}function DS(e){const{filterItems:t,filterOperators:n}=e;let i=null;for(let a=0;a<t.length;a+=1){const e=t[a],{columnName:s,type:r,value:o}=e,l={[s]:NS(r,o)};if(0===a)i=l;else if(null!==i&&a-1<n.length){const e=n[a-1];if(e===ss.and)i={$and:[i,l]};else{if(e!==ss.or)throw new Error("Unexpected filter operator ".concat(e,", ").concat(l));i={$or:[i,l]}}}}if(null==i)throw new Error("Invalid filter config ".concat(e));return i}function xS(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{$and:[...e.map((e=>DS(e))),{name:{$gt:null}},{id:{$gt:null}}]}}TS.a.plugin(OS.a);var RS=class{constructor(e){this.listeners=[],this.itemListeners=new Map,this.currentSize=0,this.currentReverse=!1,this.currentFilter=null,this.currentSort=null,this.db=new TS.a("".concat("Deephaven.").concat(e)),this.db.changes({live:!0,since:"now",include_docs:!0}).on("change",this.dbUpdate.bind(this)),this.db.createIndex({index:{fields:["id","name"]}}),this.refreshInfo()}onUpdate(e){return this.listeners=[...this.listeners,e],()=>{this.listeners=this.listeners.filter((t=>t!==e))}}onItemUpdate(e,t){return this.itemListeners.has(e)||this.itemListeners.set(e,[]),this.itemListeners.set(e,[...this.itemListeners.get(e),t]),this.refreshItem(e),()=>{this.itemListeners.set(e,this.itemListeners.get(e).filter((e=>e!==t)))}}close(){this.listeners=[]}get size(){return this.currentSize}get viewport(){return this.currentViewport}setReversed(e){this.currentReverse=e,this.currentViewportData=void 0,this.refreshData()}setViewport(e){this.currentViewport=e,this.refreshInfo(),this.refreshData()}setSorts(e){this.currentSort=e,this.currentViewportData=void 0,this.refreshData()}setFilters(e){this.currentFilter=e,this.currentViewportData=void 0,this.refreshInfo(),this.refreshData()}get data(){return this.currentViewportData}async getViewportData(){var e;return this.viewportUpdatePromise||this.refreshData(),null!==(e=this.viewportUpdatePromise)&&void 0!==e?e:Promise.resolve({items:[],offset:0})}async put(e){const t={...e,_id:e.id};return await this.db.put(t),t}sendUpdate(){var e;const{listeners:t}=this,n=null!==(e=this.currentViewportData)&&void 0!==e?e:{items:[],offset:0};for(let i=0;i<t.length;i+=1)t[i](n)}sendItemUpdate(e){const t=this.itemListeners.get(e.id);if(void 0!==t)for(let n=0;n<t.length;n+=1)t[n](e)}dbUpdate(e){MS.debug("Update received",e),this.refreshInfo(),void 0!==e.doc&&this.sendItemUpdate(e.doc),this.refreshData()}async refreshInfo(){try{var e,t;null===(e=this.infoUpdatePromise)||void 0===e||e.cancel(),this.infoUpdatePromise=Va.makeCancelable(this.db.find({selector:xS(null!==(t=this.currentFilter)&&void 0!==t?t:[]),fields:[]}));const n=await this.infoUpdatePromise;this.currentSize=n.docs.length,this.sendUpdate()}catch(n){if(!Va.isCanceled(n))throw MS.error("Unable to refreshInfo",n),n}}async refreshData(){if(this.currentViewport)try{var e,t;const{currentViewport:n}=this,i=function(e){var t;return[{id:arguments.length>1&&void 0!==arguments[1]&&arguments[1]?"desc":"asc"},...null!==(t=null===e||void 0===e?void 0:e.map((e=>({[e.column]:e.direction}))))&&void 0!==t?t:[]]}(this.currentSort,this.currentReverse);null===(e=this.viewportUpdatePromise)||void 0===e||e.cancel(),this.viewportUpdatePromise=Va.makeCancelable(this.db.find({selector:xS(null!==(t=this.currentFilter)&&void 0!==t?t:[]),skip:n.top,limit:n.bottom-n.top+1,sort:i,fields:["id","name"]}).then((e=>({items:e.docs,offset:n.top}))));const a=await this.viewportUpdatePromise;return this.currentViewportData=a,this.sendUpdate(),a}catch(n){if(!Va.isCanceled(n))throw MS.error("Unable to refreshData",n),n}}async refreshItem(e){const t=(await this.db.find({selector:{id:e},limit:1})).docs[0];return void 0!==t&&this.sendItemUpdate(t),t}async getSnapshot(e){const t=new Map,n=[{id:this.currentReverse?"desc":"asc"}];return await Promise.all(e.map((async e=>{var i;let[a,s]=e;const r=s-a+1;return this.db.find({selector:xS(null!==(i=this.currentFilter)&&void 0!==i?i:[]),skip:a,limit:r,sort:n,fields:["id","name"]}).then((e=>{for(let n=0;n<r;n+=1){const i=a+n;t.set(i,e.docs[n])}}))}))),t}};var IS=class extends RS{constructor(e){super("CommandHistoryStorage.".concat(e))}setSearch(e){this.setFilters(e?[yS.makeFilterConfig([yS.makeFilterItem("name",ns.contains,e)])]:[])}};const LS=p.module("PouchCommandHistoryStorage");var FS=class{constructor(){this.updateTableMap=new Map}getUpdateTable(e){return this.updateTableMap.has(e)||this.updateTableMap.set(e,new IS(e)),this.updateTableMap.get(e)}async getTable(e){return new IS(e)}async addItem(e,t,n,i){return this.updateItem(e,{id:"".concat((new Date).getTime()),name:n,data:i})}async updateItem(e,t){const n=this.getUpdateTable(e),i=await n.refreshItem(t.id),a={...null!==i&&void 0!==i?i:{},...t};return LS.debug("Updating item",a),await n.put(a),LS.debug("Update saved"),t}listenItem(e,t,n){return this.getUpdateTable(e).onItemUpdate(t,n)}};const kS=p.module("LocalWorkspaceStorage");class AS{static makeDefaultWorkspaceData(){return{settings:{defaultDateTimeFormat:Ds.DEFAULT_DATETIME_FORMAT_STRING,formatter:[],timeZone:Ds.DEFAULT_TIME_ZONE_ID,showTimeZone:!1,showTSeparator:!0,disableMoveConfirmation:!1}}}static makeDefaultWorkspace(){return{data:AS.makeDefaultWorkspaceData()}}async load(){try{var e;return JSON.parse(null!==(e=localStorage.getItem(AS.STORAGE_KEY))&&void 0!==e?e:"")}catch(t){return kS.info("Unable to load workspace data, initializing to default data"),AS.makeDefaultWorkspace()}}async save(e){return localStorage.setItem(AS.STORAGE_KEY,JSON.stringify(e)),e}}AS.STORAGE_KEY="deephaven.WorkspaceStorage";var PS=AS;var _S=class{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/";this.client=e,this.root=t}async getLayouts(){return(await this.client.getDirectoryContents(this.root,{glob:"*.json"})).map((e=>e.basename))}async getLayout(e){const t=await this.client.getFileContents("".concat(this.root).concat(e),{format:"text"});return JSON.parse(t)}};const HS=p.module("SessionUtils"),jS=async()=>{var e;const t=new URL(null!==(e="/jsapi")?e:"","".concat(window.location)),n="".concat(t.protocol,"//").concat(t.host);HS.info("Starting connection to '".concat(n,"'..."));const i=new va.IdeConnection(n);HS.info("Getting console types...");const a=await i.getConsoleTypes();if(HS.info("Available types:",a),0===a.length)throw new Error("No console types available");const s=a[0];HS.info("Starting session with type",s);const r=await i.startSession(s),o={type:s,id:ni.a.generate()};return HS.info("Console session established",o),{session:r,config:o,connection:i}};var VS,zS;const US=p.module("AppInit"),BS="user",WS={name:BS,operateAs:BS,groups:[],permissions:{isSuperUser:!1,isQueryViewOnly:!1,isNonInteractive:!1,canUsePanels:!0,canCreateDashboard:!0,canCreateCodeStudio:!0,canCreateQueryMonitor:!0,canCopy:!0,canDownloadCsv:!0}},GS=new PS,qS=new FS,KS=new dp(Object(wC.createClient)(null!==(VS="/notebooks")?VS:"")),YS=new _S(Object(wC.createClient)(null!==(zS="/layouts")?zS:"")),XS=e=>{const{workspace:t,setActiveTool:n,setCommandHistoryStorage:a,setDashboardData:s,setFileStorage:r,setLayoutStorage:o,setDashboardSessionWrapper:l,setUser:c,setWorkspace:h,setWorkspaceStorage:d}=e,[u,m]=Object(i.useState)(),[p,g]=Object(i.useState)(!0),v=Object(i.useCallback)((async()=>{try{var e,t;const i=await GS.load(),u=await jS();u.connection.addEventListener(va.IdeConnection.HACK_CONNECTION_FAILURE,(e=>{var t;const{detail:n}=e;US.error("Connection failure",n),m("Unable to connect: ".concat(null!==(t=n.details)&&void 0!==t?t:"Unknown Error"))}));const{data:p}=i;if(null==p.layoutConfig){const e=await rS(YS);p.layoutConfig=e}const{settings:g}=p,{shortcutOverrides:v={}}=g,f=ze.isMacPlatform?null!==(e=v.mac)&&void 0!==e?e:{}:null!==(t=v.windows)&&void 0!==t?t:{};Object.entries(f).forEach((e=>{var t;let[n,i]=e;null===(t=Be.get(n))||void 0===t||t.setKeyState(i)})),n(ac.DEFAULT),a(qS),s(da,p),r(KS),o(YS),l(da,u),c(WS),d(GS),h(i)}catch(i){m(i)}}),[n,a,s,r,o,l,c,h,d]),f=Object(i.useCallback)((()=>{document.fonts?document.fonts.ready.then((()=>{g(!1)})):g(!1)}),[]);Object(i.useEffect)((()=>{v(),f()}),[v,f]);const b=!t&&!u||p,C=!b&&!u,S=u?"".concat(u):null;return Object(DC.jsxs)(DC.Fragment,{children:[C&&Object(DC.jsx)(wS,{}),Object(DC.jsx)(Xn,{isLoading:b,isLoaded:C,errorMessage:S}),Object(DC.jsxs)("div",{id:"preload-fonts",style:{visibility:"hidden",position:"absolute",top:-1e4},children:[Object(DC.jsx)("p",{className:"fira-sans-regular",children:"preload"}),Object(DC.jsx)("p",{className:"fira-sans-semibold",children:"preload"}),Object(DC.jsx)("p",{className:"fira-mono",children:"preload"})]})]})};XS.defaultProps={workspace:null,workspaceStorage:null};var ZS=Object(o.b)((e=>{return{workspace:P(e),workspaceStorage:(t=e,F(t).workspaceStorage)};var t}),{setActiveTool:te,setCommandHistoryStorage:e=>({type:W,payload:e}),setDashboardData:Zi,setFileStorage:e=>({type:G,payload:e}),setLayoutStorage:e=>({type:yC,payload:e}),setDashboardSessionWrapper:(e,t)=>n=>n($i(e,{sessionWrapper:t})),setUser:e=>({type:q,payload:e}),setWorkspace:Q,setWorkspaceStorage:e=>({type:Y,payload:e})})(XS);class $S extends i.Component{static renderAlert(e){return Object(DC.jsxs)("div",{className:qe()("alert","alert-".concat(e)),children:[Object(DC.jsx)("strong",{children:"Well done!"}),"You successfully read this ",e," alert message."]},e)}render(){const e=["success","info","warning","danger"].map((e=>$S.renderAlert(e)));return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Alerts"}),Object(DC.jsx)("div",{style:{padding:"1rem 0"},children:e})]})}}var QS=$S;class JS extends i.Component{static renderButtonBrand(e,t){const n=e.length?"btn-".concat(e,"-").concat(t):"btn-".concat(t);return Object(DC.jsx)(Dc,{className:n,style:{marginBottom:"1rem",marginRight:"1rem"},children:t},t)}static renderButtons(e){const t=["primary","secondary","success","info","danger"].map((t=>JS.renderButtonBrand(e,t)));return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h5",{children:e.length?"Outline":"Regular"}),t]},e)}static renderSocketedButtons(){return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h5",{children:"Socketed Buttons (for linker)"}),Object(DC.jsx)(Lc,{style:{marginBottom:"1rem",marginRight:"1rem"},children:"Unlinked"}),Object(DC.jsx)(Lc,{style:{marginBottom:"1rem",marginRight:"1rem"},isLinked:!0,children:"Linked"}),Object(DC.jsx)(Lc,{style:{marginBottom:"1rem",marginRight:"1rem"},isLinkedSource:!0,children:"Linked Source"}),Object(DC.jsx)(Lc,{style:{marginBottom:"1rem",marginRight:"1rem"},isLinked:!0,isInvalid:!0,children:"Error"}),Object(DC.jsx)(Lc,{style:{marginBottom:"1rem",marginRight:"1rem"},disabled:!0,children:"Disabled"})]})}constructor(e){super(e),this.state={toggle:!0}}renderInlineButtons(){const{toggle:e}=this.state;return Object(DC.jsxs)("div",{style:{padding:"1rem 0"},children:[Object(DC.jsx)("h5",{children:"Inline Buttons"}),"Regular btn-inline:",Object(DC.jsx)(Dc,{className:"btn-inline mx-2",children:Object(DC.jsx)(Ke.a,{icon:Hn})}),"Toggle button (class active):",Object(DC.jsx)(Dc,{className:qe()("btn-inline mx-2",{active:e}),onClick:()=>{this.setState({toggle:!e})},children:Object(DC.jsx)(Ke.a,{icon:Hn})}),"Disabled:",Object(DC.jsx)(Dc,{className:"btn-inline mx-2",disabled:!0,children:Object(DC.jsx)(Ke.a,{icon:Hn})}),Object(DC.jsx)("br",{}),Object(DC.jsx)("br",{}),Object(DC.jsx)("span",{children:"btn-link-icon (no text):"}),Object(DC.jsx)(Dc,{className:"btn-link btn-link-icon px-2",children:Object(DC.jsx)(Ke.a,{icon:Hn})}),Object(DC.jsx)("span",{className:"mx-2",children:"btn-link:"}),Object(DC.jsx)(Dc,{className:"btn-link",children:"Text Button"}),Object(DC.jsx)("span",{className:"mx-2",children:"btn-link (text w/ optional with icon):"}),Object(DC.jsxs)(Dc,{className:"btn-link",children:[Object(DC.jsx)(Ke.a,{icon:Hn}),"Add Item"]})]})}render(){const e=["","outline"].map((e=>JS.renderButtons(e))),t=this.renderInlineButtons(),n=JS.renderSocketedButtons();return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Buttons"}),Object(DC.jsxs)("div",{style:{padding:"1rem 0"},children:[e,t,n]})]})}}var eE=JS;class tE extends ir{static makeRandomSeries(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100,i=[],a=[],s=[],r=[],o=new Date,l=0;l<n;l+=1){var c=new Date(o.getFullYear(),o.getMonth(),o.getDate()+l-n);i.push("".concat(c.getFullYear(),"-").concat(c.getMonth()+1,"-").concat(c.getDate()));var h=(Math.sin(l/n*e)*n/3+Math.cos(.2*l)*n/6+Math.sin(.5*l)*n/10+Math.random()*n/5+l*tE.smoothing)*t;h=Math.round(100*h)/100,a.push(h),r.push(40+l*tE.smoothing),s.push(Math.sin(l/n*e)*n/3+Math.random()*n/10+l*tE.smoothing)}return{x:i,y:a,s:s,l:r}}static makeScatter(e){return{name:"SCTR",x:e.x,y:e.y,type:"scattergl",mode:"markers",hoverinfo:"skip",marker:{size:5}}}static makeArea(e){return{name:"AREA",x:e.x,y:e.s,type:"scatter",mode:"line",fill:"tozeroy",hoverinfo:"all",line:{color:_h.area_color,width:3}}}static makeTrendline(e){return{name:"Trendline <br>R<sup>2</sup> = 0.91",x:e.x,y:e.l,type:"scattergl",mode:"line",hoverinfo:"skip",line:{width:3,dash:"dot",color:_h.trend_color}}}static makeErrorBand(e){for(var t=[],n=[],i=0;i<e.y.length;i+=1){var a=e.y[i];t[i]=Math.round(100*(a+18))/100,n[i]=Math.round(100*(a-18))/100}var s=t.concat(n.reverse());return{name:"error",x:e.x.concat(e.x.slice().reverse()),y:s,type:"scattergl",mode:"line",hoverinfo:"skip",fill:"toself",fillcolor:_h.error_band_fill_color,line:{width:0,color:_h.error_band_line_color,shape:"spline"}}}static makeLine(e){return{name:"LINE",x:e.x,y:e.y,type:"scattergl",mode:"line",hoverinfo:"x+y+text+name",line:{color:_h.line_color,width:3}}}static makeRandomData(){var e=tE.makeRandomSeries(6),t=tE.makeArea(e),n=tE.makeTrendline(e),i=tE.makeRandomSeries(2);return[t,n,tE.makeLine(i),tE.makeErrorBand(i)]}static makeDefaultLayout(){var e=fs.makeDefaultLayout(_h);return e.title="Chart",e.xaxis.title="Datestamp",e.yaxis.title="Price",e}constructor(){var{data:e=tE.makeRandomData(),layout:t=tE.makeDefaultLayout(),filterFields:n=[]}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super(),this.data=e,this.layout=t,this.filterFields=n}getData(){return this.data}getLayout(){return this.layout}getFilterColumnMap(){for(var e=new Map,t=0;t<this.filterFields.length;t+=1){var n=this.filterFields[t];e.set(n,{name:n,type:"java.lang.String"})}return e}isFilterRequired(){return this.filterFields.length>0}setFilter(){this.fireUpdate(this.data)}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(tE,"smoothing",1.5);var nE=tE;class iE extends i.PureComponent{constructor(e){super(e),this.state={model:new nE}}render(){const{model:e}=this.state;return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Chart"}),Object(DC.jsx)("div",{style:{height:500},children:Object(DC.jsx)(ur,{model:e})})]})}}var aE=iE;var sE=()=>{const e=["100","200","300","400","500","600","700","800","900"].map((e=>Object(DC.jsxs)("div",{className:qe()("swatch","gray-swatch","gray-swatch-".concat(e)),children:["Gray-",e]},e))),t=["red","orange","yellow","green","blue","purple","white","black","content-bg","primary","primary-dark","background","foreground"].map((e=>Object(DC.jsx)("div",{className:qe()("swatch","swatch-".concat(e)),children:e},e)));return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Colors"}),Object(DC.jsxs)("div",{className:"row",children:[Object(DC.jsx)("div",{className:"col",children:e}),Object(DC.jsx)("div",{className:"col",children:t}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("p",{children:"Gray Range is available for background/tab colors, and should cover the full range used in mockups. Always use the semantic color names in your .scss files when applicable for UI elements."}),Object(DC.jsx)("p",{children:"For refrence key colors are $primary for interactable elements, content-bg as background. White is same as gray-200. Gray-100 is used when white needs an active color. content-bg is between 800 and 900."}),Object(DC.jsx)("pre",{children:"\n// as semantic colours\n$primary: $interfaceblue;\n$secondary: $gray-600;\n$content-bg: $interfacegray;\n$foreground: $interfacewhite;\n$background: $interfaceblack;\n$success: $green;\n$info: $yellow;\n$warning: $orange;\n$danger: $red;\n"})]})]})]})};class rE extends i.Component{constructor(e){super(e),this.makeContextMenuItems=this.makeContextMenuItems.bind(this)}makeContextMenuItems(e){const t=e?" ".concat(e):"";return[{title:"Show Alert".concat(t),icon:Qe,action:()=>{alert("Alert".concat(t,"!"))},shortcut:new ze({id:"STYLEGUIDE.SHOW_ALERT",name:"Show Alert",shortcut:[_e.CTRL,He.A],macShortcut:[_e.CMD,He.A]})},{title:"Log Message".concat(t),icon:dn,action:()=>{console.log("Logging a message".concat(t,"!"))},shortcut:new ze({id:"STYLEGUIDE.LOG_MESSAGE",name:"Log Message",shortcut:[_e.CTRL,He.L],macShortcut:[_e.CMD,He.L]})},{title:"Sub-menu",actions:()=>this.makeContextMenuItems((e||0)+1),order:3}].concat(new Array(10).fill({title:"Disabled Option".concat(t),disabled:!0,order:2}))}render(){const e=this.makeContextMenuItems(),t=[{title:"Show Shortcuts",icon:jt,action:()=>{alert("Show keyboard shortcuts!")},shortcut:new ze({id:"STYLEGUIDE.SHOW_SHORTCUTS",name:"Show Shortcuts",shortcut:[_e.CTRL,He.SLASH],macShortcut:[_e.CMD,He.SLASH]}),group:vl.groups.global}].concat(e);return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Context Menu"}),Object(DC.jsxs)("button",{type:"button",className:"btn btn-primary",style:{cursor:"default",marginBottom:"1rem",marginRight:"1rem"},children:["Right Click Me",Object(DC.jsx)(vl,{actions:t})]}),Object(DC.jsxs)("button",{type:"button",className:"btn btn-secondary",style:{cursor:"default",marginBottom:"1rem",marginRight:"1rem"},children:["Right Click Me",Object(DC.jsx)(vl,{actions:()=>new Promise((t=>{setTimeout((()=>{t(e)}),3e3)}))})]})]})}}var oE=rE;n(1455);class lE extends i.Component{static isParentSelected(e,t){var n=t.get(e);if(void 0===n)return!1;if("boolean"===typeof n)return n;var i=Array.from(n.values()).includes(!0),a=Array.from(n.values()).includes(!1);return i&&a?null:i}constructor(e){super(e),this.toggleMenu=this.toggleMenu.bind(this),this.toggleValueFor=this.toggleValueFor.bind(this),this.selectAll=this.selectAll.bind(this),this.clear=this.clear.bind(this),this.state={menuIsOpen:!1}}toggleMenu(e){e.stopPropagation(),e.preventDefault(),this.setState((e=>{var{menuIsOpen:t}=e;return{menuIsOpen:!t}}))}toggleValueFor(e,t){var{valueMap:n,onUpdateValueMap:i}=this.props,a=new Map(n),s=a.get(e);if(s instanceof Map){var r=new Map(s);if(null!=t)r.set(t,!s.get(t));else{var o=!lE.isParentSelected(e,a);s.forEach(((e,t)=>r.set(t,o)))}a.set(e,r)}else a.set(e,!s);var l=a.get(e);void 0===t&&void 0!==l&&"boolean"!==typeof l&&(lE.isParentSelected(e,n)?l.forEach(((e,t)=>l.set(t,!1))):l.forEach(((e,t)=>l.set(t,!0)))),i(a)}setAllValues(e){var{valueMap:t,onUpdateValueMap:n}=this.props,i=new Map;t.forEach(((t,n)=>{if("boolean"===typeof t)i.set(n,e);else{var a=new Map;t.forEach(((t,n)=>a.set(n,e))),i.set(n,a)}})),n(i)}selectAll(){this.setAllValues(!0)}clear(){this.setAllValues(!1)}renderMenuElement(){var{valueMap:e}=this.props;return a.a.createElement("div",{className:"hcm-menu-container"},Array.from(e.entries()).map((t=>{var[n,i]=t;return a.a.createElement("div",{key:n},a.a.createElement(Ed,{className:"hcm-parent",checked:lE.isParentSelected(n,e),onChange:()=>this.toggleValueFor(n)},n),void 0!==i&&"boolean"!==typeof i&&Array.from(i.entries()).map((e=>{var[t,i]=e;return a.a.createElement(Ed,{className:"hcm-child",key:t,checked:i,onChange:()=>this.toggleValueFor(n,t)},t)})))})),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.selectAll},"Select All"),a.a.createElement("button",{type:"button",className:"btn btn-link",onClick:this.clear},"Clear"))}render(){var{menuText:e,className:t,icon:n,id:i}=this.props,{menuIsOpen:s}=this.state;return a.a.createElement("button",{type:"button",className:qe()("btn hcm-btn",t),onClick:this.toggleMenu,id:i},a.a.createElement("span",null,n&&a.a.createElement(Ke.a,{icon:n,className:"hcm-icon mr-1"}),e),a.a.createElement(Ke.a,{icon:Fn,className:"hcm-icon ml-1"}),a.a.createElement(El,{options:{placement:"bottom"},isShown:s,onExited:()=>{this.setState({menuIsOpen:!1})},closeOnBlur:!0,interactive:!0},this.renderMenuElement()))}}!function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(lE,"defaultProps",{className:"",icon:null,id:""});var cE=lE;class hE extends i.Component{constructor(e){super(e),this.sampleInput=a.a.createRef(),this.handleUpdateCheckboxMap=this.handleUpdateCheckboxMap.bind(this),this.state={isShown:!1,checkBoxMap:new Map([["Parent A",new Map([["Child 1",!0],["Child 2",!1]])],["Parent B",new Map([["Child 3",!0],["Child 4",!1],["Child 5",!0],["Child 6",!1]])],["Leaf Parent",!0]])}}handleUpdateCheckboxMap(e){this.setState({checkBoxMap:e})}renderChild(){return Object(DC.jsxs)("div",{className:"p-3",children:[Object(DC.jsx)("h4",{children:"Sample Child"}),Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsxs)("label",{htmlFor:"exampleInput1",children:["Input Label",Object(DC.jsx)("input",{ref:this.sampleInput,type:"text",className:"form-control",id:"exampleInput1","aria-describedby":"emailHelp",placeholder:"Input Placeholder"})]}),Object(DC.jsx)("small",{className:"form-text text-muted",children:"Help text for a form imput"})]})]})}render(){const{isShown:e,checkBoxMap:t}=this.state;return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Popover Dialog"}),Object(DC.jsx)("p",{children:"Popover dialog that can contain interactive elements, can be set to self close on blur."}),Object(DC.jsxs)("button",{type:"button",className:"btn btn-primary",style:{marginBottom:"1rem",marginRight:"1rem"},onClick:()=>{e?this.setState({isShown:!1}):this.setState({isShown:!0})},children:["Open Dialog",Object(DC.jsx)(El,{options:{placement:"bottom"},isShown:e,onEntered:()=>{this.sampleInput.current.focus()},onExited:()=>{this.setState({isShown:!1})},closeOnBlur:!0,interactive:!0,children:this.renderChild()})]}),Object(DC.jsx)("p",{children:"The Hierarchical Checkbox Menu uses a popover dialog to display hierarchical groups of checkboxes."}),Object(DC.jsx)(cE,{menuText:"Checkbox Menu",valueMap:t,onUpdateValueMap:this.handleUpdateCheckboxMap})]})}}var dE=hE;class uE extends i.Component{constructor(e){super(e),this.state={isShown:!1}}render(){const e=[{title:"Show Alert",icon:Qe,action:()=>{alert("Alert!")},shortcut:new ze({id:"STYLEGUIDE.SHOW_ALERT",name:"Show Alert",shortcut:[_e.CTRL,He.A],macShortcut:[_e.CMD,He.A]})},{title:"Log Message",icon:dn,action:()=>{console.log("Logging a message!")},shortcut:new ze({id:"STYLEGUIDE.LOG_MESSAGE",name:"Log Message",shortcut:[_e.CTRL,He.L],macShortcut:[_e.CMD,He.L]})}],t=[{title:"Show Shortcuts",icon:jt,action:()=>{alert("Show keyboard shortcuts!")},shortcut:new ze({id:"STYLEGUIDE.SHOW_SHORTCUTS",name:"Show Shortcuts",shortcut:[_e.CTRL,He.SLASH],macShortcut:[_e.CMD,He.SLASH]}),group:vl.groups.global}].concat(e),{isShown:n}=this.state;return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Dropdown Menu"}),Object(DC.jsx)("p",{children:"A simple dropdown menu of actions, can open on click of parent container, or controlled by prop."}),Object(DC.jsxs)("button",{type:"button",className:"btn btn-inline mx-2",children:[Object(DC.jsx)(Ke.a,{icon:Ot}),Object(DC.jsx)(nu,{actions:t})]}),Object(DC.jsxs)("button",{type:"button",className:"btn btn-primary",style:{marginRight:"1rem",minWidth:"165px"},onClick:()=>{n?this.setState({isShown:!1}):this.setState({isShown:!0})},children:["Menu Shown: ",n.toString()]}),Object(DC.jsxs)("div",{ref:this.button,className:"btn btn-secondary disabled",style:{marginRight:"1rem"},children:["Shown using isShown",Object(DC.jsx)(nu,{isShown:n,onMenuClosed:()=>{this.setState({isShown:!1})},actions:t})]})]})}}var mE=uE;var pE='trades = db.t("LearnDeephaven", "StockTrades").where("Date=`2017-08-25`")\\\n .headBy(3, "Sym")\\\n .view("Sym", "Last")\n\nsummary = trades.view("Sym", "AvgPrice=Last").avgBy("Sym")\n\nlj = summary.leftJoin(trades, "Sym", "Last")\n\n\n\ndef rollingAvg(rows, values):\n calculations = jpy.array(\'double\', values.size()) # create an array of integers\n\n sum = 0\n n = 0\n avg = 0\n\n for i in range(values.size()):\n sum += values.get(i) #add each value to sum\n if (i >= rows): sum -= values.get(i - rows) #subtract when needed\n\n n = i + 1 if (i < rows) else rows #n increments with i until i=rows\n avg = sum / n #get updated average every iteration\n\n calculations[i] = avg #store running average\n\n return calculations #return an array of rolling averages\n\ndef rollingStd(rows, values, averages):\n calculations = jpy.array(\'double\', values.size()) # create an array of integers\n\n sum = 0\n n = 0\n\n for i in range(values.size()):\n sum = 0\n\n j = i\n while j >= 0 and j > i - rows:\n difference = values.get(j) - averages[i]\n squareDiff = difference ** 2\n sum += squareDiff\n j -= 1\n\n n = i + 1 if (i < rows) else rows\n variance = sum / n\n standardDev = variance ** (1/2.0)\n calculations[i] = standardDev\n\n return calculations\n\ntrades = db.t("LearnDeephaven", "StockTrades")\\\n .where("Date=`2017-08-25`")\\\n .view("Sym", "Last", "Size", "ExchangeTimestamp")\n\ntrades30min = trades.updateView("TimeBin=lowerBin(ExchangeTimestamp, 30*MINUTE)")\\\n .firstBy("Sym", "TimeBin")\n\nrollingCalc = trades30min.by("Sym")\\\n .update("Avg=(double[])rollingAvg.call(30, Last)",\n "Std=(double[])rollingStd.call(30, Last, Avg)")\\\n .ungroup()\nminEdge = 0.5\nmaxPos = 3.0\nliquidity = 1e6\n\ntargetPos = rollingCalc.updateView("Zscore=(Avg-Last)/Std if (Std > 0) else NULL_DOUBLE", "AdjZscore=signum(Zscore) * min(maxPos, max(abs(Zscore)-minEdge), 0.0)", "TargetPosition=(int)(liquidity*AdjZscore/Last)")\\\n .dropColumns("ExchangeTimestamp", "Avg", "Std", "Zscore", "AdjZscore")\n\ntimeBinIndexes = targetPos.leftJoin(trades30min, "Sym", "Times=ExchangeTimestamp, SharesTraded=Size")\\\n .updateView("StartIndex=binSearchIndex(Times, TimeBin-30*MINUTE, BS_LOWEST)", "EndIndex=binSearchIndex(Times, TimeBin, BS_HIGHEST)")\\\n .dropColumns("Times")\n\nshares30min = timeBinIndexes.updateView("SharesTraded30Min=sum(SharesTraded.subArray(StartIndex, EndIndex))")\\\n .dropColumns("SharesTraded", "StartIndex", "EndIndex")\n\nfrom math import copysign\nclass SimulatorState:\n def __init__(self):\n self.hm = {}\n\n def __call__(self, sym, targetPos, shares10s):\n if sym not in self.hm:\n self.hm[sym] = [0.0] * 2\n tradedAndPosition = self.hm[sym]\n tradedAndPosition[0] = 0.0 if (targetPos == None) else copysign(1, targetPos - tradedAndPosition[1]) * min(abs(targetPos - tradedAndPosition[1]), shares10s * 0.1)\n tradedAndPosition[1] += tradedAndPosition[0]\n return jpy.array(\'double\', list(tradedAndPosition))\n\nss = SimulatorState()\n\nsimulation = shares30min.update("Values=(double[])ss.call(Sym, TargetPosition, SharesTraded30Min)", "PositionChange=Values[0]", "Position=Values[1]")\\\n .dropColumns("Values")\n',gE='trades = db.t("LearnDeephaven", "StockTrades").where("Date=`2017-08-25`")\n .headBy(3, "Sym")\n .view("Sym", "Last")\n\nsummary = trades.view("Sym", "AvgPrice=Last").avgBy("Sym")\n\nlj = summary.leftJoin(trades, "Sym", "Last")\n\n\nrollingAvg = { rows, values ->\n \n calculations = new double[values.size()]\n \n sum = 0\n n = 0\n avg = 0\n \n for (int i = 0; i < values.size(); ++i)\n {\n sum += values.get(i) //add each value to sum\n if (i >= rows) sum -= values.get(i - rows) //subtract when needed\n \n n = (i < rows) ? i + 1 : rows //n increments with i until i=rows\n avg = sum / n //get updated average every iteration\n \n calculations[i] = avg //store running average\n }\n \n return calculations //return an array of rolling averages\n}\n\nrollingStd = { rows, values, averages ->\n calculations = new double[values.size()]\n\n sum = 0\n n = 0\n\n for (int i = 0; i < values.size(); ++i)\n {\n sum = 0\n for (int j = i; j >= 0 && j > i - rows; --j)\n {\n difference = values.get(j) - averages[i]\n squareDiff = Math.pow(difference, 2)\n sum += squareDiff\n }\n\n n = (i < rows) ? i + 1 : rows\n variance = sum / n\n standardDev = Math.sqrt(variance)\n calculations[i] = standardDev\n }\n return calculations\n}\n\ntrades = db.t("LearnDeephaven", "StockTrades")\n .where("Date=`2017-08-25`")\n .view("Sym", "Last", "Size", "ExchangeTimestamp")\n\ntrades30min = trades.updateView("TimeBin=lowerBin(ExchangeTimestamp, 30*MINUTE)")\n .firstBy("Sym", "TimeBin")\n\nrollingCalc = trades30min.by("Sym")\n .update("Avg=(double[])rollingAvg.call(30, Last)","Std=(double[])rollingStd.call(30, Last, Avg)")\n.ungroup()\n\nminEdge = 0.5d\nmaxPos = 3.0d\nliquidity = 1e6d\n\ntargetPos = rollingCalc.updateView("Zscore=(Std > 0) ? (Avg-Last)/Std : NULL_DOUBLE", "AdjZscore=signum(Zscore) * min(maxPos, max(abs(Zscore)-minEdge), 0.0)", "TargetPosition=(int)(liquidity*AdjZscore/Last)")\n .dropColumns("ExchangeTimestamp", "Avg", "Std", "Zscore", "AdjZscore")\n\ntimeBinIndexes = targetPos.leftJoin(trades30min, "Sym", "Times=ExchangeTimestamp, SharesTraded=Size")\n .updateView("StartIndex=binSearchIndex(Times, TimeBin-30*MINUTE, BS_LOWEST)", "EndIndex=binSearchIndex(Times, TimeBin, BS_HIGHEST)")\n .dropColumns("Times")\n\nshares30min = timeBinIndexes.updateView("SharesTraded30Min=sum(SharesTraded.subArray(StartIndex, EndIndex))")\n .dropColumns("SharesTraded", "StartIndex", "EndIndex")\n\n\nclass SimulatorState\n{\nprivate HashMap<String, double[]> hm = new HashMap<>();\n\n public double[] update(String sym, int targetPos, int shares10s)\n {\n if (!hm.containsKey(sym)) hm.put(sym, new double[2]);\n\n double[] tradedAndPosition = hm.get(sym);\n\n tradedAndPosition[0] =\n isNull(targetPos) ? 0.0 : signum(targetPos - tradedAndPosition[1]) * min(abs(targetPos - tradedAndPosition[1]), shares10s * 0.1d)\n tradedAndPosition[1] += tradedAndPosition[0];\n\n return Arrays.copyOf(tradedAndPosition, tradedAndPosition.length);\n }\n}\nss = new SimulatorState()\n\nsimulation = shares30min.update("Values=(double[])ss.update(Sym, TargetPosition, SharesTraded30Min)", "PositionChange=Values[0]", "Position=Values[1]")\n .dropColumns("Values")\n\n';var vE=()=>Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Editor"}),Object(DC.jsx)("h5",{className:"sub-title",children:"Python"}),Object(DC.jsx)("div",{style:{height:400,position:"relative"},children:Object(DC.jsx)(Cb,{settings:{language:"python",value:pE}})}),Object(DC.jsx)("h5",{className:"sub-title",children:"Groovy"}),Object(DC.jsx)("div",{style:{height:400,position:"relative"},children:Object(DC.jsx)(Cb,{settings:{language:"groovy",value:gE}})})]});const fE=[];var bE=class extends Cu{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Go;super(),this.getCachedColumns=Object(ua.a)((e=>{const t=[];for(let n=0;n<e;n+=1)t.push({name:this.model.textForColumnHeader(n),type:"java.lang.String",description:"Mock column ".concat(n)});return t})),this.model=e,this.editedData=[]}get rowCount(){return this.model.rowCount}get columnCount(){return this.model.columnCount}get floatingTopRowCount(){return 3}get floatingBottomRowCount(){return 3}get isEditable(){return!0}isEditableRange(e){return this.isEditable}setValues(e){throw new Error("Method not implemented.")}delete(e){throw new Error("Method not implemented.")}get pendingRowCount(){return 0}set pendingRowCount(e){}get pendingDataMap(){return new Map}set pendingDataMap(e){}updateFrozenColumns(e){}getColumnIndexByName(e){return Number(e)}textForCell(e,t){var n,i;return null!==(n=null===(i=this.editedData[e])||void 0===i?void 0:i[t])&&void 0!==n?n:this.model.textForCell(e,t)}textForRowHeader(e){return this.model.textForRowHeader(e)}textForRowFooter(e){return this.model.textForRowHeader(e)}textForColumnHeader(e){return this.model.textForColumnHeader(e)}get hasExpandableRows(){return this.model.hasExpandableRows}isRowExpandable(e){return this.model.isRowExpandable(e)}isRowExpanded(e){return this.model.isRowExpanded(e)}setRowExpanded(e,t){this.model.setRowExpanded(e,t)}depthForRow(e){return this.model.depthForRow(e)}get columns(){return this.getCachedColumns(this.columnCount)}get groupedColumns(){return fE}get description(){return"A mock used for testing."}get customColumns(){return[]}set customColumns(e){}get sort(){return[]}set sort(e){}get filter(){return[]}set filter(e){}set formatter(e){}displayString(e){return"".concat(e)}valueForCell(e,t){return this.textForCell(e,t)}formatForCell(e,t){return null}setViewport(){this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED))}async setValueForCell(e,t,n){null==this.editedData[e]&&(this.editedData[e]=[]),this.editedData[e][t]="".concat(n),this.dispatchEvent(new CustomEvent(Cu.EVENT.UPDATED))}async setValueForRanges(e,t){fr.forEachCell(e,((e,n)=>{this.setValueForCell(e,n,t)}))}editValueForCell(e,t){return this.textForCell(e,t)}isValidForCell(e,t,n){return!0}};class CE extends i.PureComponent{constructor(e){super(e),this.state={irisGridModel:new bE(new Go),model:new zo,theme:{autoSelectRow:!0},treeModel:new Go,treeTheme:{autoSelectRow:!0}}}render(){const{irisGridModel:e,model:t,theme:n,treeModel:i,treeTheme:a}=this.state;return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Grid"}),Object(DC.jsx)("div",{style:{height:500},children:Object(DC.jsx)(Ao,{model:t,theme:n})}),Object(DC.jsx)("h2",{className:"ui-title",children:"Tree Grid"}),Object(DC.jsx)("div",{style:{height:500},children:Object(DC.jsx)(Ao,{model:i,theme:a})}),Object(DC.jsx)("h2",{className:"ui-title",children:"Iris Grid"}),Object(DC.jsx)("div",{style:{height:500},children:Object(DC.jsx)(xf,{model:e})})]})}}var SE=CE;const EE=e=>{let{message:t,message:{text:n}}=e;const[a,s]=Object(i.useState)(!1);return Object(i.useEffect)((()=>{if(!n)return;s(!0);const e=setTimeout((()=>{s(!1)}),2e3);return()=>{clearTimeout(e)}}),[t,n]),Object(DC.jsx)("p",{className:a?"flash in":"flash out",children:n})};var wE,yE=()=>{const[e,t]=Object(i.useState)(!0),[n,a]=Object(i.useState)(!0),[s,r]=Object(i.useState)(""),[o,l]=Object(i.useState)({text:""}),c=Object.values(Un).filter((t=>{const i=-1!==(t.prefix.toLowerCase()+t.iconName.toLowerCase()).indexOf(s.toLowerCase()),a=e&&"dh"===t.prefix,r=n&&"vs"===t.prefix;return i&&(a||r)})).map((e=>{const t=(n=e.iconName,e.prefix.toLowerCase()+n.split("-").map((e=>e.charAt(0).toUpperCase()+e.slice(1))).join(""));var n;return Object(DC.jsxs)(gh,{kind:"inline",className:"card",onClick:()=>{(async function(e){try{return await navigator.clipboard.writeText(e)}catch(t){throw new Error("Unable to copy: ".concat(t.message))}})(t).then((()=>{l({text:Object(DC.jsxs)("span",{children:[Object(DC.jsx)(Ke.a,{icon:Un.vsOutput})," Copied text:"," ",Object(DC.jsx)("strong",{children:t})]})})})).catch((e=>{l({text:Object(DC.jsx)("span",{className:"text-danger",children:e.message})})}))},children:[Object(DC.jsx)(Ke.a,{icon:e,className:"icon"}),Object(DC.jsx)("label",{title:t,children:t})]},t)}));return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Icons"}),Object(DC.jsx)("div",{className:"row",children:Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsxs)("div",{className:"form-inline mb-3",children:[Object(DC.jsx)("input",{type:"search",placeholder:"Basic icon search...",value:s,className:"form-control",onChange:e=>{r(e.target.value)}}),Object(DC.jsx)("span",{className:"mx-2",children:"Show: "}),Object(DC.jsx)(gh,{kind:"inline",active:n,className:"mr-2",onClick:()=>a(!n),icon:n?Un.vsCheck:Un.vsClose,children:"VS ICONS"}),Object(DC.jsx)(gh,{kind:"inline",active:e,className:"mr-2",onClick:()=>t(!e),icon:e?Un.vsCheck:Un.vsClose,children:"DH ICONS"}),Object(DC.jsxs)("small",{children:["(",c.length," icon",1===c.length?"":"s",")"]})]}),Object(DC.jsxs)("div",{className:"icons",children:[c,0===c.length&&Object(DC.jsx)("p",{className:"no-result",children:"No icons found."}),Object(DC.jsx)(EE,{message:o})]})]})})]})};n(1457);function TE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function OE(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.UP="UP",e.DOWN="DOWN"}(wE||(wE={}));class ME extends i.Component{constructor(e){super(e),OE(this,"popper",void 0),OE(this,"cbContainer",void 0),OE(this,"toggleButton",void 0),OE(this,"menuContainer",void 0),OE(this,"input",void 0),OE(this,"searchInput",void 0),OE(this,"getCachedFilteredOptions",Lr()(((e,t)=>e.filter((e=>e.title.toLowerCase().indexOf(t.toLowerCase())>=0||e.value.toLowerCase().indexOf(t.toLowerCase())>=0))))),this.state={value:"",filter:"",filteredOptions:e.options,keyboardOptionIndex:-1,menuIsOpen:!1,inputWidth:100},this.toggleMenu=this.toggleMenu.bind(this),this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.handleMenuBlur=this.handleMenuBlur.bind(this),this.closeMenu=this.closeMenu.bind(this),this.handleInputChange=this.handleInputChange.bind(this),this.handleInputKeyDown=this.handleInputKeyDown.bind(this),this.handleInputBlur=this.handleInputBlur.bind(this),this.handleFilterChange=this.handleFilterChange.bind(this),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleOptionFocus=this.handleOptionFocus.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.popper=a.a.createRef(),this.cbContainer=a.a.createRef(),this.toggleButton=a.a.createRef(),this.menuContainer=a.a.createRef(),this.input=a.a.createRef(),this.searchInput=a.a.createRef()}componentDidUpdate(){var{menuIsOpen:e,keyboardOptionIndex:t}=this.state;e&&t>=0&&this.scrollOptionIntoView()}setInputWidth(){this.cbContainer.current&&this.setState({inputWidth:this.cbContainer.current.getBoundingClientRect().width})}focus(){var e;null===(e=this.input.current)||void 0===e||e.focus()}resetValue(){this.setState({value:""})}updateInputValue(e){var{onChange:t}=this.props;this.setState({value:e}),t(e)}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var t,n,{filter:i,filteredOptions:a,keyboardOptionIndex:s}=this.state,{options:r}=this.props,o=i?a:r;switch(e.key){case"Enter":null!=(null===(t=o[s])||void 0===t?void 0:t.value)&&this.updateInputValue(o[s].value),this.closeMenu(),null===(n=this.input.current)||void 0===n||n.focus(),e.stopPropagation(),e.preventDefault();break;case"ArrowUp":this.handleMenuNavigation(ME.MENU_NAVIGATION_DIRECTION.UP),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":this.handleMenuNavigation(ME.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"Escape":""!==i?(this.setState({filter:""}),e.stopPropagation()):this.closeMenu();break;case"Tab":e.shiftKey||s!==o.length-1||this.closeMenu()}}handleMenuNavigation(e){var{filter:t,filteredOptions:n,keyboardOptionIndex:i}=this.state,{options:a}=this.props,s=(t?n:a).length,r=0;switch(e){case ME.MENU_NAVIGATION_DIRECTION.UP:r=-1;break;case ME.MENU_NAVIGATION_DIRECTION.DOWN:r=1}0!==r&&this.setState({keyboardOptionIndex:(i+r+s)%s})}handleInputKeyDown(e){var{onEnter:t}=this.props,{menuIsOpen:n}=this.state;"ArrowDown"===e.key||"ArrowUp"===e.key?n||this.openMenu():"Enter"===e.key&&t()}handleInputChange(e){this.updateInputValue(e.target.value)}handleOptionClick(e){var t,n=Number(e.currentTarget.value),{filter:i,filteredOptions:a}=this.state,{options:s}=this.props,r=i?a:s;this.updateInputValue(r[n].value),this.closeMenu(),null===(t=this.input.current)||void 0===t||t.focus()}handleOptionFocus(e){this.setState({keyboardOptionIndex:Number(e.target.value)})}handleFilterChange(e){var t,{options:n}=this.props,i=e.target.value,a=this.getCachedFilteredOptions(n,i);this.setState({filter:i,filteredOptions:a,keyboardOptionIndex:0}),null===(t=this.popper.current)||void 0===t||t.scheduleUpdate()}handleMenuBlur(e){var t;e.relatedTarget instanceof Element&&null!==(t=this.popper.current)&&void 0!==t&&t.element.contains(e.relatedTarget)||e.relatedTarget===this.toggleButton.current||this.closeMenu(!1)}handleInputBlur(e){var t,{menuIsOpen:n}=this.state;n&&e.relatedTarget instanceof Element&&null!==(t=this.popper.current)&&void 0!==t&&t.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuOpened(){var e;this.scrollOptionIntoView(),null===(e=this.searchInput.current)||void 0===e||e.focus()}handleMenuExited(){var e,{menuIsOpen:t}=this.state;t&&(this.setState({menuIsOpen:!1}),null===(e=this.popper.current)||void 0===e||e.hide());this.setState({filter:""})}toggleMenu(e){var{menuIsOpen:t}=this.state;t?this.closeMenu():this.openMenu(),e.stopPropagation()}openMenu(){this.updateKeyboardIndex(),this.setInputWidth(),this.setState({menuIsOpen:!0}),window.requestAnimationFrame((()=>{var e;null===(e=this.popper.current)||void 0===e||e.show()}))}closeMenu(){var e,t,n=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];(this.setState({menuIsOpen:!1}),n)&&(null===(t=this.input.current)||void 0===t||t.focus());null===(e=this.popper.current)||void 0===e||e.hide()}updateKeyboardIndex(){var{value:e,filter:t,filteredOptions:n}=this.state,{options:i}=this.props,a=(t?n:i).findIndex((t=>t.value===e));this.setState({keyboardOptionIndex:a})}scrollOptionIntoView(){var e,t=null===(e=this.menuContainer.current)||void 0===e?void 0:e.querySelector(".cb-option-btn.keyboard-active");t instanceof HTMLElement&&t.scrollIntoView({block:"nearest",inline:"nearest"})}renderMenuElement(){var{searchPlaceholder:e}=this.props,{filter:t,inputWidth:n}=this.state;return a.a.createElement("div",{className:"cb-menu-container",ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,onClick:e=>{e.stopPropagation()},style:{width:n},onBlur:this.handleMenuBlur},a.a.createElement("div",{className:"cb-search-input-container"},a.a.createElement(Gc,{value:t,ref:this.searchInput,onChange:this.handleFilterChange,className:"cb-search-input",placeholder:e})),a.a.createElement("div",{className:"cb-options-container"},a.a.createElement("div",{className:"cb-options"},this.renderOptions())))}renderOptions(){var{options:e}=this.props,{keyboardOptionIndex:t,filter:n,filteredOptions:i}=this.state;return(n?i:e).map(((e,n)=>{var i="option-".concat(n,"-").concat(e.value);return a.a.createElement("button",{key:i,type:"button",value:n,className:qe()("cb-option-btn",{"keyboard-active":t===n}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus},e.title)}))}render(){var{options:e,inputPlaceholder:t,disabled:n,className:i,defaultValue:s,spellCheck:r}=this.props,{value:o}=this.state,{popperOptions:l}=this.props;return l=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?TE(Object(n),!0).forEach((function(t){OE(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TE(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},l),a.a.createElement("div",{className:"input-group cb-container",ref:this.cbContainer},a.a.createElement("input",{value:o||s,className:qe()("form-control",i,"cb-input"),ref:this.input,onChange:this.handleInputChange,placeholder:t||e[0]&&e[0].title,disabled:n,onBlur:this.handleInputBlur,onKeyDown:this.handleInputKeyDown,spellCheck:r}),a.a.createElement("div",{className:"input-group-append cb-dropdown"},a.a.createElement("button",{type:"button",className:"btn cb-btn form-control",ref:this.toggleButton,onClick:this.toggleMenu,onKeyDown:this.handleInputKeyDown,disabled:n},a.a.createElement(Ke.a,{icon:Qt}),a.a.createElement(El,{ref:this.popper,options:l,className:qe()("combobox interactive"),onEntered:this.handleMenuOpened,onExited:this.handleMenuExited},this.renderMenuElement()))))}}OE(ME,"MENU_NAVIGATION_DIRECTION",wE),OE(ME,"DROP_DOWN_MENU_HEIGHT",200),OE(ME,"propTypes",{options:pi.a.arrayOf(pi.a.shape({title:pi.a.string.isRequired,value:pi.a.string.isRequired})).isRequired,popperOptions:pi.a.shape({title:pi.a.string.isRequired,value:pi.a.string.isRequired}),onChange:pi.a.func,inputPlaceholder:pi.a.string,searchPlaceholder:pi.a.string,disabled:pi.a.bool,className:pi.a.string,defaultValue:pi.a.string,spellCheck:pi.a.bool,onEnter:pi.a.func}),OE(ME,"defaultProps",{onChange(){},inputPlaceholder:"",searchPlaceholder:"Search",disabled:!1,className:"",defaultValue:"",popperOptions:null,spellCheck:!0,onEnter(){}});var NE=ME;n(1458);function DE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function xE(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var RE;!function(e){e.UP="UP",e.DOWN="DOWN"}(RE||(RE={}));class IE extends i.Component{constructor(e){super(e),xE(this,"popper",void 0),xE(this,"cbContainer",void 0),xE(this,"menuContainer",void 0),xE(this,"input",void 0),xE(this,"getCachedFilteredOptions",Lr()(((e,t)=>e.filter((e=>e.title.toLowerCase().indexOf(t.toLowerCase())>=0)))));var{popperOptions:t}=this.props;t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?DE(Object(n),!0).forEach((function(t){xE(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):DE(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},t),this.state={title:"",filteredOptions:[],keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,invalid:!1,popperOptions:t},this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.handleMenuBlur=this.handleMenuBlur.bind(this),this.handleInputChange=this.handleInputChange.bind(this),this.handleInputKeyDown=this.handleInputKeyDown.bind(this),this.handleInputBlur=this.handleInputBlur.bind(this),this.handelInputFocus=this.handelInputFocus.bind(this),this.handleInputClick=this.handleInputClick.bind(this),this.updateInputValue=pa()(this.updateInputValue,100),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.popper=a.a.createRef(),this.cbContainer=a.a.createRef(),this.menuContainer=a.a.createRef(),this.input=a.a.createRef()}setInputWidth(){this.cbContainer.current&&this.setState({inputWidth:this.cbContainer.current.getBoundingClientRect().width})}getValueAndValidate(e){if(!e)return this.setState({invalid:!1}),{value:e,isValid:!1};var{options:t}=this.props,n=t.filter((t=>t.title.toLowerCase()===e.toLowerCase()));return n.length<1?(this.setState({invalid:!0}),{value:e,isValid:!1}):(this.setState({invalid:!1}),{value:n[0].value,isValid:!0})}updateInputValue(e){var{menuIsOpen:t}=this.state,{value:n,isValid:i}=this.getValueAndValidate(e);t&&this.processFilterChange(e),this.fireOnChange(n,i)}fireOnChange(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],{onChange:n}=this.props;n(e,t)}processFilterChange(e){var t,{options:n}=this.props,{menuIsOpen:i}=this.state,a=e?this.getCachedFilteredOptions(n,e):n,s=1===a.length&&a[0].title===e;this.setState({filteredOptions:a,keyboardOptionIndex:0}),s&&i?this.closeMenu():null===(t=this.popper.current)||void 0===t||t.scheduleUpdate()}resetValue(){this.setState({title:""}),this.fireOnChange("")}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var t,{filteredOptions:n,keyboardOptionIndex:i}=this.state,a=n[i];switch(e.key){case"Enter":case"ArrowRight":e.stopPropagation(),e.preventDefault(),a&&(this.setState({title:a.title,invalid:!1}),this.fireOnChange(a.value)),this.closeMenu(),null===(t=this.input.current)||void 0===t||t.focus();break;case"ArrowUp":e.stopPropagation(),e.preventDefault(),this.navigateMenu(IE.MENU_NAVIGATION_DIRECTION.UP);break;case"ArrowDown":e.stopPropagation(),e.preventDefault(),this.navigateMenu(IE.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Tab":if(e.stopPropagation(),e.preventDefault(),e.shiftKey){this.navigateMenu(IE.MENU_NAVIGATION_DIRECTION.UP);break}this.navigateMenu(IE.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Escape":e.preventDefault(),e.stopPropagation(),this.closeMenu()}}navigateMenu(e){var{filteredOptions:t,keyboardOptionIndex:n}=this.state,i=n;e===IE.MENU_NAVIGATION_DIRECTION.UP?n>0?(i=(i-1)%t.length,this.setState({keyboardOptionIndex:i})):0===n&&(i=t.length-1,this.setState({keyboardOptionIndex:i})):e===IE.MENU_NAVIGATION_DIRECTION.DOWN&&n<t.length&&(i=(i+1)%t.length,this.setState({keyboardOptionIndex:i})),this.scrollOptionIntoView(i)}handleInputKeyDown(e){var{onEnter:t}=this.props,{menuIsOpen:n}=this.state;n?this.handleMenuKeyDown(e):"Enter"===e.key?t():"Escape"===e.key?(this.resetValue(),e.preventDefault(),e.stopPropagation()):"ArrowRight"!==e.key&&"ArrowLeft"!==e.key&&"Tab"!==e.key&&"Shift"!==e.key&&this.openMenu()}handleInputChange(e){this.setState({title:e.target.value}),this.updateInputValue(e.target.value)}handleOptionClick(e){var t;this.setState({title:e.title,invalid:!1}),this.fireOnChange(e.value),this.closeMenu(),null===(t=this.input.current)||void 0===t||t.focus()}handelInputFocus(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputClick(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputBlur(e){var t,{menuIsOpen:n}=this.state;n&&e.relatedTarget instanceof Element&&null!==(t=this.popper.current)&&void 0!==t&&t.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuBlur(e){var t;e.relatedTarget===this.input.current||e.relatedTarget instanceof Element&&null!==(t=this.popper.current)&&void 0!==t&&t.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuOpened(){var e;null===(e=this.input.current)||void 0===e||e.focus()}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}openMenu(){var{title:e}=this.state;this.processFilterChange(e),this.setInputWidth(),this.setState({menuIsOpen:!0}),window.requestAnimationFrame((()=>{var e;null===(e=this.popper.current)||void 0===e||e.show()}))}closeMenu(){var e,t,n=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];(this.setState({menuIsOpen:!1,keyboardOptionIndex:0}),n)&&(null===(t=this.input.current)||void 0===t||t.focus());null===(e=this.popper.current)||void 0===e||e.hide()}scrollOptionIntoView(e){var t;this.menuContainer.current&&(null===(t=this.menuContainer.current.children.item(e))||void 0===t||t.scrollIntoView({behavior:"smooth",block:"nearest"}))}renderMenuElement(){var{inputWidth:e}=this.state;return a.a.createElement("div",{className:qe()("aci-options"),ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,style:{width:e},onBlur:this.handleMenuBlur},this.renderOptions())}renderOptions(){var{noMatchText:e}=this.props,{title:t,filteredOptions:n}=this.state;return t&&0===n.length?a.a.createElement("div",{className:"no-match"},e):n.map(((e,t)=>this.renderOption(e,t)))}renderOption(e,t){var{keyboardOptionIndex:n}=this.state,i="option-".concat(t,"-").concat(e.value);return a.a.createElement("button",{key:i,type:"button",className:qe()("aci-option-btn",{"keyboard-active":n===t}),onClick:()=>this.handleOptionClick(e),onFocus:()=>this.setState({keyboardOptionIndex:t})},e.title)}render(){var{options:e,inputPlaceholder:t,disabled:n,className:i,defaultTitle:s,spellCheck:r}=this.props,{title:o,menuIsOpen:l,popperOptions:c,invalid:h}=this.state;return a.a.createElement("div",{className:"aci-container",ref:this.cbContainer},a.a.createElement("input",{value:o||s,className:qe()("form-control",i,"aci-input",{"is-invalid":h&&!l}),ref:this.input,onChange:this.handleInputChange,placeholder:t||e[0].title,disabled:n,onFocus:this.handelInputFocus,onClick:this.handleInputClick,onBlur:this.handleInputBlur,onKeyDown:this.handleInputKeyDown,spellCheck:r}),a.a.createElement(El,{ref:this.popper,options:c,className:qe()("aci-options-popper interactive"),onEntered:this.handleMenuOpened,onExited:this.handleMenuExited},this.renderMenuElement()))}}xE(IE,"propTypes",{options:pi.a.arrayOf(pi.a.shape({title:pi.a.string.isRequired,value:pi.a.string.isRequired})).isRequired,popperOptions:pi.a.shape({}),onChange:pi.a.func,inputPlaceholder:pi.a.string,disabled:pi.a.bool,className:pi.a.string,defaultTitle:pi.a.string,spellCheck:pi.a.bool,onEnter:pi.a.func,noMatchText:pi.a.string}),xE(IE,"defaultProps",{onChange(){},inputPlaceholder:"",disabled:!1,className:"",defaultTitle:"",popperOptions:null,spellCheck:!0,onEnter(){},noMatchText:"No matching items found"}),xE(IE,"MENU_NAVIGATION_DIRECTION",RE);var LE=IE,FE=(n(1456),p.module("MaskedInput")),kE="backward",AE="none",PE="\u2007",_E=a.a.forwardRef(((e,t)=>{var{className:n,example:s,getNextSegmentValue:r=((e,t,n)=>n),onChange:o=(()=>!1),onSelect:l=(()=>!1),pattern:c,selection:h,value:d,onFocus:u=(()=>!1),onBlur:m=(()=>!1)}=e,p=vi(t),g=Object(i.useMemo)((()=>Array.isArray(s)?s:[s]),[s]);function v(e){for(var t=e,n=e,i=g.length>0?g[0]:d,a=t-1;a>=0&&/[a-zA-Z0-9]/g.test(i.charAt(a));a-=1)t=a;for(var s=n;s<i.length&&/[a-zA-Z0-9]/g.test(i.charAt(s));s+=1)n=s+1;return{selectionStart:t,selectionEnd:n,selectionDirection:t===n?AE:kE}}function f(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,i="",a=0;a<n;a+=1)i=e.charAt(a)!==PE?i.concat(e[a]):i.concat(t[a]);return i=i.concat(t.substring(n))}function b(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length,n=new RegExp(c);if(n.test(e))return!0;for(var i=0;i<g.length;i+=1){var a=f(e,g[i],t);if(n.test(a))return!0}return!1}function C(e){var t=v(e),n=t.selectionEnd+1;return n>=d.length?t:v(n)}function S(e,t){var n=v(e),i=d.substring(n.selectionStart,n.selectionEnd),a=r(n,t,i,d),s=d.substring(0,n.selectionStart)+a+d.substring(n.selectionEnd);b(s,n.selectionEnd)&&(o(s),l(n))}function E(e){if(e.preventDefault(),e.stopPropagation(),p.current){var{key:t}=e,{selectionStart:n=0,selectionEnd:i=0}=p.current;null!==n&&null!==i?"ArrowLeft"===t?l(function(e){var t=v(e),n=t.selectionStart-1;return n<=0?t:v(n)}(n)):"ArrowRight"===t?l(C(i)):"ArrowUp"===t?S(n,-1):"ArrowDown"===t&&S(n,1):FE.error("Selection arrow nvaigation attempted on non-text input element",e.target)}}return Object(i.useEffect)((()=>{if(null!=h){var e;FE.debug("setting selection...",h);var{selectionStart:t,selectionEnd:n,selectionDirection:i}=h;null===(e=p.current)||void 0===e||e.setSelectionRange(t,n,i),FE.debug("selection set!")}}),[h,p]),a.a.createElement("input",{ref:p,className:qe()("form-control masked-input",n),type:"text",pattern:c,value:d,onChange:()=>{},onKeyDown:function(e){if(p.current){FE.debug("handleKeyDown",e);var{key:t}=e,{selectionStart:n=0,selectionEnd:i=0}=p.current;if(null!==n&&null!==i){if(t.startsWith("Arrow"))E(e);else if("Delete"!==t&&"Backspace"!==t){if(!(e.altKey||e.metaKey||e.ctrlKey||t.length>1)){e.preventDefault(),e.stopPropagation();for(var a=Array.from(new Set([t,t.toUpperCase(),t.toLowerCase()])),s=0;s<a.length;s+=1)for(var r=a[s],c=/[a-zA-Z0-9]/g.test(r)?d.length-1:n,h=n;h<=c;h+=1){var u=d.substring(0,h)+r+d.substring(h+1);if(b(u,h+1)){var m=v(h),g=h+1,f={selectionStart:g,selectionEnd:g,selectionDirection:AE};if(g>=m.selectionEnd){var S=C(h);S.selectionStart!==m.selectionStart&&(f=S)}return FE.debug("handleKeyDown",t,"=>",u,f),o(u),void l(f)}}}}else if(e.preventDefault(),e.stopPropagation(),n!==i){var w=d.substring(0,n)+d.substring(n,i).replace(/[a-zA-Z0-9]/g,PE)+d.substring(i);FE.debug("Range ",n,i,"deleted, setting value",w),o(w),l({selectionStart:n,selectionEnd:n,selectionDirection:AE})}else if(n>0)for(var y=n-1;y>=0;y-=1){var T=d.substring(0,y)+d.substring(y,n).replace(/[a-zA-Z0-9]/g,PE)+d.substring(n);if(T!==d)return o(T),void l({selectionStart:y,selectionEnd:y,selectionDirection:AE})}}else FE.error("Selection key event on non-text input element",e.target)}},onSelect:function(e){var{selectionStart:t=0,selectionEnd:n=0,selectionDirection:i="none"}=e.target;if(null!==t&&null!==n&&null!==i){if(FE.debug2("handleSelect",t,n,i),null==h||t!==h.selectionStart||n!==h.selectionEnd)if(t===n){var a=v(t);FE.debug("Selection segment from ",t,n,"=>",a),l(a)}else l({selectionStart:t,selectionEnd:n,selectionDirection:i})}else FE.error("Selection attempted on non-text input element",e.target)},onSelectCapture:function(e){if(p.current){FE.debug("handleSelectCapture",e);var t=p.current.selectionStart||0;t===d.length&&null!=h&&t!==h.selectionStart&&(e.preventDefault(),e.stopPropagation())}},onFocus:u,onBlur:m})}));_E.defaultProps={className:"",onChange(){},onSelect(){},getNextSegmentValue:(e,t,n)=>n,selection:void 0,onFocus(){},onBlur(){}};var HE=_E,jE=p.module("TimeInput"),VE=["00:00:00","12:34:56","23:59:59"],zE=a.a.forwardRef(((e,t)=>{var{allowValueWrapping:n=!0,className:s="",onChange:r=(()=>!1),value:o=0,onFocus:l=(()=>!1),onBlur:c=(()=>!1)}=e,[h,d]=Object(i.useState)(Ya.formatTime(o)),[u,m]=Object(i.useState)();return Object(i.useEffect)((()=>{d(Ya.formatTime(o))}),[o]),a.a.createElement(HE,{ref:t,className:s,example:VE,getNextSegmentValue:function(e,t,i){var a=0===e.selectionStart?24:60,s=parseInt(i,10)-t;return s=Number.isNaN(s)?0:n?(s%a+a)%a:Math.min(Math.max(0,s),a-1),"".concat(s).padStart(2,"0")},onChange:function(e){jE.debug("handleChange",e),d(e),Ya.isTimeString(e)&&r(Ya.parseTime(e))},onSelect:function(e){m(e)},pattern:"([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]",selection:u,value:h,onFocus:l,onBlur:c})}));zE.defaultProps={allowValueWrapping:!0,className:"",onChange:()=>!1,value:0,onFocus:()=>!1,onBlur:()=>!1};var UE=zE;n(1459);function BE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function WE(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var GE;!function(e){e.UP="UP",e.DOWN="DOWN"}(GE||(GE={}));class qE extends i.Component{constructor(e){super(e),WE(this,"csContainer",void 0),WE(this,"menuContainer",void 0),WE(this,"button",void 0),WE(this,"input",void 0);var{value:t,valueToTime:n}=e;this.toggleMenu=this.toggleMenu.bind(this),this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.closeMenu=this.closeMenu.bind(this),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleOptionFocus=this.handleOptionFocus.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.handleCustomInput=this.handleCustomInput.bind(this),this.csContainer=a.a.createRef(),this.menuContainer=a.a.createRef(),this.button=a.a.createRef(),this.input=a.a.createRef(),this.state={keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,customTime:n(t),inputFocused:!1}}getSelectedText(){var{options:e,value:t,placeholder:n}=this.props,{customTime:i}=this.state;if(null===t)return n;for(var a=0;a<e.length;a+=1){var s=e[a];if(s.value===t)return s.title}return Ya.formatTime(i)}setInputWidth(){this.csContainer.current&&this.setState({inputWidth:this.csContainer.current.getBoundingClientRect().width})}focus(){var e;null===(e=this.button.current)||void 0===e||e.focus()}updateInputValue(e){var{onChange:t}=this.props;t(e)}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var t,{keyboardOptionIndex:n,inputFocused:i}=this.state,{options:a}=this.props;switch(e.key){case"Enter":case" ":i?this.updateFromCustom():this.updateInputValue(a[n].value),this.closeMenu(),null===(t=this.button.current)||void 0===t||t.focus(),e.stopPropagation(),e.preventDefault();break;case"Tab":e.shiftKey?this.handleMenuNavigation(qE.MENU_NAVIGATION_DIRECTION.UP):this.handleMenuNavigation(qE.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"ArrowUp":this.handleMenuNavigation(qE.MENU_NAVIGATION_DIRECTION.UP),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":this.handleMenuNavigation(qE.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"Escape":this.closeMenu()}}handleMenuNavigation(e){var{keyboardOptionIndex:t,inputFocused:n}=this.state,{options:i}=this.props,a=i.length,s=t;switch(e){case qE.MENU_NAVIGATION_DIRECTION.UP:if(!n&&0===t){this.focusInput();break}n&&this.focusOption(t),t>0&&!n?(s=(s-1)%a,this.setState({keyboardOptionIndex:s})):0===t&&(s=a-1,this.setState({keyboardOptionIndex:s})),this.scrollOptionIntoView(s);break;case qE.MENU_NAVIGATION_DIRECTION.DOWN:if(!n&&t===a-1){this.focusInput();break}n&&this.focusOption(t),t<a&&(!n||0!==t)&&(s=(s+1)%a,this.setState({keyboardOptionIndex:s})),this.scrollOptionIntoView(s)}}handleOptionClick(e){var t=Number(e.currentTarget.value),{options:n,timeToValue:i}=this.props,{customTime:a}=this.state;if(-1===t){var s=i(a);this.updateAndClose(s)}else this.updateAndClose(n[t].value)}updateAndClose(e){var t;this.updateInputValue(e),this.closeMenu(),null===(t=this.button.current)||void 0===t||t.focus()}handleOptionFocus(e){this.setState({keyboardOptionIndex:Number(e.target.value)})}handleMenuOpened(){var e,{options:t,value:n}=this.props,{keyboardOptionIndex:i}=this.state;this.scrollOptionIntoView(i);var a=null===(e=this.menuContainer.current)||void 0===e?void 0:e.querySelector(".cs-option-btn.keyboard-active");(a instanceof HTMLElement&&a.focus(),null!==n)&&(t.map((e=>e.value)).indexOf(n)<0&&this.focusInput())}focusInput(){var e;null===(e=this.input.current)||void 0===e||e.focus()}focusOption(e){var t,n=null===(t=this.menuContainer.current)||void 0===t?void 0:t.querySelector(".cs-options");if(n&&n.children){var i=n.children.item(e);i instanceof HTMLElement&&i.focus()}}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}handleCustomInput(e){var{timeToValue:t}=this.props,n=t(e);this.updateInputValue(n),this.setState({customTime:e})}updateFromCustom(){var{timeToValue:e}=this.props,{customTime:t}=this.state,n=e(t);this.updateInputValue(n)}toggleMenu(e){var{menuIsOpen:t}=this.state;t?this.closeMenu():this.openMenu(),e.stopPropagation()}openMenu(){this.updateKeyboardIndex(),this.setInputWidth(),this.setState({menuIsOpen:!0})}closeMenu(){var e,t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];(this.setState({menuIsOpen:!1}),t)&&(null===(e=this.button.current)||void 0===e||e.focus())}updateKeyboardIndex(){var{options:e,value:t}=this.props;if(null!==t){var n=e.map((e=>e.value)).indexOf(t);n>0&&this.setState({keyboardOptionIndex:n})}}scrollOptionIntoView(e){var t,n=null===(t=this.menuContainer.current)||void 0===t?void 0:t.querySelector(".cs-options");if(n&&n.children){var i=n.children.item(e);i instanceof HTMLElement&&i.offsetTop>qE.DROP_DOWN_MENU_HEIGHT?n.scrollTop=i.offsetTop-qE.DROP_DOWN_MENU_HEIGHT:(i instanceof HTMLElement&&i.offsetTop<0||0===e)&&(n.scrollTop=0)}}renderMenuElement(){var{inputWidth:e}=this.state;return a.a.createElement("div",{className:"cs-menu-container",ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,onClick:e=>{e.stopPropagation()},style:{width:e}},a.a.createElement("div",{className:"cs-options-container"},a.a.createElement("div",{className:"cs-options"},this.renderOptions())))}renderOptions(){for(var{options:e,value:t,icon:n,customText:i}=this.props,{keyboardOptionIndex:s,customTime:r,inputFocused:o}=this.state,l=!1,c=[],h=0;h<e.length;h+=1){var d=e[h],u="option-".concat(h,"-").concat(d.value);l=l||d.value===t,c.push(a.a.createElement("button",{key:u,type:"button",value:h,className:qe()("cs-option-btn",{"keyboard-active":s===h&&!o}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus},d.value===t&&a.a.createElement(Ke.a,{icon:n,className:"mr-2"}),d.value!==t&&a.a.createElement("span",{className:"mr-4"}),d.title))}return c.push(a.a.createElement("hr",{className:"cs-divider",key:"option-divider"})),c.push(a.a.createElement("button",{key:"option-custom-label",type:"button",value:-1,className:qe()("cs-option-btn",{"keyboard-active":o}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus},l||null===t?a.a.createElement("span",{className:"mr-4"}):a.a.createElement(Ke.a,{icon:n,className:"mr-2"}),i)),c.push(a.a.createElement("div",{key:"cs-custom-container",className:"cs-custom-container"},a.a.createElement("span",{className:"mr-2"}),a.a.createElement(UE,{key:"option-input",ref:this.input,onChange:this.handleCustomInput,value:r,onFocus:()=>this.setState({inputFocused:!0}),onBlur:()=>this.setState({inputFocused:!1})}),a.a.createElement("span",{className:"ml-2"}))),c.push(a.a.createElement("hr",{key:"option-end",className:"mb-2"})),c}render(){var{disabled:e,invalid:t,value:n}=this.props,{menuIsOpen:i}=this.state,{popperOptions:s}=this.props;return s=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?BE(Object(n),!0).forEach((function(t){WE(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):BE(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},s),a.a.createElement("div",{className:"input-group cs-container context-menu",ref:this.csContainer},a.a.createElement("div",{className:qe()("input-group-append cs-dropdown",{"cs-dropdown-invalid":t})},a.a.createElement("button",{type:"button",className:qe()("btn cs-btn form-control",{"cs-btn-invalid":t}),ref:this.button,onClick:this.toggleMenu,disabled:e},a.a.createElement("span",{className:qe()({"text-muted":null===n})},this.getSelectedText()),a.a.createElement("span",null,a.a.createElement(Ke.a,{icon:Fn,className:"cs-caret"})),a.a.createElement(nu,{isShown:i,actions:{menuElement:this.renderMenuElement()},popperOptions:s,popperClassName:"CustomTimeSelect",onMenuOpened:this.handleMenuOpened,onMenuClosed:this.handleMenuExited,menuStyle:{maxWidth:"100rem"}}))))}}WE(qE,"MENU_NAVIGATION_DIRECTION",GE),WE(qE,"DROP_DOWN_MENU_HEIGHT",125),WE(qE,"defaultProps",{onChange(){},value:null,disabled:!1,popperOptions:{},icon:Je,customText:"Custom",placeholder:"Select a time",valueToTime:e=>null===e?0:Math.round(e/1e3),timeToValue:e=>1e3*e,invalid:!1});var KE=qE,YE=(n(1460),e=>{var{className:t="",value:n,onChange:s,spellCheck:r=!1,placeholder:o="",disabled:l=!1,delimiter:c="",id:h=""}=e,[d,u]=Object(i.useState)(n),[m,p]=Object(i.useState)(!1),g=Object(i.useRef)(null);function v(e){return e.trim().split(c).filter((e=>e)).join("\n".concat(c.trim()))}function f(e){return e.split("\n").map((e=>e.trim())).join(" ")}function b(){if(g.current){g.current.style.height="0";var e=g.current.scrollHeight+(g.current.offsetHeight-g.current.clientHeight);e>0&&(g.current.style.height="".concat(e,"px"))}}return Object(i.useEffect)((()=>{u(n)}),[n]),Object(i.useEffect)((()=>{b()}),[d]),a.a.createElement("textarea",{ref:g,id:h,className:qe()(t,"auto-resize-textarea form-control"),placeholder:o,value:d,rows:1,onChange:function(e){var t=e.target.value;m&&(c&&(t=v(t)),p(!1)),u(t),s(t)},onFocus:function(){g.current&&(c&&(u(v(d)),b()),g.current.scrollLeft=0)},onMouseDown:function(){g.current&&document.activeElement!==g.current&&g.current.focus()},onBlur:function(){c&&(u(f(d)),s(f(d)))},onPaste:function(){p(!0)},spellCheck:r,disabled:l})});YE.propTypes={value:pi.a.string.isRequired,onChange:pi.a.func.isRequired,className:pi.a.string,placeholder:pi.a.string,spellCheck:pi.a.bool,disabled:pi.a.bool,delimiter:pi.a.string,id:pi.a.string},YE.defaultProps={className:"",id:"",placeholder:"",disabled:!1,spellCheck:!1,delimiter:""};var XE=YE;const ZE=p.module("DateInput"),$E="".concat("[12][0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])"," ").concat("([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]\\.[0-9]{3}\u200b[0-9]{3}\u200b[0-9]{3}"),QE="yyyy-MM-dd HH:mm:ss.SSSSSSSSS",JE="2019-01-01 00:00:00.000\u200b000\u200b000",ew=[JE],tw=e=>{const{className:t,defaultValue:n,onChange:a}=e,[s,r]=Object(i.useState)((e=>{const t=va.i18n.DateTimeFormat.format(QE,e);return"".concat(t.substring(0,23),"\u200b").concat(t.substring(23,26),"\u200b").concat(t.substring(26))})(n)),[o,l]=Object(i.useState)(null);function c(e,t,n,i,a){const s=i-n+1,r=((parseInt(t,10)-e-n)%s+s)%s+n;return"".concat(r).padStart(a,"0")}return Object(DC.jsx)(HE,{className:t,pattern:$E,example:ew,getNextSegmentValue:function(e,t,n){const{selectionStart:i}=e;return 0===i?c(t,n,1900,2099,4):5===i?c(t,n,1,12,2):8===i?c(t,n,1,31,2):11===i?c(t,n,0,23,2):17===i||14===i?c(t,n,0,59,2):20===i||24===i||28===i?c(t,n,0,999,3):n},value:s,onChange:function(e){ZE.debug("handleChange",e),r(e),a(e)},onSelect:function(e){l(e)},selection:o})};var nw;tw.defaultProps={className:"",defaultValue:(nw=JE,va.i18n.DateTimeFormat.parse(QE,nw.replace(/\u200B/g,""))),onChange:()=>{}};var iw=tw;class aw extends i.Component{constructor(e){super(e),this.handleRadioChange=this.handleRadioChange.bind(this),this.handleToggleClick=this.handleToggleClick.bind(this),this.handleSearchInputChange=this.handleSearchInputChange.bind(this),this.example=[{title:"Title 1",value:"Value 1"},{title:"Title 2",value:"Value 2"},{title:"Title 3",value:"Value 3"},{title:"Title 4",value:"Value 4"},{title:"Title 5",value:"Value 5"},{title:"Title 6",value:"Value 6"},{title:"Title 7",value:"Value 7"},{title:"Title 8",value:"Value 8"},{title:"Title 9",value:"Value 9"},{title:"Title 9",value:"Value 9"},{title:"Title 10",value:"Value 10"},{title:"Title 11",value:"Value 11"},{title:"Title 12",value:"Value 12"}],this.timeouts=[{title:"1 minute",value:6e4},{title:"5 minutes",value:3e5},{title:"20 minutes",value:12e5},{title:"45 minutes",value:27e5},{title:"1 hour",value:36e5},{title:"4 hours",value:144e5}],this.state={on:!1,searchValue:"",check1:!0,check2:!1,check3:!1,check4:!1,check5:null,radioValue:"1",customTimeValue:null,autoResizeTextareaValue:"-DLiveTableMonitor.updateThreads=8 -DLiveTableMonitor.printDependencyInformation=false -Dassertion.heapDump=true -Drequire.heapDump=true -Dassertion.heapDump=true -Drequire.heapDump=true"}}handleRadioChange(e){this.setState({radioValue:e.target.value})}handleToggleClick(){const{on:e}=this.state;this.setState({on:!e})}handleSearchInputChange(e){this.setState({searchValue:e.target.value})}render(){const{on:e,radioValue:t,searchValue:n,check1:i,check2:a,check3:s,check4:r,check5:o,customTimeValue:l,autoResizeTextareaValue:c}=this.state;return Object(DC.jsxs)("div",{className:"style-guide-inputs",children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Inputs"}),Object(DC.jsxs)("div",{className:"row",children:[Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("form",{children:[Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsxs)("label",{htmlFor:"exampleInput1",children:["Input Label",Object(DC.jsx)("input",{type:"text",className:"form-control",id:"exampleInput1","aria-describedby":"emailHelp",placeholder:"Input Placeholder"})]}),Object(DC.jsx)("small",{className:"form-text text-muted",children:"Help text for a form imput"})]}),Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsxs)("label",{htmlFor:"exampleInput2",children:["Input Label",Object(DC.jsx)("input",{type:"text",className:"form-control",id:"exampleInput2","aria-describedby":"emailHelp",placeholder:"Input Disabled",disabled:!0})]}),Object(DC.jsx)("small",{className:"form-text text-muted",children:"Disabled input"})]}),Object(DC.jsx)("div",{className:"form-group",children:Object(DC.jsxs)("label",{htmlFor:"exampleInputPassword1",children:["Password",Object(DC.jsx)("input",{type:"password",className:"form-control",id:"exampleInputPassword1",placeholder:"Password",defaultValue:"123456789"})]})}),Object(DC.jsx)("div",{className:"form-group",children:Object(DC.jsx)(Gc,{value:n,placeholder:"Search Input",onChange:this.handleSearchInputChange})})]})}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("form",{children:[Object(DC.jsx)("h5",{children:" Checkboxes "}),Object(DC.jsx)(Ed,{className:"form-group",checked:i,onChange:()=>this.setState({check1:!i}),children:"Checked checkbox"}),Object(DC.jsx)(Ed,{className:"form-group",checked:a,onChange:()=>this.setState({check2:!a}),children:"Unchecked checkbox"}),Object(DC.jsx)(Ed,{className:"form-group",disabled:!0,children:"Disabled checkbox"}),Object(DC.jsx)(Ed,{className:"form-group",isInvalid:!0,checked:s,onChange:()=>this.setState({check3:!s}),children:"Invalid checkbox"}),Object(DC.jsx)(Ed,{className:"form-group",checked:r,onChange:()=>this.setState({check4:!r}),children:"Add radio button"}),Object(DC.jsx)(Ed,{className:"form-group",checked:o,onChange:()=>{null==o?this.setState({check5:!0}):o?this.setState({check5:!1}):this.setState({check5:null})},children:"Indeterminate Cycle"})]})}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("form",{children:[Object(DC.jsx)("h5",{children:" Radios "}),Object(DC.jsxs)(Jg,{onChange:this.handleRadioChange,value:t,children:[Object(DC.jsx)(tv,{value:"1",children:"Toggle this custom radio"}),Object(DC.jsx)(tv,{value:"2",children:"Or toggle this other custom radio"}),Object(DC.jsx)(tv,{value:"3",disabled:!0,children:"Disabled radio"}),Object(DC.jsx)(tv,{value:"4",isInvalid:!0,children:"Invalid radio"}),r&&Object(DC.jsx)(tv,{value:"5",children:"Extra radio item"})]})]})}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Selection Menu"}),Object(DC.jsxs)("select",{defaultValue:"0",className:"custom-select",children:[Object(DC.jsx)("option",{disabled:!0,value:"0",children:"Custom Selection"}),Object(DC.jsx)("option",{value:"1",children:"One"}),Object(DC.jsx)("option",{value:"2",children:"Two"}),Object(DC.jsx)("option",{value:"3",children:"Three"})]})]}),Object(DC.jsx)("div",{className:"form-group",children:Object(DC.jsxs)("select",{defaultValue:"0",className:"custom-select",disabled:!0,children:[Object(DC.jsx)("option",{disabled:!0,value:"0",children:"Custom Selection"}),Object(DC.jsx)("option",{value:"1",children:"One"}),Object(DC.jsx)("option",{value:"2",children:"Two"}),Object(DC.jsx)("option",{value:"3",children:"Three"})]})}),Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Input with Select"}),Object(DC.jsx)("div",{className:"input-group",children:Object(DC.jsx)(NE,{options:this.example,inputPlaceholder:"10.128.0.8",searchPlaceholder:"Search actions here"})}),Object(DC.jsx)("br",{}),Object(DC.jsx)("div",{className:"input-group",disabled:!0,children:Object(DC.jsx)(NE,{options:this.example,inputPlaceholder:"10.128.0.8",searchPlaceholder:"Search actions here",disabled:!0})})]}),Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"AutoCompleteInput"}),Object(DC.jsx)(LE,{options:this.example,noMatchText:"No Matches."})]})]}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Toggle Buttons"}),Object(DC.jsxs)("div",{className:"form-inline justify-content-between",children:[Object(DC.jsx)("label",{children:String(e)}),Object(DC.jsx)(Dp,{on:e,onClick:this.handleToggleClick})]}),Object(DC.jsxs)("div",{className:"form-inline justify-content-between",children:[Object(DC.jsx)("label",{children:String(!e)}),Object(DC.jsx)(Dp,{on:!e,onClick:this.handleToggleClick})]}),Object(DC.jsxs)("div",{className:"form-inline justify-content-between",children:[Object(DC.jsx)("label",{className:"isInvalid",children:"isInvalid"}),Object(DC.jsx)(Dp,{on:!e,isInvalid:!0,onClick:this.handleToggleClick})]}),Object(DC.jsxs)("div",{className:"form-inline justify-content-between",children:[Object(DC.jsx)("label",{className:"disabled",children:"disabled"}),Object(DC.jsx)(Dp,{on:!e,disabled:!0,onClick:this.handleToggleClick})]})]})}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Time Input"}),Object(DC.jsx)(UE,{}),Object(DC.jsx)("br",{}),Object(DC.jsx)("h5",{children:"Date Input"}),Object(DC.jsx)(iw,{}),Object(DC.jsx)("small",{className:"text-muted",children:"Does not work in mock"}),Object(DC.jsx)("br",{}),Object(DC.jsx)("h5",{children:"Custom Timeselect"}),Object(DC.jsx)(KE,{options:this.timeouts,value:l,onChange:e=>{this.setState({customTimeValue:e})},customText:"Custom Timeout",placeholder:"Select a timeout",valueToTime:e=>Math.round(e/1e3),timeToValue:e=>1e3*e})]})})]}),Object(DC.jsx)("div",{className:"row",children:Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Auto Resize Textarea"}),Object(DC.jsx)(XE,{value:c,delimiter:" -",onChange:e=>{this.setState({autoResizeTextareaValue:e})}})]})})})]})}}var sw=aw;class rw extends i.PureComponent{constructor(e){super(e),this.handleSelect=this.handleSelect.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.selectedItems=[],this.state={items:[],offset:0,itemCount:5e5}}handleSelect(e){const t=this.selectedItems.indexOf(e);t>=0?this.selectedItems.splice(t,1):this.selectedItems.push(e);const n=t<0,{offset:i}=this.state;let{items:a}=this.state;a=[].concat(a);const s=e-i;s>=0&&s<a.length&&(a[s].isSelected=n),this.setState({items:a})}handleViewportChange(e,t){const{itemCount:n}=this.state,i=t-e+1,a=Math.max(0,e-i),s=Math.min(t+i,n),r=[];for(let l=a;l<=s&&l<=n;l+=1){const e="Item ".concat(l),t=this.selectedItems.indexOf(l)>=0;r.push({value:e,isSelected:t})}const o=a;this.setState({offset:o,items:r})}render(){const{offset:e,items:t,itemCount:n}=this.state;return Object(DC.jsx)(Ag,{itemCount:n,items:t,offset:e,onSelect:this.handleSelect,onViewportChange:this.handleViewportChange})}}var ow=rw;class lw extends i.PureComponent{constructor(e){super(e),this.handleSelect=this.handleSelect.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.selectedItems=[],this.state={items:[],offset:0,itemCount:5e5}}handleSelect(e){const{itemCount:t}=this.state;console.log("Item selected at index",e,"/",t)}handleViewportChange(e,t){const{itemCount:n}=this.state,i=t-e+1,a=Math.max(0,e-i),s=Math.min(t+i,n),r=[];for(let l=a;l<=s;l+=1){const e="Item ".concat(l),t=this.selectedItems.indexOf(l)>=0;r.push({value:e,isSelected:t})}const o=a;this.setState({offset:o,items:r})}render(){const{isMultiSelect:e}=this.props,{offset:t,items:n,itemCount:i}=this.state;return Object(DC.jsx)(th,{isMultiSelect:e,itemCount:i,items:n,offset:t,onSelect:this.handleSelect,onViewportChange:this.handleViewportChange})}}lw.defaultProps={isMultiSelect:!1};var cw=lw;var hw=()=>Object(DC.jsxs)("div",{className:"style-guide-inputs",children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Item Lists"}),Object(DC.jsxs)("div",{className:"row",children:[Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Select List"}),Object(DC.jsx)("div",{style:{height:"300px"},children:Object(DC.jsx)(ow,{})})]})}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Item List"}),Object(DC.jsx)("div",{style:{height:"300px"},children:Object(DC.jsx)(cw,{})})]})}),Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsx)("h5",{children:"Multi Select Item List"}),Object(DC.jsx)("div",{style:{height:"300px"},children:Object(DC.jsx)(cw,{isMultiSelect:!0})})]})})]})]});var dw=()=>{const[e,t]=Object(i.useState)(0),[n,s]=Object(i.useState)(!0),r=()=>{t(0)};return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Basic Modals"}),Object(DC.jsx)("div",{style:{padding:"1rem"},children:[1,2,3].map((n=>function(n){return Object(DC.jsxs)(a.a.Fragment,{children:[Object(DC.jsxs)("button",{type:"button",className:"btn btn-primary",style:{marginBottom:"1rem",marginRight:"1rem"},onClick:()=>{t(n)},children:[n," ",n>1?"Actions":"Action"]}),Object(DC.jsx)(um,{isOpen:e===n,headerText:"Header Text",bodyText:"This is where the body text goes",onConfirm:r,onCancel:n>=2?r:null,onDiscard:n>=3?r:null})]},n)}(n)))}),Object(DC.jsx)("h2",{className:"ui-title",children:"Custom Modal"}),Object(DC.jsx)("div",{style:{padding:"1rem"},children:Object(DC.jsx)("div",{className:"modal-dialog theme-bg-light",role:"dialog",children:Object(DC.jsxs)("div",{className:"modal-content",children:[Object(DC.jsxs)("div",{className:"modal-header",children:[Object(DC.jsx)("h5",{className:"modal-title",children:"Modal title"}),Object(DC.jsx)("button",{type:"button",className:"close","data-dismiss":"modal","aria-label":"Close",children:Object(DC.jsx)("span",{"aria-hidden":"true",children:"\xd7"})})]}),Object(DC.jsxs)("div",{className:"modal-body",children:[Object(DC.jsx)("p",{children:"Modal body text goes here."}),Object(DC.jsx)(Ed,{checked:n,onChange:()=>s(!n),children:"Checked checkbox"})]}),Object(DC.jsxs)("div",{className:"modal-footer",children:[Object(DC.jsx)("button",{type:"button",className:"btn btn-outline-primary","data-dismiss":"modal",children:"Close"}),Object(DC.jsx)("button",{type:"button",className:"btn btn-primary",children:"Save changes"})]})]})})})]})};var uw=()=>Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Progress"}),Object(DC.jsxs)("div",{className:"row",children:[Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h5",{children:"Determinate Progress Loader"}),Object(DC.jsx)("br",{}),Object(DC.jsx)("div",{className:"progress",style:{marginBottom:"1rem"},children:Object(DC.jsx)("div",{className:"progress-bar bg-primary",style:{width:"25%"},"aria-valuenow":"25","aria-valuemin":"0","aria-valuemax":"100"})})]}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h5",{children:"Indeterminate Progress Spinner"}),Object(DC.jsx)(Yn,{className:"loading-spinner-large"})]}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h5",{children:"DH Spinner"}),Object(DC.jsx)(Op,{})]}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h5",{children:"Button Progress Spinner"}),Object(DC.jsx)("button",{type:"button",className:"btn btn-primary btn-spinner btn-cancelable",style:{minWidth:"10rem"},children:Object(DC.jsxs)("span",{children:[Object(DC.jsx)(Yn,{}),Object(DC.jsx)("span",{className:"btn-normal-content",children:"Connecting"}),Object(DC.jsx)("span",{className:"btn-hover-content",children:"Cancel"})]})})]})]})]}),mw=n(493),pw=n.n(mw),gw=(n(1461),parseInt(pw.a["handle-size"],10)),vw=parseInt(pw.a["popover-width"],10),fw=86399,bw=e=>{var{startTime:t,endTime:n,onStartTimeChange:s,onEndTimeChange:r,isStartModified:o,isEndModified:l}=e,[c,h]=Object(i.useState)(t>n?n:t),[d,u]=Object(i.useState)(t>n?t:n);return Object(i.useEffect)((()=>{h(t>n?n:t),u(t>n?t:n)}),[t,n]),a.a.createElement("div",{className:"time-slider-popovers"},a.a.createElement("div",{className:"flex",style:{flexBasis:"calc(".concat(c/fw*100,"% - ").concat(vw/2,"px)")}}),a.a.createElement("div",{className:"handle-popper"},a.a.createElement("label",{className:qe()({modified:t<n?o:l})},t<=n?"Start Time":"End Time"),a.a.createElement(UE,{allowValueWrapping:!1,value:c,onChange:function(e){t<=n?s(e):r(e)}})),a.a.createElement("div",{className:"flex-spacer"}),a.a.createElement("div",{className:"handle-popper"},a.a.createElement("label",{className:qe()({modified:t>n?o:l})},t>n?"Start Time":"End Time"),a.a.createElement(UE,{allowValueWrapping:!1,value:d,onChange:function(e){t<=n?r(e):s(e)}})),a.a.createElement("div",{className:"flex",style:{flexBasis:"calc(".concat((fw-d)/fw*100,"% - ").concat(vw/2,"px)")}}))},Cw=e=>{var{startTime:t,endTime:n}=e;return a.a.createElement("div",{className:"track-fills"},t>n&&a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"track-fill track-fill-start",style:{transform:"scaleX(".concat(n/fw,")")}}),a.a.createElement("div",{className:"track-fill track-fill-end",style:{transform:"scaleX(".concat((fw-t)/fw,")")}})),t<n&&a.a.createElement("div",{className:"track-fill track-fill-middle",style:{transform:"translateX(".concat(t/fw*100,"%) scaleX(").concat((n-t)/fw,")")}}))},Sw=e=>{var{track:t,time:n,setTime:s}=e,r=Object(i.useMemo)((()=>{var e=3600,t=gw/2;return n<e?t=n/e*(gw/2):n>82800&&(t=gw/2+1/3599*(n-82800)*(gw/2)),"translateX(calc(".concat(n/fw*100,"% - ").concat(t,"px))")}),[n]),o=Object(i.useCallback)((e=>{if(!t.current)return 0;var n=t.current.getBoundingClientRect(),i=Math.max(e-n.left,0),a=fw*Math.min(1,i/n.width),s=300*Math.round(a/300);return Math.min(fw,s)}),[t]),l=Object(i.useCallback)((e=>{var{clientX:t}=e;s(o(t))}),[s,o]),c=Object(i.useCallback)((e=>{var{clientX:t}=e;s(o(t)),window.removeEventListener("mousemove",l),window.removeEventListener("mouseup",c),document.documentElement.classList.remove("drag-pointer-events-none")}),[s,o,l]),h=Object(i.useCallback)((()=>{window.addEventListener("mousemove",l),window.addEventListener("mouseup",c),document.documentElement.classList.add("drag-pointer-events-none")}),[l,c]),d=Object(i.useCallback)((()=>{window.removeEventListener("mousemove",l),window.removeEventListener("mouseup",c),document.documentElement.classList.remove("drag-pointer-events-none")}),[l,c]),u=Object(i.useCallback)((()=>{h()}),[h]);return Object(i.useEffect)((()=>()=>{d()}),[d]),a.a.createElement("div",{className:"handle-track",style:{transform:r}},a.a.createElement("button",{className:"handle",type:"button","aria-label":"Change time",onMouseDown:u}))},Ew=e=>{var{startTime:t,endTime:n,onChange:s,isStartModified:r=!1,isEndModified:o=!1}=e,[l,c]=Object(i.useState)(t),[h,d]=Object(i.useState)(n),u=Object(i.useRef)(null);Object(i.useEffect)((()=>{c(t),d(n)}),[t,n]);var m=Object(i.useCallback)(((e,t)=>{var n=e,i=t;n===i&&(i<fw?i+=1:n-=1),c(n),d(i),s({startTime:n,endTime:i})}),[c,d,s]),p=Object(i.useCallback)((e=>{m(e,h)}),[m,h]),g=Object(i.useCallback)((e=>{m(l,e)}),[m,l]);return a.a.createElement("div",{className:"time-slider"},a.a.createElement(bw,{startTime:l,endTime:h,onStartTimeChange:p,onEndTimeChange:g,isStartModified:r,isEndModified:o}),a.a.createElement("div",{className:"track",ref:u},a.a.createElement(Cw,{startTime:l,endTime:h}),a.a.createElement("div",{className:"ticks"},Array(24).fill(null).map(((e,t)=>a.a.createElement("div",{className:"tick",key:t})))),a.a.createElement(Sw,{track:u,time:l,setTime:p}),a.a.createElement(Sw,{track:u,time:h,setTime:g})),a.a.createElement("div",{className:"tick-labels"},a.a.createElement("div",{className:"tick-label"},"0:00"),a.a.createElement("div",{className:"tick-label-wrapper"},Array(24).fill(null).map(((e,t)=>a.a.createElement("div",{className:"tick-label",key:t},"".concat(t+1,":00")))))))};class ww extends i.PureComponent{constructor(e){super(e),this.handleSliderChange=this.handleSliderChange.bind(this),this.state={startTime:21600,endTime:64800}}handleSliderChange(e){const{startTime:t,endTime:n}=e;this.setState({startTime:t}),this.setState({endTime:n})}render(){const{startTime:e,endTime:t}=this.state;return Object(DC.jsxs)("div",{className:"style-guide-inputs",children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Time Slider"}),Object(DC.jsx)(Ew,{startTime:e,endTime:t,onChange:this.handleSliderChange}),Object(DC.jsxs)("p",{children:["StartTime: ",Ya.formatTime(e)]}),Object(DC.jsxs)("p",{children:["EndTime: ",Ya.formatTime(t)]})]})}}var yw=ww;var Tw=()=>{const e=[dn,Qe].map((e=>Object(DC.jsx)(Ke.a,{icon:e},"".concat(e.prefix,"-").concat(e.iconName))));return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",title:"Make better looking tooltips than this one!",children:"Tooltips"}),Object(DC.jsxs)("div",{className:"btn btn-primary",style:{cursor:"default",marginBottom:"1rem",marginRight:"1rem"},children:["Simple Tooltip",Object(DC.jsx)(Ol,{children:"Text only content"})]}),Object(DC.jsxs)("div",{className:"btn btn-secondary",style:{cursor:"default",marginBottom:"1rem",marginRight:"1rem"},children:["Complex Tooltip",Object(DC.jsxs)(Ol,{children:[Object(DC.jsxs)("div",{children:["Here is some ",Object(DC.jsx)("i",{children:"cool"})," ",Object(DC.jsx)("b",{children:"text"})]}),Object(DC.jsx)("hr",{}),Object(DC.jsx)("div",{children:"And some icons down here"}),Object(DC.jsxs)("div",{children:[Object(DC.jsx)(Yn,{}),e]})]})]}),Object(DC.jsxs)("div",{className:"btn btn-success",style:{cursor:"default",marginBottom:"1rem",marginRight:"1rem"},children:["Interactive Tooltip",Object(DC.jsxs)(Ol,{interactive:!0,children:[Object(DC.jsx)("div",{children:"This tooltip is interactive."}),Object(DC.jsx)("hr",{}),Object(DC.jsx)("button",{type:"button",className:"btn btn-primary",onClick:()=>{alert("Button clicked!")},children:"Show Alert"})]})]})]})};var Ow=()=>Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Typograpy"}),Object(DC.jsxs)("div",{className:"row",children:[Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h1",{className:"text-muted",children:"h1. Unused"}),Object(DC.jsx)("h2",{className:"text-muted",children:"h2. Unused"}),Object(DC.jsx)("h3",{className:"text-muted",children:"h3. Unused"}),Object(DC.jsx)("h4",{children:"h4. Standard Heading"}),Object(DC.jsx)("h5",{children:"h5. Small Heading"}),Object(DC.jsx)("h6",{className:"text-muted",children:"h6. Unused"})]}),Object(DC.jsxs)("div",{className:"col",children:[Object(DC.jsx)("h4",{children:"Fonts"}),Object(DC.jsx)("p",{children:"UI: Fira Sans;"}),Object(DC.jsx)("p",{className:"text-monospace",children:"Code: Fira Mono;"}),Object(DC.jsx)("p",{children:'Tables: Fira Sans; font-feature-settings: "tnum";'}),Object(DC.jsx)("p",{children:"Default font-size: 14px = 1rem"})]})]})]});n(1462);class Mw extends i.PureComponent{constructor(e){super(e),this.getViewportItems=Object(ua.a)(((e,t,n)=>null==e||null==t?[]:n.slice(e,t))),this.handleSelectionChange=this.handleSelectionChange.bind(this),this.handleViewportChange=this.handleViewportChange.bind(this),this.itemList=a.a.createRef(),this.selectedItems=[],this.state={topRow:null,bottomRow:null}}focusItem(e){this.itemList.current&&this.itemList.current.focusItem(e)}handleSelectionChange(e){console.log("Selection changed",e);const{onSelectionChange:t}=this.props;t(e)}handleViewportChange(e,t){const{items:n}=this.props,i=t-e+1,a=Math.max(0,e-i),s=Math.min(t+i,n.length);this.setState({topRow:a,bottomRow:s})}render(){const{draggablePrefix:e,droppableId:t,isDragDisabled:n,isDropDisabled:i,isMultiSelect:a,items:s,selectedRanges:r}=this.props,{topRow:o,bottomRow:l}=this.state;return Object(DC.jsx)(Pv,{draggablePrefix:e,droppableId:t,isDragDisabled:n,isDropDisabled:i,isMultiSelect:a,itemCount:s.length,items:this.getViewportItems(o,l,s),offset:null!==o&&void 0!==o?o:0,onSelectionChange:this.handleSelectionChange,onViewportChange:this.handleViewportChange,ref:this.itemList,selectedRanges:r})}}Mw.defaultProps={items:[],draggablePrefix:"draggable-item",droppableId:"droppable-item-list",isDragDisabled:!1,isDropDisabled:!1,isMultiSelect:!1,onSelectionChange:()=>{},selectedRanges:[]};var Nw=Mw;const Dw=["Draggable Only","Drag and Drop","Droppable Only"],xw=[{isDropDisabled:!0},{},{isDragDisabled:!0}],Rw=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Item",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3;const n=[];for(let i=0;i<t;i+=1)n.push("".concat(e,"-").concat(i));return n};class Iw extends i.Component{static handleDragStart(e){console.log("handleDragStart",e)}static handleDragUpdate(e){console.log("handleDragUpdate",e)}constructor(e){super(e),this.getSelectionChangeHandler=Lr()((e=>this.handleSelectionChange.bind(this,e))),this.getDraggableList=Lr()(((e,t,n,i)=>Object(DC.jsx)(Nw,{items:e,droppableId:Pv.getDraggableId("drop-list",i),draggablePrefix:Pv.getDraggableId("draggable-item",i),onSelectionChange:this.getSelectionChangeHandler(i),isMultiSelect:!0,ref:n,selectedRanges:t,...xw[i]}))),this.handleDragEnd=this.handleDragEnd.bind(this),this.animationFrame=null;const t=[],n=[],i=[];for(let s=0;s<Dw.length;s+=1)t[s]=Rw(Dw[s]),n[s]=[],i[s]=a.a.createRef();this.state={items:t,lists:i,selectedRanges:n}}componentWillUnmount(){cancelAnimationFrame(this.animationFrame)}handleDragEnd(e){console.log("handleDragEnd",e);const{source:t,destination:n}=e;if(null==t||null==n)return;const i=Pv.getDraggableIndex(t.droppableId),a=Pv.getDraggableIndex(n.droppableId),s=i===a;let r=n.index;s&&t.index<n.index&&(r+=1);let o=r;this.setState((e=>{let{items:t,selectedRanges:n}=e;const l=[...t[i]],c=s?l:[...t[a]],h=Ev.reorder(l,n[i],c,r),d=[...t];d[i]=l,d[a]=c,o=s?Ev.adjustDestinationIndex(r,n[a]):r;const u=[...n];return u[i]=[],u[a]=[[o,o+h.length-1]],{items:d,selectedRanges:u}}),(()=>{cancelAnimationFrame(this.animationFrame),this.animationFrame=requestAnimationFrame((()=>{this.animationFrame=null;const{lists:e}=this.state;e[a].current.focusItem(o)}))}))}handleSelectionChange(e,t){this.setState((n=>{let{selectedRanges:i}=n;const a=[...i];return a[e]=t,{selectedRanges:a}}))}render(){const{items:e,lists:t,selectedRanges:n}=this.state;return Object(DC.jsxs)("div",{className:"style-guide-inputs",children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Drag and Drop Lists"}),Object(DC.jsx)("div",{className:"row",children:Object(DC.jsx)(Kg.a,{onDragStart:Iw.handleDragStart,onDragUpdate:Iw.handleDragUpdate,onDragEnd:this.handleDragEnd,children:Dw.map(((i,a)=>Object(DC.jsx)("div",{className:"col",children:Object(DC.jsxs)("div",{className:"form-group",children:[Object(DC.jsxs)("h5",{children:[i," List"]}),Object(DC.jsx)("div",{style:{height:"300px"},children:this.getDraggableList(e[a],n[a],t[a],a)})]})},i)))})})]})}}var Lw,Fw=Iw;!function(e){e.SUBMENU="SUBMENU",e.PAGE="PAGE",e.SWITCH="SWITCH"}(Lw||(Lw={}));let kw=0;function Aw(){const e=kw;return kw+=1,e}function Pw(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;return Math.floor(Math.random()*t)+e}function _w(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Aw();return{id:t,type:e}}function Hw(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Pw(),t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Pw(),n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Pw();const i=[];for(let a=0;a<e;a+=1)i.push(_w(Lw.SUBMENU));for(let a=0;a<t;a+=1)i.push(_w(Lw.PAGE));for(let a=0;a<n;a+=1)i.push(_w(Lw.SWITCH));return i}function jw(e){let{type:t,id:n}=e;switch(t){case Lw.SUBMENU:return"Submenu ".concat(n);case Lw.PAGE:return"Page ".concat(n);case Lw.SWITCH:return"Switch ".concat(n)}}var Vw=()=>{const[e,t]=Object(i.useState)([]),[n,a]=Object(i.useState)(new Map),s=Object(i.useCallback)((n=>{t([...e,n])}),[e,t]),r=Object(i.useCallback)((()=>{const n=[...e];n.pop(),t(n)}),[e,t]),o=Object(i.useCallback)((()=>{const n=[e[0]];t(n)}),[e,t]),l=Object(i.useCallback)((e=>{var t;const i=null!==(t=n.get(e))&&void 0!==t&&t,s=new Map(n);s.set(e,!i),a(s)}),[n,a]),c=Object(i.useCallback)((t=>{const n=e[e.length-1],{items:i}=n;if(!i)throw new Error("Navigation handleSelect triggered without items to select");const a=i[t];switch(a.type){case Lw.PAGE:s({title:jw(a)});break;case Lw.SUBMENU:s({title:jw(a),items:Hw()});break;case Lw.SWITCH:l(a.id)}}),[e,l,s]);Object(i.useEffect)((()=>{t([{title:"Navigation Menu",items:Hw()}])}),[]);const h=Object(i.useMemo)((()=>e.map(((e,t)=>{let{items:i,title:a}=e;if(!i)return Object(DC.jsx)(Np,{onBack:r,onClose:o,title:a,children:Object(DC.jsx)("div",{children:"Page content!"})},a);let s=null;if(i){const e=i.map((e=>{const t=jw(e),i=function(e){let{type:t}=e;switch(t){case Lw.SUBMENU:return Dt;case Lw.PAGE:return vt;case Lw.SWITCH:return Hn}}(e);let a,s;var r;e.type===Lw.SWITCH&&(a=null!==(r=n.get(e.id))&&void 0!==r&&r,s=()=>{c(e.id)});return{title:t,icon:i,isOn:a,onChange:s}}));s=Object(DC.jsx)(Ip,{onSelect:c,items:e})}else s=Object(DC.jsx)("div",{children:"Page content"});return Object(DC.jsx)(Np,{onBack:t>0?r:void 0,onClose:t>0?o:void 0,title:a,children:s},a)}))),[e,n,c,r,o]);return Object(DC.jsxs)("div",{children:[Object(DC.jsx)("h2",{className:"ui-title",children:"Navigations"}),Object(DC.jsx)("div",{className:"navigations",children:Object(DC.jsx)(Mp,{children:h})})]})};var zw=()=>Object(DC.jsxs)("div",{className:"container style-guide-container",children:[Object(DC.jsx)("div",{style:{marginTop:"2rem",paddingBottom:"1rem"},children:Object(DC.jsx)("h1",{style:{paddingTop:"2rem"},children:"Deephaven UI Components"})}),Object(DC.jsx)(Ow,{}),Object(DC.jsx)(sE,{}),Object(DC.jsx)(eE,{}),Object(DC.jsx)(uw,{}),Object(DC.jsx)(QS,{}),Object(DC.jsx)(sw,{}),Object(DC.jsx)(hw,{}),Object(DC.jsx)(Fw,{}),Object(DC.jsx)(yw,{}),Object(DC.jsx)(dE,{}),Object(DC.jsx)(dw,{}),Object(DC.jsx)(oE,{}),Object(DC.jsx)(mE,{}),Object(DC.jsx)(Vw,{}),Object(DC.jsx)(Tw,{}),Object(DC.jsx)(yE,{}),Object(DC.jsx)(vE,{}),Object(DC.jsx)(SE,{}),Object(DC.jsx)(aE,{}),Object(DC.jsx)(Hf,{})]});const Uw=e=>{const{workspace:t,setWorkspace:n}=e;return Object(i.useEffect)((()=>{n(PS.makeDefaultWorkspace())}),[n]),Object(DC.jsx)(DC.Fragment,{children:t&&Object(DC.jsx)(zw,{})})};Uw.defaultProps={workspace:null};var Bw=Object(o.b)((e=>({workspace:P(e)})),{setWorkspace:Q})(Uw);var Ww=()=>Object(DC.jsx)(Fe.a,{basename:"/ide/",children:Object(DC.jsxs)(ke.d,{children:[Object(DC.jsx)(ke.b,{exact:!0,path:"/",component:ZS}),Object(DC.jsx)(ke.b,{path:"/styleguide",component:Bw}),Object(DC.jsx)(ke.a,{from:"*",to:"/"})]})});Boolean("localhost"===window.location.hostname||"[::1]"===window.location.hostname||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));UC.enable(),BC.enable(),r.a.render(Object(DC.jsx)(o.a,{store:Le,children:Object(DC.jsx)(Ww,{})}),document.getElementById("root")),"serviceWorker"in navigator&&navigator.serviceWorker.getRegistrations().then((e=>{e.forEach((e=>{e.scope.endsWith("/download/")||e.unregister()}))})),cS.registerOnLoaded(),I.init(),window["__react-beautiful-dnd-disable-dev-warnings"]=!0},157:function(e,t,n){e.exports={"paper-bgcolor":"#2d2a2e","plot-bgcolor":"#322f33","title-color":"#f0f0ee",colorway:"#76d9e4 #9edc6f #fcd65b #aa9af4 #f37e3f #f95d84 #f0f0ee",gridcolor:"#403e41",linecolor:"#5b5a5c",zerolinecolor:"#c0bfbf",activecolor:"#4878ea",rangebgcolor:"rgba(91, 90, 92, 0.7)","area-color":"#76d9e4","trend-color":"#d5f0c1","line-color":"#9edc6f","error-band-line-color":"white","error-band-fill-color":"rgba(213, 240, 193, 0.1)","ohlc-increasing":"#9edc6f","ohlc-decreasing":"#f95d84"}},350:function(e,t,n){e.exports={"title-downsampling-in-progress":"Downsampling in progress...","title-downsampling-failed":"Downsampling failed","title-downsampling-enabled":"Downsampling enabled, click to disable","title-downsampling-disabled":"Downsampling disabled, click to enable","plotly-notifier":"Chart_plotly-notifier__Owqzt","notifier-note":"Chart_notifier-note__28NqW","chart-wrapper":"Chart_chart-wrapper__3mkea","plot-container":"Chart_plot-container__2WVVQ",cartesianlayer:"Chart_cartesianlayer__3vVZK",hovertext:"Chart_hovertext__75sIN",axistext:"Chart_axistext__3MMqk",zoomlayer:"Chart_zoomlayer__28AVN",zoombox:"Chart_zoombox__2Vjiz","zoombox-corners":"Chart_zoombox-corners__14F-C","js-plotly-plot":"Chart_js-plotly-plot__1c3yl",plotly:"Chart_plotly__1o5q0",modebar:"Chart_modebar__cvCDt","modebar-btn":"Chart_modebar-btn__11DCT","fa-spin":"Chart_fa-spin__2jHrZ"}},479:function(e,t,n){var i,a;!function(s){var r={config:{},container:{},controls:{},errors:{},items:{},utils:{}};r.utils.F=function(){},r.utils.extend=function(e,t){e.prototype=r.utils.createObject(t.prototype),e.prototype.contructor=e},r.utils.createObject=function(e){return"function"===typeof Object.create?Object.create(e):(r.utils.F.prototype=e,new r.utils.F)},r.utils.objectKeys=function(e){var t,n;if("function"===typeof Object.keys)return Object.keys(e);for(n in t=[],e)t.push(n);return t},r.utils.getHashValue=function(e){var t=location.hash.match(new RegExp(e+"=([^&]*)"));return t?t[1]:null},r.utils.getQueryStringParam=function(e){if(window.location.hash)return r.utils.getHashValue(e);if(!window.location.search)return null;var t,n,i=window.location.search.substr(1).split("&"),a={};for(n=0;n<i.length;n++)a[(t=i[n].split("="))[0]]=t[1];return a[e]||null},r.utils.copy=function(e,t){for(var n in t)e[n]=t[n];return e},r.utils.animFrame=function(e){return(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)})((function(){e()}))},r.utils.indexOf=function(e,t){if(!(t instanceof Array))throw new Error("Haystack is not an Array");if(t.indexOf)return t.indexOf(e);for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1},"object"!=typeof Int8Array?r.utils.isFunction=function(e){return"function"==typeof e||!1}:r.utils.isFunction=function(e){return"[object Function]"===toString.call(e)},r.utils.fnBind=function(e,t,n){if(void 0!==Function.prototype.bind)return Function.prototype.bind.apply(e,[t].concat(n||[]));var i=function(){var a=(n||[]).concat(Array.prototype.slice.call(arguments,0));if(!(this instanceof i))return e.apply(t,a);e.apply(this,a)};return i.prototype=e.prototype,i},r.utils.removeFromArray=function(e,t){var n=r.utils.indexOf(e,t);if(-1===n)throw new Error("Can't remove item from array. Item is not in the array");t.splice(n,1)},r.utils.now=function(){return"function"===typeof Date.now?Date.now():(new Date).getTime()},r.utils.getUniqueId=function(){return(1e15*Math.random()).toString(36).replace(".","")},r.utils.filterXss=function(e,t){var n=e.replace(/javascript/gi,"j&#97;vascript").replace(/expression/gi,"expr&#101;ssion").replace(/onload/gi,"onlo&#97;d").replace(/script/gi,"&#115;cript").replace(/onerror/gi,"on&#101;rror");return!0===t?n:n.replace(/>/g,"&gt;").replace(/</g,"&lt;")},r.utils.stripTags=function(e){return s.trim(e.replace(/(<([^>]+)>)/gi,""))},r.utils.EventEmitter=function(){this._mSubscriptions={},this._mSubscriptions[r.utils.EventEmitter.ALL_EVENT]=[],this.on=function(e,t,n){if(!r.utils.isFunction(t))throw new Error("Tried to listen to event "+e+" with non-function callback "+t);this._mSubscriptions[e]||(this._mSubscriptions[e]=[]),this._mSubscriptions[e].push({fn:t,ctx:n})},this.emit=function(e){var t,n,i;i=Array.prototype.slice.call(arguments,1);var a=this._mSubscriptions[e];if(a)for(a=a.slice(),t=0;t<a.length;t++)n=a[t].ctx||{},a[t].fn.apply(n,i);i.unshift(e);var s=this._mSubscriptions[r.utils.EventEmitter.ALL_EVENT].slice();for(t=0;t<s.length;t++)n=s[t].ctx||{},s[t].fn.apply(n,i)},this.unbind=function(e,t,n){if(!this._mSubscriptions[e])throw new Error("No subscribtions to unsubscribe for event "+e);var i,a=!1;for(i=0;i<this._mSubscriptions[e].length;i++)t&&this._mSubscriptions[e][i].fn!==t||n&&n!==this._mSubscriptions[e][i].ctx||(this._mSubscriptions[e].splice(i,1),a=!0);if(!1===a)throw new Error("Nothing to unbind for "+e)},this.off=this.unbind,this.trigger=this.emit},r.utils.EventEmitter.ALL_EVENT="__all",r.utils.DragListener=function(e,t){r.utils.EventEmitter.call(this),this._eElement=s(e),this._oDocument=s(document),this._eBody=s(document.body),this._destroyAfterMouseUp=t||!1,this._nDelay=400,this._timeout=null,this._nDistance=10,this._nX=0,this._nY=0,this._nOriginalX=0,this._nOriginalY=0,this._bDragging=!1,this._fMove=r.utils.fnBind(this.onMouseMove,this),this._fUp=r.utils.fnBind(this.onMouseUp,this),this._fDown=r.utils.fnBind(this.onMouseDown,this),this._eElement.on("mousedown",this._fDown)},r.utils.DragListener.timeout=null,r.utils.copy(r.utils.DragListener.prototype,{destroy:function(){this._eElement.unbind("mousedown",this._fDown),this._oDocument.unbind("mouseup",this._fUp),this._eElement=null,this._oDocument=null,this._eBody=null,clearTimeout(this._timeout),this._timeout=null},onMouseDown:function(e){if(e.preventDefault(),0===e.button){var t=this._getCoordinates(e);this._nOriginalX=t.x,this._nOriginalY=t.y,this._oDocument.on("mousemove",this._fMove),this._oDocument.one("mouseup",this._fUp),this._timeout=setTimeout(r.utils.fnBind(this._startDrag,this),this._nDelay)}},onMouseMove:function(e){if(null!=this._timeout){e.preventDefault();var t=this._getCoordinates(e);this._nX=t.x-this._nOriginalX,this._nY=t.y-this._nOriginalY,!1===this._bDragging&&(Math.abs(this._nX)>this._nDistance||Math.abs(this._nY)>this._nDistance)&&this._startDrag(),this._bDragging&&this.emit("drag",this._nX,this._nY,e)}},onMouseUp:function(e){null!=this._timeout&&(clearTimeout(this._timeout),this._oDocument.unbind("mousemove",this._fMove),this._oDocument.unbind("mouseup",this._fUp),this._oDocument.find("iframe").css("pointer-events",""),!0===this._bDragging&&(this._bDragging=!1,this.emit("dragStop",e,this._nOriginalX+this._nX)),this._eBody&&this._eBody.removeClass("lm_dragging"),this._eElement&&this._eElement.removeClass("lm_dragging"),this._destroyAfterMouseUp&&this.destroy())},_startDrag:function(){clearTimeout(this._timeout),this._bDragging=!0,this._eBody.addClass("lm_dragging"),this._eElement.addClass("lm_dragging"),this._oDocument.find("iframe").css("pointer-events","none"),this.emit("dragStart",this._nOriginalX,this._nOriginalY)},_getCoordinates:function(e){return{x:(e=e.originalEvent&&e.originalEvent.touches?e.originalEvent.touches[0]:e).pageX,y:e.pageY}}}),r.LayoutManager=function(e,t){if(!s||"function"!==typeof s.noConflict){throw'Please either expose $ on GoldenLayout\'s scope (e.g. window) or add "jquery" to ',"your paths when using RequireJS/AMD",new Error('jQuery is missing as dependency for GoldenLayout. Please either expose $ on GoldenLayout\'s scope (e.g. window) or add "jquery" to your paths when using RequireJS/AMD')}r.utils.EventEmitter.call(this),this.isInitialised=!1,this._isFullPage=!1,this._resizeTimeoutId=null,this._components={"lm-react-component":r.utils.ReactComponentHandler},this._fallbackComponent=void 0,this._itemAreas=[],this._resizeFunction=r.utils.fnBind(this._onResize,this),this._unloadFunction=r.utils.fnBind(this._onUnload,this),this._windowBlur=this._windowBlur.bind(this),this._windowFocus=this._windowFocus.bind(this),this._maximisedItem=null,this._maximisePlaceholder=s('<div class="lm_maximise_place"></div>'),this._creationTimeoutPassed=!1,this._subWindowsCreated=!1,this._dragSources=[],this._updatingColumnsResponsive=!1,this._firstLoad=!0,this.width=null,this.height=null,this.root=null,this.openPopouts=[],this.selectedItem=null,this.isSubWindow=!1,this.eventHub=new r.utils.EventHub(this),this.config=this._createConfig(e),this.container=t,this.dropTargetIndicator=null,this.transitionIndicator=null,this.tabDropPlaceholder=s('<div class="lm_drop_tab_placeholder"></div>'),!0===this.isSubWindow&&s("body").css("visibility","hidden"),this._typeToItem={column:r.utils.fnBind(r.items.RowOrColumn,this,[!0]),row:r.utils.fnBind(r.items.RowOrColumn,this,[!1]),stack:r.items.Stack,component:r.items.Component}},r.LayoutManager.__lm=r,r.LayoutManager.minifyConfig=function(e){return(new r.utils.ConfigMinifier).minifyConfig(e)},r.LayoutManager.unminifyConfig=function(e){return(new r.utils.ConfigMinifier).unminifyConfig(e)},r.utils.copy(r.LayoutManager.prototype,{registerComponent:function(e,t){if("function"!==typeof t&&(null==t||null==t.render||"function"!==typeof t.render))throw new Error("Please register a constructor function");if(void 0!==this._components[e])throw new Error("Component "+e+" is already registered");return this._components[e]=t,function(){if(void 0===this._components[e])throw new Error("Component "+e+" is not registered");delete this._components[e]}.bind(this)},setFallbackComponent:function(e){this._fallbackComponent=e},toConfig:function(e){var t,n,i;if(!1===this.isInitialised)throw new Error("Can't create config, layout not yet initialised");if(e&&!(e instanceof r.items.AbstractContentItem))throw new Error("Root must be a ContentItem");for((t={settings:r.utils.copy({},this.config.settings),dimensions:r.utils.copy({},this.config.dimensions),labels:r.utils.copy({},this.config.labels)}).content=[],n=function(e,t){var i,a;for(i in t.config)"content"!==i&&(e[i]=t.config[i]);if("lm-react-component"===e.componentName&&(e.type="react-component"),t.contentItems.length)for(e.content=[],a=0;a<t.contentItems.length;a++)e.content[a]={},n(e.content[a],t.contentItems[a])},n(t,e?{contentItems:[e]}:this.root),this._$reconcilePopoutWindows(),t.openPopouts=[],i=0;i<this.openPopouts.length;i++)t.openPopouts.push(this.openPopouts[i].toConfig());return t.maximisedItemId=this._maximisedItem?"__glMaximised":null,t},getComponent:function(e){return this._components[e]},getFallbackComponent:function(){return this._fallbackComponent},init:function(){if(!1===this._subWindowsCreated&&(this._createSubWindows(),this._subWindowsCreated=!0),"loading"!==document.readyState&&null!==document.body){if(!0===this.isSubWindow&&!1===this._creationTimeoutPassed)return setTimeout(r.utils.fnBind(this.init,this),7),void(this._creationTimeoutPassed=!0);!0===this.isSubWindow&&this._adjustToWindowMode(),this._setContainer(),this.dropTargetIndicator=new r.controls.DropTargetIndicator(this.container),this.transitionIndicator=new r.controls.TransitionIndicator,this.updateSize(),this._create(this.config),this._bindEvents(),this.isInitialised=!0,this._adjustColumnsResponsive(),this.emit("initialised")}else s(document).ready(r.utils.fnBind(this.init,this))},updateSize:function(e,t){2===arguments.length?(this.width=e,this.height=t):(this.width=this.container.width(),this.height=this.container.height()),!0===this.isInitialised&&(this.root.callDownwards("setSize",[this.width,this.height]),this._maximisedItem&&(this._maximisedItem.element.width(this.container.width()),this._maximisedItem.element.height(this.container.height()),this._maximisedItem.callDownwards("setSize")),this._adjustColumnsResponsive())},destroy:function(){!1!==this.isInitialised&&(this._onUnload(),s(window).off("resize",this._resizeFunction),s(window).off("unload beforeunload",this._unloadFunction),s(window).off("blur.lm").off("focus.lm"),this.root.callDownwards("_$destroy",[],!0),this.root.contentItems=[],this.tabDropPlaceholder.remove(),this.dropTargetIndicator.destroy(),this.transitionIndicator.destroy(),this.eventHub.destroy(),this._dragSources.forEach((function(e){e._dragListener.destroy(),e._element=null,e._itemConfig=null,e._dragListener=null})),this._dragSources=[])},createContentItem:function(e,t){var n;if("string"!==typeof e.type)throw new r.errors.ConfigurationError("Missing parameter 'type'",e);if("react-component"===e.type&&(e.type="component",e.componentName="lm-react-component"),!this._typeToItem[e.type])throw n="Unknown type '"+e.type+"'. Valid types are "+r.utils.objectKeys(this._typeToItem).join(","),new r.errors.ConfigurationError(n);return"component"!==e.type||t instanceof r.items.Stack||!t||!0===this.isSubWindow&&t instanceof r.items.Root||(e={type:"stack",width:e.width,height:e.height,content:[e]}),new this._typeToItem[e.type](this,e,t)},createPopout:function(e,t,n,i){var a,s,o,l,c,h,d=e,u=e instanceof r.items.AbstractContentItem,m=this;if(n=n||null,u){for(d=this.toConfig(e).content,n=r.utils.getUniqueId(),l=e.parent,c=e;1===l.contentItems.length&&!l.isRoot;)l=l.parent,c=c.parent;l.addId(n),isNaN(i)&&(i=r.utils.indexOf(c,l.contentItems))}else d instanceof Array||(d=[d]);return!t&&u&&(a=window.screenX||window.screenLeft,s=window.screenY||window.screenTop,t={left:a+(o=e.element.offset()).left,top:s+o.top,width:e.element.width(),height:e.element.height()}),t||u||(t={left:window.screenX||window.screenLeft+20,top:window.screenY||window.screenTop+20,width:500,height:309}),u&&e.remove(),(h=new r.controls.BrowserPopout(d,t,n,i,this)).on("initialised",(function(){m.emit("windowOpened",h)})),h.on("closed",(function(){m._$reconcilePopoutWindows()})),this.openPopouts.push(h),h},createDragSource:function(e,t){this.config.settings.constrainDragToContainer=!1;var n=new r.controls.DragSource(s(e),t,this);return this._dragSources.push(n),n},createDragSourceFromEvent:function(e,t){return this.config.settings.constrainDragToContainer=!1,new r.controls.DragSourceFromEvent(e,this,t)},selectItem:function(e,t){if(!0!==this.config.settings.selectionEnabled)throw new Error("Please set selectionEnabled to true to use this feature");e!==this.selectedItem&&(null!==this.selectedItem&&this.selectedItem.deselect(),e&&!0!==t&&e.select(),this.selectedItem=e,this.emit("selectionChanged",e))},_$maximiseItem:function(e){null!==this._maximisedItem&&this._$minimiseItem(this._maximisedItem),this._maximisedItem=e,this._maximisedItem.addId("__glMaximised"),e.element.addClass("lm_maximised"),e.element.after(this._maximisePlaceholder),this.root.element.prepend(e.element),e.element.width(this.container.width()),e.element.height(this.container.height()),e.callDownwards("setSize"),this._maximisedItem.emit("maximised"),this.emit("stateChanged")},_$minimiseItem:function(e){e.element.removeClass("lm_maximised"),e.removeId("__glMaximised"),this._maximisePlaceholder.after(e.element),this._maximisePlaceholder.remove(),e.parent.callDownwards("setSize"),this._maximisedItem=null,e.emit("minimised"),this.emit("stateChanged")},_$closeWindow:function(){window.setTimeout((function(){window.close()}),1)},_$getArea:function(e,t){var n,i,a=1/0,s=null;for(n=0;n<this._itemAreas.length;n++)e>(i=this._itemAreas[n]).x1&&e<i.x2&&t>i.y1&&t<i.y2&&a>i.surface&&(a=i.surface,s=i);return s},_$createRootItemAreas:function(){var e={y2:"y1",x2:"x1",y1:"y2",x1:"x2"};for(var t in e){var n=this.root._$getArea();n.side=t,"2"==e[t][1]?n[t]=n[e[t]]-50:n[t]=n[e[t]]+50,n.surface=(n.x2-n.x1)*(n.y2-n.y1),this._itemAreas.push(n)}},_$calculateItemAreas:function(){var e,t,n=this._getAllContentItems();if(this._itemAreas=[],1!==n.length){for(this._$createRootItemAreas(),e=0;e<n.length;e++)if(n[e].isStack&&null!==(t=n[e]._$getArea()))if(t instanceof Array)this._itemAreas=this._itemAreas.concat(t);else{this._itemAreas.push(t);var i={};r.utils.copy(i,t),r.utils.copy(i,t.contentItem._contentAreaDimensions.header.highlightArea),i.surface=(i.x2-i.x1)*(i.y2-i.y1),this._itemAreas.push(i)}}else this._itemAreas.push(this.root._$getArea())},_$normalizeContentItem:function(e,t){if(!e)throw new Error("No content item defined");if(r.utils.isFunction(e)&&(e=e()),e instanceof r.items.AbstractContentItem)return e;if(s.isPlainObject(e)&&e.type){var n=this.createContentItem(e,t);return n.callDownwards("_$init"),n}throw new Error("Invalid contentItem")},_$reconcilePopoutWindows:function(){var e,t=[];for(e=0;e<this.openPopouts.length;e++)!1===this.openPopouts[e].getWindow().closed?t.push(this.openPopouts[e]):this.emit("windowClosed",this.openPopouts[e]);this.openPopouts.length!==t.length&&(this.emit("stateChanged"),this.openPopouts=t)},_getAllContentItems:function(){var e=[],t=function(n){if(e.push(n),n.contentItems instanceof Array)for(var i=0;i<n.contentItems.length;i++)t(n.contentItems[i])};return t(this.root),e},_bindEvents:function(){this._isFullPage&&s(window).resize(this._resizeFunction),s(window).on("unload beforeunload",this._unloadFunction).on("blur.lm",this._windowBlur).on("focus.lm",this._windowFocus)},_windowBlur:function(){this.root.element.addClass("lm_window_blur")},_windowFocus:function(){this.root.element.removeClass("lm_window_blur")},_onResize:function(){clearTimeout(this._resizeTimeoutId),this._resizeTimeoutId=setTimeout(r.utils.fnBind(this.updateSize,this),100)},_createConfig:function(e){var t=r.utils.getQueryStringParam("gl-window");t&&(this.isSubWindow=!0,e=localStorage.getItem(t),e=JSON.parse(e),e=(new r.utils.ConfigMinifier).unminifyConfig(e),localStorage.removeItem(t)),e=s.extend(!0,{},r.config.defaultConfig,e);var n=function(e){for(var t in e)"props"!==t&&"object"===typeof e[t]?n(e[t]):"type"===t&&"react-component"===e[t]&&(e.type="component",e.componentName="lm-react-component")};return n(e),!1===e.settings.hasHeaders&&(e.dimensions.headerHeight=0),e},_adjustToWindowMode:function(){var e=s('<div class="lm_popin" title="'+this.config.labels.popin+'"><div class="lm_icon"></div><div class="lm_bg"></div></div>');e.click(r.utils.fnBind((function(){this.emit("popIn")}),this)),document.title=r.utils.stripTags(this.config.content[0].title),s("head").append(s("body link, body style, template, .gl_keep")),this.container=s("body").html("").css("visibility","visible").append(e);document.body.offsetHeight;window.__glInstance=this},_createSubWindows:function(){var e,t;for(e=0;e<this.config.openPopouts.length;e++)t=this.config.openPopouts[e],this.createPopout(t.content,t.dimensions,t.parentId,t.indexInParent)},_setContainer:function(){var e=s(this.container||"body");if(0===e.length)throw new Error("GoldenLayout container not found");if(e.length>1)throw new Error("GoldenLayout more than one container element specified");e[0]===document.body&&(this._isFullPage=!0,s("html, body").css({height:"100%",margin:0,padding:0,overflow:"hidden"})),this.container=e},_create:function(e){var t;if(!(e.content instanceof Array))throw t=void 0===e.content?"Missing setting 'content' on top level of configuration":"Configuration parameter 'content' must be an array",new r.errors.ConfigurationError(t,e);if(e.content.length>1)throw t="Top level content can't contain more then one element.",new r.errors.ConfigurationError(t,e);this.root=new r.items.Root(this,{content:e.content},this.container),this.root.callDownwards("_$init"),"__glMaximised"===e.maximisedItemId&&this.root.getItemsById(e.maximisedItemId)[0].toggleMaximise()},_onUnload:function(){if(!0===this.config.settings.closePopoutsOnUnload)for(var e=0;e<this.openPopouts.length;e++)this.openPopouts[e].close()},_adjustColumnsResponsive:function(){if(this._useResponsiveLayout()&&!this._updatingColumnsResponsive&&this.config.dimensions&&this.config.dimensions.minItemWidth&&0!==this.root.contentItems.length&&this.root.contentItems[0].isRow){this._firstLoad=!1;var e=this.root.contentItems[0].contentItems.length;if(!(e<=1)){var t=this.config.dimensions.minItemWidth;if(!(e*t<=this.width)){this._updatingColumnsResponsive=!0;for(var n=e-Math.max(Math.floor(this.width/t),1),i=this.root.contentItems[0],a=this._findAllStackContainers()[0],s=0;s<n;s++){var r=i.contentItems[i.contentItems.length-1];this._addChildContentItemsToContainer(a,r)}this._updatingColumnsResponsive=!1}}}else this._firstLoad=!1},_useResponsiveLayout:function(){return this.config.settings&&("always"==this.config.settings.responsiveMode||"onload"==this.config.settings.responsiveMode&&this._firstLoad)},_addChildContentItemsToContainer:function(e,t){"stack"===t.type?t.contentItems.forEach((function(n){e.addChild(n),t.removeChild(n,!0)})):t.contentItems.forEach(r.utils.fnBind((function(t){this._addChildContentItemsToContainer(e,t)}),this))},_findAllStackContainers:function(){var e=[];return this._findAllStackContainersRecursive(e,this.root),e},_findAllStackContainersRecursive:function(e,t){t.contentItems.forEach(r.utils.fnBind((function(t){"stack"==t.type?e.push(t):t.isComponent||this._findAllStackContainersRecursive(e,t)}),this))}}),i=[n(393)],void 0===(a=function(e){return s=e,r.LayoutManager}.apply(t,i))||(e.exports=a),r.config.itemDefaultConfig={isClosable:!0,isFocusOnShow:!0,reorderEnabled:!0,title:""},r.config.defaultConfig={openPopouts:[],settings:{hasHeaders:!0,constrainDragToContainer:!0,reorderEnabled:!0,selectionEnabled:!1,popoutWholeStack:!1,blockedPopoutsThrowError:!0,closePopoutsOnUnload:!0,showPopoutIcon:!0,showMaximiseIcon:!0,showCloseIcon:!0,responsiveMode:"onload",tabOverlapAllowance:0,tabControlOffset:10},dimensions:{borderWidth:5,borderGrabWidth:10,minItemHeight:10,minItemWidth:10,headerHeight:20,dragProxyWidth:300,dragProxyHeight:200},labels:{close:"Close",maximise:"Maximise",minimise:"Minimise",popout:"Open in new window",popin:"Pop in",tabDropdown:"Additional tabs",tabNextLabel:"Next",tabPreviousLabel:"Previous"}},r.container.ItemContainer=function(e,t,n){r.utils.EventEmitter.call(this),this.width=null,this.height=null,this.title=e.componentName,this.parent=t,this.layoutManager=n,this.isHidden=!1,this._config=e,this._element=s(['<div class="lm_item_container">','<div class="lm_content" tabindex="-1"></div>',"</div>"].join("")),this._contentElement=this._element.find(".lm_content")},r.utils.copy(r.container.ItemContainer.prototype,{getElement:function(){return this._contentElement},hide:function(){this.emit("hide"),this.isHidden=!0,this._element.hide()},show:function(){this.emit("show"),this.isHidden=!1,this._element.show(),0==this.height&&0==this.width||this.emit("shown")},setSize:function(e,t){for(var n,i,a,s,r=this.parent,o=this;!r.isColumn&&!r.isRow;)if(o=r,(r=r.parent).isRoot)return!1;for(n=("height"===(i=r.isColumn?"height":"width")?t:e)/(this[i]*(1/(o.config[i]/100)))*100,a=(o.config[i]-n)/(r.contentItems.length-1),s=0;s<r.contentItems.length;s++)r.contentItems[s]===o?r.contentItems[s].config[i]=n:r.contentItems[s].config[i]+=a;return r.callDownwards("setSize"),!0},close:function(){this._config.isClosable&&(this.emit("close"),this.parent.close())},getState:function(){return this._config.componentState},extendState:function(e){this.setState(s.extend(!0,this.getState(),e))},setState:function(e){this._config.componentState=e,this.parent.emitBubblingEvent("stateChanged")},setTitle:function(e){this.parent.setTitle(e)},_$setSize:function(e,t){if(e!==this.width||t!==this.height){this.width=e,this.height=t;var n=this._contentElement[0],i=n.offsetWidth-n.clientWidth,a=n.offsetHeight-n.clientHeight;this._contentElement.width(this.width-i).height(this.height-a),this.emit("resize")}}}),r.controls.BrowserPopout=function(e,t,n,i,a){r.utils.EventEmitter.call(this),this.isInitialised=!1,this._config=e,this._dimensions=t,this._parentId=n,this._indexInParent=i,this._layoutManager=a,this._popoutWindow=null,this._id=null,this._createWindow()},r.utils.copy(r.controls.BrowserPopout.prototype,{toConfig:function(){if(!1===this.isInitialised)throw new Error("Can't create config, layout not yet initialised");return{dimensions:{width:this.getGlInstance().width,height:this.getGlInstance().height,left:this._popoutWindow.screenX||this._popoutWindow.screenLeft,top:this._popoutWindow.screenY||this._popoutWindow.screenTop},content:this.getGlInstance().toConfig().content,parentId:this._parentId,indexInParent:this._indexInParent}},getGlInstance:function(){return this._popoutWindow.__glInstance},getWindow:function(){return this._popoutWindow},close:function(){if(this.getGlInstance())this.getGlInstance()._$closeWindow();else try{this.getWindow().close()}catch(e){}},popIn:function(){var e,t;this._indexInParent;this._parentId&&(e=s.extend(!0,{},this.getGlInstance().toConfig()).content[0],(t=this._layoutManager.root.getItemsById(this._parentId)[0])||(t=this._layoutManager.root.contentItems.length>0?this._layoutManager.root.contentItems[0]:this._layoutManager.root)),t.addChild(e,this._indexInParent),this.close()},_createWindow:function(){var e,t=this._createUrl(),n=Math.floor(1e6*Math.random()).toString(36),i=this._serializeWindowOptions({width:this._dimensions.width,height:this._dimensions.height,innerWidth:this._dimensions.width,innerHeight:this._dimensions.height,menubar:"no",toolbar:"no",location:"no",personalbar:"no",resizable:"yes",scrollbars:"no",status:"no"});if(this._popoutWindow=window.open(t,n,i),this._popoutWindow)s(this._popoutWindow).on("load",r.utils.fnBind(this._positionWindow,this)).on("unload beforeunload",r.utils.fnBind(this._onClose,this)),e=setInterval(r.utils.fnBind((function(){this._popoutWindow.__glInstance&&this._popoutWindow.__glInstance.isInitialised&&(this._onInitialised(),clearInterval(e))}),this),10);else if(!0===this._layoutManager.config.settings.blockedPopoutsThrowError){var a=new Error("Popout blocked");throw a.type="popoutBlocked",a}},_serializeWindowOptions:function(e){var t,n=[];for(t in e)n.push(t+"="+e[t]);return n.join(",")},_createUrl:function(){var e,t={content:this._config},n="gl-window-config-"+r.utils.getUniqueId();t=(new r.utils.ConfigMinifier).minifyConfig(t);try{localStorage.setItem(n,JSON.stringify(t))}catch(i){throw new Error("Error while writing to localStorage "+i.toString())}return 1===(e=document.location.href.split("?")).length?e[0]+"?gl-window="+n:document.location.href+"&gl-window="+n},_positionWindow:function(){this._popoutWindow.moveTo(this._dimensions.left,this._dimensions.top),this._popoutWindow.focus()},_onInitialised:function(){this.isInitialised=!0,this.getGlInstance().on("popIn",this.popIn,this),this.emit("initialised")},_onClose:function(){setTimeout(r.utils.fnBind(this.emit,this,["closed"]),50)}}),r.controls.DragProxy=function(e,t,n,i,a,o){r.utils.EventEmitter.call(this),this._dragListener=n,this._layoutManager=i,this._contentItem=a,this._originalParent=o,this._area=null,this._lastValidArea=null,this._dragListener.on("drag",this._onDrag,this),this._dragListener.on("dragStop",this._onDrop,this),this._contentItem.tab&&this._contentItem.tab.element&&(this._layoutManager.tabDropPlaceholder.width(this._contentItem.tab.element.outerWidth(!0)),this._layoutManager.tabDropPlaceholder.height(this._contentItem.tab.element.outerHeight(!0))),this.element=s(r.controls.DragProxy._template),o&&o._side&&(this._sided=o._sided,this.element.addClass("lm_"+o._side),["right","bottom"].indexOf(o._side)>=0&&this.element.find(".lm_content").after(this.element.find(".lm_header"))),this.element.css({left:e,top:t}),this._proxyTab=this.element.find(".lm_tab"),this._proxyTab.attr("title",r.utils.stripTags(this._contentItem.config.title)),this.element.find(".lm_title").html(this._contentItem.config.title),this.childElementContainer=this.element.find(".lm_content"),this.childElementContainer.append(a.element),this._updateTree(),this._layoutManager._$calculateItemAreas(),this._setDimensions(),s(document.body).append(this.element),!this._contentItem.tab&&this._proxyTab.length&&(this._layoutManager.tabDropPlaceholder.width(this._proxyTab.outerWidth(!0)),this._layoutManager.tabDropPlaceholder.height(this._proxyTab.outerHeight(!0)));var l=this._layoutManager.container.offset();this._minX=l.left,this._minY=l.top,this._maxX=this._layoutManager.container.width()+this._minX,this._maxY=this._layoutManager.container.height()+this._minY,this._width=this.element.width(),this._height=this.element.height(),this._setDropPosition(e,t),this._layoutManager.emit("itemPickedUp",this._contentItem)},r.controls.DragProxy._template='<div class="lm_dragProxy"><div class="lm_header"><ul class="lm_tabs"><li class="lm_tab lm_active"><i class="lm_left"></i><span class="lm_title"></span><i class="lm_right"></i></li></ul></div><div class="lm_content"></div></div>',r.utils.copy(r.controls.DragProxy.prototype,{_onDrag:function(e,t,n){var i=(n=n.originalEvent&&n.originalEvent.touches?n.originalEvent.touches[0]:n).pageX,a=n.pageY;(i>this._minX&&i<this._maxX&&a>this._minY&&a<this._maxY||!0!==this._layoutManager.config.settings.constrainDragToContainer)&&this._setDropPosition(i,a)},_setDropPosition:function(e,t){this.element.css({left:e,top:t}),this._area=this._layoutManager._$getArea(e,t),null!==this._area&&(this._lastValidArea=this._area,this._area.contentItem._$highlightDropZone(e,t,this._area))},_onDrop:function(){this._layoutManager.dropTargetIndicator.hide(),null!==this._area?this._area.contentItem._$onDrop(this._contentItem,this._area):null!==this._lastValidArea?this._lastValidArea.contentItem._$onDrop(this._contentItem,this._lastValidArea):this._originalParent?this._originalParent.addChild(this._contentItem):this._contentItem._$destroy(),this._dragListener.off("drag",this._onDrag,this),this._dragListener.off("dragStop",this._onDrop,this),this.element.remove(),this._layoutManager.emit("itemDropped",this._contentItem)},_updateTree:function(){this._contentItem.parent&&this._contentItem.parent.removeChild(this._contentItem,!0),this._contentItem._$setParent(this)},_setDimensions:function(){var e=this._layoutManager.config.dimensions,t=e.dragProxyWidth,n=e.dragProxyHeight;this.element.width(t),this.element.height(n),t-=this._sided?e.headerHeight:0,n-=this._sided?0:e.headerHeight,this.childElementContainer.width(t),this.childElementContainer.height(n),this._contentItem.element.width(t),this._contentItem.element.height(n),this._contentItem.callDownwards("_$show"),this._contentItem.callDownwards("setSize")}}),r.controls.DragSource=function(e,t,n){this._element=e,this._itemConfig=t,this._layoutManager=n,this._dragListener=null,this._createDragListener()},r.utils.copy(r.controls.DragSource.prototype,{_createDragListener:function(){this._dragListener=new r.utils.DragListener(this._element,!0),this._dragListener.on("dragStart",this._onDragStart,this),this._dragListener.on("dragStop",this._createDragListener,this)},_onDragStart:function(e,t){var n=this._itemConfig;r.utils.isFunction(n)&&(n=n());var i=this._layoutManager._$normalizeContentItem(s.extend(!0,{},n)),a=new r.controls.DragProxy(e,t,this._dragListener,this._layoutManager,i,null);this._layoutManager.transitionIndicator.transitionElements(this._element,a.element)}}),r.controls.DragSourceFromEvent=function(e,t,n){this._element=s(window),this._itemConfig=e,this._layoutManager=t,this._dragListener=null,this._createDragListener(n)},r.utils.copy(r.controls.DragSourceFromEvent.prototype,{_createDragListener:function(e){null!==this._dragListener&&this._dragListener.destroy(),this._dragListener=new r.utils.DragListener(this._element,!0),this._dragListener.on("dragStart",this._onDragStart,this),this._dragListener.on("dragStop",this._destroy,this),this._dragListener._fDown(e),this._dragListener._startDrag()},_destroy:function(){this._dragListener=null,this._element=null,this._itemConfig=null,this._layoutManager=null},_onDragStart:function(e,t){var n=this._itemConfig;r.utils.isFunction(n)&&(n=n());var i=this._layoutManager._$normalizeContentItem(s.extend(!0,{},n));new r.controls.DragProxy(e,t,this._dragListener,this._layoutManager,i,null)}}),r.controls.DropTargetIndicator=function(){this.element=s(r.controls.DropTargetIndicator._template),s(document.body).append(this.element)},r.controls.DropTargetIndicator._template='<div class="lm_dropTargetIndicator"><div class="lm_inner"></div></div>',r.utils.copy(r.controls.DropTargetIndicator.prototype,{destroy:function(){this.element.remove()},highlightArea:function(e){this.element.css({left:e.x1,top:e.y1,width:Math.floor(e.x2-e.x1),height:Math.floor(e.y2-e.y1)}).show()},hide:function(){this.element.hide()}}),r.controls.Header=function(e,t){r.utils.EventEmitter.call(this),this.layoutManager=e,this.element=s(r.controls.Header._template),!0===this.layoutManager.config.settings.selectionEnabled&&(this.element.addClass("lm_selectable"),this.element.on("click",r.utils.fnBind(this._onHeaderClick,this))),this.tabsContainer=this.element.find(".lm_tabs"),this.tabDropdownContainer=this.element.find(".lm_tabdropdown_list"),this.tabDropdownContainer.hide(),this.tabDropdownSearch=this.element.find(".lm_tabdropdown_search input"),this.tabDropdownList=null,this._handleFilterInput=this._handleFilterInput.bind(this),this._handleFilterKeydown=this._handleFilterKeydown.bind(this),this.tabDropdownSearch.on("input",this._handleFilterInput),this.tabDropdownSearch.on("keydown",this._handleFilterKeydown),this.controlsContainer=this.element.find(".lm_controls"),this.parent=t,this.parent.on("resize",this._updateTabSizes,this),this.tabs=[],this.activeContentItem=null,this.closeButton=null,this.tabDropdownButton=null,this.tabNextButton=s(r.controls.Header._nextButtonTemplate),this.tabPreviousButton=s(r.controls.Header._previousButtonTemplate),this._handleItemPickedUp=this._handleItemPickedUp.bind(this),this._handleItemDropped=this._handleItemDropped.bind(this),this._handleNextMouseEnter=this._handleNextMouseEnter.bind(this),this._handleNextMouseLeave=this._handleNextMouseLeave.bind(this),this._handlePreviousMouseEnter=this._handlePreviousMouseEnter.bind(this),this._handlePreviousMouseLeave=this._handlePreviousMouseLeave.bind(this),this._handleScrollRepeat=this._handleScrollRepeat.bind(this),this._handleNextButtonMouseDown=this._handleNextButtonMouseDown.bind(this),this._handlePreviousButtonMouseDown=this._handlePreviousButtonMouseDown.bind(this),this._handleScrollButtonMouseDown=this._handleScrollButtonMouseDown.bind(this),this._handleScrollButtonMouseUp=this._handleScrollButtonMouseUp.bind(this),this._handleScrollEvent=this._handleScrollEvent.bind(this),this.tabNextButton.on("mousedown",this._handleNextButtonMouseDown),this.tabPreviousButton.on("mousedown",this._handlePreviousButtonMouseDown),this.tabsContainer.on("scroll",this._handleScrollEvent),this.holdTimer=null,this.rAF=null,this.CLICK_TIMEOUT=500,this.START_SPEED=.01,this.ACCELERATION=5e-4,this.SCROLL_LEFT="left",this.SCROLL_RIGHT="right",this.layoutManager.on("itemPickedUp",this._handleItemPickedUp),this.layoutManager.on("itemDropped",this._handleItemDropped),this.isDraggingTab=!1,this.isOverflowing=!1,this.isDropdownShown=!1,this.dropdownKeyIndex=0,this.tabsContainer.before(this.tabPreviousButton),this.tabPreviousButton=this.tabPreviousButton.find(">:first-child"),this.tabPreviousButton.hide(),this._showAdditionalTabsDropdown=this._showAdditionalTabsDropdown.bind(this),this._hideAdditionalTabsDropdown=this._hideAdditionalTabsDropdown.bind(this),this._lastVisibleTabIndex=-1,this._tabControlOffset=this.layoutManager.config.settings.tabControlOffset,this._createControls()},r.controls.Header._template=['<div class="lm_header">','<ul class="lm_tabs"></ul>','<ul class="lm_controls"></ul>','<ul class="lm_tabdropdown_list">','<li class="lm_tabdropdown_search"><input type="text" placeholder="Find tab..."></li>',"</ul>","</div>"].join(""),r.controls.Header._previousButtonTemplate=['<ul class="lm_controls">','<li class="lm_tabpreviousbutton"></li>',"</ul>"].join(""),r.controls.Header._nextButtonTemplate=['<li class="lm_tabnextbutton"></li>'].join(""),r.utils.copy(r.controls.Header.prototype,{createTab:function(e,t){var n,i;for(i=0;i<this.tabs.length;i++)if(this.tabs[i].contentItem===e)return;if(n=new r.controls.Tab(this,e),0===this.tabs.length)return this.tabs.push(n),void this.tabsContainer.append(n.element);void 0===t&&(t=this.tabs.length),t>0?this.tabs[t-1].element.after(n.element):this.tabs[0].element.before(n.element),this.tabs.splice(t,0,n),this._updateTabSizes()},removeTab:function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].contentItem===e)return this.tabs[t]._$destroy(),void this.tabs.splice(t,1);throw new Error("contentItem is not controlled by this header")},setActiveContentItem:function(e){for(var t,n=0;n<this.tabs.length;n++)t=this.tabs[n].contentItem===e,this.tabs[n].setActive(t),!0===t&&(this.activeContentItem=e,this.parent.config.activeItemIndex=n);this.tabs[this.parent.config.activeItemIndex].element.get(0).scrollIntoView({inline:"nearest"}),this._hideAdditionalTabsDropdown(),this._updateTabSizes(),this.parent.emitBubblingEvent("stateChanged")},position:function(e){var t=this.parent._header.show;return t&&!this.parent._side&&(t="top"),void 0!==e&&this.parent._header.show!==e&&(this.parent._header.show=e,this.parent._setupHeaderPosition()),t},_attachWheelListener:function(){this.tabsContainer.get(0).addEventListener("wheel",this._handleWheelEvent,{passive:!0})},_detachWheelListener:function(){this.tabsContainer.get(0).removeEventListener("wheel",this._handleWheelEvent,{passive:!0})},_handleWheelEvent:function(e){var t=e.currentTarget,n=Math.abs(e.deltaY)>Math.abs(e.deltaX)?e.deltaY:e.deltaX;e.deltaMode===WheelEvent.DOM_DELTA_PAGE?n*=this.tabsContainer.innerWidhth():e.deltaMode===WheelEvent.DOM_DELTA_LINE&&(n*=100/3),t.scrollLeft+=Math.round(n)},_handleScrollEvent:function(){this._checkScrollArrows()},_handleItemPickedUp:function(){this.isDraggingTab=!0,this.controlsContainer.on("mouseenter",this._handleNextMouseEnter),this.tabPreviousButton.on("mouseenter",this._handlePreviousMouseEnter)},_handleItemDropped:function(){this.isDraggingTab=!1,this.rAF=window.cancelAnimationFrame(this.rAF),this.controlsContainer.off("mouseenter",this._handleNextMouseEnter),this.controlsContainer.off("mouseleave",this._handleNextMouseLeave),this.tabPreviousButton.off("mouseenter",this._handlePreviousMouseEnter),this.tabPreviousButton.off("mouseleave",this._handlePreviousMouseLeave)},_handleNextMouseEnter:function(){this.controlsContainer.on("mouseleave",this._handleNextMouseLeave),this._handleScrollRepeat(this.SCROLL_RIGHT,this.tabsContainer.scrollLeft())},_handlePreviousMouseEnter:function(){this.tabPreviousButton.on("mouseleave",this._handlePreviousMouseLeave),this._handleScrollRepeat(this.SCROLL_LEFT,this.tabsContainer.scrollLeft())},_handleNextMouseLeave:function(){this.rAF=window.cancelAnimationFrame(this.rAF),this.controlsContainer.off("mouseleave",this._handleNextMouseLeave)},_handlePreviousMouseLeave:function(){this.rAF=window.cancelAnimationFrame(this.rAF),this.tabPreviousButton.off("mouseleave",this._handlePreviousMouseLeave)},_handleNextButtonMouseDown:function(){for(var e,t=0;t<this.tabs.length;t+=1)if(this.tabs[t].element.get(0).offsetLeft>this.tabsContainer.get(0).offsetWidth+this.tabsContainer.scrollLeft()){e=this.tabs[t].element.get(0);break}e?(e.scrollIntoView({behavior:"smooth",inline:"nearest"}),this._handleScrollButtonMouseDown(this.SCROLL_RIGHT)):this.tabsContainer.get(0).scrollLeft=this.tabsContainer.get(0).scrollWidth},_handlePreviousButtonMouseDown:function(){for(var e,t=this.tabs.length-1;t>=0;t-=1)if(this.tabs[t].element.get(0).offsetLeft<this.tabsContainer.scrollLeft()){e=this.tabs[t].element.get(0);break}e?(e.scrollIntoView({behavior:"smooth",inline:"start"}),this._handleScrollButtonMouseDown(this.SCROLL_LEFT)):this.tabsContainer.get(0).scrollLeft=0},_handleScrollButtonMouseDown:function(e){this.holdTimer=setTimeout(function(){this._handleScrollRepeat(e,this.tabsContainer.scrollLeft(),100)}.bind(this),this.CLICK_TIMEOUT),window.addEventListener("mouseup",this._handleScrollButtonMouseUp)},_handleScrollButtonMouseUp:function(){this.holdTimer=clearTimeout(this.holdTimer),this.rAF=cancelAnimationFrame(this.rAF),window.removeEventListener("mouseup",this._handleScrollButtonMouseUp)},_checkScrollArrows:function(){0===this.tabsContainer.scrollLeft()?this.tabPreviousButton.first().attr("disabled",!0):this.tabsContainer.scrollLeft()+this.tabsContainer.innerWidth()===this.tabsContainer.get(0).scrollWidth?this.tabNextButton.attr("disabled",!0):(this.tabNextButton.attr("disabled",!1),this.tabPreviousButton.first().attr("disabled",!1))},_handleScrollRepeat:function(e,t,n,i){n||(n=0);var a=this.tabsContainer.get(0).getBoundingClientRect();if(e===this.SCROLL_LEFT){if(this.tabsContainer.scrollLeft(t-n),this.isDraggingTab&&this.parent._highlightHeaderDropZone(a.left-1),0===this.tabsContainer.scrollLeft())return void this._checkScrollArrows()}else if(e===this.SCROLL_RIGHT&&(this.tabsContainer.scrollLeft(t+n),this.isDraggingTab&&this.parent._highlightHeaderDropZone(a.right+1),this.tabsContainer.scrollLeft()+this.tabsContainer.innerWidth()===this.tabsContainer.get(0).scrollWidth))return void this._checkScrollArrows();window.cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(function(n){var a=i||n,s=n-a,r=this.START_SPEED*s+.5*this.ACCELERATION*(s*s);r=Math.min(r,this.tabsContainer.get(0).scrollWidth),this._handleScrollRepeat(e,t,r,a)}.bind(this))},_$setClosable:function(e){return!(!this.closeButton||!this._isClosable())&&(this.closeButton.element[e?"show":"hide"](),!0)},_$destroy:function(){this.emit("destroy",this);for(var e=0;e<this.tabs.length;e++)this.tabs[e]._$destroy();this._detachWheelListener(),this._handleItemDropped(),s(document).off("mouseup",this._hideAdditionalTabsDropdown),this.tabDropdownSearch.off("input",this._handleFilterInput),this.tabDropdownSearch.off("keydown",this._handleFilterKeydown),this.element.remove()},_getHeaderSetting:function(e){if(e in this.parent._header)return this.parent._header[e]},_createControls:function(){var e,t,n,i,a,s,o,l;l=this.layoutManager.config.labels.tabDropdown,this.layoutManager.config.labels.tabNextLabel,this.layoutManager.config.labels.tabPreviousLabel,this.tabDropdownButton=new r.controls.HeaderButton(this,l,"lm_tabdropdown",this._showAdditionalTabsDropdown),this.tabDropdownButton.element.hide(),this.controlsContainer.prepend(this.tabNextButton),this.tabNextButton.hide(),this._getHeaderSetting("popout")&&(t=r.utils.fnBind(this._onPopoutClick,this),n=this._getHeaderSetting("popout"),new r.controls.HeaderButton(this,n,"lm_popout",t)),this._getHeaderSetting("maximise")&&(s=r.utils.fnBind(this.parent.toggleMaximise,this.parent),i=this._getHeaderSetting("maximise"),a=this._getHeaderSetting("minimise"),o=new r.controls.HeaderButton(this,i,"lm_maximise",s),this.parent.on("maximised",(function(){o.element.attr("title",a)})),this.parent.on("minimised",(function(){o.element.attr("title",i)}))),this._isClosable()&&(e=r.utils.fnBind(this.parent.remove,this.parent),n=this._getHeaderSetting("close"),this.closeButton=new r.controls.HeaderButton(this,n,"lm_close",e))},_showAdditionalTabsDropdown:function(){this.isDropdownShown?this._hideAdditionalTabsDropdown():(this.tabDropdownList=this.tabsContainer.clone(!0).appendTo(this.tabDropdownContainer).children().removeClass("lm_active"),this.tabDropdownContainer.show(),this.isDropdownShown=!0,this.element.addClass("lm_dropdown_open"),this.tabDropdownSearch.val("").focus(),this.dropdownKeyIndex=0,this.tabDropdownList.eq(this.dropdownKeyIndex).addClass("lm_keyboard_active"),s(document).on("mousedown",this._hideAdditionalTabsDropdown),this._updateAdditionalTabsDropdown())},_handleFilterKeydown:function(e){if(-1!==this.dropdownKeyIndex)if("Escape"!==e.key){if("Enter"===e.key||" "===e.key)return this._hideAdditionalTabsDropdown(),void this.tabs[this.dropdownKeyIndex]._onTabClick();"ArrowDown"===e.key||"Tab"===e.key&&!1===e.shiftKey?(e.preventDefault(),this.tabDropdownList.eq(this.dropdownKeyIndex).removeClass("lm_keyboard_active"),this.dropdownKeyIndex=t(this.dropdownKeyIndex,1,this.tabDropdownList),this.tabDropdownList.eq(this.dropdownKeyIndex).addClass("lm_keyboard_active")):"ArrowUp"!==e.key&&"Tab"!==e.key||(e.preventDefault(),this.tabDropdownList.eq(this.dropdownKeyIndex).removeClass("lm_keyboard_active"),this.dropdownKeyIndex=t(this.dropdownKeyIndex,-1,this.tabDropdownList),this.tabDropdownList.eq(this.dropdownKeyIndex).addClass("lm_keyboard_active"))}else this._hideAdditionalTabsDropdown();function t(e,t,n){if(n.length<2)return-1;for(var i=(e+t+n.length)%n.length;i!==e;){if("none"!==n.eq(i).css("display"))return i;i=(i+t+n.length)%n.length}return e}},_handleFilterInput:function(e){this.tabDropdownList.eq(this.dropdownKeyIndex).removeClass("lm_keyboard_active"),this.dropdownKeyIndex=-1;for(var t=0;t<this.tabDropdownList.length;t++)-1!==this.tabs[t].contentItem.config.title.toLowerCase().indexOf(e.target.value.toLowerCase())?(this.tabDropdownList.eq(t).css("display",""),-1===this.dropdownKeyIndex&&(this.dropdownKeyIndex=t)):this.tabDropdownList.eq(t).css("display","none");-1!==this.dropdownKeyIndex&&this.tabDropdownList.eq(this.dropdownKeyIndex).addClass("lm_keyboard_active")},_hideAdditionalTabsDropdown:function(e){this.isDropdownShown&&(e&&this.tabDropdownContainer.get(0).contains(e.target)||e&&this.tabDropdownButton.element.get(0)===e.target||(this.element.removeClass("lm_dropdown_open"),this.tabDropdownContainer.hide(),this.isDropdownShown=!1,this.tabDropdownContainer.find(".lm_tabs").remove(),s(document).off("mousedown",this._hideAdditionalTabsDropdown)))},_updateAdditionalTabsDropdown:function(){this.tabDropdownContainer.css("max-height","");var e=this.tabDropdownContainer[0].scrollHeight;if(0!==e){var t=this.tabDropdownContainer.offset().top-s(window).scrollTop();t+e>s(window).height()&&this.tabDropdownContainer.css("max-height",s(window).height()-t-10)}},_isClosable:function(){return this.parent.config.isClosable&&this.layoutManager.config.settings.showCloseIcon},_onPopoutClick:function(){!0===this.layoutManager.config.settings.popoutWholeStack?this.parent.popout():this.activeContentItem.popout()},_onHeaderClick:function(e){e.target===this.element[0]&&this.parent.select()},_updateTabSizes:function(){0!==this.tabs.length&&(!this.isOverflowing&&this.tabsContainer.get(0).scrollWidth>this.tabsContainer.get(0).clientWidth?(this.tabDropdownButton.element.show(),this.tabNextButton.show(),this.tabPreviousButton.show(),this.isOverflowing=!0):this.isOverflowing&&this.tabsContainer.get(0).scrollWidth<=this.tabsContainer.get(0).clientWidth&&(this.tabDropdownButton.element.hide(),this.tabNextButton.hide(),this.tabPreviousButton.hide(),this.isOverflowing=!1),this.isOverflowing&&this._checkScrollArrows())}}),r.controls.HeaderButton=function(e,t,n,i){this._header=e,this.element=s('<li class="'+n+'" title="'+t+'"></li>'),this._header.on("destroy",this._$destroy,this),this._action=i,this.element.on("click",this._action),this._header.controlsContainer.append(this.element)},r.utils.copy(r.controls.HeaderButton.prototype,{_$destroy:function(){this.element.off(),this.element.remove()}}),r.controls.Splitter=function(e,t,n){this._isVertical=e,this._size=t,this._grabSize=n<t?t:n,this.element=this._createElement(),this._dragListener=new r.utils.DragListener(this.element)},r.utils.copy(r.controls.Splitter.prototype,{on:function(e,t,n){this._dragListener.on(e,t,n)},_$destroy:function(){this._dragListener.destroy(),this._dragListener=null,this.element.remove()},_createElement:function(){var e=s('<div class="lm_drag_handle"></div>'),t=s('<div class="lm_splitter"></div>');t.append(e);var n=this._grabSize-this._size,i=n/2;return this._isVertical?(e.css("top",-i),e.css("height",this._size+n),t.addClass("lm_vertical"),t.height(this._size)):(e.css("left",-i),e.css("width",this._size+n),t.addClass("lm_horizontal"),t.width(this._size)),t}}),r.controls.Tab=function(e,t){this.header=e,this.contentItem=t,this.element=s(r.controls.Tab._template),this.titleElement=this.element.find(".lm_title"),this.closeElement=this.element.find(".lm_close_tab"),this.closeElement[t.config.isClosable?"show":"hide"](),this.isActive=!1,this.setTitle(t.config.title),this.contentItem.on("titleChanged",this.setTitle,this),this._layoutManager=this.contentItem.layoutManager,!0===this._layoutManager.config.settings.reorderEnabled&&!0===t.config.reorderEnabled&&(this._dragListener=new r.utils.DragListener(this.element),this._dragListener.on("dragStart",this._onDragStart,this),this.contentItem.on("destroy",this._dragListener.destroy,this._dragListener)),this._onTabClickFn=r.utils.fnBind(this._onTabClick,this),this._onCloseClickFn=r.utils.fnBind(this._onCloseClick,this),this._onTabContentFocusInFn=r.utils.fnBind(this._onTabContentFocusIn,this),this._onTabContentFocusOutFn=r.utils.fnBind(this._onTabContentFocusOut,this),this.element.on("mousedown",this._onTabClickFn),this.contentItem.config.isClosable?(this.closeElement.on("click",this._onCloseClickFn),this.closeElement.on("mousedown",this._onCloseMousedown)):this.closeElement.remove(),this.contentItem.tab=this,this.contentItem.emit("tab",this),this.contentItem.layoutManager.emit("tabCreated",this),this.contentItem.isComponent&&(this.contentItem.container._contentElement.on("focusin click",this._onTabContentFocusInFn).on("focusout",this._onTabContentFocusOutFn),this.contentItem.container.tab=this,this.contentItem.container.emit("tab",this))},r.controls.Tab._template=['<li class="lm_tab">','<span class="lm_title_before"></span>','<span class="lm_title"></span>','<div class="lm_close_tab"></div>',"</li>"].join(""),r.utils.copy(r.controls.Tab.prototype,{setTitle:function(e){this.titleElement.html(e)},setActive:function(e){e!==this.isActive&&(this.isActive=e,e?this.element.addClass("lm_active"):this.element.removeClass("lm_active"))},_$destroy:function(){this.element.off("mousedown",this._onTabClickFn),this.closeElement.off("click",this._onCloseClickFn),this.contentItem.isComponent&&this.contentItem.container._contentElement.off(),this._dragListener&&(this.contentItem.off("destroy",this._dragListener.destroy,this._dragListener),this._dragListener.off("dragStart",this._onDragStart),this._dragListener=null),this.element.remove()},_onDragStart:function(e,t){!0===this.contentItem.parent.isMaximised&&this.contentItem.parent.toggleMaximise(),new r.controls.DragProxy(e,t,this._dragListener,this._layoutManager,this.contentItem,this.header.parent)},_onTabContentFocusIn:function(){this.contentItem.container._contentElement[0].contains(document.activeElement)||this.contentItem.container._contentElement[0].focus(),this.element.addClass("lm_focusin")},_onTabContentFocusOut:function(){this.contentItem.container._contentElement[0].contains(document.activeElement)||this.element.removeClass("lm_focusin")},_onTabClick:function(e){if(e&&0!==e.button)1===e.button&&this.contentItem.config.isClosable&&this._onCloseClick(e);else{var t=this.header.parent.getActiveContentItem();this.contentItem!==t?(this.header.parent.setActiveContentItem(this.contentItem),this.contentItem.container.emit("tabClicked")):this.contentItem.isComponent&&!this.contentItem.container._contentElement[0].contains(document.activeElement)&&this.contentItem.container._contentElement.focus(),this.header._hideAdditionalTabsDropdown(),this.element.get(0).scrollIntoView({inline:"nearest"})}},_onCloseClick:function(e){e.stopPropagation(),this.contentItem.isComponent?this.contentItem.container.close():this.header.parent.removeChild(this.contentItem)},_onCloseMousedown:function(e){e.stopPropagation()}}),r.controls.TransitionIndicator=function(){this._element=s('<div class="lm_transition_indicator"></div>'),s(document.body).append(this._element),this._toElement=null,this._fromDimensions=null,this._totalAnimationDuration=200,this._animationStartTime=null},r.utils.copy(r.controls.TransitionIndicator.prototype,{destroy:function(){this._element.remove()},transitionElements:function(e,t){},_nextAnimationFrame:function(){var e,t=this._measure(this._toElement),n=(r.utils.now()-this._animationStartTime)/this._totalAnimationDuration,i={};if(n>=1)this._element.hide();else{for(e in t.opacity=0,this._fromDimensions)i[e]=this._fromDimensions[e]+(t[e]-this._fromDimensions[e])*n;this._element.css(i),r.utils.animFrame(r.utils.fnBind(this._nextAnimationFrame,this))}},_measure:function(e){var t=e.offset();return{left:t.left,top:t.top,width:e.outerWidth(),height:e.outerHeight()}}}),r.errors.ConfigurationError=function(e,t){Error.call(this),this.name="Configuration Error",this.message=e,this.node=t},r.errors.ConfigurationError.prototype=new Error,r.items.AbstractContentItem=function(e,t,n){r.utils.EventEmitter.call(this),this.config=this._extendItemNode(t),this.type=t.type,this.contentItems=[],this.parent=n,this.isInitialised=!1,this.isMaximised=!1,this.isRoot=!1,this.isRow=!1,this.isColumn=!1,this.isStack=!1,this.isComponent=!1,this.layoutManager=e,this._pendingEventPropagations={},this._throttledEvents=["stateChanged"],this.on(r.utils.EventEmitter.ALL_EVENT,this._propagateEvent,this),t.content&&this._createContentItems(t)},r.utils.copy(r.items.AbstractContentItem.prototype,{setSize:function(){throw new Error("Abstract Method")},callDownwards:function(e,t,n,i){var a;for(!0!==n&&!0!==i&&this[e].apply(this,t||[]),a=0;a<this.contentItems.length;a++)this.contentItems[a].callDownwards(e,t,n);!0===n&&!0!==i&&this[e].apply(this,t||[])},removeChild:function(e,t){var n=r.utils.indexOf(e,this.contentItems);if(-1===n)throw new Error("Can't remove child item. Unknown content item");!0!==t&&this.contentItems[n]._$destroy(),this.contentItems.splice(n,1),this.config.content.splice(n,1),this.contentItems.length>0?this.callDownwards("setSize"):this instanceof r.items.Root||!0!==this.config.isClosable||this.parent.removeChild(this)},addChild:function(e,t){void 0===t&&(t=this.contentItems.length),this.contentItems.splice(t,0,e),void 0===this.config.content&&(this.config.content=[]),this.config.content.splice(t,0,e.config),e.parent=this,!0===e.parent.isInitialised&&!1===e.isInitialised&&e._$init()},replaceChild:function(e,t,n){t=this.layoutManager._$normalizeContentItem(t);var i=r.utils.indexOf(e,this.contentItems),a=e.element[0].parentNode;if(-1===i)throw new Error("Can't replace child. oldChild is not child of this");a.replaceChild(t.element[0],e.element[0]),!0===n&&(e.parent=null,e._$destroy()),this.contentItems[i]=t,t.parent=this,this.isStack&&(this.header.tabs[i].contentItem=t),!0===t.parent.isInitialised&&!1===t.isInitialised&&t._$init(),this.callDownwards("setSize")},remove:function(){this.parent.removeChild(this)},popout:function(){var e=this.layoutManager.createPopout(this);return this.emitBubblingEvent("stateChanged"),e},toggleMaximise:function(e){e&&e.preventDefault(),!0===this.isMaximised?this.layoutManager._$minimiseItem(this):this.layoutManager._$maximiseItem(this),this.isMaximised=!this.isMaximised,this.emitBubblingEvent("stateChanged")},select:function(){this.layoutManager.selectedItem!==this&&(this.layoutManager.selectItem(this,!0),this.element.addClass("lm_selected"))},deselect:function(){this.layoutManager.selectedItem===this&&(this.layoutManager.selectedItem=null,this.element.removeClass("lm_selected"))},setTitle:function(e){this.config.title=e,this.emit("titleChanged",e),this.emitBubblingEvent("stateChanged")},hasId:function(e){return!!this.config.id&&("string"===typeof this.config.id?this.config.id===e:this.config.id instanceof Array?-1!==r.utils.indexOf(e,this.config.id):void 0)},addId:function(e){this.hasId(e)||(this.config.id?"string"===typeof this.config.id?this.config.id=[this.config.id,e]:this.config.id instanceof Array&&this.config.id.push(e):this.config.id=e)},removeId:function(e){if(!this.hasId(e))throw new Error("Id not found");if("string"===typeof this.config.id)delete this.config.id;else if(this.config.id instanceof Array){var t=r.utils.indexOf(e,this.config.id);this.config.id.splice(t,1)}},getItemsByFilter:function(e){var t=[],n=function(i){for(var a=0;a<i.contentItems.length;a++)!0===e(i.contentItems[a])&&t.push(i.contentItems[a]),n(i.contentItems[a])};return n(this),t},getItemsById:function(e){return this.getItemsByFilter((function(t){return t.config.id instanceof Array?-1!==r.utils.indexOf(e,t.config.id):t.config.id===e}))},getItemsByType:function(e){return this._$getItemsByProperty("type",e)},getComponentsByName:function(e){var t,n=this._$getItemsByProperty("componentName",e),i=[];for(t=0;t<n.length;t++)i.push(n[t].instance);return i},_$getItemsByProperty:function(e,t){return this.getItemsByFilter((function(n){return n[e]===t}))},_$setParent:function(e){this.parent=e},_$highlightDropZone:function(e,t,n){this.layoutManager.dropTargetIndicator.highlightArea(n)},_$onDrop:function(e){this.addChild(e)},_$hide:function(){this._callOnActiveComponents("hide"),this.element.hide(),this.layoutManager.updateSize()},_$show:function(){this._callOnActiveComponents("show"),this.element.show(),this.layoutManager.updateSize()},_callOnActiveComponents:function(e){var t,n,i=this.getItemsByType("stack");for(n=0;n<i.length;n++)(t=i[n].getActiveContentItem())&&t.isComponent&&t.container[e]()},_$destroy:function(){this.emitBubblingEvent("beforeItemDestroyed"),this.callDownwards("_$destroy",[],!0,!0),this.element.remove(),this.emitBubblingEvent("itemDestroyed")},_$getArea:function(e){var t=(e=e||this.element).offset(),n=e.width(),i=e.height();return{x1:t.left,y1:t.top,x2:t.left+n,y2:t.top+i,surface:n*i,contentItem:this}},_$init:function(){var e;for(this.setSize(),e=0;e<this.contentItems.length;e++)this.childElementContainer.append(this.contentItems[e].element);this.isInitialised=!0,this.emitBubblingEvent("itemCreated"),this.emitBubblingEvent(this.type+"Created")},emitBubblingEvent:function(e){var t=new r.utils.BubblingEvent(e,this);this.emit(e,t)},_createContentItems:function(e){var t,n;if(!(e.content instanceof Array))throw new r.errors.ConfigurationError("content must be an Array",e);for(n=0;n<e.content.length;n++)t=this.layoutManager.createContentItem(e.content[n],this),this.contentItems.push(t)},_extendItemNode:function(e){for(var t in r.config.itemDefaultConfig)void 0===e[t]&&(e[t]=r.config.itemDefaultConfig[t]);return e},_propagateEvent:function(e,t){t instanceof r.utils.BubblingEvent&&!1===t.isPropagationStopped&&!0===this.isInitialised&&(!1===this.isRoot&&this.parent?this.parent.emit.apply(this.parent,Array.prototype.slice.call(arguments,0)):this._scheduleEventPropagationToLayoutManager(e,t))},_scheduleEventPropagationToLayoutManager:function(e,t){-1===r.utils.indexOf(e,this._throttledEvents)?this.layoutManager.emit(e,t.origin):!0!==this._pendingEventPropagations[e]&&(this._pendingEventPropagations[e]=!0,r.utils.animFrame(r.utils.fnBind(this._propagateEventToLayoutManager,this,[e,t])))},_propagateEventToLayoutManager:function(e,t){this._pendingEventPropagations[e]=!1,this.layoutManager.emit(e,t)}}),r.items.Component=function(e,t,n){r.items.AbstractContentItem.call(this,e,t,n);var i=e.getComponent(this.config.componentName)||e.getFallbackComponent(),a=s.extend(!0,{},this.config.componentState||{});if(null==i)throw new r.errors.ConfigurationError('Unknown component "'+this.config.componentName+'"');a.componentName=this.config.componentName,this.componentName=this.config.componentName,""===this.config.title&&(this.config.title=this.config.componentName),this.isComponent=!0,this.container=new r.container.ItemContainer(this.config,this,e),this.instance=new i(this.container,a),this.element=this.container._element},r.utils.extend(r.items.Component,r.items.AbstractContentItem),r.utils.copy(r.items.Component.prototype,{close:function(){this.parent.removeChild(this)},setSize:function(){this.element.is(":visible")&&this.container._$setSize(this.element.width(),this.element.height())},_$init:function(){r.items.AbstractContentItem.prototype._$init.call(this),this.container.emit("open")},_$hide:function(){this.container.hide(),r.items.AbstractContentItem.prototype._$hide.call(this)},_$show:function(){this.container.show(),this.container._config.isFocusOnShow&&this.container._contentElement[0].focus({preventScroll:!0}),r.items.AbstractContentItem.prototype._$show.call(this)},_$destroy:function(){this.container.emit("destroy",this),r.items.AbstractContentItem.prototype._$destroy.call(this)},_$getArea:function(){return null}}),r.items.Root=function(e,t,n){r.items.AbstractContentItem.call(this,e,t,null),this.isRoot=!0,this.type="root",this.element=s('<div class="lm_goldenlayout lm_item lm_root"></div>'),this.childElementContainer=this.element,this._containerElement=n,this._containerElement.append(this.element)},r.utils.extend(r.items.Root,r.items.AbstractContentItem),r.utils.copy(r.items.Root.prototype,{addChild:function(e){if(this.contentItems.length>0)throw new Error("Root node can only have a single child");e=this.layoutManager._$normalizeContentItem(e,this),this.childElementContainer.append(e.element),r.items.AbstractContentItem.prototype.addChild.call(this,e),this.callDownwards("setSize"),this.emitBubblingEvent("stateChanged")},setSize:function(e,t){e="undefined"===typeof e?this._containerElement.width():e,t="undefined"===typeof t?this._containerElement.height():t,this.element.width(e),this.element.height(t),this.contentItems[0]&&(this.contentItems[0].element.width(e),this.contentItems[0].element.height(t))},_$highlightDropZone:function(e,t,n){this.layoutManager.tabDropPlaceholder.remove(),r.items.AbstractContentItem.prototype._$highlightDropZone.apply(this,arguments)},_$onDrop:function(e,t){var n;if(e.isComponent&&((n=this.layoutManager.createContentItem({type:"stack",header:e.config.header||{}},this))._$init(),n.addChild(e),e=n),this.contentItems.length){var i="x"==t.side[0]?"row":"column",a="x"==t.side[0]?"width":"height",s="2"==t.side[1],o=this.contentItems[0];if(!o instanceof r.items.RowOrColumn||o.type!=i){var l=this.layoutManager.createContentItem({type:i},this);this.replaceChild(o,l),l.addChild(e,s?0:void 0,!0),l.addChild(o,s?void 0:0,!0),o.config[a]=50,e.config[a]=50,l.callDownwards("setSize")}else{var c=o.contentItems[s?0:o.contentItems.length-1];o.addChild(e,s?0:void 0,!0),c.config[a]*=.5,e.config[a]=c.config[a],o.callDownwards("setSize")}}else this.addChild(e)}}),r.items.RowOrColumn=function(e,t,n,i){r.items.AbstractContentItem.call(this,t,n,i),this.isRow=!e,this.isColumn=e,this.element=s('<div class="lm_item lm_'+(e?"column":"row")+'"></div>'),this.childElementContainer=this.element,this._splitterSize=t.config.dimensions.borderWidth,this._splitterGrabSize=t.config.dimensions.borderGrabWidth,this._isColumn=e,this._dimension=e?"height":"width",this._splitter=[],this._splitterPosition=null,this._splitterMinPosition=null,this._splitterMaxPosition=null},r.utils.extend(r.items.RowOrColumn,r.items.AbstractContentItem),r.utils.copy(r.items.RowOrColumn.prototype,{addChild:function(e,t,n){var i,a,s,o;if(e=this.layoutManager._$normalizeContentItem(e,this),void 0===t&&(t=this.contentItems.length),this.contentItems.length>0?(o=this._createSplitter(Math.max(0,t-1)).element,t>0?(this.contentItems[t-1].element.after(o),o.after(e.element)):(this.contentItems[0].element.before(o),o.before(e.element))):this.childElementContainer.append(e.element),r.items.AbstractContentItem.prototype.addChild.call(this,e,t),i=1/this.contentItems.length*100,!0!==n){for(s=0;s<this.contentItems.length;s++)this.contentItems[s]===e?e.config[this._dimension]=i:(a=this.contentItems[s].config[this._dimension]*=(100-i)/100,this.contentItems[s].config[this._dimension]=a);this.callDownwards("setSize"),this.emitBubblingEvent("stateChanged")}else this.emitBubblingEvent("stateChanged")},removeChild:function(e,t){var n,i,a=e.config[this._dimension],s=r.utils.indexOf(e,this.contentItems),o=Math.max(s-1,0);if(-1===s)throw new Error("Can't remove child. ContentItem is not child of this Row or Column");for(this._splitter[o]&&(this._splitter[o]._$destroy(),this._splitter.splice(o,1)),n=0;n<this.contentItems.length;n++)this.contentItems[n]!==e&&(this.contentItems[n].config[this._dimension]+=a/(this.contentItems.length-1));r.items.AbstractContentItem.prototype.removeChild.call(this,e,t),1===this.contentItems.length&&!0===this.config.isClosable?(i=this.contentItems[0],this.contentItems=[],this.parent.replaceChild(this,i,!0)):(this.callDownwards("setSize"),this.emitBubblingEvent("stateChanged"))},replaceChild:function(e,t){var n=e.config[this._dimension];r.items.AbstractContentItem.prototype.replaceChild.call(this,e,t),t.config[this._dimension]=n,this.callDownwards("setSize"),this.emitBubblingEvent("stateChanged")},setSize:function(){this.contentItems.length>0&&(this._calculateRelativeSizes(),this._setAbsoluteSizes()),this.emitBubblingEvent("stateChanged"),this.emit("resize")},_$init:function(){var e;if(!0!==this.isInitialised)for(r.items.AbstractContentItem.prototype._$init.call(this),e=0;e<this.contentItems.length-1;e++)this.contentItems[e].element.after(this._createSplitter(e).element)},_setAbsoluteSizes:function(){var e,t=this._calculateAbsoluteSizes();for(e=0;e<this.contentItems.length;e++)t.additionalPixel-e>0&&t.itemSizes[e]++,this._isColumn?(this.contentItems[e].element.width(t.totalWidth),this.contentItems[e].element.height(t.itemSizes[e])):(this.contentItems[e].element.width(t.itemSizes[e]),this.contentItems[e].element.height(t.totalHeight))},_calculateAbsoluteSizes:function(){var e,t,n=(this.contentItems.length-1)*this._splitterSize,i=this.element.width(),a=this.element.height(),s=0,r=[];for(this._isColumn?a-=n:i-=n,e=0;e<this.contentItems.length;e++)s+=t=this._isColumn?Math.floor(a*(this.contentItems[e].config.height/100)):Math.floor(i*(this.contentItems[e].config.width/100)),r.push(t);return{itemSizes:r,additionalPixel:Math.floor((this._isColumn?a:i)-s),totalWidth:i,totalHeight:a}},_calculateRelativeSizes:function(){var e,t=0,n=[],i=this._isColumn?"height":"width";for(e=0;e<this.contentItems.length;e++)void 0!==this.contentItems[e].config[i]?t+=this.contentItems[e].config[i]:n.push(this.contentItems[e]);if(100!==Math.round(t))if(Math.round(t)<100&&n.length>0){for(e=0;e<n.length;e++)n[e].config[i]=(100-t)/n.length;this._respectMinItemWidth()}else{if(Math.round(t)>100)for(e=0;e<n.length;e++)n[e].config[i]=50,t+=50;for(e=0;e<this.contentItems.length;e++)this.contentItems[e].config[i]=this.contentItems[e].config[i]/t*100;this._respectMinItemWidth()}else this._respectMinItemWidth()},_respectMinItemWidth:function(){var e,t,n,i,a=this.layoutManager.config.dimensions&&this.layoutManager.config.dimensions.minItemWidth||0,s=[],r=0,o=0,l=0,c=0,h=[];if(!(this._isColumn||!a||this.contentItems.length<=1)){e=this._calculateAbsoluteSizes();for(var d=0;d<this.contentItems.length;d++)this.contentItems[d],(c=e.itemSizes[d])<a?(o+=a-c,i={width:a}):(r+=c-a,i={width:c},s.push(i)),h.push(i);if(!(0===o||o>r)){for(t=o/r,l=o,d=0;d<s.length;d++)i=s[d],l-=n=Math.round((i.width-a)*t),i.width-=n;for(0!==l&&(h[h.length-1].width-=l),d=0;d<this.contentItems.length;d++)this.contentItems[d].config.width=h[d].width/e.totalWidth*100}}},_createSplitter:function(e){var t;return(t=new r.controls.Splitter(this._isColumn,this._splitterSize,this._splitterGrabSize)).on("drag",r.utils.fnBind(this._onSplitterDrag,this,[t]),this),t.on("dragStop",r.utils.fnBind(this._onSplitterDragStop,this,[t]),this),t.on("dragStart",r.utils.fnBind(this._onSplitterDragStart,this,[t]),this),this._splitter.splice(e,0,t),t},_getItemsForSplitter:function(e){var t=r.utils.indexOf(e,this._splitter);return{before:this.contentItems[t],after:this.contentItems[t+1]}},_getMinimumDimensions:function(e){for(var t=0,n=0,i=0;i<e.length;++i)t=Math.max(e[i].minWidth||0,t),n=Math.max(e[i].minHeight||0,n);return{horizontal:t,vertical:n}},_onSplitterDragStart:function(e){var t=this._getItemsForSplitter(e),n=this.layoutManager.config.dimensions[this._isColumn?"minItemHeight":"minItemWidth"],i=this._getMinimumDimensions(t.before.config.content),a=this._isColumn?i.vertical:i.horizontal,s=this._getMinimumDimensions(t.after.config.content),r=this._isColumn?s.vertical:s.horizontal;this._splitterPosition=0,this._splitterMinPosition=-1*(t.before.element[this._dimension]()-(a||n)),this._splitterMaxPosition=t.after.element[this._dimension]()-(r||n)},_onSplitterDrag:function(e,t,n){var i=this._isColumn?n:t;i>this._splitterMinPosition&&i<this._splitterMaxPosition&&(this._splitterPosition=i,e.element.css(this._isColumn?"top":"left",i))},_onSplitterDragStop:function(e){var t=this._getItemsForSplitter(e),n=t.before.element[this._dimension](),i=t.after.element[this._dimension](),a=(this._splitterPosition+n)/(n+i),s=t.before.config[this._dimension]+t.after.config[this._dimension];t.before.config[this._dimension]=a*s,t.after.config[this._dimension]=(1-a)*s,e.element.css({top:0,left:0}),r.utils.animFrame(r.utils.fnBind(this.callDownwards,this,["setSize"]))}}),r.items.Stack=function(e,t,n){r.items.AbstractContentItem.call(this,e,t,n),this.element=s('<div class="lm_item lm_stack"></div>'),this._activeContentItem=null;var i=e.config;this._header={show:!0===i.settings.hasHeaders&&!1!==t.hasHeaders,popout:i.settings.showPopoutIcon&&i.labels.popout,maximise:i.settings.showMaximiseIcon&&i.labels.maximise,close:i.settings.showCloseIcon&&i.labels.close,minimise:i.labels.minimise},i.header&&r.utils.copy(this._header,i.header),t.header&&r.utils.copy(this._header,t.header),t.content&&t.content[0]&&t.content[0].header&&r.utils.copy(this._header,t.content[0].header),this._dropZones={},this._dropSegment=null,this._contentAreaDimensions=null,this._dropIndex=null,this.isStack=!0,this.childElementContainer=s('<div class="lm_items"></div>'),this.header=new r.controls.Header(e,this),this.element.append(this.header.element),this.element.append(this.childElementContainer),this._setupHeaderPosition(),this._$validateClosability()},r.utils.extend(r.items.Stack,r.items.AbstractContentItem),r.utils.copy(r.items.Stack.prototype,{setSize:function(){var e,t=this._header.show?this.layoutManager.config.dimensions.headerHeight:0,n=this.element.width()-(this._sided?t:0),i=this.element.height()-(this._sided?0:t);for(this.childElementContainer.width(n),this.childElementContainer.height(i),e=0;e<this.contentItems.length;e++)this.contentItems[e].element.width(n).height(i);this.emit("resize"),this.emitBubblingEvent("stateChanged")},_$init:function(){var e,t;if(!0!==this.isInitialised){for(this.header._attachWheelListener(),r.items.AbstractContentItem.prototype._$init.call(this),e=0;e<this.contentItems.length;e++)this.header.createTab(this.contentItems[e]),this.contentItems[e]._$hide();if(this.contentItems.length>0){if(!(t=this.contentItems[this.config.activeItemIndex||0]))throw new Error("Configured activeItemIndex out of bounds");this.setActiveContentItem(t)}}},setActiveContentItem:function(e){if(-1===r.utils.indexOf(e,this.contentItems))throw new Error("contentItem is not a child of this stack");null!==this._activeContentItem&&this._activeContentItem._$hide(),this._activeContentItem=e,this.header.setActiveContentItem(e),e._$show(),this.emit("activeContentItemChanged",e),this.layoutManager.emit("activeContentItemChanged",e),this.emitBubblingEvent("stateChanged")},getActiveContentItem:function(){return this.header.activeContentItem},addChild:function(e,t){e=this.layoutManager._$normalizeContentItem(e,this),r.items.AbstractContentItem.prototype.addChild.call(this,e,t),this.childElementContainer.append(e.element),this.header.createTab(e,t),this.setActiveContentItem(e),this.callDownwards("setSize"),this._$validateClosability(),this.emitBubblingEvent("stateChanged")},removeChild:function(e,t){var n=r.utils.indexOf(e,this.contentItems);r.items.AbstractContentItem.prototype.removeChild.call(this,e,t),this.header.removeTab(e),this.header.activeContentItem===e&&(this.contentItems.length>0?this.setActiveContentItem(this.contentItems[Math.max(n-1,0)]):this._activeContentItem=null),this._$validateClosability(),this.emitBubblingEvent("stateChanged")},_$validateClosability:function(){var e,t,n;for(e=this.header._isClosable(),n=0,t=this.contentItems.length;n<t&&e;n++)e=this.contentItems[n].config.isClosable;this.header._$setClosable(e)},_$destroy:function(){r.items.AbstractContentItem.prototype._$destroy.call(this),this.header._$destroy()},_$onDrop:function(e){if("header"===this._dropSegment)return this._resetHeaderDropZone(),void this.addChild(e,this._dropIndex);if("body"!==this._dropSegment){var t,n,i,a="top"===this._dropSegment||"bottom"===this._dropSegment,s="left"===this._dropSegment||"right"===this._dropSegment,o="top"===this._dropSegment||"left"===this._dropSegment,l=a&&this.parent.isColumn||s&&this.parent.isRow,c=a?"column":"row",h=a?"height":"width";e.isComponent&&((n=this.layoutManager.createContentItem({type:"stack",header:e.config.header||{}},this))._$init(),n.addChild(e),e=n),l?(t=r.utils.indexOf(this,this.parent.contentItems),this.parent.addChild(e,o?t:t+1,!0),this.config[h]*=.5,e.config[h]=this.config[h],this.parent.callDownwards("setSize")):(c=a?"column":"row",i=this.layoutManager.createContentItem({type:c},this),this.parent.replaceChild(this,i),i.addChild(e,o?0:void 0,!0),i.addChild(this,o?void 0:0,!0),this.config[h]=50,e.config[h]=50,i.callDownwards("setSize"))}else this.addChild(e)},_$highlightDropZone:function(e,t){var n,i;for(n in this._contentAreaDimensions)if((i=this._contentAreaDimensions[n].hoverArea).x1<e&&i.x2>e&&i.y1<t&&i.y2>t)return void("header"===n?(this._dropSegment="header",this._highlightHeaderDropZone(e,t)):(this._resetHeaderDropZone(),this._highlightBodyDropZone(n)))},_$getArea:function(){if(!1===this.element.is(":visible"))return null;var e=r.items.AbstractContentItem.prototype._$getArea,t=e.call(this,this.header.element),n=e.call(this,this.childElementContainer),i=n.x2-n.x1,a=n.y2-n.y1;return this._contentAreaDimensions={header:{hoverArea:{x1:t.x1,y1:t.y1,x2:t.x2,y2:t.y2},highlightArea:{x1:t.x1,y1:t.y1,x2:t.x2,y2:t.y2}}},this._activeContentItem&&!1===this._activeContentItem.isComponent?t:0===this.contentItems.length?(this._contentAreaDimensions.body={hoverArea:{x1:n.x1,y1:n.y1,x2:n.x2,y2:n.y2},highlightArea:{x1:n.x1,y1:n.y1,x2:n.x2,y2:n.y2}},e.call(this,this.element)):(this._contentAreaDimensions.left={hoverArea:{x1:n.x1,y1:n.y1,x2:n.x1+.25*i,y2:n.y2},highlightArea:{x1:n.x1,y1:n.y1,x2:n.x1+.5*i,y2:n.y2}},this._contentAreaDimensions.top={hoverArea:{x1:n.x1+.25*i,y1:n.y1,x2:n.x1+.75*i,y2:n.y1+.5*a},highlightArea:{x1:n.x1,y1:n.y1,x2:n.x2,y2:n.y1+.5*a}},this._contentAreaDimensions.right={hoverArea:{x1:n.x1+.75*i,y1:n.y1,x2:n.x2,y2:n.y2},highlightArea:{x1:n.x1+.5*i,y1:n.y1,x2:n.x2,y2:n.y2}},this._contentAreaDimensions.bottom={hoverArea:{x1:n.x1+.25*i,y1:n.y1+.5*a,x2:n.x1+.75*i,y2:n.y2},highlightArea:{x1:n.x1,y1:n.y1+.5*a,x2:n.x2,y2:n.y2}},e.call(this,this.element))},_highlightHeaderDropZone:function(e){var t=this.header.tabs.length,n=null,i=null;if(0!==t){var a=this.header.tabsContainer.get(0).getBoundingClientRect(),s=this.layoutManager.tabDropPlaceholder.get(0).getBoundingClientRect();if(e<a.left?e=a.left+1:e>a.right&&(e=a.right-1),!(s.left<e&&e<s.right)){for(var r=0;r<t;r++)if((i=(n=this.header.tabs[r].element).get(0).getBoundingClientRect()).left<e&&e<i.right){this._dropIndex=r;break}n&&e<i.left+.5*i.width?n.before(this.layoutManager.tabDropPlaceholder):n&&(this._dropIndex=Math.min(this._dropIndex+1,t),n.after(this.layoutManager.tabDropPlaceholder))}var o=this.layoutManager.tabDropPlaceholder.offset().left,l=(o=Math.max(o,this.header.tabsContainer.offset().left))+this.layoutManager.tabDropPlaceholder.width();l=Math.min(l,this.header.tabsContainer.offset().left+this.header.tabsContainer.innerWidth()),this.layoutManager.dropTargetIndicator.highlightArea({x1:o,x2:l,y1:this.header.element.offset().top,y2:this.header.element.offset().top+this.header.element.innerHeight()})}else{var c=this.header.element.offset();this.layoutManager.dropTargetIndicator.highlightArea({x1:c.left,x2:c.left+100,y1:this.header.element.offset().top,y2:this.header.element.offset().top+this.header.element.innerHeight()})}},_resetHeaderDropZone:function(){this.layoutManager.tabDropPlaceholder.remove()},_setupHeaderPosition:function(){var e=["right","left","bottom"].indexOf(this._header.show)>=0&&this._header.show;if(this.header.element.toggle(!!this._header.show),this._side=e,this._sided=["right","left"].indexOf(this._side)>=0,this.element.removeClass("lm_left lm_right lm_bottom"),this._side&&this.element.addClass("lm_"+this._side),this.element.find(".lm_header").length&&this.childElementContainer){var t=["right","bottom"].indexOf(this._side)>=0?"before":"after";this.header.element[t](this.childElementContainer),this.callDownwards("setSize")}},_highlightBodyDropZone:function(e){var t=this._contentAreaDimensions[e].highlightArea;this.layoutManager.dropTargetIndicator.highlightArea(t),this._dropSegment=e}}),r.utils.BubblingEvent=function(e,t){this.name=e,this.origin=t,this.isPropagationStopped=!1},r.utils.BubblingEvent.prototype.stopPropagation=function(){this.isPropagationStopped=!0},r.utils.ConfigMinifier=function(){if(this._keys=["settings","hasHeaders","constrainDragToContainer","selectionEnabled","dimensions","borderWidth","minItemHeight","minItemWidth","headerHeight","dragProxyWidth","dragProxyHeight","labels","close","maximise","minimise","popout","content","componentName","componentState","id","width","type","height","isClosable","title","popoutWholeStack","openPopouts","parentId","activeItemIndex","reorderEnabled","borderGrabWidth"],this._keys.length>36)throw new Error("Too many keys in config minifier map");this._values=[!0,!1,"row","column","stack","component","close","maximise","minimise","open in new window"]},r.utils.copy(r.utils.ConfigMinifier.prototype,{minifyConfig:function(e){var t={};return this._nextLevel(e,t,"_min"),t},unminifyConfig:function(e){var t={};return this._nextLevel(e,t,"_max"),t},_nextLevel:function(e,t,n){var i,a;for(i in e)e instanceof Array&&(i=parseInt(i,10)),e.hasOwnProperty(i)&&(a=this[n](i,this._keys),"object"===typeof e[i]?(t[a]=e[i]instanceof Array?[]:{},this._nextLevel(e[i],t[a],n)):t[a]=this[n](e[i],this._values))},_min:function(e,t){if("string"===typeof e&&1===e.length)return"___"+e;var n=r.utils.indexOf(e,t);return-1===n?e:n.toString(36)},_max:function(e,t){return"string"===typeof e&&1===e.length?t[parseInt(e,36)]:"string"===typeof e&&"___"===e.substr(0,3)?e[3]:e}}),r.utils.EventHub=function(e){r.utils.EventEmitter.call(this),this._layoutManager=e,this._dontPropagateToParent=null,this._childEventSource=null,this.on(r.utils.EventEmitter.ALL_EVENT,r.utils.fnBind(this._onEventFromThis,this)),this._boundOnEventFromChild=r.utils.fnBind(this._onEventFromChild,this),s(window).on("gl_child_event",this._boundOnEventFromChild)},r.utils.EventHub.prototype._onEventFromThis=function(){var e=Array.prototype.slice.call(arguments);this._layoutManager.isSubWindow&&e[0]!==this._dontPropagateToParent&&this._propagateToParent(e),this._propagateToChildren(e),this._dontPropagateToParent=null,this._childEventSource=null},r.utils.EventHub.prototype._$onEventFromParent=function(e){this._dontPropagateToParent=e[0],this.emit.apply(this,e)},r.utils.EventHub.prototype._onEventFromChild=function(e){this._childEventSource=e.originalEvent.__gl,this.emit.apply(this,e.originalEvent.__glArgs)},r.utils.EventHub.prototype._propagateToParent=function(e){var t,n="gl_child_event";document.createEvent?(t=window.opener.document.createEvent("HTMLEvents")).initEvent(n,!0,!0):(t=window.opener.document.createEventObject()).eventType=n,t.eventName=n,t.__glArgs=e,t.__gl=this._layoutManager,document.createEvent?window.opener.dispatchEvent(t):window.opener.fireEvent("on"+t.eventType,t)},r.utils.EventHub.prototype._propagateToChildren=function(e){var t,n;for(n=0;n<this._layoutManager.openPopouts.length;n++)(t=this._layoutManager.openPopouts[n].getGlInstance())&&t!==this._childEventSource&&t.eventHub._$onEventFromParent(e)},r.utils.EventHub.prototype.destroy=function(){s(window).off("gl_child_event",this._boundOnEventFromChild)},r.utils.ReactComponentHandler=function(e,t){this._reactComponent=null,this._originalComponentWillUpdate=null,this._container=e,this._initialState=t,this._reactClass=this._getReactClass(),this._container.on("open",this._render,this),this._container.on("destroy",this._destroy,this)},r.utils.copy(r.utils.ReactComponentHandler.prototype,{_render:function(){ReactDOM.render(this._getReactComponent(),this._container.getElement()[0])},_gotReactComponent:function(e){e&&(this._reactComponent=e,this._originalComponentWillUpdate=this._reactComponent.componentWillUpdate||function(){},this._reactComponent.componentWillUpdate=this._onUpdate.bind(this),this._container.getState()&&this._reactComponent.setState(this._container.getState()))},_destroy:function(){ReactDOM.unmountComponentAtNode(this._container.getElement()[0]),this._container.off("open",this._render,this),this._container.off("destroy",this._destroy,this)},_onUpdate:function(e,t){this._container.setState(t),this._originalComponentWillUpdate.call(this._reactComponent,e,t)},_getReactClass:function(){var e,t=this._container._config.component;if(!t)throw new Error("No react component name. type: react-component needs a field `component`");if(!(e=this._container.layoutManager.getComponent(t)||this._container.layoutManager.getFallbackComponent()))throw new Error('React component "'+t+'" not found. Please register all components with GoldenLayout using `registerComponent(name, component)`');return e},_getReactComponent:function(){var e={glEventHub:this._container.layoutManager.eventHub,glContainer:this._container,ref:this._gotReactComponent.bind(this)},t=s.extend(e,this._container._config.props);return React.createElement(this._reactClass,t)}})}(window.$)},486:function(e,t,n){e.exports={"tab-height":"28px","drag-border-width":"5px",lm_goldenlayout:"GoldenLayout_lm_goldenlayout__2GRYd",lm_header:"GoldenLayout_lm_header__2iY8K",lm_controls:"GoldenLayout_lm_controls__2_oQD",lm_maximised:"GoldenLayout_lm_maximised__2N1-_",lm_items:"GoldenLayout_lm_items___5ebP",lm_tabpreviousbutton:"GoldenLayout_lm_tabpreviousbutton__ITtmk",lm_tabnextbutton:"GoldenLayout_lm_tabnextbutton__3Jf_i",lm_tabdropdown:"GoldenLayout_lm_tabdropdown__FSd_x",lm_maximise:"GoldenLayout_lm_maximise__1veNh",lm_tabs:"GoldenLayout_lm_tabs__29-Qw",lm_tab:"GoldenLayout_lm_tab__3D1AN",lm_title:"GoldenLayout_lm_title__20Uyh",lm_title_before:"GoldenLayout_lm_title_before__2ZaGp","editor-unsaved-indicator":"GoldenLayout_editor-unsaved-indicator__3ClJ4","is-unsaved":"GoldenLayout_is-unsaved__1LdNo",lm_active:"GoldenLayout_lm_active__28ofK",lm_focusin:"GoldenLayout_lm_focusin__2shuQ",lm_window_blur:"GoldenLayout_lm_window_blur__1f1PR",lm_content:"GoldenLayout_lm_content__3iiis",lm_close_tab:"GoldenLayout_lm_close_tab__re2q2",lm_splitter:"GoldenLayout_lm_splitter__1HKeO",lm_dragging:"GoldenLayout_lm_dragging__1gOff",lm_dragProxy:"GoldenLayout_lm_dragProxy__3SQdM",lm_tabdropdown_list:"GoldenLayout_lm_tabdropdown_list__yfZE_",lm_tabdropdown_search:"GoldenLayout_lm_tabdropdown_search__3B8FJ",lm_keyboard_active:"GoldenLayout_lm_keyboard_active__2AKC3",lm_dropTargetIndicator:"GoldenLayout_lm_dropTargetIndicator__1_fWl",march:"GoldenLayout_march__3V0NU",lm_inner:"GoldenLayout_lm_inner___P9Ek",app:"GoldenLayout_app__1Yfrc","js-plotly-plot":"GoldenLayout_js-plotly-plot__3xSsB",plotly:"GoldenLayout_plotly__1DHuD"}},493:function(e,t,n){e.exports={"handle-size":"15px","popover-width":"90px","time-slider":"TimeSlider_time-slider__1zF6b","time-slider-popovers":"TimeSlider_time-slider-popovers__3Z0ra","handle-popper":"TimeSlider_handle-popper__JYoqr","flex-spacer":"TimeSlider_flex-spacer__1vblw",track:"TimeSlider_track__mvwRV","track-fills":"TimeSlider_track-fills__2yI1O","track-fill":"TimeSlider_track-fill__dl7bL","track-fill-start":"TimeSlider_track-fill-start__2yfQ_","track-fill-middle":"TimeSlider_track-fill-middle__11mXK","track-fill-end":"TimeSlider_track-fill-end__3Rv67","handle-track":"TimeSlider_handle-track__x4Nhc",handle:"TimeSlider_handle__1VfSe",ticks:"TimeSlider_ticks__2Jnbp","tick-labels":"TimeSlider_tick-labels__1kNTw","tick-label":"TimeSlider_tick-label__zF9No","tick-label-wrapper":"TimeSlider_tick-label-wrapper__3QXwH"}},517:function(e,t,n){"use strict";(function(e){function t(e,t,n,i,a,s,r){try{var o=e[s](r),l=o.value}catch(c){return void n(c)}o.done?t(l):Promise.resolve(l).then(i,a)}class n{static makeMockContext(){return{arc:jest.fn(),beginPath:jest.fn(),clip:jest.fn(),closePath:jest.fn(),createLinearGradient:jest.fn((()=>({addColorStop:jest.fn()}))),fill:jest.fn(),fillRect:jest.fn(),fillText:jest.fn(),lineTo:jest.fn(),measureText:jest.fn((e=>({width:10*e.length}))),moveTo:jest.fn(),rect:jest.fn(),restore:jest.fn(),setTransform:jest.fn(),save:jest.fn(),stroke:jest.fn(),strokeRect:jest.fn(),translate:jest.fn(),scale:jest.fn(),createPattern:jest.fn()}}static flushPromises(){return(n=function*(){yield new Promise(e)},function(){var e=this,i=arguments;return new Promise((function(a,s){var r=n.apply(e,i);function o(e){t(r,a,s,o,l,"next",e)}function l(e){t(r,a,s,o,l,"throw",e)}o(void 0)}))})();var n}}var i,a,s;s={name:"test",operateAs:"test",groups:["allusers","test"],permissions:{isSuperUser:!1,isQueryViewOnly:!1,isNonInteractive:!1,canUsePanels:!0,canCreateDashboard:!0,canCreateCodeStudio:!0,canCreateQueryMonitor:!0,canCopy:!0,canDownloadCsv:!0}},(a="REGULAR_USER")in(i=n)?Object.defineProperty(i,a,{value:s,enumerable:!0,configurable:!0,writable:!0}):i[a]=s}).call(this,n(279).setImmediate)},518:function(e,t,n){},52:function(e,t,n){e.exports={"grid-bg":"#211f22",font:"12px Fira Sans, sans-serif","header-bg":"#2d2a2e","header-color":"#f0f0ee","header-separator-color":"#211f22","header-separator-hover-color":"#929192","header-hidden-separator-hover-color":"#4878ea","header-sort-bar-color":"#aa9af4","header-reverse-bar-color":"#548d29","header-bar-casing-color":"#211f22","header-font":"600 12px Fira Sans, sans-serif","row-background-colors":"#373438 #2d2a2e","selection-color":"rgba(118, 217, 228, 0.09)","selection-outline-color":"#76d9e4","selection-outline-casing-color":"#211f22","row-hover-bg":"#4b494c","selected-row-hover-bg":"rgba(118, 217, 228, 0.25)","scroll-bar-bg":"#322f33","scroll-bar-hover-bg":"#373438","scroll-bar-casing-color":"#555356","scroll-bar-corner-color":"#322f33","scroll-bar-color":"#5b5a5c","scroll-bar-hover-color":"#929192","scroll-bar-active-color":"#c0bfbf","text-color":"#f0f0ee","positive-number-color":"#9edc6f","negative-number-color":"#f95d84","zero-number-color":"#fcd65b","date-color":"#fcd65b","pending-text-color":"#fde38d","error-text-color":"#f95d84","filter-bar-active-bg":"#425175","filter-bar-active-color":"#4878ea","filter-bar-expanded-bg":"#373438","filter-bar-expanded-active-bg":"#313849","filter-bar-expanded-active-cell-bg":"#374d80","filter-bar-separator-color":"#929192","filter-bar-error-color":"#f95d84","filter-icon-color":"#4878ea","scrim-color":"#5b5a5c","context-menu-sort-icon-color":"#aa9af4","context-menu-reverse-icon-color":"#548d29","linker-column-hover-bg":"rgba(118, 217, 228, 0.09)","tree-line-color":"#5b5a5c","tree-marker-color":"#c0bfbf","tree-marker-hover-color":"#fcfcfa","grouped-column-divider-color":"#1a171a","floating-grid-row-color":"#555356","floating-row-background-colors":"#403e41","floating-divider-inner-color":"#403e41","floating-divider-outer-color":"#211f22"}},59:function(e,t,n){e.exports={"error-foreground":"#f95d84",background:"#2d2a2e",foreground:"#fcfcfa","line-height":"19px",string:"#fcd65b","string-delim":"#929192",delimiter:"#b2b1b2",predefined:"#9edc6f",keyword:"#76d9e4",storage:"#f95d84",number:"#aa9af4",operator:"#f95d84",identifier:"#fcfcfa","namespace-identifier":"#f95d84","identifier-js":"#fcd65b",comment:"#7c7b7c","input-option-active-border":"#929192","focus-border":"rgba(72, 120, 234, 0.85)","input-background":"#555356","input-foreground":"#f0f0ee","input-border":"#929192","editor-line-number-foreground":"#929192","editor-selection-background":"#676368","editor-line-highlight-bg":"#373438","context-menu-background":"#555356","context-menu-foreground":"#f0f0ee","menu-selection-background":"#4878ea","log-date":"#929192","log-error":"#f95d84","log-info":"#76d9e4","log-stdout":"#f0f0ee","log-warn":"#fcd65b","log-debug":"#aa9af4","log-trace":"#9edc6f","editor-find-match-background":"#3c5595","editor-find-match-highlight-background":"#343e5d","editor-widget-background":"#403e41","input-option-active-background":"#4878ea","input-option-active-foreground":"#f0f0ee","editor-suggest-widget-background":"#403e41","editor-suggest-widget-border":"#5b5a5c","editor-suggest-widget-foreground":"#f0f0ee","editor-suggest-widget-selected-background":"#41475a","editor-suggest-widget-highlightForeground":"#4878ea","list-hover-background":"#555356"}},665:function(e,t,n){},673:function(e,t,n){},717:function(e,t,n){e.exports={"gray-100":"#fcfcfa","gray-200":"#f0f0ee","gray-300":"#c0bfbf","gray-400":"#929192","gray-500":"#5b5a5c","gray-600":"#555356","gray-700":"#403e41","gray-800":"#373438","gray-850":"#322f33","gray-900":"#211f22",black:"#1a171a",white:"#f0f0ee",yellow:"#fcd65b",green:"#9edc6f",blue:"#76d9e4",purple:"#aa9af4",orange:"#f37e3f",red:"#f95d84",primary:"#4878ea","primary-hover":"#235de6","primary-dark":"#343e5d",secondary:"#5b5a5c",success:"#9edc6f",info:"#fcd65b",warning:"#f37e3f",danger:"#f95d84",light:"#fcfcfa",mid:"#929192",dark:"#373438","text-muted":"#929192",interfacewhite:"#f0f0ee",interfaceblack:"#1a171a",interfacegray:"#2d2a2e","content-bg":"#2d2a2e",background:"#1a171a",foreground:"#f0f0ee",transition:"0.15s"}},732:function(e,t,n){e.exports={resolve:{react:n(0),reactstrap:n(308)}}},752:function(e,t,n){},771:function(e,t){},778:function(e,t,n){},779:function(e,t,n){},780:function(e,t,n){},789:function(e,t,n){},790:function(e,t,n){},792:function(e,t,n){},798:function(e,t,n){},799:function(e,t,n){},800:function(e,t,n){},801:function(e,t,n){},802:function(e,t,n){},803:function(e,t,n){},804:function(e,t,n){},805:function(e,t,n){},806:function(e,t,n){},864:function(e,t,n){},865:function(e,t,n){},866:function(e,t,n){}},[[1464,3,4]]]);
2
- //# sourceMappingURL=main.0ddbc8c0.chunk.js.map